| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190 |
- ##
- ## perl59.spec -- OpenPKG RPM Package Specification
- ## Copyright (c) 2000-2007 OpenPKG Foundation e.V. <http://openpkg.net/>
- ## Copyright (c) 2000-2007 Ralf S. Engelschall <http://engelschall.com/>
- ##
- ## Permission to use, copy, modify, and distribute this software for
- ## any purpose with or without fee is hereby granted, provided that
- ## the above copyright notice and this permission notice appear in all
- ## copies.
- ##
- ## THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
- ## WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
- ## MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- ## IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR
- ## CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
- ## SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
- ## LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
- ## USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
- ## ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
- ## OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
- ## OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
- ## SUCH DAMAGE.
- ##
- # package information
- Name: perl59
- Summary: Practical Extraction and Reporting Language
- URL: http://www.perl.com/
- Vendor: The Perl Project
- Packager: OpenPKG Foundation e.V.
- Distribution: OpenPKG Community
- Class: EVAL
- Group: Perl
- License: GPL/Artistic
- Version: 5.9.5
- Release: 20070719
- # package options
- %option with_perl no
- # list of sources
- Source0: ftp://ftp.cpan.org/pub/CPAN/src/perl-%{version}.tar.gz
- Patch0: perl59.patch
- # build information
- Prefix: %{l_prefix}
- BuildRoot: %{l_buildroot}
- BuildPreReq: OpenPKG, openpkg >= 20040130, gcc
- PreReq: OpenPKG, openpkg >= 20040130
- AutoReq: no
- AutoReqProv: no
- %if "%{with_perl}" == "yes"
- Provides: perl = %{version}-%{release}
- %endif
- %description
- Perl ("Practical Reporting and Extraction Language") is a very
- sophisticated and flexible (but this way also complex) programming
- language. This is the original implementation of the Perl 5
- interpreter from Larry Wall and his community.
- ATTENTION: THIS IS THE DEVELOPMENT SERIES OF PERL 5!
- IT IS NOT INTENDED FOR PRODUCTION USE. USE IT ON YOUR OWN RISK.
- %track
- prog perl59 = {
- version = %{version}
- url = ftp://ftp.cpan.org/pub/CPAN/src/
- regex = perl-(5\.9\.\d+)\.tar\.gz
- }
- %prep
- %setup -q -n perl-%{version}
- %patch -p0
- chmod -R u+w .
- %build
- # configure the Perl package
- %{l_shtool} subst \
- -e 's;\(.*for thislib in $libswanted.*\);libswanted=`echo " $libswanted " | sed -e "s/ bind / /g" -e "s/ db / /g" -e "s/ gdbm / /g" -e "s/ iconv / /g"`\; \1;' \
- -e 's;package=perl5;package=perl;' \
- Configure
- %{l_shtool} subst \
- -e 's; */usr/local/lib;;' \
- hints/freebsd.sh hints/netbsd.sh
- case "%{l_platform -t}" in
- amd64-* ) optimize="%{l_cflags}" ;;
- *-aix* ) optimize="%{l_cflags}" ;;
- *-* ) optimize="%{l_cflags -O}" ;;
- esac
- ./Configure \
- -d -e -s \
- -Dprefix=%{l_prefix} \
- -Dvendorprefix=%{l_prefix} \
- -Dinstallprefix=%{l_prefix} \
- -Dinstallstyle="lib/perl5" \
- -Dman1dir=%{l_prefix}/man/man1 \
- -Dman3dir=%{l_prefix}/man/man3 \
- -Dcc="%{l_cc}" -Doptimize="$optimize" \
- -Dlocincpth="%{l_prefix}/include" \
- -Dloclibpth="%{l_prefix}/lib" \
- -Dldflags="%{l_ldflags}" \
- -Dlibpth="%{l_prefix}/lib /lib /usr/lib /usr/ccs/lib" \
- -Dglibpth="%{l_prefix}/lib /lib /usr/lib /usr/ccs/lib" \
- -Dscriptdir="%{l_prefix}/bin" \
- -Uinstallusrbinperl \
- -Ui_malloc -Ui_iconv -Ui_db \
- -Dusedevel
- # build the Perl package
- %{l_make} %{l_mflags} -f Makefile
- %install
- rm -rf $RPM_BUILD_ROOT
- # install the Perl package via standard procedure
- %{l_make} %{l_mflags} -f Makefile install DESTDIR=$RPM_BUILD_ROOT
- # install Perl versions of system header files
- ( case "%{l_platform -t}" in
- *-darwin* ) export DYLD_LIBRARY_PATH="`pwd`" ;;
- esac
- cd /usr/include
- PERL5LIB=$RPM_BUILD_ROOT%{l_prefix}/lib/perl
- export PERL5LIB
- eval `$RPM_BUILD_ROOT%{l_prefix}/bin/perl -V:installarchlib`
- echo *.h sys/*.h |\
- xargs $RPM_BUILD_ROOT%{l_prefix}/bin/perl%{version} \
- $RPM_BUILD_ROOT%{l_prefix}/bin/h2ph%{version} -h -d $RPM_BUILD_ROOT$installarchlib
- ) || exit $?
- # post-adjustments to installation tree
- rm -rf $RPM_BUILD_ROOT%{l_prefix}/man/man3
- for name in \
- libnetcfg perlaix perlamiga perlapollo \
- perlbeos perlbs2000 perlcygwin perldgux perlepoc perlfreebsd perlhpux \
- perlhurd perlirix perlmachten perlmacos perlmacosx perlmint perlmpeix \
- perlnetware perlos2 perlos390 perlos400 perlplan9 perlqnx perlsolaris \
- perlvmesa perlvms perlvos perlwin32; do
- rm -f $RPM_BUILD_ROOT%{l_prefix}/man/man1/$name.1
- done
- # re-adjust configuration as mentioned in Perl's INSTALL document
- ( case "%{l_platform -t}" in
- *-darwin* ) export DYLD_LIBRARY_PATH="`pwd`" ;;
- esac
- $RPM_BUILD_ROOT%{l_prefix}/bin/perl%{version} -pi.orig \
- -e "s:$RPM_BUILD_ROOT%{l_prefix}:%{l_prefix}:g" \
- $RPM_BUILD_ROOT%{l_prefix}/lib/perl/%{version}/*/Config.pm \
- `find $RPM_BUILD_ROOT%{l_prefix}/lib/perl/%{version}/ \
- -type f -name ".packlist" -print`
- find $RPM_BUILD_ROOT%{l_prefix}/lib/perl/ \
- -name "*.orig" -print | xargs rm -f
- ) || exit $?
- # strip binary files
- strip $RPM_BUILD_ROOT%{l_prefix}/bin/* 2>/dev/null || true
- # resolve file conflicts (with perl-locale)
- rm -f $RPM_BUILD_ROOT%{l_prefix}/bin/enc2xs \
- $RPM_BUILD_ROOT%{l_prefix}/bin/piconv
- # resolve filename conflicts
- %if "%{with_perl}" == "yes"
- ( cd $RPM_BUILD_ROOT%{l_prefix}/bin
- for file in *; do
- [ ".$file" = ".*" ] && continue
- mv ${file} `echo ${file} | sed -e 's;%{version}$;;'`
- done
- ) || exit $?
- %else
- ln $RPM_BUILD_ROOT%{l_prefix}/bin/perl%{version} \
- $RPM_BUILD_ROOT%{l_prefix}/bin/perl59
- ( cd $RPM_BUILD_ROOT%{l_prefix}/man/man1
- for file in *; do
- [ ".$file" = ".*" ] && continue
- mv ${file} `echo ${file} | sed -e 's;^\([^.]*\)\(\..*\)$;\1%{version}\2;'`
- done
- ) || exit $?
- %endif
- # determine installed files
- %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT %{l_files_std}
- %files -f files
- %clean
- rm -rf $RPM_BUILD_ROOT
|