aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--mesonbuild/minstall.py3
-rw-r--r--test cases/common/190 install_mode/meson.build1
2 files changed, 3 insertions, 1 deletions
diff --git a/mesonbuild/minstall.py b/mesonbuild/minstall.py
index 551f909..a810ccb 100644
--- a/mesonbuild/minstall.py
+++ b/mesonbuild/minstall.py
@@ -693,7 +693,6 @@ class Installer:
raise MesonException(f'File {fname!r} could not be found')
elif os.path.isfile(fname):
file_copied = self.do_copyfile(fname, outname, makedirs=(dm, outdir))
- self.set_mode(outname, install_mode, d.install_umask)
if should_strip and d.strip_bin is not None:
if fname.endswith('.jar'):
self.log('Not stripping jar target: {}'.format(os.path.basename(fname)))
@@ -723,6 +722,8 @@ class Installer:
pass
else:
raise
+ # file mode needs to be set last, after strip/depfixer editing
+ self.set_mode(outname, install_mode, d.install_umask)
def rebuild_all(wd: str) -> bool:
if not (Path(wd) / 'build.ninja').is_file():
diff --git a/test cases/common/190 install_mode/meson.build b/test cases/common/190 install_mode/meson.build
index cae1e91..e877ba7 100644
--- a/test cases/common/190 install_mode/meson.build
+++ b/test cases/common/190 install_mode/meson.build
@@ -51,6 +51,7 @@ install_man('foo.1',
executable('trivialprog',
sources : 'trivial.c',
install : true,
+ build_rpath: meson.current_build_dir(),
install_mode : ['rwxr-sr-x', 'root', 'root'])
# test install_mode in static_library