File tree Expand file tree Collapse file tree 5 files changed +21
-33
lines changed Expand file tree Collapse file tree 5 files changed +21
-33
lines changed Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -19,10 +19,8 @@ set -ex
1919# which apparently magically accepts the licenses.
2020
2121mkdir sdk
22- curl https://dl.google.com/android/repository/tools_r25.2.5-linux.zip -O
23- unzip -d sdk tools_r25.2.5-linux.zip
24-
25- filter=" platform-tools,android-24"
22+ curl https://dl.google.com/android/repository/sdk-tools-linux-3859397.zip -O
23+ unzip -d sdk sdk-tools-linux-3859397.zip
2624
2725case " $1 " in
2826 arm | armv7)
@@ -47,11 +45,16 @@ case "$1" in
4745 ;;
4846esac ;
4947
50- filter=" $filter ,sys-img-$abi -android-24"
51-
52- ./android-accept-licenses.sh " android - update sdk -a --no-ui --filter $filter --no-https"
53-
54- echo " no" | android create avd \
55- --name $1 \
56- --target android-24 \
57- --abi $abi
48+ # --no_https avoids
49+ # javax.net.ssl.SSLHandshakeException: sun.security.validator.ValidatorException: No trusted certificate found
50+ echo " yes" | \
51+ ./sdk/tools/bin/sdkmanager --no_https \
52+ " emulator" \
53+ " platform-tools" \
54+ " platforms;android-24" \
55+ " system-images;android-24;default;$abi "
56+
57+ echo " no" |
58+ ./sdk/tools/bin/avdmanager create avd \
59+ --name $1 \
60+ --package " system-images;android-24;default;$abi "
Original file line number Diff line number Diff line change @@ -25,7 +25,7 @@ RUN sh /android/android-install-ndk.sh $ANDROID_ARCH
2525RUN sh /android/android-install-sdk.sh $ANDROID_ARCH
2626RUN mv /root/.android /tmp
2727RUN chmod 777 -R /tmp/.android
28- RUN chmod 755 /android/sdk/tools/* /android/sdk/tools /qemu/linux-x86_64/*
28+ RUN chmod 755 /android/sdk/tools/* /android/sdk/emulator /qemu/linux-x86_64/*
2929
3030ENV PATH=$PATH:/rust/bin \
3131 CARGO_TARGET_AARCH64_LINUX_ANDROID_LINKER=aarch64-linux-android-gcc \
@@ -38,7 +38,7 @@ ENTRYPOINT [ \
3838 "-c" , \
3939 # set SHELL so android can detect a 64bits system, see
4040 # http://stackoverflow.com/a/41789144
41- "SHELL=/bin/dash emulator @aarch64 -no-window & \
41+ "SHELL=/bin/dash /android/sdk/emulator/ emulator @aarch64 -no-window & \
4242 rustc /tmp/runtest.rs -o /tmp/runtest && \
4343 exec \" $@\" " , \
4444 "--" \
Original file line number Diff line number Diff line change @@ -25,7 +25,7 @@ RUN sh /android/android-install-ndk.sh $ANDROID_ARCH
2525RUN sh /android/android-install-sdk.sh $ANDROID_ARCH
2626RUN mv /root/.android /tmp
2727RUN chmod 777 -R /tmp/.android
28- RUN chmod 755 /android/sdk/tools/* /android/sdk/tools /qemu/linux-x86_64/*
28+ RUN chmod 755 /android/sdk/tools/* /android/sdk/emulator /qemu/linux-x86_64/*
2929
3030ENV PATH=$PATH:/rust/bin \
3131 CARGO_TARGET_ARM_LINUX_ANDROIDEABI_LINKER=arm-linux-androideabi-gcc \
@@ -38,7 +38,7 @@ ENTRYPOINT [ \
3838 "-c" , \
3939 # set SHELL so android can detect a 64bits system, see
4040 # http://stackoverflow.com/a/41789144
41- "SHELL=/bin/dash emulator @arm -no-window & \
41+ "SHELL=/bin/dash /android/sdk/emulator/ emulator @arm -no-window & \
4242 rustc /tmp/runtest.rs -o /tmp/runtest && \
4343 exec \" $@\" " , \
4444 "--" \
Original file line number Diff line number Diff line change @@ -25,7 +25,7 @@ RUN sh /android/android-install-ndk.sh $ANDROID_ARCH
2525RUN sh /android/android-install-sdk.sh $ANDROID_ARCH
2626RUN mv /root/.android /tmp
2727RUN chmod 777 -R /tmp/.android
28- RUN chmod 755 /android/sdk/tools/* /android/sdk/tools /qemu/linux-x86_64/*
28+ RUN chmod 755 /android/sdk/tools/* /android/sdk/emulator /qemu/linux-x86_64/*
2929
3030ENV PATH=$PATH:/rust/bin \
3131 CARGO_TARGET_I686_LINUX_ANDROID_LINKER=i686-linux-android-gcc \
@@ -38,7 +38,7 @@ ENTRYPOINT [ \
3838 "-c" , \
3939 # set SHELL so android can detect a 64bits system, see
4040 # http://stackoverflow.com/a/41789144
41- "SHELL=/bin/dash emulator @i686 -no-window -no-accel & \
41+ "SHELL=/bin/dash /android/sdk/emulator/ emulator @i686 -no-window -no-accel & \
4242 rustc /tmp/runtest.rs -o /tmp/runtest && \
4343 exec \" $@\" " , \
4444 "--" \
You can’t perform that action at this time.
0 commit comments