Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 0 additions & 8 deletions config/blobs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,10 +6,6 @@ Percona-XtraDB-Cluster-8.4.8-8.tar.gz:
size: 506801118
object_id: 5b721094-02b7-4a5e-500e-028ba04fdc8a
sha: sha256:dab67ec69fe96f2beeaa9c4d5b9c6bc82bcdd970ae9f732f7dd32d622c829666
boost_1_59_0.tar.bz2:
size: 70389425
object_id: 7344fc77-b911-45c2-5467-c6d5fcab6d29
sha: sha256:727a932322d94287b62abb1bd2d41723eec4356a7728909e38adb65ca25241ca
boost_1_77_0.tar.bz2:
size: 110361537
object_id: d962752f-1ab7-4896-41d9-8deed29397ca
Expand All @@ -30,10 +26,6 @@ libev-4.33.tar.gz:
size: 569527
object_id: 0ea3b0f6-7b83-4fe5-7ff8-966bcc56ab73
sha: sha256:507eb7b8d1015fbec5b935f34ebed15bf346bed04a11ab82b8eee848c4205aea
percona-xtrabackup-2.4.29.tar.gz:
size: 64667518
object_id: f196e2a0-e2ba-43ef-7d91-4319f8e6b927
sha: sha256:c59f0d612ec6a0f530ca3645546fb8af690f62d3ecbd70d33f30d3f56d9e842e
percona-xtrabackup-8.0.35-35.tar.gz:
size: 447852862
object_id: cfe465d2-d13b-46a9-64f1-8ebb44bd7e08
Expand Down
73 changes: 18 additions & 55 deletions packages/percona-xtrabackup-2.4/packaging
Original file line number Diff line number Diff line change
@@ -1,57 +1,20 @@
#!/usr/bin/env bash

set -o errexit
set -o nounset

main() {
install_build_dependencies
unpack_source
build_and_install
}

install_build_dependencies() {
tar -xf libaio_*.tar.xz
cd libaio-*/
make -j "$(nproc)" install prefix="${BOSH_INSTALL_TARGET}"
cd -

tar -xf libev-*.tar.gz
cd libev-*/
./configure --prefix=/usr/local --disable-static
make -j "$(nproc)" install
./configure --prefix="${BOSH_INSTALL_TARGET}" --libdir="${BOSH_INSTALL_TARGET}/lib/private" --disable-static
make -j "$(nproc)" install-exec
cd -
}

unpack_source() {
tar -xf boost_1_59_0.tar.bz2
tar -xf percona-xtrabackup-*.tar.gz
}

build_and_install() {
cd percona-xtrabackup-*/
mkdir bld && cd bld

export LIBRARY_PATH="${BOSH_INSTALL_TARGET}/lib:${BOSH_INSTALL_TARGET}/lib/private"
export LD_LIBRARY_PATH="${BOSH_INSTALL_TARGET}/lib"
export CPLUS_INCLUDE_PATH="${BOSH_INSTALL_TARGET}/include"
export C_INCLUDE_PATH="${BOSH_INSTALL_TARGET}/include"

# shellcheck disable=SC2016
cmake .. \
-DBUILD_CONFIG=xtrabackup_release \
-DCMAKE_CXX_COMPILER=g++ \
-DCMAKE_C_COMPILER=gcc \
-DCMAKE_INSTALL_PREFIX="${BOSH_INSTALL_TARGET}" \
-DCMAKE_INSTALL_RPATH='$ORIGIN/../lib/private;$ORIGIN/../lib' \
-DINSTALL_MYSQLTESTDIR= \
-DWITH_BOOST=../../boost_1_59_0 \
-DWITH_MAN_PAGES=OFF \
-DWITH_SSL=system

make -j "$(nproc)" install/strip
rm -fr "${BOSH_INSTALL_TARGET}/man/"
}

main
set -o errexit -o nounset

mkdir -p "${BOSH_INSTALL_TARGET}/bin"
script="${BOSH_INSTALL_TARGET}/bin/xtrabackup"
cat >"$script" <<'EOF'
#!/bin/bash

for arg in "$@";do
if [[ $arg == "--version" ]]; then
echo "xtrabackup version 2.4.29"
exit 0
fi
done

echo >&2 "MySQL v5.7 is not supported under this configuration."
exit 1
EOF
chmod 0755 "${script}"
6 changes: 1 addition & 5 deletions packages/percona-xtrabackup-2.4/spec
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,4 @@ name: percona-xtrabackup-2.4

dependencies: []

files:
- boost_1_59_0.tar.bz2
- percona-xtrabackup-2.4*.tar.gz
- libev-*.tar.gz
- libaio_*.tar.xz
files: []
7 changes: 7 additions & 0 deletions packages/percona-xtrabackup-8.0/packaging
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,13 @@
set -o errexit
set -o nounset

# Workaround for uutils coreutils 0.7.0 (ubuntu-resolute): its `install -D`
# replaces symlink path components with real directories instead of following
# them. Resolve the real path so libaio's `make install` (which uses
# `install -D`) writes to the correct location on persistent disk.
# See https://github.com/uutils/coreutils/issues/11469
BOSH_INSTALL_TARGET=$(readlink -f "${BOSH_INSTALL_TARGET}")

main() {
install_build_dependencies
unpack_source
Expand Down
7 changes: 7 additions & 0 deletions packages/percona-xtrabackup-8.4/packaging
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,13 @@
set -o errexit
set -o nounset

# Workaround for uutils coreutils 0.7.0 (ubuntu-resolute): its `install -D`
# replaces symlink path components with real directories instead of following
# them. Resolve the real path so libaio's `make install` (which uses
# `install -D`) writes to the correct location on persistent disk.
# See https://github.com/uutils/coreutils/issues/11469
BOSH_INSTALL_TARGET=$(readlink -f "${BOSH_INSTALL_TARGET}")

main() {
install_build_dependencies
unpack_source
Expand Down
15 changes: 13 additions & 2 deletions packages/percona-xtradb-cluster-8.0/packaging
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,13 @@ set -o errexit
set -o nounset
set -o pipefail

# Workaround for uutils coreutils 0.7.0 (ubuntu-resolute): its `install -D`
# replaces symlink path components with real directories instead of following
# them. Resolve the real path so libaio's `make install` (which uses
# `install -D`) writes to the correct location on persistent disk.
# See https://github.com/uutils/coreutils/issues/11469
BOSH_INSTALL_TARGET=$(readlink -f "${BOSH_INSTALL_TARGET}")

main() {
install_build_dependencies
install_runtime_dependencies
Expand All @@ -26,7 +33,9 @@ install_build_dependencies() {
tar -xf boost_*.tar.bz2
cd boost_*/
./bootstrap.sh --with-libraries=program_options,system
./b2 -j "$(nproc)" link=static
./b2 -j "$(nproc)" cxxstd=17 cxxflags="-fPIC" cflags="-fPIC"
mkdir -p "${BOSH_INSTALL_TARGET}/lib/private"
cp --preserve=all ./stage/lib/libboost_program_options.so.* "${BOSH_INSTALL_TARGET}/lib/private/"
cd -

tar -xf check_*.tar.gz
Expand Down Expand Up @@ -78,7 +87,9 @@ build() {
cmake .. \
-DBUILD_CONFIG=mysql_release \
-DBOOST_ROOT="${boost_dir}" \
-DBoost_DIR="$(readlink -f "${boost_dir}"/stage/lib/cmake/Boost-*/)" \
-DCMAKE_BUILD_TYPE=RelWithDebInfo \
-DCMAKE_C_FLAGS="-std=gnu17" \
-DMINIMAL_RELWITHDEBINFO=OFF \
-DCMAKE_CXX_COMPILER=g++ \
-DCMAKE_C_COMPILER=gcc \
Expand All @@ -98,7 +109,7 @@ build() {
-DWITH_AUTHENTICATION_KERBEROS=OFF \
-DWITH_PERCONA_AUTHENTICATION_LDAP=OFF \
-DWITH_BOOST="${boost_dir}" \
-DWITH_ICU=system \
-DWITH_ICU=bundled \
-DWITH_READLINE=system \
-DWITH_ROUTER=OFF \
-DWITH_GROUP_REPLICATION=OFF \
Expand Down
16 changes: 14 additions & 2 deletions packages/percona-xtradb-cluster-8.4/packaging
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,13 @@ set -o errexit
set -o nounset
set -o pipefail

# Workaround for uutils coreutils 0.7.0 (ubuntu-resolute): its `install -D`
# replaces symlink path components with real directories instead of following
# them. Resolve the real path so libaio's `make install` (which uses
# `install -D`) writes to the correct location on persistent disk.
# See https://github.com/uutils/coreutils/issues/11469
BOSH_INSTALL_TARGET=$(readlink -f "${BOSH_INSTALL_TARGET}")

main() {
install_build_dependencies
install_runtime_dependencies
Expand All @@ -26,7 +33,9 @@ install_build_dependencies() {
tar -xf boost_*.tar.bz2
cd boost_*/
./bootstrap.sh --with-libraries=program_options,system
./b2 -j "$(nproc)" link=static
./b2 -j "$(nproc)" cxxstd=17 cxxflags="-fPIC" cflags="-fPIC"
mkdir -p "${BOSH_INSTALL_TARGET}/lib/private"
cp --preserve=all ./stage/lib/libboost_program_options.so.* "${BOSH_INSTALL_TARGET}/lib/private/"
cd -

tar -xf check_*.tar.gz
Expand Down Expand Up @@ -78,7 +87,9 @@ build() {
cmake .. \
-DBUILD_CONFIG=mysql_release \
-DBOOST_ROOT="${boost_dir}" \
-DBoost_DIR="$(readlink -f "${boost_dir}"/stage/lib/cmake/Boost-*/)" \
-DCMAKE_BUILD_TYPE=RelWithDebInfo \
-DCMAKE_C_FLAGS="-std=gnu17" \
-DMINIMAL_RELWITHDEBINFO=OFF \
-DCMAKE_CXX_COMPILER=g++ \
-DCMAKE_C_COMPILER=gcc \
Expand All @@ -97,7 +108,8 @@ build() {
-DWITH_AUTHENTICATION_FIDO=OFF \
-DWITH_AUTHENTICATION_KERBEROS=OFF \
-DWITH_PERCONA_AUTHENTICATION_LDAP=OFF \
-DWITH_ICU=system \
-DWITH_BOOST="${boost_dir}" \
-DWITH_ICU=bundled \
-DWITH_READLINE=system \
-DWITH_ROUTER=OFF \
-DWITH_GROUP_REPLICATION=OFF \
Expand Down
Loading