Search
j0ke.net Open Build Service
>
Projects
>
server:database
:
postgresql
:
9.0
>
postgresql
> postgresql.spec
Sign Up
|
Log In
Username
Password
Cancel
Overview
Repositories
Revisions
Requests
Users
Advanced
Attributes
Meta
File postgresql.spec of Package postgresql (Revision 3)
Currently displaying revision
3
,
show latest
# # spec file for package postgresql (Version 9.0.4) # # Copyright (c) 2010 SUSE LINUX Products GmbH, Nuernberg, Germany. # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed # upon. The license for this file, and modifications and additions to the # file, is the same license as for the pristine package itself (unless the # license for the pristine package is not an Open Source License, in which # case the license is the MIT License). An "Open Source License" is a # license that conforms to the Open Source Definition (Version 1.9) # published by the Open Source Initiative. # Please submit bugfixes or comments via http://bugs.opensuse.org/ # Name: postgresql BuildRequires: gettext-devel zlib-devel ncurses-devel readline-devel BuildRequires: openldap2-devel openssl-devel pam-devel BuildRequires: python-devel tcl-devel %if 0%{?suse_version} > 910 BuildRequires: krb5-devel libxslt-devel %endif Summary: Basic Clients and Utilities for PostgreSQL Version: 9.0.4 Release: 1 %define pg_minor_version %(echo %version | sed -r 's/^([0-9]+\\.[0-9]+).*/\\1/') License: BSD3c(or similar) Group: Productivity/Databases/Tools Source0: postgresql-%version.tar.bz2 Source1: baselibs.conf Source2: postgresql-README.SuSE.de Source3: postgresql-README.SuSE.en Source8: postgresql-sysconfig Source9: postgresql-init Source15: postgresql-bashprofile Source16: postgresql-firewall Source17: postgresql-rpmlintrc Patch1: postgresql-conf.patch Patch2: postgresql-regress.patch Patch3: postgresql-sle10-timestamptz.patch Patch4: postgresql-plperl.patch PreReq: postgresql-libs = %pg_minor_version Url: http://www.postgresql.org/ Provides: postgresql = %pg_minor_version BuildRoot: %{_tmppath}/%{name}-%{version}-build %description PostgreSQL is an advanced object-relational database management system that supports an extended subset of the SQL standard, including transactions, foreign keys, subqueries, triggers, and user-defined types and functions. This package contains the basic utility and client programs necessary to maintain and work with local or remote PostgreSQL databases as well as manual pages for the SQL commands that PostgreSQL supports. Full HTML documentation for PostgreSQL can be found in the postgresql-docs package. %package libs License: BSD3c(or similar) Summary: Shared Libraries Required for PostgreSQL Clients Group: Productivity/Databases/Clients # bug437293 %ifarch ppc64 Obsoletes: postgresql-libs-64bit %endif # Provides: postgresql-libs = %pg_minor_version PreReq: sh-utils fileutils %description libs PostgreSQL is an advanced object-relational database management system that supports an extended subset of the SQL standard, including transactions, foreign keys, subqueries, triggers, user-defined types and functions. This package provides the essential shared libraries for (almost) any PostgreSQL client program or interface. You will need to install this package in order to use any other PostgreSQL package or any clients that need to connect to a PostgreSQL server. %package server License: BSD3c(or similar) Summary: The Programs Needed to Create and Run a PostgreSQL Server Group: Productivity/Databases/Servers PreReq: %insserv_prereq %fillup_prereq PreReq: /usr/sbin/useradd /usr/sbin/groupadd /sbin/chkconfig PreReq: /usr/bin/strings /bin/sed PreReq: postgresql = %pg_minor_version Requires: glibc-locale Provides: postgresql-server = %pg_minor_version %package docs License: BSD3c(or similar) Summary: HTML Documentation for PostgreSQL Group: Productivity/Databases/Tools %if 0%{?suse_version} >= 1120 BuildArch: noarch %endif %description docs PostgreSQL is an advanced object-relational database management system that supports an extended subset of the SQL standard, including transactions, foreign keys, subqueries, triggers, and user-defined types and functions. This package contains the HTML documentation for PostgreSQL. The start page is: file:///usr/share/doc/packages/postgresql/html/index.html . Manual pages for the PostgreSQL SQL statements can be found in the postgresql package. %package contrib License: BSD3c(or similar) Summary: Contributed Extensions and Additions to PostgreSQL Group: Productivity/Databases/Tools Requires: postgresql-server = %pg_minor_version %description contrib PostgreSQL is an advanced object-relational database management system that supports an extended subset of the SQL standard, including transactions, foreign keys, subqueries, triggers, and user-defined types and functions. The postgresql-contrib package includes extensions and additions that are distributed along with the PostgreSQL sources, but are not (yet) officially part of the PostgreSQL core. Documentation for the modules contained in this package can be found in /usr/share/doc/packages/postgresql/contrib. %description server PostgreSQL is an advanced object-relational database management system that supports an extended subset of the SQL standard, including transactions, foreign keys, sub-queries, triggers, and user-defined types and functions. This package includes the programs needed to create and run a PostgreSQL server, which will in turn allow you to create and maintain PostgreSQL databases. %package devel License: BSD3c(or similar) Summary: PostgreSQL development header files and libraries Group: Productivity/Databases/Tools Requires: postgresql-libs = %pg_minor_version %description devel PostgreSQL is an advanced object-relational database management system that supports an extended subset of the SQL standard, including transactions, foreign keys, subqueries, triggers, and user-defined types and functions. This package contains the header files and libraries needed to compile C applications which will directly interact with a PostgreSQL database management server and the ECPG Embedded C Postgres preprocessor. You need to install this package if you want to develop applications in C which will interact with a PostgreSQL server. %package plperl License: BSD3c(or similar) Summary: The PL/Tcl, PL/Perl, and PL/Python procedural languages for PostgreSQL Group: Productivity/Databases/Servers Requires: perl = %perl_version Obsoletes: postgresql-pl Provides: postgresql-pl:%_libdir/postgresql/plperl.so Requires: postgresql-server = %pg_minor_version %description plperl PostgreSQL is an advanced object-relational database management system that supports an extended subset of the SQL standard, including transactions, foreign keys, subqueries, triggers, and user-defined types and functions. This package contains the PL/Perl procedural language for PostgreSQL. With this module one can use Perl to write stored procedures, functions, and triggers. %package plpython License: BSD3c(or similar) Summary: The PL/Python Procedural Languages for PostgreSQL Group: Productivity/Databases/Servers Obsoletes: postgresql-pl Provides: postgresql-pl:%_libdir/postgresql/plpython.so Requires: python Requires: postgresql-server = %pg_minor_version %description plpython PostgreSQL is an advanced object-relational database management system that supports an extended subset of the SQL standard, including transactions, foreign keys, subqueries, triggers, and user-defined types and functions. This package contains the PL/Python procedural language for PostgreSQL. With this module one can use Python to write stored procedures, functions, and triggers. %package pltcl License: BSD3c(or similar) Summary: PL/Tcl Procedural Language for PostgreSQL Group: Productivity/Databases/Tools Obsoletes: postgresql-pl Provides: postgresql-pl:%_libdir/postgresql/pltcl.so Requires: tcl Requires: postgresql-server = %pg_minor_version %description pltcl PostgreSQL is an advanced object-relational database management system that supports an extended subset of the SQL standard, including transactions, foreign keys, subqueries, triggers, and user-defined types and functions. This package contains the PL/Tcl procedural language for PostgreSQL. With thie module one can use Tcl to write stored procedures, functions, and triggers. %prep %setup -q %patch1 %patch2 # apply the following patch only on SLE10 %if 0%{?suse_version} == 1010 %patch3 -p1 %endif %patch4 %build export CFLAGS="%optflags $SP" # uncomment the following line to enable the stack protector # CFLAGS="$CFLAGS -fstack-protector" %configure \ --includedir=%_includedir/pgsql \ --datadir=%_datadir/postgresql \ --docdir=%_docdir \ --disable-rpath \ --enable-nls \ --enable-thread-safety \ --enable-integer-datetimes \ --with-python \ --with-perl \ --with-tcl \ --with-tclconfig=%_libdir \ --with-openssl \ --with-pam \ --with-ldap \ %if 0%{?suse_version} > 910 --with-gssapi \ --with-libxml \ --with-libxslt \ --with-krb5 \ %endif --with-system-tzdata=/usr/share/zoneinfo make %{?jobs:-j%jobs} world # %ifnarch %arm %if 0%{?suse_version} > 910 %check # # Run the regression tests. # make check || { for f in src/test/regress/log/* regression.diffs; do if test -f $f; then cat $f fi done exit 1 } %endif %endif %install make DESTDIR=%buildroot install install-docs # Don't ship static libraries, libpgport.a is needed, though. rm %buildroot/%_libdir/{libecpg,libecpg_compat,libpgtypes,libpq}.a # # Install and collect the contrib stuff # touch flag; sleep 1 # otherwise we have installed files that are not newer than flag make DESTDIR=%buildroot -C contrib install find %buildroot -type f -cnewer flag -printf "/%%P\n" | grep -v %_docdir > files.contrib rm flag for f in /etc/init.d /var/adm/fillup-templates /usr/sbin \ /etc/sysconfig/SuSEfirewall2.d/services do install -d %buildroot/$f done install -m 755 %{SOURCE9} %buildroot/etc/init.d/postgresql install -m 644 %{SOURCE8} %buildroot/var/adm/fillup-templates/sysconfig.postgresql %if 0%{?suse_version} > 1020 install -m 644 %SOURCE16 %buildroot/etc/sysconfig/SuSEfirewall2.d/services/postgresql %endif ln -s ../../etc/init.d/postgresql %buildroot/usr/sbin/rcpostgresql install -d -m 750 %buildroot/var/lib/pgsql install -d -m 700 %buildroot/var/lib/pgsql/data install -d -m 700 %buildroot/var/lib/pgsql/backups sed 's,@LIBDIR@,%_libdir,g' %{SOURCE15} > \ %buildroot/var/lib/pgsql/.bash_profile # Backup directory for old version binaries install -d %buildroot%_libdir/postgresql/backup cp doc/KNOWN_BUGS doc/MISSING_FEATURES doc/README* COPYRIGHT \ README HISTORY doc/bug.template %buildroot%_docdir/postgresql cp -a %SOURCE2 %buildroot%_docdir/postgresql/README.SuSE.de cp -a %SOURCE3 %buildroot%_docdir/postgresql/README.SuSE.en for appname in pg_dump pgscripts psql;do %find_lang $appname-%{pg_minor_version} %{name}.lang done for libname in libpq5 ecpglib6;do %find_lang $libname-%{pg_minor_version} %{name}-libs.lang done for serverapp in initdb postgres pg_controldata pg_ctl pg_resetxlog plpgsql;do %find_lang $serverapp-%{pg_minor_version} %{name}-server.lang done for develapp in pg_config ecpg;do %find_lang $develapp-%{pg_minor_version} %{name}-devel.lang done for pl in plperl plpython pltcl; do %find_lang $pl-%{pg_minor_version} $pl.lang done %post libs -p /sbin/ldconfig %postun libs -p /sbin/ldconfig %post server %fillup_and_insserv %postun server %restart_on_update postgresql %insserv_cleanup exit 0 %preun server %stop_on_removal postgresql exit 0 %pre server groupadd -g 26 -o -r postgres >/dev/null 2>/dev/null || : useradd -g postgres -o -r -d /var/lib/pgsql -s /bin/bash \ -c "PostgreSQL Server" -u 26 postgres 2>/dev/null || : %clean rm -rf %buildroot rm -f %my_provides %files -f %{name}.lang %defattr(-,root,root) %doc %_mandir/man7/* %docdir %_docdir/postgresql %dir %_docdir/postgresql %_docdir/postgresql/[[:upper:]]* %_docdir/postgresql/bug.template # command line tools %_bindir/createdb %doc %_mandir/man1/createdb.1* %_bindir/clusterdb %doc %_mandir/man1/clusterdb.1* %_bindir/createlang %doc %_mandir/man1/createlang.1* %_bindir/createuser %doc %_mandir/man1/createuser.1* %_bindir/dropdb %doc %_mandir/man1/dropdb.1* %_bindir/droplang %doc %_mandir/man1/droplang.1* %_bindir/dropuser %doc %_mandir/man1/dropuser.1* %_bindir/pg_dump %doc %_mandir/man1/pg_dump.1* %_bindir/pg_dumpall %doc %_mandir/man1/pg_dumpall.1* %_bindir/pg_restore %doc %_mandir/man1/pg_restore.1* %_bindir/psql %doc %_mandir/man1/psql.1* %_bindir/vacuumdb %doc %_mandir/man1/vacuumdb.1* %_bindir/reindexdb %doc %_mandir/man1/reindexdb.1.* %files docs %defattr(-,root,root) %docdir %_docdir/postgresql %dir %_docdir/postgresql %_docdir/postgresql/html %files contrib -f files.contrib %defattr(-,root,root) %docdir %_docdir/postgresql %dir %_docdir/postgresql %_docdir/postgresql/contrib %dir %_libdir/postgresql %dir %_datadir/postgresql %dir %_datadir/postgresql/contrib %files libs -f %{name}-libs.lang %defattr(-,root,root) %_libdir/lib*.so.* %files server -f %{name}-server.lang %defattr(-,root,root) %config /etc/init.d/postgresql %config /var/adm/fillup-templates/sysconfig.postgresql %if 0%{?suse_version} > 1020 %config /etc/sysconfig/SuSEfirewall2.d/services/postgresql %endif %_sbindir/rcpostgresql %dir %_libdir/postgresql %_libdir/postgresql/backup %_libdir/postgresql/plpgsql.so %_libdir/postgresql/dict_snowball.so %_datadir/postgresql/tsearch_data %_bindir/initdb %doc %_mandir/man1/initdb.1* %_bindir/pg_ctl %doc %_mandir/man1/pg_ctl.1* %_bindir/pg_controldata %doc %_mandir/man1/pg_controldata.1* %_bindir/pg_resetxlog %doc %_mandir/man1/pg_resetxlog.1* %_bindir/postgres %doc %_mandir/man1/postgres.1* %_bindir/postmaster %doc %_mandir/man1/postmaster.1* %dir %_datadir/postgresql %_datadir/postgresql/timezone* %_datadir/postgresql/*.* %exclude %_datadir/postgresql/*.pltcl %_libdir/postgresql/*_and_*.so %_libdir/postgresql/euc2004_sjis2004.so %_libdir/postgresql/libpqwalreceiver.so %attr(750,postgres,postgres) %dir /var/lib/pgsql %attr(700,postgres,postgres) %dir /var/lib/pgsql/data %attr(700,postgres,postgres) %dir /var/lib/pgsql/backups %attr(640,postgres,postgres) %config(noreplace) /var/lib/pgsql/.bash_profile %files devel -f %{name}-devel.lang %defattr(-,root,root) %_includedir/pgsql %_bindir/ecpg %_bindir/pg_config %_libdir/lib*.so %_libdir/libpgport.a %_libdir/postgresql/pgxs %doc %_mandir/man1/ecpg.1* %doc %_mandir/man1/pg_config.1* %doc %_mandir/man3/* %files pltcl -f pltcl.lang %defattr(-,root,root) %dir %_libdir/postgresql %_libdir/postgresql/pltcl.so %_datadir/postgresql/*.pltcl %_bindir/pltcl* %files plperl -f plperl.lang %defattr(-,root,root) %dir %_libdir/postgresql %_libdir/postgresql/plperl.so %files plpython -f plpython.lang %defattr(-,root,root) %dir %_libdir/postgresql %_libdir/postgresql/plpython*.so %changelog