Fix build with automake >= 1.12.1
authorOlivier Blin <olivier.blin@softathome.com>
Mon, 2 Jul 2012 16:50:56 +0000 (18:50 +0200)
committerMiklos Szeredi <mszeredi@suse.cz>
Wed, 4 Jul 2012 10:19:29 +0000 (12:19 +0200)
mkdir_p is deprecated since automake 1.12.1 (see automake commit
7a1eb9ff9027929687f12905e131f6fda3fa6d0c).

MKDIR_P should be used instead of mkdir_p.
This is available since autoconf 2.59d (2006-06-05), by calling
AC_PROG_MKDIR_P.

The mkdir_p workaround was not working anyway for out-of-tree builds,
since the ../mkinstalldirs path would be incorrect.

ChangeLog
configure.in
util/Makefile.am

index e58bec4222aafccb449861f3322e40ffa148953d..48e8f43893c9d6d022aabb13ad35ed5fd5beec04 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -3,6 +3,8 @@
        * Fix install of mount.fuse from out-of-tree build.  Patch by
        Olivier Blin
 
+       * Fix build with automake >= 1.12.1.  Patch by Olivier Blin
+
 2012-04-24  Miklos Szeredi <miklos@szeredi.hu>
 
        * Add fallocate operation.  Patch by Anatol Pomozov
index a7448dfbd7acae3ac895d7f349969d8d217bb184..36171d1862d8387d8b3823fb61da795664c66bef 100644 (file)
@@ -1,4 +1,5 @@
 AC_INIT(fuse, 2.9.0)
+AC_PREREQ(2.59d)
 AC_CONFIG_MACRO_DIR([m4])
 AC_CANONICAL_TARGET
 AM_INIT_AUTOMAKE
@@ -7,14 +8,9 @@ AM_CONFIG_HEADER(include/config.h)
 
 AC_PROG_LIBTOOL
 AC_PROG_CC
+AC_PROG_MKDIR_P
 AM_PROG_CC_C_O
 
-# compatibility for automake < 1.8
-if test -z "$mkdir_p"; then
-       mkdir_p="../mkinstalldirs"
-       AC_SUBST(mkdir_p)
-fi
-
 case $target_os in
      *linux*)  arch=linux;;
      *netbsd*)  arch=netbsd;;
index b036164386cbff19b937d2b8d1a56bf69b4c1fb0..059d5fc2e474f4941e4a9f662abc4bf815db1db0 100644 (file)
@@ -23,7 +23,7 @@ ulockmgr_server_LDFLAGS = -pthread
 install-exec-hook:
        -chmod u+s $(DESTDIR)$(bindir)/fusermount
        @if test ! -e $(DESTDIR)/dev/fuse; then \
-               $(mkdir_p) $(DESTDIR)/dev; \
+               $(MKDIR_P) $(DESTDIR)/dev; \
                echo "mknod $(DESTDIR)/dev/fuse -m 0666 c 10 229 || true"; \
                mknod $(DESTDIR)/dev/fuse -m 0666 c 10 229 || true; \
        fi
@@ -35,9 +35,9 @@ UDEV_RULES_PATH = @UDEV_RULES_PATH@
 INIT_D_PATH = @INIT_D_PATH@
 
 install-exec-local:
-       $(mkdir_p) $(DESTDIR)$(MOUNT_FUSE_PATH)
+       $(MKDIR_P) $(DESTDIR)$(MOUNT_FUSE_PATH)
        $(INSTALL_PROGRAM) $(builddir)/mount.fuse $(DESTDIR)$(MOUNT_FUSE_PATH)/mount.fuse
-       $(mkdir_p) $(DESTDIR)$(INIT_D_PATH)
+       $(MKDIR_P) $(DESTDIR)$(INIT_D_PATH)
        $(INSTALL_SCRIPT) $(srcdir)/init_script $(DESTDIR)$(INIT_D_PATH)/fuse
        @if test -x /usr/sbin/update-rc.d; then \
                echo "/usr/sbin/update-rc.d fuse start 34 S . start 41 0 6 . || true"; \
@@ -45,7 +45,7 @@ install-exec-local:
        fi
 
 install-data-local:
-       $(mkdir_p) $(DESTDIR)$(UDEV_RULES_PATH)
+       $(MKDIR_P) $(DESTDIR)$(UDEV_RULES_PATH)
        $(INSTALL_DATA) $(srcdir)/udev.rules $(DESTDIR)$(UDEV_RULES_PATH)/99-fuse.rules
 
 uninstall-local: