inetutils.spec 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125
  1. ##
  2. ## inetutils.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. # package information
  25. Name: inetutils
  26. Summary: GNU Internet Utilities
  27. URL: http://www.gnu.org/software/inetutils/
  28. Vendor: Free Software Foundation
  29. Packager: OpenPKG Foundation e.V.
  30. Distribution: OpenPKG Community
  31. Class: PLUS
  32. Group: Network
  33. License: GPL
  34. Version: 1.5
  35. Release: 20070710
  36. # package options
  37. %option with_legacy no
  38. # list of sources
  39. Source0: ftp://ftp.gnu.org/gnu/inetutils/inetutils-%{version}.tar.gz
  40. Patch0: inetutils.patch
  41. # build information
  42. Prefix: %{l_prefix}
  43. BuildRoot: %{l_buildroot}
  44. BuildPreReq: OpenPKG, openpkg >= 20040130, make
  45. PreReq: OpenPKG, openpkg >= 20040130
  46. BuildPreReq: ncurses
  47. PreReq: ncurses
  48. AutoReq: no
  49. AutoReqProv: no
  50. %description
  51. The GNU Internet Utilities are a collection of common network
  52. programs. Please note that specific to this OpenPKG version only a
  53. subset of the original GNU Internet Utilities is provided. Mainly we
  54. provide networking clients only.
  55. %track
  56. prog inetutils = {
  57. version = %{version}
  58. url = ftp://ftp.gnu.org/gnu/inetutils/
  59. regex = inetutils-(__VER__)\.tar\.gz
  60. }
  61. %prep
  62. %setup -q
  63. %patch -p0
  64. %build
  65. CC="%{l_cc}" \
  66. CFLAGS="%{l_cflags -O}" \
  67. CPPFLAGS="%{l_cppflags ncurses .}" \
  68. LDFLAGS="%{l_ldflags}" \
  69. ./configure \
  70. --prefix=%{l_prefix} \
  71. --mandir=%{l_prefix}/man \
  72. --infodir=%{l_prefix}/info \
  73. --program-prefix=g \
  74. --disable-servers \
  75. --disable-tftp \
  76. --disable-whois \
  77. --disable-libls \
  78. --disable-encryption \
  79. --disable-authentication \
  80. --without-krb4 \
  81. --without-krb5 \
  82. --without-wrap \
  83. --without-pam
  84. %{l_make} %{l_mflags -O}
  85. %install
  86. rm -rf $RPM_BUILD_ROOT
  87. %{l_make} %{l_mflags} install AM_MAKEFLAGS="DESTDIR=$RPM_BUILD_ROOT"
  88. strip $RPM_BUILD_ROOT%{l_prefix}/bin/* >/dev/null 2>&1 || true
  89. rm -f $RPM_BUILD_ROOT%{l_prefix}/info/dir
  90. for i in tftp syslog.conf ftpd inetd rexecd rlogind rshd syslogd talkd \
  91. telnetd tftpd; do
  92. rm -f $RPM_BUILD_ROOT%{l_prefix}/man/man?/g$i.?
  93. done
  94. %if "%{with_legacy}" == "yes"
  95. for d in $RPM_BUILD_ROOT%{l_prefix}/{bin,man/man?}; do
  96. for i in $d/*; do
  97. [ -f $i ] || continue
  98. source=`echo "$i" | sed -n -e 's;^.*/\([^/]\{1,\}\)$;\1;p'`
  99. target=`echo "$i" | sed -n -e 's;^\(.*/\)g\([^/]\{1,\}\)$;\1\2;p'`
  100. ln -s $source $target
  101. done
  102. done
  103. %endif
  104. %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT \
  105. %{l_files_std} \
  106. '%attr(4711,%{l_susr},%{l_sgrp}) %{l_prefix}/bin/gping' \
  107. '%attr(4711,%{l_susr},%{l_sgrp}) %{l_prefix}/bin/grcp' \
  108. '%attr(4711,%{l_susr},%{l_sgrp}) %{l_prefix}/bin/grlogin' \
  109. '%attr(4711,%{l_susr},%{l_sgrp}) %{l_prefix}/bin/grsh'
  110. %files -f files
  111. %clean
  112. rm -rf $RPM_BUILD_ROOT