1CXX = g++ 2 3SDK = /Developer/SDKs/MacOSX10.5.sdk 4SDK64 = /Developer/SDKs/MacOSX10.5.sdk 5JAVA_FRAMEWORK = $(SDK)/System/Library/Frameworks/JavaVM.framework 6JAVA_FRAMEWORK64 = $(SDK64)/System/Library/Frameworks/JavaVM.framework 7 8INCLUDES = -I $(JAVA_FRAMEWORK)/Headers/ 9INCLUDES64 = -I $(JAVA_FRAMEWORK64)/Headers/ 10 11LIBRARIES = -framework CoreAudio -framework JavaVM -framework AudioUnit -framework AudioToolbox -framework CoreServices 12 13LIBRARY = libtuxguitar-audiounit-jni.jnilib 14 15FILENAME = org_herac_tuxguitar_player_impl_midiport_audiounit_MidiReceiverJNI.cpp 16 17all: $(LIBRARY) 18 19$(LIBRARY): clean 20 g++ $(INCLUDES) -isysroot $(SDK) -arch ppc $(LIBRARIES) -msse -bundle -o ppc_$(LIBRARY) $(FILENAME) 21 g++ $(INCLUDES) -isysroot $(SDK) -arch i386 $(LIBRARIES) -msse -bundle -o intel_$(LIBRARY) $(FILENAME) 22 g++ $(INCLUDES64) -isysroot $(SDK64) -arch x86_64 $(LIBRARIES) -msse -bundle -o intel64_$(LIBRARY) $(FILENAME) 23 lipo -create ppc_$(LIBRARY) intel_$(LIBRARY) intel64_$(LIBRARY) -output $(LIBRARY) 24 25clean: 26 rm -f ppc_$(LIBRARY) intel_$(LIBRARY) intel64_$(LIBRARY) $(LIBRARY)