Index of /pipermail/grass-user/attachments/20021212/98c688e4
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN"><html><head><title>Index of /grass5/binary/mac_os_x</title></head><body bgcolor="#ffffff">
<em>Control-Click on the 'grass5install.sh' and choose 'save link to disk'.</em>
<p>
Please use the nearest mirror sites:
Mirror List: <a href="http://grass.itc.it/grass.mirrors.html">grass.mirrors.html</a>
</p><p>These binaries are distributed in the hope that they will be useful, but WITHOUT<br>
ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or<br>
FITNESS FOR A PARTICULAR PURPOSE. Installation support for GRASS on<br>
Mac OS X shall be <b>guaranteed</b> to be provided only to <a href="http://openosx.com/grass/">OpenOSX GRASS</a> customers.</p>
<hr>
<pre>This directory contains GRASS GIS 5.0.0 binary code for the Mac OS X 10.2.x
platform. <em>These binaries have ONLY been tested with Mac OS 10.2.1
(current version at the time of writing).</em>
[<a href="#FAQ">NEW FAQ below!</a>]
These binaries have been ported, compiled and contributed by Jeshua Lacock, the
Owner of <a href="http://openosx.com/">OpenOSX</a>. The fastest and easiest way to install a complete
installation of GRASS on Mac OS X is accomplished with OpenOSX's <a href="http://openosx.com/grass/">GRASS
5.0.0 Package,</a> which will eliminate all the instructions and downloads outlined on this page. All of the
libraries (Xfree, Tcl/TK, Mesa, gdal, etc) have been compiled with gcc 3.1 for at least
a 20% gain in performance over previous versions (which used gcc 2.95).
Note that <em>in theory</em>, these binaries should <em>only</em> work on Mac OS 10.2.1 or later systems.
<em>All</em> required and optional libraries <em>must</em> be built on Mac OS 10.2.1 or (perhaps) later.
<hr width="100%">
Requirements for graphical user interface (GUI):
a) X-Windows:
There are many different ways to install X-Windows. One option is the package from
OS X GNU, also listed on <a href="http://www.apple.com/downloads/macosx/unix_open_source/xfree86.html">Apple's Mac OS X downloads page</a>.
Another option is <a href="http://fink.sourceforge.net">fink</a>, which can also be used to install the optional libraries (see below).
<a href="http://oroborosx.sourceforge.net/">OroborOSX</a> is a modified X-Window manager that has been modified for native Mac
OS X like features. It requires an installation of X-Free. The site also lists more detailed
infomation about running X-Windows on mac OS X.
b) tcltkgrass GUI:
The above files should be moved/copied or downloaded to / (root) and installed
from there:
% cd /
% gunzip tcltk_macosX_lib.tar.gz
% tar -xvf tcltk_macosX_lib.tar.gz
% gunzip tcltkbin_macosX.tar.gz
% tar -xvf tcltkbin_macosX.tar.gz
Note that these files contain an older 8.0 version of tcl/tk, so this procedure is not recommended.
Whenever possible, install the most recent version the complete tcl/tk library from <a href="http://tcl.sourceforge.net/">http://tcl.sourceforge.net/</a>.
(It is a convenient Mac OS X install package)
Not that these binaries have been compiled with Tcl/Tk 8.4 and has not been tested with
previous versions.<hr width="100%">
GRASS 5 Installation:
1. Get the GRASS binary distribution (currently 26MB):
grass5.0.0_powerpc-apple-darwin6.1_bin.tar.bz2 (all files)
2. Also download the installation script:
grass5_powerpc-apple-darwin6.1_install.sh
Then type the following for installation (use current package name!):
% sh grass5_powerpc-apple-darwin6.1_install.sh grass5.0.0_powerpc-apple-darwin6.1_bin.tar.bz2
This will create the necessary directories and
files for you to run GRASS. The default install path is
/usr/local/grass5/
To install in a different directory, specify it in the
command line:
% sh grass5_powerpc-apple-darwin6.1_install.sh grass5.0.0_powerpc-apple-darwin6.1_bin.tar.bz2 /opt/grass5
You will likely need to add X11R6/bin to your search path and set your DISPLAY
variable if you are using the Terminal application.
If you want to use the native Mac OS X Tcl/Tk interface you will also need to
download and apply the file 'gui.tcl.MacOSX.TclTk.patch'.
If you want to use NVIZ, you will need to download and apply the
file 'widgets.tcl.OpenOSX.patch'.
-------
How to apply a patch:
widgets.tcl.OpenOSX.patch:
cp widgets.tcl.OpenOSX.patch /usr/local/grass5/etc/nviz2.2/scripts/
cd /usr/local/grass5/etc/nviz2.2/scripts/
patch -p1 < widgets.tcl.OpenOSX.patch
gui.tcl.OpenOSX.TclTk.patch:
cp gui.tcl.OpenOSX.TclTk.patch /usr/local/grass5/tcltkgrass/main/
cd /usr/local/grass5/tcltkgrass/main
patch -p1 < gui.tcl.OpenOSX.TclTk.patch
-------
After installation please enter:
% source /etc/csh.cshrc /etc/csh.login
(Mac won't find the start script otherwise).
Then start GRASS with
% grass5
The user interface is started within GRASS:
% tcltkgrass &
Note: If you are starting from the beginning, you have
to define your project area within GRASS before
accessing the "tcltkgrass" user interface.
For some funcionalities of GRASS (e.g. the PNG or GDAL driver) you need to install
additional UNIX-libraries. (All of the optional and required libraries are installed by the
OpenOSX <a href="http://openosx.com/grass/">GRASS Package</a>, or can either be compiled or installed from packages (when available)
with <a href="http://fink.sourceforge.net">fink.</a>). The most recent stable version must be used, and all
libraries must be built with gcc 3.1. The list of optional libraries and their home pages are:</pre>
<ul>
<li><code>libncurses4.x/5.x (already installed on modern systems)<br>
<a href="http://www.gnu.org/software/ncurses/ncurses.html">http://www.gnu.org/software/ncurses/ncurses.html</a> <br>
<a href="ftp://ftp.gnu.org/pub/gnu/ncurses/">ftp://ftp.gnu.org/pub/gnu/ncurses/</a><br>
</code></li>
<li><code>Mesa-3.x (openGL clone) required for NVIZ2.2<br>
<a href="http://mesa3d.sourceforge.net/">http://mesa3d.sourceforge.net/</a><br>
</code></li>
<li><code>FFTW (library for computing the Discrete Fourier Transform)
required for i.fft and i.ifft modules<br>
<a href="http://www.fftw.org/">http://www.fftw.org</a> <br>
</code></li>
<li><code>libpng (for r.in.png, r.out.png), usually already
installed.<br>
<a href="http://www.libpng.org/pub/png/libpng.html">http://www.libpng.org/pub/png/libpng.html</a> <br>
</code></li>
<li><code>libjpeg (for r.in.tiff, r.out.tiff), usually already
installed.<br>
<a href="http://www.ijg.org/">http://www.ijg.org</a><br>
<a href="ftp://ftp.uu.net/graphics/jpeg/">ftp://ftp.uu.net/graphics/jpeg/</a> <br>
</code></li>
<li><code>libtiff (for r.in.tiff, r.out.tiff), usually already
installed.<br>
<a href="http://www.libtiff.org/">http://www.libtiff.org</a> <br>
</code></li>
<li><code>libgd (for PNG driver), preferably GD 2.x.<br>
<a href="http://www.boutell.com/gd/">http://www.boutell.com/gd/</a> <br>
</code></li>
<li><code>netpbm-tools/libraries (for r.in.png/r.out.png), usually
already installed.<br>
[please look at any decent software mirror near you!]<br>
<a href="http://sourceforge.net/projects/netpbm/">http://sourceforge.net/projects/netpbm/</a> <br>
</code></li>
<li><code>PostgreSQL libraries (for the PostgreSQL database
interface)<br>
<a href="http://www.postgresql.org/">http://www.postgresql.org</a> <br>
NOTE: An easy installation package of postgreSQL for Mac OS X is available from <a href="http://www.entropy.ch">Marc Liyanage</a><br>
</code></li>
<li><code>Unix ODBC (for the ODBC database interface)<br>
<a href="http://www.unixodbc.org/">http://www.unixodbc.org</a> <br>
</code></li>
<li><code>Only required for "xanim" and "ogl3d": the Motif or
Lesstif libraries<br>
<a href="http://www.lesstif.org/">http://www.lesstif.org</a> <br>
</code></li>
<li><code>r.in.gdal requires GDAL - Geospatial Data Abstraction
Library<br>
<a href="http://www.remotesensing.org/gdal/">http://www.remotesensing.org/gdal/</a> <br>
</code></li>
<li><code>R language (for the R language interface)<br>
<a href="http://cran.r-project.org/">http://cran.r-project.org</a> <br>
NOTE: There is an installation package for OS X, but be sure to install the X11
version if you want to use it with grass,
and NOT the carbon version <br>
</code></li>
<li><code>FreeType2 (for d.text.freetype)<br>
<a href="http://www.freetype.org/">http://www.freetype.org/</a> </code></li>
</ul>
<pre>
Note that for packages that need to be compiled, you need the most recent developer tools,
that are provided on the apple website (free registration as developer required)
IMPORTANT: if grass can't find wish (from tcl/tk), you should make a link to wish8.4,
or whatever version you have installed, in /usr/local/bin/:
% ln -s /usr/local/bin/wish8.4 /usr/local/bin/wish
<hr width="100%"><a name="FAQ"></a>
FAQs:
Question:
I recently installed GRASS 5 pre3 precompiled binaries on Mac OSX,
and am getting an error when I start NVIZ:
tsdptr 4729744 datakey 4729744
start search mainPtr 0
called create main window
assigning interp 4700480
tsd is 4729744 datakey 4729744
Application initialization failed: Can't find a usable tk.tcl in the
following directories:
/System/Library/Tcl/tk8.3 /usr/local/grass5/etc/lib/tk8.3
/usr/local/grass5/
lib/tk8.3 /usr/local/grass5/etc/library /usr/local/grass5/library
/usr/local/gra
ss5/tk8.3/library /usr/local/tk8.3/library
There is, however, an installation of tk8.3 at /usr/X11R6/lib. Where
in Mac OSX can I tell the system to look for tk8.3? I don't
see it in any of the GRASS startup scripts; I think it's somewhere in
OSX.
Answer:
Actually, I think that the problem is that the MacOS X version of Tk
locates the files using a "hack" which only works for the supplied
"wish" executable.
Basically, the directories which are searched are relative to the
location of the executable (apart from /System/Library).
If you examine the list of directories:
        /System/Library/Tcl/tk8.3
        /usr/local/grass5/etc/lib/tk8.3
        /usr/local/grass5/lib/tk8.3
        /usr/local/grass5/etc/library
        /usr/local/grass5/library
        /usr/local/grass5/tk8.3/library
        /usr/local/tk8.3/library
and note that the executable pathname is:
        /usr/local/grass5/etc/nviz2.2/NVWISH2.2
it appears that the search path is effectively:
        /System/Library/Tcl/tk8.3
        /usr/local/grass5/etc/nviz2.2/../lib/tk8.3
        /usr/local/grass5/etc/nviz2.2/../../lib/tk8.3
        /usr/local/grass5/etc/nviz2.2/../library
        /usr/local/grass5/etc/nviz2.2/../../library
        /usr/local/grass5/etc/nviz2.2/../../tk8.3/library
        /usr/local/grass5/etc/nviz2.2/../../../tk8.3/library
AFAICT, the above behaviour is hard-coded into the tk shared library.
This will work for wish, assuming that both wish and the tk8.3
directory are installed into the bin and lib subirectories of a common
parent directory. It won't work for other programs which use the tk
library, though.
The simplest workaround would be to try making a symlink within
$GISBASE/lib, e.g.
% ln -s /usr/X11R6/lib/tk8.3 /usr/local/grass5/lib/tk8.3
Question:
A Mac OS X (pb and 1.0) user tries to fire up GRASS, the following
error occurs:
Error opening terminal: vt100
Answer:
% grass5 -tcltk
The solution (kudos to strobe) is to cd to the directory where your
spearfish directory is (i.e. if its found in /opt/spearfish, cd /opt)
and enter the following:
% grass5 spearfish/PERMANENT
Question:
I downloaded GRASS for Mac OS X as many other people ;-). I realized
however that for running the interface I need to logout and enter as
>console (and subsequently start the X-Windows manager) . Do you know of
any solution that let me stay inside the normal Mac OS X environment?
Answer:
Try <a href="http://oroborosx.sourceforge.net/">OroborOSX</a>. It makes Xfree86 run side by side within
the quartz engine. More information can be found at that site. OrborOSX and
XFree are installed by OpenOSX's GRASS Package.
<hr width="100%">
Paint driver notes:
1) If you have local paint devices, you will need
move the appropriate files from
$GISBASE/etc/paint/driver.uninst to the driver.sh
in the same directory. In addition, you must create
a symbolic link (using the 'ln -s' command) from
/dev/[paint driver name] to /dev/ttya or /dev/ttyb
(or whichenver system device your print device is
plugged in too). For example, if you have a
xerox4020 connected to /dev/ttya, use
% cd $GISBASE/etc/paint/driver.uninst
% mv xerox4020 ../driver.sh
% ln -s /dev/ttya /dev/xerox4020
% chmod 0666 /dev/xerox4020
You will have to be root to create the symbolic
link in /dev.
2) If you have a paint device which exists on a
remote host whose GISBASE is difference from the
local GISBASE you will need to update the value
of GISBASE in etc/paint/driver.rsh.
3) If you plan to use v.digspline and have any
digitizers copy the file etc/digcap.sampl to
etc/digcap and edit it accordingly.
USING THE BINARY VERSION
------------------------
The binary version does not come with any data or
documentation (except for on-line man pages). You will
need to acquire whatever documents you like from the GRASS
Research Group FTP server. Sample data is also available
from the FTP site, or you may use data from previous
versions of GRASS if you have it available.
***********************************************
If you experience any problems, you may email
us at:
<a href="mailto:GrassDownload@OpenOSX.com">GrassDownload@OpenOSX.com</a>
<a href="http://openosx.com/grass/">http://OpenOSX.com/grass/</a>
Jeshua Lacock, OpenOSX
Bug report form: <a href="http://grass.itc.it/bugtracking/bugreport.html">go here!</a>.
Get this <a href="http://grass.itc.it/grass5/binary/mac_os_x/README.html">file.</a>
Updated $Date: 2002/12/05 $
</pre>
</body></html>