X-Git-Url: https://git.saurik.com/cydia.git/blobdiff_plain/9b3dc53f05783db3b43b85063b9f8b34e288a730..0e2693a0132225125c4efce647d526af614104db:/makefile diff --git a/makefile b/makefile index 5868accc..d9326179 100644 --- a/makefile +++ b/makefile @@ -1,9 +1,11 @@ -ifeq (o,O) -ios := 2.0 -gcc := 4.0 -else +sdks := /Developer/Platforms/iPhoneOS.platform/Developer/SDKs + +ifeq ($(findstring iPhoneOS2.0.sdk,$(wildcard $(sdks)/iPhoneOS*.sdk)),) ios := 3.2 gcc := 4.2 +else +ios := 2.0 +gcc := 4.0 endif flags := @@ -12,7 +14,7 @@ link := #dpkg := /Library/Cydia/bin/dpkg-deb -Zlzma dpkg := dpkg-deb -sdk := /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS$(ios).sdk +sdk := $(sdks)/iPhoneOS$(ios).sdk flags += -F$(sdk)/System/Library/PrivateFrameworks flags += -I. -isystem sysroot/usr/include -Lsysroot/usr/lib @@ -56,8 +58,8 @@ clean: %.o: %.c $(cycc) -c -o $@ -x c $< -MobileCydia: MobileCydia.mm UICaboodle/*.h UICaboodle/*.mm iPhonePrivate.h lookup3.o - $(cycc) $(filter %.mm,$^) $(filter %.o,$^) $(flags) $(link) $(uikit) +MobileCydia: MobileCydia.mm UICaboodle/*.h UICaboodle/*.mm SDURLCache/SDURLCache.h SDURLCache/SDURLCache.m iPhonePrivate.h lookup3.o Cytore.hpp + $(cycc) $(filter %.mm,$^) $(filter %.o,$^) $(foreach m,$(filter %.m,$^),-x objective-c++ $(m)) $(flags) $(link) $(uikit) ldid -Slaunch.xml $@ || { rm -f $@ && false; } CydiaAppliance: CydiaAppliance.mm