Skip to content

Commit

Permalink
build script updated
Browse files Browse the repository at this point in the history
  • Loading branch information
john-preston committed Oct 1, 2015
1 parent dd113d5 commit b5e1aad
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 2 deletions.
20 changes: 20 additions & 0 deletions Telegram/Build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,17 @@ if [ "$BuildTarget" == "linux" ]; then
echo "Building version $AppVersionStrFull for Linux 64bit.."
UpdateFile="tlinuxupd$AppVersion"
SetupFile="tsetup.$AppVersionStrFull.tar.xz"
WorkPath="./../Linux"
HomePath="./../../Telegram"
FixScript="$HomePath/FixMake.sh"
ReleasePath="./../Linux/Release"
elif [ "$BuildTarget" == "linux32" ]; then
echo "Building version $AppVersionStrFull for Linux 32bit.."
UpdateFile="tlinux32upd$AppVersion"
SetupFile="tsetup32.$AppVersionStrFull.tar.xz"
WorkPath="./../Linux"
HomePath="./../../Telegram"
FixScript="$HomePath/FixMake32.sh"
ReleasePath="./../Linux/Release"
elif [ "$BuildTarget" == "mac" ]; then
echo "Building version $AppVersionStrFull for OS X 10.8+.."
Expand Down Expand Up @@ -75,6 +81,20 @@ fi
#fi

if [ "$BuildTarget" == "linux" ] || [ "$BuildTarget" == "linux32" ]; then
mkdir -p "$WorkPath/ReleaseIntermediateUpdater"
cd "$WorkPath/ReleaseIntermediateUpdater"
/usr/local/Qt-5.5.0/bin/qmake "$HomePath/Updater.pro"
make
echo "Updater build complete!"
cd "$HomePath"

mkdir -p "$WorkPath/ReleaseIntermediate"
cd "$WorkPath/ReleaseIntermediate"
/usr/local/Qt-5.5.0/bin/qmake "$HomePath/Telegram.pro"
eval "$FixScript"
make
echo "Telegram build complete!"
cd "$HomePath"
if [ ! -f "$ReleasePath/Telegram" ]; then
echo "Telegram not found!"
exit 1
Expand Down
2 changes: 0 additions & 2 deletions Telegram/Telegram.pro
Original file line number Diff line number Diff line change
Expand Up @@ -73,10 +73,8 @@ unix {
linux-g++-64:QMAKE_TARGET.arch = x86_64

contains(QMAKE_TARGET.arch, x86_64) {
CONFIG(release,debug|release):QMAKE_PRE_LINK = ./../../Telegram/FixMake.sh
DEFINES += Q_OS_LINUX64
} else {
CONFIG(release,debug|release):QMAKE_PRE_LINK = ./../../Telegram/FixMake32.sh
DEFINES += Q_OS_LINUX32
}
}
Expand Down

0 comments on commit b5e1aad

Please sign in to comment.