A standard project structure for C and C++ with a perfect Makefile.
- Add
lib<package_name>.so
instead oflib.so
for libraries.
- clean
- expand
- run
- test
- static
- dynamic
-f PIC -shared
- Structure
- bin/main
- bin/test
- include/*
- src/main.c
- test/test.c
- lib doesn't have
src/main.c
or any module insrc
withmain
function. - Structure
- bin/test
- include/*
- lib/lib.a
- lib/lib.so
- test/test.c