Skip to content

Commit 2870ca5

Browse files
committed
scripts: android_env: Adapt to Ubuntu 23.04
Adresses the issue akhilnarang#195 Change-Id: I67b5e9c8f13415e2378e69663e822335779a227e
1 parent 5e6cb17 commit 2870ca5

File tree

1 file changed

+10
-4
lines changed

1 file changed

+10
-4
lines changed

setup/android_build_env.sh

+10-4
Original file line numberDiff line numberDiff line change
@@ -16,21 +16,27 @@ PACKAGES=""
1616
sudo apt install software-properties-common -y
1717
sudo apt update
1818

19+
LSB_RELEASE="$(lsb_release -d | cut -d ':' -f 2 | sed -e 's/^[[:space:]]*//')"
20+
21+
if [[ ${LSB_RELEASE} =~ "Ubuntu 20" || ${LSB_RELEASE} =~ "Ubuntu 21" || ${LSB_RELEASE} =~ "Ubuntu 22" || ${LSB_RELEASE} =~ 'Pop!_OS 2' ]]; then
1922
# Install lsb-core packages
2023
sudo apt install lsb-core -y
21-
22-
LSB_RELEASE="$(lsb_release -d | cut -d ':' -f 2 | sed -e 's/^[[:space:]]*//')"
24+
fi
2325

2426
if [[ ${LSB_RELEASE} =~ "Mint 18" || ${LSB_RELEASE} =~ "Ubuntu 16" ]]; then
2527
PACKAGES="${UBUNTU_16_PACKAGES}"
26-
elif [[ ${LSB_RELEASE} =~ "Ubuntu 20" || ${LSB_RELEASE} =~ "Ubuntu 21" || ${LSB_RELEASE} =~ "Ubuntu 22" || ${LSB_RELEASE} =~ 'Pop!_OS 2' ]]; then
28+
elif [[ ${LSB_RELEASE} =~ "Ubuntu 20" || ${LSB_RELEASE} =~ "Ubuntu 21" || ${LSB_RELEASE} =~ "Ubuntu 22" || ${LSB_RELEASE} =~ "Ubuntu 23" || ${LSB_RELEASE} =~ 'Pop!_OS 2' ]]; then
2729
PACKAGES="${UBUNTU_20_PACKAGES}"
2830
elif [[ ${LSB_RELEASE} =~ "Debian GNU/Linux 10" ]]; then
2931
PACKAGES="${DEBIAN_10_PACKAGES}"
3032
elif [[ ${LSB_RELEASE} =~ "Debian GNU/Linux 11" ]]; then
3133
PACKAGES="${DEBIAN_11_PACKAGES}"
3234
fi
3335

36+
if [[ ${LSB_RELEASE} =~ "Ubuntu 20" || ${LSB_RELEASE} =~ "Ubuntu 21" || ${LSB_RELEASE} =~ "Ubuntu 22" || ${LSB_RELEASE} =~ 'Pop!_OS 2' ]]; then
37+
sudo apt install python2.7 python-all-dev -y
38+
fi
39+
3440
sudo DEBIAN_FRONTEND=noninteractive \
3541
apt install \
3642
adb autoconf automake axel bc bison build-essential \
@@ -40,7 +46,7 @@ sudo DEBIAN_FRONTEND=noninteractive \
4046
libexpat1-dev libgmp-dev '^liblz4-.*' '^liblzma.*' libmpc-dev libmpfr-dev libncurses5-dev \
4147
libsdl1.2-dev libssl-dev libtool libxml2 libxml2-utils '^lzma.*' lzop \
4248
maven ncftp ncurses-dev patch patchelf pkg-config pngcrush \
43-
pngquant python2.7 python-all-dev re2c schedtool squashfs-tools subversion \
49+
pngquant re2c schedtool squashfs-tools subversion \
4450
texinfo unzip w3m xsltproc zip zlib1g-dev lzip \
4551
libxml-simple-perl libswitch-perl apt-utils \
4652
${PACKAGES} -y

0 commit comments

Comments
 (0)