summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--uicache.mm12
-rw-r--r--uicache.xml12
2 files changed, 21 insertions, 3 deletions
diff --git a/uicache.mm b/uicache.mm
index cbf3b8e..2eafcdd 100644
--- a/uicache.mm
+++ b/uicache.mm
@@ -86,6 +86,15 @@
int main(int argc, const char *argv[]) {
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
+ Class $LSApplicationWorkspace(objc_getClass("LSApplicationWorkspace"));
+ LSApplicationWorkspace *workspace($LSApplicationWorkspace == nil ? nil : [$LSApplicationWorkspace defaultWorkspace]);
+
+ if ([workspace respondsToSelector:@selector(_LSPrivateRebuildApplicationDatabasesForSystemApps:internal:user:)]) {
+ if (![workspace _LSPrivateRebuildApplicationDatabasesForSystemApps:YES internal:YES user:NO])
+ fprintf(stderr, "failed to rebuild application databases");
+ return 0;
+ }
+
bool respring(false);
NSString *home(NSHomeDirectory());
@@ -100,9 +109,6 @@ int main(int argc, const char *argv[]) {
system("killall lsd");
- Class $LSApplicationWorkspace(objc_getClass("LSApplicationWorkspace"));
- LSApplicationWorkspace *workspace($LSApplicationWorkspace == nil ? nil : [$LSApplicationWorkspace defaultWorkspace]);
-
if ([workspace respondsToSelector:@selector(invalidateIconCache:)])
while (![workspace invalidateIconCache:nil])
sleep(1);
diff --git a/uicache.xml b/uicache.xml
index c91640f..9a34f2b 100644
--- a/uicache.xml
+++ b/uicache.xml
@@ -5,5 +5,17 @@
<array>
<string>InstallForLaunchServices</string>
</array>
+
+ <key>com.apple.lsapplicationworkspace.rebuildappdatabases</key>
+ <true/>
+
+ <key>com.apple.private.MobileContainerManager.allowed</key>
+ <true/>
+
+ <key>com.apple.private.kernel.override-cpumon</key>
+ <true/>
+
+ <key>com.apple.vpn.installer_events</key>
+ <true/>
</dict>
</plist>