This is for iliaal’s php_excel extension – https://github.com/iliaal/php_excel
I found that the installation procedure is a bit different from the official installation method
(There are no ./buildconf
file)
Just a quick note for future deployment
1. Install tools, php*-dev for the phpize
tool
apt-get install php7.2-dev libxml2-dev git
2. Install LibXL library
wget http://www.libxl.com/download/libxl-lin-3.8.5.tar.gz tar -zxv -f libxl-lin-3.8.5.tar.gz cd libxl-3.8.5.0/ cp lib64/libxl.so /usr/lib/libxl.so mkdir -p /usr/include/libxl_c/ cp include_c/* /usr/include/libxl_c/
(Change lib64 to lib if 32 bit)
3. Compile and install php_excel (LibXL PHP extension)
git clone https://github.com/Jan-E/php_excel.git -b php7-issue241 cd php_excel phpize ./configure --with-php-config=/usr/bin/php-config --with-libxl-incdir=/usr/include/libxl_c/ --with-libxml-dir=/usr/include/libxml2/ --with-excel make make install
4. Create PHP extension config and enable it
vim /etc/php/7.2/mods-available/excel.ini
with content
; configuration for php excel module ; priority=30 extension=excel.so [excel] excel.license_name="Tiger Fok" excel.license_key="linux-xxxxxxxxxxxxxxxxxxxxx" excel.skip_empty=0
5. Enable the PHP config
phpenmod excel
6. Restart Apache / php-fpm
phpinfo() should now should show excel extension
1. Install tools, php*-dev for the phpize
tool
apt-get install php7.0-dev libxml2-dev git
2. Install LibXL library
wget http://www.libxl.com/download/libxl-lin-3.7.2.tar.gz tar -zxv -f libxl-lin-3.7.2.tar.gz cd libxl-3.7.2.0/ cp lib64/libxl.so /usr/lib/libxl.so mkdir -p /usr/include/libxl_c/ cp include_c/* /usr/include/libxl_c/
(Change lib64 to lib if 32 bit)
3. Compile and install php_excel (LibXL PHP extension)
git clone https://github.com/iliaal/php_excel.git -b php7 cd php_excel phpize ./configure --with-php-config=/usr/bin/php-config --with-libxl-incdir=/usr/include/libxl_c/ --with-libxml-dir=/usr/include/libxml2/ --with-excel make make install
4. Create PHP extension config and enable it
vim /etc/php/7.0/mods-available/excel.ini
with content
; configuration for php excel module ; priority=30 extension=excel.so [excel] excel.license_name="Tiger Fok" excel.license_key="linux-xxxxxxxxxxxxxxxxxxxxx" excel.skip_empty=0
5. Enable the PHP config
phpenmod excel
6. Restart Apache / php-fpm
phpinfo() should now should show excel extension
1. Install tools, php*-dev for the phpize
tool
apt-get install php5-dev libxml2-dev git
2. Install LibXL library
wget http://www.libxl.com/download/libxl-lin-3.7.2.tar.gz tar -zxv -f libxl-lin-3.7.2.tar.gz cd libxl-3.7.2.0/ cp lib64/libxl.so /usr/lib/libxl.so mkdir -p /usr/include/libxl_c/ cp include_c/* /usr/include/libxl_c/
(Change lib64 to lib if 32 bit)
3. Compile and install php_excel (LibXL PHP extension)
git clone https://github.com/iliaal/php_excel.git cd php_excel phpize ./configure --with-php-config=/usr/bin/php-config --with-libxl-incdir=/usr/include/libxl_c/ --with-libxml-dir=/usr/include/libxml2/ --with-excel make make install
4. Create PHP extension config and enable it
vim /etc/php5/mods-available/excel.ini
with content
; configuration for php excel module ; priority=30 extension=excel.so [excel] excel.license_name="Tiger Fok" excel.license_key="linux-xxxxxxxxxxxxxxxxxxxxx" excel.skip_empty=0
5. Enable the PHP config
phpenmod excel
6. Restart Apache / php-fpm
phpinfo() should now should show excel extension