FindPostgreSQL: Add brew-style directories to search path

As of 14.5, homebrew names PostgreSQL directories with the version
number, e.g., `postgresql@14`.
This commit is contained in:
parkesb authored and Brad King committed 2022-08-31 10:37:13 -04:00
1 parent 3aebeb1b55
commit f799e0f23d
1 file changed
+3
+3
View File
@@ -121,13 +121,16 @@ foreach(suffix ${PostgreSQL_KNOWN_VERSIONS})
if(UNIX)
list(APPEND PostgreSQL_LIBRARY_ADDITIONAL_SEARCH_SUFFIXES
"postgresql${suffix}"
"postgresql@${suffix}"
"pgsql-${suffix}/lib")
list(APPEND PostgreSQL_INCLUDE_ADDITIONAL_SEARCH_SUFFIXES
"postgresql${suffix}"
"postgresql@${suffix}"
"postgresql/${suffix}"
"pgsql-${suffix}/include")
list(APPEND PostgreSQL_TYPE_ADDITIONAL_SEARCH_SUFFIXES
"postgresql${suffix}/server"
"postgresql@${suffix}/server"
"postgresql/${suffix}/server"
"pgsql-${suffix}/include/server")
endif()