Skip to content

Commit

Permalink
Show license version in \dx
Browse files Browse the repository at this point in the history
  • Loading branch information
konskov committed Mar 14, 2023
1 parent f8022eb commit ab8583f
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
9 changes: 7 additions & 2 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ include(GitCommands)
include(GenerateScripts)
include(CMakeDependentOption)

option(APACHE_ONLY "only compile apache code" off)
# This requires all tests to run. This defaults to OFF but can be enabled to
# ensure that no tests are skipped because of missing tools.
option(REQUIRE_ALL_TESTS "Require all tests to run." OFF)
Expand Down Expand Up @@ -386,6 +387,12 @@ set(EXT_CONTROL_FILE ${PROJECT_NAME}.control)
if(${PG_VERSION_MAJOR} GREATER "12")
set(TRUSTED trusted=true)
endif()

if(APACHE_ONLY)
set(LICENSE_MESSAGE "Apache 2 Edition")
else()
set(LICENSE_MESSAGE "Community Edition")
endif()
configure_file(${EXT_CONTROL_FILE}.in ${EXT_CONTROL_FILE})

install(FILES ${CMAKE_CURRENT_BINARY_DIR}/${EXT_CONTROL_FILE}
Expand Down Expand Up @@ -618,8 +625,6 @@ add_subdirectory(sql)
add_subdirectory(test)
add_subdirectory(src)

option(APACHE_ONLY "only compile apache code" off)

if(NOT APACHE_ONLY)
add_subdirectory(tsl)
endif()
Expand Down
2 changes: 1 addition & 1 deletion timescaledb.control.in
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# timescaledb extension
comment = 'Enables scalable inserts and complex queries for time-series data'
comment = '(@LICENSE_MESSAGE@) Enables scalable inserts and complex queries for time-series data'
default_version = '@PROJECT_VERSION_MOD@'
module_pathname = '$libdir/timescaledb-@PROJECT_VERSION_MOD@'
#extension cannot be relocatable once installed because it uses multiple schemas and that is forbidden by PG.
Expand Down

0 comments on commit ab8583f

Please sign in to comment.