[CMake] advice for resolving errors with CMake 3.8

Stephen McDowell sjm324 at cornell.edu
Thu May 3 10:02:49 EDT 2018


If you don't want to have to keep switching to Windows and back to test,
the most reliable way to know with absolute certainty is to install CMake
3.8 on OSX and use that.

Fortunately building cmake is actually quite easy, you can even use the
newer cmake from brew to configure the older one (use cmake to build
cmake!).

Make sure you set CMAKE_INSTALL_PREFIX to somewhere you know about (e.g.
/opt/cmake-3.8). When you need to test this project, update your path to
point there

export PATH="/opt/cmake-3.8/bin:$PATH"

You need to run that export command for every terminal, or put it in your
~/.bashrc while developing this project.

If you don't set CMAKE_INSTAL_PREFIX, `make install` will put it in
/usr/local by default which will make it more challenging to uninstall in
the future when you want to use cmake 3.11 from brew. Putting it in /opt
makes it so you can just delete that entire /opt/cmake-3.8 folder and/or
comment out the export command in your ~/.bashrc (making sure to launch a
new terminal and verify cmake --version after editing your ~/.bashrc).
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://cmake.org/pipermail/cmake/attachments/20180503/8fc243f2/attachment.html>


More information about the CMake mailing list