From ce4f3495924e54a55d308438bf120855417d9e8a Mon Sep 17 00:00:00 2001 From: "Nicolas \"Pixel\" Noble" Date: Mon, 7 Dec 2009 01:30:16 +0100 Subject: Properly building for darwin9 now, and upgrading to LuaJIT 2.0.0-beta2 --- Makefile | 26 +++++++++++++++++--------- 1 file changed, 17 insertions(+), 9 deletions(-) (limited to 'Makefile') diff --git a/Makefile b/Makefile index 249ad13..419e214 100644 --- a/Makefile +++ b/Makefile @@ -8,7 +8,10 @@ GL_GLUE=gl-glue.s CC = gcc CXX = g++ LD = g++ +AS = as +LUAJIT = ../LuaJIT/src/libluajit.a ifeq ($(SYSTEM),Darwin) +LIPO = lipo ARCH_FLAGS=-arch i386 LDFLAGS_MESA=-all_load ../Mesa-7.4.4/lib/libGLU.a ../Mesa-7.4.4/lib/libmesa.a ../Mesa-7.4.4/lib/libglapi.a ../Mesa-7.4.4/lib/osmesa.o CPPFLAGS_READLINE= @@ -23,11 +26,15 @@ LDFLAGS_GL = -L/usr/X11/lib -lGLU -lGL -X11 -dylib_file \ GL_GLUE=gl-glue-fat.o STRIP = strip -x ifeq ($(TRUESYSTEM),Linux) -CC = i686-apple-darwin9-gcc-4.0.1 -CXX = i686-apple-darwin9-g++-4.0.1 -LD = i686-apple-darwin9-ld -arch i386 +CC = i686-apple-darwin9-gcc +CXX = i686-apple-darwin9-g++ +LD = i686-apple-darwin9-g++ -arch i386 STRIP = i686-apple-darwin9-strip -x +AS = i686-apple-darwin9-as +LIPO = i686-apple-darwin9-lipo ARCH_FLAGS = +LDFLAGS_MESA = -all_load ../Mesa-7.4.4-darwin9/lib/libGLU.a ../Mesa-7.4.4-darwin9/lib/libOSMesa.a +LUAJIT = ../LuaJIT-darwin9/src/libluajit.a endif else ARCH_FLAGS=-march=i686 -m32 @@ -77,7 +84,8 @@ CPPFLAGS += $(CPPFLAGS_NO_ARCH) $(ARCH_FLAGS) BASIC_LDFLAGS += $(ARCH_FLAGS) $(LIBS) -LDFLAGS += $(BASIC_LDFLAGS) $(LDFLAGS_READLINE) -L/usr/lib/oracle/11.1.0.1/client/lib ../LuaJIT/src/luajit.a +LDFLAGS += $(BASIC_LDFLAGS) $(LDFLAGS_READLINE) -L/usr/lib/oracle/11.1.0.1/client/lib $(LUAJIT) + vpath %.c ../Baltisot/lib:../Baltisot/src:../mogltk/lib:../tinyxml:../lua-modules/src:src vpath %.cc ../Baltisot/lib:../Baltisot/src:../mogltk/lib:../tinyxml:../lua-modules/src:src:../lua-modules-cd-tool/src:../lua-modules-iup/src @@ -273,19 +281,19 @@ gl-glue.s: src/generate-gl-glue.sh > gl-glue.s gl-glue-i386.o: gl-glue-i386.s - as -arch i386 $< -o $@ + $(AS) -arch i386 $< -o $@ gl-glue-x86_64.o: gl-glue-x86_64.s - as -arch x86_64 $< -o $@ + $(AS) -arch x86_64 $< -o $@ gl-glue-ppc.o: gl-glue-ppc.s - as -arch ppc $< -o $@ + $(AS) -arch ppc $< -o $@ gl-glue-ppc64.o: gl-glue-ppc64.s - as -arch ppc64 $< -o $@ + $(AS) -arch ppc64 $< -o $@ gl-glue-fat.o: gl-glue-i386.o gl-glue-x86_64.o gl-glue-ppc.o gl-glue-ppc64.o - lipo -create $^ -output $@ + $(LIPO) -create $^ -output $@ -include $(ALL_DEPS) -- cgit v1.2.3