CC ?= aarch64-apple-darwin-clang
STRIP ?= aarch64-apple-darwin-strip
LDID ?= ldid
-CFLAGS ?= -arch arm64 -isysroot /home/cameron/Documents/SDK/iPhoneOS14.2.sdk -miphoneos-version-min=13.0 -Iinclude
+CFLAGS ?= -arch arm64 -isysroot /home/cameron/Documents/SDK/iPhoneOS14.2.sdk -miphoneos-version-min=13.0
INSTALL ?= install
FAKEROOT ?= fakeroot
PREFIX ?= /usr
build/snaprestore: src/snaprestore.m src/ent.xml
mkdir -p build
- $(CC) $(CFLAGS) -o build/snaprestore src/snaprestore.m -framework IOKit -framework Foundation -framework MobileCoreServices -fobjc-arc
+ $(CC) $(CFLAGS) -o build/snaprestore src/snaprestore.m -framework IOKit -framework Foundation -framework CoreServices -fobjc-arc
$(STRIP) build/snaprestore
$(LDID) -Ssrc/ent.xml build/snaprestore
+++ /dev/null
-/home/cameron/Documents/SDK/MacOSX11.0.sdk/System/Library/Frameworks/IOKit.framework/Headers
\ No newline at end of file
+++ /dev/null
-/home/cameron/Documents/SDK/MacOSX11.0.sdk/usr/include/libkern
\ No newline at end of file
#import <Foundation/Foundation.h>
#import <Foundation/NSFileManager.h>
-#import <IOKit/IOKitLib.h>
#import <sys/snapshot.h>
#import <getopt.h>
+typedef char io_string_t[512];
+typedef mach_port_t io_object_t;
+typedef io_object_t io_registry_entry_t;
+io_registry_entry_t IORegistryEntryFromPath(mach_port_t master, const io_string_t path);
+CFTypeRef IORegistryEntryCreateCFProperty(io_registry_entry_t entry, CFStringRef key, CFAllocatorRef allocator, uint32_t options);
+kern_return_t IOObjectRelease(io_object_t object);
+
@interface LSApplicationWorkspace : NSObject
+ (id)defaultWorkspace;
- (BOOL)_LSPrivateRebuildApplicationDatabasesForSystemApps:(BOOL)arg1 internal:(BOOL)arg2 user:(BOOL)arg3;