Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 374605

Summary: www-apps/moodle doesn't support dev-lang/php[gd-external]
Product: Gentoo Linux Reporter: Nathan Phillip Brink (binki) (RETIRED) <binki>
Component: [OLD] UnspecifiedAssignee: Anthony Basile <blueness>
Status: RESOLVED FIXED    
Severity: normal CC: web-apps
Priority: Normal    
Version: unspecified   
Hardware: All   
OS: All   
Whiteboard:
Package list:
Runtime testing required: ---

Description Nathan Phillip Brink (binki) (RETIRED) gentoo-dev 2011-07-09 21:14:53 UTC
In dev-lang/php's REQUIRED_USE, I find:

        gd? ( zlib !gd-external )
        gd-external? ( !gd )

This means, I think, that any app which depends on php with gd support has to depend on || ( dev-lang/php[gd] dev-lang/php[gd-external] ) instead of requiring php to use the built-in gd.

(Or maybe would it make more sense for php's gd-external useflag to require that the gd useflag be enabled to prevent making deps on php[gd] complicated?)
Comment 1 Anthony Basile gentoo-dev 2011-07-11 08:23:56 UTC
Okay, I've restructured the RDEPEND to reflect this.  The new ebuilds are on my overlay for testing before being moved to the tree.  There is no rev bump since anyone who has moodle installed would not need to reinstall it to get this fix.  The commit is at:

http://git.overlays.gentoo.org/gitweb/?p=dev/blueness.git;a=blob;f=www-apps/moodle/moodle-1.9.12.ebuild;h=5c20029d2d4fcb97874343cc2b606ba9fddc7183;hb=9e49fb4154cacffeb6057c3475b27f19a95f8c4f


I'll repeat the diff here for convenience.  For 1.9.12

29c29,30
< PHPFLAGS="ctype,curl,gd,iconv,ssl,tokenizer,xml,xmlrpc,zlib"
---
> PHPFLAGS_A="ctype,curl,gd,iconv,ssl,tokenizer,xml,xmlrpc,zlib"
> PHPFLAGS_B="ctype,curl,gd-external,iconv,ssl,tokenizer,xml,xmlrpc,zlib"
38c39,43
< RDEPEND=">=dev-lang/php-4.3.0[${DBFLAGS},${AUTHFLAGS},${PHPFLAGS}]
---
> RDEPEND="
> 	|| (
> 		>=dev-lang/php-4.3.0[${DBFLAGS},${AUTHFLAGS},${PHPFLAGS_A}]
> 		>=dev-lang/php-4.3.0[${DBFLAGS},${AUTHFLAGS},${PHPFLAGS_B}]
> 	)


For 2.0.3 (and similarly 2.1):
30,31c30,33
< PHP_OPTIONAL_FLAGS_52="gd,soap,ssl,tokenizer,xmlrpc"
< PHP_FLAGS_52="${PHP_REQUIRED_FLAGS_52},${PHP_OPTIONAL_FLAGS_52}"
---
> PHP_OPTIONAL_FLAGS_52_A="gd,soap,ssl,tokenizer,xmlrpc"
> PHP_OPTIONAL_FLAGS_52_B="gd-external,soap,ssl,tokenizer,xmlrpc"
> PHP_FLAGS_52_A="${PHP_REQUIRED_FLAGS_52},${PHP_OPTIONAL_FLAGS_52_A}"
> PHP_FLAGS_52_B="${PHP_REQUIRED_FLAGS_52},${PHP_OPTIONAL_FLAGS_52_B}"
34,35c36,39
< PHP_OPTIONAL_FLAGS_53="gd,intl,soap,ssl,tokenizer,xmlrpc"
< PHP_FLAGS_53="${PHP_REQUIRED_FLAGS_53},${PHP_OPTIONAL_FLAGS_53}"
---
> PHP_OPTIONAL_FLAGS_53_A="gd,intl,soap,ssl,tokenizer,xmlrpc"
> PHP_OPTIONAL_FLAGS_53_B="gd-external,intl,soap,ssl,tokenizer,xmlrpc"
> PHP_FLAGS_53_A="${PHP_REQUIRED_FLAGS_53},${PHP_OPTIONAL_FLAGS_53_A}"
> PHP_FLAGS_53_B="${PHP_REQUIRED_FLAGS_53},${PHP_OPTIONAL_FLAGS_53_B}"
46,47c50,53
< 		=dev-lang/php-5.2*[${DB_FLAGS},${AUTHENTICATION_FLAGS},${PHP_FLAGS_52}]
< 		=dev-lang/php-5.3*[${DB_FLAGS},${AUTHENTICATION_FLAGS},${PHP_FLAGS_53}]
---
> 		=dev-lang/php-5.2*[${DB_FLAGS},${AUTHENTICATION_FLAGS},${PHP_FLAGS_52_A}]
> 		=dev-lang/php-5.2*[${DB_FLAGS},${AUTHENTICATION_FLAGS},${PHP_FLAGS_52_B}]
> 		=dev-lang/php-5.3*[${DB_FLAGS},${AUTHENTICATION_FLAGS},${PHP_FLAGS_53_A}]
> 		=dev-lang/php-5.3*[${DB_FLAGS},${AUTHENTICATION_FLAGS},${PHP_FLAGS_53_B}]
Comment 2 Anthony Basile gentoo-dev 2011-07-12 21:13:41 UTC
I tested and the dependencies work as expected.  I moved the ebuilds from my dev overlay to the tree.