X-Git-Url: https://fleuret.org/cgi-bin/gitweb/gitweb.cgi?a=blobdiff_plain;f=Makefile;h=3a41714e9cdfb60cf8f2246f2e63700f6ebeadb8;hb=d5b909fd8dd3d0ebc6d1bd107abb5383e2cbeca1;hp=232fe63be43bb4b56ed1376ec0c41cc2413371ad;hpb=9126d5d47b80310a767b861fe8f1221aabd1a52a;p=universe.git diff --git a/Makefile b/Makefile index 232fe63..3a41714 100644 --- a/Makefile +++ b/Makefile @@ -16,14 +16,14 @@ # CXX=g++-3.3 ifeq ($(DEBUG),yes) - CXXFLAGS = -Wall -g -DDEBUG + CXXFLAGS = -fPIC -Wall -g -DDEBUG else # Optimized compilation # CXXFLAGS = -Wall -g -O3 -pg --coverage CXXFLAGS = -fPIC -Wall -g -O3 endif -LDFLAGS = -L/usr/X11R6/lib/ +LDFLAGS = -L/usr/X11R6/lib/ -lz -ldl TASK_SRC = dummy.cc move_square.cc hit_shape.cc TASK_OBJ = $(TASK_SRC:.cc=.task) @@ -44,7 +44,7 @@ main: main.o misc.o \ manipulator.o \ approximer.o \ intelligence.o - $(CXX) -lX11 $(CXXFLAGS) -o $@ $^ $(LDFLAGS) + $(CXX) $(CXXFLAGS) $(LDFLAGS) -lX11 -o $@ $^ %.task: %.cc misc.o universe.o polygon.o xfig_tracer.o map.o task.o manipulator.o $(CXX) $(CXXFLAGS) -shared -Wl,-soname,$@ -o $@ $^