Closed tenzap closed 7 months ago
According to the Makefile
, the install
program is already called with the -D
option, which should create all the intermediary directories.
Example:
$ DESTDIR=/tmp/a/b/c make install
...
install -D "mount-zip" "/tmp/a/b/c/usr/bin/mount-zip"
install -D -m 644 mount-zip.1 "/tmp/a/b/c/usr/share/man/man1/mount-zip.1"
$ tree /tmp/a
/tmp/a
└── b
└── c
└── usr
├── bin
│ └── mount-zip
└── share
└── man
└── man1
└── mount-zip.1
8 directories, 2 files
$ rm -r /tmp/a
$ tree /tmp/a
/tmp/a [error opening dir]
0 directories, 0 files
$ DESTDIR=/tmp/a/b/c make install-strip
...
install -D -s "mount-zip" "/tmp/a/b/c/usr/bin/mount-zip"
install -D -m 644 mount-zip.1 "/tmp/a/b/c/usr/share/man/man1/mount-zip.1"
$ tree /tmp/a
/tmp/a
└── b
└── c
└── usr
├── bin
│ └── mount-zip
└── share
└── man
└── man1
└── mount-zip.1
8 directories, 2 files
So, I'm not sure how you could run into the situation you described. For example, your traces show that the install
program is called with --strip-program=true
, but this string is nowhere to be found in mount-zip
's makefiles.
This is how the debian package calls make install. It looks like the packager calls it by overriding INSTALL.
dh_auto_install --destdir=debian/mount-zip/
install -m0755 -d /builds/bastif/mount-zip/debian/output/source_dir/debian/mount-zip
make -j2 install DESTDIR=/builds/bastif/mount-zip/debian/output/source_dir/debian/mount-zip AM_UPDATE_INFO_DIR=no "INSTALL=install --strip-program=true"
Would you consider something like that? Ie. keep only the name/path of the binary in INSTALL, and move the -D argument to INSTALL_PROGRAM & INSTALL_DATA
--- a/Makefile
+++ b/Makefile
@@ -36,9 +36,9 @@
MAN = $(DEST).1
MANDIR = $(prefix)/share/man/man1
CLEANFILES = $(OBJECTS) $(DEST)
-INSTALL = install -D
-INSTALL_PROGRAM = $(INSTALL)
-INSTALL_DATA = $(INSTALL) -m 644
+INSTALL = install
+INSTALL_PROGRAM = $(INSTALL) -D
+INSTALL_DATA = $(INSTALL) -D -m 644
all: $(DEST)
When running make install, it fails if the destination dir doesn't exist yet. Please create the destination dir if required.
Same issue when installing the manpage