From 04486663595085e91e5e766d58181c6e1b517c17 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Marc=20Andr=C3=A9=20Tanner?= Date: Wed, 31 May 2017 15:00:45 +0200 Subject: build: add a make docker target This should produce a self-contained vis binary for x86_64 Linux. --- Makefile | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/Makefile b/Makefile index 7950865..653657f 100644 --- a/Makefile +++ b/Makefile @@ -86,6 +86,16 @@ vis-single-payload.inc: $(EXECUTABLES) lua/* vis-single: vis-single.c vis-single-payload.inc ${CC} ${CFLAGS} ${CFLAGS_AUTO} ${CFLAGS_STD} ${CFLAGS_EXTRA} $< ${LDFLAGS} ${LDFLAGS_STD} ${LDFLAGS_AUTO} -larchive -lacl -lbz2 -llzma -o $@ +docker: clean + docker rm -f vis || true + docker build -t vis . + docker run --rm -d --name vis vis tail -f /dev/null + docker cp . vis:/tmp/vis + docker exec vis ./configure CC='cc --static' + docker exec vis make clean vis-single + docker cp vis:/tmp/vis/vis-single vis + docker kill vis + debug: clean @$(MAKE) CFLAGS_EXTRA='${CFLAGS_EXTRA} ${CFLAGS_DEBUG}' @@ -172,4 +182,4 @@ uninstall: @echo removing support files from ${DESTDIR}${SHAREPREFIX}/vis @rm -rf ${DESTDIR}${SHAREPREFIX}/vis -.PHONY: all clean dist install uninstall debug profile coverage test test-update luadoc luadoc-all luacheck man +.PHONY: all clean dist install uninstall debug profile coverage test test-update luadoc luadoc-all luacheck man docker -- cgit v1.2.3