From aa3838308b22dd3940e6b18cb23224356544da92 Mon Sep 17 00:00:00 2001 From: Dirk Hohndel Date: Fri, 3 May 2013 13:13:14 -0700 Subject: Similar build fix for Mac Apparently only older Linux toolchains didn't bother to throw up with the remainders of Gtk related code. Signed-off-by: Dirk Hohndel --- macos.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'macos.c') diff --git a/macos.c b/macos.c index 38e58f54b..d28ea1dae 100644 --- a/macos.c +++ b/macos.c @@ -151,8 +151,11 @@ const char *subsurface_icon_name() { static char path[PATH_MAX]; +#if USE_GTK_UI snprintf(path, sizeof(path), "%s/%s", gtkosx_application_get_resource_path(), ICON_NAME); - +#else + /* need Qt path */ +#endif return path; } @@ -174,15 +177,18 @@ const char *subsurface_gettext_domainpath(char *argv0) { /* on a Mac we ignore the argv0 argument and instead use the resource_path * to figure out where to find the translation files */ +#if USE_GTK_UI static char buffer[PATH_MAX]; const char *resource_path = gtkosx_application_get_resource_path(); if (resource_path) { snprintf(buffer, sizeof(buffer), "%s/share/locale", resource_path); return buffer; } +#endif /* USE_GTK_UI */ return "./share/locale"; } +#if USE_GTK_UI static void show_main_window(GtkWidget *w, gpointer data) { gtk_widget_show(main_window); @@ -230,6 +236,7 @@ void subsurface_ui_setup(GtkSettings *settings, GtkWidget *menubar, gtkosx_application_ready(osx_app); } +#endif /* UES_GTK_UI */ void subsurface_command_line_init(gint *argc, gchar ***argv) { -- cgit v1.2.3-70-g09d2