]> granicus.if.org Git - php/commitdiff
- MFH: add png and jpeg version info
authorPierre Joye <pajoye@php.net>
Tue, 4 Nov 2008 20:25:45 +0000 (20:25 +0000)
committerPierre Joye <pajoye@php.net>
Tue, 4 Nov 2008 20:25:45 +0000 (20:25 +0000)
ext/gd/gd.c

index 1c4149c7bf75868629835d0ada4805ce48112f20..8c6f5fe7f6cd596006613c565e3dfd5e9a029393 100644 (file)
 /* needs to be first */
 #include <png.h>
 #endif
+#ifdef HAVE_GD_JPG
+/* needs to be first */
+#include <jpeglib.h>
+#endif
 
 #include "php.h"
 #include "php_ini.h"
@@ -1390,10 +1394,16 @@ PHP_MINFO_FUNCTION(gd)
        php_info_print_table_row(2, "GIF Create Support", "enabled");
 #endif
 #ifdef HAVE_GD_JPG
-       php_info_print_table_row(2, "JPG Support", "enabled");
+       {
+               char tmp[256];
+               snprintf(tmp, sizeof(tmp), "%d", JPEG_LIB_VERSION);
+               php_info_print_table_row(2, "JPG Support", "enabled");
+               php_info_print_table_row(2, "libJPEG Version", tmp);
+       }
 #endif
 #ifdef HAVE_GD_PNG
        php_info_print_table_row(2, "PNG Support", "enabled");
+       php_info_print_table_row(2, "libPNG Version", PNG_LIBPNG_VER_STRING);
 #endif
 #ifdef HAVE_GD_WBMP
        php_info_print_table_row(2, "WBMP Support", "enabled");