Skip to content

Commit c2269db

Browse files
committed
Fix extension comment for generic loader package
When building apt or rpm packages we build a separate loader package that will be used by both the apache and community editions. Having the edition in the description would be misleading so we remove it for these cases.
1 parent a60d305 commit c2269db

File tree

3 files changed

+12
-4
lines changed

3 files changed

+12
-4
lines changed

.unreleased/pr_7201

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
Fixes: #7201 Use generic extension description when building apt and rpm loader packages
2+
Thanks: @posuch For reporting misleading extension description in the generic loader package

CMakeLists.txt

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -398,10 +398,16 @@ endif(PG_SOURCE_DIR)
398398

399399
set(EXT_CONTROL_FILE ${PROJECT_NAME}.control)
400400

401-
if(APACHE_ONLY)
402-
set(LICENSE_EDITION "Apache 2 Edition")
401+
# When building apt or rpm packages we build a separate loader package that will
402+
# be used by both the apache and community editions. Having the edition in the
403+
# description would be misleading so we remove it for these cases.
404+
set(GENERIC_LOADER_METHOD apt rpm)
405+
if(PROJECT_INSTALL_METHOD IN_LIST GENERIC_LOADER_METHOD)
406+
set(COMMENT_SUFFIX "")
407+
elseif(APACHE_ONLY)
408+
set(COMMENT_SUFFIX " (Apache 2 Edition)")
403409
else()
404-
set(LICENSE_EDITION "Community Edition")
410+
set(COMMENT_SUFFIX " (Community Edition)")
405411
endif()
406412
configure_file(${EXT_CONTROL_FILE}.in ${EXT_CONTROL_FILE})
407413

timescaledb.control.in

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
# timescaledb extension
2-
comment = 'Enables scalable inserts and complex queries for time-series data (@LICENSE_EDITION@)'
2+
comment = 'Enables scalable inserts and complex queries for time-series data@COMMENT_SUFFIX@'
33
default_version = '@PROJECT_VERSION_MOD@'
44
module_pathname = '$libdir/timescaledb-@PROJECT_VERSION_MOD@'
55
#extension cannot be relocatable once installed because it uses multiple schemas and that is forbidden by PG.

0 commit comments

Comments
 (0)