aboutsummaryrefslogtreecommitdiffstats
path: root/tools/lz4/patches/001-add-make-ENABLE_DOCS-configurable.patch
diff options
context:
space:
mode:
authorTony Butler <spudz76@gmail.com>2022-11-28 16:01:26 -0800
committerDaniel Golle <daniel@makrotopia.org>2023-01-16 23:51:10 +0000
commit8b12966d20bf10316752b3678d3999f83e564c60 (patch)
treeec1786d1a7c0126ae3f9bdc1be3b4c706c8c29f0 /tools/lz4/patches/001-add-make-ENABLE_DOCS-configurable.patch
parent539b52068a079801fe0955f7cf5f39e536a08803 (diff)
downloadupstream-8b12966d20bf10316752b3678d3999f83e564c60.tar.gz
upstream-8b12966d20bf10316752b3678d3999f83e564c60.tar.bz2
upstream-8b12966d20bf10316752b3678d3999f83e564c60.zip
tools/lz4: add `lz4` binaries
same as `packages/liblz4` modified to be a HOST/tools type build with unified liblz4 (this is also the dev package for liblz4) the image initramfs generator offers the LZ4 option but there was no executable to support it actually working Signed-off-by: Tony Butler <spudz76@gmail.com>
Diffstat (limited to 'tools/lz4/patches/001-add-make-ENABLE_DOCS-configurable.patch')
-rw-r--r--tools/lz4/patches/001-add-make-ENABLE_DOCS-configurable.patch60
1 files changed, 60 insertions, 0 deletions
diff --git a/tools/lz4/patches/001-add-make-ENABLE_DOCS-configurable.patch b/tools/lz4/patches/001-add-make-ENABLE_DOCS-configurable.patch
new file mode 100644
index 0000000000..5d6dca33f3
--- /dev/null
+++ b/tools/lz4/patches/001-add-make-ENABLE_DOCS-configurable.patch
@@ -0,0 +1,60 @@
++++ a/programs/Makefile 2022-08-15 15:45:31.000000000 -0700
+--- b/programs/Makefile 2022-11-28 16:34:21.315593784 -0800
+@@ -66,6 +66,7 @@
+ MD2ROFF = ronn
+ MD2ROFF_FLAGS = --roff --warnings --manual="User Commands" --organization="lz4 $(LZ4_VERSION)"
+
++ENABLE_DOCS ?= 1
+
+ default: lz4-release
+
+@@ -120,6 +121,7 @@
+ lz4c32 : $(SRCFILES)
+ $(CC) $(FLAGS) $^ -o $@$(EXT)
+
++ifeq ($(ENABLE_DOCS),1)
+ lz4.1: lz4.1.md $(LIBVER_SRC)
+ cat $< | $(MD2ROFF) $(MD2ROFF_FLAGS) | $(SED) -n '/^\.\\\".*/!p' > $@
+
+@@ -130,6 +132,7 @@
+
+ preview-man: clean-man man
+ man ./lz4.1
++endif
+
+ clean:
+ ifeq ($(WINBASED),yes)
+@@ -172,16 +175,19 @@
+
+ install: lz4
+ @echo Installing binaries in $(DESTDIR)$(bindir)
+- $(INSTALL_DIR) $(DESTDIR)$(bindir)/ $(DESTDIR)$(man1dir)/
++ $(INSTALL_DIR) $(DESTDIR)$(bindir)/
+ $(INSTALL_PROGRAM) lz4$(EXT) $(DESTDIR)$(bindir)/lz4$(EXT)
+ $(LN_SF) lz4$(EXT) $(DESTDIR)$(bindir)/lz4c$(EXT)
+ $(LN_SF) lz4$(EXT) $(DESTDIR)$(bindir)/lz4cat$(EXT)
+ $(LN_SF) lz4$(EXT) $(DESTDIR)$(bindir)/unlz4$(EXT)
++ifeq ($(ENABLE_DOCS),1)
+ @echo Installing man pages in $(DESTDIR)$(man1dir)
++ $(INSTALL_DIR) $(DESTDIR)$(man1dir)/
+ $(INSTALL_DATA) lz4.1 $(DESTDIR)$(man1dir)/lz4.1
+ $(LN_SF) lz4.1 $(DESTDIR)$(man1dir)/lz4c.1
+ $(LN_SF) lz4.1 $(DESTDIR)$(man1dir)/lz4cat.1
+ $(LN_SF) lz4.1 $(DESTDIR)$(man1dir)/unlz4.1
++endif
+ @echo lz4 installation completed
+
+ uninstall:
+@@ -189,10 +195,12 @@
+ $(RM) $(DESTDIR)$(bindir)/unlz4$(EXT)
+ $(RM) $(DESTDIR)$(bindir)/lz4$(EXT)
+ $(RM) $(DESTDIR)$(bindir)/lz4c$(EXT)
++ifeq ($(ENABLE_DOCS),1)
+ $(RM) $(DESTDIR)$(man1dir)/lz4.1
+ $(RM) $(DESTDIR)$(man1dir)/lz4c.1
+ $(RM) $(DESTDIR)$(man1dir)/lz4cat.1
+ $(RM) $(DESTDIR)$(man1dir)/unlz4.1
++endif
+ @echo lz4 programs successfully uninstalled
+
+ endif