File tree 8 files changed +22
-46
lines changed
8 files changed +22
-46
lines changed Original file line number Diff line number Diff line change 3
3
set -ex
4
4
5
5
NDK=android-ndk-r21d
6
- wget --tries=20 https://dl.google.com/android/repository/${NDK} -linux-x86_64.zip
6
+ wget --tries=20 -q https://dl.google.com/android/repository/${NDK} -linux-x86_64.zip
7
7
unzip -q ${NDK} -linux-x86_64.zip
8
8
9
9
case " $1 " in
10
10
arm)
11
11
arch=arm
12
- api=24
12
+ api=28
13
13
;;
14
14
armv7)
15
15
arch=arm
16
- api=24
16
+ api=28
17
17
;;
18
18
aarch64)
19
19
arch=arm64
20
- api=24
20
+ api=28
21
21
;;
22
22
i686)
23
23
arch=x86
Original file line number Diff line number Diff line change @@ -9,10 +9,10 @@ set -ex
9
9
# located in https://github.com/appunite/docker by just wrapping it in a script
10
10
# which apparently magically accepts the licenses.
11
11
12
- SDK=4333796
13
- mkdir sdk
14
- wget -- tries=20 https://dl.google.com/android/repository/sdk-tools- linux-${SDK} .zip
15
- unzip -q -d sdk sdk -tools-linux-${SDK} .zip
12
+ SDK=6609375
13
+ mkdir -p sdk/cmdline-tools
14
+ wget -q -- tries=20 https://dl.google.com/android/repository/commandlinetools- linux-${SDK} _latest .zip
15
+ unzip -q -d sdk/cmdline -tools commandlinetools -linux-${SDK} _latest .zip
16
16
17
17
case " $1 " in
18
18
arm | armv7)
@@ -51,14 +51,14 @@ echo '#Fri Nov 03 10:11:27 CET 2017 count=0' >> /root/.android/repositories.cfg
51
51
#
52
52
# | grep -v = || true removes the progress bar output from the sdkmanager
53
53
# which produces an insane amount of output.
54
- yes | ./sdk/tools/bin/sdkmanager --licenses --no_https | grep -v = || true
55
- yes | ./sdk/tools/bin/sdkmanager --no_https \
54
+ yes | ./sdk/cmdline-tools/ tools/bin/sdkmanager --licenses --no_https | grep -v = || true
55
+ yes | ./sdk/cmdline-tools/ tools/bin/sdkmanager --no_https \
56
56
" emulator" \
57
57
" platform-tools" \
58
58
" platforms;android-${api} " \
59
59
" ${image} " | grep -v = || true
60
60
61
61
echo " no" |
62
- ./sdk/tools/bin/avdmanager create avd \
62
+ ./sdk/cmdline-tools/ tools/bin/avdmanager create avd \
63
63
--name " ${1} " \
64
64
--package " ${image} " | grep -v = || true
Original file line number Diff line number Diff line change @@ -14,7 +14,7 @@ main() {
14
14
apt-get install --no-install-recommends e2tools
15
15
16
16
pushd " ${td} "
17
- wget --tries=5 " ${URL} /${name} "
17
+ wget -q - -tries=5 " ${URL} /${name} "
18
18
unzip -q " ${name} "
19
19
20
20
local system
Original file line number Diff line number Diff line change @@ -19,16 +19,17 @@ WORKDIR /android/
19
19
COPY android* /android/
20
20
21
21
ENV ANDROID_ARCH=aarch64
22
- ENV PATH=$PATH:/android/ndk-$ANDROID_ARCH/bin:/android/sdk/tools:/android/sdk/platform-tools
22
+ ENV PATH=$PATH:/android/ndk-$ANDROID_ARCH/bin:/android/sdk/cmdline-tools/ tools:/android/sdk/platform-tools
23
23
24
24
RUN sh /android/android-install-ndk.sh $ANDROID_ARCH
25
25
RUN sh /android/android-install-sdk.sh $ANDROID_ARCH
26
26
RUN mv /root/.android /tmp
27
27
RUN chmod 777 -R /tmp/.android
28
- RUN chmod 755 /android/sdk/tools/* /android/sdk/emulator/qemu/linux-x86_64/*
28
+ RUN chmod 755 /android/sdk/cmdline-tools/tools/* /android/sdk/emulator/qemu/linux-x86_64/*
29
+ RUN ls -a /android/sdk/platform-tools
29
30
30
31
ENV PATH=$PATH:/rust/bin \
31
- CARGO_TARGET_AARCH64_LINUX_ANDROID_LINKER=aarch64-linux-android-gcc \
32
+ CARGO_TARGET_AARCH64_LINUX_ANDROID_LINKER=aarch64-linux-android28-clang \
32
33
CARGO_TARGET_AARCH64_LINUX_ANDROID_RUNNER=/tmp/runtest \
33
34
HOME=/tmp
34
35
Original file line number Diff line number Diff line change @@ -19,13 +19,14 @@ WORKDIR /android/
19
19
COPY android* /android/
20
20
21
21
ENV ANDROID_ARCH=arm
22
- ENV PATH=$PATH:/android/ndk-$ANDROID_ARCH/bin:/android/sdk/tools:/android/sdk/platform-tools
22
+ ENV PATH=$PATH:/android/ndk-$ANDROID_ARCH/bin:/android/sdk/cmdline-tools/ tools:/android/sdk/platform-tools
23
23
24
24
RUN sh /android/android-install-ndk.sh $ANDROID_ARCH
25
25
RUN sh /android/android-install-sdk.sh $ANDROID_ARCH
26
26
RUN mv /root/.android /tmp
27
27
RUN chmod 777 -R /tmp/.android
28
- RUN chmod 755 /android/sdk/tools/* /android/sdk/emulator/qemu/linux-x86_64/*
28
+ RUN chmod 755 /android/sdk/cmdline-tools/tools/* /android/sdk/emulator/qemu/linux-x86_64/*
29
+ RUN ls -a /android/sdk/platform-tools
29
30
30
31
ENV PATH=$PATH:/rust/bin \
31
32
CARGO_TARGET_ARM_LINUX_ANDROIDEABI_LINKER=arm-linux-androideabi-gcc \
Original file line number Diff line number Diff line change @@ -20,13 +20,13 @@ WORKDIR /android/
20
20
COPY android* /android/
21
21
22
22
ENV ANDROID_ARCH=i686
23
- ENV PATH=$PATH:/android/ndk-$ANDROID_ARCH/bin:/android/sdk/tools:/android/sdk/platform-tools
23
+ ENV PATH=$PATH:/android/ndk-$ANDROID_ARCH/bin:/android/sdk/cmdline- tools/tools :/android/sdk/cmdline-tools /platform-tools
24
24
25
25
RUN sh /android/android-install-ndk.sh $ANDROID_ARCH
26
26
RUN sh /android/android-install-sdk.sh $ANDROID_ARCH
27
27
RUN mv /root/.android /tmp
28
28
RUN chmod 777 -R /tmp/.android
29
- RUN chmod 755 /android/sdk/tools/* /android/sdk/emulator/qemu/linux-x86_64/*
29
+ RUN chmod 755 /android/sdk/cmdline-tools/ tools/* /android/sdk/emulator/qemu/linux-x86_64/*
30
30
31
31
ENV PATH=$PATH:/rust/bin \
32
32
CARGO_TARGET_I686_LINUX_ANDROID_LINKER=i686-linux-android-gcc \
Original file line number Diff line number Diff line change @@ -9,7 +9,7 @@ path = ".."
9
9
default-features = false
10
10
11
11
[build-dependencies ]
12
- cc = " 1.0"
12
+ cc = " = 1.0.52 "
13
13
# FIXME: Use fork ctest until the maintainer gets back.
14
14
ctest2 = " 0.3"
15
15
Original file line number Diff line number Diff line change @@ -1370,7 +1370,6 @@ fn test_android(target: &str) {
1370
1370
t => panic ! ( "unsupported target: {}" , t) ,
1371
1371
} ;
1372
1372
let x86 = target. contains ( "i686" ) || target. contains ( "x86_64" ) ;
1373
- let aarch64 = target. contains ( "aarch64" ) ;
1374
1373
1375
1374
let mut cfg = ctest_cfg ( ) ;
1376
1375
cfg. define ( "_GNU_SOURCE" , None ) ;
@@ -1592,31 +1591,6 @@ fn test_android(target: &str) {
1592
1591
// test the XSI version below.
1593
1592
"strerror_r" => true ,
1594
1593
1595
- // FIXME: Somehow we cannot find these fns on aarch64.
1596
- // https://github.com/rust-lang/libc/issues/1765
1597
- "lockf"
1598
- | "preadv64"
1599
- | "pwritev64"
1600
- | "openpty"
1601
- | "forkpty"
1602
- | "login_tty"
1603
- | "getifaddrs"
1604
- | "freeifaddrs"
1605
- | "sethostname"
1606
- | "getgrgid_r"
1607
- | "getgrnam_r"
1608
- | "sigtimedwait"
1609
- | "fmemopen"
1610
- | "open_memstream"
1611
- | "open_wmemstream"
1612
- | "clock_getcpuclockid"
1613
- | "process_vm_readv"
1614
- | "process_vm_writev"
1615
- if aarch64 =>
1616
- {
1617
- true
1618
- }
1619
-
1620
1594
_ => false ,
1621
1595
}
1622
1596
} ) ;
You can’t perform that action at this time.
0 commit comments