Enable gcc's link time optimizations.
[SXSI/libbp.git] / Makefile
index 23cd4f6..3effd67 100644 (file)
--- a/Makefile
+++ b/Makefile
@@ -14,9 +14,9 @@ else
 endif
 
 ifeq ($(DEBUG), true)
-       OPT_FLAGS=-O0 -g $(POPCOUNT_FLAG) -fno-PIC -static
+       OPT_FLAGS=-O0 -g $(POPCOUNT_FLAG) -static
 else
-       OPT_FLAGS=-O4 $(POPCOUNT_FLAG) -fno-PIC -static
+       OPT_FLAGS=-O4 $(POPCOUNT_FLAG) -static -flto
 endif
 
 
@@ -24,7 +24,7 @@ endif
 INC_FLAGS=-I.
 CFLAGS= $(INC_FLAGS) $(OPT_FLAGS)
 CXXFLAGS= $(INC_FLAGS) $(OPT_FLAGS)
-CC=gcc
+CC=g++
 
 
 OBJECTS_BP=bp.o bp-utils.o bp-darray.o bp-core.o