This is an automated email from the ASF dual-hosted git repository. oppenheimer01 pushed a commit to branch cbdb-postgres-merge in repository https://gitbox.apache.org/repos/asf/cloudberry.git
commit 50f1ec0b279b9ad77db810c67930c6bd15868936 Author: Dianjin Wang <[email protected]> AuthorDate: Tue Apr 7 11:40:07 2026 +0800 Build: make diskquota installation opt-in diskquota is currently built and installed by default from gpcontrib, which makes it available in all standard builds without an explicit decision to enable it. Change diskquota to an opt-in installation model by adding a dedicated `--with-diskquota` configure option that defaults to `no`. Only build, install, and run installcheck for diskquota when that option is explicitly enabled. This makes diskquota adoption an explicit choice and avoids shipping the extension by default. --- configure | 32 ++++++++++++++++++++++ configure.ac | 7 +++++ .../cloudberry/scripts/configure-cloudberry.sh | 1 + gpcontrib/Makefile | 12 ++++---- src/Makefile.global.in | 1 + 5 files changed, 48 insertions(+), 5 deletions(-) diff --git a/configure b/configure index 2143f45a93e..edce250a56d 100755 --- a/configure +++ b/configure @@ -718,6 +718,7 @@ with_libcurl with_rt PROTOC with_gp_stats_collector +with_diskquota with_zstd with_libbz2 LZ4_LIBS @@ -943,6 +944,7 @@ with_zlib with_lz4 with_zstd with_libbz2 +with_diskquota with_gp_stats_collector with_rt with_libcurl @@ -1698,6 +1700,7 @@ Optional Packages: --with-quicklz build with QuickLZ support (requires quicklz library) --without-zstd do not build with Zstandard + --with-diskquota build with diskquota extension --with-gp_stats_collector build with stats collector extension --without-rt do not use Realtime Library @@ -11414,6 +11417,35 @@ fi $as_echo "$with_zstd" >&6; } +# +# diskquota +# + + + +# Check whether --with-diskquota was given. +if test "${with_diskquota+set}" = set; then : + withval=$with_diskquota; + case $withval in + yes) + : + ;; + no) + : + ;; + *) + as_fn_error $? "no argument expected for --with-diskquota option" "$LINENO" 5 + ;; + esac + +else + with_diskquota=no + +fi + + + + # # gp_stats_collector # diff --git a/configure.ac b/configure.ac index dba10e15115..26a9e6794e8 100644 --- a/configure.ac +++ b/configure.ac @@ -1456,6 +1456,13 @@ PGAC_ARG_BOOL(with, zstd, yes, [do not build with Zstandard], AC_MSG_RESULT([$with_zstd]) AC_SUBST(with_zstd) +# +# diskquota +# +PGAC_ARG_BOOL(with, diskquota, no, + [build with diskquota extension]) +AC_SUBST(with_diskquota) + # # gp_stats_collector # diff --git a/devops/build/automation/cloudberry/scripts/configure-cloudberry.sh b/devops/build/automation/cloudberry/scripts/configure-cloudberry.sh index 90f0614bfe8..80575309092 100755 --- a/devops/build/automation/cloudberry/scripts/configure-cloudberry.sh +++ b/devops/build/automation/cloudberry/scripts/configure-cloudberry.sh @@ -162,6 +162,7 @@ execute_cmd ./configure --prefix=${BUILD_DESTINATION} \ --disable-pxf \ --enable-tap-tests \ ${CONFIGURE_DEBUG_OPTS} \ + --with-diskquota \ --with-gp-stats-collector \ --with-gssapi \ --with-ldap \ diff --git a/gpcontrib/Makefile b/gpcontrib/Makefile index b40098b4e7a..e27dd490d43 100644 --- a/gpcontrib/Makefile +++ b/gpcontrib/Makefile @@ -24,8 +24,7 @@ ifeq "$(enable_debug_extensions)" "yes" gp_legacy_string_agg \ gp_replica_check \ gp_toolkit \ - pg_hint_plan \ - diskquota + pg_hint_plan else recurse_targets = gp_sparse_vector \ gp_distribution_policy \ @@ -33,8 +32,11 @@ else gp_legacy_string_agg \ gp_exttable_fdw \ gp_toolkit \ - pg_hint_plan \ - diskquota + pg_hint_plan +endif + +ifeq "$(with_diskquota)" "yes" + recurse_targets += diskquota endif ifeq "$(with_zstd)" "yes" @@ -101,4 +103,4 @@ installcheck: $(MAKE) -C gp_sparse_vector installcheck $(MAKE) -C gp_toolkit installcheck $(MAKE) -C gp_exttable_fdw installcheck - $(MAKE) -C diskquota installcheck + if [ "$(with_diskquota)" = "yes" ]; then $(MAKE) -C diskquota installcheck; fi diff --git a/src/Makefile.global.in b/src/Makefile.global.in index b340afa5f9e..74ba8d0c370 100644 --- a/src/Makefile.global.in +++ b/src/Makefile.global.in @@ -269,6 +269,7 @@ with_zstd = @with_zstd@ ZSTD_CFLAGS = @ZSTD_CFLAGS@ ZSTD_LIBS = @ZSTD_LIBS@ EVENT_LIBS = @EVENT_LIBS@ +with_diskquota = @with_diskquota@ with_gp_stats_collector = @with_gp_stats_collector@ ########################################################################## --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
