View previous topic :: View next topic |
Author |
Message |
mdtn n00b


Joined: 30 Jun 2003 Posts: 33
|
Posted: Tue Jul 15, 2003 2:57 pm Post subject: customizing php and mod_php ebuild question |
|
|
hello,
i am new to gentoo and i hope someone can help me with this subject. i wish to emerge both php and mod_php with the option '--with-regex=system'. i have successfully emerge both with the default setting but a program i am working with requires me to have the 'regex' option set to 'system'.
php-4.3.2
Usage: configure [options] [host]
--with-regex=TYPE regex library type: system, apache, php. Default: php
it it possible for me to modify the ebuild after i emerge so it includes the 'regex' option?
for example: (for php-4.3.2) add '--with-regex=system' to the php-4.3.2.ebuild
src_compile() {
use readline && myconf="${myconf} --with-readline"
myconf="${myconf} \
--disable-cgi \
--enable-cli \
--with-regex=system" # <------------------------NEW
php_src_compile
}
and then run the ebuild. can someone tell me if this is the correct approach or should i try something else.
Thanks in advance.
/mdtn |
|
Back to top |
|
 |
Pythonhead Developer


Joined: 16 Dec 2002 Posts: 1801 Location: Redondo Beach, Republic of Calif.
|
Posted: Tue Jul 15, 2003 3:10 pm Post subject: |
|
|
Yes, that looks correct. Just copy the ebuild to /usr/local/portage/dev-php/php so it won't be over-written on the next 'emerge sync' |
|
Back to top |
|
 |
mdtn n00b


Joined: 30 Jun 2003 Posts: 33
|
Posted: Wed Jul 16, 2003 11:46 pm Post subject: |
|
|
i was able to get 'php-4.3.2.ebuild' to re-emerge and work correctly but i am still having problem with mod_php.
inside my 'mod_php-4.3.2-r3.ebuild' i have added '--with-regex=system' but now i am running into some conflict with apache.
Inside 'mod_php-4.3.2-r3.ebuild'
=====================
...
src_compile() {
#no readline on server SAPI
myconf="${myconf} --without-readline --with-regex=system"
# Every Apache2 MPM EXCEPT prefork needs Zend Thread Safety
if [ -n "${USE_APACHE2}" ]; then
APACHE2_MPM="`apache2 -l |egrep 'worker|prechild|leader|threadpool|prefork'|xargs|cut -d. -f1`"
case "${APACHE2_MPM}" in
prefork) ;;
*) myconf="${myconf} --enable-experimental-zts" ;;
esac;
fi
# optional support for apache2
#&& myconf="${myconf} --with-apxs2=/usr/sbin/apxs2" \
#|| myconf="${myconf} --with-apxs=/usr/sbin/apxs"
#use apache2 \
myconf="${myconf} --with-apxs${USE_APACHE2}=/usr/sbin/apxs${USE_APACHE2}"
#php CGI stuff
#--enable-discard-path --enable-force-cgi-redirect
php_src_compile
}
...
=====================
ERROR after editing my ebuild and re-emerging
=====================
/bin/sh /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/libtool --silent --preserve-dup-deps --mode=compile gcc -Isapi/cli/ -I/var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/cli/ -DPHP_ATOM_INC -I/var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/include -I/var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main -I/var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2 -I/usr/include/apache2 -I/var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/Zend -I/usr/include/libxml2 -I/usr/include/mysql -I/usr/include/pspell -I/usr/qt/3/include -I/var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/ext/xml/expat -I/var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/TSRM -march=pentium3 -O3 -pipe -prefer-pic -c /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/cli/getopt.c -o sapi/cli/getopt.lo
In file included from /usr/include/apache2/httpd.h:86,
from /usr/include/apache2/util_filter.h:61,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/sapi_apache2.c:40:
/usr/include/apache2/pcreposix.h:26:1: warning: "REG_ICASE" redefined
In file included from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main/php_regex.h:39,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main/php.h:74,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/sapi_apache2.c:25:
/usr/include/regex.h:266:1: warning: this is the location of the previous definition
In file included from /usr/include/apache2/httpd.h:86,
from /usr/include/apache2/util_filter.h:61,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/sapi_apache2.c:40:
/usr/include/apache2/pcreposix.h:27:1: warning: "REG_NEWLINE" redefined
In file included from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main/php_regex.h:39,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main/php.h:74,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/sapi_apache2.c:25:
/usr/include/regex.h:271:1: warning: this is the location of the previous definition
In file included from /usr/include/apache2/httpd.h:86,
from /usr/include/apache2/util_filter.h:61,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/sapi_apache2.c:40:
/usr/include/apache2/pcreposix.h:28:1: warning: "REG_NOTBOL" redefined
In file included from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main/php_regex.h:39,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main/php.h:74,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/sapi_apache2.c:25:
/usr/include/regex.h:285:1: warning: this is the location of the previous definition
In file included from /usr/include/apache2/httpd.h:86,
from /usr/include/apache2/util_filter.h:61,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/sapi_apache2.c:40:
/usr/include/apache2/pcreposix.h:29:1: warning: "REG_NOTEOL" redefined
In file included from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main/php_regex.h:39,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main/php.h:74,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/sapi_apache2.c:25:
/usr/include/regex.h:288:1: warning: this is the location of the previous definition
In file included from /usr/include/apache2/httpd.h:86,
from /usr/include/apache2/util_filter.h:61,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/sapi_apache2.c:40:
/usr/include/apache2/pcreposix.h:34:1: warning: "REG_EXTENDED" redefined
In file included from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main/php_regex.h:39,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main/php.h:74,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/sapi_apache2.c:25:
/usr/include/regex.h:262:1: warning: this is the location of the previous definition
In file included from /usr/include/apache2/httpd.h:86,
from /usr/include/apache2/util_filter.h:61,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/sapi_apache2.c:40:
/usr/include/apache2/pcreposix.h:35:1: warning: "REG_NOSUB" redefined
In file included from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main/php_regex.h:39,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main/php.h:74,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/sapi_apache2.c:25:
/usr/include/regex.h:275:1: warning: this is the location of the previous definition
In file included from /usr/include/apache2/httpd.h:86,
from /usr/include/apache2/util_filter.h:61,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/sapi_apache2.c:40:
/usr/include/apache2/pcreposix.h:41: conflicting types for `REG_BADBR'
/usr/include/regex.h:312: previous declaration of `REG_BADBR'
/usr/include/apache2/pcreposix.h:42: conflicting types for `REG_BADPAT'
/usr/include/regex.h:304: previous declaration of `REG_BADPAT'
/usr/include/apache2/pcreposix.h:43: conflicting types for `REG_BADRPT'
/usr/include/regex.h:315: previous declaration of `REG_BADRPT'
/usr/include/apache2/pcreposix.h:44: conflicting types for `REG_EBRACE'
/usr/include/regex.h:311: previous declaration of `REG_EBRACE'
/usr/include/apache2/pcreposix.h:45: conflicting types for `REG_EBRACK'
/usr/include/regex.h:309: previous declaration of `REG_EBRACK'
/usr/include/apache2/pcreposix.h:46: conflicting types for `REG_ECOLLATE'
/usr/include/regex.h:305: previous declaration of `REG_ECOLLATE'
/usr/include/apache2/pcreposix.h:47: conflicting types for `REG_ECTYPE'
/usr/include/regex.h:306: previous declaration of `REG_ECTYPE'
/usr/include/apache2/pcreposix.h:48: conflicting types for `REG_EESCAPE'
/usr/include/regex.h:307: previous declaration of `REG_EESCAPE'
/usr/include/apache2/pcreposix.h:50: conflicting types for `REG_EPAREN'
/usr/include/regex.h:310: previous declaration of `REG_EPAREN'
/usr/include/apache2/pcreposix.h:51: conflicting types for `REG_ERANGE'
/usr/include/regex.h:313: previous declaration of `REG_ERANGE'
/usr/include/apache2/pcreposix.h:52: conflicting types for `REG_ESIZE'
/usr/include/regex.h:319: previous declaration of `REG_ESIZE'
/usr/include/apache2/pcreposix.h:53: conflicting types for `REG_ESPACE'
/usr/include/regex.h:314: previous declaration of `REG_ESPACE'
/usr/include/apache2/pcreposix.h:54: conflicting types for `REG_ESUBREG'
/usr/include/regex.h:308: previous declaration of `REG_ESUBREG'
/usr/include/apache2/pcreposix.h:57: conflicting types for `REG_NOMATCH'
/usr/include/regex.h:300: previous declaration of `REG_NOMATCH'
/usr/include/apache2/pcreposix.h:66: conflicting types for `regex_t'
/usr/include/regex.h:401: previous declaration of `regex_t'
/usr/include/apache2/pcreposix.h:70: warning: redefinition of `regoff_t'
/usr/include/regex.h:404: warning: `regoff_t' previously declared here
/usr/include/apache2/pcreposix.h:75: conflicting types for `regmatch_t'
/usr/include/regex.h:432: previous declaration of `regmatch_t'
/usr/include/apache2/pcreposix.h:79: conflicting types for `regcomp'
/usr/include/regex.h:547: previous declaration of `regcomp'
/usr/include/apache2/pcreposix.h:80: conflicting types for `regexec'
/usr/include/regex.h:551: previous declaration of `regexec'
/usr/include/apache2/pcreposix.h:81: conflicting types for `regerror'
/usr/include/regex.h:556: previous declaration of `regerror'
/usr/include/apache2/pcreposix.h:82: conflicting types for `regfree'
/usr/include/regex.h:559: previous declaration of `regfree'
distcc[2706] ERROR: compile on localhost failed with exit code 1
make: *** [sapi/apache2handler/sapi_apache2.lo] Error 1
make: *** Waiting for unfinished jobs....
In file included from /usr/include/apache2/httpd.h:86,
from /usr/include/apache2/util_filter.h:61,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/php_functions.c:32:
/usr/include/apache2/pcreposix.h:26:1: warning: "REG_ICASE" redefined
In file included from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main/php_regex.h:39,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main/php.h:74,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/php_functions.c:21:
/usr/include/regex.h:266:1: warning: this is the location of the previous definition
In file included from /usr/include/apache2/httpd.h:86,
from /usr/include/apache2/util_filter.h:61,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/php_functions.c:32:
/usr/include/apache2/pcreposix.h:27:1: warning: "REG_NEWLINE" redefined
In file included from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main/php_regex.h:39,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main/php.h:74,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/php_functions.c:21:
/usr/include/regex.h:271:1: warning: this is the location of the previous definition
In file included from /usr/include/apache2/httpd.h:86,
from /usr/include/apache2/util_filter.h:61,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/php_functions.c:32:
/usr/include/apache2/pcreposix.h:28:1: warning: "REG_NOTBOL" redefined
In file included from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main/php_regex.h:39,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main/php.h:74,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/php_functions.c:21:
/usr/include/regex.h:285:1: warning: this is the location of the previous definition
In file included from /usr/include/apache2/httpd.h:86,
from /usr/include/apache2/util_filter.h:61,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/php_functions.c:32:
/usr/include/apache2/pcreposix.h:29:1: warning: "REG_NOTEOL" redefined
In file included from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main/php_regex.h:39,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main/php.h:74,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/php_functions.c:21:
/usr/include/regex.h:288:1: warning: this is the location of the previous definition
In file included from /usr/include/apache2/httpd.h:86,
from /usr/include/apache2/util_filter.h:61,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/php_functions.c:32:
/usr/include/apache2/pcreposix.h:34:1: warning: "REG_EXTENDED" redefined
In file included from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main/php_regex.h:39,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main/php.h:74,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/php_functions.c:21:
/usr/include/regex.h:262:1: warning: this is the location of the previous definition
In file included from /usr/include/apache2/httpd.h:86,
from /usr/include/apache2/util_filter.h:61,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/php_functions.c:32:
/usr/include/apache2/pcreposix.h:35:1: warning: "REG_NOSUB" redefined
In file included from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main/php_regex.h:39,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/main/php.h:74,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/php_functions.c:21:
/usr/include/regex.h:275:1: warning: this is the location of the previous definition
In file included from /usr/include/apache2/httpd.h:86,
from /usr/include/apache2/util_filter.h:61,
from /var/tmp/portage/mod_php-4.3.2-r3/work/php-4.3.2/sapi/apache2handler/php_functions.c:32:
/usr/include/apache2/pcreposix.h:41: conflicting types for `REG_BADBR'
/usr/include/regex.h:312: previous declaration of `REG_BADBR'
/usr/include/apache2/pcreposix.h:42: conflicting types for `REG_BADPAT'
/usr/include/regex.h:304: previous declaration of `REG_BADPAT'
/usr/include/apache2/pcreposix.h:43: conflicting types for `REG_BADRPT'
/usr/include/regex.h:315: previous declaration of `REG_BADRPT'
/usr/include/apache2/pcreposix.h:44: conflicting types for `REG_EBRACE'
/usr/include/regex.h:311: previous declaration of `REG_EBRACE'
/usr/include/apache2/pcreposix.h:45: conflicting types for `REG_EBRACK'
/usr/include/regex.h:309: previous declaration of `REG_EBRACK'
/usr/include/apache2/pcreposix.h:46: conflicting types for `REG_ECOLLATE'
/usr/include/regex.h:305: previous declaration of `REG_ECOLLATE'
/usr/include/apache2/pcreposix.h:47: conflicting types for `REG_ECTYPE'
/usr/include/regex.h:306: previous declaration of `REG_ECTYPE'
/usr/include/apache2/pcreposix.h:48: conflicting types for `REG_EESCAPE'
/usr/include/regex.h:307: previous declaration of `REG_EESCAPE'
/usr/include/apache2/pcreposix.h:50: conflicting types for `REG_EPAREN'
/usr/include/regex.h:310: previous declaration of `REG_EPAREN'
/usr/include/apache2/pcreposix.h:51: conflicting types for `REG_ERANGE'
/usr/include/regex.h:313: previous declaration of `REG_ERANGE'
/usr/include/apache2/pcreposix.h:52: conflicting types for `REG_ESIZE'
/usr/include/regex.h:319: previous declaration of `REG_ESIZE'
/usr/include/apache2/pcreposix.h:53: conflicting types for `REG_ESPACE'
/usr/include/regex.h:314: previous declaration of `REG_ESPACE'
/usr/include/apache2/pcreposix.h:54: conflicting types for `REG_ESUBREG'
/usr/include/regex.h:308: previous declaration of `REG_ESUBREG'
/usr/include/apache2/pcreposix.h:57: conflicting types for `REG_NOMATCH'
/usr/include/regex.h:300: previous declaration of `REG_NOMATCH'
/usr/include/apache2/pcreposix.h:66: conflicting types for `regex_t'
/usr/include/regex.h:401: previous declaration of `regex_t'
/usr/include/apache2/pcreposix.h:70: warning: redefinition of `regoff_t'
/usr/include/regex.h:404: warning: `regoff_t' previously declared here
/usr/include/apache2/pcreposix.h:75: conflicting types for `regmatch_t'
/usr/include/regex.h:432: previous declaration of `regmatch_t'
/usr/include/apache2/pcreposix.h:79: conflicting types for `regcomp'
/usr/include/regex.h:547: previous declaration of `regcomp'
/usr/include/apache2/pcreposix.h:80: conflicting types for `regexec'
/usr/include/regex.h:551: previous declaration of `regexec'
/usr/include/apache2/pcreposix.h:81: conflicting types for `regerror'
/usr/include/regex.h:556: previous declaration of `regerror'
/usr/include/apache2/pcreposix.h:82: conflicting types for `regfree'
/usr/include/regex.h:559: previous declaration of `regfree'
distcc[2678] ERROR: compile on localhost failed with exit code 1
make: *** [sapi/apache2handler/php_functions.lo] Error 1
!!! ERROR: dev-php/mod_php-4.3.2-r3 failed.
!!! Function php_src_compile, Line 383, Exitcode 2
!!! compile problem
=====================
any suggestion on how i can go about this? |
|
Back to top |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|