Fix multilib problem introduced in 8.2.x: new include file ecpg_config.h is

architecture-dependent.
This commit is contained in:
Tom Lane 2007-09-04 17:26:37 +00:00
parent 05e04c889c
commit 23226f90bb
2 changed files with 32 additions and 1 deletions

25
ecpg_config.h Normal file
View File

@ -0,0 +1,25 @@
/*
* Kluge to support multilib installation of both 32- and 64-bit RPMS:
* we need to arrange that header files that appear in both RPMs are
* identical. Hence, this file is architecture-independent and calls
* in an arch-dependent file that will appear in just one RPM.
*
* To avoid breaking arches not explicitly supported by Red Hat, we
* use this indirection file *only* on known multilib arches.
*
* Note: this may well fail if user tries to use gcc's -I- option.
* But that option is deprecated anyway.
*/
#if defined(__x86_64__)
#include "ecpg_config_x86_64.h"
#elif defined(__i386__)
#include "ecpg_config_i386.h"
#elif defined(__ppc64__) || defined(__powerpc64__)
#include "ecpg_config_ppc64.h"
#elif defined(__ppc__) || defined(__powerpc__)
#include "ecpg_config_ppc.h"
#elif defined(__s390x__)
#include "ecpg_config_s390x.h"
#elif defined(__s390__)
#include "ecpg_config_s390.h"
#endif

View File

@ -81,7 +81,7 @@
Summary: PostgreSQL client programs and libraries Summary: PostgreSQL client programs and libraries
Name: postgresql Name: postgresql
Version: 8.2.4 Version: 8.2.4
Release: 5%{?dist} Release: 6%{?dist}
License: BSD License: BSD
Group: Applications/Databases Group: Applications/Databases
Url: http://www.postgresql.org/ Url: http://www.postgresql.org/
@ -91,6 +91,7 @@ Source3: postgresql.init
Source4: Makefile.regress Source4: Makefile.regress
Source5: pg_config.h Source5: pg_config.h
Source6: README.rpm-dist Source6: README.rpm-dist
Source7: ecpg_config.h
Source14: postgresql.pam Source14: postgresql.pam
Source15: postgresql-bashprofile Source15: postgresql-bashprofile
Source16: filter-requires-perl-Pg.sh Source16: filter-requires-perl-Pg.sh
@ -484,6 +485,8 @@ case `uname -i` in
install -m 644 %{SOURCE5} $RPM_BUILD_ROOT/usr/include/ install -m 644 %{SOURCE5} $RPM_BUILD_ROOT/usr/include/
mv $RPM_BUILD_ROOT/usr/include/pgsql/server/pg_config.h $RPM_BUILD_ROOT/usr/include/pgsql/server/pg_config_`uname -i`.h mv $RPM_BUILD_ROOT/usr/include/pgsql/server/pg_config.h $RPM_BUILD_ROOT/usr/include/pgsql/server/pg_config_`uname -i`.h
install -m 644 %{SOURCE5} $RPM_BUILD_ROOT/usr/include/pgsql/server/ install -m 644 %{SOURCE5} $RPM_BUILD_ROOT/usr/include/pgsql/server/
mv $RPM_BUILD_ROOT/usr/include/ecpg_config.h $RPM_BUILD_ROOT/usr/include/ecpg_config_`uname -i`.h
install -m 644 %{SOURCE7} $RPM_BUILD_ROOT/usr/include/
;; ;;
*) *)
;; ;;
@ -819,6 +822,9 @@ rm -rf $RPM_BUILD_ROOT
%endif %endif
%changelog %changelog
* Tue Sep 4 2007 Tom Lane <tgl@redhat.com> 8.2.4-6
- Fix multilib problem for /usr/include/ecpg_config.h (which is new in 8.2.x)
* Sat Aug 25 2007 Tom Lane <tgl@redhat.com> 8.2.4-5 * Sat Aug 25 2007 Tom Lane <tgl@redhat.com> 8.2.4-5
- Use nicer solution for tzdata file substitution: upstream discussion - Use nicer solution for tzdata file substitution: upstream discussion
concluded that hardwiring the path was better than a symlink after all. concluded that hardwiring the path was better than a symlink after all.