rhino.spec 2.8 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788
  1. ##
  2. ## rhino.spec -- OpenPKG RPM Package Specification
  3. ## Copyright (c) 2000-2008 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 version
  24. %define V_opkg 1.7r2pre
  25. %define V_dist 1_7R2pre
  26. # package information
  27. Name: rhino
  28. Summary: JavaScript Engine for Java Virtual Machine
  29. URL: http://www.mozilla.org/rhino/
  30. Vendor: Mozilla Foundation
  31. Packager: OpenPKG Foundation e.V.
  32. Distribution: OpenPKG Community
  33. Class: EVAL
  34. Group: Language
  35. License: MPL
  36. Version: %{V_opkg}
  37. Release: 20080731
  38. # list of sources
  39. Source0: ftp://ftp.mozilla.org/pub/mozilla.org/js/rhino%{V_dist}.zip
  40. Source1: rhino.sh
  41. # build information
  42. Prefix: %{l_prefix}
  43. BuildRoot: %{l_buildroot}
  44. BuildPreReq: OpenPKG, openpkg >= 20060823, infozip
  45. PreReq: OpenPKG, openpkg >= 20060823
  46. AutoReq: no
  47. AutoReqProv: no
  48. %description
  49. Rhino is an open-source implementation of JavaScript 1.7 written
  50. entirely in Java. It is typically embedded into Java applications to
  51. provide scripting to end users through the Scripting Engine API of
  52. the JVM.
  53. %track
  54. prog rhino = {
  55. version = %{V_dist}
  56. url = ftp://ftp.mozilla.org/pub/mozilla.org/js/
  57. regex = rhino(__VER__R\d+)\.zip
  58. }
  59. %prep
  60. %setup -q -T -c
  61. unzip -q -x %{SOURCE0}
  62. %build
  63. %install
  64. rm -rf $RPM_BUILD_ROOT
  65. %{l_shtool} mkdir -f -p -m 755 \
  66. $RPM_BUILD_ROOT%{l_prefix}/bin \
  67. $RPM_BUILD_ROOT%{l_prefix}/lib/rhino
  68. %{l_shtool} install -c -m 755 %{l_value -s -a} \
  69. %{SOURCE rhino.sh} $RPM_BUILD_ROOT%{l_prefix}/bin/rhino
  70. %{l_shtool} install -c -m 644 \
  71. rhino%{V_dist}/js.jar $RPM_BUILD_ROOT%{l_prefix}/lib/rhino/
  72. %{l_rpmtool} files -v -ofiles -r$RPM_BUILD_ROOT %{l_files_std}
  73. %files -f files
  74. %clean
  75. rm -rf $RPM_BUILD_ROOT