macOS - install GNU make, cmake


about cmake


install using brew



brew install make 

will be installed /usr/local/Cellar/cmake/under and linked to/usr/local/bin


/usr/local/Cellar/cmake/3.23.2/bin There are the following four executable files under

  • ccmake
  • cmake
  • cpack
  • ctest

View version information

cmake --version

gets returned as follows

cmake version 3.23.2

CMake suite maintained and supported by Kitware (kitware.com/cmake).

About GNU make


Method 1: brew

Visible brew official documentation: https://formulae.brew.sh/formula/make

brew install make

The installation package will be located /usr/local/Cellar/makeat the executable file /usr/local/Cellar/make/4.3/bin/gmake, which is linked to/usr/local/bin/gmake


Get version information:

gmake --version

GNU Make 4.3
Built for x86_64-apple-darwin21.1.0
Copyright (C) 1988-2020 Free Software Foundation, Inc.
License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>
This is free software: you are free to change and redistribute it.
There is NO WARRANTY, to the extent permitted by law.

Method 2: Download the source code


Here I download: make-4.3.tar.gz
get the compressed package, after decompression, enter the folder, execute the following command:

./configure
make 
sudo make install

Executable files are available:/usr/local/bin/make


View version information:

/usr/local/bin/make --version

get

GNU Make 4.3
为 x86_64-apple-darwin22.5.0 编译
Copyright (C) 1988-2020 Free Software Foundation, Inc.
许可证:GPLv3+:GNU 通用公共许可证第 3 版或更新版本<http://gnu.org/licenses/gpl.html>。
本软件是自由软件:您可以自由修改和重新发布它。
在法律允许的范围内没有其他保证

Iori 2023-08-14

Guess you like

Origin blog.csdn.net/lovechris00/article/details/132282795