build automation script. tested on macos

This commit is contained in:
Ilya Kitaev 2016-07-25 16:24:07 +03:00
parent c7c06a5893
commit 1b35a1ae4b
2 changed files with 34 additions and 2 deletions

28
build.sh Executable file
View file

@ -0,0 +1,28 @@
#!/bin/bash
pushd $(pwd)
ROOT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
#$SHELL get_libwallet_api.sh
if [ ! -d build ]; then mkdir build; fi
cd build
echo $(pwd)
qmake ../monero-core.pro "CONFIG += release"
make release
make deploy
popd

View file

@ -5,6 +5,7 @@ QT += qml quick widgets
WALLET_ROOT=$$PWD/bitmonero WALLET_ROOT=$$PWD/bitmonero
CONFIG += c++11 CONFIG += c++11
CONFIG += debug_and_release
# cleaning "auto-generated" bitmonero directory on "make distclean" # cleaning "auto-generated" bitmonero directory on "make distclean"
QMAKE_DISTCLEAN += -r $$WALLET_ROOT QMAKE_DISTCLEAN += -r $$WALLET_ROOT
@ -102,9 +103,12 @@ macx {
-lssl \ -lssl \
-lcrypto \ -lcrypto \
-ldl -ldl
deploy.commands += macdeployqt $$sprintf("%1/release/%2.app", $$OUT_PWD,$$TARGET)
} }
deploy.commands +=
# translations files; # translations files;
TRANSLATIONS = $$PWD/translations/monero-core_en.ts \ # English (could be untranslated) TRANSLATIONS = $$PWD/translations/monero-core_en.ts \ # English (could be untranslated)
@ -127,9 +131,9 @@ trans_release.depends = trans_update $$TRANSLATIONS
#translate.commands = $(MKDIR) ${DESTDIR}/i18n && $(COPY) $$PWD/translations/*.qm ${DESTDIR}/i18n #translate.commands = $(MKDIR) ${DESTDIR}/i18n && $(COPY) $$PWD/translations/*.qm ${DESTDIR}/i18n
translate.depends = trans_release translate.depends = trans_release
deploy.commands = pushd $QMAKE_
QMAKE_EXTRA_TARGETS += trans_update trans_release translate
QMAKE_EXTRA_TARGETS += trans_update trans_release translate deploy
# updating transations only in release mode as this is requires to re-link project # updating transations only in release mode as this is requires to re-link project
# even if no changes were made. # even if no changes were made.