I have a piece of software that relies on a particular version of GEOS and GDAL (ie newer than the one installed on the system). I've installed the particular versions with prefix /opt/hhd. The problem is that there already is both GDAL and GEOS installed, and those get included first.
How can I force CMake to use this location to include headers, instead of /usr/local?
I was trying the BEFORE / AFTER keywords. But that didn't help:
include_directories(
/opt/hhd/geos/include
/opt/hhd/gdal/include
...
)
I was also trying -iprefix with above folders.