1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42
|
#!/bin/sh
# File to get the version from
FILE_VERSION=../src/version.h
# Generated binary
BINARY=../build.win32/bin/kchmviewer.exe
# Qt libs
QTPATH=/home/tim/bin/qt-4.4.0
QTLIBS=$QTPATH/dll
# Start the mojo
ln -s $BINARY kchmviewer.exe
ln -s $QTLIBS/QtGui4.dll QtGui4.dll
ln -s $QTLIBS/QtCore4.dll QtCore4.dll
ln -s $QTLIBS/QtNetwork4.dll QtNetwork4.dll
ln -s $QTLIBS/QtWebKit4.dll QtWebKit4.dll
ln -s /mnt/disk_c/Qt/MinGW/bin/mingwm10.dll mingwm10.dll
export NSISDIR=/home/tim/bin/nsis
# Get current, and save the next version
VERSION_MAJOR=`sed -n 's/^\#define\s\+APP_VERSION_MAJOR\s\+\([0-9]\+\)/\1/p' $FILE_VERSION`
VERSION_MINOR=`sed -n 's/^\#define\s\+APP_VERSION_MINOR\s\+\([0-9]\+\)/\1/p' $FILE_VERSION`
VERSION="$VERSION_MAJOR.$VERSION_MINOR"
INSTNAME="InstallKchmviewer-$VERSION.exe"
echo "Creating $INSTNAME"
makensis installer.nsis
# Remove unused
rm kchmviewer.exe
rm QtGui4.dll
rm QtCore4.dll
rm mingwm10.dll
rm QtNetwork4.dll
rm QtWebKit4.dll
mv InstallKchmViewer.exe $INSTNAME
|