diff options
author | 2022-05-02 06:10:21 -0300 | |
---|---|---|
committer | 2022-05-08 09:52:49 +0000 | |
commit | 4421517c558b9a2964263ffae42c6fb9d3e33bf1 (patch) | |
tree | 55c964effc025cba6e7397379110fe176505dcf6 | |
parent | Whitelist for NixOS to resolve binary paths in user environment (diff) | |
download | firejail-4421517c558b9a2964263ffae42c6fb9d3e33bf1.tar.gz firejail-4421517c558b9a2964263ffae42c6fb9d3e33bf1.tar.zst firejail-4421517c558b9a2964263ffae42c6fb9d3e33bf1.zip |
configure*: remove ultimately unused INSTALL and RANLIB check macros
From the manual of GNU Autoconf (version 2.69):
> -- Macro: AC_PROG_INSTALL
> Set output variable 'INSTALL' to the name of a BSD-compatible
> 'install' program, if one is found in the current 'PATH'.
> Otherwise, set 'INSTALL' to 'DIR/install-sh -c', checking the
> directories specified to 'AC_CONFIG_AUX_DIR' (or its default
> directories) to determine DIR (*note Output::). Also set the
> variables 'INSTALL_PROGRAM' and 'INSTALL_SCRIPT' to '${INSTALL}'
> and 'INSTALL_DATA' to '${INSTALL} -m 644'.
> -- Macro: AC_PROG_RANLIB
> Set output variable 'RANLIB' to 'ranlib' if 'ranlib' is found,
> and otherwise to ':' (do nothing).
None of the aforementioned variables are used:
$ git grep -F -e '${INSTALL}' -e INSTALL_PROGRAM -e INSTALL_SCRIPT \
-e INSTALL_DATA -e RANLIB
$
So remove the macros that define them.
Misc: The macros in question have been present on configure.ac since it
was created, on commit 137985136 ("Baseline firejail 0.9.28",
2015-08-08). And while the install command is called multiple times,
ranlib is not used anywhere (and it seems that it was never used):
$ git grep -E '^[[:blank:]]+install ' -- '*Makefile*' '*.mk*' |
wc -l
32
$ git grep -F ranlib | wc -l
0
$ git log --pretty= --name-only -G'RANLIB|ranlib' \
137985136..master | sort -u
README.md
Kind of relates to #4695.
-rwxr-xr-x | configure | 224 | ||||
-rw-r--r-- | configure.ac | 2 |
2 files changed, 0 insertions, 226 deletions
@@ -658,10 +658,6 @@ PKG_CONFIG_LIBDIR | |||
658 | PKG_CONFIG_PATH | 658 | PKG_CONFIG_PATH |
659 | PKG_CONFIG | 659 | PKG_CONFIG |
660 | HAVE_APPARMOR | 660 | HAVE_APPARMOR |
661 | RANLIB | ||
662 | INSTALL_DATA | ||
663 | INSTALL_SCRIPT | ||
664 | INSTALL_PROGRAM | ||
665 | OBJEXT | 661 | OBJEXT |
666 | EXEEXT | 662 | EXEEXT |
667 | ac_ct_CC | 663 | ac_ct_CC |
@@ -2882,220 +2878,6 @@ ac_compile='$CC -c $CFLAGS $CPPFLAGS conftest.$ac_ext >&5' | |||
2882 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' | 2878 | ac_link='$CC -o conftest$ac_exeext $CFLAGS $CPPFLAGS $LDFLAGS conftest.$ac_ext $LIBS >&5' |
2883 | ac_compiler_gnu=$ac_cv_c_compiler_gnu | 2879 | ac_compiler_gnu=$ac_cv_c_compiler_gnu |
2884 | 2880 | ||
2885 | ac_aux_dir= | ||
2886 | for ac_dir in "$srcdir" "$srcdir/.." "$srcdir/../.."; do | ||
2887 | if test -f "$ac_dir/install-sh"; then | ||
2888 | ac_aux_dir=$ac_dir | ||
2889 | ac_install_sh="$ac_aux_dir/install-sh -c" | ||
2890 | break | ||
2891 | elif test -f "$ac_dir/install.sh"; then | ||
2892 | ac_aux_dir=$ac_dir | ||
2893 | ac_install_sh="$ac_aux_dir/install.sh -c" | ||
2894 | break | ||
2895 | elif test -f "$ac_dir/shtool"; then | ||
2896 | ac_aux_dir=$ac_dir | ||
2897 | ac_install_sh="$ac_aux_dir/shtool install -c" | ||
2898 | break | ||
2899 | fi | ||
2900 | done | ||
2901 | if test -z "$ac_aux_dir"; then | ||
2902 | as_fn_error $? "cannot find install-sh, install.sh, or shtool in \"$srcdir\" \"$srcdir/..\" \"$srcdir/../..\"" "$LINENO" 5 | ||
2903 | fi | ||
2904 | |||
2905 | # These three variables are undocumented and unsupported, | ||
2906 | # and are intended to be withdrawn in a future Autoconf release. | ||
2907 | # They can cause serious problems if a builder's source tree is in a directory | ||
2908 | # whose full name contains unusual characters. | ||
2909 | ac_config_guess="$SHELL $ac_aux_dir/config.guess" # Please don't use this var. | ||
2910 | ac_config_sub="$SHELL $ac_aux_dir/config.sub" # Please don't use this var. | ||
2911 | ac_configure="$SHELL $ac_aux_dir/configure" # Please don't use this var. | ||
2912 | |||
2913 | |||
2914 | # Find a good install program. We prefer a C program (faster), | ||
2915 | # so one script is as good as another. But avoid the broken or | ||
2916 | # incompatible versions: | ||
2917 | # SysV /etc/install, /usr/sbin/install | ||
2918 | # SunOS /usr/etc/install | ||
2919 | # IRIX /sbin/install | ||
2920 | # AIX /bin/install | ||
2921 | # AmigaOS /C/install, which installs bootblocks on floppy discs | ||
2922 | # AIX 4 /usr/bin/installbsd, which doesn't work without a -g flag | ||
2923 | # AFS /usr/afsws/bin/install, which mishandles nonexistent args | ||
2924 | # SVR4 /usr/ucb/install, which tries to use the nonexistent group "staff" | ||
2925 | # OS/2's system install, which has a completely different semantic | ||
2926 | # ./install, which can be erroneously created by make from ./install.sh. | ||
2927 | # Reject install programs that cannot install multiple files. | ||
2928 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for a BSD-compatible install" >&5 | ||
2929 | $as_echo_n "checking for a BSD-compatible install... " >&6; } | ||
2930 | if test -z "$INSTALL"; then | ||
2931 | if ${ac_cv_path_install+:} false; then : | ||
2932 | $as_echo_n "(cached) " >&6 | ||
2933 | else | ||
2934 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | ||
2935 | for as_dir in $PATH | ||
2936 | do | ||
2937 | IFS=$as_save_IFS | ||
2938 | test -z "$as_dir" && as_dir=. | ||
2939 | # Account for people who put trailing slashes in PATH elements. | ||
2940 | case $as_dir/ in #(( | ||
2941 | ./ | .// | /[cC]/* | \ | ||
2942 | /etc/* | /usr/sbin/* | /usr/etc/* | /sbin/* | /usr/afsws/bin/* | \ | ||
2943 | ?:[\\/]os2[\\/]install[\\/]* | ?:[\\/]OS2[\\/]INSTALL[\\/]* | \ | ||
2944 | /usr/ucb/* ) ;; | ||
2945 | *) | ||
2946 | # OSF1 and SCO ODT 3.0 have their own names for install. | ||
2947 | # Don't use installbsd from OSF since it installs stuff as root | ||
2948 | # by default. | ||
2949 | for ac_prog in ginstall scoinst install; do | ||
2950 | for ac_exec_ext in '' $ac_executable_extensions; do | ||
2951 | if as_fn_executable_p "$as_dir/$ac_prog$ac_exec_ext"; then | ||
2952 | if test $ac_prog = install && | ||
2953 | grep dspmsg "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then | ||
2954 | # AIX install. It has an incompatible calling convention. | ||
2955 | : | ||
2956 | elif test $ac_prog = install && | ||
2957 | grep pwplus "$as_dir/$ac_prog$ac_exec_ext" >/dev/null 2>&1; then | ||
2958 | # program-specific install script used by HP pwplus--don't use. | ||
2959 | : | ||
2960 | else | ||
2961 | rm -rf conftest.one conftest.two conftest.dir | ||
2962 | echo one > conftest.one | ||
2963 | echo two > conftest.two | ||
2964 | mkdir conftest.dir | ||
2965 | if "$as_dir/$ac_prog$ac_exec_ext" -c conftest.one conftest.two "`pwd`/conftest.dir" && | ||
2966 | test -s conftest.one && test -s conftest.two && | ||
2967 | test -s conftest.dir/conftest.one && | ||
2968 | test -s conftest.dir/conftest.two | ||
2969 | then | ||
2970 | ac_cv_path_install="$as_dir/$ac_prog$ac_exec_ext -c" | ||
2971 | break 3 | ||
2972 | fi | ||
2973 | fi | ||
2974 | fi | ||
2975 | done | ||
2976 | done | ||
2977 | ;; | ||
2978 | esac | ||
2979 | |||
2980 | done | ||
2981 | IFS=$as_save_IFS | ||
2982 | |||
2983 | rm -rf conftest.one conftest.two conftest.dir | ||
2984 | |||
2985 | fi | ||
2986 | if test "${ac_cv_path_install+set}" = set; then | ||
2987 | INSTALL=$ac_cv_path_install | ||
2988 | else | ||
2989 | # As a last resort, use the slow shell script. Don't cache a | ||
2990 | # value for INSTALL within a source directory, because that will | ||
2991 | # break other packages using the cache if that directory is | ||
2992 | # removed, or if the value is a relative name. | ||
2993 | INSTALL=$ac_install_sh | ||
2994 | fi | ||
2995 | fi | ||
2996 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $INSTALL" >&5 | ||
2997 | $as_echo "$INSTALL" >&6; } | ||
2998 | |||
2999 | # Use test -z because SunOS4 sh mishandles braces in ${var-val}. | ||
3000 | # It thinks the first close brace ends the variable substitution. | ||
3001 | test -z "$INSTALL_PROGRAM" && INSTALL_PROGRAM='${INSTALL}' | ||
3002 | |||
3003 | test -z "$INSTALL_SCRIPT" && INSTALL_SCRIPT='${INSTALL}' | ||
3004 | |||
3005 | test -z "$INSTALL_DATA" && INSTALL_DATA='${INSTALL} -m 644' | ||
3006 | |||
3007 | if test -n "$ac_tool_prefix"; then | ||
3008 | # Extract the first word of "${ac_tool_prefix}ranlib", so it can be a program name with args. | ||
3009 | set dummy ${ac_tool_prefix}ranlib; ac_word=$2 | ||
3010 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | ||
3011 | $as_echo_n "checking for $ac_word... " >&6; } | ||
3012 | if ${ac_cv_prog_RANLIB+:} false; then : | ||
3013 | $as_echo_n "(cached) " >&6 | ||
3014 | else | ||
3015 | if test -n "$RANLIB"; then | ||
3016 | ac_cv_prog_RANLIB="$RANLIB" # Let the user override the test. | ||
3017 | else | ||
3018 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | ||
3019 | for as_dir in $PATH | ||
3020 | do | ||
3021 | IFS=$as_save_IFS | ||
3022 | test -z "$as_dir" && as_dir=. | ||
3023 | for ac_exec_ext in '' $ac_executable_extensions; do | ||
3024 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then | ||
3025 | ac_cv_prog_RANLIB="${ac_tool_prefix}ranlib" | ||
3026 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | ||
3027 | break 2 | ||
3028 | fi | ||
3029 | done | ||
3030 | done | ||
3031 | IFS=$as_save_IFS | ||
3032 | |||
3033 | fi | ||
3034 | fi | ||
3035 | RANLIB=$ac_cv_prog_RANLIB | ||
3036 | if test -n "$RANLIB"; then | ||
3037 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $RANLIB" >&5 | ||
3038 | $as_echo "$RANLIB" >&6; } | ||
3039 | else | ||
3040 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | ||
3041 | $as_echo "no" >&6; } | ||
3042 | fi | ||
3043 | |||
3044 | |||
3045 | fi | ||
3046 | if test -z "$ac_cv_prog_RANLIB"; then | ||
3047 | ac_ct_RANLIB=$RANLIB | ||
3048 | # Extract the first word of "ranlib", so it can be a program name with args. | ||
3049 | set dummy ranlib; ac_word=$2 | ||
3050 | { $as_echo "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5 | ||
3051 | $as_echo_n "checking for $ac_word... " >&6; } | ||
3052 | if ${ac_cv_prog_ac_ct_RANLIB+:} false; then : | ||
3053 | $as_echo_n "(cached) " >&6 | ||
3054 | else | ||
3055 | if test -n "$ac_ct_RANLIB"; then | ||
3056 | ac_cv_prog_ac_ct_RANLIB="$ac_ct_RANLIB" # Let the user override the test. | ||
3057 | else | ||
3058 | as_save_IFS=$IFS; IFS=$PATH_SEPARATOR | ||
3059 | for as_dir in $PATH | ||
3060 | do | ||
3061 | IFS=$as_save_IFS | ||
3062 | test -z "$as_dir" && as_dir=. | ||
3063 | for ac_exec_ext in '' $ac_executable_extensions; do | ||
3064 | if as_fn_executable_p "$as_dir/$ac_word$ac_exec_ext"; then | ||
3065 | ac_cv_prog_ac_ct_RANLIB="ranlib" | ||
3066 | $as_echo "$as_me:${as_lineno-$LINENO}: found $as_dir/$ac_word$ac_exec_ext" >&5 | ||
3067 | break 2 | ||
3068 | fi | ||
3069 | done | ||
3070 | done | ||
3071 | IFS=$as_save_IFS | ||
3072 | |||
3073 | fi | ||
3074 | fi | ||
3075 | ac_ct_RANLIB=$ac_cv_prog_ac_ct_RANLIB | ||
3076 | if test -n "$ac_ct_RANLIB"; then | ||
3077 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: $ac_ct_RANLIB" >&5 | ||
3078 | $as_echo "$ac_ct_RANLIB" >&6; } | ||
3079 | else | ||
3080 | { $as_echo "$as_me:${as_lineno-$LINENO}: result: no" >&5 | ||
3081 | $as_echo "no" >&6; } | ||
3082 | fi | ||
3083 | |||
3084 | if test "x$ac_ct_RANLIB" = x; then | ||
3085 | RANLIB=":" | ||
3086 | else | ||
3087 | case $cross_compiling:$ac_tool_warned in | ||
3088 | yes:) | ||
3089 | { $as_echo "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5 | ||
3090 | $as_echo "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;} | ||
3091 | ac_tool_warned=yes ;; | ||
3092 | esac | ||
3093 | RANLIB=$ac_ct_RANLIB | ||
3094 | fi | ||
3095 | else | ||
3096 | RANLIB="$ac_cv_prog_RANLIB" | ||
3097 | fi | ||
3098 | |||
3099 | 2881 | ||
3100 | HAVE_SPECTRE="no" | 2882 | HAVE_SPECTRE="no" |
3101 | 2883 | ||
@@ -4896,7 +4678,6 @@ gives unlimited permission to copy, distribute and modify it." | |||
4896 | 4678 | ||
4897 | ac_pwd='$ac_pwd' | 4679 | ac_pwd='$ac_pwd' |
4898 | srcdir='$srcdir' | 4680 | srcdir='$srcdir' |
4899 | INSTALL='$INSTALL' | ||
4900 | test -n "\$AWK" || AWK=awk | 4681 | test -n "\$AWK" || AWK=awk |
4901 | _ACEOF | 4682 | _ACEOF |
4902 | 4683 | ||
@@ -5361,10 +5142,6 @@ ac_abs_srcdir=$ac_abs_top_srcdir$ac_dir_suffix | |||
5361 | # CONFIG_FILE | 5142 | # CONFIG_FILE |
5362 | # | 5143 | # |
5363 | 5144 | ||
5364 | case $INSTALL in | ||
5365 | [\\/$]* | ?:[\\/]* ) ac_INSTALL=$INSTALL ;; | ||
5366 | *) ac_INSTALL=$ac_top_build_prefix$INSTALL ;; | ||
5367 | esac | ||
5368 | _ACEOF | 5145 | _ACEOF |
5369 | 5146 | ||
5370 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 | 5147 | cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1 |
@@ -5418,7 +5195,6 @@ s&@abs_top_srcdir@&$ac_abs_top_srcdir&;t t | |||
5418 | s&@builddir@&$ac_builddir&;t t | 5195 | s&@builddir@&$ac_builddir&;t t |
5419 | s&@abs_builddir@&$ac_abs_builddir&;t t | 5196 | s&@abs_builddir@&$ac_abs_builddir&;t t |
5420 | s&@abs_top_builddir@&$ac_abs_top_builddir&;t t | 5197 | s&@abs_top_builddir@&$ac_abs_top_builddir&;t t |
5421 | s&@INSTALL@&$ac_INSTALL&;t t | ||
5422 | $ac_datarootdir_hack | 5198 | $ac_datarootdir_hack |
5423 | " | 5199 | " |
5424 | eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ | 5200 | eval sed \"\$ac_sed_extra\" "$ac_file_inputs" | $AWK -f "$ac_tmp/subs.awk" \ |
diff --git a/configure.ac b/configure.ac index 4066618e0..28e6b7837 100644 --- a/configure.ac +++ b/configure.ac | |||
@@ -19,8 +19,6 @@ AC_CONFIG_SRCDIR([src/firejail/main.c]) | |||
19 | AC_CONFIG_MACRO_DIR([m4]) | 19 | AC_CONFIG_MACRO_DIR([m4]) |
20 | 20 | ||
21 | AC_PROG_CC | 21 | AC_PROG_CC |
22 | AC_PROG_INSTALL | ||
23 | AC_PROG_RANLIB | ||
24 | 22 | ||
25 | HAVE_SPECTRE="no" | 23 | HAVE_SPECTRE="no" |
26 | AX_CHECK_COMPILE_FLAG( | 24 | AX_CHECK_COMPILE_FLAG( |