aboutsummaryrefslogtreecommitdiffstats
path: root/x11-wm/stumpwm/Makefile
diff options
context:
space:
mode:
authorjrm <jrm@FreeBSD.org>2017-08-18 22:27:26 +0800
committerjrm <jrm@FreeBSD.org>2017-08-18 22:27:26 +0800
commit306ab7edc0d15f4de048d83d3717848945a9e422 (patch)
tree910409ad93e9b8d7a911b14c0e7423f4d06f3666 /x11-wm/stumpwm/Makefile
parent66f2bea4ba7109edc660e766c499b965c3c9b1d6 (diff)
downloadfreebsd-ports-gnome-306ab7edc0d15f4de048d83d3717848945a9e422.tar.gz
freebsd-ports-gnome-306ab7edc0d15f4de048d83d3717848945a9e422.tar.zst
freebsd-ports-gnome-306ab7edc0d15f4de048d83d3717848945a9e422.zip
x11-wm/stumpwm: re-add after deletion in 2014
Instead of bundling StumpWM, SBCL, and other libraries into one large executable, pull in SBCL and the other dependencies and use the simple CL framework that other FreeBSD CL ports use. Since StumpWM only supports running under SBCL, the port pulls in the *-sbcl port dependencies and conforms to the framework itself, except that it directly installs the fasl files instead of having an associated x11-wm/stumpwm-sbcl. This means no fasl files will be generated under ~/.cache/common-lisp/sbcl-*/ [1] and the package is only made up of the source, fasl files, and a few small, miscellaneous files. From a user perspective, they still get an executable, but it is a small shell script and the package is under 3 MB instead of around 65 MB. [1] Loading personal modules in ~/.stumpwmrc will still generate fasl files under ~/.cache/common-lisp/sbcl-*/
Diffstat (limited to 'x11-wm/stumpwm/Makefile')
-rw-r--r--x11-wm/stumpwm/Makefile87
1 files changed, 87 insertions, 0 deletions
diff --git a/x11-wm/stumpwm/Makefile b/x11-wm/stumpwm/Makefile
new file mode 100644
index 000000000000..d0b63b2f8650
--- /dev/null
+++ b/x11-wm/stumpwm/Makefile
@@ -0,0 +1,87 @@
+# Created by: Alejandro Pulver <alepulver@FreeBSD.org>
+# $FreeBSD$
+
+PORTNAME= stumpwm
+DISTVERSION= 1.0.0-168
+DISTVERSIONSUFFIX= -g49fdf94
+CATEGORIES= x11-wm lisp
+
+MAINTAINER= jrm@FreeBSD.org
+COMMENT= Tiling, keyboard driven Window Manager written in Common Lisp
+
+LICENSE= GPLv2
+LICENSE_FILE= ${WRKSRC}/COPYING
+
+BUILD_DEPENDS= cl-alexandria>=0:devel/cl-alexandria \
+ cl-alexandria-sbcl>=0:devel/cl-alexandria-sbcl \
+ cl-clx>=0:x11/cl-clx \
+ cl-clx-sbcl>=0:x11/cl-clx-sbcl \
+ cl-ppcre>=0:textproc/cl-ppcre \
+ cl-ppcre-sbcl>=0:textproc/cl-ppcre-sbcl \
+ texinfo>=0:print/texinfo
+RUN_DEPENDS= cl-alexandria>=0:devel/cl-alexandria \
+ cl-alexandria-sbcl>=0:devel/cl-alexandria-sbcl \
+ cl-clx>=0:x11/cl-clx \
+ cl-clx-sbcl>=0:x11/cl-clx-sbcl \
+ cl-ppcre>=0:textproc/cl-ppcre \
+ cl-ppcre-sbcl>=0:textproc/cl-ppcre-sbcl
+
+USE_GITHUB= yes
+GH_TAGNAME= 49fdf94
+USE_SBCL= yes
+
+PLIST_SUB= ASDF_PATHNAME="${ASDF_PATHNAME:S,^${PREFIX}/,,}" \
+ ASDF_REGISTRY="${ASDF_REGISTRY:S,^${PREFIX}/,,}"
+SUB_FILES= stumpwm
+SUB_LIST= ASDF_REGISTRY=${ASDF_REGISTRY} \
+ SBCL=${SBCL}
+
+INFO= ${PORTNAME}
+PORTDOCS= AUTHORS COPYING HACKING NEWS README.md
+PORTEXAMPLES= sample-stumpwmrc.lisp
+
+OPTIONS_DEFINE= DOCS EXAMPLES
+
+post-patch:
+ @${CP} ${WRKSRC}/load-stumpwm.lisp.in ${WRKSRC}/load-stumpwm.lisp
+ @${REINPLACE_CMD} -e 's|@STUMPWM_ASDF_DIR@|${ASDF_PATHNAME}|' \
+ ${WRKSRC}/load-stumpwm.lisp
+ ${CP} ${WRKSRC}/make-image.lisp.in ${WRKSRC}/make-image.lisp
+ @${REINPLACE_CMD} -e 's|@MODULE_DIR@|${DATADIR}|' \
+ ${WRKSRC}/make-image.lisp
+
+do-build:
+ (cd ${WRKSRC} && \
+ CL_SOURCE_REGISTRY="${WRKSRC}" \
+ ASDF_OUTPUT_TRANSLATIONS="/:" \
+ ${SBCL} \
+ --eval "(asdf:oos 'asdf:compile-op :${PORTNAME})" \
+ --eval "(load \"load-stumpwm.lisp\")" \
+ --eval "(load \"manual.lisp\")" \
+ --eval "(stumpwm::generate-manual)" \
+ --eval "(sb-ext:quit)" && \
+ makeinfo stumpwm.texi)
+
+do-install:
+ @${MKDIR} ${STAGEDIR}${ASDF_PATHNAME} \
+ ${STAGEDIR}${ASDF_REGISTRY} \
+ ${STAGEDIR}${ASDF_PATHNAME}/sbclfasl
+ ${INSTALL_SCRIPT} ${WRKDIR}/stumpwm ${STAGEDIR}${PREFIX}/bin
+ ${INSTALL_DATA} ${WRKSRC}/.dir-locals.el ${WRKSRC}/${PORTNAME}.asd \
+ ${WRKSRC}/*.lisp ${STAGEDIR}${ASDF_PATHNAME}
+ ${INSTALL_DATA} ${WRKSRC}/*.fasl ${STAGEDIR}${ASDF_PATHNAME}/sbclfasl
+ ${INSTALL_DATA} ${WRKSRC}/${PORTNAME}.info \
+ ${STAGEDIR}${PREFIX}/${INFO_PATH}
+ @${RLN} ${STAGEDIR}${ASDF_PATHNAME}/${PORTNAME}.asd \
+ ${STAGEDIR}${ASDF_REGISTRY}
+
+do-install-DOCS-on:
+ ${MKDIR} ${STAGEDIR}${DOCSDIR}
+ (cd ${WRKSRC} && ${INSTALL_DATA} ${PORTDOCS} ${STAGEDIR}${DOCSDIR})
+
+do-install-EXAMPLES-on:
+ ${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
+ ${INSTALL_DATA} ${WRKSRC}/${PORTEXAMPLES} ${STAGEDIR}/${EXAMPLESDIR}
+
+.include "${.CURDIR}/../../devel/cl-asdf/bsd.cl-asdf.mk"
+.include <bsd.port.mk>