Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit ef91a3d

Browse files
committed
Added Wkhtml x64/x32
Added Wkhtml x64/x32
1 parent c524114 commit ef91a3d

File tree

1 file changed

+11
-5
lines changed

1 file changed

+11
-5
lines changed

V9/odoo_install.sh

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -76,11 +76,17 @@ sudo apt-get install python-gevent
7676
# Install Wkhtmltopdf if needed
7777
#--------------------------------------------------
7878
if [ $INSTALL_WKHTMLTOPDF = "True" ]; then
79-
echo -e "\n---- Install wkhtml and place on correct place for ODOO 8 ----"
80-
sudo wget http://download.gna.org/wkhtmltopdf/0.12/0.12.1/wkhtmltox-0.12.1_linux-trusty-amd64.deb
81-
sudo dpkg -i wkhtmltox-0.12.1_linux-trusty-amd64.deb
82-
sudo cp /usr/local/bin/wkhtmltopdf /usr/bin
83-
sudo cp /usr/local/bin/wkhtmltoimage /usr/bin
79+
echo -e "\n---- Install wkhtml and place shortcuts on correct place for ODOO 9 ----"
80+
#pick up correct one from x64 & x32 versions:
81+
if [ "`getconf LONG_BIT`" == "64" ];then
82+
_url=$WKHTMLTOX_X64
83+
else
84+
_url=$WKHTMLTOX_X32
85+
fi
86+
sudo wget $_url
87+
sudo gdebi --n `basename $_url`
88+
sudo ln -s /usr/local/bin/wkhtmltopdf /usr/bin
89+
sudo ln -s /usr/local/bin/wkhtmltoimage /usr/bin
8490
else
8591
echo "Wkhtmltopdf isn't installed due to the choice of the user!"
8692
fi

0 commit comments

Comments
 (0)