diff options
author | Brent Cook <bcook@openbsd.org> | 2015-07-12 22:15:04 -0500 |
---|---|---|
committer | Brent Cook <bcook@openbsd.org> | 2015-07-12 22:15:04 -0500 |
commit | c136688ad7cae73e656d2b31e154d30c9fd0bdaa (patch) | |
tree | ee12275a5af717cb9ea4b5cc15f5d25a4afac9a3 /apps | |
parent | e2903fcefcc412176bcf89b5e64c65c1ae9ab921 (diff) | |
parent | bda20bd13f8bf2063f915a3619db2292b38b6d88 (diff) | |
download | portable-c136688ad7cae73e656d2b31e154d30c9fd0bdaa.tar.gz portable-c136688ad7cae73e656d2b31e154d30c9fd0bdaa.tar.bz2 portable-c136688ad7cae73e656d2b31e154d30c9fd0bdaa.zip |
Land #107, improve default OPENSSLDIR install behavior
Diffstat (limited to 'apps')
-rw-r--r-- | apps/Makefile.am | 22 |
1 files changed, 21 insertions, 1 deletions
diff --git a/apps/Makefile.am b/apps/Makefile.am index 3604349..d756e10 100644 --- a/apps/Makefile.am +++ b/apps/Makefile.am | |||
@@ -84,4 +84,24 @@ noinst_HEADERS += s_apps.h | |||
84 | noinst_HEADERS += testdsa.h | 84 | noinst_HEADERS += testdsa.h |
85 | noinst_HEADERS += testrsa.h | 85 | noinst_HEADERS += testrsa.h |
86 | noinst_HEADERS += timeouts.h | 86 | noinst_HEADERS += timeouts.h |
87 | noinst_HEADERS += openssl.cnf | 87 | |
88 | EXTRA_DIST = cert.pem | ||
89 | EXTRA_DIST += openssl.cnf | ||
90 | EXTRA_DIST += x509v3.cnf | ||
91 | |||
92 | install-exec-hook: | ||
93 | @mkdir -p "$(DESTDIR)/$(OPENSSLDIR)" | ||
94 | @for i in cert.pem openssl.cnf x509v3.cnf; do \ | ||
95 | if [ ! -f "$(DESTDIR)/$(OPENSSLDIR)/$i" ]; then \ | ||
96 | $(INSTALL) -m 644 "$(srcdir)/$$i" "$(DESTDIR)/$(OPENSSLDIR)/$$i"; \ | ||
97 | else \ | ||
98 | echo " $(DESTDIR)/$(OPENSSLDIR)/$$i already exists, install will not overwrite"; \ | ||
99 | fi \ | ||
100 | done | ||
101 | |||
102 | uninstall-local: | ||
103 | @for i in cert.pem openssl.cnf x509v3.cnf; do \ | ||
104 | if cmp -s "$(DESTDIR)/$(OPENSSLDIR)/$$i" "$(srcdir)/$$i"; then \ | ||
105 | rm -f "$(DESTDIR)/$(OPENSSLDIR)/$$i"; \ | ||
106 | fi \ | ||
107 | done | ||