PROJ=libarg CC=g++ CFLAGS=-g3 -Wall -fpermissive -fno-rtti -fno-exceptions -fno-unwind-tables -Wno-comment LDFLAGS= SOURCE=arg OBJECTS=$(SOURCE:=.o) SOURCES=$(SOURCE:=.c) %.o: %.c $(CC) $(CFLAGS) -c $< make: dynamic static dynamic: CFLAGS+=-fPIC dynamic: clean $(OBJECTS) gcc $(CFLAGS) $(OBJECTS) -shared -o $(PROJ).so static: clean $(OBJECTS) ar rcs $(PROJ).a $(OBJECTS) clean: rm -rf *.o rm -rf *.a rm -rf *.so