From f202e250096c9ede75321adc20ac4dec56294ca2 Mon Sep 17 00:00:00 2001 From: Tobias Markmann Date: Wed, 3 Dec 2008 19:43:59 +0100 Subject: Using new LFLAGS variable. --- configure | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/configure b/configure index a647d910..5de9f67a 100755 --- a/configure +++ b/configure @@ -125,7 +125,8 @@ then LUA_INCDIR_SET=yes LUA_LIBDIR=/usr/local/lib LUA_LIBDIR_SET=yes - CFLAGS="-bundle -Wl,-undefined,dynamic_lookup" + CFLAGS="" + LFLAGS="-bundle -undefined dynamic_lookup" fi fi -- cgit v1.2.3 From d2d44b512ba429551e7ce843d64c25be745a8dd5 Mon Sep 17 00:00:00 2001 From: Tobias Markmann Date: Wed, 3 Dec 2008 20:32:03 +0100 Subject: Making makefile work under OS X finally. Yeah OS X's gcc is a little bit strange. --- util-src/Makefile | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/util-src/Makefile b/util-src/Makefile index fdb689dd..5dcd65d2 100644 --- a/util-src/Makefile +++ b/util-src/Makefile @@ -12,16 +12,21 @@ OPENSSL_LIB?=crypto all: encodings.so hashes.so install: encodings.so hashes.so - install -s *.so ../util/ + install *.so ../util/ clean: rm -f *.so rm -f ../util/*.so -encodings.so: encodings.c - gcc $(CFLAGS) encodings.c -I$(LUA_INCDIR) -l$(LUA_LIB) -l$(IDN_LIB) -o encodings.so +encodings.o: encodings.c + gcc $(CFLAGS) -I$(LUA_INCDIR) -c -o encodings.o encodings.c +encodings.so: encodings.o + export MACOSX_DEPLOYMENT_TARGET="10.3"; gcc $(LFLAGS) -o encodings.so encodings.o -L/usr/local/lib -lcrypto -lidn + -hashes.so: hashes.c - gcc $(CFLAGS) hashes.c -I$(LUA_INCDIR) -l$(LUA_LIB) -l$(OPENSSL_LIB) -o hashes.so +hashes.o: hashes.c + gcc $(CFLAGS) -I$(LUA_INCDIR) -c -o hashes.o hashes.c +hashes.so: hashes.o + export MACOSX_DEPLOYMENT_TARGET="10.3"; gcc $(LFLAGS) -o hashes.so hashes.o -L/usr/local/lib -lcrypto -lssl -- cgit v1.2.3 From 87703412c1bdc8f88f89dd7e4c13fb7df1a83c13 Mon Sep 17 00:00:00 2001 From: Matthew Wild Date: Wed, 3 Dec 2008 19:55:57 +0000 Subject: Fix configure to save LFLAGS, and also set proper defaults for all sensible OSes --- configure | 4 +++- util-src/Makefile | 2 +- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/configure b/configure index 5de9f67a..8eb7b367 100755 --- a/configure +++ b/configure @@ -13,7 +13,8 @@ LUA_LIBDIR="/usr/lib" IDN_LIB=idn OPENSSL_LIB=crypto -CFLAGS="-shared -fPIC" +CFLAGS="-fPIC" +LFLAGS="-shared" # Help @@ -277,6 +278,7 @@ REQUIRE_CONFIG=$REQUIRE_CONFIG IDN_LIB=$IDN_LIB OPENSSL_LIB=$OPENSSL_LIB CFLAGS=$CFLAGS +LFLAGS=$LFLAGS EOF diff --git a/util-src/Makefile b/util-src/Makefile index 5dcd65d2..a325a0d6 100644 --- a/util-src/Makefile +++ b/util-src/Makefile @@ -28,5 +28,5 @@ encodings.so: encodings.o hashes.o: hashes.c gcc $(CFLAGS) -I$(LUA_INCDIR) -c -o hashes.o hashes.c hashes.so: hashes.o - export MACOSX_DEPLOYMENT_TARGET="10.3"; gcc $(LFLAGS) -o hashes.so hashes.o -L/usr/local/lib -lcrypto -lssl + export MACOSX_DEPLOYMENT_TARGET="10.3"; gcc $(CFLAGS) -o hashes.so hashes.o -L/usr/local/lib -lcrypto -lssl -- cgit v1.2.3 From d1d7509f315717e7963740b8ebbc6a376a3a02ec Mon Sep 17 00:00:00 2001 From: Matthew Wild Date: Wed, 3 Dec 2008 20:00:17 +0000 Subject: Fix Makefile to link with Lua again --- util-src/Makefile | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/util-src/Makefile b/util-src/Makefile index a325a0d6..4aedec40 100644 --- a/util-src/Makefile +++ b/util-src/Makefile @@ -22,11 +22,11 @@ clean: encodings.o: encodings.c gcc $(CFLAGS) -I$(LUA_INCDIR) -c -o encodings.o encodings.c encodings.so: encodings.o - export MACOSX_DEPLOYMENT_TARGET="10.3"; gcc $(LFLAGS) -o encodings.so encodings.o -L/usr/local/lib -lcrypto -lidn + export MACOSX_DEPLOYMENT_TARGET="10.3"; gcc $(LFLAGS) -o encodings.so encodings.o -L/usr/local/lib -llua$(LUA_SUFFIX) -lcrypto -lidn hashes.o: hashes.c gcc $(CFLAGS) -I$(LUA_INCDIR) -c -o hashes.o hashes.c hashes.so: hashes.o - export MACOSX_DEPLOYMENT_TARGET="10.3"; gcc $(CFLAGS) -o hashes.so hashes.o -L/usr/local/lib -lcrypto -lssl + export MACOSX_DEPLOYMENT_TARGET="10.3"; gcc $(LFLAGS) -o hashes.so hashes.o -L/usr/local/lib -llua$(LUA_SUFFIX) -lcrypto -lssl -- cgit v1.2.3 -- cgit v1.2.3