Mac OS comes with make version 3.81 and I want a newer version (>=4.0) for use on some projects.
How can I install a newer version, preferably using brew?
That's related to GNU Make --output-sync doesn't work? as I want to use some feature output sync on parallel builds.
brew ships a make in the homebrew/dupes tap. brew install homebrew/dupes/make puts a gmake binary in the PATH to avoid clashes with the default make version on macOS.
The option --with-default-names will install as make and thus shadow the default version.
See brew info homebrew/dupes/make for more details.
homebrew/dupes/make: stable 4.2.1 (bottled)
Utility for directing compilation
https://www.gnu.org/software/make/
/usr/local/Cellar/make/4.2.1 (12 files, 957.3K) *
Poured from bottle on 2016-08-11 at 20:18:41
From: https://github.com/Homebrew/homebrew-dupes/blob/master/make.rb
==> Dependencies
Optional: guile ✘
==> Options
--with-default-names
Do not prepend 'g' to the binary
--with-guile
Build with guile support
Related
I was able to install Homebrew + nginx + rtmp in macOS High Sierra 10.13. Now I want do the same on macOS Mojave 10.14.
So let's start ... istallation of Homebrew, first we need Xcode in terminal...
xcode-select –install
than. We need homebrew
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)"
than install nginx + rtmp
And here's the problem
I tried:
brew install nginx-full --with-rtmp-module
but it won't work
the result:
Updating Homebrew...
Usage: brew install [options] formula
Install formula. Additional options specific to formula may be appended to the command.
Unless HOMEBREW_NO_INSTALL_CLEANUP is set, brew cleanup will then be run for
the installed formulae or, every 30 days, for all formulae.
-d, --debug If brewing fails, open an interactive
debugging session with access to IRB or a
shell inside the temporary build directory.
--env If std is passed, use the standard build
environment instead of superenv. If super
is passed, use superenv even if the formula
specifies the standard build environment.
--ignore-dependencies An unsupported Homebrew development flag to
skip installing any dependencies of any
kind. If the dependencies are not already
present, the formula will have issues. If
you're not developing Homebrew, consider
adjusting your PATH rather than using this
flag.
--only-dependencies Install the dependencies with specified
options but do not install the formula
itself.
--cc Attempt to compile using the specified
compiler, which should be the name of the
compiler's executable, e.g. gcc-7 for GCC
7. In order to use LLVM's clang, specify
llvm_clang. To use the Apple-provided
clang, specify clang. This option will
only accept compilers that are provided by
Homebrew or bundled with macOS. Please do
not file issues if you encounter errors
while using this option.
-s, --build-from-source Compile formula from source even if a
bottle is provided. Dependencies will still
be installed from bottles if they are
available.
--force-bottle Install from a bottle if it exists for the
current or newest version of macOS, even if
it would not normally be used for
installation.
--include-test Install testing dependencies required to
run brew test formula.
--devel If formula defines it, install the
development version.
--HEAD If formula defines it, install the HEAD
version, aka. master, trunk, unstable.
--fetch-HEAD Fetch the upstream repository to detect if
the HEAD installation of the formula is
outdated. Otherwise, the repository's HEAD
will only be checked for updates when a new
stable or development version has been
released.
--keep-tmp Retain the temporary files created during
installation.
--build-bottle Prepare the formula for eventual bottling
during installation, skipping any
post-install steps.
--bottle-arch Optimise bottles for the specified
architecture rather than the oldest
architecture supported by the version of
macOS the bottles are built on.
-f, --force Install without checking for previously
installed keg-only or non-migrated
versions.
-v, --verbose Print the verification and postinstall
steps.
--display-times Print install times for each formula at the
end of the run.
-i, --interactive Download and patch formula, then open a
shell. This allows the user to run
./configure --help and otherwise
determine how to turn the software package
into a Homebrew package.
-g, --git Create a Git repository, useful for
creating patches to the software.
-h, --help Show this message.
Error: invalid option: --with-rtmp-module
so i tried:
brew install nginx --with-rtmp-module
but.....result:
Updating Homebrew...
Error: No available formula with the name "–with-rtmp-module"
==> Searching for a previously deleted formula (in the last month)...
Error: No previously deleted formula found.
==> Searching for similarly named formulae...
Error: No similarly named formulae found.
==> Searching taps...
==> Searching taps on GitHub...
Error: No formulae found in taps.
so I decided to try install nginx first and than rtmp module
brew install nginx
and than i tried:
brew install nginx libnginx-mod-rtmp (copying from Linux)
brew install rtmp-module
brew install module-rtmp
But none of the above worked. How do I resolve it?
You should tap a nginx formulae before try install nginx-full
Well you can try denji/nginx, since homebrew/nginx tap has been deprecated, That's:
brew tap denji/nginx
then
brew install nginx-full --with-rtmp-module
That works for me.
I am having a problem where I can't specify options for installing a formula with brew.
Specifically
brew install gnuplot --with-qt results in a invalid option: --with-qt and when I look at brew info gnuplot there is no option available:
$ brew info gnuplot
gnuplot: stable 5.2.6 (bottled), HEAD
Command-driven, interactive function plotting
http://www.gnuplot.info/
Not installed
From: https://github.com/Homebrew/homebrew-core/blob/master/Formula/gnuplot.rb
==> Dependencies
Build: pkg-config ✔
Required: gd ✔, libcerf ✔, lua ✔, pango ✔, qt ✔, readline ✔
==> Options
--HEAD
Install HEAD version
However, I get all indication from the documentation, and thousands of Andrew Ng's machine learning course students that there are some optional flags I could specify. I've tried all sorts of updating and upgrading, and nothing under brew doctor seems to be relevant. I've installed very many things with brew in the past (though ultimately I'm not very sure of the inner workings)
$ brew --version
Homebrew 2.0.1
Homebrew/homebrew-core (git revision 1204; last commit 2019-02-09)
Homebrew/homebrew-cask (git revision 8d29a; last commit 2019-02-09)
mac os 10.14.2 Mojave
Any ideas on where to start investigating would be helpful.
Unfortunately, options have been removed recently, more about it can be found here: Remove all options from Homebrew/homebrew-core formulae
My recommendation would be to use MacPorts as it's generally much easier to install.
$ port variant gnuplot
gnuplot has the variants:
[+]aquaterm: Enable AquaTerm terminal
[+]luaterm: Enable lua-based terminals
old_bitmap_terminals: Enable PBM (Portable Bit Map) and other older bitmap terminals
[+]pangocairo: Enable cairo-based terminals
qt: Enable qt terminal with Qt 4
* conflicts with qt5
qt5: Enable qt terminal with Qt 5
* conflicts with qt
universal: Build for multiple architectures
[+]wxwidgets: Enable wxt terminal
[+]x11: Enable X11 support
Note: In the description it states that qt conflicts with qt5, so you'll want to use one or the other.
So based upon that output you can see there are several "variants" available to install. To use qt:
$ sudo port install gnuplot +qt
If you also wanted to install x11 with qt you could do:
$ sudo port install gnuplot +qt +x11
For now, the option --with-qt is applied by default when you do brew install gnuplot.
As you can see in the following source code of gnuplot hombrew formula.
args = %W[
--disable-dependency-tracking
--disable-silent-rules
--prefix=#{prefix}
--with-readline=#{Formula["readline"].opt_prefix}
--without-tutorial
--disable-wxwidgets
--with-qt
--without-x
]
system "./configure", *args
This can be changed in the future. You can check the source code of gnuplot formula here:
https://github.com/Homebrew/homebrew-core/blob/master/Formula/gnuplot.rb
I cannot install Valgrind on macOS High Sierra. It's not available through brew. I've tried with 3.10. After make install, I get this message:
configure: error: Valgrind works on Darwin 10.x, 11.x, 12.x, 13.x and 14.x (Mac OS X 10.6/7/8/9/10)
Homebrew says:
valgrind: This formula either does not compile or function as expected on macOS
versions newer than Sierra due to an upstream incompatibility.
Error: An unsatisfied requirement failed this build.
I had the problem like this.
So, I found the solving. You should install valgrind by this code
brew install --HEAD valgrind
I have created a port of valgrind 3.13.0 to work on macOS High Sierra (10.13.x). You can get it here: https://github.com/padiakalpesh/valgrind_3.13_high_sierra
Once you have obtained the source, run the following commands from inside the source directory:
./configure
make
sudo make install
brew install Valgrind has some compatibility problem when installing on latest macOS but there is a workaround with this problem. You must be getting this error message when you try to install it using brew.
$brew install valgrind
valgrind: This formula either does not compile or function as expected on macOS
versions newer than High Sierra due to an upstream incompatibility.
Error: An unsatisfied requirement failed this build.
-------------------------------------------------------------------SOLUTION--------------------------------------------------------------
Step1: $brew edit valgrind
Step2: Find this line in the file ->(url "https://sourceware.org/git/valgrind.git")
Step3: Replace it with -> (url "git://sourceware.org/git/valgrind.git")
Step4: $brew update
Step5: $brew install --HEAD valgrind
And Done!
Let me know if it still doesn't work.
Thanks!!
I have got this working in July 2018, for reference:
https://gist.github.com/AlessandroMinali/d8316d6cc650c97027433644c2ff31ee
Edit ./configure
- 5468: applellvm-5.1|applellvm-6.*|applellvm-7.*|applellvm-8.*)
+ 5468: applellvm-5.1|applellvm-6.*|applellvm-7.*|applellvm-8.*|applellvm-9.*)
- 5879: 16.*)
+ 5879: 17.*)
Run
./autogen.sh
./configure
make
make install
Create file ~/.valgrind.supp
# false positive for any executable (it seems)
# macOS 10.12.6
# valgrind 3.13.0
{
libtrace initialization false positive
Memcheck:Param
msg->desc.port.name
fun:mach_msg_trap
fun:mach_msg
fun:task_set_special_port
fun:_os_trace_create_debug_control_port
fun:_libtrace_init
}
Create file ~/.valgrindrc
--suppressions=$HOME/.valgrind.supp
Troubleshooting
if can not read suppresion file copy and paste the contents of $HOME
if it complains about clang versions, bump the first edit up
if it complains about Darwin version, bump the second edit up
using the brew install --HEAD valgrind also worked for me, but be sure to know that it will take awhile to pull the HEAD version, and build/install.
However, no other changes were needed.
I build the git head version of Valgrind on macOS fairly regularly. If you have xcode installed then there isn't much more to it than following the instructions here.
I'll update with my build script later.
As an alternative, you might want to consider clang sanitizers. This can be enabled in xcode, or with the -fsanitize=X option (where X is address, undefined, thread, memory and a few others).
Valgrind is a rather touchy piece of software, and requires updates for each major release of macOS.
As of February 2018, there is no released version of Valgrind which supports macOS High Sierra (10.13). You will need to use a development version of Valgrind, or use alternate tools. (Apple's Instruments may have some of the functionality you are looking for.)
MacPorts version started working for me in Sep 2018!
The command, for completeness sake (completes very fast - apparently, prebuilt):
sudo port install valgrind-devel
Version:
$ valgrind --version
valgrind-3.14.0.GIT
The following worked for me using the latest Valgrind release 3.14.0 (9th October 2018) on macOS 10.13.6.
VERSION="3.14.0"
wget -O - http://www.valgrind.org/downloads/valgrind-"$VERSION".tar.bz2 | tar xjf -
cd valgrind-"$VERSION"
# use --prefix=/path/to if you want it installed somewhere in particular
./configure
make
# may need sudo
make install
# test all is working
valgrind ls -l
These instructions are taken from the README inside the Valgrind release tar ball.
On my Mac OS X 10.9 Mavericks I have lua already installed:
MacBook-Pro-Dmitri:~ dmitri$ lua
Lua 5.1.5 Copyright (C) 1994-2012 Lua.org, PUC-Rio
I want to upgrade it to latest 5.2.2 version..
Unfortunately brew throws an error when I'm trying to do this:
MacBook-Pro-Dmitri:~ dmitri$ brew install lua
Warning: lua-5.1.5 already installed
or:
MacBook-Pro-Dmitri:~ dmitri$ brew upgrade lua
Error: lua-5.1.5 already installed
Does this mean that I need to update only with building it myself?
Did somebody solve this issue on his/her machine?
Thanks!
5.2.2 is the latest, do yourself a favour and forget brew
wget http://www.lua.org/ftp/lua-5.2.2.tar.gz
tar -zxvf lua-5.2.2.tar.gz
cd lua-5.2.2
make macosx
sudo make install
That certainly sounds like brew does not have lua 5.2.2 available under the lua name.
That being said about two minutes worth of searching on google and reading around (to be fair I had to read the lua.rb formula but it was in a comment nearly at the very top of the file) found that there is a lua5.2 version in Homebrew-Versions.
So what I've done is:
I checked that brew already installed lua 5.1.5 and highlight is requiring it..
I installed lua 5.2.1 as:
brew install lua52
and linked it like:
brew link lua52
brew doctor is saying everythings ok and terminal runs lua version 5.2.1:
MacBook-Pro-Dmitri:bin dmitri$ lua
Lua 5.2.1 Copyright (C) 1994-2012 Lua.org, PUC-Rio
I'm not sure that my solving was correct, so put your comments please!
This is my first time trying to compile source code in terminal (I installed gimp using macPorts but this could be part of the problem...?)
I want to install fontforge and I was following these instructions how to install fontforge.
I got this warning while installing brew:
Warning: The following *evil* dylibs exist in /usr/local/lib
They may break builds or worse. You should consider deleting them:
/usr/local/lib/libssl.0.9.8.dylib
I could not find usr/local/lib and the only libssl file was in opt/local/lib called libssl.1.0.0.dylib which is supposed to be hidden apparently...
I made it to the "brew install cairo --use-clang" step, then when I try the "brew install fontforge --use-gcc" step I get the following warning:
Warning: It appears you have MacPorts or Fink installed.
Software installed with other package managers causes known problems for
Homebrew. If a formula fails to build, uninstall MacPorts/Fink and try again.
==> Installing fontforge dependency: gettext
Error: GCC could not be found
when I check gcc version I get:
:~ me$ gcc --V
i686-apple-darwin11-llvm-gcc-4.2: no input files
Do I need to uninstall macports (then re-install gimp?)
I read gcc comes with xcode, I have xcode 4.3 (upgraded after this issue but didn't fix it) so do I have gcc or not? is there another way to check etc.
Can anyone tell me what I am doing wrong (what I broke etc)?
NOTE I also have flashbuilder which has a program called gcc as well (I dont know if this broke the other gcc...)