/[smecontribs]/rpms/perl-Ezmlm/contribs7/Ezmlm.spec
ViewVC logotype

Annotation of /rpms/perl-Ezmlm/contribs7/Ezmlm.spec

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


Revision 1.1 - (hide annotations) (download)
Wed Apr 23 18:55:27 2008 UTC (16 years ago) by slords
Branch: MAIN
Initial import of perl-Ezmlm-0.07-2.el4.sme.src.rpm

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

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