I extracted the sources and the spec file from the SRPM package (did some minor changes to the %pre script). However, build fails. RPM produces the following output: make: Leaving directory `/usr/src/redhat/BUILD/postgresql-7.0.2/doc' + pushd /var/tmp/postgresql-7.0.2-root/usr/share/man /var/tmp/postgresql-7.0.2-root/usr/share/man /usr/src/redhat/BUILD/postgresql-7. 0.2 + tar xzf /usr/src/redhat/BUILD/postgresql-7.0.2/doc/man.tar.gz + cp /usr/src/redhat/SOURCES/postgresql-dump.1.gz man1 + popd /usr/src/redhat/BUILD/postgresql-7.0.2 + pushd /var/tmp/postgresql-7.0.2-root/usr/include /var/tmp/postgresql-7.0.2-root/usr/include /usr/src/redhat/BUILD/postgresql-7.0. 2 + rm -rf 'pgsql/*' + mv c.h pgsql + mv config.h pgsql + mv ecpgerrno.h pgsql + mv ecpglib.h pgsql + mv ecpgtype.h pgsql + mv fmgr.h pgsql + mv libpgeasy.h pgsql + mv libpgtcl.h pgsql + mv libpq-fe.h pgsql + mv libpq++.h pgsql + mv libpq-int.h pgsql + mv os.h pgsql + mv postgres_ext.h pgsql + mv postgres.h pgsql + mv pqexpbuffer.h pgsql + mv sql3types.h pgsql + mv sqlca.h pgsql + mv access pgsql + mv commands pgsql + mv executor pgsql + mv iodbc pgsql + mv lib pgsql + mv libpq pgsql + mv libpq++ pgsql + mv port pgsql + mv utils pgsql + popd /usr/src/redhat/BUILD/postgresql-7.0.2 + pushd src/include /usr/src/redhat/BUILD/postgresql-7.0.2/src/include /usr/src/redhat/BUILD/postgre sql-7.0.2 + /lib/cpp -M -I. -I../backend executor/spi.h + xargs -n 1 + grep '\W' + cpio -pdu /var/tmp/postgresql-7.0.2-root/usr/include/pgsql + sort + grep -v spi.h + grep -v '^/' cpio: spi.o:: No such file or directory 1233 blocks Bad exit status from /var/tmp/rpm-tmp.54321 (%install)
This has been fixed (just grep -v that file) - some cpp changes, I think.