diff options
author | Alexey Neyman <stilor@att.net> | 2018-04-11 04:27:07 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-04-11 04:27:07 (GMT) |
commit | ffc638142d8bb5d70204047a7bd3bdd34b127d85 (patch) | |
tree | 317cf27c6163d608a3df30e15eecc540c7020ef4 /m4/ctng_prog_install.m4 | |
parent | 7c3422675909ea8b117f94a26170af06a265477e (diff) | |
parent | c4608f07f7e06a58d48d74b64296be663a94c604 (diff) |
Merge pull request #937 from stilor/build-autotoolize
Autotoolize crosstool-ng
Diffstat (limited to 'm4/ctng_prog_install.m4')
-rw-r--r-- | m4/ctng_prog_install.m4 | 26 |
1 files changed, 26 insertions, 0 deletions
diff --git a/m4/ctng_prog_install.m4 b/m4/ctng_prog_install.m4 new file mode 100644 index 0000000..61cd358 --- /dev/null +++ b/m4/ctng_prog_install.m4 @@ -0,0 +1,26 @@ +# Additional checks for install(1) + +# Check if install(1) supports --strip-program=... +AC_DEFUN( + [CTNG_INSTALL_STRIP_PROGRAM], + [AC_CACHE_CHECK([whether install takes --strip-program option], + [ctng_cv_install_with_strip_program], + [touch conftest + mkdir conftest.dir + AS_IF([$INSTALL --strip-program=true -s conftest conftest.dir/conftest 2>/dev/null], + [ctng_cv_install_with_strip_program=yes], + [ctng_cv_install_with_strip_program=no]) + rm -rf conftest.dir + rm -f conftest + ]) + AS_IF([test "$ctng_cv_install_with_strip_program" = yes], [$1], [$2]) + ]) + +AC_DEFUN([CTNG_PROG_INSTALL], + [CTNG_WITH_DEPRECATED([install], [INSTALL]) + AC_ARG_VAR([INSTALL], [Specify the full path to a BSD-compatible install]) + AC_PROG_INSTALL + CTNG_INSTALL_STRIP_PROGRAM( + [CTNG_SET_KCONFIG_OPTION([install_with_strip_program], [y])], + [CTNG_SET_KCONFIG_OPTION([install_with_strip_program])]) + ]) |