]> granicus.if.org Git - postgis/commitdiff
Include GUI as conditional install target
authorPaul Ramsey <pramsey@cleverelephant.ca>
Mon, 28 Dec 2009 18:48:49 +0000 (18:48 +0000)
committerPaul Ramsey <pramsey@cleverelephant.ca>
Mon, 28 Dec 2009 18:48:49 +0000 (18:48 +0000)
git-svn-id: http://svn.osgeo.org/postgis/trunk@5057 b70326c6-7e19-0410-871a-916f4a2858ee

loader/Makefile.in

index f844e1176a5b791dc34f04a557ebeb45fca55a77..afcf68f2ec7a66e7299d6cc853b23ab13b347dbe 100644 (file)
@@ -56,6 +56,8 @@ ifeq ($(REGRESS),1)
        datadir=/share
 endif
 
+# We test this variable later to see if we're building the GUI
+gtk_build = @GTK_BUILD@
 
 # The real parts of the Makefile
 all: $(SHP2PGSQL-CLI) $(PGSQL2SHP) @GTK_BUILD@
@@ -88,8 +90,13 @@ shp2pgsql-gui.o: shp2pgsql-gui.c
 $(SHP2PGSQL-GUI): stringbuffer.o shpopen.o dbfopen.o shp2pgsql-core.o shp2pgsql-gui.o $(LIBLWGEOM) $(GTK_WIN32_RES)
        $(CC) $(CFLAGS) $(GTK_WIN32_FLAGS) $^ -o $@ $(GTK_LIBS) $(ICONV_LDFLAGS) $(PGSQL_FE_LDFLAGS) -lm 
 
-install: all
+installdir:
        @mkdir -p $(DESTDIR)$(bindir)
+
+install: installdir 
+ifdef gtk_build
+       $(INSTALL) $(SHP2PGSQL-GUI) $(DESTDIR)$(bindir)
+endif
        $(INSTALL) $(PGSQL2SHP) $(DESTDIR)$(bindir)
        $(INSTALL) $(SHP2PGSQL-CLI) $(DESTDIR)$(bindir)