From 3f71d1f39a7984748759354902d3eae66bb78758 Mon Sep 17 00:00:00 2001 From: Kinsey Moore Date: Wed, 31 Jan 2024 13:02:03 -0600 Subject: [PATCH] configure: Correctly handle gdbus_codegen When gdbus_codegen is retrieved via pkg-config, it is not guaranteed to have an absolute path. This patch resolves the absolute path before checking to see whether it's executable. This also omits emission of GDBUS_CODEGEN to config-host.mak when gdbus_codegen is empty. --- configure | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/configure b/configure index 4cef321d9d..261f3fbeb8 100755 --- a/configure +++ b/configure @@ -3506,6 +3506,7 @@ if $pkg_config --atleast-version=$glib_req_ver gio-2.0; then gio_cflags=$($pkg_config --cflags gio-2.0) gio_libs=$($pkg_config --libs gio-2.0) gdbus_codegen=$($pkg_config --variable=gdbus_codegen gio-2.0) + gdbus_codegen=$(which $gdbus_codegen) if [ ! -x "$gdbus_codegen" ]; then gdbus_codegen= fi @@ -6168,7 +6169,9 @@ if test "$gio" = "yes" ; then echo "CONFIG_GIO=y" >> $config_host_mak echo "GIO_CFLAGS=$gio_cflags" >> $config_host_mak echo "GIO_LIBS=$gio_libs" >> $config_host_mak - echo "GDBUS_CODEGEN=$gdbus_codegen" >> $config_host_mak + if test "x$GDBUS_CODEGEN" != "x" ; then + echo "GDBUS_CODEGEN=$gdbus_codegen" >> $config_host_mak + fi fi echo "CONFIG_TLS_PRIORITY=\"$tls_priority\"" >> $config_host_mak if test "$gnutls" = "yes" ; then -- 2.39.2