recipes: xorg/mesa: upgraded to version 18.3.2
[dragora.git] / recipes / devel / guile / recipe
blob00340095f519fe1c3829d963c046cd12069365b1
1 # Build recipe for guile.
3 # Copyright (c) 2018 Matias Fonzo, <selk@dragora.org>.
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
9 #    http://www.apache.org/licenses/LICENSE-2.0
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.
17 program=guile
18 version=2.2.4
19 release=2
21 # Set 'outdir' for a nice and well-organized output directory
22 outdir="${outdir}/${arch}/devel"
24 tarname=${program}-${version}.tar.lz
26 # Remote source(s)
27 fetch=http://ftp.gnu.org/gnu/guile/$tarname
29 homepage=http://www.gnu.org/software/guile/
31 description="
32 The GNU Guile programming language.
34 Guile is designed to help programmers create flexible applications that
35 can be extended by users or other programmers with plug-ins, modules,
36 or scripts.  With Guile you can create applications and games for the
37 desktop, the Web, the command-line, and more.
39 For more information, visit:
40 $homepage
43 license="GPLv3+, LGPLv3+"
45 # Source documentation
46 docs="AUTHORS COPYING* ChangeLog GUILE-VERSION HACKING NEWS README THANKS"
47 docsdir="${docdir}/${program}-${version}"
49 build()
51     set -e
53     unpack "${tardir}/$tarname"
55     cd "$srcdir"
57     # Set sane permissions
58     chmod -R u+w,go-w,a+rX-s .
60     ./configure CFLAGS="$QICFLAGS" LDFLAGS="$QILDFLAGS" \
61      $configure_args \
62      --libdir=/usr/lib${libSuffix} \
63      --infodir=$infodir \
64      --mandir=$mandir \
65      --docdir=$docsdir \
66      --enable-static=no \
67      --enable-shared=yes \
68      --disable-rpath \
69      --with-threads \
70      --build="$(cc -dumpmachine)"
72     # Uncomment the following (two) commented lines if you want to
73     # build the documentation.  We do not build it by default in
74     # order to save 9M, approx.
76     make -j${jobs} V=1
77     #make V=1 html
78     make -j${jobs} DESTDIR="$destdir" install-strip
79     #make -j${jobs} DESTDIR="$destdir" install-html
81     # Delete generated charset.alias
82     rm -f "${destdir}/usr/lib${libSuffix}/charset.alias"
84     # Move misplaced file(s) for GDB
85     mkdir -p "${destdir}/usr/share/gdb/auto-load/usr/lib${libSuffix}"
86     mv "${destdir}/usr/lib${libSuffix}"/*-gdb.scm \
87        "${destdir}/usr/share/gdb/auto-load/usr/lib${libSuffix}"
89     # Compress info documents deleting index file for the package
90     if test -d "${destdir}/$infodir"
91     then
92         rm -f "${destdir}/${infodir}/dir"
93         lzip -9 "${destdir}/${infodir}"/*
94     fi
96     # Compress and link man pages (if needed)
97     if test -d "${destdir}/$mandir"
98     then
99         (
100             cd "${destdir}/$mandir"
101             find . -type f -exec lzip -9 '{}' +
102             find . -type l | while read -r file
103             do
104                 ln -sf "$(readlink -- "$file").lz" "${file}.lz"
105                 rm -- "$file"
106             done
107         )
108     fi
110     # Copy documentation
111     mkdir -p "${destdir}${docsdir}"
112     cp -p $docs "${destdir}${docsdir}"/