[BUGFIX] Support packages depending on typo3/cms 74/37974/3
authorMathias Brodala <mbrodala@pagemachine.de>
Fri, 20 Mar 2015 14:07:06 +0000 (15:07 +0100)
committerNicole Cordes <typo3@cordes.co>
Fri, 4 Sep 2015 21:50:40 +0000 (23:50 +0200)
This adds "typo3/cms" to the list of non composer requirements to allow
packages to depend on it (and thus install the core through Composer) and still
be installable in the Extension Manager.

Resolves: #65867
Releases: master, 6.2
Change-Id: I8564f8dff000fa71876c01343411a3155e0c0c92
Reviewed-on: http://review.typo3.org/37974
Reviewed-by: Helmut Hummel <helmut.hummel@typo3.org>
Tested-by: Helmut Hummel <helmut.hummel@typo3.org>
Reviewed-by: Nicole Cordes <typo3@cordes.co>
Tested-by: Nicole Cordes <typo3@cordes.co>
typo3/sysext/core/Classes/Package/Package.php

index 3de91c6..cb479c0 100644 (file)
@@ -327,8 +327,9 @@ class Package implements PackageInterface {
                // According to http://getcomposer.org/doc/02-libraries.md#platform-packages
                // the following regex should capture all non composer requirements.
                // typo3 is included in the list because it's a meta package and not supported for now.
+               // typo3/cms is included since it's basically a container and cannot be detected at runtime.
                // composer/installers is included until extensionmanager can handle composer packages natively
-               return preg_match('/^(php(-64bit)?|ext-[^\/]+|lib-(curl|iconv|libxml|openssl|pcre|uuid|xsl)|typo3|composer\/installers)$/', $requirement) !== 1;
+               return preg_match('/^(php(-64bit)?|ext-[^\/]+|lib-(curl|iconv|libxml|openssl|pcre|uuid|xsl)|typo3|typo3\/cms|composer\/installers)$/', $requirement) !== 1;
        }
 
        /**