Compiling on Debian Wheezy

#1
If you do a minimal net install of Debian Wheezy and go to compile OLS on it, you will find that it won't work.

You need to install the below (at the minimum)

Code:
aptitude install libssl-dev make automake build-essentials g++ libpcre3 libpcre3-dev libexpat1-dev libgeoip-dev libcurl4-openssl-dev libbz2-dev libjpeg8-dev libpng-dev libfreetype6-dev libmagickwand-dev
to get it and PHP to compile.

If you want imagemagick and geoip installed for php, you will need to do a
Code:
/usr/local/lsws/lsphp5/bin/pecl install imagick
/usr/local/lsws/lsphp5/bin/pecl install geoip
and then add
Code:
extension=/usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20121212/imagick.so
extension=/usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20121212/geoip.so
zend_extension=/usr/local/lsws/lsphp5/lib/php/extensions/no-debug-non-zts-20121212/opcache.so
date.timezone='US/Central'
in your php.ini file (which you will also need to copy from /usr/local/lsws/php to /usr/local/lsws/lsphp5/lib.

If you run into a problem that your site doesn't show up, you need to issue
Code:
/usr/local/lsws/fcgi-bin/lsphp5 -i
and check for any errors. What I've been having show up is
Code:
PHP Fatal error:  Directive 'allow_call_time_pass_reference' is no longer available in PHP in Unknown on line 0
, which can be resolved by commenting it out of your php.ini. Once I did that my sites came up running fine.
 
Last edited:

Tracy Perry

Active Member
#3
On the required list, replace build-essentials with build-essential (drop the s). I would have edited the original post but cannot due to time expiration.
Also need to add libmcrypt-dev to the build essentials apt-get list.
@Slavik, if you could edit the original post this one can be deleted.
 
Last edited:
#4
OpenLiteSpeed 1.2.9 will compile on Ubuntu 14.04 with the same process as Debian, but you WILL need to do some slight mods.

Even though Ubuntu uses base Debian code, I found that OpenLiteSpeed would NOT compile on it. Even with the correct libraries installed (which the Debian listed are correct) I ended up getting
Code:
collect2: error: ld returned 1 exit status
make[3]: *** [openlitespeed] Error 1
make[3]: Leaving directory `/home/tracy/work/openlitespeed-1.2.9/src'
make[2]: *** [all-recursive] Error 1
make[2]: Leaving directory `/home/tracy/work/openlitespeed-1.2.9/src'
make[1]: *** [all] Error 2
make[1]: Leaving directory `/home/tracy/work/openlitespeed-1.2.9/src'
make: *** [all-recursive] Error 1

This was solved by going into the (for version 1.2.9) /openlitespeed-1.2.9/src directory and editing the Makefile and finding
Code:
EXPAT_LDFLAGS =
If you notice, there is nothing designated for that.... and therein lay the problem. You will need to modify the Makefile (and be SURE it's the one in the /src directory) to
Code:
EXPAT_LDFLAGS = -lexpat
Once you do that you can do the standard Debian install routine of
  • sudo ./configure --with-group=nogroup
  • sudo make && sudo make install
 
Top