1 diff -urN rpm-3.0.5.orig/configure.in rpm-3.0.5/configure.in
2 --- rpm-3.0.5.orig/configure.in Sun Jul 30 00:05:48 2000
3 +++ rpm-3.0.5/configure.in Sun Jul 30 00:07:06 2000
5 AC_PATH_PROG(__MKDIR, mkdir, /bin/mkdir, $MYPATH)
6 AC_PATH_PROG(__MV, mv, /bin/mv, $MYPATH)
7 AC_PATH_PROG(__PATCH, patch, /usr/bin/patch, $MYPATH)
8 + AC_PATH_PROG(PERL, perl, /usr/bin/perl, $MYPATH)
9 AC_MSG_CHECKING(old version of patch)
10 PATCHVERSION=`patch --version 2>&1`
13 dnl export LIBS INCPATH CONFIG_SITE
15 AC_CONFIG_SUBDIRS(popt)
16 -AC_OUTPUT([Doxyfile Makefile rpmrc macros macros.pld platform rpmpopt scripts/brp-redhat
17 +AC_OUTPUT([Doxyfile Makefile rpmrc macros macros.pld platform rpmpopt
18 + scripts/brp-redhat macros.perl scripts/perl.req scripts/perl.prov
19 lib/Makefile build/Makefile tools/Makefile scripts/Makefile
20 tests/Makefile tests/rpmrc tests/macros tests/hello-test/Makefile
21 misc/Makefile po/Makefile.in intl/Makefile
22 diff -urN rpm-3.0.5.orig/macros.in rpm-3.0.5/macros.in
23 --- rpm-3.0.5.orig/macros.in Sun Jul 30 00:05:48 2000
24 +++ rpm-3.0.5/macros.in Sun Jul 30 00:07:06 2000
26 # %{perl_sitearch}/Image
27 # %dir %{perl_sitearch}/auto/Image
30 +# NOTE: %{perl_sitearch}, %{perl_archlib} and %{perl_sitelib} macros
31 +# has been moved to macros.perl (see info in this file for details).
33 %requires_eq() %(LC_ALL="C" rpm -q --queryformat 'Requires:%%{NAME} = %%{VERSION}' %1| grep -v "is not")
34 -%perl_sitearch %(eval "`perl -V:installsitearch`"; echo $installsitearch)
35 -%perl_archlib %(eval "`perl -V:installarchlib`"; echo $installarchlib)
37 #------------------------------------------------------------------------------
38 # arch macro for all Intel i?86 compatibile processors
39 diff -urN rpm-3.0.5.orig/macros.perl.in rpm-3.0.5/macros.perl.in
40 --- rpm-3.0.5.orig/macros.perl.in Thu Jan 1 01:00:00 1970
41 +++ rpm-3.0.5/macros.perl.in Sun Jul 30 00:07:06 2000
43 +# Perl specific macro definitions.
44 +# To make use of these macros insert the following line into your spec file:
45 +# %include @RPMCONFIGDIR@/macros.perl
47 +%define __find_requires @RPMCONFIGDIR@/find-perl-requires
48 +%define __find_provides @RPMCONFIGDIR@/find-perl-provides
50 +%define perl_sitelib %(eval "`perl -V:installsitelib`"; echo $installsitelib)
51 +%define perl_sitearch %(eval "`perl -V:installsitearch`"; echo $installsitearch)
52 +%define perl_archlib %(eval "`perl -V:installarchlib`"; echo $installarchlib)
53 +%define perl_privlib %(eval "`perl -V:installprivlib`"; echo $installprivlib)
55 diff -urN rpm-3.0.5.orig/scripts/Makefile.am rpm-3.0.5/scripts/Makefile.am
56 --- rpm-3.0.5.orig/scripts/Makefile.am Sun Jul 9 17:36:20 2000
57 +++ rpm-3.0.5/scripts/Makefile.am Sun Jul 30 00:07:51 2000
59 find-prov.pl find-req.pl cpanflute find-provides.perl \
60 find-requires.perl get_magic.pl getpo.sh http.req \
61 magic.prov magic.req perl.prov perl.req rpmdiff rpmdiff.cgi u_pkg.sh \
62 - vpkg-provides.sh vpkg-provides2.sh
63 + vpkg-provides.sh vpkg-provides2.sh \
64 + find-perl-requires find-perl-provides
66 installprefix = $(DESTDIR)
69 find-prov.pl find-req.pl cpanflute find-provides.perl \
70 find-requires.perl get_magic.pl getpo.sh http.req \
71 magic.prov magic.req perl.prov perl.req rpmdiff rpmdiff.cgi u_pkg.sh \
72 - vpkg-provides.sh vpkg-provides2.sh
73 + vpkg-provides.sh vpkg-provides2.sh \
74 + find-perl-requires find-perl-provides
75 diff -urN rpm-3.0.5.orig/scripts/find-perl-provides rpm-3.0.5/scripts/find-perl-provides
76 --- rpm-3.0.5.orig/scripts/find-perl-provides Thu Jan 1 01:00:00 1970
77 +++ rpm-3.0.5/scripts/find-perl-provides Sun Jul 30 00:07:06 2000
82 +filelist=`sed "s/['\"]/\\\&/g"`
84 +echo $filelist|/usr/lib/rpm/find-provides
85 +/usr/lib/rpm/perl.prov $filelist
87 diff -urN rpm-3.0.5.orig/scripts/find-perl-requires rpm-3.0.5/scripts/find-perl-requires
88 --- rpm-3.0.5.orig/scripts/find-perl-requires Thu Jan 1 01:00:00 1970
89 +++ rpm-3.0.5/scripts/find-perl-requires Sun Jul 30 00:07:06 2000
94 +filelist=`sed "s/['\"]/\\\&/g"`
96 +requires="`echo $filelist|/usr/lib/rpm/find-requires`"
97 +requires_perl="`/usr/lib/rpm/perl.req $filelist`"
98 +requires_mod="`rpm -q --whatprovides --qf "%{NAME}\n" $requires_perl 2>/dev/null`"
101 +$requires_mod"| sort -u
102 diff -urN rpm-3.0.5.orig/scripts/perl.prov rpm-3.0.5/scripts/perl.prov
103 --- rpm-3.0.5.orig/scripts/perl.prov Wed Jun 14 14:34:50 2000
104 +++ rpm-3.0.5/scripts/perl.prov Sun Jul 30 00:07:06 2000
110 + if (! m=(/(doc|usr/src)/|\.(so|gz|ph|pod|h|html)$)=) {
117 # contents of the file.
121 + if (! m=(/(doc|usr/src)/|\.(so|gz|ph|pod|h|html)$)=) {
127 diff -urN rpm-3.0.5.orig/scripts/perl.req rpm-3.0.5/scripts/perl.req
128 --- rpm-3.0.5.orig/scripts/perl.req Wed Jun 14 14:34:50 2000
129 +++ rpm-3.0.5/scripts/perl.req Sun Jul 30 00:07:06 2000
134 # RPM (and it's source code) is covered under two separate licenses.
141 + if (m=/usr/(sbin|bin|lib|share|X11R6/(lib|bin))/=) {
142 + if (! m=(/(doc|man|info|usr/src)/|\.(so|ph|h|html|pod)$)=) {
150 # contents of the file.
154 + if (m=/usr/(sbin|bin|lib|share|X11R6/(lib|bin))/=) {
155 + if (! m=(/(doc|man|info|usr/src)/|\.(so|ph|h|html|pod)$)=) {
163 foreach $module (sort keys %require) {
164 if (length($require{$module}) == 0) {
165 - print "perl($module)\n";
166 + if ($module =~ /^[0-9._]+$/) {
167 + print "perl >= $module\n";
169 + print "perl($module)\n";
173 # I am not using rpm3.0 so I do not want spaces arround my
175 # will be included with the name sys/systeminfo.ph so only use the
176 # basename of *.ph files
178 - ($module =~ m/\.ph$/) && ($module =~ s!.*/!!g );
179 + # ($module =~ m/\.ph$/) && ($module =~ s!.*/!!g );
181 + # there is no need to generate dependencies for ph, pl or test files
182 + # so let's just skip them.
184 + ($module =~ m/\.(ph|pl|t)$/) && next;
186 + # skip all modules for platforms other than linux.
188 + ($module =~ m/Mac|OS2|MSDOS|Win32|VMS|vmsish/) && next;
190 + # if the module name starts in a dot it is not a module name.
192 + ($module =~ m/^\./) && next;
194 + # if the module ends with .pm strip it to leave only basename.
196 + $module =~ s/\.pm$//;
198 + $module =~ s/\//::/;
200 + # trim off trailing parenthesis if any. Sometimes people pass
201 + # the module an empty list.
203 + $module =~ s/\(\s*\)$//;
206 $require{$module}=$version;