From e4963256e1769cf56187d12c0b26b8be61e69b75 Mon Sep 17 00:00:00 2001 From: Sarah Hoffmann Date: Tue, 24 May 2016 00:24:23 +0200 Subject: [PATCH] cmake: use explicit VPATH when calling pgxs makefile Some postgres installations report problems with the makefile magic that should look for the source where the Makefile is located. So hand in the path explicitly via VPATH instead. Fixes #453. --- module/CMakeLists.txt | 2 +- module/Makefile | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/module/CMakeLists.txt b/module/CMakeLists.txt index 5e507a9e..4dfc477c 100644 --- a/module/CMakeLists.txt +++ b/module/CMakeLists.txt @@ -1,6 +1,6 @@ # just use the pgxs makefile ADD_CUSTOM_COMMAND( OUTPUT ${CMAKE_CURRENT_SOURCE_DIR}/dummy - COMMAND PGXS=${PGXS} PG_CONFIG=${PG_CONFIG} make -f ${CMAKE_CURRENT_SOURCE_DIR}/Makefile + COMMAND PGXS=${PGXS} PG_CONFIG=${PG_CONFIG} MODSRCDIR=${CMAKE_CURRENT_SOURCE_DIR} make -f ${CMAKE_CURRENT_SOURCE_DIR}/Makefile COMMENT "Running external makefile ${PGXS}" ) diff --git a/module/Makefile b/module/Makefile index 783a6602..78b395a5 100644 --- a/module/Makefile +++ b/module/Makefile @@ -1,4 +1,5 @@ MODULES = nominatim +VPATH = $(MODSRCDIR) include $(PGXS) all: