]> git.pld-linux.org Git - packages/perl.git/blob - perl.spec
- updated to 5.6.1
[packages/perl.git] / perl.spec
1 %define         __find_provides %{_builddir}/%{name}-%{version}/find-perl-provides
2 %define         perlthread %{?bcond_on_perl_threads:-thread-multi}
3 Summary:        Practical Extraction and Report Language
4 Summary(de):    Praktische Extraktions- und Berichtsprache 
5 Summary(fr):    Practical Extraction and Report Language (Perl)
6 Summary(pl):    Practical Extraction and Report Language (Perl)
7 Summary(tr):    Kabuk yorumlama dili
8 Name:           perl
9 Version:        5.6.1
10 Release:        1
11 Epoch:          1
12 License:        GPL
13 Group:          Applications/Text
14 Group(de):      Applikationen/Text
15 Group(fr):      Utilitaires/Texte
16 Group(pl):      Aplikacje/Tekst
17 Source0:        ftp://ftp.perl.org/pub/perl/CPAN/src/%{name}-%{version}.tar.gz
18 Patch0:         %{name}-noroot_install.patch
19 Patch1:         %{name}-nodb.patch
20 Patch2:         %{name}-DESTDIR.patch
21 Patch3:         %{name}-find-provides.patch
22 Patch4:         %{name}-prereq.patch
23 Patch5:         %{name}-syslog.patch
24 Patch6:         %{name}-CGI-upload-tmpdir.patch
25 Patch7:         %{name}-LD_RUN_PATH.patch
26 Patch8:         %{name}-errno_h-parsing.patch
27 Patch9:         %{name}-use-LD_PRELOAD-for-libperl.so.patch
28 URL:            http://www.perl.org/
29 #Requires:      csh
30 Provides:       perl-ANSIColor
31 Provides:       perl-Devel-Peek
32 Provides:       perl-DProf
33 Provides:       perl-PodParser
34 Provides:       perl-CGI
35 Obsoletes:      perl-ANSIColor
36 Obsoletes:      perl-Devel-Peek
37 Obsoletes:      perl-DProf
38 Obsoletes:      perl-PodParser
39 Obsoletes:      perl-CGI
40 BuildRoot:      %{tmpdir}/%{name}-%{version}-root-%(id -u -n)
41
42 %description
43 Perl is an interpreted language optimized for scanning arbitrary text
44 files, extracting information from those text files, and printing
45 reports based on that information. It's also a good language for many
46 system management tasks. The language is intended to be practical
47 (easy to use, efficient, complete) rather than beautiful (tiny,
48 elegant, minimal).
49
50 This version has support for threads compiled in.
51
52 %description -l de
53 Perl ist eine Interpreter-Sprache, die zum Durchsuchen beliebiger
54 Text- dateien, Extrahieren von Informationen aus diesen Dateien und
55 Drucken von auf diesen Informationen basierenden Berichten optimiert
56 ist. Die Sprache eignet sich außerdem für viele
57 Systemverwaltungsaufgaben. Sie ist eher praktisch (einfache
58 Anwendung,effizient, vollständig) als schön (winzig, elegant,
59 minimal).
60
61 %description -l fr
62 Perl est un langage interprété, optimisé pour filtrer des fichiers
63 texte, extraire des informations de ces fichiers, et imprimer des
64 rapports basés sur ces informations. C'est aussi un bon langage pour
65 de nombreuses procédures de gestion système. Ce langage se veut
66 pratique (simple à utiliser, efficace, complet) autant qu'agréable
67 (conscrit, élégant, minimal).
68
69 %description -l pl
70 Perl jest jêzykiem przeznaczonym do skanowania plików tekstowych,
71 wyci±gania z nich informacji i drukowania raportu bazuj±cego na tych
72 informacjach. Jest równie¿ doskona³ym jêzykiem dla wielu narzêdzi do
73 nadzoru systemu. Jêzyk ten jest w zamierzeniu praktycznym (³atwym w
74 u¿yciu, efektywnym, kompletnym) bardziej ni¿ piêkny ;) (skromny,
75 elegancki, minimalny).
76
77 %description -l tr
78 Perl, metin dosyalarýný taramak, bu metin dosyalarýndan bilgi çýkarmak
79 ve bu bilgiye dayalý raporlar hazýrlamak icin geliþtirilmiþ bir
80 yorumlamalý dildir. Ayrýca pek çok sistem yönetimi görevleri için de
81 yararlý yetenekleri vardýr. Perl, güzel (ufak, zarif, minimum)
82 olmaktan çok, pratik olmaya yönelik (kullanýmý kolay, verimli,
83 eksiksiz) olarak tasarlanmýþtýr.
84
85 %package -n sperl
86 Summary:        Practical Extraction and Report Language (SUID root binary)
87 Summary(pl):    Practical Extraction and Report Language (SUID root binaria)
88 Group:          Applications/Text
89 Group(de):      Applikationen/Text
90 Group(fr):      Utilitaires/Texte
91 Group(pl):      Aplikacje/Tekst
92 Requires:       %{name} = %{version}
93
94 %description -n sperl
95 Practical Extraction and Report Language (SUID root binary).
96
97 %description -n sperl -l pl
98 Practical Extraction and Report Language (SUID root binaria).
99
100
101 %prep
102 %setup  -q
103 %patch0 -p1
104 %patch1 -p1
105 %patch2 -p1
106 %patch3 -p1
107 %patch4 -p1
108 %patch5 -p1
109 %patch6 -p1
110 %patch7 -p1
111 %patch8 -p1
112 %patch9 -p1
113
114 for i in find-* ; do
115         mv -f $i $i.old
116         sed "s|FPPATH|%{_builddir}/%{name}-%{version}|g" < $i.old > $i
117         chmod 755 $i; rm -f $i.old
118 done
119
120 %build
121 # this is gross
122 # i added more ugly stuff here
123 # i know that is ugly way to set that but i dont know how do it better  
124 cat > config.over <<EOF
125 installprefix=$RPM_BUILD_ROOT%{_prefix}
126 test -d \$installprefix || mkdir -p \$installprefix
127 test -d \$installprefix/bin || mkdir -p \$installprefix/bin
128 installarchlib=\`echo \$installarchlib | sed "s!\$prefix!\$installprefix!"\`
129 installbin=\`echo \$installbin | sed "s!\$prefix!\$installprefix!"\`
130 installman1dir=\`echo \$installman1dir | sed "s!\$prefix!\$installprefix!"\`
131 installman3dir=\`echo \$installman3dir | sed "s!\$prefix!\$installprefix!"\`
132 installprivlib=\`echo \$installprivlib | sed "s!\$prefix!\$installprefix!"\`
133 installscript=\`echo \$installscript | sed "s!\$prefix!\$installprefix!"\`
134 installsitelib=\`echo \$installsitelib | sed "s!\$prefix!\$installprefix!"\`
135 installsitearch=\`echo \$installsitearch | sed "s!\$prefix!\$installprefix!"\`
136 dynamic_ext=\`echo \$dynamic_ext GDBM_File NDBM_File\`
137 EOF
138
139 USETHREADS=%{!?bcond_on_perl_threads:-U}%{?bcond_on_perl_threads:-D}
140 sh Configure \
141         -des \
142         -Dcc=%{__cc} \
143         -Darchname=%{_target_platform} \
144         -Dcccdlflags='-fPIC' \
145         -Dprefix=%{_prefix} \
146         -Dscriptdir=%{_bindir} \
147         -Dman1dir=%{_mandir}/man1 \
148         -Dman3dir=%{_mandir}/man3 \
149         -Dman3ext=3pm \
150         -Doptimize="$RPM_OPT_FLAGS" \
151         ${USETHREADS}usethreads \
152         -Uuselargefiles \
153 %ifarch sparc sparc64
154         -Ud_longdbl \
155 %endif
156 %ifnarch sparc sparc64
157         -Duseshrplib \
158 %endif 
159         -Dd_dosuid \
160         -Ud_setresuid \
161         -Ud_setresgid 
162
163 %{__make}
164
165 %install
166 rm -rf $RPM_BUILD_ROOT
167 install -d $RPM_BUILD_ROOT
168
169 %{__make} install
170 install utils/pl2pm $RPM_BUILD_ROOT%{_bindir}/pl2pm
171
172 ## Generate *.ph files with a trick (based on RH).
173
174 %{__make} all -f - <<EOF
175 PKGS    = glibc-devel gdbm-devel gpm-devel libgr-devel libjpeg-devel \
176         libpng-devel libtiff-devel ncurses-devel popt-devel \
177         zlib-devel binutils libelf e2fsprogs-devel pam-devel pwdb-devel \
178         rpm-devel
179 STDH    = \$(filter /usr/include/%%, \$(shell rpm -q --queryformat '[%%{FILENAMES}\n]' \$(PKGS)))
180 STDH    += \$(wildcard /usr/include/linux/*.h) \$(wildcard /usr/include/asm/*.h) \$(wildcard /usr/include/scsi/*.h)
181 GCCDIR  = \$(shell gcc --print-file-name include)
182 GCCH    = \$(filter \$(GCCDIR)/%%, \$(shell rpm -q --queryformat '[%%{FILENAMES}\n]' gcc))
183
184 LIBPATH = %{_builddir}/%{name}-%{version}
185 PERLLIB = $RPM_BUILD_ROOT%{_libdir}/perl5/%{version}
186 PERLBIN = $RPM_BUILD_ROOT%{_bindir}/perl
187 PERL    = LD_LIBRARY_PATH=\$(LIBPATH) PERL5LIB=\$(PERLLIB) \$(PERLBIN)
188 PHDIR   = \$(PERLLIB)/%{_target_platform}%{perlthread}
189 PHBIN   = $RPM_BUILD_ROOT%{_bindir}/h2ph
190 H2PH    = \$(PERL) \$(PHBIN) -d \$(PHDIR)/
191
192 all: std-headers gcc-headers
193
194 std-headers: \$(STDH)
195         cd /usr/include && \$(H2PH) \$(STDH:/usr/include/%%=%%)
196
197 gcc-headers: \$(GCCH)
198         cd \$(GCCDIR) && \$(H2PH) \$(GCCH:\$(GCCDIR)/%%=%%)
199
200 EOF
201
202 ## Fix paths
203 (
204 cd $RPM_BUILD_ROOT%{_libdir}/perl5/%{version}/%{_target_platform}%{perlthread}
205 sed -e "s|$RPM_BUILD_ROOT||g" < Config.pm > Config.pm.new
206 mv -f Config.pm.new Config.pm
207 sed -e "s|$RPM_BUILD_ROOT||g" < .packlist > .packlist.new
208 mv -f .packlist.new .packlist
209 )
210
211 ## Fix permissions
212 find $RPM_BUILD_ROOT%{_libdir}/perl5 -name \*.ph -exec chmod 444 {} \;
213 find $RPM_BUILD_ROOT%{_libdir}/perl5 -type d -exec chmod 755 {} \;
214
215 gzip -9nf README Change*
216
217
218 %clean
219 rm -rf $RPM_BUILD_ROOT
220
221 %files
222 %defattr(644,root,root,755)
223 %doc README.gz Change*
224
225 %attr(755,root,root) %{_bindir}/a2p
226 %attr(755,root,root) %{_bindir}/c2ph
227 %attr(755,root,root) %{_bindir}/find2perl
228 %attr(755,root,root) %{_bindir}/h2ph
229 %attr(755,root,root) %{_bindir}/h2xs
230 %attr(755,root,root) %{_bindir}/perl
231 %attr(755,root,root) %{_bindir}/perl%{version}
232 %attr(755,root,root) %{_bindir}/perlbug
233 %attr(755,root,root) %{_bindir}/perlcc
234 %attr(755,root,root) %{_bindir}/perldoc
235 %attr(755,root,root) %{_bindir}/pl2pm
236 %attr(755,root,root) %{_bindir}/pod2html
237 %attr(755,root,root) %{_bindir}/pod2latex
238 %attr(755,root,root) %{_bindir}/pod2man
239 %attr(755,root,root) %{_bindir}/pod2text
240 %attr(755,root,root) %{_bindir}/podselect
241 %attr(755,root,root) %{_bindir}/pstruct
242 %attr(755,root,root) %{_bindir}/s2p
243 %attr(755,root,root) %{_bindir}/splain
244
245 %dir %{_libdir}/perl5
246 %attr( - ,root,root) %{_libdir}/perl5/%{version}/*
247 %dir %{_libdir}/perl5/site_perl
248 %attr( - ,root,root) %{_libdir}/perl5/site_perl/*
249 %{_mandir}/man[13]/*
250
251 %files -n sperl
252 %defattr(644,root,root,755)
253 %attr(4755,root,root) %{_bindir}/sperl%{version}
254 %attr(4755,root,root) %{_bindir}/suidperl
This page took 0.059514 seconds and 4 git commands to generate.