xref: /glogg/release-win32-x.sh (revision 21a1b6dca17b27fc159f6642d5f1709e2b02f301)
13597d419SNicolas Bonnefon#!/bin/bash
23597d419SNicolas Bonnefon
33597d419SNicolas Bonnefon# Build glogg for win32 using the cross-compiler
43597d419SNicolas Bonnefon
53597d419SNicolas BonnefonQTXDIR=$HOME/qt-x-win32
63597d419SNicolas Bonnefon
73597d419SNicolas Bonnefonmake clean
83597d419SNicolas Bonnefonif [ -z "$VERSION" ]; then
9*21a1b6dcSNicolas Bonnefon    echo "Building default version"
103597d419SNicolas Bonnefon    qmake glogg.pro -spec win32-x-g++ -r CONFIG+="release win32"
11*21a1b6dcSNicolas Bonnefonelse
12*21a1b6dcSNicolas Bonnefon    echo "Building version $VERSION"
13*21a1b6dcSNicolas Bonnefon    qmake glogg.pro -spec win32-x-g++ -r CONFIG+="release win32" VERSION="$VERSION"
143597d419SNicolas Bonnefonfi
153597d419SNicolas Bonnefonmake -j3
163597d419SNicolas Bonnefoncp $QTXDIR/qt_win/2010.02.1/qt/bin/{QtCore4,QtGui4}.dll release/
173597d419SNicolas Bonnefoncp $QTXDIR/qt_win/2010.02.1/mingw/bin/libgcc_s_dw2-1.dll release/
183597d419SNicolas Bonnefongunzip -c /usr/share/doc/mingw32-runtime/mingwm10.dll.gz >release/mingwm10.dll
193597d419SNicolas Bonnefonif [ -z "$VERSION" ]; then
203597d419SNicolas Bonnefon    VERSION=`git describe`;
213597d419SNicolas Bonnefonfi
223597d419SNicolas Bonnefonecho Generating installer for glogg-$VERSION
233597d419SNicolas Bonnefonwine $QTXDIR/NSIS/makensis -DVERSION=$VERSION glogg.nsi
24