/[smeserver]/rpms/perl-Log-Agent/sme7/Log-Agent.spec
ViewVC logotype

Annotation of /rpms/perl-Log-Agent/sme7/Log-Agent.spec

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


Revision 1.1 - (hide annotations) (download)
Tue Jun 12 16:58:57 2007 UTC (17 years, 2 months ago) by slords
Branch: MAIN
CVS Tags: perl-Log-Agent-0_305-2_el4_sme
Import on branch sme7 of package perl-Log-Agent-0.305-2.el4.sme.src.rpm

1 slords 1.1 #
2     # - Log::Agent -
3     # This spec file was automatically generated by cpan2rpm [ver: 2.022]
4     # The following arguments were used:
5     # --distribution=BEA --packager=Bent Terp <Bent.Terp@bea.ki.se> --url=http://www.bea.ki.se --no-upgrade-chk --force --spec-only Log::Agent
6     # For more information on cpan2rpm please visit: http://perl.arix.com/
7     #
8    
9     %define pkgname Log-Agent
10     %define filelist %{pkgname}-%{version}-filelist
11     %define NVR %{pkgname}-%{version}-%{release}
12     %define maketest 1
13    
14     name: perl-Log-Agent
15     summary: Log-Agent - logging agent
16     version: 0.305
17     Release: 2%{?dist}
18     license: Artistic
19     group: Applications/CPAN
20     url: http://www.bea.ki.se
21     buildroot: %{_tmppath}/%{name}-%{version}-%(id -u -n)
22     prefix: %(echo %{_prefix})
23     source: http://search.cpan.org//CPAN/authors/id/M/MR/MROGASKI/Log-Agent-0.305.tar.gz
24    
25     %description
26     The C<Log::Agent> module provides an abstract layer for logging and
27     tracing, which is independant from the actual method used to physically
28     perform those activities. It acts as an agent (hence the name) that
29     collects the requests and delegates processing to a sublayer: the
30     logging driver.
31    
32     The C<Log::Agent> module is meant to be used in all reusable components,
33     since they cannot know in advance how the application which ends up using
34     them will perform its logging activities: either by emitting messages
35     on stdout and errors on stderr, or by directing messages to logfiles,
36     or by using syslog(3).
37    
38     The logging interface is common for all the logging drivers, and is
39     therefore the result of a compromise between many logging schemes: any
40     information given at this level must be either handled by all drivers,
41     or may be ignored depending on the application's final choice.
42    
43     WARNING: THIS INTERFACE IS STILL SOMEWHAT ALPHA AND COULD STILL CHANGE
44     DEPENDING ON THE FEEDBACK I SHALL GET FROM USERS AND FROM MY OWN
45     EXPERIENCE USING IT, WITHOUT ANY BACKWARD COMPATIBILITY ASSURANCE.
46    
47     #
48     # This package was generated automatically with the cpan2rpm
49     # utility. To get this software or for more information
50     # please visit: http://perl.arix.com/
51     #
52    
53     %prep
54     %setup -q -n %{pkgname}-%{version}
55     chmod -R u+w %{_builddir}/%{pkgname}-%{version}
56    
57     %build
58     grep -rsl '^#!.*perl' . |
59     grep -v '.bak$' |xargs --no-run-if-empty \
60     %__perl -MExtUtils::MakeMaker -e 'MY->fixin(@ARGV)'
61     CFLAGS="$RPM_OPT_FLAGS"
62     %{__perl} Makefile.PL `%{__perl} -MExtUtils::MakeMaker -e ' print qq|PREFIX=%{buildroot}%{_prefix}| if \$ExtUtils::MakeMaker::VERSION =~ /5\.9[1-6]|6\.0[0-5]/ '`
63     %{__make}
64     %if %maketest
65     %{__make} test
66     %endif
67    
68     %install
69     [ "%{buildroot}" != "/" ] && rm -rf %{buildroot}
70    
71     %{makeinstall} `%{__perl} -MExtUtils::MakeMaker -e ' print \$ExtUtils::MakeMaker::VERSION <= 6.05 ? qq|PREFIX=%{buildroot}%{_prefix}| : qq|DESTDIR=%{buildroot}| '`
72    
73     [ -x /usr/lib/rpm/brp-compress ] && /usr/lib/rpm/brp-compress
74    
75     # SuSE Linux
76     if [ -e /etc/SuSE-release -o -e /etc/UnitedLinux-release ]
77     then
78     %{__mkdir_p} %{buildroot}/var/adm/perl-modules
79     %{__cat} `find %{buildroot} -name "perllocal.pod"` \
80     | %{__sed} -e s+%{buildroot}++g \
81     > %{buildroot}/var/adm/perl-modules/%{name}
82     fi
83    
84     # remove special files
85     find %{buildroot} -name "perllocal.pod" \
86     -o -name ".packlist" \
87     -o -name "*.bs" \
88     |xargs -i rm -f {}
89    
90     # no empty directories
91     find %{buildroot}%{_prefix} \
92     -type d -depth \
93     -exec rmdir {} \; 2>/dev/null
94    
95     %{__perl} -MFile::Find -le '
96     find({ wanted => \&wanted, no_chdir => 1}, "%{buildroot}");
97     print "%doc Agent README";
98     for my $x (sort @dirs, @files) {
99     push @ret, $x unless indirs($x);
100     }
101     print join "\n", sort @ret;
102    
103     sub wanted {
104     return if /auto$/;
105    
106     local $_ = $File::Find::name;
107     my $f = $_; s|^%{buildroot}||;
108     return unless length;
109     return $files[@files] = $_ if -f $f;
110    
111     $d = $_;
112     /\Q$d\E/ && return for reverse sort @INC;
113     $d =~ /\Q$_\E/ && return
114     for qw|/etc %_prefix/man %_prefix/bin %_prefix/share|;
115    
116     $dirs[@dirs] = $_;
117     }
118    
119     sub indirs {
120     my $x = shift;
121     $x =~ /^\Q$_\E\// && $x ne $_ && return 1 for @dirs;
122     }
123     ' > %filelist
124    
125     [ -z %filelist ] && {
126     echo "ERROR: empty %files listing"
127     exit -1
128     }
129    
130     %clean
131     [ "%{buildroot}" != "/" ] && rm -rf %{buildroot}
132    
133     %files -f %filelist
134     %defattr(-,root,root)
135    
136     %changelog
137     * Sun Apr 29 2007 Shad L. Lords <slords@mail.com>
138     - Clean up spec so package can be built by koji/plague
139    
140     * Sun Apr 29 2007 Shad L. Lords <slords@mail.com> 0.51.5-9
141     - Change to dist for tagging release
142     - Fix to be able to build on 64-bit
143    
144    
145     * Sun Dec 10 2006 <greg@runlevel7.ca>
146     - Update release and packager
147    
148     * Wed Jan 21 2004 bent@mata.biosci.ki.se
149     - Initial build.

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