Common subdirectories: image_captcha/CVS and new_image_captcha/CVS
Common subdirectories: image_captcha/fonts and new_image_captcha/fonts
diff -upw image_captcha/image_captcha.admin.inc new_image_captcha/image_captcha.admin.inc
--- image_captcha/image_captcha.admin.inc	2009-09-23 00:51:00.000000000 +0200
+++ new_image_captcha/image_captcha.admin.inc	2009-09-23 10:45:17.625000000 +0200
@@ -49,6 +49,14 @@ function image_captcha_settings_form() {
     // It is no use to continue building the rest of the settings form.
     return $form;
   }
+  if ($image_captcha_setup_errno & IMAGE_CAPTCHA_ERROR_NO_GDLIB_WITH_PNG) {
+    drupal_set_message(t(
+      'The Image CAPTCHA module can not generate images because your PHP setup does not support it (no <a href="!gdlib">GD library</a> with PNG support).',
+      array('!gdlib' => 'http://php.net/manual/en/book.image.php')
+    ), 'error');
+    // It is no use to continue building the rest of the settings form.
+    return $form;
+  }
 
   $form['image_captcha_example'] = array(
     '#type' => 'fieldset',
diff -upw image_captcha/image_captcha.module new_image_captcha/image_captcha.module
--- image_captcha/image_captcha.module	2009-09-23 00:51:00.000000000 +0200
+++ new_image_captcha/image_captcha.module	2009-09-23 10:42:50.125000000 +0200
@@ -12,6 +12,7 @@ define('IMAGE_CAPTCHA_ALLOWED_CHARACTERS
 
 define('IMAGE_CAPTCHA_SETUP_OK', 0);
 define('IMAGE_CAPTCHA_ERROR_NO_GDLIB_WITH_JPEG', 1);
+define('IMAGE_CAPTCHA_ERROR_NO_GDLIB_WITH_PNG', 3);
 define('IMAGE_CAPTCHA_ERROR_NO_TTF_SUPPORT', 2);
 define('IMAGE_CAPTCHA_ERROR_TTF_FILE_READ_PROBLEM', 4);
 
@@ -106,13 +107,16 @@ function _image_captcha_utf8_split($str)
  * Helper function for checking if the requirements for the Image CAPTCHA are met.
  *
  * @return error code such as IMAGE_CAPTCHA_SETUP_OK, IMAGE_CAPTCHA_ERROR_NO_GDLIB_WITH_JPEG,
- *   IMAGE_CAPTCHA_ERROR_NO_TTF_SUPPORT, IMAGE_CAPTCHA_ERROR_TTF_FILE_READ_PROBLEM.
+ *   IMAGE_CAPTCHA_ERROR_NO_GDLIB_WITH_PNG, IMAGE_CAPTCHA_ERROR_NO_TTF_SUPPORT, IMAGE_CAPTCHA_ERROR_TTF_FILE_READ_PROBLEM.
  */
 function _image_captcha_check_setup() {
   // Check GD library and is TTF support.
   if (!function_exists('imagejpeg')) {
     return IMAGE_CAPTCHA_ERROR_NO_GDLIB_WITH_JPEG;
   }
+  if (!function_exists('imagepng')) {
+    return IMAGE_CAPTCHA_ERROR_NO_GDLIB_WITH_PNG;
+  }  
   if (!function_exists('imagettftext')) {
     return IMAGE_CAPTCHA_ERROR_NO_TTF_SUPPORT;
   }
