recipe 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778
  1. # Build recipe for guile.
  2. #
  3. # Copyright (C) 2017 MMPG, <mmpg@vp.pl>
  4. #
  5. # Licensed under the Apache License, Version 2.0 (the "License");
  6. # you may not use this file except in compliance with the License.
  7. # You may obtain a copy of the License at
  8. #
  9. # http://www.apache.org/licenses/LICENSE-2.0
  10. #
  11. # Unless required by applicable law or agreed to in writing, software
  12. # distributed under the License is distributed on an "AS IS" BASIS,
  13. # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  14. # See the License for the specific language governing permissions and
  15. # limitations under the License.
  16. program=guile
  17. version=2.2.2
  18. release=1
  19. tarname=${program}-${version}.tar.lz
  20. # Remote source(s)
  21. fetch=http://ftp.gnu.org/pub/gnu/guile/$tarname
  22. description="
  23. Project GNU's extension language library.
  24. Guile is an implementation of the Scheme programming language, packaged
  25. as a library that can be linked into applications to give them their own
  26. extension language. Guile supports other languages as well, giving
  27. users of Guile-based applications a choice of languages.
  28. "
  29. homepage=https://www.gnu.org/software/guile/
  30. license=GPLv3+
  31. # Source documentation
  32. docs="ABOUT-NLS AUTHORS ChangeLog COPYING COPYING.LESSER GUILE-VERSION HACKING LICENSE NEWS README THANKS TODO"
  33. docsdir="${docdir}/${program}-${version}"
  34. build()
  35. {
  36. set -e
  37. unpack "${tardir}/$tarname"
  38. cd "$srcdir"
  39. ./configure CFLAGS="$QICFLAGS" LDFLAGS="$QILDFLAGS" \
  40. $configure_args \
  41. --libdir=/usr/lib${libSuffix} \
  42. --infodir=$infodir \
  43. --mandir=$mandir \
  44. --docdir=$docdir \
  45. --build="$(cc -dumpmachine)"
  46. make -j${jobs}
  47. make -j${jobs} html
  48. makeinfo --plaintext -o doc/r5rs/r5rs.txt doc/r5rs/r5rs.texi
  49. makeinfo --plaintext -o doc/ref/guile.txt doc/ref/guile.texi
  50. make -j${jobs} DESTDIR="$destdir" install
  51. make -j${jobs} DESTDIR="$destdir" install-html
  52. # Move libguile*-gdb.scm to GDB's autoload directory to avoid getting "not an ELF file" errors from ldconfig
  53. mv /usr/lib/libguile-*-gdb.scm /usr/share/gdb/auto-load/usr/lib
  54. # Copy documentation
  55. mkdir -p "${destdir}${docsdir}"
  56. for file in $docs
  57. do
  58. cp -p $file "${destdir}${docsdir}"
  59. done
  60. }