diff options
Diffstat (limited to 'contrib/cygwin/Makefile')
-rw-r--r-- | contrib/cygwin/Makefile | 56 |
1 files changed, 56 insertions, 0 deletions
diff --git a/contrib/cygwin/Makefile b/contrib/cygwin/Makefile new file mode 100644 index 000000000..09e8ea2db --- /dev/null +++ b/contrib/cygwin/Makefile | |||
@@ -0,0 +1,56 @@ | |||
1 | srcdir=../.. | ||
2 | prefix=/usr | ||
3 | exec_prefix=$(prefix) | ||
4 | bindir=$(prefix)/bin | ||
5 | datadir=$(prefix)/share | ||
6 | docdir=$(datadir)/doc | ||
7 | sshdocdir=$(docdir)/openssh | ||
8 | cygdocdir=$(docdir)/Cygwin | ||
9 | sysconfdir=/etc | ||
10 | defaultsdir=$(sysconfdir)/defaults/etc | ||
11 | PRIVSEP_PATH=/var/empty | ||
12 | INSTALL=/usr/bin/install -c | ||
13 | |||
14 | DESTDIR= | ||
15 | |||
16 | all: | ||
17 | @echo | ||
18 | @echo "Use \`make cygwin-postinstall DESTDIR=[package directory]'" | ||
19 | @echo "Be sure having DESTDIR set correctly!" | ||
20 | @echo | ||
21 | |||
22 | move-config-files: $(DESTDIR)$(sysconfdir)/ssh_config $(DESTDIR)$(sysconfdir)/sshd_config | ||
23 | $(srcdir)/mkinstalldirs $(DESTDIR)$(defaultsdir) | ||
24 | mv $(DESTDIR)$(sysconfdir)/ssh_config $(DESTDIR)$(defaultsdir) | ||
25 | mv $(DESTDIR)$(sysconfdir)/sshd_config $(DESTDIR)$(defaultsdir) | ||
26 | |||
27 | remove-empty-dir: | ||
28 | rm -rf $(DESTDIR)$(PRIVSEP_PATH) | ||
29 | |||
30 | install-sshdoc: | ||
31 | $(srcdir)/mkinstalldirs $(DESTDIR)$(sshdocdir) | ||
32 | $(INSTALL) -m 644 $(srcdir)/CREDITS $(DESTDIR)$(sshdocdir)/CREDITS | ||
33 | $(INSTALL) -m 644 $(srcdir)/ChangeLog $(DESTDIR)$(sshdocdir)/ChangeLog | ||
34 | $(INSTALL) -m 644 $(srcdir)/LICENCE $(DESTDIR)$(sshdocdir)/LICENCE | ||
35 | $(INSTALL) -m 644 $(srcdir)/OVERVIEW $(DESTDIR)$(sshdocdir)/OVERVIEW | ||
36 | $(INSTALL) -m 644 $(srcdir)/README $(DESTDIR)$(sshdocdir)/README | ||
37 | $(INSTALL) -m 644 $(srcdir)/README.dns $(DESTDIR)$(sshdocdir)/README.dns | ||
38 | $(INSTALL) -m 644 $(srcdir)/README.privsep $(DESTDIR)$(sshdocdir)/README.privsep | ||
39 | $(INSTALL) -m 644 $(srcdir)/README.smartcard $(DESTDIR)$(sshdocdir)/README.smartcard | ||
40 | $(INSTALL) -m 644 $(srcdir)/RFC.nroff $(DESTDIR)$(sshdocdir)/RFC.nroff | ||
41 | $(INSTALL) -m 644 $(srcdir)/TODO $(DESTDIR)$(sshdocdir)/TODO | ||
42 | $(INSTALL) -m 644 $(srcdir)/WARNING.RNG $(DESTDIR)$(sshdocdir)/WARNING.RNG | ||
43 | |||
44 | install-cygwindoc: README | ||
45 | $(srcdir)/mkinstalldirs $(DESTDIR)$(cygdocdir) | ||
46 | $(INSTALL) -m 644 README $(DESTDIR)$(cygdocdir)/openssh.README | ||
47 | |||
48 | install-doc: install-sshdoc install-cygwindoc | ||
49 | |||
50 | install-scripts: ssh-host-config ssh-user-config | ||
51 | $(srcdir)/mkinstalldirs $(DESTDIR)$(bindir) | ||
52 | $(INSTALL) -m 755 ssh-host-config $(DESTDIR)$(bindir)/ssh-host-config | ||
53 | $(INSTALL) -m 755 ssh-user-config $(DESTDIR)$(bindir)/ssh-user-config | ||
54 | |||
55 | cygwin-postinstall: move-config-files remove-empty-dir install-doc install-scripts | ||
56 | @echo "Cygwin specific configuration finished." | ||