]> git.saurik.com Git - cycript.git/commitdiff
Guarantee all the older Cydget bridge definitions. v0.9.590
authorJay Freeman (saurik) <saurik@saurik.com>
Mon, 11 Jan 2016 20:41:40 +0000 (12:41 -0800)
committerJay Freeman (saurik) <saurik@saurik.com>
Mon, 11 Jan 2016 20:41:40 +0000 (12:41 -0800)
Analysis.cpp
Analyze.cpp
Bridge.old [new file with mode: 0644]
Makefile.am
Makefile.in

index 23fc5a3cc70553b89342ca5ab2fec2b44e173b53..7da64f308fb330a2e60220daac97a5a8673504d3 100644 (file)
@@ -64,6 +64,7 @@
 #include <AddressBook/AddressBook.h>
 #include <CoreData/CoreData.h>
 #include <CoreLocation/CoreLocation.h>
+#include <MapKit/MapKit.h>
 #include <Security/Security.h>
 
 #include <dispatch/dispatch.h>
@@ -74,6 +75,7 @@
 
 #include <mach-o/dyld.h>
 #include <mach-o/dyld_images.h>
+#include <mach-o/nlist.h>
 
 #if TARGET_OS_IPHONE
 #include <UIKit/UIKit.h>
index 5bf49148fcb0c6f4504fe95483c1f078a3144c15..9a056e5993ae68b7571fa64f2b23af3145a577ae 100644 (file)
@@ -502,6 +502,10 @@ static CXChildVisitResult CYChildVisit(CXCursor cursor, CXCursor parent, CXClien
         } break;
 
         case CXCursor_EnumDecl: {
+            // the enum constants are implemented separately *also*
+            // XXX: maybe move output logic to function we can call
+            result = CXChildVisit_Recurse;
+
             if (spelling[0] == '\0')
                 goto skip;
             // XXX: this was blindly copied from StructDecl
@@ -520,10 +524,6 @@ static CXChildVisitResult CYChildVisit(CXCursor cursor, CXCursor parent, CXClien
             value << ".withName(\"" << name << "\")";
             name = "$cye" + name;
             flags = CYBridgeType;
-
-            // the enum constants are implemented separately *also*
-            // XXX: maybe move output logic to function we can call
-            result = CXChildVisit_Recurse;
         } break;
 
         case CXCursor_MacroDefinition: {
diff --git a/Bridge.old b/Bridge.old
new file mode 100644 (file)
index 0000000..7a3d258
--- /dev/null
@@ -0,0 +1,92 @@
+CTCallRef|0"(typedef id)"
+UIAbbreviatedMonthDayFormat|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UIAbbreviatedMonthDayFormat'))"
+UIAbbreviatedWeekdayDateFormat|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UIAbbreviatedWeekdayDateFormat'))"
+UIAbbreviatedWeekdayFormat|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UIAbbreviatedWeekdayFormat'))"
+UIAbbreviatedWeekdayMonthDayFormat|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UIAbbreviatedWeekdayMonthDayFormat'))"
+UIAbbreviatedWeekdayMonthDayMinutelessFormat|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UIAbbreviatedWeekdayMonthDayMinutelessFormat'))"
+UIAbbreviatedWeekdayMonthDayTimeFormat|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UIAbbreviatedWeekdayMonthDayTimeFormat'))"
+UIDatePickerDayFormat|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UIDatePickerDayFormat'))"
+UIDatePickerMonthFormat|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UIDatePickerMonthFormat'))"
+UIDatePickerYearFormat|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UIDatePickerYearFormat'))"
+UIHourFormat|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UIHourFormat'))"
+UIMinutelessTimeFormat|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UIMinutelessTimeFormat'))"
+UIMonthYearFormat|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UIMonthYearFormat'))"
+UINoAMPMTimeFormat|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UINoAMPMTimeFormat'))"
+UIShortMonthDayFormat|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UIShortMonthDayFormat'))"
+UIWeekdayAbbreviatedDateFormat|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UIWeekdayAbbreviatedDateFormat'))"
+UIWeekdayAbbreviatedNoYearDateFormat|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UIWeekdayAbbreviatedNoYearDateFormat'))"
+UIWeekdayFormat|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UIWeekdayFormat'))"
+UIWeekdayNoYearDateFormat|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UIWeekdayNoYearDateFormat'))"
+kUIButtonBarButtonAction|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'kUIButtonBarButtonAction'))"
+kUIButtonBarButtonInfo|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'kUIButtonBarButtonInfo'))"
+kUIButtonBarButtonInfoOffset|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'kUIButtonBarButtonInfoOffset'))"
+kUIButtonBarButtonSelectedInfo|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'kUIButtonBarButtonSelectedInfo'))"
+kUIButtonBarButtonSizeToFit|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'kUIButtonBarButtonSizeToFit'))"
+kUIButtonBarButtonStyle|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'kUIButtonBarButtonStyle'))"
+kUIButtonBarButtonTag|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'kUIButtonBarButtonTag'))"
+kUIButtonBarButtonTarget|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'kUIButtonBarButtonTarget'))"
+kUIButtonBarButtonTitle|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'kUIButtonBarButtonTitle'))"
+kUIButtonBarButtonTitleVerticalHeight|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'kUIButtonBarButtonTitleVerticalHeight'))"
+kUIButtonBarButtonTitleWidth|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'kUIButtonBarButtonTitleWidth'))"
+kUIButtonBarButtonType|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'kUIButtonBarButtonType'))"
+UIKeyboardRequiresInternationalKey|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UIKeyboardRequiresInternationalKey'))"
+UIKeyboardCandidateCorrectionDidChangeNotification|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UIKeyboardCandidateCorrectionDidChangeNotification'))"
+UIKeyboardCurrentInputModeDidChangeNotification|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UIKeyboardCurrentInputModeDidChangeNotification'))"
+UIKeyboardDefaultsDidChangeNotification|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UIKeyboardDefaultsDidChangeNotification'))"
+UIKeyboardEmptyDelegateNotification|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UIKeyboardEmptyDelegateNotification'))"
+UIWebViewDidReceiveMessageNotification|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UIWebViewDidReceiveMessageNotification'))"
+UIWebViewDidClearMessagesNotification|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'UIWebViewDidClearMessagesNotification'))"
+CFGregorianCalendar|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'CFGregorianCalendar'))"
+kCFLocaleCurrentLocaleDidChangeNotificatio|0"*(typedef id *)(dlsym(RTLD_DEFAULT, 'kCFLocaleCurrentLocaleDidChangeNotificatio'))"
+UIEdgeInsetsMake|0"*(typedef UIEdgeInsets(*)(float, float, float, float))(dlsym(RTLD_DEFAULT, 'UIEdgeInsetsMake'))"
+UIEdgeInsetsEqualToEdgeInsets|0"*(typedef bool(*)(UIEdgeInsets, UIEdgeInsets))(dlsym(RTLD_DEFAULT, 'UIEdgeInsetsEqualToEdgeInsets'))"
+UIEdgeInsetsInsetRect|0"*(typedef CGRect (*)(CGRect,UIEdgeInsets))(dlsym(RTLD_DEFAULT, 'UIEdgeInsetsInsetRect'))"
+UIGetScreenImage|0"*(typedef id (*)())(dlsym(RTLD_DEFAULT, 'UIGetScreenImage'))"
+UIDateFormatStringForFormatType|0"*(typedef id (*)(id))(dlsym(RTLD_DEFAULT, 'UIDateFormatStringForFormatType'))"
+UIApplicationUseLegacyEvents|0"*(typedef void (*)(bool))(dlsym(RTLD_DEFAULT, 'UIApplicationUseLegacyEvents'))"
+UIKeyboardDisableAutomaticAppearance|0"*(typedef void (*)())(dlsym(RTLD_DEFAULT, 'UIKeyboardDisableAutomaticAppearance'))"
+UIKeyboardEnableAutomaticAppearance|0"*(typedef void (*)())(dlsym(RTLD_DEFAULT, 'UIKeyboardEnableAutomaticAppearance'))"
+UIKeyboardInputModeUsesKBStar|0"*(typedef bool (*)(id))(dlsym(RTLD_DEFAULT, 'UIKeyboardInputModeUsesKBStar'))"
+_UIImageWithName|0"*(typedef id (*)(id))(dlsym(RTLD_DEFAULT, '_UIImageWithName'))"
+UIFormattedPhoneNumberFromString|0"*(typedef id (*)(id))(dlsym(RTLD_DEFAULT, 'UIFormattedPhoneNumberFromString'))"
+UIUnformattedPhoneNumberFromString|0"*(typedef id (*)(id))(dlsym(RTLD_DEFAULT, 'UIUnformattedPhoneNumberFromString'))"
+SecCertificateGetItem|0"*(typedef id(*)(id, id*))(dlsym(RTLD_DEFAULT, 'SecCertificateGetItem'))"
+CPPhoneNumberCopyNetworkCountryCode|0"*(typedef id (*)())(dlsym(RTLD_DEFAULT, 'CPPhoneNumberCopyNetworkCountryCode'))"
+ABCGetSharedAddressBook|0"*(typedef id (*)())(dlsym(RTLD_DEFAULT, 'ABCGetSharedAddressBook'))"
+ABCFindPersonMatchingPhoneNumberWithCountry|0"*(typedef id(id, id, id, int *, int *))(dlsym(RTLD_DEFAULT, 'ABCFindPersonMatchingPhoneNumberWithCountry'))"
+ABCRecordCopyCompositeName|0"*(typedef id (*)(id))(dlsym(RTLD_DEFAULT, 'ABCRecordCopyCompositeName'))"
+ABCFindPersonMatchingPhoneNumber|0"*(typedef id(*)(id, id, int*, int*))(dlsym(RTLD_DEFAULT, 'ABCFindPersonMatchingPhoneNumber'))"
+ABCCopyLocalizedPropertyOrLabel|0"*(typedef id (*)(int))(dlsym(RTLD_DEFAULT, 'ABCCopyLocalizedPropertyOrLabel'))"
+CalDatabaseCopyEventOccurrencesInDateRange|0"*(typedef CFArrayRef(*)(CalDatabase*,CalFilter*,CFGregorianDate,CFGregorianDate,CFTimeZoneRef))(dlsym(RTLD_DEFAULT, 'CalDatabaseCopyEventOccurrencesInDateRange'))"
+CalFilterCreateWithDatabase|0"*(typedef struct CalFilter *(*)(CalDatabase *))(dlsym(RTLD_DEFAULT, 'CalFilterCreateWithDatabase'))"
+CalEventOccurrenceGetEvent|0"*(typedef id (*)(id))(dlsym(RTLD_DEFAULT, 'CalEventOccurrenceGetEvent'))"
+CalEventCopySummary|0"*(typedef id (*)(id))(dlsym(RTLD_DEFAULT, 'CalEventCopySummary'))"
+CalEventIsAllDay|0"*(typedef bool (*)(id))(dlsym(RTLD_DEFAULT, 'CalEventIsAllDay'))"
+CalEventOccurrenceGetDate|0"*(typedef unsigned int (*)(id))(dlsym(RTLD_DEFAULT, 'CalEventOccurrenceGetDate'))"
+CFRangeMake|0"*(typedef CFRange (*)(CFIndex,CFIndex))(dlsym(RTLD_DEFAULT, 'CFRangeMake'))"
+CTCallCopyAddress|0"*(typedef CFStringRef *(*)(CFAllocatorRef,CTCallRef))(dlsym(RTLD_DEFAULT, 'CTCallCopyAddress'))"
+CTCallCopyAllMissedCallsAfterRowID|0"*(typedef CFArrayRef (*)(CFAllocatorRef, long))(dlsym(RTLD_DEFAULT, 'CTCallCopyAllMissedCallsAfterRowID'))"
+CTCallCopyAllMissedCallsSince|0"*(typedef CFArrayRef(*)(CFAllocatorRef, CFDateRef))(dlsym(RTLD_DEFAULT, 'CTCallCopyAllMissedCallsSince'))"
+CTCallGetGetRowIDOfLastInsert|0"*(typedef int (*)())(dlsym(RTLD_DEFAULT, 'CTCallGetGetRowIDOfLastInsert'))"
+CTCallGetID|0"*(typedef long (*)(CTCallRef))(dlsym(RTLD_DEFAULT, 'CTCallGetID'))"
+CTCallGetStartTime|0"*(typedef bool(*)(CTCallRef, double *))(dlsym(RTLD_DEFAULT, 'CTCallGetStartTime'))"
+CTCallGetTypeID|0"*(typedef CFTypeID (*)())(dlsym(RTLD_DEFAULT, 'CTCallGetTypeID'))"
+WiFiNetworkComparePriority|0"*(typedef bool (*)(id, id))(dlsym(RTLD_DEFAULT, 'WiFiNetworkComparePriority'))"
+WiFiNetworkCopyPassword|0"*(typedef id (*)(id))(dlsym(RTLD_DEFAULT, 'WiFiNetworkCopyPassword'))"
+WiFiNetworkGetAssociationDate|0"*(typedef id (*)(id))(dlsym(RTLD_DEFAULT, 'WiFiNetworkGetAssociationDate'))"
+WiFiNetworkGetSSID|0"*(typedef id (*)(id))(dlsym(RTLD_DEFAULT, 'WiFiNetworkGetSSID'))"
+WiFiNetworkGetSSIDData|0"*(typedef id (*)(id))(dlsym(RTLD_DEFAULT, 'WiFiNetworkGetSSIDData'))"
+WiFiNetworkGetTypeID|0"*(typedef CFTypeID (*)())(dlsym(RTLD_DEFAULT, 'WiFiNetworkGetTypeID'))"
+WiFiNetworkIsEAP|0"*(typedef bool (*)(id))(dlsym(RTLD_DEFAULT, 'WiFiNetworkIsEAP'))"
+WiFiNetworkIsEnabled|0"*(typedef bool (*)(id))(dlsym(RTLD_DEFAULT, 'WiFiNetworkIsEnabled'))"
+WiFiNetworkIsHidden|0"*(typedef bool (*)(id))(dlsym(RTLD_DEFAULT, 'WiFiNetworkIsHidden'))"
+WiFiNetworkIsHiddenSSID|0"*(typedef bool (*)(id))(dlsym(RTLD_DEFAULT, 'WiFiNetworkIsHiddenSSID'))"
+WiFiNetworkIsWEP|0"*(typedef bool (*)(id))(dlsym(RTLD_DEFAULT, 'WiFiNetworkIsWEP'))"
+WiFiNetworkIsWPA|0"*(typedef bool (*)(id))(dlsym(RTLD_DEFAULT, 'WiFiNetworkIsWPA'))"
+WiFiNetworkRemovePassword|0"*(typedef void (*)(id))(dlsym(RTLD_DEFAULT, 'WiFiNetworkRemovePassword'))"
+WiFiNetworkRequiresIdentity|0"*(typedef bool (*)(id))(dlsym(RTLD_DEFAULT, 'WiFiNetworkRequiresIdentity'))"
+WiFiNetworkRequiresOneTimePassword|0"*(typedef bool (*)(id))(dlsym(RTLD_DEFAULT, 'WiFiNetworkRequiresOneTimePassword'))"
+WiFiNetworkRequiresPassword|0"*(typedef bool (*)(id))(dlsym(RTLD_DEFAULT, 'WiFiNetworkRequiresPassword'))"
+WiFiNetworkRequiresUsername|0"*(typedef bool (*)(id))(dlsym(RTLD_DEFAULT, 'WiFiNetworkRequiresUsername'))"
+WiFiNetworkSetAssociationDate|0"*(typedef void (*)(id, id))(dlsym(RTLD_DEFAULT, 'WiFiNetworkSetAssociationDate'))"
+WiFiNetworkSetPassword|0"*(typedef void (*)(id, id))(dlsym(RTLD_DEFAULT, 'WiFiNetworkSetPassword'))"
index 93a65603fb773ae7b216e11f146a8be321ba7adc..341f993d3c7f853843828da48279333dbd820197 100644 (file)
@@ -102,8 +102,9 @@ Analyze: Analyze.cpp Error.cpp Output.cpp Replace.cpp Syntax.cpp
        $(CXX_FOR_BUILD) $(CXXFLAGS_FOR_BUILD) -std=c++11 $(LDFLAGS_FOR_BUILD) $(CY_LANGFLAGS) -I$(srcdir)/extra -o $@ $^ $(CY_LIBCLANG) -Wno-bitwise-op-parentheses -Wno-dangling-else -Wno-logical-op-parentheses
 
 CLEANFILES += Bridge.def
-Bridge.def: Analysis.cpp Analyze
+Bridge.def: Analysis.cpp Analyze Bridge.old
        ./Analyze $< $(OBJCXX) $(CPPFLAGS) $(AM_OBJCXXFLAGS) $(OBJCXXFLAGS) $(CY_LANGFLAGS) $(CY_ANDFLAGS) >$@
+       cat $(srcdir)/Bridge.old >>$@
 else
 CLEANFILES += Bridge.def
 Bridge.def: Bridge.def.in
index 274ab82c45abb14122f95945f32b7ad92145d3b4..cc2f245eafa3483c57349ff8ab35e9312296ae1e 100644 (file)
@@ -1430,8 +1430,9 @@ uninstall-am: uninstall-binPROGRAMS uninstall-datDATA \
 @CY_EXECUTE_TRUE@      $(srcdir)/libcycript.py $(CY_SYSTEM) $@ $(srcdir) <$<
 @CY_EXECUTE_TRUE@@CY_PRELINK_TRUE@Analyze: Analyze.cpp Error.cpp Output.cpp Replace.cpp Syntax.cpp
 @CY_EXECUTE_TRUE@@CY_PRELINK_TRUE@     $(CXX_FOR_BUILD) $(CXXFLAGS_FOR_BUILD) -std=c++11 $(LDFLAGS_FOR_BUILD) $(CY_LANGFLAGS) -I$(srcdir)/extra -o $@ $^ $(CY_LIBCLANG) -Wno-bitwise-op-parentheses -Wno-dangling-else -Wno-logical-op-parentheses
-@CY_EXECUTE_TRUE@@CY_PRELINK_TRUE@Bridge.def: Analysis.cpp Analyze
+@CY_EXECUTE_TRUE@@CY_PRELINK_TRUE@Bridge.def: Analysis.cpp Analyze Bridge.old
 @CY_EXECUTE_TRUE@@CY_PRELINK_TRUE@     ./Analyze $< $(OBJCXX) $(CPPFLAGS) $(AM_OBJCXXFLAGS) $(OBJCXXFLAGS) $(CY_LANGFLAGS) $(CY_ANDFLAGS) >$@
+@CY_EXECUTE_TRUE@@CY_PRELINK_TRUE@     cat $(srcdir)/Bridge.old >>$@
 @CY_EXECUTE_TRUE@@CY_PRELINK_FALSE@Bridge.def: Bridge.def.in
 @CY_EXECUTE_TRUE@@CY_PRELINK_FALSE@    cat $< >$@
 @CY_JAVA_TRUE@Class/Cycript.class: Java/Cycript.java