From d0182601e1aa434a4d4adc34b34a0eb3963a178b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ren=C3=A9=20Canna=C3=B2?= Date: Tue, 17 Sep 2024 18:57:19 +0000 Subject: [PATCH] Speed up packing time --- Makefile | 6 ++++++ .../proxysql/deb-compliant/entrypoint/entrypoint.bash | 8 ++++---- .../proxysql/rhel-compliant/entrypoint/entrypoint.bash | 8 ++++---- .../rhel-compliant/rhel6/entrypoint/entrypoint.bash | 8 ++++---- .../proxysql/suse-compliant/entrypoint/entrypoint.bash | 8 ++++---- test/tap/tap/Makefile | 3 +++ 6 files changed, 25 insertions(+), 16 deletions(-) diff --git a/Makefile b/Makefile index 056159d046..831da6f30f 100644 --- a/Makefile +++ b/Makefile @@ -344,6 +344,12 @@ build-%: .NOTPARALLEL: binaries/proxysql% binaries/proxysql%: + cd deps && ${MAKE} cleanall + cd lib && ${MAKE} clean + cd src && ${MAKE} clean + cd test/tap && ${MAKE} clean + cd test/deps && ${MAKE} cleanall + find . -not -path "./binaries/*" -not -path "./.git/*" -exec touch -h --date=@`git show -s --format=%ct HEAD` {} \; @docker compose -p proxysql down -v --remove-orphans @docker compose -p proxysql up $(IMG_NAME)$(IMG_TYPE)$(IMG_COMP)_build @docker compose -p proxysql down -v --remove-orphans diff --git a/docker/images/proxysql/deb-compliant/entrypoint/entrypoint.bash b/docker/images/proxysql/deb-compliant/entrypoint/entrypoint.bash index 8ed235472b..f0c6ae079d 100755 --- a/docker/images/proxysql/deb-compliant/entrypoint/entrypoint.bash +++ b/docker/images/proxysql/deb-compliant/entrypoint/entrypoint.bash @@ -25,9 +25,9 @@ echo "==> Building" git config --system --add safe.directory '/opt/proxysql' cd /opt/proxysql echo "==> ProxySQL '$(git describe --long --abbrev=7)'" -export SOURCE_DATE_EPOCH=$(git show -s --format=%ct HEAD) -echo "==> Setting SOURCE_DATE_EPOCH=${SOURCE_DATE_EPOCH}" -find /opt/proxysql -not -path "/opt/proxysql/binaries/*" -exec touch -h --date=@${SOURCE_DATE_EPOCH} {} \; +#export SOURCE_DATE_EPOCH=$(git show -s --format=%ct HEAD) +#echo "==> Setting SOURCE_DATE_EPOCH=${SOURCE_DATE_EPOCH}" +#find /opt/proxysql -not -path "/opt/proxysql/binaries/*" -exec touch -h --date=@${SOURCE_DATE_EPOCH} {} \; if [[ -z ${PROXYSQL_BUILD_TYPE:-} ]] ; then deps_target="build_deps" @@ -36,7 +36,7 @@ else deps_target="build_deps_$PROXYSQL_BUILD_TYPE" build_target="$PROXYSQL_BUILD_TYPE" fi -${MAKE} cleanbuild +#${MAKE} cleanbuild ${MAKE} ${MAKEOPT} "${deps_target}" if [[ -z ${build_target} ]] ; then diff --git a/docker/images/proxysql/rhel-compliant/entrypoint/entrypoint.bash b/docker/images/proxysql/rhel-compliant/entrypoint/entrypoint.bash index f1c639f930..619e5878cc 100755 --- a/docker/images/proxysql/rhel-compliant/entrypoint/entrypoint.bash +++ b/docker/images/proxysql/rhel-compliant/entrypoint/entrypoint.bash @@ -25,9 +25,9 @@ echo "==> Building" git config --system --add safe.directory '/opt/proxysql' cd /opt/proxysql echo "==> ProxySQL '$(git describe --long --abbrev=7)'" -export SOURCE_DATE_EPOCH=$(git show -s --format=%ct HEAD) -echo "==> Setting SOURCE_DATE_EPOCH=${SOURCE_DATE_EPOCH}" -find /opt/proxysql -not -path "/opt/proxysql/binaries/*" -exec touch -h --date=@${SOURCE_DATE_EPOCH} {} \; +#export SOURCE_DATE_EPOCH=$(git show -s --format=%ct HEAD) +#echo "==> Setting SOURCE_DATE_EPOCH=${SOURCE_DATE_EPOCH}" +#find /opt/proxysql -not -path "/opt/proxysql/binaries/*" -exec touch -h --date=@${SOURCE_DATE_EPOCH} {} \; if [[ -z ${PROXYSQL_BUILD_TYPE:-} ]] ; then deps_target="build_deps" @@ -36,7 +36,7 @@ else deps_target="build_deps_$PROXYSQL_BUILD_TYPE" build_target="$PROXYSQL_BUILD_TYPE" fi -${MAKE} cleanbuild +#${MAKE} cleanbuild ${MAKE} ${MAKEOPT} "${deps_target}" if [[ -z ${build_target} ]] ; then diff --git a/docker/images/proxysql/rhel-compliant/rhel6/entrypoint/entrypoint.bash b/docker/images/proxysql/rhel-compliant/rhel6/entrypoint/entrypoint.bash index 3d372dc942..aa4babeef2 100755 --- a/docker/images/proxysql/rhel-compliant/rhel6/entrypoint/entrypoint.bash +++ b/docker/images/proxysql/rhel-compliant/rhel6/entrypoint/entrypoint.bash @@ -25,9 +25,9 @@ echo "==> Building" git config --system --add safe.directory '/opt/proxysql' cd /opt/proxysql echo "==> ProxySQL '$(git describe --long --abbrev=7)'" -export SOURCE_DATE_EPOCH=$(git show -s --format=%ct HEAD) -echo "==> Setting SOURCE_DATE_EPOCH=${SOURCE_DATE_EPOCH}" -find /opt/proxysql -not -path "/opt/proxysql/binaries/*" -exec touch -h --date=@${SOURCE_DATE_EPOCH} {} \; +#export SOURCE_DATE_EPOCH=$(git show -s --format=%ct HEAD) +#echo "==> Setting SOURCE_DATE_EPOCH=${SOURCE_DATE_EPOCH}" +#find /opt/proxysql -not -path "/opt/proxysql/binaries/*" -exec touch -h --date=@${SOURCE_DATE_EPOCH} {} \; if [[ -z ${PROXYSQL_BUILD_TYPE:-} ]] ; then deps_target="build_deps" @@ -36,7 +36,7 @@ else deps_target="build_deps_$PROXYSQL_BUILD_TYPE" build_target="$PROXYSQL_BUILD_TYPE" fi -${MAKE} cleanbuild +#${MAKE} cleanbuild ${MAKE} ${MAKEOPT} "${deps_target}" if [[ -z ${build_target} ]] ; then diff --git a/docker/images/proxysql/suse-compliant/entrypoint/entrypoint.bash b/docker/images/proxysql/suse-compliant/entrypoint/entrypoint.bash index 109b2a27de..cecea77ee9 100755 --- a/docker/images/proxysql/suse-compliant/entrypoint/entrypoint.bash +++ b/docker/images/proxysql/suse-compliant/entrypoint/entrypoint.bash @@ -25,9 +25,9 @@ echo "==> Building" git config --system --add safe.directory '/opt/proxysql' cd /opt/proxysql echo "==> ProxySQL '$(git describe --long --abbrev=7)'" -export SOURCE_DATE_EPOCH=$(git show -s --format=%ct HEAD) -echo "==> Setting SOURCE_DATE_EPOCH=${SOURCE_DATE_EPOCH}" -find /opt/proxysql -not -path "/opt/proxysql/binaries/*" -exec touch -h --date=@${SOURCE_DATE_EPOCH} {} \; +#export SOURCE_DATE_EPOCH=$(git show -s --format=%ct HEAD) +#echo "==> Setting SOURCE_DATE_EPOCH=${SOURCE_DATE_EPOCH}" +#find /opt/proxysql -not -path "/opt/proxysql/binaries/*" -exec touch -h --date=@${SOURCE_DATE_EPOCH} {} \; if [[ -z ${PROXYSQL_BUILD_TYPE:-} ]] ; then deps_target="build_deps" @@ -36,7 +36,7 @@ else deps_target="build_deps_$PROXYSQL_BUILD_TYPE" build_target="$PROXYSQL_BUILD_TYPE" fi -${MAKE} cleanbuild +#${MAKE} cleanbuild ${MAKE} ${MAKEOPT} "${deps_target}" if [[ -z ${build_target} ]] ; then diff --git a/test/tap/tap/Makefile b/test/tap/tap/Makefile index 1f724aee77..aa7fb3486f 100644 --- a/test/tap/tap/Makefile +++ b/test/tap/tap/Makefile @@ -180,3 +180,6 @@ clean: find . -name '*.o' -delete || true find . -name '*.so' -delete || true find . -name '*.so.*' -delete || true + cd cpp-dotenv/static && rm -rf cpp-dotenv-*/ || true + cd cpp-dotenv/dynamic && rm -rf cpp-dotenv-*/ || true +