diff options
author | Po-Chuan Hsieh <sunpoet@FreeBSD.org> | 2022-08-31 19:21:32 +0800 |
---|---|---|
committer | Po-Chuan Hsieh <sunpoet@FreeBSD.org> | 2022-08-31 19:40:51 +0800 |
commit | 3a0193f087441c73130b34f09ef4d391e78bf3ad (patch) | |
tree | a27e54d29ea092fbc64c34060fbc83af2489b453 /archivers | |
parent | 19a2c1ac739decdaa358cffd07ef7c67e817d2a6 (diff) | |
download | freebsd-ports-3a0193f087441c73130b34f09ef4d391e78bf3ad.zip |
archivers/zstd: Use MAKE_ENV instead of patch files
Diffstat (limited to 'archivers')
-rw-r--r-- | archivers/zstd/Makefile | 4 | ||||
-rw-r--r-- | archivers/zstd/files/patch-lib-Makefile | 55 | ||||
-rw-r--r-- | archivers/zstd/files/patch-programs-Makefile | 44 |
3 files changed, 4 insertions, 99 deletions
diff --git a/archivers/zstd/Makefile b/archivers/zstd/Makefile index c3d6153e9861..0f444ca11498 100644 --- a/archivers/zstd/Makefile +++ b/archivers/zstd/Makefile @@ -20,6 +20,10 @@ USES= gmake localbase:ldflags tar:zst ALL_TARGET= default #BINARY_ALIAS= gmd5sum=md5sum TEST_TARGET= test +MAKE_ENV= INSTALL_DATA="${INSTALL_DATA}" \ + INSTALL_MAN="${INSTALL_MAN}" \ + INSTALL_PROGRAM="${INSTALL_PROGRAM}" \ + INSTALL_SCRIPT="${INSTALL_SCRIPT}" USE_LDCONFIG= yes PLIST_SUB= PORTVERSION=${PORTVERSION} diff --git a/archivers/zstd/files/patch-lib-Makefile b/archivers/zstd/files/patch-lib-Makefile deleted file mode 100644 index a769fa8296c7..000000000000 --- a/archivers/zstd/files/patch-lib-Makefile +++ /dev/null @@ -1,55 +0,0 @@ -% sed -i .orig -e 's|INSTALL_|BSD_&|' lib/Makefile - ---- lib/Makefile.orig 2022-01-20 21:17:18 UTC -+++ lib/Makefile -@@ -292,8 +292,8 @@ else - INSTALL ?= install - endif - --INSTALL_PROGRAM ?= $(INSTALL) --INSTALL_DATA ?= $(INSTALL) -m 644 -+BSD_INSTALL_PROGRAM ?= $(INSTALL) -+BSD_INSTALL_DATA ?= $(INSTALL) -m 644 - - - libzstd.pc: libzstd.pc.in -@@ -314,7 +314,7 @@ install: install-pc install-static install-shared inst - .PHONY: install-pc - install-pc: libzstd.pc - [ -e $(DESTDIR)$(PKGCONFIGDIR) ] || $(INSTALL) -d -m 755 $(DESTDIR)$(PKGCONFIGDIR)/ -- $(INSTALL_DATA) libzstd.pc $(DESTDIR)$(PKGCONFIGDIR)/ -+ $(BSD_INSTALL_DATA) libzstd.pc $(DESTDIR)$(PKGCONFIGDIR)/ - - .PHONY: install-static - install-static: -@@ -322,7 +322,7 @@ install-static: - [ -e libzstd.a ] || $(MAKE) libzstd.a-release - [ -e $(DESTDIR)$(LIBDIR) ] || $(INSTALL) -d -m 755 $(DESTDIR)$(LIBDIR)/ - @echo Installing static library -- $(INSTALL_DATA) libzstd.a $(DESTDIR)$(LIBDIR) -+ $(BSD_INSTALL_DATA) libzstd.a $(DESTDIR)$(LIBDIR) - - .PHONY: install-shared - install-shared: -@@ -330,7 +330,7 @@ install-shared: - [ -e $(LIBZSTD) ] || $(MAKE) libzstd-release - [ -e $(DESTDIR)$(LIBDIR) ] || $(INSTALL) -d -m 755 $(DESTDIR)$(LIBDIR)/ - @echo Installing shared library -- $(INSTALL_PROGRAM) $(LIBZSTD) $(DESTDIR)$(LIBDIR) -+ $(BSD_INSTALL_PROGRAM) $(LIBZSTD) $(DESTDIR)$(LIBDIR) - ln -sf $(LIBZSTD) $(DESTDIR)$(LIBDIR)/libzstd.$(SHARED_EXT_MAJOR) - ln -sf $(LIBZSTD) $(DESTDIR)$(LIBDIR)/libzstd.$(SHARED_EXT) - -@@ -338,9 +338,9 @@ install-shared: - install-includes: - [ -e $(DESTDIR)$(INCLUDEDIR) ] || $(INSTALL) -d -m 755 $(DESTDIR)$(INCLUDEDIR)/ - @echo Installing includes -- $(INSTALL_DATA) zstd.h $(DESTDIR)$(INCLUDEDIR) -- $(INSTALL_DATA) zstd_errors.h $(DESTDIR)$(INCLUDEDIR) -- $(INSTALL_DATA) zdict.h $(DESTDIR)$(INCLUDEDIR) -+ $(BSD_INSTALL_DATA) zstd.h $(DESTDIR)$(INCLUDEDIR) -+ $(BSD_INSTALL_DATA) zstd_errors.h $(DESTDIR)$(INCLUDEDIR) -+ $(BSD_INSTALL_DATA) zdict.h $(DESTDIR)$(INCLUDEDIR) - - .PHONY: uninstall - uninstall: diff --git a/archivers/zstd/files/patch-programs-Makefile b/archivers/zstd/files/patch-programs-Makefile deleted file mode 100644 index ee30a0cacc19..000000000000 --- a/archivers/zstd/files/patch-programs-Makefile +++ /dev/null @@ -1,44 +0,0 @@ -% sed -i .orig -e 's|INSTALL_|BSD_&|' programs/Makefile - ---- programs/Makefile.orig 2022-01-20 21:17:18 UTC -+++ programs/Makefile -@@ -391,10 +391,10 @@ else - INSTALL ?= install - endif - --INSTALL_PROGRAM ?= $(INSTALL) --INSTALL_SCRIPT ?= $(INSTALL_PROGRAM) --INSTALL_DATA ?= $(INSTALL) -m 644 --INSTALL_MAN ?= $(INSTALL_DATA) -+BSD_INSTALL_PROGRAM ?= $(INSTALL) -+BSD_INSTALL_SCRIPT ?= $(INSTALL_PROGRAM) -+BSD_INSTALL_DATA ?= $(INSTALL) -m 644 -+BSD_INSTALL_MAN ?= $(INSTALL_DATA) - - .PHONY: install - install: -@@ -403,18 +403,18 @@ install: - [ -e $(DESTDIR)$(BINDIR) ] || $(INSTALL) -d -m 755 $(DESTDIR)$(BINDIR)/ - [ -e $(DESTDIR)$(MAN1DIR) ] || $(INSTALL) -d -m 755 $(DESTDIR)$(MAN1DIR)/ - @echo Installing binaries -- $(INSTALL_PROGRAM) zstd$(EXT) $(DESTDIR)$(BINDIR)/zstd$(EXT) -+ $(BSD_INSTALL_PROGRAM) zstd$(EXT) $(DESTDIR)$(BINDIR)/zstd$(EXT) - ln -sf zstd$(EXT) $(DESTDIR)$(BINDIR)/zstdcat$(EXT) - ln -sf zstd$(EXT) $(DESTDIR)$(BINDIR)/unzstd$(EXT) - ln -sf zstd$(EXT) $(DESTDIR)$(BINDIR)/zstdmt$(EXT) -- $(INSTALL_SCRIPT) zstdless $(DESTDIR)$(BINDIR)/zstdless -- $(INSTALL_SCRIPT) zstdgrep $(DESTDIR)$(BINDIR)/zstdgrep -+ $(BSD_INSTALL_SCRIPT) zstdless $(DESTDIR)$(BINDIR)/zstdless -+ $(BSD_INSTALL_SCRIPT) zstdgrep $(DESTDIR)$(BINDIR)/zstdgrep - @echo Installing man pages -- $(INSTALL_MAN) zstd.1 $(DESTDIR)$(MAN1DIR)/zstd.1 -+ $(BSD_INSTALL_MAN) zstd.1 $(DESTDIR)$(MAN1DIR)/zstd.1 - ln -sf zstd.1 $(DESTDIR)$(MAN1DIR)/zstdcat.1 - ln -sf zstd.1 $(DESTDIR)$(MAN1DIR)/unzstd.1 -- $(INSTALL_MAN) zstdgrep.1 $(DESTDIR)$(MAN1DIR)/zstdgrep.1 -- $(INSTALL_MAN) zstdless.1 $(DESTDIR)$(MAN1DIR)/zstdless.1 -+ $(BSD_INSTALL_MAN) zstdgrep.1 $(DESTDIR)$(MAN1DIR)/zstdgrep.1 -+ $(BSD_INSTALL_MAN) zstdless.1 $(DESTDIR)$(MAN1DIR)/zstdless.1 - @echo zstd installation completed - - .PHONY: uninstall |