Fix permissions

This commit is contained in:
Andrea Cavalli 2020-10-08 02:25:33 +02:00
parent 5c02945088
commit bcdfb14502
2 changed files with 38 additions and 35 deletions

View File

@ -57,15 +57,18 @@ ENV TRAVIS_OS_NAME=windows
ENV TRAVIS_BUILD_DIR=/home/$UNAME/work
ENV TRAVIS_OUTPUT_DIR=/home/$UNAME/output
RUN git clone --depth 1 https://github.com/openssl/openssl.git /tmp/openssl_cross
RUN sudo git clone --depth 1 https://github.com/openssl/openssl.git /var/lib/openssl_cross
RUN sudo chown -R $UNAME:$UNAME /var/lib/openssl_cross
RUN git clone --depth 1 https://github.com/madler/zlib.git /tmp/zlib_cross
RUN sudo git clone --depth 1 https://github.com/madler/zlib.git /var/lib/zlib_cross
RUN sudo chown -R $UNAME:$UNAME /var/lib/zlib_cross
RUN mkdir /tmp/java11_cross
RUN cd /tmp/java11_cross
RUN wget https://github.com/AdoptOpenJDK/openjdk11-binaries/releases/download/jdk-11.0.8%2B10/OpenJDK11U-jdk_x64_windows_hotspot_11.0.8_10.zip -O /tmp/java11_cross/jdk.zip
RUN unzip /tmp/java11_cross/jdk.zip -d /tmp/java11_cross/
RUN mv /tmp/java11_cross/jdk-11.0.8+10/ /tmp/java11_cross/jdk
RUN sudo mkdir /var/lib/java11_cross
RUN sudo chown -R $UNAME:$UNAME /var/lib/zlib_cross
RUN cd /var/lib/java11_cross
RUN wget https://github.com/AdoptOpenJDK/openjdk11-binaries/releases/download/jdk-11.0.8%2B10/OpenJDK11U-jdk_x64_windows_hotspot_11.0.8_10.zip -O /var/lib/java11_cross/jdk.zip
RUN unzip /var/lib/java11_cross/jdk.zip -d /var/lib/java11_cross/
RUN mv /var/lib/java11_cross/jdk-11.0.8+10/ /var/lib/java11_cross/jdk
RUN cd /home/$UNAME/work

View File

@ -4,24 +4,24 @@ cd $TRAVIS_BUILD_DIR
source ./jenkins/scripts/setup_workspace.sh
export JAVA_HOME=/usr/lib/jvm/zulu-11-amd64
export JAVA_AWT_LIBRARY=/tmp/java11_cross/jdk/lib/jawt.lib
export JAVA_JVM_LIBRARY=/tmp/java11_cross/jdk/lib/jvm.lib
export JAVA_INCLUDE_PATH=/tmp/java11_cross/jdk/include
export JAVA_INCLUDE_PATH2=/tmp/java11_cross/jdk/include/win32
export JAVA_AWT_INCLUDE_PATH=/tmp/java11_cross/jdk/include
export JAVA_AWT_LIBRARY=/var/lib/java11_cross/jdk/lib/jawt.lib
export JAVA_JVM_LIBRARY=/var/lib/java11_cross/jdk/lib/jvm.lib
export JAVA_INCLUDE_PATH=/var/lib/java11_cross/jdk/include
export JAVA_INCLUDE_PATH2=/var/lib/java11_cross/jdk/include/win32
export JAVA_AWT_INCLUDE_PATH=/var/lib/java11_cross/jdk/include
TOOLCHAIN_FILE=$TRAVIS_BUILD_DIR/toolchain-win64.cmake
# ====== Prepare dependencies
## Install zlib for windows
cd /tmp/zlib_cross
cd /var/lib/zlib_cross
export CC=x86_64-w64-mingw32-gcc-posix
nice -n 5 chrt -b 0 ./configure --prefix=/tmp/zlib_cross
nice -n 5 chrt -b 0 make -f win32/Makefile.gcc BINARY_PATH=/tmp/zlib_cross/bin INCLUDE_PATH=/tmp/zlib_cross/include LIBRARY_PATH=/tmp/zlib_cross/lib PREFIX=x86_64-w64-mingw32- install
nice -n 5 chrt -b 0 ./configure --prefix=/var/lib/zlib_cross
nice -n 5 chrt -b 0 make -f win32/Makefile.gcc BINARY_PATH=/var/lib/zlib_cross/bin INCLUDE_PATH=/var/lib/zlib_cross/include LIBRARY_PATH=/var/lib/zlib_cross/lib PREFIX=x86_64-w64-mingw32- install
## Install openssl for windows
cd /tmp/openssl_cross
cd /var/lib/openssl_cross
export CC=
nice -n 5 chrt -b 0 ./Configure --cross-compile-prefix=x86_64-w64-mingw32- --prefix=/tmp/openssl_cross mingw64 shared
nice -n 5 chrt -b 0 ./Configure --cross-compile-prefix=x86_64-w64-mingw32- --prefix=/var/lib/openssl_cross mingw64 shared
nice -n 5 chrt -b 0 sudo make install
# ====== Prepare TdLib
@ -37,15 +37,15 @@ nice -n 5 chrt -b 0 \
-DJAVA_JVM_LIBRARY=${JAVA_JVM_LIBRARY} \
-DJAVA_INCLUDE_PATH=${JAVA_INCLUDE_PATH} \
-DJAVA_INCLUDE_PATH2=${JAVA_INCLUDE_PATH2} \
-DOPENSSL_ROOT_DIR=/tmp/openssl_cross \
-DOPENSSL_LIBRARIES_DIR=/tmp/openssl_cross/lib \
-DOPENSSL_INCLUDE_DIR=/tmp/openssl_cross/include \
-DOPENSSL_CRYPTO_LIBRARY=/tmp/openssl_cross/libcrypto-3-x64.dll \
-DOPENSSL_SSL_LIBRARY=/tmp/openssl_cross/libssl-3-x64.dll \
-DZLIB_ROOT=/tmp/zlib_cross \
-DZLIB_LIBRARY=/tmp/zlib_cross/zlib1.dll \
-DZLIB_LIBRARIES_DIR=/tmp/zlib_cross \
-DZLIB_INCLUDE_DIR=/tmp/zlib_cross/include \
-DOPENSSL_ROOT_DIR=/var/lib/openssl_cross \
-DOPENSSL_LIBRARIES_DIR=/var/lib/openssl_cross/lib \
-DOPENSSL_INCLUDE_DIR=/var/lib/openssl_cross/include \
-DOPENSSL_CRYPTO_LIBRARY=/var/lib/openssl_cross/libcrypto-3-x64.dll \
-DOPENSSL_SSL_LIBRARY=/var/lib/openssl_cross/libssl-3-x64.dll \
-DZLIB_ROOT=/var/lib/zlib_cross \
-DZLIB_LIBRARY=/var/lib/zlib_cross/zlib1.dll \
-DZLIB_LIBRARIES_DIR=/var/lib/zlib_cross \
-DZLIB_INCLUDE_DIR=/var/lib/zlib_cross/include \
\
-DCMAKE_BUILD_TYPE=Release \
-DCMAKE_INSTALL_PREFIX:PATH=${TD_BIN_DIR} \
@ -76,15 +76,15 @@ nice -n 5 chrt -b 0 \
-DJAVA_JVM_LIBRARY=${JAVA_JVM_LIBRARY} \
-DJAVA_INCLUDE_PATH=${JAVA_INCLUDE_PATH} \
-DJAVA_INCLUDE_PATH2=${JAVA_INCLUDE_PATH2} \
-DOPENSSL_ROOT_DIR=/tmp/openssl_cross \
-DOPENSSL_LIBRARIES_DIR=/tmp/openssl_cross/lib \
-DOPENSSL_INCLUDE_DIR=/tmp/openssl_cross/include \
-DOPENSSL_CRYPTO_LIBRARY=/tmp/openssl_cross/libcrypto-3-x64.dll \
-DOPENSSL_SSL_LIBRARY=/tmp/openssl_cross/libssl-3-x64.dll \
-DZLIB_ROOT=/tmp/zlib_cross \
-DZLIB_LIBRARY=/tmp/zlib_cross/zlib1.dll \
-DZLIB_LIBRARIES_DIR=/tmp/zlib_cross \
-DZLIB_INCLUDE_DIR=/tmp/zlib_cross/include \
-DOPENSSL_ROOT_DIR=/var/lib/openssl_cross \
-DOPENSSL_LIBRARIES_DIR=/var/lib/openssl_cross/lib \
-DOPENSSL_INCLUDE_DIR=/var/lib/openssl_cross/include \
-DOPENSSL_CRYPTO_LIBRARY=/var/lib/openssl_cross/libcrypto-3-x64.dll \
-DOPENSSL_SSL_LIBRARY=/var/lib/openssl_cross/libssl-3-x64.dll \
-DZLIB_ROOT=/var/lib/zlib_cross \
-DZLIB_LIBRARY=/var/lib/zlib_cross/zlib1.dll \
-DZLIB_LIBRARIES_DIR=/var/lib/zlib_cross \
-DZLIB_INCLUDE_DIR=/var/lib/zlib_cross/include \
\
-DCMAKE_BUILD_TYPE=Release \
-DTD_GENERATED_BINARIES_DIR=${TD_CROSS_BIN_DIR}/td/generate \