1
0
mirror of https://github.com/lineageos4microg/docker-lineage-cicd synced 2024-11-09 10:09:56 +01:00

Remove openjdk-7

OpenJDK 7 was previously taken from the Debian experimental repo, but is
has been removed.
OpenJDK 7 is needed to build LineageOS/Cyanogenmod 11.0-13.0, so
support for those version is dropped.
This commit is contained in:
Nicola Corna 2019-08-21 10:00:45 +02:00
parent 50027d7dd2
commit c3478c3352
2 changed files with 7 additions and 18 deletions

@ -161,9 +161,6 @@ RUN mkdir -p $USERSCRIPTS_DIR
# Install build dependencies
############################
RUN echo 'deb http://deb.debian.org/debian sid main' >> /etc/apt/sources.list
RUN echo 'deb http://deb.debian.org/debian experimental main' >> /etc/apt/sources.list
COPY apt_preferences /etc/apt/preferences
RUN apt-get -qq update
RUN apt-get -qqy upgrade
@ -171,9 +168,8 @@ RUN apt-get install -y bc bison bsdmainutils build-essential ccache cgpt cron \
curl flex g++-multilib gcc-multilib git gnupg gperf imagemagick kmod \
lib32ncurses5-dev lib32readline-dev lib32z1-dev libesd0-dev liblz4-tool \
libncurses5-dev libsdl1.2-dev libssl-dev libwxgtk3.0-dev libxml2 \
libxml2-utils lsof lzop maven openjdk-7-jdk openjdk-8-jdk pngcrush \
procps python rsync schedtool squashfs-tools wget xdelta3 xsltproc yasm \
zip zlib1g-dev
libxml2-utils lsof lzop maven openjdk-8-jdk pngcrush procps python rsync \
schedtool squashfs-tools wget xdelta3 xsltproc yasm zip zlib1g-dev
RUN curl https://storage.googleapis.com/git-repo-downloads/repo > /usr/local/bin/repo
RUN chmod a+x /usr/local/bin/repo

@ -146,6 +146,11 @@ for branch in ${BRANCH_NAME//,/ }; do
fi
android_version_major=$(cut -d '.' -f 1 <<< $android_version)
if [ "$android_version_major" -lt "7" ]; then
echo ">> [$(date)] ERROR: $branch requires a JDK version too old (< 8); aborting"
exit 1
fi
if [ "$android_version_major" -ge "8" ]; then
vendor="lineage"
else
@ -234,18 +239,6 @@ for branch in ${BRANCH_NAME//,/ }; do
sed -i "1s;^;PRODUCT_DEFAULT_DEV_CERTIFICATE := user-keys/releasekey\nPRODUCT_OTA_PUBLIC_KEYS := user-keys/releasekey\nPRODUCT_EXTRA_RECOVERY_KEYS := user-keys/releasekey\n\n;" "vendor/$vendor/config/common.mk"
fi
if [ "$android_version_major" -ge "7" ]; then
jdk_version=8
elif [ "$android_version_major" -ge "5" ]; then
jdk_version=7
else
echo ">> [$(date)] ERROR: $branch requires a JDK version too old (< 7); aborting"
exit 1
fi
echo ">> [$(date)] Using OpenJDK $jdk_version"
update-java-alternatives -s java-1.$jdk_version.0-openjdk-amd64 &> /dev/null
# Prepare the environment
echo ">> [$(date)] Preparing build environment"
source build/envsetup.sh > /dev/null