From 871fe9107db22fd2a16ab287a894234ac2f6fdfd Mon Sep 17 00:00:00 2001 From: Richard Levitte Date: Mon, 21 Jun 2004 09:07:41 +0000 Subject: [PATCH] Make sure we don't try to loop over an empty EXHEADER. In the Makefiles where this was fixed by commenting away code, change it to check for an empty EXHEADER instead, so we have less hassle in a future where EXHEADER changes. PR: 900 --- fips/aes/Makefile | 12 +++++++----- fips/des/Makefile | 12 +++++++----- fips/dh/Makefile | 13 +++++++------ fips/dsa/Makefile | 13 +++++++------ fips/rsa/Makefile | 13 +++++++------ fips/sha1/Makefile | 12 +++++++----- 6 files changed, 42 insertions(+), 33 deletions(-) diff --git a/fips/aes/Makefile b/fips/aes/Makefile index b085d43122..b7bd5ca243 100644 --- a/fips/aes/Makefile +++ b/fips/aes/Makefile @@ -56,11 +56,13 @@ links: @$(PERL) $(TOP)/util/mklink.pl $(TOP)/apps $(APPS) install: - @for i in $(EXHEADER) ; \ - do \ - (cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \ - chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \ - done; + @if test -n "$(EXHEADER)"; then \ + for i in $(EXHEADER) ; \ + do \ + (cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \ + chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \ + done; \ + fi tags: ctags $(SRC) diff --git a/fips/des/Makefile b/fips/des/Makefile index 7d38bc7ed5..ce64e67b36 100644 --- a/fips/des/Makefile +++ b/fips/des/Makefile @@ -56,11 +56,13 @@ links: @$(PERL) $(TOP)/util/mklink.pl $(TOP)/apps $(APPS) install: - @for i in $(EXHEADER) ; \ - do \ - (cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \ - chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \ - done; + @if test -n "$(EXHEADER)"; then \ + for i in $(EXHEADER) ; \ + do \ + (cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \ + chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \ + done; \ + fi tags: ctags $(SRC) diff --git a/fips/dh/Makefile b/fips/dh/Makefile index 925810fd74..c44c551a19 100644 --- a/fips/dh/Makefile +++ b/fips/dh/Makefile @@ -54,12 +54,13 @@ links: @$(PERL) $(TOP)/util/mklink.pl $(TOP)/apps $(APPS) install: -# some shells don't like empty lists -# @for i in $(EXHEADER) ; \ -# do \ -# (cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \ -# chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \ -# done; + @if test -n "$(EXHEADER)"; then \ + for i in $(EXHEADER) ; \ + do \ + (cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \ + chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \ + done; \ + fi tags: ctags $(SRC) diff --git a/fips/dsa/Makefile b/fips/dsa/Makefile index 96cd964ef2..76aa7dd1dc 100644 --- a/fips/dsa/Makefile +++ b/fips/dsa/Makefile @@ -54,12 +54,13 @@ links: @$(PERL) $(TOP)/util/mklink.pl $(TOP)/apps $(APPS) install: -# some shells don't like empty lists -# @for i in $(EXHEADER) ; \ -# do \ -# (cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \ -# chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \ -# done; + @if test -n "$(EXHEADER)"; then \ + for i in $(EXHEADER) ; \ + do \ + (cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \ + chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \ + done; \ + fi tags: ctags $(SRC) diff --git a/fips/rsa/Makefile b/fips/rsa/Makefile index 91c2d49c27..5aa1e2bae7 100644 --- a/fips/rsa/Makefile +++ b/fips/rsa/Makefile @@ -54,12 +54,13 @@ links: @$(PERL) $(TOP)/util/mklink.pl $(TOP)/apps $(APPS) install: -# some shells don't like empty lists -# @for i in $(EXHEADER) ; \ -# do \ -# (cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \ -# chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \ -# done; + @if test -n "$(EXHEADER)"; then \ + for i in $(EXHEADER) ; \ + do \ + (cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \ + chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \ + done; \ + fi tags: ctags $(SRC) diff --git a/fips/sha1/Makefile b/fips/sha1/Makefile index f98c084b49..4a35a6fc3a 100644 --- a/fips/sha1/Makefile +++ b/fips/sha1/Makefile @@ -64,11 +64,13 @@ links: @$(PERL) $(TOP)/util/mklink.pl $(TOP)/apps $(APPS) install: - @for i in $(EXHEADER) ; \ - do \ - (cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \ - chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \ - done; + @if test -n "$(EXHEADER)"; then \ + for i in $(EXHEADER) ; \ + do \ + (cp $$i $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i; \ + chmod 644 $(INSTALL_PREFIX)$(INSTALLTOP)/include/openssl/$$i ); \ + done; \ + fi tags: ctags $(SRC) -- 2.40.0