[libvirt-php 1/6] m4: ignore --php-binary if it doesn't exist

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On OpenSUSE 151,  "php-config --php-binary" reports a name of
"/usr/bin/php-cgi", but this binary doesn't actually exist. We
need to fallback to the plain "/usr/bin/php" command.

Signed-off-by: Daniel P. Berrangé <berrange@xxxxxxxxxx>
---
 m4/virt-php-extension.m4 | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/m4/virt-php-extension.m4 b/m4/virt-php-extension.m4
index 5aa3cb7..2a97e74 100644
--- a/m4/virt-php-extension.m4
+++ b/m4/virt-php-extension.m4
@@ -26,7 +26,7 @@ AC_DEFUN([LIBVIRT_CHECK_PHP_EXTENSION],[
   AC_MSG_CHECKING([for php module $1])
 
   phpbinary="$($PHPCONFIG --php-binary)"
-  if test "x$phpbinary" = "x"; then
+  if test "x$phpbinary" = "x" || test ! -x "$phpbinary" ; then
     phpbinary="$($PHPCONFIG --prefix)/bin/php"
   fi
 
-- 
2.26.2





[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux