From b465edbe379726a5091b3ef65512867c655c01cc Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Niels=20M=C3=B6ller?= <nisse@lysator.liu.se> Date: Mon, 27 Nov 2006 16:57:44 +0100 Subject: [PATCH] * Makefile.in (MKDIR_P): Use MKDIR_P for creating installation directories. * configure.ac: Use AC_PROG_MKDIR_P. Rev: src/nettle/ChangeLog:1.399 Rev: src/nettle/Makefile.in:1.36 Rev: src/nettle/configure.ac:1.78 --- ChangeLog | 10 ++++++++++ Makefile.in | 10 +++++----- configure.ac | 4 ++++ 3 files changed, 19 insertions(+), 5 deletions(-) diff --git a/ChangeLog b/ChangeLog index 325b9085..50e25541 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,13 @@ +2006-11-27 Niels M�ller <niels@s3.kth.se> + + * tools/Makefile.in (install): Use MKDIR_P to create installation + directory. Install only one file at a time. + + * Makefile.in (MKDIR_P): Use MKDIR_P for creating installation + directories. + + * configure.ac: Use AC_PROG_MKDIR_P. + 2006-11-24 Niels M�ller <nisse@lysator.liu.se> * testsuite/yarrow-test.c (test_main): Use gold-bug.txt as input diff --git a/Makefile.in b/Makefile.in index cbbefe6f..599b4573 100644 --- a/Makefile.in +++ b/Makefile.in @@ -12,6 +12,7 @@ INSTALL_DATA = @INSTALL_DATA@ INSTALL_PROGRAM = @INSTALL_PROGRAM@ INSTALL_SCRIPT = @INSTALL_SCRIPT@ INSTALL_STRIP_PROGRAM = $(INSTALL_PROGRAM) -s +MKDIR_P = @MKDIR_P@ SUBDIRS = tools testsuite examples @@ -229,11 +230,11 @@ config.m4: config.m4.in config.status # Installation # FIXME: Use mkinstalldirs. install-here: install-info install-headers libnettle.a $(SHLIBINSTALL) - [ -d $(DESTDIR)$(libdir) ] || mkdir $(DESTDIR)$(libdir) + $(MKDIR_P) $(DESTDIR)$(libdir) $(INSTALL_DATA) libnettle.a $(DESTDIR)$(libdir) install-shared: $(SHLIBFORLINK) - [ -d $(DESTDIR)$(libdir) ] || mkdir $(DESTDIR)$(libdir) + $(MKDIR_P) $(DESTDIR)$(libdir) $(INSTALL_PROGRAM) $(SHLIBFORLINK) $(DESTDIR)$(libdir)/$(SHLIBFILE) [ -z "$(SHLIBSONAME)" ] \ || (cd $(DESTDIR)$(libdir) \ @@ -245,7 +246,7 @@ install-shared: $(SHLIBFORLINK) # friends for ordinary explicit rules. install-info: nettle.info - [ -d $(DESTDIR)$(infodir) ] || mkdir $(DESTDIR)$(infodir) + $(MKDIR_P) $(DESTDIR)$(infodir) f=nettle.info ; \ [ -f $$f ] || f="$(srcdir)/$$f" ; \ $(INSTALL_DATA) "$$f" $(DESTDIR)$(infodir) ; \ @@ -257,8 +258,7 @@ install-info: nettle.info # NOTE: I'd like to use $^, but that's a GNU extension. $? should be # more portable, and equivalent for phony targets. install-headers: $(INSTALL_HEADERS) - [ -d $(DESTDIR)$(includedir) ] || mkdir $(DESTDIR)$(includedir) - [ -d $(DESTDIR)$(includedir)/nettle ] || mkdir $(DESTDIR)$(includedir)/nettle + $(MKDIR_P) $(DESTDIR)$(includedir)/nettle for f in $(INSTALL_HEADERS) ; do \ if [ -f "$$f" ] ; then \ $(INSTALL_DATA) "$$f" $(DESTDIR)$(includedir)/nettle ; \ diff --git a/configure.ac b/configure.ac index cbc772d7..b324ac52 100644 --- a/configure.ac +++ b/configure.ac @@ -96,6 +96,10 @@ fi AC_PROG_INSTALL +# According to the autoconf manual, needs install-sh from +# autoconf-2.60 or automake-1.10 to avoid races. +AC_PROG_MKDIR_P + LSH_DEPENDENCY_TRACKING if test x$enable_dependency_tracking = xyes ; then -- GitLab