devops: remove universal WebKit build (#16468)

We experimented with it and are not ready to commit.
This commit is contained in:
Andrey Lushnikov 2022-08-11 10:12:45 -07:00 committed by GitHub
parent f3269c6891
commit acc9b528ea
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 18 additions and 84 deletions

View File

@ -331,13 +331,6 @@ elif [[ "$BUILD_FLAVOR" == "webkit-debian-11" ]]; then
EXPECTED_HOST_OS="Debian"
EXPECTED_HOST_OS_VERSION="11"
BUILD_BLOB_NAME="webkit-debian-11.zip"
elif [[ "$BUILD_FLAVOR" == "webkit-universal" ]]; then
BROWSER_NAME="webkit"
EXTRA_BUILD_ARGS="--full --universal"
EXTRA_ARCHIVE_ARGS="--universal"
EXPECTED_HOST_OS="Ubuntu"
EXPECTED_HOST_OS_VERSION="20.04"
BUILD_BLOB_NAME="webkit-linux-universal.zip"
elif [[ "$BUILD_FLAVOR" == "webkit-ubuntu-18.04" ]]; then
BROWSER_NAME="webkit"
EXTRA_BUILD_ARGS="--full"

View File

@ -86,9 +86,6 @@ elif [[ "${BUILD_FLAVOR}" == "webkit-ubuntu-22.04-arm64" ]]; then
elif [[ "${BUILD_FLAVOR}" == "webkit-debian-11" ]]; then
DOCKER_PLATFORM="linux/amd64"
DOCKER_IMAGE_NAME="debian:11"
elif [[ "${BUILD_FLAVOR}" == "webkit-universal" ]]; then
DOCKER_PLATFORM="linux/amd64"
DOCKER_IMAGE_NAME="ubuntu:20.04"
else
echo "ERROR: unknown build flavor - '${BUILD_FLAVOR}'"
exit 1
@ -113,10 +110,6 @@ function ensure_docker_container {
if docker ps | grep "${DOCKER_CONTAINER_NAME}" 2>&1 1>/dev/null; then
return;
fi
if [[ "${BUILD_FLAVOR}" == "webkit-universal" ]]; then
# NOTE: WebKit Linux Universal build is run in PRIVILEGED container due to Flatpak!
DOCKER_ARGS="${DOCKER_ARGS} --privileged"
fi
docker pull --platform "${DOCKER_PLATFORM}" "${DOCKER_IMAGE_NAME}"
docker run --rm ${DOCKER_ARGS} --name "${DOCKER_CONTAINER_NAME}" --platform "${DOCKER_PLATFORM}" -d -t "${DOCKER_IMAGE_NAME}" /bin/bash
docker exec ${DOCKER_ARGS} "${DOCKER_CONTAINER_NAME}" /bin/bash -c '

View File

@ -1,4 +1,3 @@
webkit-linux-universal.zip
webkit-ubuntu-18.04.zip
webkit-ubuntu-20.04.zip
webkit-ubuntu-20.04-arm64.zip

View File

@ -3,7 +3,7 @@ set -e
set +x
if [[ ("$1" == "-h") || ("$1" == "--help") ]]; then
echo "usage: $(basename "$0") [output-absolute-path] [--universal]"
echo "usage: $(basename "$0") [output-absolute-path]"
echo
echo "Generate distributable .zip archive from ./checkout folder that was previously built."
echo
@ -28,11 +28,6 @@ if ! [[ -d $(dirname "$ZIP_PATH") ]]; then
exit 1
fi
IS_UNIVERSAL_BUILD=""
if [[ $2 == "--universal" ]]; then
IS_UNIVERSAL_BUILD=1
fi
main() {
if [[ ! -z "${WK_CHECKOUT_PATH}" ]]; then
cd "${WK_CHECKOUT_PATH}"
@ -67,17 +62,10 @@ createZipForLinux() {
# Generate and unpack MiniBrowser bundles for each port
for port in gtk wpe; do
if [[ -n "${IS_UNIVERSAL_BUILD}" ]]; then
Tools/Scripts/generate-bundle \
--syslibs=bundle-all \
--bundle=MiniBrowser --release \
--platform=${port} --destination="${tmpdir}"
else
WEBKIT_OUTPUTDIR=$(pwd)/WebKitBuild/${port^^} \
Tools/Scripts/generate-bundle \
--bundle=MiniBrowser --release \
--platform=${port} --destination="${tmpdir}"
fi
WEBKIT_OUTPUTDIR=$(pwd)/WebKitBuild/${port^^} \
Tools/Scripts/generate-bundle \
--bundle=MiniBrowser --release \
--platform=${port} --destination="${tmpdir}"
unzip "${tmpdir}"/MiniBrowser_${port}_release.zip -d "${tmpdir}"/minibrowser-${port}
rm -f "${tmpdir}"/MiniBrowser_${port}_release.zip
@ -85,14 +73,6 @@ createZipForLinux() {
cd "$tmpdir"
if [[ -n "${IS_UNIVERSAL_BUILD}" ]]; then
# De-duplicate common files: convert to relative symlinks identical files (same hash).
# We apply this algorithm only to unified build since in JHBuild WPE/Minibrowser
# and GTK/Minibrowser executables are identical and should not be symlinked.
rdfind -deterministic true -makesymlinks true -makehardlinks false -makeresultsfile false .
symlinks -rc .
fi
# zip resulting directory and cleanup TMP.
zip --symlinks -r "$ZIP_PATH" ./
cd -

View File

@ -7,13 +7,8 @@ cd "$(dirname "$0")"
SCRIPT_FOLDER="$(pwd -P)"
source "${SCRIPT_FOLDER}/../utils.sh"
# On Linux, Universal build uses Flatpak rather then JHBuild
# and packs into a universal binary that can run on any linux
# distribution.
IS_UNIVERSAL_BUILD=""
build_gtk() {
if [[ -z "${IS_UNIVERSAL_BUILD}" && ! -d "./WebKitBuild/GTK/DependenciesGTK" ]]; then
if [[ ! -d "./WebKitBuild/GTK/DependenciesGTK" ]]; then
yes | WEBKIT_JHBUILD=1 \
WEBKIT_JHBUILD_MODULESET=minimal \
WEBKIT_OUTPUTDIR=$(pwd)/WebKitBuild/GTK \
@ -27,18 +22,14 @@ build_gtk() {
if [[ -n "${EXPORT_COMPILE_COMMANDS}" ]]; then
CMAKE_ARGS+=("--cmakeargs=-DCMAKE_EXPORT_COMPILE_COMMANDS=1")
fi
if [[ -n "${IS_UNIVERSAL_BUILD}" ]]; then
./Tools/Scripts/build-webkit --gtk --release "${CMAKE_ARGS}" --touch-events --orientation-events --no-bubblewrap-sandbox "${CMAKE_ARGS[@]}" MiniBrowser
else
WEBKIT_JHBUILD=1 \
WEBKIT_JHBUILD_MODULESET=minimal \
WEBKIT_OUTPUTDIR=$(pwd)/WebKitBuild/GTK \
./Tools/Scripts/build-webkit --gtk --release "${CMAKE_ARGS}" --touch-events --orientation-events --no-bubblewrap-sandbox "${CMAKE_ARGS[@]}" MiniBrowser
fi
WEBKIT_JHBUILD=1 \
WEBKIT_JHBUILD_MODULESET=minimal \
WEBKIT_OUTPUTDIR=$(pwd)/WebKitBuild/GTK \
./Tools/Scripts/build-webkit --gtk --release "${CMAKE_ARGS}" --touch-events --orientation-events --no-bubblewrap-sandbox "${CMAKE_ARGS[@]}" MiniBrowser
}
build_wpe() {
if [[ -z "${IS_UNIVERSAL_BUILD}" && ! -d "./WebKitBuild/WPE/DependenciesWPE" ]]; then
if [[ ! -d "./WebKitBuild/WPE/DependenciesWPE" ]]; then
yes | WEBKIT_JHBUILD=1 \
WEBKIT_JHBUILD_MODULESET=minimal \
WEBKIT_OUTPUTDIR=$(pwd)/WebKitBuild/WPE \
@ -55,35 +46,19 @@ build_wpe() {
CMAKE_ARGS+=("--cmakeargs=-DCMAKE_EXPORT_COMPILE_COMMANDS=1")
fi
if [[ -n "${IS_UNIVERSAL_BUILD}" ]]; then
./Tools/Scripts/build-webkit --wpe --release "${CMAKE_ARGS}" --touch-events --orientation-events --no-bubblewrap-sandbox "${CMAKE_ARGS[@]}" MiniBrowser
else
WEBKIT_JHBUILD=1 \
WEBKIT_JHBUILD_MODULESET=minimal \
WEBKIT_OUTPUTDIR=$(pwd)/WebKitBuild/WPE \
./Tools/Scripts/build-webkit --wpe --release "${CMAKE_ARGS}" --touch-events --orientation-events --no-bubblewrap-sandbox "${CMAKE_ARGS[@]}" MiniBrowser
fi
WEBKIT_JHBUILD=1 \
WEBKIT_JHBUILD_MODULESET=minimal \
WEBKIT_OUTPUTDIR=$(pwd)/WebKitBuild/WPE \
./Tools/Scripts/build-webkit --wpe --release "${CMAKE_ARGS}" --touch-events --orientation-events --no-bubblewrap-sandbox "${CMAKE_ARGS[@]}" MiniBrowser
}
ensure_linux_deps() {
if [[ -n "${IS_UNIVERSAL_BUILD}" ]]; then
SUDO="" ; [ $UID -ne 0 ] && SUDO="sudo"
# - flatpak drives the build
# - symlinks and rdfind are needed to de-duplicate files on the GTK+WPE bundle to reduce its size.
DEBIAN_FRONTEND=noninteractive ${SUDO} apt-get install -y flatpak symlinks rdfind
fi
yes | DEBIAN_FRONTEND=noninteractive ./Tools/gtk/install-dependencies
yes | DEBIAN_FRONTEND=noninteractive ./Tools/wpe/install-dependencies
if [[ -z "${IS_UNIVERSAL_BUILD}" ]]; then
# In non-universal build install JHBuild deps.
yes | DEBIAN_FRONTEND=noninteractive WEBKIT_JHBUILD=1 WEBKIT_JHBUILD_MODULESET=minimal WEBKIT_OUTPUTDIR=$(pwd)/WebKitBuild/WPE ./Tools/Scripts/update-webkitwpe-libs
yes | DEBIAN_FRONTEND=noninteractive WEBKIT_JHBUILD=1 WEBKIT_JHBUILD_MODULESET=minimal WEBKIT_OUTPUTDIR=$(pwd)/WebKitBuild/GTK ./Tools/Scripts/update-webkitgtk-libs
else
yes | ./Tools/Scripts/update-webkitwpe-libs
yes | ./Tools/Scripts/update-webkitgtk-libs
fi
# Install JHBuild deps.
yes | DEBIAN_FRONTEND=noninteractive WEBKIT_JHBUILD=1 WEBKIT_JHBUILD_MODULESET=minimal WEBKIT_OUTPUTDIR=$(pwd)/WebKitBuild/WPE ./Tools/Scripts/update-webkitwpe-libs
yes | DEBIAN_FRONTEND=noninteractive WEBKIT_JHBUILD=1 WEBKIT_JHBUILD_MODULESET=minimal WEBKIT_OUTPUTDIR=$(pwd)/WebKitBuild/GTK ./Tools/Scripts/update-webkitgtk-libs
}
if [[ ! -z "${WK_CHECKOUT_PATH}" ]]; then
@ -106,7 +81,6 @@ elif is_linux; then
--full) IS_FULL="1"; unset args[i]; ;;
--gtk) BUILD_GTK="1"; unset args[i]; ;;
--wpe) BUILD_WPE="1"; unset args[i]; ;;
--universal) IS_UNIVERSAL_BUILD="1"; unset args[i]; ;;
esac
done
@ -117,11 +91,6 @@ elif is_linux; then
fi
echo "== BUILD CONFIGURATION =="
if [[ -n "${IS_UNIVERSAL_BUILD}" ]]; then
echo "- universal build: YES"
else
echo "- universal build: NO"
fi
if [[ -n "${IS_FULL}" ]]; then
echo "- install dependencies: YES"
else