Blame SOURCES/rpm-pgsql.patch

ca36e9
For the RPMs, we want the custom installation directories to end in
ca36e9
/pgsql not /postgresql.  This is historical but not worth changing.
ca36e9
ca36e9
Notice that this patch also makes the appending of /pgsql unconditional.
ca36e9
This is to avoid unexpected behavior if the RPM is built in a working
ca36e9
directory whose path happens to include "postgres" or "pgsql" already.
ca36e9
However, datadir and sysconfdir are already set up in the specfile's
ca36e9
configure call, so we do not have to append anything to them.
ca36e9
ca36e9
ca36e9
diff -Naur postgresql-9.0.1.orig/src/Makefile.global.in postgresql-9.0.1/src/Makefile.global.in
ca36e9
--- postgresql-9.0.1.orig/src/Makefile.global.in	2010-10-01 10:25:44.000000000 -0400
ca36e9
+++ postgresql-9.0.1/src/Makefile.global.in	2010-10-11 11:52:05.224975308 -0400
ca36e9
@@ -55,8 +55,7 @@
ca36e9
 # Installation directories
ca36e9
 #
ca36e9
 # These are set by the equivalent --xxxdir configure options.  We
ca36e9
-# append "postgresql" to some of them, if the string does not already
ca36e9
-# contain "pgsql" or "postgres", in order to avoid directory clutter.
ca36e9
+# append "pgsql" to some of them, in order to avoid directory clutter.
ca36e9
 #
ca36e9
 # In a PGXS build, we cannot use the values inserted into Makefile.global
ca36e9
 # by configure, since the installation tree may have been relocated.
ca36e9
@@ -74,45 +73,23 @@
ca36e9
 bindir := @bindir@
ca36e9
 
ca36e9
 datadir := @datadir@
ca36e9
-ifeq "$(findstring pgsql, $(datadir))" ""
ca36e9
-ifeq "$(findstring postgres, $(datadir))" ""
ca36e9
-override datadir := $(datadir)/postgresql
ca36e9
-endif
ca36e9
-endif
ca36e9
 
ca36e9
 sysconfdir := @sysconfdir@
ca36e9
-ifeq "$(findstring pgsql, $(sysconfdir))" ""
ca36e9
-ifeq "$(findstring postgres, $(sysconfdir))" ""
ca36e9
-override sysconfdir := $(sysconfdir)/postgresql
ca36e9
-endif
ca36e9
-endif
ca36e9
 
ca36e9
 libdir := @libdir@
ca36e9
 
ca36e9
 pkglibdir = $(libdir)
ca36e9
-ifeq "$(findstring pgsql, $(pkglibdir))" ""
ca36e9
-ifeq "$(findstring postgres, $(pkglibdir))" ""
ca36e9
-override pkglibdir := $(pkglibdir)/postgresql
ca36e9
-endif
ca36e9
-endif
ca36e9
+override pkglibdir := $(pkglibdir)/pgsql
ca36e9
 
ca36e9
 includedir := @includedir@
ca36e9
 
ca36e9
 pkgincludedir = $(includedir)
ca36e9
-ifeq "$(findstring pgsql, $(pkgincludedir))" ""
ca36e9
-ifeq "$(findstring postgres, $(pkgincludedir))" ""
ca36e9
-override pkgincludedir := $(pkgincludedir)/postgresql
ca36e9
-endif
ca36e9
-endif
ca36e9
+override pkgincludedir := $(pkgincludedir)/pgsql
ca36e9
 
ca36e9
 mandir := @mandir@
ca36e9
 
ca36e9
 docdir := @docdir@
ca36e9
-ifeq "$(findstring pgsql, $(docdir))" ""
ca36e9
-ifeq "$(findstring postgres, $(docdir))" ""
ca36e9
-override docdir := $(docdir)/postgresql
ca36e9
-endif
ca36e9
-endif
ca36e9
+override docdir := $(docdir)/pgsql
ca36e9
 
ca36e9
 htmldir := @htmldir@
ca36e9