Diff

util-src/Makefile @ 534:684cd8aedc1a

Making makefile work under OS X finally. Yeah OS X's gcc is a little bit strange.
author Tobias Markmann <tm@ayena.de>
date Wed, 03 Dec 2008 20:32:03 +0100
parent 513:cadc9d6db7d8
child 536:dfe06eab47c0
line wrap: on
line diff
--- a/util-src/Makefile	Wed Dec 03 19:43:59 2008 +0100
+++ b/util-src/Makefile	Wed Dec 03 20:32:03 2008 +0100
@@ -12,16 +12,21 @@
 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