[postgis-tickets] r15894 - Drop conditionals on PG 91 (we require 93+ anyway)

Sandro Santilli strk at kbt.io
Thu Oct 5 04:28:42 PDT 2017


Author: strk
Date: 2017-10-05 04:28:42 -0700 (Thu, 05 Oct 2017)
New Revision: 15894

Modified:
   trunk/extensions/postgis/Makefile.in
   trunk/extensions/postgis_sfcgal/Makefile.in
   trunk/extensions/postgis_tiger_geocoder/Makefile.in
   trunk/extensions/postgis_topology/Makefile.in
Log:
Drop conditionals on PG 91 (we require 93+ anyway)

Modified: trunk/extensions/postgis/Makefile.in
===================================================================
--- trunk/extensions/postgis/Makefile.in	2017-10-05 10:50:16 UTC (rev 15893)
+++ trunk/extensions/postgis/Makefile.in	2017-10-05 11:28:42 UTC (rev 15894)
@@ -27,14 +27,11 @@
 #DOCS         = $(wildcard ../../doc/html/*.html)
 PG_CONFIG    = @PG_CONFIG@
 
-PG91         = $(shell $(PG_CONFIG) --version | $(GREP) -qE " 8\.| 9\.0" && echo no || echo yes)
 SQL_BITS     = $(wildcard sql_bits/*.sql)
 EXTRA_CLEAN += ${SQL_BITS} sql/*.sql
 
 CURV_big=@POSTGIS_MAJOR_VERSION@@POSTGIS_MINOR_VERSION@
 
-ifeq ($(PG91),yes)
-
 all: sql/$(EXTENSION)--$(EXTVERSION).sql sql/$(EXTENSION)--unpackaged--$(EXTVERSION).sql sql/$(EXTENSION)--$(EXTVERSION)--$(EXTVERSION)next.sql sql/$(EXTENSION)--$(EXTVERSION)next--$(EXTVERSION).sql sql_minor_upgrade
 
 sql/$(EXTENSION).sql: sql_bits/postgis.sql sql_bits/postgis_comments.sql sql_bits/rtpostgis.sql sql_bits/spatial_ref_sys_config_dump.sql sql_bits/raster_comments.sql sql_bits/spatial_ref_sys.sql
@@ -105,7 +102,6 @@
 
 DATA = $(wildcard sql/*--*.sql)
 EXTRA_CLEAN += sql/$(EXTENSION)--$(EXTVERSION).sql sql/postgis--unpackaged--$(EXTVERSION).sql
-endif
 
 distclean: clean
 	rm -f Makefile

Modified: trunk/extensions/postgis_sfcgal/Makefile.in
===================================================================
--- trunk/extensions/postgis_sfcgal/Makefile.in	2017-10-05 10:50:16 UTC (rev 15893)
+++ trunk/extensions/postgis_sfcgal/Makefile.in	2017-10-05 11:28:42 UTC (rev 15894)
@@ -26,18 +26,16 @@
 
 PG_CONFIG    =  @PG_CONFIG@
 
-PG91         = $(shell $(PG_CONFIG) --version | $(GREP) -qE " 8\.| 9\.0" && echo no || echo yes)
 SQL_BITS     = $(wildcard sql_bits/*.sql)
-EXTRA_CLEAN += sql/*.sql ${SQL_BITS} 
+EXTRA_CLEAN += sql/*.sql ${SQL_BITS}
 
 
-ifeq ($(PG91),yes)
 all: sql/$(EXTENSION)--$(EXTVERSION).sql sql/$(EXTENSION)--unpackaged--$(EXTVERSION).sql sql/$(EXTENSION)--$(EXTVERSION)--$(EXTVERSION)next.sql sql/$(EXTENSION)--$(EXTVERSION)next--$(EXTVERSION).sql sql_minor_upgrade
 
 sql/$(EXTENSION)--$(EXTVERSION).sql: sql/$(EXTENSION).sql
 	mkdir -p sql
 	cp $< $@
-	
+
 sql/$(EXTENSION).sql: sql_bits/sfcgal.sql  sql_bits/sfcgal_comments.sql
 	mkdir -p sql
 	cat $^ > $@
@@ -81,10 +79,9 @@
 	for OLD_VERSION in $(UPGRADEABLE_VERSIONS); do \
   	  cat $< > sql/$(EXTENSION)--$$OLD_VERSION--$(EXTVERSION).sql; \
 	done
-	
+
 DATA = $(wildcard sql/*--*.sql)
 EXTRA_CLEAN += sql/$(EXTENSION)--$(EXTVERSION).sql sql/$(EXTENSION)--unpackaged--$(EXTVERSION).sql
-endif
 
 distclean: clean
 	rm Makefile

Modified: trunk/extensions/postgis_tiger_geocoder/Makefile.in
===================================================================
--- trunk/extensions/postgis_tiger_geocoder/Makefile.in	2017-10-05 10:50:16 UTC (rev 15893)
+++ trunk/extensions/postgis_tiger_geocoder/Makefile.in	2017-10-05 11:28:42 UTC (rev 15894)
@@ -28,9 +28,8 @@
 
 PG_CONFIG    =  @PG_CONFIG@
 
-PG91         = $(shell $(PG_CONFIG) --version | $(GREP) -qE " 8\.| 9\.0" && echo no || echo yes)
 SQL_BITS     = $(wildcard sql_bits/*.sql)
-EXTRA_CLEAN += sql/*.sql ${SQL_BITS} 
+EXTRA_CLEAN += sql/*.sql ${SQL_BITS}
 
 #test address standardizer if also built
 ifeq (@ADDRESS_STANDARDIZER@,address_standardizer)
@@ -38,7 +37,6 @@
 	REGRESS_OPTS += --load-extension=address_standardizer
 endif
 
-ifeq ($(PG91),yes)
 all: sql/$(EXTENSION)--$(EXTVERSION).sql sql/$(EXTENSION)--unpackaged--$(EXTVERSION).sql sql/$(EXTENSION)--$(EXTVERSION)--$(EXTVERSION)next.sql sql/$(EXTENSION)--$(EXTVERSION)next--$(EXTVERSION).sql  sql_minor_upgrade sql/test-normalize_address.sql  sql/test-pagc_normalize_address.sql expected/test-normalize_address.out expected/test-pagc_normalize_address.out sql/test-upgrade.sql expected/test-upgrade.out sql/$(EXTENSION)--$(EXTVERSION)next--$(EXTVERSION).sql  sql_minor_upgrade
 
 sql/$(EXTENSION)--$(EXTVERSION).sql: sql/$(EXTENSION).sql
@@ -50,46 +48,46 @@
 expected/test-normalize_address.out: sql_bits/test_tuples_only_unaligned.sql.in ../../extras/tiger_geocoder/regress/normalize_address_regress
 	mkdir -p expected
 	cat $^ > $@
-	
+
 expected/test-pagc_normalize_address.out: sql_bits/test_tuples_only_unaligned.sql.in ../../extras/tiger_geocoder/regress/pagc_normalize_address_regress
 	cat $^ > $@
-	
+
 ## adding \t .. to force output to be the same as what get in regular regress in tiger folder
 sql/test-normalize_address.sql: sql_bits/test_tuples_only_unaligned.sql.in ../../extras/tiger_geocoder/regress/normalize_address_regress.sql
 	mkdir -p sql
 	cat $^ > $@
-	
-sql/test-upgrade.sql: 
+
+sql/test-upgrade.sql:
 	mkdir -p sql
 	echo 'ALTER EXTENSION ${EXTENSION} UPDATE TO "$(EXTVERSION)next"' > $@
-	
+
 expected/test-upgrade.out: sql/test-upgrade.sql
 	cp $< $@
-	
+
 sql/test-pagc_normalize_address.sql: sql_bits/test_tuples_only_unaligned.sql.in ../../extras/tiger_geocoder/regress/pagc_normalize_address_regress.sql
 	mkdir -p sql
 	cat $^ > $@
-	
+
 sql/$(EXTENSION).sql: sql_bits/tiger_geocoder.sql  sql_bits/mark_editable_objects.sql.in sql_bits/tiger_geocoder_comments.sql
 	mkdir -p sql
 	cat $^ > $@
-	
+
 #this is a cludge to allow upgrading from same SVN to same SVN
 sql/$(EXTENSION)--$(EXTVERSION)--$(EXTVERSION)next.sql: ../postgis_extension_helper.sql sql_bits/remove_from_extension.sql.in sql/tiger_geocoder_upgrade_minor.sql sql_bits/mark_editable_objects.sql.in sql_bits/tiger_geocoder_comments.sql
 	mkdir -p sql
 	cat $^ > $@
 	echo "SELECT postgis_extension_drop_if_exists('${EXTENSION}', 'DROP SCHEMA tiger_data');" >> $@
 	cat ../postgis_extension_helper_uninstall.sql  >> $@
-	
-	
 
 
+
+
 sql/$(EXTENSION)--$(EXTVERSION)next--$(EXTVERSION).sql: sql/$(EXTENSION)--$(EXTVERSION)--$(EXTVERSION)next.sql
 	mkdir -p sql
 	cp $< $@
-	
+
 #strip BEGIN/COMMIT since these are not allowed in extensions
-#strip CREATE SCHEMA since we force extension 
+#strip CREATE SCHEMA since we force extension
 # to create schema by setting schema to tiger_geocoder in control
 #also remove tiger_data from extension if it is part of it
 sql_bits/tiger_geocoder_minor.sql.in: ../../extras/tiger_geocoder/utility/set_search_path.sql \
@@ -124,7 +122,7 @@
 	../../extras/tiger_geocoder/geocode/reverse_geocode.sql \
 	../../extras/tiger_geocoder/geocode/census_tracts_functions.sql
 	cat $^ > $@
-	
+
 #also remove tiger_data from extension if it is part of it so data gets backed up
 sql_bits/tiger_geocoder.sql.in: sql_bits/norm_addy_create.sql.in \
 	../../extras/tiger_geocoder/utility/set_search_path.sql \
@@ -165,20 +163,20 @@
 	cat $^ > $@
 	echo "SELECT postgis_extension_drop_if_exists('${EXTENSION}', 'DROP SCHEMA tiger_data');" >> $@
 	cat ../postgis_extension_helper_uninstall.sql  >> $@
-	
+
 sql_bits/tiger_geocoder.sql: sql_bits/tiger_geocoder.sql.in
 	sed -e 's/BEGIN;//g' -e 's/COMMIT;//g' -e '/^CREATE SCHEMA/d;'  $< > $@
 	$(PERL) -pe 's/BEGIN\;//g ; s/COMMIT\;//g' $< > $@
-	
+
 sql_bits/add_search_path.sql: sql_bits/add_search_path.sql.in
 	cp $< $@
-	
+
 ../../doc/tiger_geocoder_comments.sql:
 	$(MAKE) -C ../../doc comments
-	
+
 sql_bits/tiger_geocoder_comments.sql: ../../doc/tiger_geocoder_comments.sql
 	cp $< $@
-	
+
 #grep all lines that start with CREATE OR REPLACE FUNCTION, TRIGGER...
 #then replace CREATE OR REPLACE .. with ALTER EXTENSION..;
 #then remove default values and extra junk
@@ -193,7 +191,7 @@
 # 		-e 's/\\(;/;/' \
 # 		-e 's/;;/;/g' $< > $@
 
-#hardcode for now using 
+#hardcode for now using
 #the extensions/make_unpackaged.sql script form an install
 sql/$(EXTENSION)--unpackaged--$(EXTVERSION).sql: sql_bits/tiger_geocoder--unpackaged.sql.in
 	mkdir -p sql
@@ -202,28 +200,27 @@
 #upgrade script should have everything but table, schema, type creation/alter
 #NOTE: we assume all object definitions end in ;
 #first expression deletes all non-removable objects defined on same line
-#second deletes all non-removable defined on multiple lines 
+#second deletes all non-removable defined on multiple lines
 #  the end of the body of object we assume ends in ;
-#aggregates are special 
+#aggregates are special
 #they can be dropped but we need to remove
 #them from the extension first
-sql/tiger_geocoder_upgrade_minor.sql:  sql_bits/tiger_geocoder_minor.sql.in 
+sql/tiger_geocoder_upgrade_minor.sql:  sql_bits/tiger_geocoder_minor.sql.in
 	mkdir -p sql
 	 sed -e '/^\(CREATE\|ALTER\) \(CAST\|TYPE\|TABLE\|SCHEMA\|DOMAIN\|TRIGGER\).*;/d' \
 	 	 -e '/^\(CREATE\|ALTER\) \(CAST\|TYPE\|TABLE\|SCHEMA\|DOMAIN\|TRIGGER\)/,/\;/d' \
 	 	 -e 's/BEGIN;//g' -e 's/COMMIT;//g' \
 	 	 $< > $@
-	 	 	
+
 sql_minor_upgrade: sql/$(EXTENSION)--$(EXTVERSION)--$(EXTVERSION)next.sql
 	for OLD_VERSION in $(UPGRADEABLE_VERSIONS); do \
   	  cat $^ > sql/$(EXTENSION)--$$OLD_VERSION--$(EXTVERSION).sql; \
 	done
 
-#only extension files	
+#only extension files
 DATA = ${EXTENSION}.control sql/$(EXTENSION).sql $(wildcard sql/*--*.sql)
 EXTRA_CLEAN += $(wildcard expected/*--*.out)
 EXTRA_CLEAN += sql/$(EXTENSION)--$(EXTVERSION).sql sql/$(EXTENSION)--unpackaged--$(EXTVERSION).sql
-endif
 
 distclean: clean
 	rm Makefile

Modified: trunk/extensions/postgis_topology/Makefile.in
===================================================================
--- trunk/extensions/postgis_topology/Makefile.in	2017-10-05 10:50:16 UTC (rev 15893)
+++ trunk/extensions/postgis_topology/Makefile.in	2017-10-05 11:28:42 UTC (rev 15894)
@@ -23,41 +23,38 @@
 
 PG_CONFIG    = @PG_CONFIG@
 
-PG91         = $(shell $(PG_CONFIG) --version | $(GREP) -qE " 8\.| 9\.0" && echo no || echo yes)
 SQL_BITS     = $(wildcard sql_bits/*.sql)
 EXTRA_CLEAN += sql/*.sql ${SQL_BITS}
 
 
-ifeq ($(PG91),yes)
-
 all: sql/$(EXTENSION)--$(EXTVERSION).sql sql/$(EXTENSION)--unpackaged--$(EXTVERSION).sql sql/$(EXTENSION)--$(EXTVERSION)--$(EXTVERSION)next.sql sql/$(EXTENSION)--$(EXTVERSION)next--$(EXTVERSION).sql sql_minor_upgrade
 
 sql/$(EXTENSION)--$(EXTVERSION).sql: sql/$(EXTENSION).sql
 	mkdir -p sql
 	cp $< $@
-	
+
 sql/$(EXTENSION).sql: extlock.sql sql_bits/topology.sql  sql_bits/mark_editable_objects.sql.in sql_bits/topology_comments.sql
 	mkdir -p sql
 	cat $^ > $@
-	
+
 #this is a cludge to allow upgrading from same SVN to same SVN
 sql/$(EXTENSION)--$(EXTVERSION)--$(EXTVERSION)next.sql: extlock.sql ../postgis_extension_helper.sql sql_bits/remove_from_extension.sql.in sql/topology_upgrade.sql sql_bits/mark_editable_objects.sql.in sql_bits/topology_comments.sql ../postgis_extension_helper_uninstall.sql
 	cat $^ > $@
 sql/$(EXTENSION)--$(EXTVERSION)next--$(EXTVERSION).sql: sql/$(EXTENSION)--$(EXTVERSION)--$(EXTVERSION)next.sql
 	cat $^ > $@
-	
+
 #strip BEGIN/COMMIT since these are not allowed in extensions
-#strip CREATE SCHEMA since we force extension 
+#strip CREATE SCHEMA since we force extension
 # to create schema by setting schema to topology in control
 sql_bits/topology.sql: ../../topology/topology.sql
 	sed -e 's/BEGIN;//g' -e 's/COMMIT;//g' -e '/^CREATE SCHEMA/d;'  $< > $@
-	
+
 ../../doc/topology_comments.sql:
 	$(MAKE) -C ../../doc comments
-	
+
 sql_bits/topology_comments.sql: ../../doc/topology_comments.sql
 	cp $< $@
-	
+
 sql/$(EXTENSION)--unpackaged--$(EXTVERSION).sql: ../../topology/topology.sql ../../utils/create_unpackaged.pl
 	mkdir -p sql
 	cat $< | $(PERL) ../../utils/create_unpackaged.pl postgis_topology > $@
@@ -65,15 +62,15 @@
 #upgrade script should have everything but table, schema, type creation/alter
 #NOTE: we assume all object definitions end in ;
 #first expression deletes all non-removable objects defined on same line
-#second deletes all non-removable defined on multiple lines 
+#second deletes all non-removable defined on multiple lines
 #  the end of the body of object we assume ends in ;
-#aggregates are special 
+#aggregates are special
 #they can be dropped but we need to remove
 #them from the extension first
 sql/topology_upgrade.sql:  ../../topology/topology_upgrade.sql
 	mkdir -p sql
 	sed -e 's/BEGIN;//g' -e 's/COMMIT;//g' -e '/^CREATE SCHEMA/d;'  $< > $@
-	
+
 sql_minor_upgrade: extlock.sql ../postgis_extension_helper.sql sql_bits/remove_from_extension.sql.in sql/topology_upgrade.sql sql_bits/mark_editable_objects.sql.in sql_bits/topology_comments.sql ../postgis_extension_helper_uninstall.sql
 	for OLD_VERSION in $(UPGRADEABLE_VERSIONS); do \
   	  cat $^ > sql/$(EXTENSION)--$$OLD_VERSION--$(EXTVERSION).sql; \
@@ -81,7 +78,6 @@
 
 DATA = $(wildcard sql/*--*.sql)
 EXTRA_CLEAN += sql/$(EXTENSION)--$(EXTVERSION).sql sql/$(EXTENSION)--unpackaged--$(EXTVERSION).sql
-endif
 
 distclean: clean
 	rm Makefile



More information about the postgis-tickets mailing list