]>
Commit | Line | Data |
---|---|---|
4703c2f4 AF |
1 | --- rpm-3.0.4/scripts/Makefile.am.wiget Wed Feb 23 02:48:51 2000 |
2 | +++ rpm-3.0.4/scripts/Makefile.am Thu Mar 23 18:31:34 2000 | |
3 | @@ -8,7 +8,8 @@ | |
4 | cpanflute find-provides.perl find-requires.perl \ | |
5 | freshen.sh get_magic.pl getpo.sh http.req magic.prov magic.req \ | |
6 | perl.prov perl.req rpmdiff rpmdiff.cgi u_pkg.sh \ | |
7 | - vpkg-provides.sh vpkg-provides2.sh | |
8 | + vpkg-provides.sh vpkg-provides2.sh \ | |
9 | + find-perl-requires find-perl-provides | |
edf87823 | 10 | |
11 | installprefix = $(DESTDIR) | |
12 | ||
4703c2f4 AF |
13 | @@ -21,4 +22,5 @@ |
14 | cpanflute find-provides.perl find-requires.perl \ | |
15 | freshen.sh get_magic.pl getpo.sh http.req magic.prov magic.req \ | |
16 | perl.prov perl.req rpmdiff rpmdiff.cgi u_pkg.sh \ | |
17 | - vpkg-provides.sh vpkg-provides2.sh | |
18 | + vpkg-provides.sh vpkg-provides2.sh \ | |
19 | + find-perl-requires find-perl-provides | |
20 | --- rpm-3.0.4/scripts/perl.req.wiget Mon Jan 17 19:58:36 2000 | |
21 | +++ rpm-3.0.4/scripts/perl.req Thu Mar 23 18:31:34 2000 | |
2fa5aec3 AF |
22 | @@ -1,4 +1,4 @@ |
23 | -#!/usr/bin/perl | |
24 | +#!@PERL@ | |
4703c2f4 AF |
25 | |
26 | # RPM (and it's source code) is covered under two separate licenses. | |
27 | ||
28 | @@ -41,7 +41,11 @@ | |
2fa5aec3 AF |
29 | |
30 | if ("@ARGV") { | |
31 | foreach (@ARGV) { | |
32 | - process_file($_); | |
20a6d548 | 33 | + if (m=/usr/(sbin|bin|lib|share|X11R6/(lib|bin))/=) { |
2eb651d8 | 34 | + if (! m=(/(doc|man|info|usr/src)/|\.(so|ph|h|html|pod)$)=) { |
2fa5aec3 AF |
35 | + process_file($_); |
36 | + } | |
37 | + } | |
38 | } | |
39 | } else { | |
40 | ||
4703c2f4 | 41 | @@ -49,14 +53,22 @@ |
2fa5aec3 AF |
42 | # contents of the file. |
43 | ||
44 | foreach (<>) { | |
45 | - process_file($_); | |
4703c2f4 AF |
46 | + if (m=/usr/(sbin|bin|lib|share|X11R6/(lib|bin))/=) { |
47 | + if (! m=(/(doc|man|info|usr/src)/|\.(so|ph|h|html|pod)$)=) { | |
48 | + process_file($_); | |
49 | + } | |
50 | + } | |
2fa5aec3 AF |
51 | } |
52 | } | |
edf87823 | 53 | |
54 | ||
55 | foreach $module (sort keys %require) { | |
edf87823 | 56 | if (length($require{$module}) == 0) { |
57 | - print "perl($module)\n"; | |
4703c2f4 AF |
58 | + if ($module =~ /^[0-9._]+$/) { |
59 | + print "perl >= $module\n"; | |
60 | + } else { | |
61 | + print "perl($module)\n"; | |
62 | + } | |
edf87823 | 63 | } else { |
2fa5aec3 | 64 | |
4703c2f4 AF |
65 | # I am not using rpm3.0 so I do not want spaces arround my |
66 | @@ -183,7 +195,31 @@ | |
3ce8984f | 67 | # will be included with the name sys/systeminfo.ph so only use the |
68 | # basename of *.ph files | |
69 | ||
70 | - ($module =~ m/\.ph$/) && ($module =~ s!.*/!!g ); | |
71 | + # ($module =~ m/\.ph$/) && ($module =~ s!.*/!!g ); | |
cfd811fa | 72 | + |
852c3a98 | 73 | + # there is no need to generate dependencies for ph, pl or test files |
4a19987c | 74 | + # so let's just skip them. |
4703c2f4 | 75 | + |
852c3a98 | 76 | + ($module =~ m/\.(ph|pl|t)$/) && next; |
cfd811fa | 77 | + |
4a19987c | 78 | + # skip all modules for platforms other than linux. |
92b19143 | 79 | + |
80 | + ($module =~ m/Mac|OS2|MSDOS|Win32|VMS|vmsish/) && next; | |
81 | + | |
4a19987c | 82 | + # if the module name starts in a dot it is not a module name. |
4d8fb4e3 | 83 | + |
84 | + ($module =~ m/^\./) && next; | |
85 | + | |
4a19987c | 86 | + # if the module ends with .pm strip it to leave only basename. |
5e855029 | 87 | + |
4a19987c | 88 | + $module =~ s/\.pm$//; |
5e855029 | 89 | + |
cb87a980 | 90 | + $module =~ s/\//::/; |
91 | + | |
4a19987c | 92 | + # trim off trailing parenthesis if any. Sometimes people pass |
93 | + # the module an empty list. | |
94 | + | |
95 | + $module =~ s/\(\s*\)$//; | |
cfd811fa | 96 | |
4703c2f4 | 97 | |
3ce8984f | 98 | $require{$module}=$version; |
4703c2f4 AF |
99 | --- rpm-3.0.4/scripts/perl.prov.wiget Mon Jan 17 19:58:36 2000 |
100 | +++ rpm-3.0.4/scripts/perl.prov Thu Mar 23 18:36:24 2000 | |
101 | @@ -47,7 +47,9 @@ | |
40e8d3f7 | 102 | |
103 | if ("@ARGV") { | |
104 | foreach (@ARGV) { | |
105 | - process_file($_); | |
cebd7a08 | 106 | + if (! m=(/(doc|usr/src)/|\.(so|gz|ph|pod|h|html)$)=) { |
40e8d3f7 | 107 | + process_file($_); |
108 | + } | |
109 | } | |
110 | } else { | |
111 | ||
4703c2f4 | 112 | @@ -55,7 +57,9 @@ |
40e8d3f7 | 113 | # contents of the file. |
114 | ||
115 | foreach (<>) { | |
116 | - process_file($_); | |
cebd7a08 | 117 | + if (! m=(/(doc|usr/src)/|\.(so|gz|ph|pod|h|html)$)=) { |
40e8d3f7 | 118 | + process_file($_); |
119 | + } | |
120 | } | |
121 | } | |
122 | ||
4703c2f4 AF |
123 | --- rpm-3.0.4/macros.in.wiget Thu Mar 23 18:31:34 2000 |
124 | +++ rpm-3.0.4/macros.in Thu Mar 23 18:31:34 2000 | |
125 | @@ -532,9 +532,11 @@ | |
126 | # %{perl_sitearch}/Image | |
127 | # %dir %{perl_sitearch}/auto/Image | |
128 | # | |
129 | +# | |
130 | +# NOTE: %{perl_sitearch}, %{perl_archlib} and %{perl_sitelib} macros | |
131 | +# has been moved to macros.perl (see info in this file for details). | |
132 | +# | |
133 | %requires_eq() %(LC_ALL="C" rpm -q --queryformat 'Requires:%%{NAME} = %%{VERSION}' %1| grep -v "is not") | |
134 | -%perl_sitearch %(eval "`perl -V:installsitearch`"; echo $installsitearch) | |
135 | -%perl_archlib %(eval "`perl -V:installarchlib`"; echo $installarchlib) | |
40e8d3f7 | 136 | |
4703c2f4 AF |
137 | #------------------------------------------------------------------------------ |
138 | # arch macro for all Intel i?86 compatibile processors | |
139 | --- rpm-3.0.4/configure.in.wiget Thu Mar 23 18:31:34 2000 | |
140 | +++ rpm-3.0.4/configure.in Thu Mar 23 18:31:34 2000 | |
141 | @@ -181,6 +181,7 @@ | |
142 | AC_PATH_PROG(__MKDIR, mkdir, /bin/mkdir, $MYPATH) | |
143 | AC_PATH_PROG(__MV, mv, /bin/mv, $MYPATH) | |
144 | AC_PATH_PROG(__PATCH, patch, /usr/bin/patch, $MYPATH) | |
145 | + AC_PATH_PROG(PERL, perl, /usr/bin/perl, $MYPATH) | |
146 | AC_MSG_CHECKING(old version of patch) | |
147 | PATCHVERSION=`patch --version 2>&1` | |
40e8d3f7 | 148 | |
4703c2f4 AF |
149 | @@ -932,7 +933,8 @@ |
150 | dnl export LIBS INCPATH CONFIG_SITE | |
4a19987c | 151 | |
4703c2f4 AF |
152 | AC_CONFIG_SUBDIRS(popt) |
153 | -AC_OUTPUT([Doxyfile Makefile rpmrc macros macros.pld platform rpmpopt scripts/brp-redhat | |
154 | +AC_OUTPUT([Doxyfile Makefile rpmrc macros macros.pld platform rpmpopt | |
155 | + scripts/brp-redhat macros.perl scripts/perl.req scripts/perl.prov | |
156 | lib/Makefile build/Makefile tools/Makefile scripts/Makefile | |
157 | tests/Makefile tests/rpmrc tests/macros tests/hello-test/Makefile | |
158 | misc/Makefile po/Makefile.in intl/Makefile | |
159 | --- /dev/null Tue May 5 22:32:27 1998 | |
160 | +++ rpm-3.0.4/scripts/find-perl-requires Thu Mar 23 18:31:34 2000 | |
161 | @@ -0,0 +1,11 @@ | |
162 | +#!/bin/sh | |
163 | +ulimit -c 0 | |
4a19987c | 164 | + |
4703c2f4 AF |
165 | +filelist=`sed "s/['\"]/\\\&/g"` |
166 | + | |
167 | +requires="`echo $filelist|/usr/lib/rpm/find-requires`" | |
168 | +requires_perl="`/usr/lib/rpm/perl.req $filelist`" | |
169 | +requires_mod="`rpm -q --whatprovides --qf "%{NAME}\n" $requires_perl 2>/dev/null`" | |
170 | +echo "$requires | |
171 | +$requires_perl | |
172 | +$requires_mod"| sort -u | |
173 | --- /dev/null Tue May 5 22:32:27 1998 | |
174 | +++ rpm-3.0.4/scripts/find-perl-provides Thu Mar 23 18:31:34 2000 | |
175 | @@ -0,0 +1,8 @@ | |
176 | +#!/bin/sh | |
177 | +ulimit -c 0 | |
178 | + | |
179 | +filelist=`sed "s/['\"]/\\\&/g"` | |
180 | + | |
181 | +echo $filelist|/usr/lib/rpm/find-provides | |
182 | +/usr/lib/rpm/perl.prov $filelist | |
183 | + | |
184 | --- /dev/null Tue May 5 22:32:27 1998 | |
185 | +++ rpm-3.0.4/macros.perl.in Thu Mar 23 18:31:34 2000 | |
186 | @@ -0,0 +1,11 @@ | |
187 | +# Perl specific macro definitions. | |
188 | +# To make use of these macros insert the following line into your spec file: | |
189 | +# %include @RPMCONFIGDIR@/macros.perl | |
190 | + | |
191 | +%define __find_requires @RPMCONFIGDIR@/find-perl-requires | |
192 | +%define __find_provides @RPMCONFIGDIR@/find-perl-provides | |
193 | + | |
194 | +%define perl_sitelib %(eval "`perl -V:installsitelib`"; echo $installsitelib) | |
195 | +%define perl_sitearch %(eval "`perl -V:installsitearch`"; echo $installsitearch) | |
196 | +%define perl_archlib %(eval "`perl -V:installarchlib`"; echo $installarchlib) | |
4a19987c | 197 | + |