perl-gd.spec 7.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188
  1. ##
  2. ## perl-gd.spec -- OpenPKG RPM Package Specification
  3. ## Copyright (c) 2000-2006 OpenPKG Foundation e.V. <http://openpkg.net/>
  4. ## Copyright (c) 2000-2006 Ralf S. Engelschall <http://engelschall.com/>
  5. ##
  6. ## Permission to use, copy, modify, and distribute this software for
  7. ## any purpose with or without fee is hereby granted, provided that
  8. ## the above copyright notice and this permission notice appear in all
  9. ## copies.
  10. ##
  11. ## THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  12. ## WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  13. ## MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
  14. ## IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR
  15. ## CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  16. ## SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  17. ## LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  18. ## USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  19. ## ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  20. ## OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  21. ## OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  22. ## SUCH DAMAGE.
  23. ##
  24. # versions of individual parts
  25. %define V_perl 5.8.7
  26. %define V_gd 2.30
  27. %define V_gdtextutil 0.86
  28. %define V_gdbarcode 1.15
  29. %define V_gdgraph 1.43
  30. %define V_gdgraph3d 0.56
  31. %define V_gdgraphmap 1.05
  32. %define V_chart 2.4.1
  33. %define V_chartthreed 0.01
  34. %define V_chartplot 0.11
  35. %define V_imagetimeline 0.11
  36. # package information
  37. Name: perl-gd
  38. Summary: Perl Modules for use with GD
  39. URL: http://www.cpan.org/
  40. Vendor: Perl Community
  41. Packager: OpenPKG
  42. Distribution: OpenPKG
  43. Class: BASE
  44. Group: Language
  45. License: GPL/Artistic
  46. Version: %{V_perl}
  47. Release: 20060126
  48. # list of sources
  49. Source0: http://www.cpan.org/modules/by-module/GD/GD-%{V_gd}.tar.gz
  50. Source1: http://www.cpan.org/modules/by-module/GD/GDTextUtil-%{V_gdtextutil}.tar.gz
  51. Source2: http://www.cpan.org/modules/by-module/GD/GD-Barcode-%{V_gdbarcode}.tar.gz
  52. Source3: http://www.cpan.org/modules/by-module/GD/GDGraph-%{V_gdgraph}.tar.gz
  53. Source4: http://www.cpan.org/modules/by-module/GD/GDGraph3d-%{V_gdgraph3d}.tar.gz
  54. Source5: http://www.cpan.org/modules/by-module/GD/GDGraph-Map-%{V_gdgraphmap}.tgz
  55. Source6: http://www.cpan.org/modules/by-module/Chart/Chart-%{V_chart}.tar.gz
  56. Source7: http://www.cpan.org/modules/by-module/Chart/Chart-ThreeD-%{V_chartthreed}.tar.gz
  57. Source8: http://www.cpan.org/modules/by-module/Chart/Chart-Plot-%{V_chartplot}.tar.gz
  58. Source9: http://www.cpan.org/modules/by-module/Image/Image-Timeline-%{V_imagetimeline}.tar.gz
  59. # build information
  60. Prefix: %{l_prefix}
  61. BuildRoot: %{l_buildroot}
  62. BuildPreReq: OpenPKG, openpkg >= 20040130, perl >= %{V_perl}, perl-openpkg >= %{V_perl}-20040126
  63. PreReq: OpenPKG, openpkg >= 20040130, perl >= %{V_perl}
  64. BuildPreReq: gd >= 2.0.7
  65. PreReq: gd >= 2.0.7
  66. AutoReq: no
  67. AutoReqProv: no
  68. %description
  69. Various modules for using the GD library from within the Perl
  70. language plus additional functionality for drawing various types of
  71. charts and graphs.
  72. - GD (%{V_gd})
  73. - GD::TextUtil (%{V_gdtextutil})
  74. - GD::Barcode (%{V_gdbarcode})
  75. - GD::Graph (%{V_gdgraph})
  76. - GD::Graph::3d (%{V_gdgraph3d})
  77. - GD::Graph::Map (%{V_gdgraphmap})
  78. - Chart (%{V_chart})
  79. - Chart::ThreeD (%{V_chartthreed})
  80. - Chart::Plot (%{V_chartplot})
  81. - Image::Timeline (%{V_imagetimeline})
  82. %track
  83. prog perl-gd:Chart = {
  84. version = %{V_chart}
  85. url = http://www.cpan.org/modules/by-module/Chart/
  86. regex = Chart-(__VER__)\.tar\.gz
  87. }
  88. prog perl-gd:Chart-Plot = {
  89. version = %{V_chartplot}
  90. url = http://www.cpan.org/modules/by-module/Chart/
  91. regex = Chart-Plot-(__VER__)\.tar\.gz
  92. }
  93. prog perl-gd:Chart-ThreeD = {
  94. version = %{V_chartthreed}
  95. url = http://www.cpan.org/modules/by-module/Chart/
  96. regex = Chart-ThreeD-(__VER__)\.tar\.gz
  97. }
  98. prog perl-gd:GD = {
  99. version = %{V_gd}
  100. url = http://www.cpan.org/modules/by-module/GD/
  101. regex = GD-(__VER__)\.tar\.gz
  102. }
  103. prog perl-gd:GD-Barcode = {
  104. version = %{V_gdbarcode}
  105. url = http://www.cpan.org/modules/by-module/GD/
  106. regex = GD-Barcode-(__VER__)\.tar\.gz
  107. }
  108. prog perl-gd:GDGraph = {
  109. version = %{V_gdgraph}
  110. url = http://www.cpan.org/modules/by-module/GD/
  111. regex = GDGraph-(__VER__)\.tar\.gz
  112. }
  113. prog perl-gd:GDGraph-Map = {
  114. version = %{V_gdgraphmap}
  115. url = http://www.cpan.org/modules/by-module/GD/
  116. regex = GDGraph-Map-(__VER__)\.tgz
  117. }
  118. prog perl-gd:GDGraph3d = {
  119. version = %{V_gdgraph3d}
  120. url = http://www.cpan.org/modules/by-module/GD/
  121. regex = GDGraph3d-(__VER__)\.tar\.gz
  122. }
  123. prog perl-gd:GDTextUtil = {
  124. version = %{V_gdtextutil}
  125. url = http://www.cpan.org/modules/by-module/GD/
  126. regex = GDTextUtil-(__VER__)\.tar\.gz
  127. }
  128. prog perl-gd:Image-Timeline = {
  129. version = %{V_imagetimeline}
  130. url = http://www.cpan.org/modules/by-module/Image/
  131. regex = Image-Timeline-(__VER__)\.tar\.gz
  132. }
  133. %prep
  134. %setup -q -c
  135. %setup -q -T -D -a 1
  136. %setup -q -T -D -a 2
  137. %setup -q -T -D -a 3
  138. %setup -q -T -D -a 4
  139. %setup -q -T -D -a 5
  140. %setup -q -T -D -a 6
  141. %setup -q -T -D -a 7
  142. %setup -q -T -D -a 8
  143. %setup -q -T -D -a 9
  144. %build
  145. %install
  146. rm -rf $RPM_BUILD_ROOT
  147. %{l_prefix}/bin/perl-openpkg prepare
  148. ( cd GD-%{V_gd}
  149. %{l_shtool} subst \
  150. -e 's/\(@INC = qw(\).*\();\)/\1\2/' \
  151. -e 's/\(@LIBPATH = qw(\).*\();\)/\1\2/' \
  152. Makefile.PL
  153. %{l_prefix}/bin/perl-openpkg \
  154. -A '-options GIF,PNG,JPEG,FT' \
  155. -A '-lib_gd_path %{l_prefix}' \
  156. -A '-lib_png_path %{l_prefix}' \
  157. -A '-lib_zlib_path %{l_prefix}' \
  158. -A '-lib_jpeg_path %{l_prefix}' \
  159. -A '-lib_ft_path %{l_prefix}' \
  160. configure build install
  161. ) || exit $?
  162. %{l_prefix}/bin/perl-openpkg -d %{SOURCE1} configure build install
  163. %{l_prefix}/bin/perl-openpkg -d %{SOURCE2} configure build install
  164. %{l_prefix}/bin/perl-openpkg -d %{SOURCE3} configure build install
  165. %{l_prefix}/bin/perl-openpkg -d %{SOURCE4} configure build install
  166. %{l_prefix}/bin/perl-openpkg -d %{SOURCE5} configure build install
  167. %{l_prefix}/bin/perl-openpkg -d %{SOURCE6} configure build install
  168. %{l_prefix}/bin/perl-openpkg -d %{SOURCE7} configure build install
  169. %{l_prefix}/bin/perl-openpkg -d %{SOURCE8} configure build install
  170. %{l_prefix}/bin/perl-openpkg -d %{SOURCE9} configure build install
  171. %{l_prefix}/bin/perl-openpkg -F perl-openpkg-files fixate cleanup
  172. %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT %{l_files_std} `cat perl-openpkg-files`
  173. %files -f files
  174. %clean
  175. rm -rf $RPM_BUILD_ROOT