From 287d55d27631a320be021d4eb2530381ea231f07 Mon Sep 17 00:00:00 2001 From: Stefan Profanter Date: Thu, 8 Nov 2018 14:46:20 +0100 Subject: [PATCH] CI: Pack lib binaries into zip and tar release --- tools/travis/travis_linux_script.sh | 12 +++++++----- tools/travis/travis_push_release.sh | 9 ++++++++- 2 files changed, 15 insertions(+), 6 deletions(-) diff --git a/tools/travis/travis_linux_script.sh b/tools/travis/travis_linux_script.sh index 7db7cec26a1..d6354528af2 100644 --- a/tools/travis/travis_linux_script.sh +++ b/tools/travis/travis_linux_script.sh @@ -101,7 +101,8 @@ else cmake -DCMAKE_TOOLCHAIN_FILE=../tools/cmake/Toolchain-mingw32.cmake -DUA_ENABLE_AMALGAMATION=ON -DCMAKE_BUILD_TYPE=Release -DUA_BUILD_EXAMPLES=ON -DBUILD_SHARED_LIBS=ON .. make -j if [ $? -ne 0 ] ; then exit 1 ; fi - zip -r open62541-win32.zip ../../doc_latex/open62541.pdf ../LICENSE ../AUTHORS ../README.md ./bin/examples/server_ctt.exe ./bin/examples/client.exe ./bin/libopen62541.* open62541.h open62541.c + cp ../LICENSE ../AUTHORS ../README.md . + zip -r open62541-win32.zip ../../doc_latex/open62541.pdf LICENSE AUTHORS README.md ./bin/examples/server_ctt.exe ./bin/examples/client.exe ./bin/libopen62541.* open62541.h open62541.c cp open62541-win32.zip .. cd .. && rm build -rf echo -en 'travis_fold:end:script.build.cross_mingw32\\r' @@ -111,7 +112,8 @@ else cmake -DCMAKE_TOOLCHAIN_FILE=../tools/cmake/Toolchain-mingw64.cmake -DUA_ENABLE_AMALGAMATION=ON -DCMAKE_BUILD_TYPE=Release -DUA_BUILD_EXAMPLES=ON -DBUILD_SHARED_LIBS=ON .. make -j if [ $? -ne 0 ] ; then exit 1 ; fi - zip -r open62541-win64.zip ../../doc_latex/open62541.pdf ../LICENSE ../AUTHORS ../README.md ./bin/examples/server_ctt.exe ./bin/examples/client.exe ./bin/libopen62541.* open62541.h open62541.c + cp ../LICENSE ../AUTHORS ../README.md . + zip -r open62541-win64.zip ../../doc_latex/open62541.pdf LICENSE AUTHORS README.md ./bin/examples/server_ctt.exe ./bin/examples/client.exe ./bin/libopen62541.* open62541.h open62541.c cp open62541-win64.zip .. cd .. && rm build -rf echo -en 'travis_fold:end:script.build.cross_mingw64\\r' @@ -121,7 +123,7 @@ else cmake -DCMAKE_TOOLCHAIN_FILE=../tools/cmake/Toolchain-gcc-m32.cmake -DUA_ENABLE_AMALGAMATION=ON -DCMAKE_BUILD_TYPE=Release -DUA_BUILD_EXAMPLES=ON -DBUILD_SHARED_LIBS=ON .. make -j if [ $? -ne 0 ] ; then exit 1 ; fi - tar -pczf open62541-linux32.tar.gz ../../doc_latex/open62541.pdf ../LICENSE ../AUTHORS ../README.md ./bin/examples/server_ctt ./bin/examples/client ./bin/libopen62541.* open62541.h open62541.c + tar -pczf open62541-linux32.tar.gz ../../doc_latex/open62541.pdf ../LICENSE ../AUTHORS ../README.md bin/examples/server_ctt bin/examples/client bin/libopen62541.* open62541.h open62541.c cp open62541-linux32.tar.gz .. cd .. && rm build -rf echo -en 'travis_fold:end:script.build.cross_linux\\r' @@ -133,7 +135,7 @@ else cmake -DCMAKE_TOOLCHAIN_FILE=../tools/cmake/Toolchain-rpi64.cmake -DUA_ENABLE_AMALGAMATION=ON -DCMAKE_BUILD_TYPE=Release -DUA_BUILD_EXAMPLES=ON -DBUILD_SHARED_LIBS=ON .. make -j if [ $? -ne 0 ] ; then exit 1 ; fi - tar -pczf open62541-raspberrypi.tar.gz ../../doc_latex/open62541.pdf ../LICENSE ../AUTHORS ../README.md ./bin/examples/server_ctt ./bin/examples/client ./bin/libopen62541.* open62541.h open62541.c + tar -pczf open62541-raspberrypi.tar.gz ../../doc_latex/open62541.pdf ../LICENSE ../AUTHORS ../README.md bin/examples/server_ctt bin/examples/client bin/libopen62541.* open62541.h open62541.c cp open62541-raspberrypi.tar.gz .. cd .. && rm build -rf echo -en 'travis_fold:end:script.build.cross_raspi\\r' @@ -144,7 +146,7 @@ else cmake -DPYTHON_EXECUTABLE:FILEPATH=/usr/bin/$PYTHON -DCMAKE_BUILD_TYPE=Release -DUA_ENABLE_AMALGAMATION=ON -DUA_BUILD_EXAMPLES=ON -DBUILD_SHARED_LIBS=ON .. make -j if [ $? -ne 0 ] ; then exit 1 ; fi - tar -pczf open62541-linux64.tar.gz ../../doc_latex/open62541.pdf ../LICENSE ../AUTHORS ../README.md ./bin/examples/server_ctt ./bin/examples/client ./bin/libopen62541.* open62541.h open62541.c + tar -pczf open62541-linux64.tar.gz ../../doc_latex/open62541.pdf ../LICENSE ../AUTHORS ../README.md bin/examples/server_ctt bin/examples/client bin/libopen62541.* open62541.h open62541.c cp open62541-linux64.tar.gz .. cp open62541.h ../.. # copy single file-release cp open62541.c ../.. # copy single file-release diff --git a/tools/travis/travis_push_release.sh b/tools/travis/travis_push_release.sh index a1044bb4589..e2e39203a8f 100644 --- a/tools/travis/travis_push_release.sh +++ b/tools/travis/travis_push_release.sh @@ -30,10 +30,17 @@ if [ ! -e "releases/$TAG.zip" ]; then cp ../../../open62541.c . cp ../../../open62541.h . cp ../../../doc_latex/open62541.pdf . - zip -r "$TAG.zip" open62541.c open62541.h open62541.pdf + cp ./../../README.md . + cp ./../../LICENSE . + cp ./../../AUTHORS . + + zip -r "$TAG.zip" open62541.c open62541.h open62541.pdf README.md LICENSE AUTHORS rm open62541.c rm open62541.h rm open62541.pdf + rm README.md + rm LICENSE + rm AUTHORS git add "$TAG.zip" echo "$TAG.zip" | cat - raw.txt > temp && mv temp raw.txt