perl-net.spec 16 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398
  1. ##
  2. ## perl-net.spec -- OpenPKG RPM Package Specification
  3. ## Copyright (c) 2000-2007 OpenPKG Foundation e.V. <http://openpkg.net/>
  4. ## Copyright (c) 2000-2007 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.8
  26. %define V_math_base85 0.2
  27. %define V_net_ipv4addr 0.10
  28. %define V_net_ipv6addr 0.2
  29. %define V_net_daemon 0.43
  30. %define V_net_server 0.96
  31. %define V_net_ext 1.011
  32. %define V_libnet 1.21
  33. %define V_net_netmask 1.9015
  34. %define V_net_ftp_common 6.0
  35. %define V_net_snmp 5.2.0
  36. %define V_net_tftp 0.17
  37. %define V_net_telnet 3.03
  38. %define V_net_telnet_cisco 1.10
  39. %define V_plrpc 0.2020
  40. %define V_curl_easy 1.35
  41. %define V_net_imap_simple 1.14
  42. %define V_net_bgp 0.08
  43. %define V_net_pcap 0.14
  44. %define V_net_radius 1.56
  45. %define V_net_ip 1.25
  46. %define V_class_gomor 1.01
  47. %define V_net_packet 3.25
  48. %define V_net_xmpp 1.02
  49. %define V_net_jabber 2.0
  50. %define V_net_patricia 1.014
  51. %define V_net_irc 0.75
  52. %define V_ip_country 2.23
  53. %define V_io_socket_multicast 1.05
  54. %define V_net_growlclient 0.02
  55. # package information
  56. Name: perl-net
  57. Summary: Perl Modules for use with networks
  58. URL: http://www.cpan.org/
  59. Vendor: Perl Community
  60. Packager: OpenPKG Foundation e.V.
  61. Distribution: OpenPKG Community
  62. Class: BASE
  63. Group: Perl
  64. License: GPL/Artistic
  65. Version: %{V_perl}
  66. Release: 20070719
  67. # package options
  68. %option with_curl no
  69. %option with_pcap no
  70. # list of sources
  71. Source0: http://www.cpan.org/modules/by-module/Math/Math-Base85-%{V_math_base85}.tar.gz
  72. Source1: http://www.cpan.org/modules/by-module/Net/Net-IPv4Addr-%{V_net_ipv4addr}.tar.gz
  73. Source2: http://www.cpan.org/modules/by-module/Net/Net-IPv6Addr-%{V_net_ipv6addr}.tar.gz
  74. Source3: http://www.cpan.org/modules/by-module/Net/Net-Daemon-%{V_net_daemon}.tar.gz
  75. Source4: http://www.cpan.org/modules/by-module/Net/Net-Server-%{V_net_server}.tar.gz
  76. Source5: http://www.cpan.org/modules/by-module/Net/Net-ext-%{V_net_ext}.tar.gz
  77. Source6: http://www.cpan.org/modules/by-module/Net/libnet-%{V_libnet}.tar.gz
  78. Source7: http://www.cpan.org/modules/by-module/Net/Net-Netmask-%{V_net_netmask}.tar.gz
  79. Source8: http://www.cpan.org/modules/by-module/Net/Net-FTP-Common-%{V_net_ftp_common}.tar.gz
  80. Source9: http://www.cpan.org/modules/by-module/Net/Net-SNMP-%{V_net_snmp}.tar.gz
  81. Source10: http://www.cpan.org/modules/by-module/Net/Net-TFTP-%{V_net_tftp}.tar.gz
  82. Source11: http://www.cpan.org/modules/by-module/Net/Net-Telnet-%{V_net_telnet}.tar.gz
  83. Source12: http://www.cpan.org/modules/by-module/Net/Net-Telnet-Cisco-%{V_net_telnet_cisco}.tar.gz
  84. Source13: http://www.cpan.org/modules/by-module/Net/Net-Radius-%{V_net_radius}.tar.gz
  85. Source14: http://www.cpan.org/modules/by-module/RPC/PlRPC-%{V_plrpc}.tar.gz
  86. Source15: http://curl.haxx.se/libcurl/perl/Curl-easy-%{V_curl_easy}.tar.gz
  87. Source16: http://www.cpan.org/modules/by-module/Net/Net-IMAP-Simple-%{V_net_imap_simple}.tar.gz
  88. Source17: http://www.cpan.org/modules/by-module/Net/Net-BGP-%{V_net_bgp}.tar.gz
  89. Source18: http://www.cpan.org/modules/by-module/Net/Net-Pcap-%{V_net_pcap}.tar.gz
  90. Source19: http://www.cpan.org/modules/by-module/Class/Class-Gomor-%{V_class_gomor}.tar.gz
  91. Source20: http://www.cpan.org/modules/by-module/Net/Net-Packet-%{V_net_packet}.tar.gz
  92. Source21: http://www.cpan.org/modules/by-module/Net/Net-IP-%{V_net_ip}.tar.gz
  93. Source22: http://www.cpan.org/modules/by-module/Net/Net-XMPP-%{V_net_xmpp}.tar.gz
  94. Source23: http://www.cpan.org/modules/by-module/Net/Net-Jabber-%{V_net_jabber}.tar.gz
  95. Source24: http://www.cpan.org/modules/by-module/Net/Net-Patricia-%{V_net_patricia}.tar.gz
  96. Source25: http://www.cpan.org/modules/by-module/Net/Net-IRC-%{V_net_irc}.tar.gz
  97. Source26: http://www.cpan.org/modules/by-module/IP/IP-Country-%{V_ip_country}.tar.gz
  98. Source27: http://www.cpan.org/modules/by-module/IO/IO-Socket-Multicast-%{V_io_socket_multicast}.tar.gz
  99. Source28: http://www.cpan.org/modules/by-module/Net/Net-GrowlClient-%{V_net_growlclient}.tar.gz
  100. Patch0: perl-net.patch
  101. # build information
  102. Prefix: %{l_prefix}
  103. BuildRoot: %{l_buildroot}
  104. BuildPreReq: OpenPKG, openpkg >= 20040130, perl >= %{V_perl}, perl-openpkg >= %{V_perl}-20040126
  105. PreReq: OpenPKG, openpkg >= 20040130, perl >= %{V_perl}
  106. BuildPreReq: perl-crypto, perl-sys, perl-time, perl-xml, perl-util >= %{V_perl}-20040210
  107. PreReq: perl-crypto, perl-sys, perl-time, perl-xml, perl-util >= %{V_perl}-20040210
  108. %if "%{with_curl}" == "yes"
  109. BuildPreReq: curl
  110. PreReq: curl
  111. %endif
  112. %if "%{with_pcap}" == "yes"
  113. BuildPreReq: libpcap
  114. PreReq: libpcap
  115. %endif
  116. AutoReq: no
  117. AutoReqProv: no
  118. %description
  119. Perl modules for use with networks:
  120. - Net::Daemon (%{V_net_daemon})
  121. - Net::FTP (%{V_libnet})
  122. - Net::NNTP
  123. - Net::POP3
  124. - Net::SMTP
  125. - Net::SNPP
  126. - Net::Time
  127. - Net::FTP::Common (%{V_net_ftp_common})
  128. - Net::Gen (%{V_net_ext})
  129. - Net::Inet
  130. - Net::TCP
  131. - Net::TCP::Server
  132. - Net::UDP
  133. - Net::UNIX
  134. - Net::UNIX::Server
  135. - Net::Netmask (%{V_net_netmask})
  136. - Net::SNMP (%{V_net_snmp})
  137. - Net::Server (%{V_net_server})
  138. - Net::TFTP (%{V_net_tftp})
  139. - Net::Telnet (%{V_net_telnet})
  140. - Net::Telnet::Cisco (%{V_net_telnet_cisco})
  141. - Net::Radius (%{V_net_radius})
  142. - RPC::PlServer, RPC::PlClient (%{V_plrpc})
  143. - Net::IP (%{V_net_ip})
  144. %if "%{with_curl}" == "yes"
  145. - Curl::easy (%{V_curl_easy})
  146. %endif
  147. - Net::IMAP::Simple (%{V_net_imap_simple})
  148. - Net::BGP (%{V_net_bgp})
  149. %if "%{with_pcap}" == "yes"
  150. - Net::Pcap (%{V_net_pcap})
  151. - Net::Packet (%{V_net_packet})
  152. - Class::Gomor (%{V_class_gomor})
  153. %endif
  154. - Net::XMPP (%{V_net_xmpp})
  155. - Net::Jabber (%{V_net_jabber})
  156. - Net::Patricia (%{V_net_patricia})
  157. - Net::IPv4Addr (%{V_net_ipv4addr})
  158. - Net::IPv6Addr (%{V_net_ipv6addr})
  159. - Net::IRC (%{V_net_irc})
  160. - IP::Country (%{V_ip_country})
  161. - IO::Socket::Multicast (%{V_io_socket_multicast})
  162. - Net::GrowlClient (%{V_net_growlclient})
  163. %track
  164. prog perl-net:Curl-easy = {
  165. version = %{V_curl_easy}
  166. url = http://curl.haxx.se/libcurl/perl/
  167. regex = Curl-easy-(__VER__)\.tar\.gz
  168. }
  169. prog perl-net:Net-Netmask = {
  170. version = %{V_net_netmask}
  171. url = http://www.cpan.org/modules/by-module/Net/
  172. regex = Net-Netmask-(__VER__)\.tar\.gz
  173. }
  174. prog perl-net:Net-Ftp-Common = {
  175. version = %{V_net_ftp_common}
  176. url = http://www.cpan.org/modules/by-module/Net/
  177. regex = Net-FTP-Common-(__VER__)\.tar\.gz
  178. }
  179. prog perl-net:libnet = {
  180. version = %{V_libnet}
  181. url = http://www.cpan.org/modules/by-module/Net/
  182. regex = libnet-(__VER__)\.tar\.gz
  183. }
  184. prog perl-net:Net-BGP = {
  185. version = %{V_net_bgp}
  186. url = http://www.cpan.org/modules/by-module/Net/
  187. regex = Net-BGP-(__VER__)\.tar\.gz
  188. }
  189. prog perl-net:Net-Daemon = {
  190. version = %{V_net_daemon}
  191. url = http://www.cpan.org/modules/by-module/Net/
  192. regex = Net-Daemon-(__VER__)\.tar\.gz
  193. }
  194. prog perl-net:Net-ext = {
  195. version = %{V_net_ext}
  196. url = http://www.cpan.org/modules/by-module/Net/
  197. regex = Net-ext-(__VER__)\.tar\.gz
  198. }
  199. prog perl-net:Net-Imap-Simple = {
  200. version = %{V_net_imap_simple}
  201. url = http://www.cpan.org/modules/by-module/Net/
  202. regex = Net-IMAP-Simple-(__VER__)\.tar\.gz
  203. }
  204. prog perl-net:Net-Server = {
  205. version = %{V_net_server}
  206. url = http://www.cpan.org/modules/by-module/Net/
  207. regex = Net-Server-(__VER__)\.tar\.gz
  208. }
  209. prog perl-net:Net-SNMP = {
  210. version = %{V_net_snmp}
  211. url = http://www.cpan.org/modules/by-module/Net/
  212. regex = Net-SNMP-(__VER__)\.tar\.gz
  213. }
  214. prog perl-net:Net-Telnet = {
  215. version = %{V_net_telnet}
  216. url = http://www.cpan.org/modules/by-module/Net/
  217. regex = Net-Telnet-(__VER__)\.tar\.gz
  218. }
  219. prog perl-net:Net-Telnet-Cisco = {
  220. version = %{V_net_telnet_cisco}
  221. url = http://www.cpan.org/modules/by-module/Net/
  222. regex = Net-Telnet-Cisco-(__VER__)\.tar\.gz
  223. }
  224. prog perl-net:Net-TFTP = {
  225. version = %{V_net_tftp}
  226. url = http://www.cpan.org/modules/by-module/Net/
  227. regex = Net-TFTP-(__VER__)\.tar\.gz
  228. }
  229. prog perl-net:PlRPC = {
  230. version = %{V_plrpc}
  231. url = http://www.cpan.org/modules/by-module/RPC/
  232. regex = PlRPC-(__VER__)\.tar\.gz
  233. }
  234. prog perl-net:Net-Pcap = {
  235. version = %{V_net_pcap}
  236. url = http://www.cpan.org/modules/by-module/Net/
  237. regex = Net-Pcap-(__VER__)\.tar\.gz
  238. }
  239. prog perl-net:Net-Radius = {
  240. version = %{V_net_radius}
  241. url = http://www.cpan.org/modules/by-module/Net/
  242. regex = Net-Radius-(__VER__)\.tar\.gz
  243. }
  244. prog perl-net:Net-IP = {
  245. version = %{V_net_ip}
  246. url = http://www.cpan.org/authors/id/M/MA/MANU/
  247. regex = Net-IP-(__VER__)\.tar\.gz
  248. }
  249. prog perl-net:Net-Packet = {
  250. version = %{V_net_packet}
  251. url = http://www.cpan.org/modules/by-module/Net/
  252. regex = Net-Packet-(__VER__)\.tar\.gz
  253. }
  254. prog perl-net:Class-Gomor = {
  255. version = %{V_class_gomor}
  256. url = http://www.cpan.org/modules/by-module/Class/
  257. regex = Class-Gomor-(__VER__)\.tar\.gz
  258. }
  259. prog perl-net:Net-XMPP = {
  260. version = %{V_net_xmpp}
  261. url = http://www.cpan.org/modules/by-module/Net/
  262. regex = Net-XMPP-(__VER__)\.tar\.gz
  263. }
  264. prog perl-net:Net-Jabber = {
  265. version = %{V_net_jabber}
  266. url = http://www.cpan.org/modules/by-module/Net/
  267. regex = Net-Jabber-(__VER__)\.tar\.gz
  268. }
  269. prog perl-net:Net-Patricia = {
  270. version = %{V_net_patricia}
  271. url = http://www.cpan.org/modules/by-module/Net/
  272. regex = Net-Patricia-(__VER__)\.tar\.gz
  273. }
  274. prog perl-net:Net-IPv4Addr = {
  275. version = %{V_net_ipv4addr}
  276. url = http://www.cpan.org/modules/by-module/Net/
  277. regex = Net-IPv4Addr-(__VER__)\.tar\.gz
  278. }
  279. prog perl-net:Net-IPv6Addr = {
  280. version = %{V_net_ipv6addr}
  281. url = http://www.cpan.org/modules/by-module/Net/
  282. regex = Net-IPv6Addr-(__VER__)\.tar\.gz
  283. }
  284. prog perl-net:Math-Base85 = {
  285. version = %{V_math_base85}
  286. url = http://www.cpan.org/modules/by-module/Math/
  287. regex = Math-Base85-(__VER__)\.tar\.gz
  288. }
  289. prog perl-net:Net-IRC = {
  290. version = %{V_net_irc}
  291. url = http://www.cpan.org/modules/by-module/Net/
  292. regex = Net-IRC-(__VER__)\.tar\.gz
  293. }
  294. prog perl-net:IP-Country = {
  295. version = %{V_ip_country}
  296. url = http://www.cpan.org/modules/by-module/IP/
  297. regex = IP-Country-(__VER__)\.tar\.gz
  298. }
  299. prog perl-net:IO-Socket-Multicast = {
  300. version = %{V_io_socket_multicast}
  301. url = http://www.cpan.org/modules/by-module/IO/
  302. regex = IO-Socket-Multicast-(__VER__)\.tar\.gz
  303. }
  304. prog perl-net:Net-GrowlClient = {
  305. version = %{V_net_growlclient}
  306. url = http://www.cpan.org/modules/by-module/Net/
  307. regex = Net-GrowlClient-(__VER__)\.tar\.gz
  308. }
  309. %prep
  310. %setup -q -c
  311. %setup -q -T -D -a 1
  312. %setup -q -T -D -a 2
  313. %setup -q -T -D -a 3
  314. %setup -q -T -D -a 4
  315. %setup -q -T -D -a 5
  316. %setup -q -T -D -a 6
  317. %setup -q -T -D -a 7
  318. %setup -q -T -D -a 8
  319. %setup -q -T -D -a 9
  320. %setup -q -T -D -a 10
  321. %setup -q -T -D -a 11
  322. %setup -q -T -D -a 12
  323. %setup -q -T -D -a 13
  324. %setup -q -T -D -a 14
  325. %setup -q -T -D -a 15
  326. %setup -q -T -D -a 16
  327. %setup -q -T -D -a 17
  328. %setup -q -T -D -a 18
  329. %setup -q -T -D -a 19
  330. %setup -q -T -D -a 20
  331. %setup -q -T -D -a 21
  332. %setup -q -T -D -a 22
  333. %setup -q -T -D -a 23
  334. %setup -q -T -D -a 24
  335. %setup -q -T -D -a 25
  336. %setup -q -T -D -a 26
  337. %setup -q -T -D -a 27
  338. %setup -q -T -D -a 28
  339. sed <%{PATCH0} -e 's;@l_prefix@;%{l_prefix};g' | %{l_patch} -p0 -b
  340. %build
  341. %install
  342. rm -rf $RPM_BUILD_ROOT
  343. %{l_prefix}/bin/perl-openpkg prepare
  344. %{l_prefix}/bin/perl-openpkg -d %{SOURCE0} configure build install
  345. %{l_prefix}/bin/perl-openpkg -d %{SOURCE1} configure build install
  346. %{l_prefix}/bin/perl-openpkg -d %{SOURCE2} configure build install
  347. %{l_prefix}/bin/perl-openpkg -d %{SOURCE3} configure build install
  348. %{l_prefix}/bin/perl-openpkg -d %{SOURCE4} configure build install
  349. %{l_prefix}/bin/perl-openpkg -d %{SOURCE5} configure build install
  350. %{l_prefix}/bin/perl-openpkg -d %{SOURCE6} configure build install
  351. %{l_prefix}/bin/perl-openpkg -d %{SOURCE7} configure build install
  352. %{l_prefix}/bin/perl-openpkg -d %{SOURCE8} configure build install
  353. %{l_prefix}/bin/perl-openpkg -d %{SOURCE9} configure build install
  354. %{l_prefix}/bin/perl-openpkg -d %{SOURCE10} configure build install
  355. %{l_prefix}/bin/perl-openpkg -d %{SOURCE11} configure build install
  356. %{l_prefix}/bin/perl-openpkg -d %{SOURCE12} configure build install
  357. %{l_prefix}/bin/perl-openpkg -d %{SOURCE13} configure build install
  358. %{l_prefix}/bin/perl-openpkg -d %{SOURCE14} configure build install
  359. %if "%{with_curl}" == "yes"
  360. %{l_prefix}/bin/perl-openpkg -d %{SOURCE15} configure build install
  361. %endif
  362. %{l_prefix}/bin/perl-openpkg -d %{SOURCE16} configure build install
  363. %{l_prefix}/bin/perl-openpkg -d %{SOURCE17} configure build install
  364. %if "%{with_pcap}" == "yes"
  365. %{l_prefix}/bin/perl-openpkg -d %{SOURCE18} configure build install
  366. %{l_prefix}/bin/perl-openpkg -d %{SOURCE19} configure build install
  367. %{l_prefix}/bin/perl-openpkg -d %{SOURCE20} \
  368. -A "INC='-I. %{l_cppflags}'" \
  369. -A "LIBS='%{l_ldflags} -lpcap'" \
  370. configure build install
  371. %endif
  372. %{l_prefix}/bin/perl-openpkg -d %{SOURCE21} configure build install
  373. %{l_prefix}/bin/perl-openpkg -d %{SOURCE22} configure build install
  374. %{l_prefix}/bin/perl-openpkg -d %{SOURCE23} configure build install
  375. %{l_prefix}/bin/perl-openpkg -d %{SOURCE24} configure build install
  376. %{l_prefix}/bin/perl-openpkg -d %{SOURCE25} configure build install
  377. %{l_prefix}/bin/perl-openpkg -d %{SOURCE26} configure build install
  378. %{l_prefix}/bin/perl-openpkg -d %{SOURCE27} configure build install
  379. %{l_prefix}/bin/perl-openpkg -d %{SOURCE28} configure build install
  380. %{l_prefix}/bin/perl-openpkg -F perl-openpkg-files fixate cleanup
  381. %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT %{l_files_std} `cat perl-openpkg-files`
  382. %files -f files
  383. %clean
  384. rm -rf $RPM_BUILD_ROOT