elinks.spec 4.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142
  1. ##
  2. ## elinks.spec -- OpenPKG RPM Package Specification
  3. ## Copyright (c) 2000-2009 OpenPKG Foundation e.V. <http://openpkg.net/>
  4. ##
  5. ## Permission to use, copy, modify, and distribute this software for
  6. ## any purpose with or without fee is hereby granted, provided that
  7. ## the above copyright notice and this permission notice appear in all
  8. ## copies.
  9. ##
  10. ## THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESSED OR IMPLIED
  11. ## WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
  12. ## MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
  13. ## IN NO EVENT SHALL THE AUTHORS AND COPYRIGHT HOLDERS AND THEIR
  14. ## CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
  15. ## SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
  16. ## LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF
  17. ## USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND
  18. ## ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
  19. ## OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT
  20. ## OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
  21. ## SUCH DAMAGE.
  22. ##
  23. # package information
  24. Name: elinks
  25. Summary: Interactive Full-Screen Client for HTTP/HTTPS/FTP Protocols
  26. URL: http://elinks.cz/
  27. Vendor: Stranka Mikulase Patocky, Jonas Fonseca
  28. Packager: OpenPKG Foundation e.V.
  29. Distribution: OpenPKG Community
  30. Class: EVAL
  31. Group: Web
  32. License: GPL
  33. Version: 0.12pre5
  34. Release: 20090708
  35. # package options
  36. %option with_ssl yes
  37. %option with_idn yes
  38. %option with_js yes
  39. %option with_cgi no
  40. # list of sources
  41. Source0: http://elinks.cz/download/elinks-%{version}.tar.gz
  42. # build information
  43. Prefix: %{l_prefix}
  44. BuildRoot: %{l_buildroot}
  45. BuildPreReq: OpenPKG, openpkg >= 20040130, make, pkgconfig
  46. PreReq: OpenPKG, openpkg >= 20040130
  47. BuildPreReq: expat, zlib, bzip2, libiconv
  48. PreReq: expat, zlib, bzip2, libiconv
  49. %if "%{with_ssl}" == "yes"
  50. BuildPreReq: openssl
  51. PreReq: openssl
  52. %endif
  53. %if "%{with_js}" == "yes"
  54. BuildPreReq: js
  55. PreReq: js
  56. %endif
  57. %if "%{with_idn}" == "yes"
  58. BuildPreReq: libidn
  59. PreReq: libidn
  60. %endif
  61. AutoReq: no
  62. AutoReqProv: no
  63. %description
  64. ELinks is an advanced and well-established feature-rich text mode
  65. web browser. ELinks can render both frames and tables, is highly
  66. customizable and can be extended via Lua or Guile scripts. It is
  67. very portable and runs on a variety of platforms.
  68. %track
  69. prog elinks = {
  70. version = %{version}
  71. url = http://elinks.cz/download/
  72. regex = elinks-(__VER__)\.tar\.gz
  73. }
  74. %prep
  75. %setup -q
  76. %build
  77. export CC="%{l_cc}"
  78. export CFLAGS="%{l_cflags -O}"
  79. export CPPFLAGS="%{l_cppflags}"
  80. export LDFLAGS="%{l_ldflags}"
  81. export LIBS=""
  82. CFLAGS="$CFLAGS `pkg-config libidn js --cflags-only-other`"
  83. CPPFLAGS="$CPPFLAGS `pkg-config libidn js --cflags-only-I`"
  84. LDFLAGS="$LDFLAGS `pkg-config libidn js --libs-only-other`"
  85. LIBS="$LIBS `pkg-config libidn js --libs-only-l`"
  86. export TERM=vt100
  87. ./configure \
  88. --prefix=%{l_prefix} \
  89. --libdir=%{l_prefix}/lib/elinks \
  90. --enable-html-highlight \
  91. --enable-css \
  92. --enable-cookies \
  93. --enable-ftp \
  94. --with-libiconv=%{l_prefix} \
  95. %if "%{with_idn}" == "yes"
  96. --with-idn=%{l_prefix} \
  97. %else
  98. --without-idn \
  99. %endif
  100. %if "%with_ssl}" == "yes"
  101. --with-openssl=%{l_prefix} \
  102. %else
  103. --without-openssl \
  104. %endif
  105. --without-gnutls \
  106. %if "%{with_js}" == "yes"
  107. --enable-sm-scripting \
  108. --with-spidermonkey=%{l_prefix} \
  109. %else
  110. --disable-sm-scripting \
  111. %endif
  112. %if "%with_cgi}" == "yes"
  113. --enable-cgi \
  114. %else
  115. --disable-cgi \
  116. %endif
  117. --with-zlib \
  118. --with-bzlib \
  119. --disable-nls
  120. %{l_make} %{l_mflags}
  121. %install
  122. rm -rf $RPM_BUILD_ROOT
  123. %{l_make} %{l_mflags} install DESTDIR=$RPM_BUILD_ROOT
  124. strip $RPM_BUILD_ROOT%{l_prefix}/bin/* >/dev/null 2>&1 || true
  125. rm -rf $RPM_BUILD_ROOT%{l_prefix}/share/locale
  126. %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT %{l_files_std}
  127. %files -f files
  128. %clean
  129. rm -rf $RPM_BUILD_ROOT