aboutsummaryrefslogtreecommitdiff
path: root/GNUmakefile
diff options
context:
space:
mode:
authorChristian Hesse <mail@eworm.de>2017-01-11 10:50:02 +0100
committerChristian Hesse <mail@eworm.de>2017-01-11 22:40:38 +0100
commit3a6788c0d0b50e0cae902cfdc737d1b2624202ba (patch)
treed59d106c171a7b9746906283b007844313b7a52e /GNUmakefile
parent0a1b23e2a2467eb11673f507c044088f66386a55 (diff)
downloadvis-3a6788c0d0b50e0cae902cfdc737d1b2624202ba.tar.gz
vis-3a6788c0d0b50e0cae902cfdc737d1b2624202ba.tar.xz
single: allow to build self-extracting executable
This allows to create a self extracting executable. The standalone binary and lua files are extracted to /tmp/.vis-XXXXXX, vis is started with the given command line arguments, finally temporary files are removed. Signed-off-by: Christian Hesse <mail@eworm.de>
Diffstat (limited to 'GNUmakefile')
-rw-r--r--GNUmakefile5
1 files changed, 5 insertions, 0 deletions
diff --git a/GNUmakefile b/GNUmakefile
index dba2952..052c300 100644
--- a/GNUmakefile
+++ b/GNUmakefile
@@ -185,4 +185,9 @@ standalone: clean
CFLAGS="-I$(DEPS_INC) --static -Wl,--as-needed" LDFLAGS="-L$(DEPS_LIB)" CC=musl-gcc
PATH=$(DEPS_BIN):$$PATH $(MAKE)
+single: standalone
+ cp vis-single.sh vis-single
+ strip vis
+ tar c vis lua/ | gzip -9 >> vis-single
+
.PHONY: standalone local dependencies-common dependencies-local dependencies-clean