DEV Community

Jaipal001
Jaipal001

Posted on

MyLibc

Github

I started as me implementing syscalls in assembly
now I am trying to implement musl and stdc++

NOTE:
Btw should I change libmyc.so to something else?

Building

make compile # create build/*.o of src
make shared  # creates lib/libmyc.so
# For C++
make stdcxx  # creates lib/libstdc++.so
Enter fullscreen mode Exit fullscreen mode

Run tests

This is one of the rare occasions when I wrote tests

make test-all # run all test
# For solo test:
make test TEST=(test-name)
# as I will assume tested file is in tests/ folder with .c extension
Enter fullscreen mode Exit fullscreen mode

Compiling your files

# For C
make run your-file.c # run-static for static output
# For C++
make runpp your-file.c # runpp-static for static output
Enter fullscreen mode Exit fullscreen mode

Github

Top comments (0)