diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2011-02-13 20:06:41 -0500 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2011-02-13 22:54:49 -0500 |
commit | 629b3af27d5c2bc9d6e16b22b943ad651d4ecb56 (patch) | |
tree | eae9ef9a69ae6ad7aacb2428e3cf15ec77873ac5 /contrib/lo | |
parent | e693e97d754ed6812ea115170afeae4bf8797d3f (diff) | |
download | postgresql-629b3af27d5c2bc9d6e16b22b943ad651d4ecb56.tar.gz |
Convert contrib modules to use the extension facility.
This isn't fully tested as yet, in particular I'm not sure that the
"foo--unpackaged--1.0.sql" scripts are OK. But it's time to get some
buildfarm cycles on it.
sepgsql is not converted to an extension, mainly because it seems to
require a very nonstandard installation process.
Dimitri Fontaine and Tom Lane
Diffstat (limited to 'contrib/lo')
-rw-r--r-- | contrib/lo/.gitignore | 1 | ||||
-rw-r--r-- | contrib/lo/Makefile | 5 | ||||
-rw-r--r-- | contrib/lo/lo--1.0.sql (renamed from contrib/lo/lo.sql.in) | 5 | ||||
-rw-r--r-- | contrib/lo/lo--unpackaged--1.0.sql | 5 | ||||
-rw-r--r-- | contrib/lo/lo.control | 5 | ||||
-rw-r--r-- | contrib/lo/uninstall_lo.sql | 17 |
6 files changed, 14 insertions, 24 deletions
diff --git a/contrib/lo/.gitignore b/contrib/lo/.gitignore deleted file mode 100644 index 979347bd00..0000000000 --- a/contrib/lo/.gitignore +++ /dev/null @@ -1 +0,0 @@ -/lo.sql diff --git a/contrib/lo/Makefile b/contrib/lo/Makefile index 43c01f57c0..66b337c17a 100644 --- a/contrib/lo/Makefile +++ b/contrib/lo/Makefile @@ -1,8 +1,9 @@ # contrib/lo/Makefile MODULES = lo -DATA_built = lo.sql -DATA = uninstall_lo.sql + +EXTENSION = lo +DATA = lo--1.0.sql lo--unpackaged--1.0.sql ifdef USE_PGXS PG_CONFIG = pg_config diff --git a/contrib/lo/lo.sql.in b/contrib/lo/lo--1.0.sql index 8c7afbe5e3..6ecb370a22 100644 --- a/contrib/lo/lo.sql.in +++ b/contrib/lo/lo--1.0.sql @@ -1,7 +1,4 @@ -/* contrib/lo/lo.sql.in */ - --- Adjust this setting to control where the objects get created. -SET search_path = public; +/* contrib/lo/lo--1.0.sql */ -- -- Create the data type ... now just a domain over OID diff --git a/contrib/lo/lo--unpackaged--1.0.sql b/contrib/lo/lo--unpackaged--1.0.sql new file mode 100644 index 0000000000..54de61686e --- /dev/null +++ b/contrib/lo/lo--unpackaged--1.0.sql @@ -0,0 +1,5 @@ +/* contrib/lo/lo--unpackaged--1.0.sql */ + +ALTER EXTENSION lo ADD domain lo; +ALTER EXTENSION lo ADD function lo_oid(lo); +ALTER EXTENSION lo ADD function lo_manage(); diff --git a/contrib/lo/lo.control b/contrib/lo/lo.control new file mode 100644 index 0000000000..849dfb5803 --- /dev/null +++ b/contrib/lo/lo.control @@ -0,0 +1,5 @@ +# lo extension +comment = 'Large Object maintenance' +default_version = '1.0' +module_pathname = '$libdir/lo' +relocatable = true diff --git a/contrib/lo/uninstall_lo.sql b/contrib/lo/uninstall_lo.sql deleted file mode 100644 index 77deb1d550..0000000000 --- a/contrib/lo/uninstall_lo.sql +++ /dev/null @@ -1,17 +0,0 @@ -/* contrib/lo/uninstall_lo.sql */ - --- Adjust this setting to control where the objects get dropped. -SET search_path = public; - --- --- This removes the LO type --- It's used just for development --- - --- drop the type and associated functions -DROP TYPE lo CASCADE; - --- the trigger function has no dependency on the type, so drop separately -DROP FUNCTION lo_manage(); - --- the lo stuff is now removed from the system |