Skip to content

Commit 861dade

Browse files
dezzachrisbra
authored andcommitted
patch 9.1.1560: configure: uses $PKG_CONFIG before it is defined
Problem: configure: uses $PKG_CONFIG before it is defined Solution: Define $PKG_CONFIG earlier in the script (Christoffer Aasted). closes: #17771 Signed-off-by: Christoffer Aasted <chr.aasted@gmail.com> Signed-off-by: Christian Brabandt <cb@256bit.org>
1 parent 12d274a commit 861dade

3 files changed

Lines changed: 120 additions & 118 deletions

File tree

src/auto/configure

Lines changed: 114 additions & 114 deletions
Original file line numberDiff line numberDiff line change
@@ -668,7 +668,6 @@ GNOME_LIBS
668668
GTK_LIBNAME
669669
GTK_LIBS
670670
GTK_CFLAGS
671-
PKG_CONFIG
672671
X_LIB
673672
X_EXTRA_LIBS
674673
X_LIBS
@@ -755,6 +754,7 @@ XCODE_SELECT
755754
CPP_MM
756755
CROSS_COMPILING
757756
BUILD_DATE_MSG
757+
PKG_CONFIG
758758
STRIP
759759
AWK
760760
FGREP
@@ -4526,6 +4526,119 @@ printf "%s\n" "#define HAVE_SYS_WAIT_H 1" >>confdefs.h
45264526
fi
45274527

45284528

4529+
if test -z "$PKG_CONFIG"; then
4530+
if test -n "$ac_tool_prefix"; then
4531+
# Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
4532+
set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
4533+
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4534+
printf %s "checking for $ac_word... " >&6; }
4535+
if test ${ac_cv_path_PKG_CONFIG+y}
4536+
then :
4537+
printf %s "(cached) " >&6
4538+
else case e in #(
4539+
e) case $PKG_CONFIG in
4540+
[\\/]* | ?:[\\/]*)
4541+
ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
4542+
;;
4543+
*)
4544+
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4545+
for as_dir in $PATH
4546+
do
4547+
IFS=$as_save_IFS
4548+
case $as_dir in #(((
4549+
'') as_dir=./ ;;
4550+
*/) ;;
4551+
*) as_dir=$as_dir/ ;;
4552+
esac
4553+
for ac_exec_ext in '' $ac_executable_extensions; do
4554+
if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4555+
ac_cv_path_PKG_CONFIG="$as_dir$ac_word$ac_exec_ext"
4556+
printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4557+
break 2
4558+
fi
4559+
done
4560+
done
4561+
IFS=$as_save_IFS
4562+
4563+
;;
4564+
esac ;;
4565+
esac
4566+
fi
4567+
PKG_CONFIG=$ac_cv_path_PKG_CONFIG
4568+
if test -n "$PKG_CONFIG"; then
4569+
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
4570+
printf "%s\n" "$PKG_CONFIG" >&6; }
4571+
else
4572+
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4573+
printf "%s\n" "no" >&6; }
4574+
fi
4575+
4576+
4577+
fi
4578+
if test -z "$ac_cv_path_PKG_CONFIG"; then
4579+
ac_pt_PKG_CONFIG=$PKG_CONFIG
4580+
# Extract the first word of "pkg-config", so it can be a program name with args.
4581+
set dummy pkg-config; ac_word=$2
4582+
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
4583+
printf %s "checking for $ac_word... " >&6; }
4584+
if test ${ac_cv_path_ac_pt_PKG_CONFIG+y}
4585+
then :
4586+
printf %s "(cached) " >&6
4587+
else case e in #(
4588+
e) case $ac_pt_PKG_CONFIG in
4589+
[\\/]* | ?:[\\/]*)
4590+
ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
4591+
;;
4592+
*)
4593+
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
4594+
for as_dir in $PATH
4595+
do
4596+
IFS=$as_save_IFS
4597+
case $as_dir in #(((
4598+
'') as_dir=./ ;;
4599+
*/) ;;
4600+
*) as_dir=$as_dir/ ;;
4601+
esac
4602+
for ac_exec_ext in '' $ac_executable_extensions; do
4603+
if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
4604+
ac_cv_path_ac_pt_PKG_CONFIG="$as_dir$ac_word$ac_exec_ext"
4605+
printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
4606+
break 2
4607+
fi
4608+
done
4609+
done
4610+
IFS=$as_save_IFS
4611+
4612+
;;
4613+
esac ;;
4614+
esac
4615+
fi
4616+
ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
4617+
if test -n "$ac_pt_PKG_CONFIG"; then
4618+
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
4619+
printf "%s\n" "$ac_pt_PKG_CONFIG" >&6; }
4620+
else
4621+
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
4622+
printf "%s\n" "no" >&6; }
4623+
fi
4624+
4625+
if test "x$ac_pt_PKG_CONFIG" = x; then
4626+
PKG_CONFIG="no"
4627+
else
4628+
case $cross_compiling:$ac_tool_warned in
4629+
yes:)
4630+
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
4631+
printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
4632+
ac_tool_warned=yes ;;
4633+
esac
4634+
PKG_CONFIG=$ac_pt_PKG_CONFIG
4635+
fi
4636+
else
4637+
PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
4638+
fi
4639+
4640+
fi
4641+
45294642
if test x"$ac_cv_prog_cc_c99" != xno; then
45304643

45314644

@@ -10573,119 +10686,6 @@ fi
1057310686

1057410687

1057510688

10576-
if test -z "$PKG_CONFIG"; then
10577-
if test -n "$ac_tool_prefix"; then
10578-
# Extract the first word of "${ac_tool_prefix}pkg-config", so it can be a program name with args.
10579-
set dummy ${ac_tool_prefix}pkg-config; ac_word=$2
10580-
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10581-
printf %s "checking for $ac_word... " >&6; }
10582-
if test ${ac_cv_path_PKG_CONFIG+y}
10583-
then :
10584-
printf %s "(cached) " >&6
10585-
else case e in #(
10586-
e) case $PKG_CONFIG in
10587-
[\\/]* | ?:[\\/]*)
10588-
ac_cv_path_PKG_CONFIG="$PKG_CONFIG" # Let the user override the test with a path.
10589-
;;
10590-
*)
10591-
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10592-
for as_dir in $PATH
10593-
do
10594-
IFS=$as_save_IFS
10595-
case $as_dir in #(((
10596-
'') as_dir=./ ;;
10597-
*/) ;;
10598-
*) as_dir=$as_dir/ ;;
10599-
esac
10600-
for ac_exec_ext in '' $ac_executable_extensions; do
10601-
if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
10602-
ac_cv_path_PKG_CONFIG="$as_dir$ac_word$ac_exec_ext"
10603-
printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
10604-
break 2
10605-
fi
10606-
done
10607-
done
10608-
IFS=$as_save_IFS
10609-
10610-
;;
10611-
esac ;;
10612-
esac
10613-
fi
10614-
PKG_CONFIG=$ac_cv_path_PKG_CONFIG
10615-
if test -n "$PKG_CONFIG"; then
10616-
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $PKG_CONFIG" >&5
10617-
printf "%s\n" "$PKG_CONFIG" >&6; }
10618-
else
10619-
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
10620-
printf "%s\n" "no" >&6; }
10621-
fi
10622-
10623-
10624-
fi
10625-
if test -z "$ac_cv_path_PKG_CONFIG"; then
10626-
ac_pt_PKG_CONFIG=$PKG_CONFIG
10627-
# Extract the first word of "pkg-config", so it can be a program name with args.
10628-
set dummy pkg-config; ac_word=$2
10629-
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking for $ac_word" >&5
10630-
printf %s "checking for $ac_word... " >&6; }
10631-
if test ${ac_cv_path_ac_pt_PKG_CONFIG+y}
10632-
then :
10633-
printf %s "(cached) " >&6
10634-
else case e in #(
10635-
e) case $ac_pt_PKG_CONFIG in
10636-
[\\/]* | ?:[\\/]*)
10637-
ac_cv_path_ac_pt_PKG_CONFIG="$ac_pt_PKG_CONFIG" # Let the user override the test with a path.
10638-
;;
10639-
*)
10640-
as_save_IFS=$IFS; IFS=$PATH_SEPARATOR
10641-
for as_dir in $PATH
10642-
do
10643-
IFS=$as_save_IFS
10644-
case $as_dir in #(((
10645-
'') as_dir=./ ;;
10646-
*/) ;;
10647-
*) as_dir=$as_dir/ ;;
10648-
esac
10649-
for ac_exec_ext in '' $ac_executable_extensions; do
10650-
if as_fn_executable_p "$as_dir$ac_word$ac_exec_ext"; then
10651-
ac_cv_path_ac_pt_PKG_CONFIG="$as_dir$ac_word$ac_exec_ext"
10652-
printf "%s\n" "$as_me:${as_lineno-$LINENO}: found $as_dir$ac_word$ac_exec_ext" >&5
10653-
break 2
10654-
fi
10655-
done
10656-
done
10657-
IFS=$as_save_IFS
10658-
10659-
;;
10660-
esac ;;
10661-
esac
10662-
fi
10663-
ac_pt_PKG_CONFIG=$ac_cv_path_ac_pt_PKG_CONFIG
10664-
if test -n "$ac_pt_PKG_CONFIG"; then
10665-
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_pt_PKG_CONFIG" >&5
10666-
printf "%s\n" "$ac_pt_PKG_CONFIG" >&6; }
10667-
else
10668-
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: no" >&5
10669-
printf "%s\n" "no" >&6; }
10670-
fi
10671-
10672-
if test "x$ac_pt_PKG_CONFIG" = x; then
10673-
PKG_CONFIG="no"
10674-
else
10675-
case $cross_compiling:$ac_tool_warned in
10676-
yes:)
10677-
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: WARNING: using cross tools not prefixed with host triplet" >&5
10678-
printf "%s\n" "$as_me: WARNING: using cross tools not prefixed with host triplet" >&2;}
10679-
ac_tool_warned=yes ;;
10680-
esac
10681-
PKG_CONFIG=$ac_pt_PKG_CONFIG
10682-
fi
10683-
else
10684-
PKG_CONFIG="$ac_cv_path_PKG_CONFIG"
10685-
fi
10686-
10687-
fi
10688-
1068910689
if test -z "$SKIP_GTK3"; then
1069010690
{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking --disable-gtktest argument" >&5
1069110691
printf %s "checking --disable-gtktest argument... " >&6; }

src/configure.ac

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,10 @@ AC_EXEEXT
2525

2626
AC_HEADER_SYS_WAIT
2727

28+
if test -z "$PKG_CONFIG"; then
29+
AC_PATH_TOOL(PKG_CONFIG, pkg-config, no)
30+
fi
31+
2832
dnl Check that the C99 features that Vim uses are supported:
2933
if test x"$ac_cv_prog_cc_c99" != xno; then
3034
dnl If the compiler doesn't explicitly support C99, then check
@@ -2885,10 +2889,6 @@ AC_DEFUN([GNOME_INIT],[
28852889
GNOME_INIT_HOOK([],fail)
28862890
])
28872891

2888-
if test -z "$PKG_CONFIG"; then
2889-
AC_PATH_TOOL(PKG_CONFIG, pkg-config, no)
2890-
fi
2891-
28922892
dnl ---------------------------------------------------------------------------
28932893
dnl Check for GTK3. If it succeeds, skip the check for GTK2.
28942894
dnl ---------------------------------------------------------------------------

src/version.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -719,6 +719,8 @@ static char *(features[]) =
719719

720720
static int included_patches[] =
721721
{ /* Add new patch number below this line */
722+
/**/
723+
1560,
722724
/**/
723725
1559,
724726
/**/

0 commit comments

Comments
 (0)