Skip to content

Commit 70a9890

Browse files
authored
Merge pull request #1324 from joto/postgres-fixes
Postgres fixes
2 parents fd17511 + 8c72b2c commit 70a9890

2 files changed

Lines changed: 9 additions & 2 deletions

File tree

.github/actions/build-and-test/action.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ runs:
1616

1717
- name: configure
1818
run: |
19-
CMAKE_OPTIONS="-DPostgreSQL_TYPE_INCLUDE_DIR=/usr/include -LA -DBUILD_TESTS=ON"
19+
CMAKE_OPTIONS="-LA -DBUILD_TESTS=ON"
2020
if [ -z "${LUA_VERSION}" ]; then
2121
CMAKE_OPTIONS="$CMAKE_OPTIONS -DWITH_LUA=OFF"
2222
else

CMakeLists.txt

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,10 +52,17 @@ option(EXTERNAL_LIBOSMIUM "Do not use the bundled libosmium" OFF)
5252
option(EXTERNAL_PROTOZERO "Do not use the bundled protozero" OFF)
5353
option(EXTERNAL_FMT "Do not use the bundled fmt" OFF)
5454

55+
if (NOT WIN32 AND NOT APPLE)
56+
# No need for this path, just a workaround to make cmake work on all systems.
57+
# Without this we need the PostgreSQL server libraries installed.
58+
# https://stackoverflow.com/questions/13920383/findpostgresql-cmake-wont-work-on-ubuntu
59+
set(PostgreSQL_TYPE_INCLUDE_DIR /usr/include)
60+
endif()
61+
5562
set(MINIMUM_POSTGRESQL_SERVER_VERSION "9.3")
5663
set(MINIMUM_POSTGRESQL_SERVER_VERSION_NUM "90300")
5764

58-
set(PostgreSQL_ADDITIONAL_VERSIONS "9.3" "9.4" "9.5" "9.6" "10" "11" "12" "13")
65+
set(PostgreSQL_ADDITIONAL_VERSIONS "13" "12" "11" "10" "9.6" "9.5" "9.4" "9.3")
5966

6067
#############################################################
6168
# Version

0 commit comments

Comments
 (0)