diff options
author | Darren Tucker <dtucker@zip.com.au> | 2017-12-01 17:11:47 +1100 |
---|---|---|
committer | Darren Tucker <dtucker@zip.com.au> | 2017-12-01 17:13:34 +1100 |
commit | 6c8a246437f612ada8541076be2414846d767319 (patch) | |
tree | c3e47dda594bd83a2f55d5485713fc4c71482ddf /contrib/cygwin | |
parent | 3058dd78d2e43ed0f82ad8eab8bb04b043a72023 (diff) |
Replace mkinstalldirs with mkdir -p.
Check for MIKDIR_P and use it instead of mkinstalldirs. Should fix "mkdir:
cannot create directory:... File exists" during "make install".
Patch from eb at emlix.com.
Diffstat (limited to 'contrib/cygwin')
-rw-r--r-- | contrib/cygwin/Makefile | 11 |
1 files changed, 6 insertions, 5 deletions
diff --git a/contrib/cygwin/Makefile b/contrib/cygwin/Makefile index a0261f48d..4b78cd950 100644 --- a/contrib/cygwin/Makefile +++ b/contrib/cygwin/Makefile | |||
@@ -13,6 +13,7 @@ defaultsdir=$(sysconfdir)/defaults/etc | |||
13 | inetdefdir=$(defaultsdir)/inetd.d | 13 | inetdefdir=$(defaultsdir)/inetd.d |
14 | PRIVSEP_PATH=/var/empty | 14 | PRIVSEP_PATH=/var/empty |
15 | INSTALL=/usr/bin/install -c | 15 | INSTALL=/usr/bin/install -c |
16 | MKDIR_P=$(srcdir)/mkinstalldirs | ||
16 | 17 | ||
17 | DESTDIR= | 18 | DESTDIR= |
18 | 19 | ||
@@ -23,7 +24,7 @@ all: | |||
23 | @echo | 24 | @echo |
24 | 25 | ||
25 | move-config-files: $(DESTDIR)$(sysconfdir)/ssh_config $(DESTDIR)$(sysconfdir)/sshd_config | 26 | move-config-files: $(DESTDIR)$(sysconfdir)/ssh_config $(DESTDIR)$(sysconfdir)/sshd_config |
26 | $(srcdir)/mkinstalldirs $(DESTDIR)$(defaultsdir) | 27 | $(MKDIR_P) $(DESTDIR)$(defaultsdir) |
27 | mv $(DESTDIR)$(sysconfdir)/ssh_config $(DESTDIR)$(defaultsdir) | 28 | mv $(DESTDIR)$(sysconfdir)/ssh_config $(DESTDIR)$(defaultsdir) |
28 | mv $(DESTDIR)$(sysconfdir)/sshd_config $(DESTDIR)$(defaultsdir) | 29 | mv $(DESTDIR)$(sysconfdir)/sshd_config $(DESTDIR)$(defaultsdir) |
29 | 30 | ||
@@ -31,11 +32,11 @@ remove-empty-dir: | |||
31 | rm -rf $(DESTDIR)$(PRIVSEP_PATH) | 32 | rm -rf $(DESTDIR)$(PRIVSEP_PATH) |
32 | 33 | ||
33 | install-inetd-config: | 34 | install-inetd-config: |
34 | $(srcdir)/mkinstalldirs $(DESTDIR)$(inetdefdir) | 35 | $(MKDIR_P) $(DESTDIR)$(inetdefdir) |
35 | $(INSTALL) -m 644 sshd-inetd $(DESTDIR)$(inetdefdir)/sshd-inetd | 36 | $(INSTALL) -m 644 sshd-inetd $(DESTDIR)$(inetdefdir)/sshd-inetd |
36 | 37 | ||
37 | install-sshdoc: | 38 | install-sshdoc: |
38 | $(srcdir)/mkinstalldirs $(DESTDIR)$(sshdocdir) | 39 | $(MKDIR_P) $(DESTDIR)$(sshdocdir) |
39 | -$(INSTALL) -m 644 $(srcdir)/CREDITS $(DESTDIR)$(sshdocdir)/CREDITS | 40 | -$(INSTALL) -m 644 $(srcdir)/CREDITS $(DESTDIR)$(sshdocdir)/CREDITS |
40 | -$(INSTALL) -m 644 $(srcdir)/ChangeLog $(DESTDIR)$(sshdocdir)/ChangeLog | 41 | -$(INSTALL) -m 644 $(srcdir)/ChangeLog $(DESTDIR)$(sshdocdir)/ChangeLog |
41 | -$(INSTALL) -m 644 $(srcdir)/LICENCE $(DESTDIR)$(sshdocdir)/LICENCE | 42 | -$(INSTALL) -m 644 $(srcdir)/LICENCE $(DESTDIR)$(sshdocdir)/LICENCE |
@@ -52,13 +53,13 @@ install-sshdoc: | |||
52 | -$(INSTALL) -m 644 $(srcdir)/TODO $(DESTDIR)$(sshdocdir)/TODO | 53 | -$(INSTALL) -m 644 $(srcdir)/TODO $(DESTDIR)$(sshdocdir)/TODO |
53 | 54 | ||
54 | install-cygwindoc: README | 55 | install-cygwindoc: README |
55 | $(srcdir)/mkinstalldirs $(DESTDIR)$(cygdocdir) | 56 | $(MKDIR_P) $(DESTDIR)$(cygdocdir) |
56 | $(INSTALL) -m 644 README $(DESTDIR)$(cygdocdir)/openssh.README | 57 | $(INSTALL) -m 644 README $(DESTDIR)$(cygdocdir)/openssh.README |
57 | 58 | ||
58 | install-doc: install-sshdoc install-cygwindoc | 59 | install-doc: install-sshdoc install-cygwindoc |
59 | 60 | ||
60 | install-scripts: ssh-host-config ssh-user-config | 61 | install-scripts: ssh-host-config ssh-user-config |
61 | $(srcdir)/mkinstalldirs $(DESTDIR)$(bindir) | 62 | $(MKDIR_P) $(DESTDIR)$(bindir) |
62 | $(INSTALL) -m 755 ssh-host-config $(DESTDIR)$(bindir)/ssh-host-config | 63 | $(INSTALL) -m 755 ssh-host-config $(DESTDIR)$(bindir)/ssh-host-config |
63 | $(INSTALL) -m 755 ssh-user-config $(DESTDIR)$(bindir)/ssh-user-config | 64 | $(INSTALL) -m 755 ssh-user-config $(DESTDIR)$(bindir)/ssh-user-config |
64 | 65 | ||