%.sql: %.sql.in
sed 's,MODULE_PATHNAME,$$libdir/postgis-@POSTGIS_MAJOR_VERSION@.@POSTGIS_MINOR_VERSION@,g' $< >$@
-postgis_upgrade_20_minor.sql.in: postgis_drop_before.sql.in.c postgis.sql postgis_drop.sql.in.c
+postgis_upgrade_20_minor.sql.in: postgis_drop_before.sql postgis.sql postgis_drop_after.sql
cat $^ > $@
postgis_upgrade_20_minor.sql: postgis_upgrade_20_minor.sql.in ../utils/postgis_proc_upgrade.pl
$(PERL) ../utils/postgis_proc_upgrade.pl $< 2.0 > $@
# SQL objects are also dependent on postgis_config.h for PostgreSQL version
$(SQL_OBJS): ../postgis_config.h ../postgis_svn_revision.h
-postgis.sql.in: sqldefines.h long_xact.sql.in.c geography.sql.in.c postgis_drop.sql.in.c
+postgis.sql.in: sqldefines.h long_xact.sql.in.c geography.sql.in.c
#uninstall_postgis.sql.in: sqldefines.h uninstall_sqlmm.sql.in.c uninstall_long_xact.sql.in.c uninstall_geography.sql.in.c
uninstall_postgis.sql: postgis.sql ../utils/create_undef.pl
+-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+--
-- $Id$
+--
+-- PostGIS - Spatial Types for PostgreSQL
+-- http://postgis.refractions.net
+--
+-- Copyright (C) 2011-2012 Sandro Santilli <strk@keybit.net>
+-- Copyright (C) 2010-2012 Regina Obe <lr@pcorp.us>
+-- Copyright (C) 2009 Paul Ramsey <pramsey@cleverelephant.ca>
+--
+-- This is free software; you can redistribute and/or modify it under
+-- the terms of the GNU General Public Licence. See the COPYING file.
+--
+-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+--
+-- This file contains drop commands for obsoleted items that need
+-- to be dropped _after_ upgrade of old functions.
+-- Changes to this file affect postgis_upgrade*.sql script.
+--
+-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+
-- First drop old aggregates
DROP AGGREGATE IF EXISTS memgeomunion(geometry);
DROP AGGREGATE IF EXISTS geomunion(geometry);
--- /dev/null
+-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+--
+-- $Id$
+--
+-- PostGIS - Spatial Types for PostgreSQL
+-- http://postgis.refractions.net
+--
+-- Copyright (C) 2011-2012 Sandro Santilli <strk@keybit.net>
+-- Copyright (C) 2010-2012 Regina Obe <lr@pcorp.us>
+-- Copyright (C) 2009 Paul Ramsey <pramsey@cleverelephant.ca>
+--
+-- This is free software; you can redistribute and/or modify it under
+-- the terms of the GNU General Public Licence. See the COPYING file.
+--
+-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+--
+-- This file contains drop commands for obsoleted items that need
+-- to be dropped _before_ upgrade of old functions.
+-- Changes to this file affect postgis_upgrade*.sql script.
+--
+-- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
+
+DROP FUNCTION IF EXISTS AddGeometryColumn(varchar,varchar,varchar,varchar,integer,varchar,integer,boolean);
+DROP FUNCTION IF EXISTS ST_MakeEnvelope(float8, float8, float8, float8);
+--changed name of prec arg to be consistent with ST_AsGML/KML
+DROP FUNCTION IF EXISTS ST_AsX3D(geometry, integer, integer);
+--changed name of arg: http://trac.osgeo.org/postgis/ticket/1606
+DROP FUNCTION IF EXISTS UpdateGeometrySRID(varchar,varchar,varchar,varchar,integer);
+++ /dev/null
--- $Id$
--- These are functions where the argument names may have changed --
--- so have to be dropped before upgrade can happen --
-DROP FUNCTION IF EXISTS AddGeometryColumn(varchar,varchar,varchar,varchar,integer,varchar,integer,boolean);
-DROP FUNCTION IF EXISTS ST_MakeEnvelope(float8, float8, float8, float8);
---changed name of prec arg to be consistent with ST_AsGML/KML
-DROP FUNCTION IF EXISTS ST_AsX3D(geometry, integer, integer);
---changed name of arg: http://trac.osgeo.org/postgis/ticket/1606
-DROP FUNCTION IF EXISTS UpdateGeometrySRID(varchar,varchar,varchar,varchar,integer);