stubs.c
1 #include <CoreFoundation/CoreFoundation.h> 2 #include <stdio.h> 3 #include <SystemConfiguration/SystemConfiguration.h> 4 5 #define STUB() printf("STUB %s\n", __func__) 6 7 const CFStringRef kSCDynamicStoreDomainState = CFSTR("State:"); 8 const CFStringRef kSCEntNetIPv4 = CFSTR("IPv4"); 9 const CFStringRef kSCEntNetIPv6 = CFSTR("IPv6"); 10 const CFStringRef kSCPropNetIPv4Router = CFSTR("Router"); 11 const CFStringRef kSCPropNetIPv6Router = CFSTR("Router"); /* Yes, they are the same */ 12 const CFStringRef kSCCompSystem = CFSTR("System"); 13 14 const CFStringRef kSCConsoleSessionUserName = CFSTR("kCGSSessionUserNameKey"); /* value is CFString */ 15 const CFStringRef kSCConsoleSessionUID = CFSTR("kCGSSessionUserIDKey"); /* value is CFNumber (a uid_t) */ 16 const CFStringRef kSCConsoleSessionConsoleSet = CFSTR("kCGSSessionConsoleSetKey"); /* value is CFNumber */ 17 const CFStringRef kSCConsoleSessionOnConsole = CFSTR("kCGSSessionOnConsoleKey"); /* value is CFBoolean */ 18 const CFStringRef kSCConsoleSessionLoginDone = CFSTR("kCGSessionLoginDoneKey"); /* value is CFBoolean */ 19 const CFStringRef kSCConsoleSessionID = CFSTR("kCGSSessionIDKey"); /* value is CFNumber */ 20 const CFStringRef kSCConsoleSessionSystemSafeBoot = CFSTR("kCGSSessionSystemSafeBoot"); /* value is CFBoolean */ 21 const CFStringRef kSCConsoleSessionLoginwindowSafeLogin = CFSTR("kCGSSessionLoginwindowSafeLogin"); /* value is CFBoolean */ 22 23 const CFStringRef kSCCompAnyRegex = CFSTR("[^/]+"); 24 const CFStringRef kSCEntNetDNS = CFSTR("DNS"); 25 26 CFStringRef SCDynamicStoreKeyCreateNetworkGlobalEntity(CFAllocatorRef allocator, CFStringRef domain, CFStringRef entity) 27 { 28 STUB(); 29 return NULL; 30 } 31 32 CFPropertyListRef SCDynamicStoreCopyValue(SCDynamicStoreRef store, CFStringRef key) 33 { 34 STUB(); 35 return NULL; 36 } 37 38 SCDynamicStoreRef SCDynamicStoreCreate(CFAllocatorRef allocator, CFStringRef name, SCDynamicStoreCallBack callout, SCDynamicStoreContext *context) 39 { 40 STUB(); 41 return NULL; 42 } 43 44 CFStringRef SCDynamicStoreKeyCreate(CFAllocatorRef allocator, CFStringRef fmt, ...) 45 { 46 STUB(); 47 return NULL; 48 } 49 50 Boolean SCDynamicStoreSetDispatchQueue(SCDynamicStoreRef store, dispatch_queue_t queue) 51 { 52 STUB(); 53 return FALSE; 54 } 55 56 Boolean SCDynamicStoreSetNotificationKeys(SCDynamicStoreRef store, CFArrayRef __nullable keys, CFArrayRef __nullable patterns) { 57 STUB(); 58 return FALSE; 59 } 60 61 CFStringRef SCDynamicStoreKeyCreateComputerName(CFAllocatorRef allocator) { 62 STUB(); 63 return NULL; 64 }; 65 66 Boolean SCPreferencesSetComputerName(SCPreferencesRef prefs, CFStringRef __nullable name, CFStringEncoding nameEncoding) { 67 STUB(); 68 return FALSE; 69 }; 70 71 Boolean SCPreferencesSetLocalHostName(SCPreferencesRef prefs, CFStringRef __nullable name) { 72 STUB(); 73 return FALSE; 74 }; 75 76 CFStringRef SCDynamicStoreKeyCreateHostNames(CFAllocatorRef allocator) { 77 STUB(); 78 return NULL; 79 }; 80 81 CFStringRef SCDynamicStoreKeyCreateNetworkInterfaceEntity(CFAllocatorRef allocator, CFStringRef domain, CFStringRef ifname, CFStringRef entity) { 82 STUB(); 83 return NULL; 84 };