Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 352560 - dev-lang/php[suhosin] can only be installed when dev-lang/php[-suhosin]
Summary: dev-lang/php[suhosin] can only be installed when dev-lang/php[-suhosin]
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Core system (show other bugs)
Hardware: All Linux
: High normal (vote)
Assignee: PHP Bugs
URL:
Whiteboard:
Keywords:
: 353057 (view as bug list)
Depends on:
Blocks:
 
Reported: 2011-01-23 23:48 UTC by Tiago Marques
Modified: 2011-01-29 23:18 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tiago Marques 2011-01-23 23:48:07 UTC
If I have suhosin merged first, it goes ok, otherwise it emerges php twice:

-----------------------------------------------------------------------------------

sudo emerge php -pv

These are the packages that would be merged, in order:

Calculating dependencies... done!


[nomerge      ] dev-lang/php-5.3.5  USE="apache2 berkdb bzip2 cli crypt ctype curl fileinfo filter gd gdbm hash iconv ipv6 json mysql nls phar posix readline session simplexml ssl suhosin tokenizer unicode xml zlib -adabas -bcmath -birdstep -calendar -cdb -cgi -cjk -curlwrappers -db2 -dbmaker -debug -doc -embed -empress -empress-bcs -enchant -esoob -exif -firebird -flatfile -fpm -frontbase -ftp -gd-external -gmp -imap -inifile -interbase -intl -iodbc -kerberos -kolab -ldap -ldap-sasl -libedit -mhash -mssql -mysqli -mysqlnd -oci8 -oci8-instant-client -odbc -pcntl -pdo -pic -postgres -qdbm -recode -sapdb -sharedext -sharedmem -snmp -soap -sockets -solid -spell -sqlite -sqlite3 -sybase-ct -sysvipc -threads -tidy -truetype -wddx -xmlreader -xmlrpc -xmlwriter -xpm -xsl -zip"
[ebuild  N    ]  dev-php5/suhosin-0.9.32.1-r2  PHP_TARGETS="php5-3 -php5-2" 117 kB
[ebuild  N    ]   dev-lang/php-5.3.5  USE="apache2 berkdb bzip2 cli crypt ctype curl fileinfo filter gd gdbm hash iconv ipv6 json mysql nls phar posix readline session simplexml ssl suhosin tokenizer unicode xml zlib -adabas -bcmath -birdstep -calendar -cdb -cgi -cjk -curlwrappers -db2 -dbmaker -debug -doc -embed -empress -empress-bcs -enchant -esoob -exif -firebird -flatfile -fpm -frontbase -ftp -gd-external -gmp -imap -inifile -interbase -intl -iodbc -kerberos -kolab -ldap -ldap-sasl -libedit -mhash -mssql -mysqli -mysqlnd -oci8 -oci8-instant-client -odbc -pcntl -pdo -pic -postgres -qdbm -recode -sapdb -sharedext -sharedmem -snmp -soap -sockets -solid -spell -sqlite -sqlite3 -sybase-ct -sysvipc -threads -tidy -truetype -wddx -xmlreader -xmlrpc -xmlwriter -xpm -xsl -zip" 10,603 kB

Total: 2 packages (2 new), Size of downloads: 10,719 kB

 * Error: circular dependencies:

(dev-lang/php-5.3.5, ebuild scheduled for merge) depends on
 (dev-lang/php-5.3.5, ebuild scheduled for merge) (buildtime)

It might be possible to break this cycle
by applying the following change:
- dev-lang/php-5.3.5 (Change USE: -suhosin)

Note that this change can be reverted, once the package has been installed.

 * IMPORTANT: 2 news items need reading for repository 'gentoo'.
 * Use eselect news to read news items.

tmarques@li196-165 ~ $ sudo emerge suhosin php -pv

These are the packages that would be merged, in order:

Calculating dependencies... done!


[ebuild  N    ] dev-php5/suhosin-0.9.32.1-r2  PHP_TARGETS="php5-3 -php5-2" 117 kB
[ebuild  N    ]  dev-lang/php-5.3.5  USE="apache2 berkdb bzip2 cli crypt ctype curl fileinfo filter gd gdbm hash iconv ipv6 json mysql nls phar posix readline session simplexml ssl suhosin tokenizer unicode xml zlib -adabas -bcmath -birdstep -calendar -cdb -cgi -cjk -curlwrappers -db2 -dbmaker -debug -doc -embed -empress -empress-bcs -enchant -esoob -exif -firebird -flatfile -fpm -frontbase -ftp -gd-external -gmp -imap -inifile -interbase -intl -iodbc -kerberos -kolab -ldap -ldap-sasl -libedit -mhash -mssql -mysqli -mysqlnd -oci8 -oci8-instant-client -odbc -pcntl -pdo -pic -postgres -qdbm -recode -sapdb -sharedext -sharedmem -snmp -soap -sockets -solid -spell -sqlite -sqlite3 -sybase-ct -sysvipc -threads -tidy -truetype -wddx -xmlreader -xmlrpc -xmlwriter -xpm -xsl -zip" 10,603 kB

Total: 2 packages (2 new), Size of downloads: 10,719 kB

 * Error: circular dependencies:

(dev-lang/php-5.3.5, ebuild scheduled for merge) depends on
 (dev-lang/php-5.3.5, ebuild scheduled for merge) (buildtime)

It might be possible to break this cycle
by applying the following change:
- dev-lang/php-5.3.5 (Change USE: -suhosin)

Note that this change can be reverted, once the package has been installed.

 * IMPORTANT: 2 news items need reading for repository 'gentoo'.
 * Use eselect news to read news items.


-----------------------------------------------------------------------------------------------


tmarques@li196-165 ~ $ emerge --info
Portage 2.1.9.25 (default/linux/x86/10.0, gcc-4.4.3, glibc-2.10.1-r1, 2.6.32.16-linode28 i686)
=================================================================
System uname: Linux-2.6.32.16-linode28-i686-Intel-R-_Xeon-R-_CPU_L5520_@_2.27GHz-with-gentoo-1.12.13
Timestamp of tree: Sun, 23 Jan 2011 23:30:22 +0000
app-shells/bash:     4.0_p37
dev-lang/python:     2.6.4-r1, 3.1.2-r3
sys-apps/baselayout: 1.12.13
sys-apps/sandbox:    1.6-r2
sys-devel/autoconf:  2.65
sys-devel/automake:  1.11.1
sys-devel/binutils:  2.20.1-r1
sys-devel/gcc:       4.4.3-r2
sys-devel/gcc-config: 1.4.1
sys-devel/libtool:   2.2.6b
sys-devel/make:      3.81
virtual/os-headers:  2.6.30-r1 (sys-kernel/linux-headers)
ACCEPT_KEYWORDS="x86"
ACCEPT_LICENSE="*"
CBUILD="x86_64-pc-linux-gnu"
CFLAGS="-O2 -pipe"
CHOST="x86_64-pc-linux-gnu"
CONFIG_PROTECT="/etc"
CONFIG_PROTECT_MASK="/etc/ca-certificates.conf /etc/env.d /etc/gconf /etc/sandbox.d /etc/terminfo"
CXXFLAGS="-O2 -pipe"
DISTDIR="/tmp/distfiles"
FEATURES="assume-digests binpkg-logs distlocks fixlafiles fixpackages news parallel-fetch protect-owned sandbox sfperms strict unknown-features-warn unmerge-logs unmerge-orphans userfetch"
GENTOO_MIRRORS="http://distfiles.gentoo.org"
LDFLAGS="-Wl,-O1 -Wl,--as-needed"
MAKEOPTS="-j4"
PKGDIR="/usr/portage/packages"
PORTAGE_CONFIGROOT="/"
PORTAGE_RSYNC_OPTS="--recursive --links --safe-links --perms --times --compress --force --whole-file --delete --stats --timeout=180 --exclude=/distfiles --exclude=/local --exclude=/packages"
PORTAGE_TMPDIR="/tmp"
PORTDIR="/usr/portage"
SYNC="rsync://rsync.gentoo.org/gentoo-portage"
USE="acl berkdb bzip2 cli cracklib crypt cxx dri fortran gdbm gpm iconv ipv6 modules mudflap ncurses nls nptl nptlonly openmp pam pcre perl pppd python readline session ssl sysfs tcpd unicode x86 xorg zlib" ALSA_CARDS="ali5451 als4000 atiixp atiixp-modem bt87x ca0106 cmipci emu10k1 emu10k1x ens1370 ens1371 es1938 es1968 fm801 hda-intel intel8x0 intel8x0m maestro3 trident usb-audio via82xx via82xx-modem ymfpci" ALSA_PCM_PLUGINS="adpcm alaw asym copy dmix dshare dsnoop empty extplug file hooks iec958 ioplug ladspa lfloat linear meter mmap_emul mulaw multi null plug rate route share shm softvol" APACHE2_MODULES="actions alias auth_basic authn_alias authn_anon authn_dbm authn_default authn_file authz_dbm authz_default authz_groupfile authz_host authz_owner authz_user autoindex cache cgi cgid dav dav_fs dav_lock deflate dir disk_cache env expires ext_filter file_cache filter headers include info log_config logio mem_cache mime mime_magic negotiation rewrite setenvif speling status unique_id userdir usertrack vhost_alias" APACHE2_MPMS="prefork" COLLECTD_PLUGINS="df interface irq load memory rrdtool swap syslog" ELIBC="glibc" GPSD_PROTOCOLS="ashtech aivdm earthmate evermore fv18 garmin garmintxt gpsclock itrax mtk3301 nmea ntrip navcom oceanserver oldstyle oncore rtcm104v2 rtcm104v3 sirf superstar2 timing tsip tripmate tnt ubx" INPUT_DEVICES="keyboard mouse evdev" KERNEL="linux" LCD_DEVICES="bayrad cfontz cfontz633 glk hd44780 lb216 lcdm001 mtxorb ncurses text" PHP_TARGETS="php5-3" RUBY_TARGETS="ruby18" USERLAND="GNU" VIDEO_CARDS="fbdev glint intel mach64 mga neomagic nouveau nv r128 radeon savage sis tdfx trident vesa via vmware dummy v4l" XTABLES_ADDONS="quota2 psd pknock lscan length2 ipv4options ipset ipp2p iface geoip fuzzy condition tee tarpit sysrq steal rawnat logmark ipmark dhcpmac delude chaos account"
Unset:  CPPFLAGS, CTARGET, EMERGE_DEFAULT_OPTS, FFLAGS, INSTALL_MASK, LANG, LC_ALL, LINGUAS, PORTAGE_BUNZIP2_COMMAND, PORTAGE_COMPRESS, PORTAGE_COMPRESS_FLAGS, PORTAGE_RSYNC_EXTRA_OPTS, PORTDIR_OVERLAY


Reproducible: Always
Comment 1 Tiago Marques 2011-01-24 00:00:35 UTC
My bad. This is completely broken, I can't even install it without removing the flag. This is strange, as I did just that a few weeks ago, with this same version of PHP.
Comment 2 Jeroen Roovers (RETIRED) gentoo-dev 2011-01-25 01:42:00 UTC
This is probably a duplicate, but it's still quite a bad bug.
Comment 3 Tiago Marques 2011-01-27 20:21:41 UTC
Strange, managed to install it with the flag after an install without it, which brought other packages like apache.
Comment 4 Matti Bickel (RETIRED) gentoo-dev 2011-01-27 20:44:49 UTC
The problem here is that suhosin requires php to be built with USE='unicode'. We currently enforce this via a DEPEND on dev-lang/php-5.3*[unicode]. This is where the self-reference comes from.

I was under the impression this only affected a minority of users upgrading from a suhosin-less php to one with suhosin installed. Plus the php-5.3* bit should allow the update to procede if you have any version of php-5.3 installed.
Portage in fact tells you, you might get suhosin after installing w/o it:
"Note that this change can be reverted, once the package has been installed."

Is this a fresh install of php or are you upgrading from a previous version? If you're upgrading, from which version?

I agree that this is difficult. I agree we can do better. In fact, with the upcoming release of EAPI4 the php ebuilds will be a lot more user-friendly with regards to USE-flags. Promised.
Comment 5 Tiago Marques 2011-01-27 22:37:41 UTC
Thanks for looking into this. 
Yes, it is was a clean install.
Comment 6 Matti Bickel (RETIRED) gentoo-dev 2011-01-28 15:07:27 UTC
*** Bug 353057 has been marked as a duplicate of this bug. ***
Comment 7 Matti Bickel (RETIRED) gentoo-dev 2011-01-28 22:25:54 UTC
So after speaking with Ole about this, it occurred to me that DEPEND is a too strong requirement. We can actually get away with having the self depend in RDEPEND. Which will still give you a nasty warning when USE="-unicode suhosin", but it won't bark at you on new installs.

Going to commit a new version that fixes this tomorrow.
Comment 8 Matti Bickel (RETIRED) gentoo-dev 2011-01-29 22:19:50 UTC
Should be fixed now. Thanks for reporting this!
Comment 9 Tiago Marques 2011-01-29 23:18:42 UTC
You're welcome! Thanks for fixing it!

Best regards,
Tiago