Update LoopbackFS-ObjC for macFUSE 5
This commit is contained in:
parent
7324f50a65
commit
b0fd1fed0d
|
|
@ -205,7 +205,6 @@
|
|||
"$(inherited)",
|
||||
"@executable_path/../Frameworks",
|
||||
);
|
||||
MACOSX_DEPLOYMENT_TARGET = "$(RECOMMENDED_MACOSX_DEPLOYMENT_TARGET)";
|
||||
PRODUCT_BUNDLE_IDENTIFIER = "io.macfuse.demo.loopbackfs-objc";
|
||||
PRODUCT_NAME = LoopbackFS;
|
||||
PROVISIONING_PROFILE_SPECIFIER = "";
|
||||
|
|
@ -232,7 +231,6 @@
|
|||
"$(inherited)",
|
||||
"@executable_path/../Frameworks",
|
||||
);
|
||||
MACOSX_DEPLOYMENT_TARGET = "$(RECOMMENDED_MACOSX_DEPLOYMENT_TARGET)";
|
||||
PRODUCT_BUNDLE_IDENTIFIER = "io.macfuse.demo.loopbackfs-objc";
|
||||
PRODUCT_NAME = LoopbackFS;
|
||||
PROVISIONING_PROFILE_SPECIFIER = "";
|
||||
|
|
@ -289,6 +287,7 @@
|
|||
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
|
||||
GCC_WARN_UNUSED_FUNCTION = YES;
|
||||
GCC_WARN_UNUSED_VARIABLE = YES;
|
||||
MACOSX_DEPLOYMENT_TARGET = 10.15;
|
||||
MTL_ENABLE_DEBUG_INFO = YES;
|
||||
ONLY_ACTIVE_ARCH = YES;
|
||||
OTHER_CODE_SIGN_FLAGS = "--timestamp";
|
||||
|
|
@ -340,6 +339,7 @@
|
|||
GCC_WARN_UNINITIALIZED_AUTOS = YES_AGGRESSIVE;
|
||||
GCC_WARN_UNUSED_FUNCTION = YES;
|
||||
GCC_WARN_UNUSED_VARIABLE = YES;
|
||||
MACOSX_DEPLOYMENT_TARGET = 10.15;
|
||||
MTL_ENABLE_DEBUG_INFO = NO;
|
||||
OTHER_CODE_SIGN_FLAGS = "--timestamp";
|
||||
SDKROOT = macosx;
|
||||
|
|
|
|||
|
|
@ -43,7 +43,7 @@ static NSString *LoopbackMountPath = @"/Volumes/loop";
|
|||
[alert setMessageText:@"Mount Failed"];
|
||||
[alert setInformativeText:[error localizedDescription] ?: @"Unknown error"];
|
||||
[alert runModal];
|
||||
|
||||
|
||||
[[NSApplication sharedApplication] terminate:nil];
|
||||
});
|
||||
}
|
||||
|
|
|
|||
|
|
@ -294,9 +294,29 @@
|
|||
|
||||
#pragma mark Directory Contents
|
||||
|
||||
- (NSArray *)contentsOfDirectoryAtPath:(NSString *)path error:(NSError **)error {
|
||||
- (NSArray<GMDirectoryEntry *> *)contentsOfDirectoryAtPath:(NSString *)path
|
||||
includingAttributesForKeys:(NSArray<NSString *> *)keys
|
||||
error:(NSError * _Nullable *)error {
|
||||
NSString *p = [rootPath_ stringByAppendingString:path];
|
||||
return [[NSFileManager defaultManager] contentsOfDirectoryAtPath:p error:error];
|
||||
NSArray<NSString *> *contents =
|
||||
[[NSFileManager defaultManager] contentsOfDirectoryAtPath:p error:error];
|
||||
if (!contents) {
|
||||
return nil;
|
||||
}
|
||||
|
||||
NSMutableArray *entries = [NSMutableArray array];
|
||||
for (NSString *n in contents) {
|
||||
NSDictionary *d =
|
||||
[[NSFileManager defaultManager] attributesOfItemAtPath:[p stringByAppendingPathComponent:n]
|
||||
error:nil];
|
||||
if (!d) {
|
||||
continue;
|
||||
}
|
||||
|
||||
GMDirectoryEntry *entry = [GMDirectoryEntry directoryEntryWithName:n attributes:d];
|
||||
[entries addObject:entry];
|
||||
}
|
||||
return entries;
|
||||
}
|
||||
|
||||
#pragma mark Getting and Setting Attributes
|
||||
|
|
|
|||
Loading…
Reference in New Issue