add build scripts for Linux/Win
This commit is contained in:
39
linux-static-build.sh
Executable file
39
linux-static-build.sh
Executable file
@@ -0,0 +1,39 @@
|
||||
#!/bin/bash
|
||||
# Copyright 2019 The Hush Developers
|
||||
|
||||
UNAME=$(uname)
|
||||
|
||||
if [ "$UNAME" == "Linux" ] ; then
|
||||
JOBS=$(nproc)
|
||||
elif [ "$UNAME" == "FreeBSD" ] ; then
|
||||
JOBS=$(nproc)
|
||||
elif [ "$UNAME" == "Darwin" ] ; then
|
||||
JOBS=$(sysctl -n hw.ncpu)
|
||||
else
|
||||
JOBS=1
|
||||
fi
|
||||
|
||||
|
||||
VERSION=$(cat src/version.h |cut -d\" -f2)
|
||||
echo "Compiling SilentDragonLite $VERSION with $JOBS threads..."
|
||||
CONF=silentdragon-lite.pro
|
||||
|
||||
set -e
|
||||
qbuild () {
|
||||
/home/$USER/Qt/5.11.2/static/bin/qmake $CONF CONFIG+=debug
|
||||
#lupdate $CONF
|
||||
#lrelease $CONF
|
||||
make -j$JOBS
|
||||
}
|
||||
|
||||
if [ "$1" == "clean" ]; then
|
||||
make clean
|
||||
elif [ "$1" == "linguist" ]; then
|
||||
lupdate $CONF
|
||||
lrelease $CONF
|
||||
elif [ "$1" == "cleanbuild" ]; then
|
||||
make clean
|
||||
qbuild
|
||||
else
|
||||
qbuild
|
||||
fi
|
||||
Reference in New Issue
Block a user