[cmake-developers] How to speed up CMake configuration on macOS

Gregor Jasny gjasny at googlemail.com
Sat Mar 23 10:07:39 EDT 2019


Hello,

in the past when building CMake (itself) I spent long times waiting for 
configuration of the embedded libraries. Mostly libcurl send / receive 
signature detection. Today I had the idea of using system libraries 
installed with Homebrew and the speedups are quite noticeable:

You first need to install all required packages:

brew install curl expat jsoncpp libarchive rhash libuv xz zstd

Then configure with:
   -DCMAKE_USE_SYSTEM_LIBRARIES=ON
   -DLibArchive_ROOT=$(brew --prefix libarchive)

Speeup:

           embedded    system
   Ninja       103s       14s
   Xcode       749s       67s

Cheers,
Gregor


More information about the cmake-developers mailing list