]> git.pld-linux.org Git - packages/perl.git/blobdiff - perl.spec
d41edb020c64e4f5dbafabab42f82edd perl-CPAN-1.50.patch
[packages/perl.git] / perl.spec
index 8559226a6dfc20e5ab9bd9b63d8cb374fb815e56..b629224c2083b6b4637278527783663152a9b1a9 100644 (file)
--- a/perl.spec
+++ b/perl.spec
@@ -1,67 +1,82 @@
-%define                perlver 5.005
-%define                perlrel 03
-%define                perlthread -thread
-
+%define        __find_provides %{_builddir}/%{name}-%{version}/find-perl-provides
+%define                perlthread      -thread-multi
 Summary:       Practical Extraction and Report Language
 Summary(de):   Praktische Extraktions- und Berichtsprache 
 Summary(fr):   Practical Extraction and Report Language (Perl)
 Summary(pl):   Practical Extraction and Report Language (Perl)
 Summary(tr):   Kabuk yorumlama dili
 Name:          perl
-Version:       %{perlver}_%{perlrel}
-Release:       4
-Copyright:     GPL
+Version:       5.6.0
+Release:       1
+Epoch:         1
+License:       GPL
 Group:         Utilities/Text
+Group(fr):     Utilitaires/Texte
 Group(pl):     Narzêdzia/Tekst
-Source:                ftp://ftp.perl.org/pub/perl/CPAN/src/5.0/%{name}%{version}.tar.gz
+Source:                ftp://ftp.perl.org/pub/perl/CPAN/src/%{name}-%{version}.tar.gz
 Patch0:                perl-noroot_install.patch
-Patch1:                perl-db1.patch
+Patch1:                perl-nodb.patch
+Patch2:                perl-DESTDIR.patch
+Patch3:                perl-CPAN-1.54.patch
+Patch4:                perl-find-provides.patch
+Patch5:                perl-prereq.patch
+Patch6:                perl-syslog.patch
 URL:           http://www.perl.org/
-Requires:      csh
-Buildroot:     /tmp/%{name}-%{version}-root
+#Requires:     csh
+Obsoletes:     perl-ANSIColor
+Obsoletes:     perl-Devel-Peek
+Obsoletes:     perl-DProf
+Obsoletes:     perl-PodParser
+BuildRoot:     %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
 
 %description
 Perl is an interpreted language optimized for scanning arbitrary text
-files, extracting information from those text files, and printing reports
-based on that information.  It's also a good language for many system
-management tasks.  The language is intended to be practical (easy to use,
-efficient, complete) rather than beautiful (tiny, elegant, minimal).
+files, extracting information from those text files, and printing
+reports based on that information. It's also a good language for many
+system management tasks. The language is intended to be practical
+(easy to use, efficient, complete) rather than beautiful (tiny,
+elegant, minimal).
 
 This version has support for threads compiled in.
 
 %description -l de
-Perl ist eine Interpreter-Sprache, die zum Durchsuchen beliebiger Text-
-dateien, Extrahieren von Informationen aus diesen Dateien und Drucken von
-auf diesen Informationen basierenden Berichten optimiert ist. Die Sprache
-eignet sich außerdem für viele Systemverwaltungsaufgaben. Sie ist eher 
-praktisch (einfache Anwendung,effizient, vollständig) als schön (winzig,
-elegant, minimal).
+Perl ist eine Interpreter-Sprache, die zum Durchsuchen beliebiger
+Text- dateien, Extrahieren von Informationen aus diesen Dateien und
+Drucken von auf diesen Informationen basierenden Berichten optimiert
+ist. Die Sprache eignet sich außerdem für viele
+Systemverwaltungsaufgaben. Sie ist eher praktisch (einfache
+Anwendung,effizient, vollständig) als schön (winzig, elegant,
+minimal).
 
 %description -l fr
-Perl est un langage interprété, optimisé pour filtrer des fichiers texte,
-extraire des informations de ces fichiers, et imprimer des rapports basés
-sur ces informations. C'est aussi un bon langage pour de nombreuses procédures
-de gestion système. Ce langage se veut pratique (simple à utiliser, efficace,
-complet) autant qu'agréable (conscrit, élégant, minimal).
+Perl est un langage interprété, optimisé pour filtrer des fichiers
+texte, extraire des informations de ces fichiers, et imprimer des
+rapports basés sur ces informations. C'est aussi un bon langage pour
+de nombreuses procédures de gestion système. Ce langage se veut
+pratique (simple à utiliser, efficace, complet) autant qu'agréable
+(conscrit, élégant, minimal).
 
 %description -l pl
-Perl jest jêzykiem przeznaczonym do skanowania plików tekstowych, wyci±gania
-z nich informacji i drukowania raportu bazuj±cego na tych informacjach. Jest
-równie¿ doskona³ym jêzykiem dla wielu narzêdzi do nadzoru systemu. Jêzyk ten
-jest w zamierzeniu praktycznym (³atwym w u¿yciu, efektywnym, kompletnym) 
-bardziej ni¿ piêkny ;) (skromny, elegancki, minimalny).
+Perl jest jêzykiem przeznaczonym do skanowania plików tekstowych,
+wyci±gania z nich informacji i drukowania raportu bazuj±cego na tych
+informacjach. Jest równie¿ doskona³ym jêzykiem dla wielu narzêdzi do
+nadzoru systemu. Jêzyk ten jest w zamierzeniu praktycznym (³atwym w
+u¿yciu, efektywnym, kompletnym) bardziej ni¿ piêkny ;) (skromny,
+elegancki, minimalny).
 
 %description -l tr
-Perl, metin dosyalarýný taramak, bu metin dosyalarýndan bilgi çýkarmak ve
-bu bilgiye dayalý raporlar hazýrlamak icin geliþtirilmiþ bir yorumlamalý
-dildir. Ayrýca pek çok sistem yönetimi görevleri için de yararlý yetenekleri
-vardýr. Perl, güzel (ufak, zarif, minimum) olmaktan çok, pratik olmaya
-yönelik (kullanýmý kolay, verimli, eksiksiz) olarak tasarlanmýþtýr.
-
-%package -n    sperl
+Perl, metin dosyalarýný taramak, bu metin dosyalarýndan bilgi çýkarmak
+ve bu bilgiye dayalý raporlar hazýrlamak icin geliþtirilmiþ bir
+yorumlamalý dildir. Ayrýca pek çok sistem yönetimi görevleri için de
+yararlý yetenekleri vardýr. Perl, güzel (ufak, zarif, minimum)
+olmaktan çok, pratik olmaya yönelik (kullanýmý kolay, verimli,
+eksiksiz) olarak tasarlanmýþtýr.
+
+%package -n sperl
 Summary:       Practical Extraction and Report Language (SUID root binary)
 Summary(pl):   Practical Extraction and Report Language (SUID root binaria)
 Group:         Utilities/Text
+Group(fr):     Utilitaires/Texte
 Group(pl):     Narzêdzia/Tekst
 Requires:      %{name} = %{version}
 
@@ -72,16 +87,27 @@ Practical Extraction and Report Language (SUID root binary).
 Practical Extraction and Report Language (SUID root binaria).
 
 %prep
-%setup  -q -n %{name}%{version}
+%setup  -q
 %patch0 -p1
 %patch1 -p1
+%patch2 -p1
+%patch3 -p1
+%patch4 -p1
+%patch5 -p1
+%patch6 -p1
+
+for i in find-* ; do
+       mv $i $i.old
+       sed "s|FPPATH|%{_builddir}/%{name}-%{version}|g" < $i.old > $i
+       chmod 755 $i; rm -f $i.old
+done
 
 %build
 # this is gross
 cat > config.over <<EOF
-installprefix=$RPM_BUILD_ROOT/usr
-test -d \$installprefix || mkdir \$installprefix
-test -d \$installprefix/bin || mkdir \$installprefix/bin
+installprefix=$RPM_BUILD_ROOT%{_prefix}
+test -d \$installprefix || mkdir -p \$installprefix
+test -d \$installprefix/bin || mkdir -p \$installprefix/bin
 installarchlib=\`echo \$installarchlib | sed "s!\$prefix!\$installprefix!"\`
 installbin=\`echo \$installbin | sed "s!\$prefix!\$installprefix!"\`
 installman1dir=\`echo \$installman1dir | sed "s!\$prefix!\$installprefix!"\`
@@ -94,21 +120,24 @@ EOF
 
 sh Configure \
        -des \
-       -Darchname=%{_target} \
-       -Dprefix=/usr \
+       -Dcc=gcc \
+       -Darchname=%{_target_platform} \
+       -Dprefix=%{_prefix} \
+       -Dscriptdir=%{_bindir} \
        -Dman1dir=%{_mandir}/man1 \
        -Dman3dir=%{_mandir}/man3 \
        -Dman3ext=3pm \
        -Doptimize="$RPM_OPT_FLAGS" \
        -Duseshrplib \
        -Dusethreads \
+       -Uuselargefiles \
        -Dd_dosuid \
        -Ud_setresuid \
        -Ud_setresgid 
 
-make
+%{__make}
 
-# Strip binaries (done now rather than at install)
+## Strip binaries (done now rather than at install)
 
 strip {perl,suidperl,x2p/a2p}
 
@@ -116,31 +145,57 @@ strip {perl,suidperl,x2p/a2p}
 rm -rf $RPM_BUILD_ROOT
 install -d $RPM_BUILD_ROOT
 
-make install
-install utils/pl2pm $RPM_BUILD_ROOT/usr/bin/pl2pm
+%{__make} install
+install utils/pl2pm $RPM_BUILD_ROOT%{_bindir}/pl2pm
+
+## Generate *.ph files with a trick (based on RH).
 
+%{__make} all -f - <<EOF
+PKGS   = glibc-devel gdbm-devel gpm-devel libgr-devel libjpeg-devel \
+       libpng-devel libtiff-devel ncurses-devel popt-devel \
+       zlib-devel binutils libelf e2fsprogs-devel pam-devel pwdb-devel \
+       rpm-devel
+STDH   = \$(filter /usr/include/%%, \$(shell rpm -q --queryformat '[%%{FILENAMES}\n]' \$(PKGS)))
+STDH   += \$(wildcard /usr/include/linux/*.h) \$(wildcard /usr/include/asm/*.h) \$(wildcard /usr/include/scsi/*.h)
+GCCDIR = \$(shell gcc --print-file-name include)
+GCCH    = \$(filter \$(GCCDIR)/%%, \$(shell rpm -q --queryformat '[%%{FILENAMES}\n]' gcc))
 
-(cd /usr/include ;
-PERL5LIB=$RPM_BUILD_ROOT/usr/lib/perl5 $RPM_BUILD_ROOT/usr/bin/perl \
-$RPM_BUILD_ROOT/usr/lib/perl5/%{perlver}%{perlrel}/%{_target}%{perlthread} \
-$RPM_BUILD_ROOT/usr/bin/h2ph \
--d $RPM_BUILD_ROOT/usr/lib/perl5/%{_target}/%{perlver}%{perlrel}/ \
-*.h sys/*.h linux/*.h asm/*.h net/*.h netinet/*.h arpa/*.h )
+LIBPATH = %{_builddir}/%{name}-%{version}
+PERLLIB = $RPM_BUILD_ROOT%{_libdir}/perl5/%{version}
+PERLBIN = $RPM_BUILD_ROOT%{_bindir}/perl
+PERL   = LD_LIBRARY_PATH=\$(LIBPATH) PERL5LIB=\$(PERLLIB) \$(PERLBIN)
+PHDIR  = \$(PERLLIB)/%{_target_platform}%{perlthread}
+PHBIN  = $RPM_BUILD_ROOT%{_bindir}/h2ph
+H2PH   = \$(PERL) \$(PHBIN) -d \$(PHDIR)/
 
-( cd $RPM_BUILD_ROOT/usr/lib/perl5/%{perlver}%{perlrel}/%{_target}%{perlthread}/
+all: std-headers gcc-headers
 
-mv .packlist .packlist.old
-sed "s|$RPM_BUILD_ROOT||g" < .packlist.old > .packlist
-rm -f .packlist.old
+std-headers: \$(STDH)
+       cd /usr/include && \$(H2PH) \$(STDH:/usr/include/%%=%%)
 
-mv Config.pm Config.pm.old
-sed "s|$RPM_BUILD_ROOT||g" < Config.pm.old > Config.pm
-rm -f Config.pm.old )
+gcc-headers: \$(GCCH)
+       cd \$(GCCDIR) && \$(H2PH) \$(GCCH:\$(GCCDIR)/%%=%%)
 
-gzip -9fn $RPM_BUILD_ROOT%{_mandir}/man*/* \
+EOF
+
+## Fix paths
+(
+cd $RPM_BUILD_ROOT%{_libdir}/perl5/%{version}/%{_target_platform}%{perlthread}
+sed -e "s|$RPM_BUILD_ROOT||g" < Config.pm > Config.pm.new
+mv -f Config.pm.new Config.pm
+sed -e "s|$RPM_BUILD_ROOT||g" < .packlist > .packlist.new
+mv -f .packlist.new .packlist
+)
+
+## Fix permissions
+find $RPM_BUILD_ROOT%{_libdir}/perl5 -name \*.ph -exec chmod 444 {} \;
+find $RPM_BUILD_ROOT%{_libdir}/perl5 -type d -exec chmod 755 {} \;
+
+gzip -9nf $RPM_BUILD_ROOT%{_mandir}/man*/* \
        README Change*
 
-find $RPM_BUILD_ROOT/usr/lib/perl5 -name \*.so -exec strip --strip-unneeded {} \;
+find $RPM_BUILD_ROOT%{_libdir}/perl5 -name \*.so \
+       -exec strip --strip-unneeded {} \;
 
 %clean
 rm -rf $RPM_BUILD_ROOT
@@ -149,71 +204,32 @@ rm -rf $RPM_BUILD_ROOT
 %defattr(644,root,root,755)
 %doc README.gz Change*
 
-%attr(755,root,root) /usr/bin/a2p
-%attr(755,root,root) /usr/bin/c2ph
-%attr(755,root,root) /usr/bin/find2perl
-%attr(755,root,root) /usr/bin/h2ph
-%attr(755,root,root) /usr/bin/h2xs
-%attr(755,root,root) /usr/bin/perl
-%attr(755,root,root) /usr/bin/perl%{perlver}%{perlrel}
-%attr(755,root,root) /usr/bin/perlbug
-%attr(755,root,root) /usr/bin/perlcc
-%attr(755,root,root) /usr/bin/perldoc
-%attr(755,root,root) /usr/bin/pl2pm
-%attr(755,root,root) /usr/bin/pod2html
-%attr(755,root,root) /usr/bin/pod2latex
-%attr(755,root,root) /usr/bin/pod2man
-%attr(755,root,root) /usr/bin/pod2text
-%attr(755,root,root) /usr/bin/pstruct
-%attr(755,root,root) /usr/bin/s2p
-%attr(755,root,root) /usr/bin/splain
-
-%dir /usr/lib/perl5
-%attr( - ,root,root) /usr/lib/perl5/*
+%attr(755,root,root) %{_bindir}/a2p
+%attr(755,root,root) %{_bindir}/c2ph
+%attr(755,root,root) %{_bindir}/find2perl
+%attr(755,root,root) %{_bindir}/h2ph
+%attr(755,root,root) %{_bindir}/h2xs
+%attr(755,root,root) %{_bindir}/perl
+%attr(755,root,root) %{_bindir}/perl%{version}
+%attr(755,root,root) %{_bindir}/perlbug
+%attr(755,root,root) %{_bindir}/perlcc
+%attr(755,root,root) %{_bindir}/perldoc
+%attr(755,root,root) %{_bindir}/pl2pm
+%attr(755,root,root) %{_bindir}/pod2html
+%attr(755,root,root) %{_bindir}/pod2latex
+%attr(755,root,root) %{_bindir}/pod2man
+%attr(755,root,root) %{_bindir}/pod2text
+%attr(755,root,root) %{_bindir}/pstruct
+%attr(755,root,root) %{_bindir}/s2p
+%attr(755,root,root) %{_bindir}/splain
+
+%dir %{_libdir}/perl5
+%attr( - ,root,root) %{_libdir}/perl5/*
+#%dir %{_libdir}/site_perl
+#%attr( - ,root,root) %{_libdir}/site_perl/*
 %{_mandir}/man[13]/*
 
 %files -n sperl
-%attr(4755,root,root) /usr/bin/sperl%{perlver}%{perlrel}
-%attr(4755,root,root) /usr/bin/suidperl
-
-%changelog
-* Sun May  9 1999 Piotr Czerwiñski <pius@pld.org.pl>
-  [5.005_03-4]
-- FHS 2.0 compliant changes.
-
-* Wed Apr 28 1999 Artur Frysiak <wiget@pld.org.pl>
-  [5.005_03-3]
-- added db1 patch from RH 6.0
-
-* Tue Apr 20 1999 Artur Frysiak <wiget@pld.org.pl>
-  [5.005_03-2]
-- updated to 5.005_03
-- changed source URL
-- added -Dman3dir=%{_mandir}/man3 -Dman3ext=3pm -Duseshrplib to Configure
-- corrected .packlist
-- changed --strip-debug to --strip-unneeded
-- gzipped %doc (instead bzipping2)
-- commpiled on rpm 3
-
-* Mon Oct 26 1998 Tomasz K³oczko <kloczek@rudy.mif.pg.gda.pl>
-  [5.005_02-2]
-- added using $RPM_OPT_FLAGS during compile,
-- added stripping modules,
-- added URL,
-- added sperl subpackage with suid perl binaries.
-
-* Tue Sep 15 1998 Wojtek ¦lusarczyk <wojtek@shadow.eu.org>
-  [5.005_02-1]
-- updated to 5.005_02
-  (based on Ian Macdonald <ianmacd@xs4all.nl> spec files),
-- install -d instead mkdir -p,
-- added %defattr, but It's still unable to build from non root's account,
-- man3 subdirectory moved to %{_mandir}/man3,
-- minor modifications of spec file.   
-
-* Mon Jun 15 1998 Wojtek ¦lusarczyk <wojtek@shadow.eu.org>
-  [5.005_01-1]
-- added pl translation,
-- moved %changelog to end of spec,
-- removed all old patches. 
-- start at RH spec file.
+%defattr(644,root,root,755)
+%attr(4755,root,root) %{_bindir}/sperl%{version}
+%attr(4755,root,root) %{_bindir}/suidperl
This page took 0.066678 seconds and 4 git commands to generate.