From 430140cca18b88f464618612162a8ed094f3b2ee Mon Sep 17 00:00:00 2001 From: Andrea Date: Wed, 19 Aug 2020 12:54:45 +0200 Subject: [PATCH] Update deploy_master.sh and linux.sh --- travis/deploy_master.sh | 12 ++++++++---- travis/linux.sh | 4 ++-- 2 files changed, 10 insertions(+), 6 deletions(-) diff --git a/travis/deploy_master.sh b/travis/deploy_master.sh index 75a2aaf..700f2de 100644 --- a/travis/deploy_master.sh +++ b/travis/deploy_master.sh @@ -91,7 +91,9 @@ if ! (git diff --exit-code "src/main/resources/libs/$TRAVIS_OS_NAME_SHORT/$TRAVI # Upgrade the dependency of tdlight-java cd $TRAVIS_BUILD_DIR git clone --depth=1 -b master --single-branch git@ssh.git.ignuranza.net:tdlight-team/tdlight-java.git || true - cd tdlight-java + cd $TRAVIS_BUILD_DIR/tdlight-java + git checkout master + git pull mvn versions:use-latest-releases -Dincludes=it.tdlight:tdlight-natives-$TRAVIS_OS_NAME_STANDARD-$TRAVIS_CPU_ARCH_STANDARD rm pom.xml.versionsBackup git add pom.xml @@ -114,13 +116,15 @@ if [ "$TRAVIS_OS_NAME_STANDARD" = "linux" ]; then # Upgrade the file of tdlight-java cd $TRAVIS_BUILD_DIR git clone --depth=1 -b master --single-branch git@ssh.git.ignuranza.net:tdlight-team/tdlight-java.git || true - cd tdlight-java - git pull - cp $JAVA_SRC_DIR/it/tdlight/tdnatives/TdApi.java src/main/java/it/tdlight/tdnatives/TdApi.java + cd $TRAVIS_BUILD_DIR/tdlight-java + git checkout master + git pull + cp $JAVA_SRC_DIR/it/tdlight/tdnatives/TdApi.java $TRAVIS_BUILD_DIR/tdlight-java/src/main/java/it/tdlight/tdnatives/TdApi.java # IF TdApi.java IS CHANGED if ! (git diff --exit-code "$JAVA_SRC_DIR/it/tdlight/tdnatives/TdApi.java"); then # Upgrade TdApi.java in repository master + cd $TRAVIS_BUILD_DIR/tdlight-java git add src/main/java/it/tdlight/tdnatives/TdApi.java git commit -m "Upgraded TdApi.java" git push diff --git a/travis/linux.sh b/travis/linux.sh index 3d19198..becee45 100644 --- a/travis/linux.sh +++ b/travis/linux.sh @@ -38,12 +38,12 @@ echo "JAVA_INCLUDE_PATH=${JAVA_INCLUDE_PATH}" # ====== Build Td cd $TD_BUILD_DIR cmake -DCMAKE_BUILD_TYPE=Release -DTD_ENABLE_JNI=ON -DCMAKE_INSTALL_PREFIX:PATH=${TD_BIN_DIR} ${TD_SRC_DIR} -cmake --build $TD_BUILD_DIR --target install -- -j2 +cmake --build $TD_BUILD_DIR --target install # ====== Build TdNatives cd $TDNATIVES_CPP_BUILD_DIR cmake -DCMAKE_BUILD_TYPE=Release -DTD_BIN_DIR=${TD_BIN_DIR} -DTDNATIVES_BIN_DIR=${TDNATIVES_BIN_DIR} -DTDNATIVES_DOCS_BIN_DIR=${TDNATIVES_DOCS_BIN_DIR} -DTd_DIR=${TD_BIN_DIR}/lib/cmake/Td -DJAVA_SRC_DIR=${JAVA_SRC_DIR} -DTDNATIVES_CPP_SRC_DIR:PATH=$TDNATIVES_CPP_SRC_DIR $TDNATIVES_CPP_SRC_DIR -cmake --build $TDNATIVES_CPP_BUILD_DIR --target install -- -j2 +cmake --build $TDNATIVES_CPP_BUILD_DIR --target install mv $TDNATIVES_BIN_DIR/libtdjni.so $TRAVIS_BUILD_DIR/out/libtdjni.so mv $TDNATIVES_DOCS_BIN_DIR $TRAVIS_BUILD_DIR/out/docs