wok-6.x rev 22737
updated dolibarr (9.0.0 -> 10.0.6)
author | Hans-G?nter Theisgen |
---|---|
date | Fri Jan 24 07:09:03 2020 +0100 (2020-01-24) |
parents | f26b964dc2aa |
children | bcedcc3b79db |
files | dolibarr/receipt |
line diff
1.1 --- a/dolibarr/receipt Thu Jan 23 17:36:26 2020 +0100 1.2 +++ b/dolibarr/receipt Fri Jan 24 07:09:03 2020 +0100 1.3 @@ -1,9 +1,9 @@ 1.4 # SliTaz package receipt. 1.5 1.6 PACKAGE="dolibarr" 1.7 -VERSION="9.0.0" 1.8 +VERSION="10.0.6" 1.9 CATEGORY="office" 1.10 -SHORT_DESC="ERP/CRM for small and medium companies" 1.11 +SHORT_DESC="ERP/CRM for small and medium companies." 1.12 MAINTAINER="erjo@slitaz.org" 1.13 LICENSE="GPLv3" 1.14 WEB_SITE="https://www.dolibarr.org/" 1.15 @@ -17,7 +17,7 @@ 1.16 # Rules to configure and make the package. 1.17 compile_rules() 1.18 { 1.19 - # Fix attributes and perms 1.20 + # Fix attributes and permissions 1.21 chown -R root.root * 1.22 chmod -x C* I* R* 1.23 find . \( -name "*.php" \ 1.24 @@ -32,47 +32,46 @@ 1.25 # Rules to gen a SliTaz package suitable for Tazpkg. 1.26 genpkg_rules() 1.27 { 1.28 - 1.29 - mkdir -p $fs/etc/dolibarr \ 1.30 - $fs/usr/share/dolibarr \ 1.31 - $fs/var/lib/dolibarr/documents \ 1.32 - $fs/usr/share/doc/$PACKAGE/schemas \ 1.33 - $fs/usr/share/applications 1.34 - 1.35 - 1.36 - cp -a $src/htdocs $fs/usr/share/dolibarr 1.37 - cp -a $src/scripts $fs/usr/share/dolibarr 1.38 - 1.39 + mkdir -p $fs/etc/dolibarr 1.40 + mkdir -p $fs/usr/share/dolibarr 1.41 + mkdir -p $fs/var/lib/dolibarr/documents 1.42 + mkdir -p $fs/usr/share/doc/$PACKAGE/schemas 1.43 + mkdir -p $fs/usr/share/applications 1.44 + 1.45 + cp -a $src/htdocs $fs/usr/share/dolibarr 1.46 + cp -a $src/scripts $fs/usr/share/dolibarr 1.47 + 1.48 # Remove install directory 1.49 #rm -rf $fs/usr/share/dolibarr/htdocs/install 1.50 - 1.51 + 1.52 # Populate documents directory 1.53 for dir in facture users propale mycompany ficheinter produit rapport 1.54 - do 1.55 + do 1.56 mkdir $fs/var/lib/dolibarr/documents/$dir 1.57 - done 1.58 - 1.59 - # Fix perms 1.60 - chown -R root.www $fs/var/lib/dolibarr/documents 1.61 - chmod -R 770 $fs/var/lib/dolibarr/documents 1.62 - 1.63 - cp $stuff/conf.php $fs/etc/dolibarr 1.64 - cp $stuff/$PACKAGE-$VERSION-mysql.sql $fs/usr/share/doc/$PACKAGE/schemas 1.65 - cp -a $stuff/pixmaps $fs/usr/share/ 1.66 - 1.67 + done 1.68 + 1.69 + # Fix permissions 1.70 + chown -R root.www $fs/var/lib/dolibarr/documents 1.71 + chmod -R 770 $fs/var/lib/dolibarr/documents 1.72 + 1.73 + cp $stuff/conf.php $fs/etc/dolibarr 1.74 + cp $stuff/$PACKAGE-$VERSION-mysql.sql \ 1.75 + $fs/usr/share/doc/$PACKAGE/schemas 1.76 + cp -a $stuff/pixmaps $fs/usr/share/ 1.77 + 1.78 ln -s /etc/dolibarr/conf.php $fs/usr/share/dolibarr/htdocs/conf 1.79 - 1.80 } 1.81 1.82 post_install(){ 1.83 - 1.84 db_name=dolibarr 1.85 db_user=dolibarr 1.86 db_password=dolibarr 1.87 1.88 # Configure apache server 1.89 - if [ -f "$1/etc/apache/httpd.conf" ]; then 1.90 - if [ ! -f "$1/etc/apache/conf.d/dolibarr.conf" ]; then 1.91 + if [ -f "$1/etc/apache/httpd.conf" ] 1.92 + then 1.93 + if [ ! -f "$1/etc/apache/conf.d/dolibarr.conf" ] 1.94 + then 1.95 cat > "$1/etc/apache/conf.d/dolibarr.conf" <<EOT 1.96 <IfModule mod_alias.c> 1.97 Alias /dolibarr /usr/share/dolibarr/htdocs 1.98 @@ -85,34 +84,41 @@ 1.99 </Directory> 1.100 1.101 EOT 1.102 - if [ -z "$1" ]; then 1.103 + if [ -z "$1" ] 1.104 + then 1.105 # Start Web server. 1.106 - test -f /var/run/apache/httpd.pid && \ 1.107 - ( kill -0 $(cat /var/run/apache/httpd.pid) && /etc/init.d/apache restart ) 1.108 + test -f /var/run/apache/httpd.pid && 1.109 + ( kill -0 $(cat /var/run/apache/httpd.pid) && /etc/init.d/apache restart ) 1.110 fi 1.111 fi 1.112 fi 1.113 1.114 - # Configure every thing. 1.115 - if [ -z "$1" ]; then 1.116 - if ( ! mysqladmin -s ping > /dev/null ); then 1.117 + # Configure everything. 1.118 + if [ -z "$1" ] 1.119 + then 1.120 + if ( ! mysqladmin -s ping > /dev/null ) 1.121 + then 1.122 echo "Starting MySQL server" 1.123 ( /etc/init.d/mysql start ; status ) || exit 1.124 sleep 4 #let the mysql daemon start 1.125 fi 1.126 - if ( ! mysql -u root -Be 'show databases' | grep -q $db_name ); then 1.127 + if ( ! mysql -u root -Be 'show databases' | grep -q $db_name ) 1.128 + then 1.129 echo -n "Create $db_name database" 1.130 - mysql -Be "create database $db_name" ; status 1.131 + mysql -Be "create database $db_name" 1.132 + status 1.133 + 1.134 # We suppose that databse user does not exist. 1.135 # It may be false. 1.136 echo -n "Create user $db_user with password $db_password" 1.137 mysql -Be "grant all privileges on ${db_name}.* to '$db_user'@'localhost' 1.138 - identified by '$db_password'" ; status 1.139 + identified by '$db_password'" 1.140 + status 1.141 + 1.142 # At last populate the database. 1.143 echo -n "Create $db_name database schema." 1.144 - mysql -u $db_user -p${db_password} -D $db_name < /usr/share/doc/dolibarr/schemas/$PACKAGE-$VERSION-mysql.sql ; status 1.145 - 1.146 + mysql -u $db_user -p${db_password} -D $db_name < /usr/share/doc/dolibarr/schemas/$PACKAGE-$VERSION-mysql.sql 1.147 + status 1.148 fi 1.149 - 1.150 fi 1.151 }