#include "gnunet_configuration_lib.h"
#include "gnunet_disk_lib.h"
#include "gnunet_os_lib.h"
-#if OSX
+#if DARWIN
#include <mach-o/ldsyms.h>
#include <mach-o/dyld.h>
#endif
}
#endif
-#if OSX
+#if DARWIN
typedef int (*MyNSGetExecutablePathProto) (char *buf, size_t * bufsize);
static char *
if (ret != NULL)
return ret;
#endif
-#if OSX
+#if DARWIN
ret = get_path_from_dyld_image ();
if (ret != NULL)
return ret;
return ret;
/* other attempts here */
GNUNET_log (GNUNET_ERROR_TYPE_ERROR,
- _("Could not determine installation path for GNUnet. Set `%s' environment variable.\n"),
- "GNUNET_PREFIX");
+ _
+ ("Could not determine installation path for GNUnet. Set `%s' environment variable.\n"),
+ "GNUNET_PREFIX");
return NULL;
}
{
char *ret;
+ ret = NULL;
#if LINUX
ret = get_path_from_proc_exe ();
if (ret != NULL)
if (ret != NULL)
return ret;
#endif
-#if OSX
+#if DARWIN
ret = get_path_from_NSGetExecutablePath ();
if (ret != NULL)
return ret;
#endif
/* other attempts here */
- return NULL;
+ return ret;
}
#ifdef __cplusplus
}
#endif
-/* end of installpath.c */
+/* end of os_installation.c */