-
Notifications
You must be signed in to change notification settings - Fork 1
Building the prerequisites on MacOS X
Homebrew can install the most of the required general-purpose development tools, e.g.,
- autoconf
- automake
- libtool
- cmake
- ...
If some tool or library is obsolete or missing on the system, trying to get it installed by Homebrew may be the fastest option.
Be aware that, for proper functioning, brew
tool may require setting the correct proxies in your shell (Terminal), via http_proxy
and https_proxy
variables.
Please consult man brew
for more information.
To install GNU C, C++, and Fortran compilers and libraries, Homebrew may be used:
brew install gcc
Alternatively, see Installing GCC page how to install GCC from the source distribution. I have used the latest development sources from the SVN (trunk) to successfully bootstrap the compilers. In essence, the procedure is to:
- Checkout the SVN sources.
- Download the missing prerequisites (if not already installed on the system), by invoking
./contrib/download_prerequisites
from the top-level directory of a working copy created in step 1. -
Configure the build. To avoid any clashes with the system's
gcc
driver, or with a possible Homebrew GCC installation, etc., saying./configure --prefix=$GCC_HOME
, whereGCC_HOME
is set to a sub-directory of the user's$HOME
, may be a reasonable choice. - Say
make bootstrap
and thenmake install-strip
. - Be sure to prepend
$GCC_HOME/bin
toPATH
,$GCC_HOME/lib
toDYLD_LIBRARY_PATH
, and (optionally)$GCC_HOME/share/man
toMANPATH
, in order to use the newly built compilers, instead of those already present on the system.
Downloading and installing CUDA Toolkit should be straightforward. Afterwards:
- Please make sure that you export a variable
CUDADIR
with the contents/Developer/NVIDIA/CUDA-X.Y
, whereX=8
andY=0
in the case of 8.0 (Release Candidate), orX=7
andY=5
in the case of 7.5 (Release) CUDA versions. - With such a definition, add
$CUDADIR/bin
toPATH
,$CUDADIR/lib
toDYLD_LIBRARY_PATH
, and (optionally)$CUDADIR/doc/man
toMANPATH
.
TBD