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

Bug 129488

Summary: php with postgresql and threads requires libpq built with threads USE flag
Product: Gentoo Linux Reporter: Chris Bainbridge (RETIRED) <chrb>
Component: New packagesAssignee: PHP Bugs <php-bugs>
Status: RESOLVED FIXED    
Severity: normal CC: esigra
Priority: High    
Version: 2005.1   
Hardware: All   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---
Bug Depends on: 120190    
Bug Blocks:    

Description Chris Bainbridge (RETIRED) gentoo-dev 2006-04-10 08:37:17 UTC
php with postgresql and threads requires libpq built with threads USE flag.
Comment 1 Luca Longinotti (RETIRED) gentoo-dev 2006-04-18 05:55:20 UTC
Fixed with an additional check to the PHP eclasses:

php_check_pgsql() {
	if useq "postgres" \
	&& useq "apache2" && useq "threads" \
	&& has_version ">=dev-db/libpq-8.1.3-r1" \
	&& ! built_with_use ">=dev-db/libpq-8.1.3-r1" "threads" ; then
		eerror
		eerror "You must build dev-db/libpq with the 'threads' USE flag"
		eerror "turned on if you want to build PHP with threads support!"
		eerror
		die "Rebuild dev-db/libpq with 'threads' USE flag enabled"
	fi
}

It checks for both use "apache2" and "threads" in PHP, as only if both are enabled, PHP is compiled with thread-safety/support enabled. It also checks for the libpq version, since I've seen that only >=libpq-8.1.3-r1 has the "threads" USE flag/support.
Best regards, CHTEKK.