yaml/yaml.spec

changeset 591
f65313225f8a
parent 590
488716b6db75
equal deleted inserted replaced
2:a70f9eb8d725 3:fe4b50794c3a
1 ## 1 ##
2 ## yaml.spec -- OpenPKG RPM Package Specification 2 ## yaml.spec -- OpenPKG RPM Package Specification
3 ## Copyright (c) 2000-2011 OpenPKG Foundation e.V. <http://openpkg.net/> 3 ## Copyright (c) 2000-2012 OpenPKG Foundation e.V. <http://openpkg.net/>
4 ## 4 ##
5 ## Permission to use, copy, modify, and distribute this software for 5 ## Permission to use, copy, modify, and distribute this software for
6 ## any purpose with or without fee is hereby granted, provided that 6 ## any purpose with or without fee is hereby granted, provided that
7 ## the above copyright notice and this permission notice appear in all 7 ## the above copyright notice and this permission notice appear in all
8 ## copies. 8 ## copies.
22 ## 22 ##
23 23
24 # package version 24 # package version
25 %define V_libsyck 0.70 25 %define V_libsyck 0.70
26 %define V_libyaml 0.1.4 26 %define V_libyaml 0.1.4
27 %define V_perl_yaml 0.80 27 %define V_perl_yaml 0.84
28 %define V_perl_yaml_syck 1.19 28 %define V_perl_yaml_syck 1.20
29 %define V_perl_yaml_tiny 1.50 29 %define V_perl_yaml_tiny 1.51
30 %define V_perl_yaml_appconfig 0.16 30 %define V_perl_yaml_appconfig 0.16
31 %define V_perl_yaml_libyaml 0.38 31 %define V_perl_yaml_libyaml 0.38
32 %define V_perl_yaml_active 1.100810 32 %define V_perl_yaml_active 1.100810
33 %define V_perl_yaml_object 0.04 33 %define V_perl_yaml_object 0.04
34 %define V_perl_io_yaml 0.08 34 %define V_perl_io_yaml 0.08
35 %define V_yaml_javascript 0.03 35 %define V_yaml_javascript 0.03
36 %define V_yaml_spec 2004-12-28 36 %define V_yaml_spec 2004-12-28
37 %define V_java_jvyaml 0.2.1 37 %define V_java_jvyaml 0.2.1
38 %define V_java_jyaml 1.3 38 %define V_java_jyaml 1.3
39 %define V_php_syck 0.9.3 39 %define V_php_syck 0.9.3
40 %define V_php_yaml 1.0.1 40 %define V_php_yaml 1.1.0RC2
41 %define V_php_spyc 0.4.5
41 42
42 # package information 43 # package information
43 Name: yaml 44 Name: yaml
44 Summary: YAML Ain't Markup Language (YAML) 45 Summary: YAML Ain't Markup Language (YAML)
45 URL: http://yaml.org/ 46 URL: http://yaml.org/
48 Distribution: OpenPKG Community 49 Distribution: OpenPKG Community
49 Class: PLUS 50 Class: PLUS
50 Group: Language 51 Group: Language
51 License: BSD/Artistic 52 License: BSD/Artistic
52 Version: 0 53 Version: 0
53 Release: 20120208 54 Release: 20120731
54 55
55 # package options 56 # package options
56 %option with_perl no 57 %option with_perl no
57 %option with_php no 58 %option with_php no
58 %option with_ruby no 59 %option with_ruby no
72 Source10: https://jvyaml.dev.java.net/files/documents/5215/41455/jvyaml-src-%{V_java_jvyaml}.tar.gz 73 Source10: https://jvyaml.dev.java.net/files/documents/5215/41455/jvyaml-src-%{V_java_jvyaml}.tar.gz
73 Source11: http://switch.dl.sourceforge.net/jyaml/jyaml-src-%{V_java_jyaml}.tgz 74 Source11: http://switch.dl.sourceforge.net/jyaml/jyaml-src-%{V_java_jyaml}.tgz
74 Source12: http://www.cpan.org/authors/id/E/EI/EIDOLON/YAML-Object-%{V_perl_yaml_object}.tar.gz 75 Source12: http://www.cpan.org/authors/id/E/EI/EIDOLON/YAML-Object-%{V_perl_yaml_object}.tar.gz
75 Source13: http://pecl.php.net/get/syck-%{V_php_syck}.tgz 76 Source13: http://pecl.php.net/get/syck-%{V_php_syck}.tgz
76 Source14: http://pecl.php.net/get/yaml-%{V_php_yaml}.tgz 77 Source14: http://pecl.php.net/get/yaml-%{V_php_yaml}.tgz
77 Source15: http://yaml.org/spec/history/%{V_yaml_spec}/%{V_yaml_spec}.pdf 78 Source15: http://spyc.googlecode.com/files/spyc-%{V_php_spyc}.zip
78 Source16: yaml.yml 79 Source16: http://yaml.org/spec/history/%{V_yaml_spec}/%{V_yaml_spec}.pdf
80 Source17: yaml.yml
79 Patch0: yaml.patch 81 Patch0: yaml.patch
80 82
81 # build information 83 # build information
82 Prefix: %{l_prefix} 84 BuildPreReq: OpenPKG, openpkg >= 20100101, make, bison
83 BuildRoot: %{l_buildroot} 85 PreReq: OpenPKG, openpkg >= 20100101
84 BuildPreReq: OpenPKG, openpkg >= 20060823, make, bison
85 PreReq: OpenPKG, openpkg >= 20060823
86 %if "%{with_perl}" == "yes" 86 %if "%{with_perl}" == "yes"
87 BuildPreReq: perl, perl-openpkg, perl-module 87 BuildPreReq: perl, perl-openpkg, perl-module
88 PreReq: perl 88 PreReq: perl
89 %endif 89 %endif
90 %if "%{with_php}" == "yes" 90 %if "%{with_php}" == "yes"
97 %endif 97 %endif
98 %if "%{with_java}" == "yes" 98 %if "%{with_java}" == "yes"
99 BuildPreReq: java, JAVA-JDK, ant 99 BuildPreReq: java, JAVA-JDK, ant
100 PreReq: java, JAVA-JDK 100 PreReq: java, JAVA-JDK
101 %endif 101 %endif
102 AutoReq: no
103 AutoReqProv: no
104 102
105 %description 103 %description
106 YAML Ain't Markup Language (YAML) is an international collaboration 104 YAML Ain't Markup Language (YAML) is an international collaboration
107 to make a sophisticated data serialization language which is both 105 to make a sophisticated data serialization language which is both
108 human readable and computationally powerful. This OpenPKG package 106 human readable and computationally powerful. This OpenPKG package
190 } 188 }
191 prog yaml:PHP-YAML = { 189 prog yaml:PHP-YAML = {
192 version = %{V_php_yaml} 190 version = %{V_php_yaml}
193 url = http://pecl.php.net/package/yaml 191 url = http://pecl.php.net/package/yaml
194 regex = yaml-(__VER__)\.tgz 192 regex = yaml-(__VER__)\.tgz
193 }
194 prog yaml:PHP-spyc = {
195 version = %{V_php_spyc}
196 url = http://spyc.googlecode.com/files/
197 regex = spyc-(__VER__)\.zip
195 } 198 }
196 199
197 %prep 200 %prep
198 %setup -q -c 201 %setup -q -c
199 %setup -q -T -D -a 1 202 %setup -q -T -D -a 1
208 %setup -q -T -D -a 10 211 %setup -q -T -D -a 10
209 %setup -q -T -D -a 11 212 %setup -q -T -D -a 11
210 %setup -q -T -D -a 12 213 %setup -q -T -D -a 12
211 %setup -q -T -D -a 13 214 %setup -q -T -D -a 13
212 %setup -q -T -D -a 14 215 %setup -q -T -D -a 14
216 %setup -q -T -D -a 15
213 %patch -p0 217 %patch -p0
214 218
215 %build 219 %build
216 # build YAML C API 220 # build YAML C API
217 ( cd yaml-%{V_libyaml} 221 ( cd yaml-%{V_libyaml}
226 # build Syck C API 230 # build Syck C API
227 ( cd syck-%{V_libsyck} 231 ( cd syck-%{V_libsyck}
228 CC="%{l_cc}" \ 232 CC="%{l_cc}" \
229 CFLAGS="%{l_cflags -O}" \ 233 CFLAGS="%{l_cflags -O}" \
230 ./configure \ 234 ./configure \
231 --prefix=%{l_prefix} \ 235 --prefix=%{l_prefix}
232 --disable-shared
233 %{l_make} %{l_mflags} 236 %{l_make} %{l_mflags}
234 ) || exit $? 237 ) || exit $?
235 238
236 # build PHP API 239 # build PHP API
237 %if "%{with_php}" == "yes" 240 %if "%{with_php}" == "yes"
287 %{l_prefix}/bin/ant 290 %{l_prefix}/bin/ant
288 ) || exit $? 291 ) || exit $?
289 %endif 292 %endif
290 293
291 %install 294 %install
292 # clean build cruft
293 rm -rf $RPM_BUILD_ROOT
294 295
295 # install YAML C API 296 # install YAML C API
296 ( cd yaml-%{V_libyaml} 297 ( cd yaml-%{V_libyaml}
297 %{l_make} %{l_mflags} install AM_MAKEFLAGS="DESTDIR=$RPM_BUILD_ROOT" 298 %{l_make} %{l_mflags} install AM_MAKEFLAGS="DESTDIR=$RPM_BUILD_ROOT"
298 ) || exit $? 299 ) || exit $?
307 ( cd syck-%{V_php_syck} 308 ( cd syck-%{V_php_syck}
308 %{l_make} %{l_mflags} install INSTALL_ROOT=$RPM_BUILD_ROOT 309 %{l_make} %{l_mflags} install INSTALL_ROOT=$RPM_BUILD_ROOT
309 ) || exit $? 310 ) || exit $?
310 ( cd yaml-%{V_php_yaml} 311 ( cd yaml-%{V_php_yaml}
311 %{l_make} %{l_mflags} install INSTALL_ROOT=$RPM_BUILD_ROOT 312 %{l_make} %{l_mflags} install INSTALL_ROOT=$RPM_BUILD_ROOT
313 ) || exit $?
314 ( cd spyc-%{V_php_spyc}
315 %{l_shtool} mkdir -f -p -m 755 \
316 $RPM_BUILD_ROOT%{l_prefix}/share/yaml
317 %{l_shtool} install -c -m 644 \
318 spyc.php $RPM_BUILD_ROOT%{l_prefix}/share/yaml/
312 ) || exit $? 319 ) || exit $?
313 %endif 320 %endif
314 321
315 # install Ruby API 322 # install Ruby API
316 %if "%{with_ruby}" == "yes" 323 %if "%{with_ruby}" == "yes"
366 %{l_files_std} `cat perl-openpkg-files` 373 %{l_files_std} `cat perl-openpkg-files`
367 374
368 %files -f files 375 %files -f files
369 376
370 %clean 377 %clean
371 rm -rf $RPM_BUILD_ROOT 378
372

mercurial