I had to install Gnuplot today on OS X Mavericks. To do so, I used homebrew, which is an easy way to install the missing packages from OSX, and that I need to work. After typing in the following command in my terminal :
1 |
brew install gnuplot |
I obtained the following error :
1 2 3 |
==> Summary /usr/local/Cellar/jpeg/8d: 18 files, 780K Error: You must `brew link libpng jpeg' before gd can be installed |
I tried to link the the libraries, but unfortunately I obtained this error :
1 2 3 4 5 |
$ brew link libpng jpeg Linking /usr/local/Cellar/libpng/1.5.14... Warning: Could not link libpng. Unlinking... Error: Could not symlink file: /usr/local/Cellar/libpng/1.5.14/include/pnglibconf.h /usr/local/include is not writable. You should change its permissions. |
I then tried with ‘sudo’ and obtained another ‘error’ :
1 2 3 4 5 6 |
$ sudo brew link libpng jpeg Password: Error: Cowardly refusing to `sudo brew link` You can use brew with sudo, but only if the brew executable is owned by root. However, this is both not recommended and completely unsupported so do so at your own risk. |
This is an easy fix to solve the problem and install GnuPlot without errors :
(There are some other solutions out there, but that are way more complicated than this one)
- Type the following commands in your Terminal
1 |
$ sudo chmod 777 /usr/local/include/ |
1 |
$ sudo chmod 777 /usr/local/lib |
- Install Gnuplot with the following command
1 |
$ brew install gnuplot --cairo --latex --with-x --tests |
- Restore the rights on the ‘include’ and ‘lib’ folders
1 |
$ sudo chmod 755 /usr/local/lib |
1 |
$ sudo chmod 755 /usr/local/include/ |
You can now use GnuPlot on OS X Mavericks.
Note : If you have any problems, please check the comments + if you found a solution to a problem, please post it as a comment for future users. Thanks to all the people who contribute and contributed in the comments.
{ 1 } Trackback
[…] des Terminals oder der Eingabeaufforderung eingehen. Denn es gibt sowohl für MacOS (auch als brew), Linux (hier exemplarisch Ubuntu)und sogar Windows gute Tutorials. Hier möchte ich nur auf die […]
Post a Comment