summaryrefslogtreecommitdiff
path: root/Makefile
diff options
context:
space:
mode:
authorNicolas "Pixel" Noble <pixel@nobis-crew.org>2010-06-07 21:06:39 +0200
committerNicolas "Pixel" Noble <pixel@nobis-crew.org>2010-06-07 21:06:39 +0200
commit01dc8b8ee0ff54941656bdf688f5ab095acd1ad3 (patch)
tree5a5919c8e2de6037aa573c604eba0aaddf3f818b /Makefile
parent22356e5e0cf21fdad0029c3afb99a648a3b94f83 (diff)
Adding pre-compiled gmp support.
Diffstat (limited to 'Makefile')
-rw-r--r--Makefile8
1 files changed, 5 insertions, 3 deletions
diff --git a/Makefile b/Makefile
index d255e83..311e5e2 100644
--- a/Makefile
+++ b/Makefile
@@ -36,12 +36,16 @@ FINK=$(USR)
LIBXM = $(FINK)
endif
LIBXM = $(FINK)/sw/lib/libXm.a -lXp
+GMPLIBDIR=../gmp-4.3.2-darwin9/lib
+GMP_LIBS=-all_load $(GMPLIBDIR)/libgmpxx.a $(GMPLIBDIR)/libgmp.a
else
ARCH_FLAGS=-march=i686 -m32
SHARED_FLAGS=-shared
SHARED_EXT=so
LD = g++ -m32
STRIP = strip --strip-unneeded
+GMPLIBDIR=../gmp-4.3.2-linux/lib
+GMP_LIBS=-Wl,--whole-archive $(GMPLIBDIR)/libgmpxx.a $(GMPLIBDIR)/libgmp.a -Wl,--no-whole-archive
endif
INCLUDES = \
@@ -65,8 +69,6 @@ GMP_SOURCES = \
plugin-luagmp.cc \
lgmp.lua \
-GMP_LIBS = -lgmp
-
WHOLE_SOURCES = \
$(GMP_SOURCES) \
@@ -91,7 +93,7 @@ luagmp.a: $(addsuffix .o, $(notdir $(basename $(GMP_SOURCES))))
$(AR) $@ $+
luagmp.$(SHARED_EXT): plugin-luagmp.o luagmp.a
- $(LD) $(LDFLAGS) -o $@ $+ $(IM_LIBS) $(CD_LIBS) $(IUP_LIBS)
+ $(LD) $(LDFLAGS) -o $@ $+ $(GMP_LIBS)
clean:
rm -f *.o *.dep *.so *.dylib *.a