merged the two script qt custom and qt standard build

preferencesAboutTextFull
Claudio Valerio 12 years ago
parent 94d518ec98
commit bfbae8a835
  1. 25
      buildDebianPackage

@ -2,7 +2,7 @@
# -------------------------------------------------------------------- # --------------------------------------------------------------------
# This program is free software: you can redistribute it and/or modify # This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by # it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or # the Free Software Foundation, either version 2 of the License, or
# (at your option) any later version. # (at your option) any later version.
# #
# This program is distributed in the hope that it will be useful, # This program is distributed in the hope that it will be useful,
@ -23,6 +23,7 @@ initializeVariables()
{ {
MAKE_TAG=true MAKE_TAG=true
CREATE_DIENA_DISTRIBUTION_ZIP=false CREATE_DIENA_DISTRIBUTION_ZIP=false
STANDARD_QT_USED=false
PRODUCT_PATH="build/linux/release/product" PRODUCT_PATH="build/linux/release/product"
QT_PATH="/usr/local/Trolltech/Qt-4.8.0" QT_PATH="/usr/local/Trolltech/Qt-4.8.0"
@ -96,13 +97,27 @@ copyQtLibrary(){
fi fi
} }
buildWithStandardQt(){
STANDARD_QT=`which qmake-qt4`
if [ $? == "0" ]; then
QT_VERSION=`$STANDARD_QT --version | grep -i "Using Qt version" | sed -e "s/Using Qt version \(.*\) in.*/\1/"`
if [ `echo $QT_VERSION | sed -e "s/\.//g"` -gt 480 ]; then
notifyProgress "Standard QT" "A recent enough qmake has been found. Using this one instead of custom one"
STANDARD_QT_USED=true
QMAKE_PATH=$STANDARD_QT
LRELEASES=`which lrelease`
QT_PATH="/usr/lib/`arch`-linux-gnu"
PLUGINS_PATH="$QT_PATH/qt4/plugins"
fi
fi
}
#********************** #**********************
# script # script
#********************** #**********************
initializeVariables initializeVariables
buildWithStandardQt
for var in "$@" for var in "$@"
do do
@ -174,6 +189,7 @@ cp -R resources/linux/qtlinux/* $PRODUCT_PATH/
notifyProgress "QT" "Coping plugins and library ..." notifyProgress "QT" "Coping plugins and library ..."
cp -R $PLUGINS_PATH $PRODUCT_PATH/ cp -R $PLUGINS_PATH $PRODUCT_PATH/
if [ $STANDARD_QT_USED == false ]; then
#copying custom qt library #copying custom qt library
mkdir -p $QT_LIBRARY_DEST_PATH mkdir -p $QT_LIBRARY_DEST_PATH
copyQtLibrary libQtDBus copyQtLibrary libQtDBus
@ -186,6 +202,7 @@ copyQtLibrary libQtGui
copyQtLibrary libQtCore copyQtLibrary libQtCore
copyQtLibrary libphonon copyQtLibrary libphonon
copyQtLibrary libQtWebKit copyQtLibrary libQtWebKit
fi
notifyProgress "QT" "Internalization" notifyProgress "QT" "Internalization"
if [ ! -e $PRODUCT_PATH/i18n ]; then if [ ! -e $PRODUCT_PATH/i18n ]; then

Loading…
Cancel
Save