From 0bb9d37e2ef3fb6da06bf4630345d37504ea52f0 Mon Sep 17 00:00:00 2001 From: sam Date: Sat, 11 Oct 2008 09:10:11 +0000 Subject: [PATCH] Make the GTK# detection code more robust. git-svn-id: file:///srv/caca.zoy.org/var/lib/svn/libpipi/trunk@2912 92316355-f0b4-4df1-b90c-862c8a59935f --- ThePimp/Makefile.am | 4 +++- configure.ac | 11 +++++++---- pipi-sharp/Makefile.am | 4 ++-- 3 files changed, 12 insertions(+), 7 deletions(-) diff --git a/ThePimp/Makefile.am b/ThePimp/Makefile.am index 9749c73..77204ed 100644 --- a/ThePimp/Makefile.am +++ b/ThePimp/Makefile.am @@ -28,8 +28,10 @@ image_sources = \ images/about.svg if USE_CSHARP +if USE_GTKSHARP bin_SCRIPTS = Pimp.exe endif +endif EXTRA_DIST = $(pimp_sources) $(pimp_resources) $(image_sources) @@ -37,7 +39,7 @@ Pimp.exe: ../pipi-sharp/pipi-sharp.dll $(pimp_sources) $(pimp_resources) cp ../pipi-sharp/pipi-sharp.dll . cp ../pipi-sharp/pipi-sharp.dll.config . cp ../pipi-sharp/pipi-sharp.dll.mdb . - gmcs -debug -out:$@ -lib:./ \ + $(GMCS) -debug -out:$@ -lib:./ \ $(addprefix $(srcdir)/, $(pimp_sources)) \ $(foreach x, $(pimp_resources), \ -resource:$(srcdir)/$x,ThePimp.$(subst /,.,$x)) \ diff --git a/configure.ac b/configure.ac index 1e8b793..b4fe2b8 100644 --- a/configure.ac +++ b/configure.ac @@ -169,13 +169,16 @@ if test "${ac_cv_my_have_il}" = "no" -a "${ac_cv_my_have_ole}" = "no" -a "${ac_c AC_MSG_ERROR([[cannot find DevIL, OLE, SDL_Image, Imlib2, Cocoa, or OpenCV, please install one of them]]) fi -# Build The Pimp? +# Build pipi-sharp? AC_PATH_PROG(GMCS, gmcs, no) -PKG_CHECK_MODULES([GLADE_SHARP_20], [glade-sharp-2.0], [:]) -PKG_CHECK_MODULES([GLIB_SHARP_20], [glib-sharp-2.0], [:]) -PKG_CHECK_MODULES([GTK_SHARP_20], [gtk-sharp-2.0], [:]) AM_CONDITIONAL(USE_CSHARP, test "${gmcs}" != "no") +# Build The Pimp? +ac_cv_my_have_gtksharp=yes +PKG_CHECK_MODULES([GLADE_SHARP_20], [glade-sharp-2.0], [:], [ac_cv_my_have_gtksharp=no]) +PKG_CHECK_MODULES([GLIB_SHARP_20], [glib-sharp-2.0], [:], [ac_cv_my_have_gtksharp=no]) +PKG_CHECK_MODULES([GTK_SHARP_20], [gtk-sharp-2.0], [:], [ac_cv_my_have_gtksharp=no]) +AM_CONDITIONAL(USE_GTKSHARP, test "${ac_cv_my_have_gtksharp}" != no) AC_CONFIG_FILES([ Makefile diff --git a/pipi-sharp/Makefile.am b/pipi-sharp/Makefile.am index fff6c1a..9386661 100644 --- a/pipi-sharp/Makefile.am +++ b/pipi-sharp/Makefile.am @@ -19,10 +19,10 @@ EXTRA_DIST = $(pipi_sources) $(test_sources) \ pipi-sharp.pc.in pipi-sharp.dll.config.in pipi-sharp.dll: $(pipi_sources) - gmcs -debug -unsafe $(pipi_sources) -out:$@ -target:library + $(GMCS) -debug -unsafe $(pipi_sources) -out:$@ -target:library test.exe: $(test_sources) pipi-sharp.dll - gmcs -debug $(test_sources) -out:$@ -lib:./ \ + $(GMCS) -debug $(test_sources) -out:$@ -lib:./ \ -r:./pipi-sharp.dll clean-local: