Fixed issue #3682: im_version_5 is always reset to im5 when using ImageMagick 6.x
authorFrancois Suter <francois.suter@typo3.org>
Wed, 11 Mar 2009 16:53:51 +0000 (16:53 +0000)
committerFrancois Suter <francois.suter@typo3.org>
Wed, 11 Mar 2009 16:53:51 +0000 (16:53 +0000)
git-svn-id: https://svn.typo3.org/TYPO3v4/Core/trunk@5198 709f56b5-9817-0410-a4d7-c38de5d9e867

ChangeLog
typo3/sysext/install/mod/class.tx_install.php

index d9e7718..6623ded 100755 (executable)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,7 @@
+2009-03-11  Francois Suter  <francois@typo3.org>
+
+       * Fixed issue #3682: im_version_5 is always reset to im5 when using ImageMagick 6.x (thanks to Andreas Wolf and Steffen Gebert)
+
 2009-03-11  Stanislas Rolland  <typo3@sjbr.ca>
 
        * Fixed issue #7973: htmlArea RTE: Superfluous leading bar inserted in toolbar after linebreak
index e2f75ad..87e245e 100755 (executable)
@@ -2204,7 +2204,9 @@ From sub-directory:
                                                                                $value_ext = 'gm';
                                                                        } elseif(doubleval($version)<5) {       // Assume ImageMagick 4.x
                                                                                $value_ext = '';
-                                                                       } else  {       // Assume ImageMagick 5+
+                                                                       } elseif(doubleval($version) >= 6) {    // Assume ImageMagick 6.x
+                                                                               $value_ext = 'im6';
+                                                                       } else  {       // Assume ImageMagick 5.x
                                                                                $value_ext = 'im5';
                                                                        }
                                                                        if (strcmp(strtolower($GLOBALS['TYPO3_CONF_VARS']['GFX']['im_version_5']),$value_ext))  {
@@ -2413,7 +2415,16 @@ From sub-directory:
                                                        $formArray['im_path']=array($path);
                                                        $found=1;
                                                }
-                                       } elseif (!$found)      {
+                                       } elseif (doubleval($dat['convert']) >= 6) {
+                                               $formArray['im_version_5'] = array('im6');
+                                               if ($dat['gif_capability'] == 'LZW') {
+                                                       $formArray['im_path'] = array($path);
+                                                       $found = 2;
+                                               } elseif ($found < 2)   {
+                                                       $formArray['im_path'] = array($path);
+                                                       $found = 1;
+                                               }
+                                       } elseif (!$found) {
                                                $formArray['im_version_5']=array('im5');
                                                $formArray['im_path']=array($path);
                                                $found=1;