/[smeserver]/rpms/perl-I18N-AcceptLanguage/sme8/I18N-AcceptLanguage.spec
ViewVC logotype

Annotation of /rpms/perl-I18N-AcceptLanguage/sme8/I18N-AcceptLanguage.spec

Parent Directory Parent Directory | Revision Log Revision Log | View Revision Graph Revision Graph


Revision 1.1 - (hide annotations) (download)
Tue Jun 12 20:21:49 2007 UTC (17 years, 5 months ago) by slords
Branch: MAIN
CVS Tags: perl-I18N-AcceptLanguage-1_02-1_el5_sme
Import on branch sme8 of package perl-I18N-AcceptLanguage-1.02-1.el5.sme.src.rpm

1 slords 1.1 #
2     # - I18N::AcceptLanguage -
3     # This spec file was automatically generated by cpan2rpm [ver: 2.026]
4     # The following arguments were used:
5     # --release=1centos I18N::AcceptLanguage
6     # For more information on cpan2rpm please visit: http://perl.arix.com/
7     #
8     %define pkgname I18N-AcceptLanguage
9     %define filelist %{pkgname}-%{version}-filelist
10     %define NVR %{pkgname}-%{version}-%{release}
11     %define maketest 1
12    
13     name: perl-I18N-AcceptLanguage
14     summary: I18N-AcceptLanguage - Matches language preference to available
15     version: 1.02
16     release: 1%{?dist}
17     license: Artistic
18     group: Applications/CPAN
19     url: http://www.cpan.org
20     buildroot: %{_tmppath}/%{name}-%{version}-%(id -u -n)
21     buildarch: noarch
22     prefix: %(echo %{_prefix})
23     source: http://search.cpan.org/dist/C/CG/CGILMORE/I18N-AcceptLanguage-1.02.tar.gz
24    
25     %description
26     B<I18N::AcceptLanguage> matches language preference to available
27     languages per rules defined in RFC 2616, section 14.4: HTTP/1.1 -
28     Header Field Definitions - Accept-Language.
29    
30     #
31     # This package was generated automatically with the cpan2rpm
32     # utility. To get this software or for more information
33     # please visit: http://perl.arix.com/
34     #
35    
36     %prep
37     %setup -q -n %{pkgname}-%{version}
38     chmod -R u+w %{_builddir}/%{pkgname}-%{version}
39    
40     %build
41     grep -rsl '^#!.*perl' . |
42     grep -v '.bak$' |xargs --no-run-if-empty \
43     %__perl -MExtUtils::MakeMaker -e 'MY->fixin(@ARGV)'
44     CFLAGS="$RPM_OPT_FLAGS"
45     %{__perl} Makefile.PL `%{__perl} -MExtUtils::MakeMaker -e ' print qq|PREFIX=%{buildroot}%{_prefix}| if \$ExtUtils::MakeMaker::VERSION =~ /5\.9[1-6]|6\.0[0-5]/ '`
46     %{__make}
47     %if %maketest
48     %{__make} test
49     %endif
50    
51     %install
52     [ "%{buildroot}" != "/" ] && rm -rf %{buildroot}
53    
54     %{makeinstall} `%{__perl} -MExtUtils::MakeMaker -e ' print \$ExtUtils::MakeMaker::VERSION <= 6.05 ? qq|PREFIX=%{buildroot}%{_prefix}| : qq|DESTDIR=%{buildroot}| '`
55    
56     [ -x /usr/lib/rpm/brp-compress ] && /usr/lib/rpm/brp-compress
57    
58     # SuSE Linux
59     if [ -e /etc/SuSE-release -o -e /etc/UnitedLinux-release ]
60     then
61     %{__mkdir_p} %{buildroot}/var/adm/perl-modules
62     %{__cat} `find %{buildroot} -name "perllocal.pod"` \
63     | %{__sed} -e s+%{buildroot}++g \
64     > %{buildroot}/var/adm/perl-modules/%{name}
65     fi
66    
67     # remove special files
68     find %{buildroot} -name "perllocal.pod" \
69     -o -name ".packlist" \
70     -o -name "*.bs" \
71     |xargs -i rm -f {}
72    
73     # no empty directories
74     find %{buildroot}%{_prefix} \
75     -type d -depth \
76     -exec rmdir {} \; 2>/dev/null
77    
78     %{__perl} -MFile::Find -le '
79     find({ wanted => \&wanted, no_chdir => 1}, "%{buildroot}");
80     print "%doc Changes";
81     for my $x (sort @dirs, @files) {
82     push @ret, $x unless indirs($x);
83     }
84     print join "\n", sort @ret;
85    
86     sub wanted {
87     return if /auto$/;
88    
89     local $_ = $File::Find::name;
90     my $f = $_; s|^\Q%{buildroot}\E||;
91     return unless length;
92     return $files[@files] = $_ if -f $f;
93    
94     $d = $_;
95     /\Q$d\E/ && return for reverse sort @INC;
96     $d =~ /\Q$_\E/ && return
97     for qw|/etc %_prefix/man %_prefix/bin %_prefix/share|;
98    
99     $dirs[@dirs] = $_;
100     }
101    
102     sub indirs {
103     my $x = shift;
104     $x =~ /^\Q$_\E\// && $x ne $_ && return 1 for @dirs;
105     }
106     ' > %filelist
107    
108     [ -z %filelist ] && {
109     echo "ERROR: empty %files listing"
110     exit -1
111     }
112    
113     %clean
114     [ "%{buildroot}" != "/" ] && rm -rf %{buildroot}
115    
116     %files -f %filelist
117     %defattr(-,root,root)
118    
119     %changelog
120     * Sun Apr 29 2007 Shad L. Lords <slords@mail.com>
121     - Clean up spec so package can be built by koji/plague
122    
123     * Thu Dec 07 2006 Shad L. Lords <slords@mail.com>
124     - Update to new release naming. No functional changes.
125     - Make Packager generic
126    
127     * Thu Sep 2 2004 charlieb@charlieb-centos
128     - Initial build.

admin@koozali.org
ViewVC Help
Powered by ViewVC 1.2.1 RSS 2.0 feed