rwhoisd.spec 4.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133
  1. ##
  2. ## rwhoisd.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. # package information
  25. Name: rwhoisd
  26. Summary: Referral WHOIS Daemon
  27. URL: http://www.rwhois.net/
  28. Vendor: Verisign GRS
  29. Packager: OpenPKG
  30. Distribution: OpenPKG
  31. Class: EVAL
  32. Group: WHOIS
  33. License: GPL
  34. Version: 1.5.9.6
  35. Release: 20060923
  36. # list of sources
  37. Source0: http://www.rwhois.net/ftp/rwhoisd-%{version}.tar.gz
  38. Source1: rc.rwhoisd
  39. Patch0: rwhoisd.patch
  40. # build information
  41. Prefix: %{l_prefix}
  42. BuildRoot: %{l_buildroot}
  43. BuildPreReq: OpenPKG, openpkg >= 20060823, make
  44. PreReq: OpenPKG, openpkg >= 20060823
  45. AutoReq: no
  46. AutoReqProv: no
  47. %description
  48. RWhois (Referral Whois) is a Directory Services protocol which
  49. extends and enhances the Whois concept in a hierarchical and
  50. scalable fashion. It focuses on the distribution of "network
  51. objects"--the data representing Internet resources or people--and
  52. uses the inherently hierarchical nature of these network objects
  53. (domain names, Internet Protocol (IP) networks, email addresses) to
  54. more accurately discover the requested information.
  55. %track
  56. prog rwhoisd = {
  57. comment = "rse: domain rwhois.net no longer assigned to project"
  58. version = %{version}
  59. url = http://www.rwhois.net/ftp/
  60. regex = rwhoisd-(\d+\.\d+\.\d+(\.\d+)*)\.tar\.gz
  61. }
  62. %prep
  63. %setup -q
  64. %patch -p0
  65. %{l_shtool} subst -s \
  66. -e "s;/usr/local/bin/perl;%{l_prefix}/bin/perl;g" \
  67. tools/scripts/rwhois.pl
  68. %build
  69. # configure package
  70. CC="%{l_cc}" \
  71. CFLAGS="%{l_cflags -O}" \
  72. ./configure \
  73. --prefix=%{l_prefix}
  74. # build package
  75. %{l_make} %{l_mflags}
  76. %install
  77. # install package
  78. rm -rf $RPM_BUILD_ROOT
  79. %{l_shtool} mkdir -f -p -m 755 \
  80. $RPM_BUILD_ROOT%{l_prefix} \
  81. $RPM_BUILD_ROOT%{l_prefix}/sbin \
  82. $RPM_BUILD_ROOT%{l_prefix}/etc/rwhoisd/samples \
  83. $RPM_BUILD_ROOT%{l_prefix}/var/rwhoisd \
  84. $RPM_BUILD_ROOT%{l_prefix}/share/rwhoisd \
  85. $RPM_BUILD_ROOT%{l_prefix}/man/man8
  86. %{l_make} %{l_mflags} install DESTDIR=$RPM_BUILD_ROOT
  87. # install documentation
  88. %{l_shtool} install -c -m 644 \
  89. doc/*.8 \
  90. $RPM_BUILD_ROOT%{l_prefix}/man/man8/
  91. %{l_shtool} install -c -m 644 \
  92. doc/operations_guide.* doc/rfc2167.txt \
  93. $RPM_BUILD_ROOT%{l_prefix}/share/rwhoisd/
  94. # post-adjust package
  95. strip $RPM_BUILD_ROOT%{l_prefix}/bin/* >/dev/null 2>&1 || true
  96. strip $RPM_BUILD_ROOT%{l_prefix}/sbin/* >/dev/null 2>&1 || true
  97. mv $RPM_BUILD_ROOT%{l_prefix}/etc/rwhoisd/samples/* \
  98. $RPM_BUILD_ROOT%{l_prefix}/etc/rwhoisd/
  99. rmdir $RPM_BUILD_ROOT%{l_prefix}/etc/rwhoisd/samples
  100. %{l_shtool} subst %{l_value -s -a} \
  101. -e "s;^root-dir: $RPM_BUILD_ROOT%{l_prefix};root-dir: %{l_prefix};g" \
  102. $RPM_BUILD_ROOT%{l_prefix}/etc/rwhoisd/rwhoisd.conf
  103. # install run-command script
  104. %{l_shtool} mkdir -f -p -m 755 \
  105. $RPM_BUILD_ROOT%{l_prefix}/etc/rc.d
  106. %{l_shtool} install -c -m 755 %{l_value -s -a} \
  107. %{SOURCE rc.rwhoisd} \
  108. $RPM_BUILD_ROOT%{l_prefix}/etc/rc.d/
  109. # determine installation files
  110. %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT \
  111. %{l_files_std} \
  112. '%config %{l_prefix}/etc/rwhoisd/rwhoisd.*' \
  113. '%attr(0750,%{l_rusr},%{l_rgrp}) %{l_prefix}/var/rwhoisd'
  114. %files -f files
  115. %clean
  116. rm -rf $RPM_BUILD_ROOT