# build dynamic library with -fPIC -shared
CFLAGS = -g # -O3 -fPIC
CXXFLAGS = -g # -O3 -fPIC
CPPFLAGS = -MMD -MP # -I../foo -DNDEBUG
LDFLAGS = # -L../foo -shared -static
LDLIBS = # -lfoo
ifneq ($(wildcard *.cpp),)
CC = $(CXX) # link with CXX for .cpp
endif
# target name is basename of one of the source files
main: $(addsuffix .o,$(basename $(wildcard *.c *.cpp)))
-include *.d
clean: ; rm -fr *.o *.d main
.PHONY: clean
Popular repositories Loading
- chess
chess PublicHTML
- lijh8.github.io
lijh8.github.io PublicHTML
- minimal_makefile
minimal_makefile PublicC
- cmake
cmake PublicCMake
- autotools
autotools PublicMakefile
Something went wrong, please refresh the page to try again.
If the problem persists, check the GitHub status page or contact support.
If the problem persists, check the GitHub status page or contact support.
Uh oh!
There was an error while loading. Please reload this page.