Blame SOURCES/php-5.4.0-phpize.patch

37fd76
--- php-5.4.0RC5/scripts/phpize.in.orig	2012-01-18 17:13:54.018022983 +0100
37fd76
+++ php-5.4.0RC5/scripts/phpize.in	2012-01-18 17:14:40.614024941 +0100
37fd76
@@ -162,6 +162,15 @@
37fd76
   $PHP_AUTOHEADER || exit 1
37fd76
 }
37fd76
 
37fd76
+phpize_check_headers()
37fd76
+{
37fd76
+  if test ! -f $includedir/main/php.h; then
37fd76
+    echo "Can't find PHP headers in $includedir"
37fd76
+    echo "The php-devel package is required for use of this command."
37fd76
+    exit 1
37fd76
+  fi
37fd76
+}
37fd76
+
37fd76
 # Main script
37fd76
 
37fd76
 case "$1" in 
37fd76
@@ -180,12 +189,15 @@
37fd76
 
37fd76
   # Version
37fd76
   --version|-v)
37fd76
+    phpize_check_headers
37fd76
     phpize_print_api_numbers
37fd76
     exit 0
37fd76
   ;;
37fd76
 
37fd76
   # Default
37fd76
   *)
37fd76
+     phpize_check_headers
37fd76
+
37fd76
      phpize_check_configm4 0
37fd76
 
37fd76
      phpize_check_build_files