Add some #ifdefs for future Apple support if needed

https://github.com/Hamlib/Hamlib/issues/985
pull/1091/head
Mike Black W9MDB 2022-07-15 17:43:23 -05:00
rodzic 8be68aacff
commit 4d41dd140f
1 zmienionych plików z 13 dodań i 0 usunięć

Wyświetl plik

@ -986,6 +986,19 @@ HAMLIB_EXPORT(int) rig_settings_get_path(char *path, int pathlen)
return -RIG_EINTERNAL;
}
#ifdef APPLE
//#include "TargetConditionals.h"
#ifdef TARGET_OS_IPHONE
// iOS
#elif TARGET_IPHONE_SIMULATOR
// iOS Simulator
#elif TARGET_OS_MAC
// Other kinds of Mac OS
#else
// Unsupported platform
#endif
#endif
char *xdgpath = getenv("XDG_CONFIG_HOME");
char *home = getenv("HOME");
snprintf(path, pathlen, "%s/.config", home);