Skip to content

Commit

Permalink
Merge pull request #4647 from sysown/v2.7-PackageSpeedup
Browse files Browse the repository at this point in the history
Speed up packing time
  • Loading branch information
renecannao authored Sep 18, 2024
2 parents 7357229 + d018260 commit 2d6c897
Show file tree
Hide file tree
Showing 6 changed files with 25 additions and 16 deletions.
6 changes: 6 additions & 0 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -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
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand All @@ -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
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand All @@ -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
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand All @@ -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
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand All @@ -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
Expand Down
3 changes: 3 additions & 0 deletions test/tap/tap/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -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

0 comments on commit 2d6c897

Please sign in to comment.