blob: 0e713a2abe1a89e805bef4835185d76bc17f1521 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
|
# $NetBSD: Makefile,v 1.56 2022/10/24 14:12:56 wiz Exp $
SLIBVERSION= 3.2.7
DISTNAME= guile-slib-${SLIBVERSION}
CATEGORIES= devel
MASTER_SITES= # empty
DISTFILES= # empty
MAINTAINER= gdt@NetBSD.org
HOMEPAGE= http://people.csail.mit.edu/jaffer/SLIB
COMMENT= SLIB glue files for guile
GUILE_VERSION= guile20
GUILE_DIR= 2.0
PLIST_SUBST+= GUILE_DIR=${GUILE_DIR}
DEPENDS+= slib>=${SLIBVERSION}:../../devel/slib
NO_BUILD= yes
WRKSRC= ${WRKDIR}
# Instructions at
# https://www.gnu.org/software/guile/docs/docs-2.0/guile-ref/SLIB-installation.html
# say
# ln -s /usr/local/lib/slib /usr/local/share/guile/2.0/slib
# However, slib's default catalog location is guile/site/2.0, so we
# use that.
# There is a residual problem where after slib is used (and scheme
# code is compiled), building the package again can result in "Unbound
# variable: module-export-all!".
INSTALLATION_DIRS= guile/${GUILE_DIR}/share/guile/site/${GUILE_DIR}
# GUILE_LOAD_PATH enables (ice-9 slib) to find slib, needed because
# the symlink is in the DESTDIR but not yet in the installed system.
# GUILE_IMPLEMENTATION_PATH is an override to the slib catalog build
# procedure to write the catalog at that particular path instead of
# the default value of (%site-dir), which is
# /usr/pkg/guile/2.0/share/guile/site/2.0
# The RM commands are only needed if there is a failure in install and
# install is re-run.
do-install:
${RM} -f ${DESTDIR}${PREFIX}/guile/${GUILE_DIR}/share/guile/site/${GUILE_DIR}/slib
${LN} -sf ${PREFIX}/share/slib \
${DESTDIR}${PREFIX}/guile/${GUILE_DIR}/share/guile/site/${GUILE_DIR}/slib
${RM} -f ${DESTDIR}${PREFIX}/guile/${GUILE_DIR}/share/guile/site/${GUILE_DIR}/slibcat
cd ${DESTDIR}${PREFIX}/guile/${GUILE_DIR}/share/guile/site/${GUILE_DIR}/slib && \
GUILE_LOAD_PATH=${PREFIX}/share \
GUILE_IMPLEMENTATION_PATH=${DESTDIR}${PREFIX}/guile/${GUILE_DIR}/share/guile/site/${GUILE_DIR} \
${PREFIX}/guile/${GUILE_DIR}/bin/guile -q -c "(begin (use-modules (ice-9 slib)) (require 'new-catalog))"
.include "../../lang/${GUILE_VERSION}/buildlink3.mk"
.include "../../mk/bsd.pkg.mk"
|