annotate src/msys-gzip.mk @ 4253:32a7bea19bb1

msys-gzip: add .bat wrappers to shellscripts * tools/gen-bat-wrapper: new file * dist-files.mk: add gen-bat-wrapper * src/msys-gzip.mk: add find of shell script and create .bat file
author John D
date Mon, 21 Nov 2016 17:11:21 -0500
parents ae4193aad5fe
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
2956
dfa81fbfc1f5 msys binary packages
John W. Eaton <jwe@octave.org>
parents:
diff changeset
1 # This file is part of MXE.
dfa81fbfc1f5 msys binary packages
John W. Eaton <jwe@octave.org>
parents:
diff changeset
2 # See index.html for further information.
dfa81fbfc1f5 msys binary packages
John W. Eaton <jwe@octave.org>
parents:
diff changeset
3
dfa81fbfc1f5 msys binary packages
John W. Eaton <jwe@octave.org>
parents:
diff changeset
4 PKG := msys-gzip
dfa81fbfc1f5 msys binary packages
John W. Eaton <jwe@octave.org>
parents:
diff changeset
5 $(PKG)_IGNORE :=
3480
13be64f9f16d move version info from index.html to src/*.mk files
John W. Eaton <jwe@octave.org>
parents: 3012
diff changeset
6 $(PKG)_VERSION := 1.3.12-2
2956
dfa81fbfc1f5 msys binary packages
John W. Eaton <jwe@octave.org>
parents:
diff changeset
7 $(PKG)_CHECKSUM := a8954ccefa9732cd16b68e2fb50bfef281465c78
dfa81fbfc1f5 msys binary packages
John W. Eaton <jwe@octave.org>
parents:
diff changeset
8 $(PKG)_REMOTE_SUBDIR := gzip/gzip-$($(PKG)_VERSION)
dfa81fbfc1f5 msys binary packages
John W. Eaton <jwe@octave.org>
parents:
diff changeset
9 $(PKG)_SUBDIR :=
dfa81fbfc1f5 msys binary packages
John W. Eaton <jwe@octave.org>
parents:
diff changeset
10 $(PKG)_FILE := gzip-$($(PKG)_VERSION)-msys-1.0.13-bin.tar.lzma
dfa81fbfc1f5 msys binary packages
John W. Eaton <jwe@octave.org>
parents:
diff changeset
11 $(PKG)_URL := $(MSYS_BASE_URL)/$($(PKG)_REMOTE_SUBDIR)/$($(PKG)_FILE)/download
dfa81fbfc1f5 msys binary packages
John W. Eaton <jwe@octave.org>
parents:
diff changeset
12 $(PKG)_DEPS :=
dfa81fbfc1f5 msys binary packages
John W. Eaton <jwe@octave.org>
parents:
diff changeset
13
dfa81fbfc1f5 msys binary packages
John W. Eaton <jwe@octave.org>
parents:
diff changeset
14 define $(PKG)_UPDATE
3561
ae4193aad5fe revise and enable more $(PKG)_UPDATE rules
John W. Eaton <jwe@octave.org>
parents: 3480
diff changeset
15 $(WGET) -q -O- '$(MSYS_BASE_URL)/gzip' | \
ae4193aad5fe revise and enable more $(PKG)_UPDATE rules
John W. Eaton <jwe@octave.org>
parents: 3480
diff changeset
16 $(SED) -n 's,.*title="gzip-\([0-9][^"]*\)".*,\1,p' | \
ae4193aad5fe revise and enable more $(PKG)_UPDATE rules
John W. Eaton <jwe@octave.org>
parents: 3480
diff changeset
17 head -1
2956
dfa81fbfc1f5 msys binary packages
John W. Eaton <jwe@octave.org>
parents:
diff changeset
18 endef
dfa81fbfc1f5 msys binary packages
John W. Eaton <jwe@octave.org>
parents:
diff changeset
19
dfa81fbfc1f5 msys binary packages
John W. Eaton <jwe@octave.org>
parents:
diff changeset
20 define $(PKG)_BUILD
dfa81fbfc1f5 msys binary packages
John W. Eaton <jwe@octave.org>
parents:
diff changeset
21 mkdir -p '$(MSYS_BASE_DIR)'
4253
32a7bea19bb1 msys-gzip: add .bat wrappers to shellscripts
John D
parents: 3561
diff changeset
22 if test $(MXE_WINDOWS_BUILD) = "yes"; then \
32a7bea19bb1 msys-gzip: add .bat wrappers to shellscripts
John D
parents: 3561
diff changeset
23 for f in `find $(1)/bin -type f -exec grep -l '\/bin/sh$$' {} \;` ; do \
32a7bea19bb1 msys-gzip: add .bat wrappers to shellscripts
John D
parents: 3561
diff changeset
24 echo "file $$f"; \
32a7bea19bb1 msys-gzip: add .bat wrappers to shellscripts
John D
parents: 3561
diff changeset
25 $(TOP_DIR)/tools/gen-bat-wrapper `basename $$f` > $$f.bat; \
32a7bea19bb1 msys-gzip: add .bat wrappers to shellscripts
John D
parents: 3561
diff changeset
26 done; \
32a7bea19bb1 msys-gzip: add .bat wrappers to shellscripts
John D
parents: 3561
diff changeset
27 fi
2956
dfa81fbfc1f5 msys binary packages
John W. Eaton <jwe@octave.org>
parents:
diff changeset
28 cd '$(1)' && tar cf - . | ( cd '$(MSYS_BASE_DIR)'; tar xpf - )
3012
100e618349f7 Improve handling of prefix directories by defining HOST_PREFIX and
John W. Eaton <jwe@octave.org>
parents: 2956
diff changeset
29 mkdir -p '$(MSYS_INFO_DIR)'
100e618349f7 Improve handling of prefix directories by defining HOST_PREFIX and
John W. Eaton <jwe@octave.org>
parents: 2956
diff changeset
30 cd '$(1)' && find . > '$(MSYS_INFO_DIR)'/$(PKG).list
2956
dfa81fbfc1f5 msys binary packages
John W. Eaton <jwe@octave.org>
parents:
diff changeset
31 endef