perl-bytecode.spec 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118
  1. ##
  2. ## perl-bytecode.spec -- OpenPKG RPM Package Specification
  3. ## Copyright (c) 2000-2009 OpenPKG Foundation e.V. <http://openpkg.net/>
  4. ##
  5. ## Permission to use, copy, modify, and distribute this software for
  6. ## any purpose with or without fee is hereby granted, provided that
  7. ## the above copyright notice and this permission notice appear in all
  8. ## copies.
  9. ##
  10. ## THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  11. ## WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  12. ## MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
  13. ## IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR
  14. ## CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  15. ## SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  16. ## LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  17. ## USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  18. ## ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  19. ## OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  20. ## OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  21. ## SUCH DAMAGE.
  22. ##
  23. # versions of individual parts
  24. %define V_perl 5.10
  25. %define V_b_c 1.04_21
  26. %define V_b_utils 0.08
  27. %define V_b_recdeparse 0.04
  28. %define V_b_generate 1.20
  29. # package information
  30. Name: perl-bytecode
  31. Summary: Perl Modules for Bytecode Management
  32. URL: http://www.cpan.org/
  33. Vendor: Perl Community
  34. Packager: OpenPKG Foundation e.V.
  35. Distribution: OpenPKG Community
  36. Class: BASE
  37. Group: Perl
  38. License: GPL/Artistic
  39. Version: %{V_perl}
  40. Release: 20091108
  41. # list of sources
  42. Source0: http://www.cpan.org/authors/id/R/RU/RURBAN/B-C-%{V_b_c}.tar.gz
  43. Source1: http://www.cpan.org/modules/by-module/B/B-Utils-%{V_b_utils}.tar.gz
  44. Source2: http://www.cpan.org/modules/by-module/B/B-RecDeparse-%{V_b_recdeparse}.tar.gz
  45. Source3: http://www.cpan.org/modules/by-module/B/B-Generate-%{V_b_generate}.tar.gz
  46. # build information
  47. Prefix: %{l_prefix}
  48. BuildRoot: %{l_buildroot}
  49. BuildPreReq: OpenPKG, openpkg >= 20040130, perl >= %{V_perl}, perl-openpkg >= %{V_perl}-20040126
  50. PreReq: OpenPKG, openpkg >= 20040130, perl >= %{V_perl}
  51. BuildPreReq: perl-module
  52. PreReq: perl-module
  53. AutoReq: no
  54. AutoReqProv: no
  55. %description
  56. Perl modules for Bytecode Management:
  57. - B::Compile (%{V_b_c})
  58. - B::Utils (%{V_b_utils})
  59. - B::RecDeparse (%{V_b_recdeparse})
  60. - B::Generate (%{V_b_generate})
  61. %track
  62. prog perl-bytecode:B-C = {
  63. version = %{V_b_c}
  64. url = http://www.cpan.org/authors/id/R/RU/RURBAN/
  65. regex = B-C-(__VER__)\.tar\.gz
  66. }
  67. prog perl-bytecode:B-Utils = {
  68. version = %{V_b_utils}
  69. url = http://www.cpan.org/modules/by-module/B/
  70. regex = B-Utils-(__VER__)\.tar\.gz
  71. }
  72. prog perl-bytecode:B-RecDeparse = {
  73. version = %{V_b_recdeparse}
  74. url = http://www.cpan.org/modules/by-module/B/
  75. regex = B-RecDeparse-(__VER__)\.tar\.gz
  76. }
  77. prog perl-bytecode:B-Generate = {
  78. version = %{V_b_generate}
  79. url = http://www.cpan.org/modules/by-module/B/
  80. regex = B-Generate-(__VER__)\.tar\.gz
  81. }
  82. %prep
  83. %setup -q -c
  84. %setup -q -T -D -a 1
  85. %setup -q -T -D -a 2
  86. %setup -q -T -D -a 3
  87. %build
  88. %install
  89. rm -rf $RPM_BUILD_ROOT
  90. %{l_prefix}/bin/perl-openpkg prepare
  91. %{l_prefix}/bin/perl-openpkg -d %{SOURCE0} configure build install
  92. %{l_shtool} mkdir -f -p -m 755 \
  93. $RPM_BUILD_ROOT%{l_prefix}/bin
  94. %{l_shtool} install -c -m 755 \
  95. -e 's;#! perl;#!%{l_prefix}/bin/perl;' \
  96. B-C-%{V_b_c}/script/perlcc.PL \
  97. $RPM_BUILD_ROOT%{l_prefix}/bin/perlcc
  98. %{l_prefix}/bin/perl-openpkg -d %{SOURCE1} configure build install
  99. %{l_prefix}/bin/perl-openpkg -d %{SOURCE2} configure build install
  100. %{l_prefix}/bin/perl-openpkg -d %{SOURCE3} configure build install
  101. %{l_prefix}/bin/perl-openpkg -F perl-openpkg-files fixate cleanup
  102. %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT %{l_files_std} `cat perl-openpkg-files`
  103. %files -f files
  104. %clean
  105. rm -rf $RPM_BUILD_ROOT