New build system (BETA)

I have tryed this script with next options:

default_php=5
php4_cli=yes
php4_cgi=no
php5_cli=no
php5_cgi=yes
apache_ver=2.2
dovecot=yes


But phpinfo() on users page still show php4 not 5 :/ And also imap is also broken :/

I have FreeBSD 6.2 and latest DA.

What should I do ?

Regards
 
It has nothing to do with IMAP. It shows php4, because default_php is only for php*_cgi, if you want both PHPs and php5 as default use:
Code:
default_php=5
php4_cli=no
php4_cgi=yes
php5_cli=no
php5_cgi=yes
apache_ver=2.2
dovecot=yes

or:
Code:
default_php=5
php4_cli=no
php4_cgi=yes
php5_cli=yes
php5_cgi=no
apache_ver=2.2
dovecot=yes
 
Now I get:

-lz -ljpeg -lcurl -lz -lm -lcurl -lssl -lcrypto -lz -lcrypt -lcrypt -o sapi/cgi/php
main/network.o(.text+0xc10): In function `php_stream_sock_ssl_activate_with_method':
/usr/local/directadmin/custombuild/php-4.4.6/main/network.c:744: undefined reference to `php_SSL_new_from_context'
main/network.o(.text+0xc74):/usr/local/directadmin/custombuild/php-4.4.6/main/network.c:778: undefined reference to `php_openssl_apply_verification_policy'
*** Error code 1

Im buidling it again so we will see what will happen now :/
 
Code:
default_php=5
php4_cli=yes
php4_cgi=no
php5_cli=no
php5_cgi=yes
apache_ver=2.2
dovecot=yes

I've just added one more feature to it and released a new version of custombuild, it will be uploaded soon. From now you can use default_php both for CGI and CLI versions of PHP.

P.S. it should be in "Feature requests" and not here (http://www.directadmin.com/forum/showthread.php?t=18280)
 
okay, just done rebuilding from scratch and here are the results:

* ips.conf gets generated
* ditto for directadmin-vhosts.conf
(nice, since i always delete /etc/httpd before rebuilding)

so those finally work :)

options.conf:
Code:
default_php=4
php4_cli=yes
php4_cgi=no
php5_cli=no
php5_cgi=yes
apache_ver=2.2
dovecot=no

the /etc/init.d/httpd file fails to kill apache, so i always need to killall httpd instead. Maybe that to can be fixed.

Furthermore, it doesnt parse php. Im still missing php stuff like addhandler etc.
 
Now I get:

-lz -ljpeg -lcurl -lz -lm -lcurl -lssl -lcrypto -lz -lcrypt -lcrypt -o sapi/cgi/php
main/network.o(.text+0xc10): In function `php_stream_sock_ssl_activate_with_method':
/usr/local/directadmin/custombuild/php-4.4.6/main/network.c:744: undefined reference to `php_SSL_new_from_context'
main/network.o(.text+0xc74):/usr/local/directadmin/custombuild/php-4.4.6/main/network.c:778: undefined reference to `php_openssl_apply_verification_policy'
*** Error code 1

Im buidling it again so we will see what will happen now :/


Anybody have any suggestion ? :/
 
This is actually fixed in PHP 5, but won't fix in PHP 4. If openssl support is built into php everything goes fine.
 
What's in your /etc/httpd/conf/extra/httpd-php-handlers.conf ?
well, actually i was hoping to find such a file but its not there ;)

great addition to the /extra folder though :)

edit:
Code:
mrhat:/usr/local/directadmin/custombuild/configure/ap2/conf/extra# ls -l
total 68
-rwxr-xr-x  1 root root     2 Apr  6 21:45 directadmin-vhosts.conf
-rwxr-xr-x  1 root root   334 Apr  6 21:45 httpd-alias.conf
-rwxr-xr-x  1 root root  2825 Apr  6 21:45 httpd-autoindex.conf
-rwxr-xr-x  1 root root  1649 Apr  6 21:45 httpd-dav.conf
-rwxr-xr-x  1 root root  2344 Apr  6 21:45 httpd-default.conf
-rwxr-xr-x  1 root root  1214 Apr 12 21:32 httpd-deflate.conf
-rwxr-xr-x  1 root root  1103 Apr  6 21:45 httpd-info.conf
-rwxr-xr-x  1 root root  5040 Apr  6 21:45 httpd-languages.conf
-rwxr-xr-x  1 root root   696 Apr  9 20:58 httpd-manual.conf
-rwxr-xr-x  1 root root  3534 Apr  6 21:45 httpd-mpm.conf
-rwxr-xr-x  1 root root  2156 Apr  6 21:45 httpd-multilang-errordoc.conf
-rwxr-xr-x  1 root root 10111 Apr  9 20:54 httpd-ssl.conf
-rwxr-xr-x  1 root root   812 Apr  6 21:45 httpd-userdir.conf
-rwxr-xr-x  1 root root  1670 Apr  6 21:45 httpd-vhosts.conf

edit2
its missing here to:
Code:
http://files.directadmin.com/services/customapache/beta/custombuild/configure/ap2/conf/extra/
or is it generated on the fly ?

edit3:
doesn't look like it, since there is no mentioning of *php-handlers* in the whole custombuild/ folder..

edit4:
hmm, just did a ./build update and this is what i got:
Code:
mrhat:/usr/local/directadmin/custombuild# ls -l build
-rwxr-xr-x  1 root root 91005 Apr 15 21:00 build
mrhat:/usr/local/directadmin/custombuild# ./build
./build: line 1: autoconf: command not found
./build: line 331: [: -ge: unary operator expected
./build: line 3254: syntax error near unexpected token `;'
./build: line 3254: `           if [ "${PHPOPT}" = "1" ] && [ "${DEFPHP}" != "5" ]; then; then'

edit5:
BTW, why dont you just drop the options.conf file and let everything be done with ./build ?

eg.

./build all d
stands for apache2+php5+proftpd

./build ap2 php4-cgi php5-cli dovecot proftpd
stands apache2 with php4/5, dovecot and proftpd

./build ap2 php4-cli proftpd
you got the point ;)

also, is Zend compiled-in by default ?
 
Last edited:
Build error

Hi guys,

I get the following error:

Code:
[root@nobim01 custombuild]# ./build
./build: line 332: doAutoconf: command not found
./build: line 3254: syntax error near unexpected token `;'
./build: line 3254: `           if [ "${PHPOPT}" = "1" ] && [ "${DEFPHP}" != "5" ]; then; then'
[root@nobim01 custombuild]#

autoconf version autoconf-2.59-5 is installed by the way.

Any ideas???
 
edit5:
BTW, why dont you just drop the options.conf file and let everything be done with ./build ?

also, is Zend compiled-in by default ?

No, Zend isn't compiled by default. We don't drop options.conf because it's easier to use the custombuild script with it, you don't need to set options again and you don't need to remember commands like php_ap2, update_data_ap2 etc., it's just php, update_data now.
 
Version 0.1.8 has been released.

Use this to update:
Code:
cd /usr/local/directadmin
rm -rf custombuild.old
mv custombuild custombuild.old
wget http://files.directadmin.com/services/custombuild/beta/custombuild.tar.gz
tar xvzf custombuild.tar.gz
cd custombuild
./build update_data
 
okay, first "bugs":
Code:
mrhat:/usr/local/directadmin/custombuild# ./build update_data
./build: line 1: autoconf: command not found
./build: line 330: [: -ge: unary operator expected
File already exists:    httpd-2.2.4.tar.gz
File already exists:    httpd_2
File already exists:    httpd_2_freebsd
File already exists:    httpd_2_debian
File already exists:    mime.types
File already exists:    mod_perl-2.0.3.tar.gz
File already exists:    curl-7.16.2.tar.gz
File already exists:    gd-2.0.34.tar.gz
File already exists:    libmcrypt-2.5.7.tar.gz
File already exists:    mhash-0.9.1.tar.gz
File already exists:    zziplib-0.10.82.tar.gz
File already exists:    php-4.4.6.tar.gz
File already exists:    php-5.2.1.tar.gz
File already exists:    webalizer-2.01-10-src.tgz
File already exists:    proftpd-1.3.1rc2.tar.gz
File already exists:    suphp-0.6.2.tar.gz
./build: line 2479: [: -ge: unary operator expected
mrhat:/usr/local/directadmin/custombuild#
 
The followin file is now missing:

Include conf/extra/httpd-php-handlers.conf

So php is totaly broken!

####EDITED####

The httpd-php-handlers.conf now looks like this for me and is working for as far as I can tell.
Code:
# PHP Configuration for Apache
#
# Load the apache module
#
LoadModule php5_module modules/libphp5.so
#
# Cause the PHP interpreter handle files with a .php extension.
#
AddType application/x-httpd-php .php
AddType application/x-httpd-php-source .phps
#
# Add index.php to the list of files that will be served as directory
# indexes.
#
DirectoryIndex index.php
 
Last edited:
I have just tested about 20 mins ago and I have got an autoconf error. I have FreeBSD and I already have autoconf 259.

regards
 
Im using the old version and now I get next:

bash-2.05b# Syntax error on line 23 of /usr/local/directadmin/data/users/nean/httpd.conf:
User cannot occur within <VirtualHost> section


And also a errors for apache conf files in users directory. Like Port is changed with Listen etc...

Is this script working on freebsd or not ?

Regards
 
Back
Top