diff --git a/config.h.in b/config.h.in index f0ff231..08e3146 100644 --- a/config.h.in +++ b/config.h.in @@ -51,6 +51,9 @@ /* Define to 1 if you have the header file. */ #undef HAVE_GETOPT_H +/* Use GTK3 */ +#undef HAVE_GTK3 + /* Define to 1 if you have the `inet_ntoa' function. */ #undef HAVE_INET_NTOA diff --git a/configure.ac b/configure.ac index ff8c174..5c7de3a 100644 --- a/configure.ac +++ b/configure.ac @@ -2,7 +2,7 @@ # Process this file with autoconf to produce a configure script. AC_PREREQ([2.69]) -AC_INIT([scopedesign], [0.2.2], [tbowers@email.arizona.edu]) +AC_INIT([scopedesign], [0.2.3], [tbowers@email.arizona.edu]) AM_INIT_AUTOMAKE AC_CONFIG_SRCDIR([src/main.c]) AC_CONFIG_HEADERS([config.h]) @@ -26,8 +26,9 @@ AC_PROG_LN_S AC_PROG_MAKE_SET AC_PROG_RANLIB dnl Needed by ARGTABLE, XPA -PKG_CHECK_MODULES([GTK], [gtk+-3.0]) - +PKG_CHECK_MODULES([GTK], [gtk+-3.0], + [AC_DEFINE([HAVE_GTK3], [1], [Use GTK3])], + [AC_DEFINE([HAVE_GTK3], [0], [Use GTK3])] ) # Checks for header files. diff --git a/src/main.c b/src/main.c index 65a97ea..269ddac 100644 --- a/src/main.c +++ b/src/main.c @@ -102,7 +102,9 @@ int main(int argc, char *argv[]) /* Display a splash screen! */ display_splash(0); +#if HAVE_GTK3 ui_example_window(); +#endif /* Initialize N_RAYS */ init_set_nrays(); diff --git a/src/ui.c b/src/ui.c index 2fd0829..2e91df4 100644 --- a/src/ui.c +++ b/src/ui.c @@ -27,6 +27,8 @@ #include "sd_defs.h" // Main Package Header #undef wombat +#if HAVE_GTK3 + /* Include packages */ #include @@ -77,3 +79,5 @@ int ui_example_window (){ return status; } + +#endif