From 23e4bf9bac126770e78da5145bcb7db44c0a08a6 Mon Sep 17 00:00:00 2001 From: oldosfan Date: Fri, 30 Sep 2022 03:27:16 +0000 Subject: [PATCH] Add code to make tarballs * Imakefile (.PHONY): Add dist. (dist, 12to11.tar.gz): New targets. * README: Remove wayland-scanner dependency when not building from a repository checkout. --- Imakefile | 18 +++++++++++++++++- README | 6 ++++-- 2 files changed, 21 insertions(+), 3 deletions(-) diff --git a/Imakefile b/Imakefile index 2c79375..e5c1c01 100644 --- a/Imakefile +++ b/Imakefile @@ -119,7 +119,8 @@ $(OBJS): $(GENHEADERS) depend:: $(GENHEADERS) $(SRCS) cleandir:: - $(RM) $(GENHEADERS) $(GENSRCS) transfer_atoms.h short_types.txt + $(RM) $(GENHEADERS) $(GENSRCS) transfer_atoms.h short_types.txt \ + 12to11.tar.gz /* Undefine _BSD_SOURCE and _SVID_SOURCE, since both are deprecated and are also superseeded by _GNU_SOURCE. */ @@ -127,3 +128,18 @@ cleandir:: EXTRA_DEFINES := -D_GNU_SOURCE -U_BSD_SOURCE -U_SVID_SOURCE ComplexProgramTarget(12to11) + +.PHONY: dist +dist: 12to11.tar.gz + +DIST_FILES = Imakefile $(SRCS) media_types.txt shaders.txt *.awk *.xml \ + 12to11.man README libraries.def *.h + +/* Include files generated by wayland-scanner, so the target does not + need to have it installed. */ + +12to11.tar.gz: $(DIST_FILES) + rm -rf 12to11.tar.gz + tar -cvf 12to11.tar $(DIST_FILES) + gzip 12to11.tar + $(RM) 12to11.tar diff --git a/README b/README index 7a79c25..99a3893 100644 --- a/README +++ b/README @@ -89,12 +89,14 @@ This directory is organized as follows: those containing MIME types or shaders Building the source code is simple, provided that you have the -necessary libwayland-server library, wayland-scanner, pixman, XCB, and -X extension libraries installed: +necessary libwayland-server library, pixman, XCB, and X extension +libraries installed: xmkmf # to generate the Makefile make # to build the binary +wayland-scanner is also required when building from the repository. + Running the binary should be simple as well: ./12to11