recipe 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485
  1. # Build recipe for isl.
  2. #
  3. # Copyright (c) 2016-2021 Matias Fonzo, <selk@dragora.org>.
  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. # Exit immediately on any error
  17. set -e
  18. program=isl
  19. version=0.24
  20. release=2
  21. # Define a category for the output of the package name
  22. pkgcategory=libs
  23. tarname=${program}-${version}.tar.bz2
  24. # Remote source(s)
  25. fetch=https://libisl.sourceforge.io/$tarname
  26. description="
  27. A library of integers.
  28. ISL is a library for manipulating sets and relations of integer points
  29. bounded by linear constraints. Supported operations on sets include
  30. intersection, union, set difference, emptiness check, convex hull,
  31. (integer) affine hull, integer projection, and computing the
  32. lexicographic minimum using parametric integer programming.
  33. It also includes an ILP solver based on generalized basis reduction.
  34. "
  35. homepage=https://freshmeat.net/projects/isl
  36. license=MIT
  37. # Source documentation
  38. docs="AUTHORS ChangeLog LICENSE README"
  39. docsdir="${docdir}/${program}-${version}"
  40. build()
  41. {
  42. unpack "${tardir}/$tarname"
  43. cd "$srcdir"
  44. # Update for hosts based on musl
  45. cp -f "${worktree}/archive/common/config.guess" config.guess
  46. cp -f "${worktree}/archive/common/config.sub" config.sub
  47. # Set sane permissions
  48. chmod -R u+w,go-w,a+rX-s .
  49. ./configure CPPFLAGS="$QICPPFLAGS" \
  50. CFLAGS="$QICFLAGS" LDFLAGS="$QILDFLAGS" \
  51. $configure_args \
  52. --libdir=/usr/lib${libSuffix} \
  53. --enable-static \
  54. --enable-shared \
  55. --build="$(gcc -dumpmachine)"
  56. make -j${jobs} V=1
  57. make -j${jobs} DESTDIR="$destdir" install-strip
  58. # Move misplaced file(s) for GDB
  59. mkdir -p "${destdir}/usr/share/gdb/auto-load/usr/lib${libSuffix}"
  60. mv "${destdir}/usr/lib${libSuffix}"/*-gdb.py \
  61. "${destdir}/usr/share/gdb/auto-load/usr/lib${libSuffix}"
  62. # Copy documentation
  63. mkdir -p "${destdir}/$docsdir"
  64. cp -p $docs "${destdir}/$docsdir"
  65. }