Compiling on MacOSX: Difference between revisions

From GRASS-Wiki
Jump to navigation Jump to search
No edit summary
(cleanup; uptodate notes in source)
Line 1: Line 1:
To build Grass from source you can use the frameworks that are on :
Up-to-date compilation instructions are maintained in the source <tt>macosx/ReadMe.rtf</tt>.
http://www.kyngchaos.com/software/unixport/frameworks
This builds a double-clickable application with "aqua" options where possible (Tcl/Tk, Python, OpenGL,...)
great thanks to W.Kyngesbury
and leaves out obscure X11-only-based features that have newer system-agnostic options (like motif/xganim),
though these newer features may not be quite as fully-featured, yet.
The X11 display system ''is'' included, since it is simple to include and is still quite useful.


after install the "all frameworks" you can add some library such "motif" needed by Xganim, using fink or build the source code
The method below is for the older X11-based compilation, and includes the X11 motif-based xganim.


install from source the tcl-tk library : http://www.tcl.tk/software/tcltk/downloadnow84.tml  in /usr/local
To build Grass from source you can use the frameworks that are on :  
http://www.kyngchaos.com/software:frameworks
great thanks to W.Kyngesburye.


download a cvs version http://grass.itc.it/download/index.php
After installing all the frameworks you can add some library such "motif" needed by Xganim, using fink or build the source code


then configure and make grass cvs :
Install from source the tcl-tk library : http://www.tcl.tk/software/tcltk/downloadnow84.tml  in /usr/local


cd /path_to_grass_source
Postgres can be easily compiled from source.


./configure --prefix=/usr/local --enable-sysv --with-x --with-opengl=x11 --without-odbc --with-cxx --with-freetype
Download a cvs version http://grass.itc.it/download/index.php


--with-freetype-includes=/Library/Frameworks/FreeType.framework/unix/include
Then configure and make grass cvs :


--with-freetype-libs=/Library/Frameworks/FreeType.framework/unix/lib
<pre>
cd /path_to_grass_source


--with-gdal=/Library/Frameworks/GDAL.framework/Versions/1.5/Programs/gdal-config  
./configure --enable-sysv --with-x --with-opengl=x11 --without-odbc --with-cxx --with-freetype \
 
--with-freetype-includes=/Library/Frameworks/FreeType.framework/unix/include \
--with-proj-includes=/Library/Frameworks/PROJ.framework/unix/include  
--with-freetype-libs=/Library/Frameworks/FreeType.framework/unix/lib \
 
--with-gdal=/Library/Frameworks/GDAL.framework/Versions/1.5/Programs/gdal-config \
--with-proj-libs=/Library/Frameworks/PROJ.framework/unix/lib  
--with-proj-includes=/Library/Frameworks/PROJ.framework/unix/include \
 
--with-proj-libs=/Library/Frameworks/PROJ.framework/unix/lib \
--with-proj-share=/Library/Frameworks/PROJ.framework/Versions/4.5/unix/share/  
--with-proj-share=/Library/Frameworks/PROJ.framework/Versions/4.5/unix/share/ \
 
--with-jpeg --with-jpeg-includes=/Library/Frameworks/UnixImageIO.framework/unix/include \
--with-jpeg --with-jpeg-includes=/Library/Frameworks/UnixImageIO.framework/unix/include  
--with-jpeg-libs=/Library/Frameworks/UnixImageIO.framework/unix/lib \
 
--with-tiff --with-tiff-includes=/Library/Frameworks/UnixImageIO.framework/unix/include \
--with-jpeg-libs=/Library/Frameworks/UnixImageIO.framework/unix/lib  
--with-tiff-libs=/Library/Frameworks/UnixImageIO.framework/unix/lib \
 
--with-png-includes=/Library/Frameworks/UnixImageIO.framework/unix/include \
--with-tiff --with-tiff-includes=/Library/Frameworks/UnixImageIO.framework/unix/include  
--with-png-libs=/Library/Frameworks/UnixImageIO.framework/unix/lib \
 
--with-sqlite --with-sqlite-libs=/Library/Frameworks/SQLite3.framework/unix/lib \
--with-tiff-libs=/Library/Frameworks/UnixImageIO.framework/unix/lib  
--with-sqlite-includes=/Library/Frameworks/SQLite3.framework/unix/include \
 
--with-fftw --with-fftw-includes=/Library/Frameworks/FFTW3.framework/unix/include \
--with-png-includes=/Library/Frameworks/UnixImageIO.framework/unix/include  
--with-fftw-libs=/Library/Frameworks/FFTW3.framework/unix/lib \
 
--with-postgres-includes=/usr/local/pgsql/include --with-postgres-libs=/usr/local/pgsql/lib \
--with-png-libs=/Library/Frameworks/UnixImageIO.framework/unix/lib  
--with-freetype --with-freetype-includes=/Library/Frameworks/FreeType.framework/unix/include \
 
--with-freetype-libs=/Library/Frameworks/FreeType.framework/unix/lib --with-python --with-readline \
--with-sqlite --with-sqlite-libs=/Library/Frameworks/SQLite3.framework/unix/lib  
--with-readline-includes=/sw/include/readline --with-readline-libs=/sw/lib --with-tcltk-includes=/usr/local/include \
 
--with-tcltk-libs=/usr/local/lib --with-blas --with-lapack \
--with-sqlite-includes=/Library/Frameworks/SQLite3.framework/unix/include  
--with-blas-includes=/System/Library/Frameworks/Accelerate.framework/Frameworks/vecLib.framework/Headers \
--with-lapack-includes=/System/Library/Frameworks/Accelerate.framework/Frameworks/vecLib.framework/Headers \
--with-motif --with-motif-includes=/sw/include --with-motif-libs=/sw/lib --with-glw


--with-fftw --with-fftw-includes=/Library/Frameworks/FFTW3.framework/unix/include
make
 
sudo make install
--with-fftw-libs=/Library/Frameworks/FFTW3.framework/unix/lib
</pre>
 
--with-postgres-includes=/usr/local/pgsql/include --with-postgres-libs=/usr/local/pgsql/lib
 
--with-freetype --with-freetype-includes=/Library/Frameworks/FreeType.framework/unix/include
 
--with-freetype-libs=/Library/Frameworks/FreeType.framework/unix/lib --with-python --with-readline
 
--with-readline-includes=/sw/include/readline --with-readline-libs=/sw/lib --with-tcltk-includes=/usr/local/include
 
--with-tcltk-libs=/usr/local/lib
 
--with-blas --with-blas-libs=/System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/
 
--with-lapack --with-lapack-libs=/System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/
 
--with-motif --with-motif-includes=/sw/include --with-motif-libs=/sw/lib --with-glw

Revision as of 04:24, 12 March 2009

Up-to-date compilation instructions are maintained in the source macosx/ReadMe.rtf. This builds a double-clickable application with "aqua" options where possible (Tcl/Tk, Python, OpenGL,...) and leaves out obscure X11-only-based features that have newer system-agnostic options (like motif/xganim), though these newer features may not be quite as fully-featured, yet. The X11 display system is included, since it is simple to include and is still quite useful.

The method below is for the older X11-based compilation, and includes the X11 motif-based xganim.

To build Grass from source you can use the frameworks that are on : http://www.kyngchaos.com/software:frameworks great thanks to W.Kyngesburye.

After installing all the frameworks you can add some library such "motif" needed by Xganim, using fink or build the source code

Install from source the tcl-tk library : http://www.tcl.tk/software/tcltk/downloadnow84.tml in /usr/local

Postgres can be easily compiled from source.

Download a cvs version http://grass.itc.it/download/index.php

Then configure and make grass cvs :

cd /path_to_grass_source

./configure --enable-sysv --with-x --with-opengl=x11 --without-odbc --with-cxx --with-freetype \
--with-freetype-includes=/Library/Frameworks/FreeType.framework/unix/include \
--with-freetype-libs=/Library/Frameworks/FreeType.framework/unix/lib \
--with-gdal=/Library/Frameworks/GDAL.framework/Versions/1.5/Programs/gdal-config \
--with-proj-includes=/Library/Frameworks/PROJ.framework/unix/include \
--with-proj-libs=/Library/Frameworks/PROJ.framework/unix/lib \
--with-proj-share=/Library/Frameworks/PROJ.framework/Versions/4.5/unix/share/ \
--with-jpeg --with-jpeg-includes=/Library/Frameworks/UnixImageIO.framework/unix/include \
--with-jpeg-libs=/Library/Frameworks/UnixImageIO.framework/unix/lib \
--with-tiff --with-tiff-includes=/Library/Frameworks/UnixImageIO.framework/unix/include \
--with-tiff-libs=/Library/Frameworks/UnixImageIO.framework/unix/lib \
--with-png-includes=/Library/Frameworks/UnixImageIO.framework/unix/include \
--with-png-libs=/Library/Frameworks/UnixImageIO.framework/unix/lib \
--with-sqlite --with-sqlite-libs=/Library/Frameworks/SQLite3.framework/unix/lib \
--with-sqlite-includes=/Library/Frameworks/SQLite3.framework/unix/include \
--with-fftw --with-fftw-includes=/Library/Frameworks/FFTW3.framework/unix/include \
--with-fftw-libs=/Library/Frameworks/FFTW3.framework/unix/lib \
--with-postgres-includes=/usr/local/pgsql/include --with-postgres-libs=/usr/local/pgsql/lib \
--with-freetype --with-freetype-includes=/Library/Frameworks/FreeType.framework/unix/include \
--with-freetype-libs=/Library/Frameworks/FreeType.framework/unix/lib --with-python --with-readline \
--with-readline-includes=/sw/include/readline --with-readline-libs=/sw/lib --with-tcltk-includes=/usr/local/include \
--with-tcltk-libs=/usr/local/lib --with-blas --with-lapack \
--with-blas-includes=/System/Library/Frameworks/Accelerate.framework/Frameworks/vecLib.framework/Headers \
--with-lapack-includes=/System/Library/Frameworks/Accelerate.framework/Frameworks/vecLib.framework/Headers \
--with-motif --with-motif-includes=/sw/include --with-motif-libs=/sw/lib --with-glw

make
sudo make install