packages: php-phpdocs-pman/php-phpdocs-pman.spec - use own man dir, man pag...

glen glen at pld-linux.org
Sun Jul 31 12:51:55 CEST 2011


Author: glen                         Date: Sun Jul 31 10:51:55 2011 GMT
Module: packages                      Tag: HEAD
---- Log message:
- use own man dir, man pages conflict with too many system packages

---- Files affected:
packages/php-phpdocs-pman:
   php-phpdocs-pman.spec (1.1 -> 1.2) 

---- Diffs:

================================================================
Index: packages/php-phpdocs-pman/php-phpdocs-pman.spec
diff -u packages/php-phpdocs-pman/php-phpdocs-pman.spec:1.1 packages/php-phpdocs-pman/php-phpdocs-pman.spec:1.2
--- packages/php-phpdocs-pman/php-phpdocs-pman.spec:1.1	Sun Jul 31 12:34:14 2011
+++ packages/php-phpdocs-pman/php-phpdocs-pman.spec	Sun Jul 31 12:51:50 2011
@@ -1,13 +1,11 @@
 # $Revision$, $Date$
-# TODO
-# - fix rpm destroying symlinks and keep pman as symlink not shell wrapper
 %define		status		stable
 %define		pearname	pman
 %include	/usr/lib/rpm/macros.php
 Summary:	%{pearname} - PHP Unix manual pages
 Name:		php-phpdocs-pman
 Version:	2011.06.25
-Release:	1
+Release:	2
 License:	Creative Commons Attribution 3.0
 Group:		Development/Languages/PHP
 Source0:	http://doc.php.net/get/%{pearname}-%{version}.tgz
@@ -21,10 +19,10 @@
 Requires:	man
 Requires:	php-channel(doc.php.net)
 Requires:	php-pear
-Requires:	php-zlib
 BuildArch:	noarch
 BuildRoot:	%{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
+%define		_phpdocdir	%{_docdir}/phpdoc
 
 %description
 Unix manual pages of the PHP documentations from php.net.
@@ -32,15 +30,11 @@
 In PEAR status of this package is: %{status}.
 
 %prep
-%pear_package_setup
-
-# we install to system dir, no need for wrapper
-# XXX rpm converts this symlink to file F@#@$ in some __post_ scriptlets
-#ln -snf %{_bindir}/man .%{_bindir}/pman
+%pear_package_setup -d doc_dir=%{_phpdocdir}
 
 cat <<'EOF' >.%{_bindir}/pman
-#!/bin/sh
-exec %{_bindir}/man "$@"
+!/bin/sh
+exec %{_bindir}/man -M %{_phpdocdir}/pman "$@"
 EOF
 
 %build
@@ -48,10 +42,10 @@
 
 %install
 rm -rf $RPM_BUILD_ROOT
-install -d $RPM_BUILD_ROOT{%{php_pear_dir},%{_bindir},%{_mandir}}
+install -d $RPM_BUILD_ROOT{%{php_pear_dir},%{_bindir},%{_phpdocdir}}
 cp -a ./%{php_pear_dir}/.registry $RPM_BUILD_ROOT%{php_pear_dir}
 
-cp -a docs/pman/*  $RPM_BUILD_ROOT%{_mandir}
+cp -a ./%{_phpdocdir}/pman  $RPM_BUILD_ROOT%{_phpdocdir}
 
 install -d $RPM_BUILD_ROOT{%{_bindir},%{php_pear_dir}}
 install -p ./%{_bindir}/* $RPM_BUILD_ROOT%{_bindir}
@@ -64,7 +58,9 @@
 %doc ChangeLog install.log
 %{php_pear_dir}/.registry/.channel.*/*.reg
 %attr(755,root,root) %{_bindir}/pman
-%{_mandir}/man3/*.3*
+%dir %{_phpdocdir}/pman
+%dir %{_phpdocdir}/pman/man3
+%{_phpdocdir}/pman/man3/*.3*
 
 %define date	%(echo `LC_ALL="C" date +"%a %b %d %Y"`)
 %changelog
@@ -72,5 +68,8 @@
 All persons listed below can be reached at <cvs_login>@pld-linux.org
 
 $Log$
+Revision 1.2  2011/07/31 10:51:50  glen
+- use own man dir, man pages conflict with too many system packages
+
 Revision 1.1  2011/07/31 10:34:14  glen
 - initial package, maybe should package manuals for each extension to subpackages?
================================================================

---- CVS-web:
    http://cvs.pld-linux.org/cgi-bin/cvsweb.cgi/packages/php-phpdocs-pman/php-phpdocs-pman.spec?r1=1.1&r2=1.2&f=u



More information about the pld-cvs-commit mailing list