Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to check version of GNU make in mac terminal?

Title says it all. I googled around but only found methods using rpm, which is not installed on my mac.

like image 555
hch Avatar asked Aug 26 '15 23:08

hch


People also ask

How do I find my Makefile version?

You can test $(MAKE_VERSION), which was added in Version 3.69 (late 1993, judging from the ftp listing) according to 'NEWS'. On a related note, I've been using this: ifeq (3.81,$(firstword $(sort $(MAKE_VERSION) 3.81))) # stuff that requires make-3.81 or higher endif and would be glad to learn a clearer method.

What is make command in Mac?

make The purpose of the make utility is to determine automatically which pieces of a large program need to be recompiled, and issue the commands to recompile them. you can use make with any programming language whose compiler can be run with a shell command.

How do I find the version of my Mac?

From the Apple menu  in the corner of your screen, choose About This Mac. You should see the macOS name, such as macOS Monterey or macOS Big Sur, followed by its version number. If you need to know the build number as well, click the version number to see it.

What is the difference between Gmake and make?

'gmake' refers specifically to GNU make. 'make' refers to the system's default make implementation; on most Linux distros this is GNU make, but on other unixes, it could refer to some other implementation of make, such as BSD make, or the make implementations of various commercial unixes.


2 Answers

The easiest way would be to run make --version. E.g., on my machine it outputs:

mureinik@computer ~$ make --version 
GNU Make 4.0
Built for x86_64-redhat-linux-gnu
Copyright (C) 1988-2013 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.
like image 93
Mureinik Avatar answered Oct 14 '22 02:10

Mureinik


To display the version, type the following in the terminal:

make -v

Which on my machine gave the following output:

GNU Make 3.81
Copyright (C) 2006  Free Software Foundation, Inc.
This is free software; see the source for copying conditions.
There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A
PARTICULAR PURPOSE.

This program built for i386-apple-darwin11.3.0
like image 34
Alexander Avatar answered Oct 14 '22 02:10

Alexander