Explorar o código

Add -fPIC for static linked library.

Lianghui %!s(int64=10) %!d(string=hai) anos
pai
achega
6b044c378b
Modificáronse 1 ficheiros con 1 adicións e 0 borrados
  1. 1 0
      Makefile

+ 1 - 0
Makefile

@@ -239,6 +239,7 @@ distclean: clean
 	$(RMF) $(CPROG) lib$(CPROG).so lib$(CPROG).a *.dmg *.msi *.exe lib$(CPROG).dll lib$(CPROG).dll.a
 	$(RMF) $(UNIT_TEST_PROG)
 
+lib$(CPROG).a: CFLAGS += -fPIC
 lib$(CPROG).a: $(LIB_OBJECTS)
 	@$(RMF) $@
 	ar cq $@ $(LIB_OBJECTS)