mutt.spec 3.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105
  1. ##
  2. ## mutt.spec -- OpenPKG RPM Specification
  3. ## Copyright (c) 2000-2001 Cable & Wireless Deutschland GmbH
  4. ## Copyright (c) 2000-2001 Ralf S. Engelschall <rse@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. %define V_mutt 1.3.22.1
  25. # package information
  26. Name: mutt
  27. Summary: Mail User Agent
  28. URL: http://www.mutt.org/
  29. Vendor: Michael Elkins
  30. Packager: The OpenPKG Project
  31. Distribution: OpenPKG [EXP]
  32. Group: Mail
  33. License: BSD
  34. Version: %{V_mutt}i
  35. Release: 2
  36. # list of sources
  37. Source0: ftp://ftp.mutt.org/pub/mutt/devel/mutt-%{V_mutt}i.tar.gz
  38. Source1: mailcap
  39. Source2: muttrc
  40. # build information
  41. Prefix: %{l_prefix}
  42. BuildRoot: %{l_buildroot}
  43. BuildPreReq: OpenPKG, openpkg >= 0.9-33, make, openssl, slang, libiconv
  44. PreReq: OpenPKG, openpkg >= 0.9-33
  45. AutoReq: no
  46. AutoReqProv: no
  47. %description
  48. Mutt is a small but very powerful text based program for reading
  49. electronic mail under Unix operating systems, including support
  50. color terminals, MIME, and a threaded sorting mode
  51. %prep
  52. %setup -q -n mutt-%{V_mutt}
  53. %build
  54. options=''
  55. case "%{l_target}" in
  56. *-freebsd* ) options="--enable-flock --disable-fcntl" ;;
  57. esac
  58. CC="%{l_cc}" \
  59. CFLAGS="%{l_cflags -O}" \
  60. ./configure \
  61. --prefix=%{l_prefix} \
  62. --sysconfdir=%{l_prefix}/etc/mutt \
  63. --with-docdir=%{l_prefix}/share/mutt \
  64. --with-slang=%{l_prefix} \
  65. --with-iconv=%{l_prefix} \
  66. --with-ssl=%{l_prefix} \
  67. --without-wc-funcs \
  68. --enable-pop \
  69. --enable-imap \
  70. --disable-nls \
  71. $options
  72. %{l_make} %{l_mflags}
  73. %install
  74. rm -rf $RPM_BUILD_ROOT
  75. %{l_rpmtool} subst "s;chmod 2755;true;" "s;chgrp mail;true;" -- Makefile
  76. %{l_make} %{l_mflags} install DESTDIR=$RPM_BUILD_ROOT
  77. rm -f $RPM_BUILD_ROOT%{l_prefix}/share/mutt/[A-Za-d]*
  78. rm -rf $RPM_BUILD_ROOT%{l_prefix}/share/mutt/html
  79. rm -rf $RPM_BUILD_ROOT%{l_prefix}/share/mutt/samples
  80. rm -f $RPM_BUILD_ROOT%{l_prefix}/bin/flea
  81. rm -f $RPM_BUILD_ROOT%{l_prefix}/man/man1/flea.1
  82. rm -f $RPM_BUILD_ROOT%{l_prefix}/bin/muttbug
  83. rm -f $RPM_BUILD_ROOT%{l_prefix}/man/man1/muttbug.1
  84. rm -f $RPM_BUILD_ROOT%{l_prefix}/bin/pgp*
  85. %{l_shtool} install -c -m 644 -e "s;@l_prefix@;%{l_prefix};g" \
  86. %{SOURCE muttrc} $RPM_BUILD_ROOT%{l_prefix}/etc/mutt/Muttrc
  87. %{l_shtool} install -c -m 644 -e "s;@l_prefix@;%{l_prefix};g" \
  88. %{SOURCE mailcap} $RPM_BUILD_ROOT%{l_prefix}/etc/mutt/mailcap
  89. strip $RPM_BUILD_ROOT%{l_prefix}/bin/* >/dev/null 2>&1 || true
  90. %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT %{l_files_std}
  91. %files -f files
  92. %clean
  93. rm -rf $RPM_BUILD_ROOT