How to force cmake to omit default LINUX pathes on FreeBSD

Dariusz Niespodziany d.niespodziany at gmail.com
Mon May 26 22:26:17 UTC 2014


Hi porters,
Does anyone know how to force cmake to look for executables in
/usr/local/bin first, not in /usr/bin?

*FIND_PROGRAM(FLEX_EXECUTABLE flex PATH /usr/local/bin DOC "path to the
flex executable" NO_DEFAULT_PATH)*

It works, but its not correct. Is there any more proper way?

FIND_PROGRAM uses "which" to get executable path. PATH variable is fetched,
but overriding $PATH is also not that proper.

Regards
niespodd


More information about the freebsd-ports mailing list