# # spec file for package phpPgAdmin # # Copyright (c) 2011 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: phpPgAdmin %define apxs %{_sbindir}/apxs2 %define ap_sysconfdir %(%{apxs} -q SYSCONFDIR) %define ap_serverroot %(%{apxs} -q PREFIX) %define ap_docroot %(%{apxs} -q PREFIX)/htdocs %define ppa_config %{_sysconfdir}/%{name}/config.inc.php Summary: Administration of PostgreSQL over the web Version: 5.0.2 Release: 1 License: GPLv2+ Group: Productivity/Databases/Tools Url: http://phppgadmin.sourceforge.net Source0: %{name}-%{version}.tar.bz2 Source1: %{name}.http Patch0: %{name}-4.2.3-config.inc.patch BuildArch: noarch BuildRoot: %{_tmppath}/%{name}-%{version}-build BuildRequires: apache2-devel Requires: mod_php_any php-pgsql %description phpPgAdmin is a web-based administration tool for PostgreSQL. It is perfect for PostgreSQL DBAs, newbies and hosting services. Features * Administer multiple servers * Support for PostgreSQL 7.4.x, 8.0.x, 8.1.x, 8.2.x, 8.3.x, 8.4.x, 9.0.x * Manage all aspects of: o Users & groups o Databases o Schemas o Tables, indexes, constraints, triggers, rules & privileges o Views, sequences & functions o Advanced objects o Reports * Easy data manipulation: o Browse tables, views & reports o Execute arbitrary SQL o Select, insert, update and delete * Dump table data in a variety of formats: SQL, COPY, XML, XHTML, CSV, Tabbed, pg_dump * Import SQL scripts, COPY data, XML, CSV and Tabbed * Supports the Slony master-slave replication engine * Excellent language support: o Available in 27 languages o No encoding conflicts. Edit Russian data using a Japanese interface! %prep %setup -q %patch0 -p1 %build %install %{__install} -d %{buildroot}%{ap_docroot}/%{name} %{__cp} -dR *.php *.js classes help images lang libraries sql themes xloadtree \ %{buildroot}%{ap_docroot}/%{name} # install config to config dir %{__install} -D -m0640 conf/config.inc.php-dist \ %{buildroot}%{ppa_config} # install config for apache %{__install} -D -m0644 %{S:1} %{buildroot}%{ap_sysconfdir}/conf.d/%{name}.conf # fix paths in http config %{__sed} -i -e "s,@ap_docroot@,%{ap_docroot},g" -e "s,@name@,%{name},g" \ -e "s,@docdir@,%{_docdir},g" %{buildroot}%{ap_sysconfdir}/conf.d/%{name}.conf # remove not needed files from lang/ for i in Makefile convert.awk langcheck php2po po2php synch; do %{__rm} -f %{buildroot}%{ap_docroot}/%{name}/lang/${i} done # remove not needed files %{__rm} %{buildroot}%{ap_docroot}/%{name}/build_tests.php %postun %restart_on_update apache2 %clean %{__rm} -rf %{buildroot} %files %defattr(0644,root,root,0755) %doc CREDITS DEVELOPERS FAQ HISTORY INSTALL LICENSE TODO TRANSLATORS %{ap_docroot}/%{name} %config(noreplace) %{ap_sysconfdir}/conf.d/%{name}.conf %dir %attr(0750,wwwrun,root) %{_sysconfdir}/%{name} %config(noreplace) %attr(0640,root,www) %{ppa_config} %changelog