• R/O
  • SSH

contrib-spec-files: Commit

日本OpenSolaris Users Group有志による、レポジトリサーバ作成のためのspecファイル群です。


Commit MetaInfo

Revisionaf8a7975ffd5b191deb0c9cf4bdbebe79ca13b71 (tree)
Time2015-11-15 10:40:05
AuthorFumihisa TONAKA <fumi.ftnk@gmai...>
CommiterFumihisa TONAKA

Log Message

merge spec_SFEperl-io-handle-util to default

Change Summary

Incremental Difference

diff -r d9f3490be7b8 -r af8a7975ffd5 .hgtags
--- a/.hgtags Sun Nov 15 10:35:16 2015 +0900
+++ b/.hgtags Sun Nov 15 10:40:05 2015 +0900
@@ -430,3 +430,4 @@
430430 008738e30e20ae23d48f7f9eb36e2d8d4271bf66 spec_SFEperl-http-request-ascgi_base
431431 0478b76cf22ecca807d45559fedb8d58031a543e spec_SFEperl-http-server-simple_base
432432 6af35b092f98f92e1c05353b8c9c0dd967b9b16a spec_SFEperl-http-server-simple-psgi_base
433+d9f3490be7b8b77a453bde24a582886a21b77bae spec_SFEperl-io-handle-util_base
diff -r d9f3490be7b8 -r af8a7975ffd5 specs/SFEperl-io-handle-util.spec
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/specs/SFEperl-io-handle-util.spec Sun Nov 15 10:40:05 2015 +0900
@@ -0,0 +1,303 @@
1+%include Solaris.inc
2+
3+%define build584 0
4+%define build510 %( if [ -x /usr/perl5/5.10/bin/perl ]; then echo '1'; else echo '0'; fi)
5+%define build512 %( if [ -x /usr/perl5/5.12/bin/perl ]; then echo '1'; else echo '0'; fi)
6+%define build516 %( if [ -x /usr/perl5/5.16/bin/perl ]; then echo '1'; else echo '0'; fi)
7+%define build520 %( if [ -x /usr/perl5/5.20/bin/perl ]; then echo '1'; else echo '0'; fi)
8+%define include_executable 0
9+
10+%define cpan_name IO-Handle-Util
11+%define sfe_cpan_name io-handle-util
12+%define ips_cpan_name io-handle-util
13+
14+Summary: Iterator based read handle
15+Name: SFEperl-%{sfe_cpan_name}
16+IPS_package_name: library/perl-5/%{ips_cpan_name}
17+Version: 0.01
18+IPS_component_version: 0.1
19+License: unknown
20+URL: https://metacpan.org/pod/IO::Handle::Util
21+Source0: http://cpan.metacpan.org/authors/id/N/NU/NUFFIN/IO-Handle-Util-%{version}.tar.gz
22+BuildRoot: %{_tmppath}/%{name}-%{version}-build
23+
24+%description
25+Iterator based read handle
26+
27+%if %{build584}
28+%package 584
29+IPS_package_name: library/perl-5/%{ips_cpan_name}-584
30+Summary: Iterator based read handle
31+BuildRequires: runtime/perl-584 = *
32+BuildRequires: library/perl-5/extutils-makemaker-584
33+BuildRequires: library/perl-5/asa-584
34+Requires: runtime/perl-584 = *
35+Requires: library/perl-5/%{ips_cpan_name}
36+Requires: library/perl-5/asa-584
37+Requires: library/perl-5/io-string-584
38+Requires: library/perl-5/parent-584
39+Requires: library/perl-5/scalar-list-utils-584
40+Requires: library/perl-5/sub-exporter-584
41+Requires: library/perl-5/test-simple-584
42+
43+%description 584
44+Iterator based read handle
45+%endif
46+
47+%if %{build510}
48+%package 510
49+IPS_package_name: library/perl-5/%{ips_cpan_name}-510
50+Summary: Iterator based read handle
51+BuildRequires: runtime/perl-510 = *
52+BuildRequires: library/perl-5/extutils-makemaker-510
53+BuildRequires: library/perl-5/asa-510
54+Requires: runtime/perl-510 = *
55+Requires: library/perl-5/%{ips_cpan_name}
56+Requires: library/perl-5/asa-510
57+Requires: library/perl-5/io-string-510
58+Requires: library/perl-5/parent-510
59+Requires: library/perl-5/scalar-list-utils-510
60+Requires: library/perl-5/sub-exporter-510
61+Requires: library/perl-5/test-simple-510
62+
63+%description 510
64+Iterator based read handle
65+%endif
66+
67+%if %{build512}
68+%package 512
69+IPS_package_name: library/perl-5/%{ips_cpan_name}-512
70+Summary: Iterator based read handle
71+BuildRequires: runtime/perl-512 = *
72+BuildRequires: library/perl-5/extutils-makemaker-512
73+BuildRequires: library/perl-5/asa-512
74+Requires: runtime/perl-512 = *
75+Requires: library/perl-5/%{ips_cpan_name}
76+Requires: library/perl-5/asa-512
77+Requires: library/perl-5/io-string-512
78+Requires: library/perl-5/parent-512
79+Requires: library/perl-5/scalar-list-utils-512
80+Requires: library/perl-5/sub-exporter-512
81+Requires: library/perl-5/test-simple-512
82+
83+%description 512
84+Iterator based read handle
85+%endif
86+
87+%if %{build516}
88+%package 516
89+IPS_package_name: library/perl-5/%{ips_cpan_name}-516
90+Summary: Iterator based read handle
91+BuildRequires: runtime/perl-516 = *
92+BuildRequires: library/perl-5/extutils-makemaker-516
93+BuildRequires: library/perl-5/asa-516
94+Requires: runtime/perl-516 = *
95+Requires: library/perl-5/%{ips_cpan_name}
96+Requires: library/perl-5/asa-516
97+Requires: library/perl-5/io-string-516
98+Requires: library/perl-5/parent-516
99+Requires: library/perl-5/scalar-list-utils-516
100+Requires: library/perl-5/sub-exporter-516
101+Requires: library/perl-5/test-simple-516
102+
103+%description 516
104+Iterator based read handle
105+%endif
106+
107+%if %{build520}
108+%package 520
109+IPS_package_name: library/perl-5/%{ips_cpan_name}-520
110+Summary: Iterator based read handle
111+BuildRequires: runtime/perl-520 = *
112+BuildRequires: library/perl-5/extutils-makemaker-520
113+BuildRequires: library/perl-5/asa-520
114+Requires: runtime/perl-520 = *
115+Requires: library/perl-5/%{ips_cpan_name}
116+Requires: library/perl-5/asa-520
117+Requires: library/perl-5/io-string-520
118+Requires: library/perl-5/parent-520
119+Requires: library/perl-5/scalar-list-utils-520
120+Requires: library/perl-5/sub-exporter-520
121+Requires: library/perl-5/test-simple-520
122+
123+%description 520
124+Iterator based read handle
125+%endif
126+
127+
128+%prep
129+%setup -q -n %{cpan_name}-%{version}
130+rm -rf %{buildroot}
131+
132+%build
133+build_with_makefile.pl_for() {
134+ perl_ver=$1
135+ test=$2
136+ bindir="/usr/perl5/${perl_ver}/bin"
137+ vendor_dir="/usr/perl5/vendor_perl/${perl_ver}"
138+
139+ export PERL5LIB=${vendor_dir}
140+ ${bindir}/perl Makefile.PL PREFIX=%{_prefix} \
141+ DESTDIR=$RPM_BUILD_ROOT \
142+ LIB=${vendor_dir}
143+ make
144+ [ x${test} = 'xwithout_test' ] || make test
145+ make pure_install
146+}
147+
148+build_with_build.pl_for() {
149+ perl_ver=$1
150+ test=$2
151+ bindir="/usr/perl5/${perl_ver}/bin"
152+ vendor_dir="/usr/perl5/vendor_perl/${perl_ver}"
153+
154+ export PERL5LIB=${vendor_dir}
155+ ${bindir}/perl Build.PL \
156+ --installdirs vendor \
157+ --destdir $RPM_BUILD_ROOT
158+ ${bindir}/perl ./Build
159+ [ x${test} = 'xwithout_test' ] || ${bindir}/perl ./Build test
160+ ${bindir}/perl ./Build install --destdir $RPM_BUILD_ROOT
161+}
162+
163+modify_bin_dir() {
164+ perl_ver=$1
165+ if [ -d $RPM_BUILD_ROOT/usr/bin ]
166+ then
167+ [ -d $RPM_BUILD_ROOT/usr/perl5/${perl_ver} ] || mkdir -p $RPM_BUILD_ROOT/usr/perl5/${perl_ver}
168+ mv $RPM_BUILD_ROOT/usr/bin $RPM_BUILD_ROOT/usr/perl5/${perl_ver}/bin
169+ fi
170+
171+ if [ -d $RPM_BUILD_ROOT/usr/perl5/${perl_ver}bin ]
172+ then
173+ for i in $RPM_BUILD_ROOT/usr/perl5/${perl_ver}bin/*
174+ do
175+ sed -ibak -e "s/\/usr\/bin\/env ruby/\/usr\/perl5\/${perl-ver}\/bin\/ruby/" ${I}
176+ [ -f ${i}.bak] || rm ${i}.bak
177+ done
178+ fi
179+}
180+
181+modify_man_dir() {
182+ perl_ver=$1
183+ if [ -d $RPM_BUILD_ROOT/usr/perl5/${perl_ver}/man ]
184+ then
185+ if [ -d $RPM_BUILD_ROOT%{_datadir}/man ]
186+ then
187+ rm -rf $RPM_BUILD_ROOT/usr/perl5/${perl_ver}/man
188+ else
189+ mkdir -p $RPM_BUILD_ROOT%{_datadir}
190+ mv $RPM_BUILD_ROOT/usr/perl5/${perl_ver}/man $RPM_BUILD_ROOT%{_datadir}/
191+ rm -rf $RPM_BUILD_ROOT/usr/perl5/${perl_ver}/man
192+ fi
193+ rmdir $RPM_BUILD_ROOT/usr/perl5/${perl_ver}
194+ fi
195+}
196+
197+build_for() {
198+ if [ -f Build.PL ];
199+ then
200+ build_with_build.pl_for $*
201+ elif [ -f Makefile.PL ];
202+ then
203+ build_with_makefile.pl_for $*
204+ fi
205+
206+ modify_bin_dir $*
207+ modify_man_dir $*
208+}
209+
210+# To build without test, pass 'without_test' to build_for commaond.
211+# like 'build_for version without_test'
212+%if %{build584}
213+build_for 5.8.4
214+%endif
215+
216+%if %{build510}
217+build_for 5.10
218+%endif
219+
220+%if %{build512}
221+build_for 5.12
222+%endif
223+
224+%if %{build516}
225+build_for 5.16
226+%endif
227+
228+%if %{build520}
229+build_for 5.20
230+%endif
231+
232+%install
233+if [ -d $RPM_BUILD_ROOT%{_prefix}/man ]
234+then
235+ mkdir -p $RPM_BUILD_ROOT%{_datadir}
236+ mv $RPM_BUILD_ROOT%{_prefix}/man $RPM_BUILD_ROOT%{_datadir}
237+fi
238+if [ -d $RPM_BUILD_ROOT%{_datadir}/man/man3 ]
239+then
240+ mv $RPM_BUILD_ROOT%{_datadir}/man/man3 $RPM_BUILD_ROOT%{_datadir}/man/man3perl
241+fi
242+
243+%clean
244+rm -rf %{buildroot}
245+
246+%files
247+%defattr(0755,root,bin,-)
248+%{_datadir}/man
249+
250+%if %{build584}
251+%files 584
252+%defattr(0755,root,bin,-)
253+%dir %attr (0755, root, sys) /usr
254+/usr/perl5/vendor_perl/5.8.4
255+%if %{include_executable}
256+/usr/perl5/5.8.4
257+%endif
258+%endif
259+
260+%if %{build510}
261+%files 510
262+%defattr(0755,root,bin,-)
263+%dir %attr (0755, root, sys) /usr
264+/usr/perl5/vendor_perl/5.10
265+%if %{include_executable}
266+/usr/perl5/5.1.0
267+%endif
268+%endif
269+
270+%if %{build512}
271+%files 512
272+%defattr(0755,root,bin,-)
273+%dir %attr (0755, root, sys) /usr
274+/usr/perl5/vendor_perl/5.12
275+%if %{include_executable}
276+/usr/perl5/5.12
277+%endif
278+%endif
279+
280+%if %{build516}
281+%files 516
282+%defattr(0755,root,bin,-)
283+%dir %attr (0755, root, sys) /usr
284+/usr/perl5/vendor_perl/5.16
285+%if %{include_executable}
286+/usr/perl5/5.16
287+%endif
288+%endif
289+
290+%if %{build520}
291+%files 520
292+%defattr(0755,root,bin,-)
293+%dir %attr (0755, root, sys) /usr
294+/usr/perl5/vendor_perl/5.20
295+%if %{include_executable}
296+/usr/perl5/5.20
297+%endif
298+%endif
299+
300+
301+%changelog
302+* Sun Nov 15 2015 - Fumihisa TONAKA <fumi.ftnk@gmail.com>
303+- initial commit
Show on old repository browser