Gdal version 1.6.2 - How to Download and Install on Mac OS X
Saturday the 7th of November, 2009

    version 1.6.2

      View the most recent changes for the gdal port at: gdal.darwinports.com/diff
      Scroll down toward the bottom of the page to get installation instructions for gdal.
      The raw portfile for gdal 1.6.2 is located here:
      http://gdal.darwinports.com/dports/science/gdal/Portfile
      Find related portfiles with the unique DarwinPorts.com search feature.
      Check for any related Fink projects here: pdb.finkproject.org/pdb/package.php/gdal


      The gdal Portfile 58230 2009-09-24 16:45:22Z ryandesign macports.org $

      PortSystem 1.0
      Name: gdal
      Version: 1.6.2
      Maintainers: gmail.com:seanasy
      Platform: darwin
      Description: GDAL - Geospatial Data Abstraction Library
      Long Description: GDAL is a translator library for raster geospatial data formats that is released under an X/MIT style Open Source license. As a library, it presents a single abstract data model to the calling application for all supported formats. The related OGR library (which lives within the GDAL source tree) provides a similar capability for simple features vector data.
      Homepage: http://www.gdal.org/
      Master Sites: http://www.gdal.org/dl/ http://download.osgeo.org/gdal/
      Category: science
      Checksums: md5 f2dcd6aa7222d021202984523adf3b55 rmd160 e445680953f25047a280f36cedba0597094e0562 sha1 1d9e1d8f01f06bca99e7335d7e86dff784eee819

      depends_lib port:zlib port:libpng port:tiff port:libgeotiff port:jpeg path:include/gif_lib.h:giflib port:proj

      configure.args --with-local=${prefix} --with-libz=${prefix} --with-png=${prefix} --with-libtiff=${prefix} --with-geotiff=${prefix} --with-jpeg=${prefix} --with-gif=${prefix} --with-static-proj4=${prefix} --without-pg --without-grass --without-libgrass --without-cfitsio --without-pcraster --without-netcdf --without-ogdi --without-fme --without-hdf4 --without-hdf5 --without-jasper --without-ecw --without-kakadu --without-mrsid --without-jp2mrsid --without-msg --without-bsb --without-oci --without-grib --without-mysql --without-ingres --without-xerces --without-expat --without-odbc --with-dods-support=no --without-curl --without-sqlite3 --without-dwgdirect --without-idb --without-sde --without-geos --without-pam --without-macosx-framework --without-perl --without-php --without-ruby --without-python --without-ogpython --without-xerces --mandir=${prefix}/share/man --with-pthreads

      # Patch to ensure that the python installation respects DESTDIR
      Patch Files: patch-swig_python_GNUmakefile

      # Patches for universal build

      pre-build {
      if {[variant_isset universal]} {
      system "cd ${worksrcpath} && patch -p0 < ${portpath}/files/patch_cpl_config_h"
      }
      }

      # Set target to none
      build.target

      Variant: geos description {Enable GEOS geometry engine functionality} {
      depends_lib-append port:geos
      configure.args-delete --without-geos
      configure.args-append --with-geos=${prefix}/bin/geos-config
      }

      Variant: curl description {Enable curl support} {
      depends_lib-append port:curl
      configure.args-delete --without-curl
      configure.args-append --with-curl=${prefix}/bin/curl-config
      }

      Variant: mrsid description {Enable MrSID file format} {
      depends_lib-append port:geoexpress-sdk
      configure.args-delete --without-mrsid
      configure.args-append --with-mrsid=${prefix}/share/Geo_DSDK

      # Fixes for Geo_DSDK 7.x - http://trac.osgeo.org/gdal/ticket/2410
      patchfiles-append patch-frmts_mrsid_mrsiddataset.cpp patch-mrsid-configure
      }

      Variant: hdf4 description {Enable HDF4 file format} {
      depends_lib-append port:hdf4
      configure.args-delete --without-hdf4
      configure.args-append --with-hdf4=${prefix}
      }

      Variant: hdf5 description {Enable HDF5 file format} {
      depends_lib-append port:hdf5
      configure.args-delete --without-hdf5
      configure.args-append --with-hdf5=${prefix}
      }

      Variant: netcdf description {Enable NetCDF file format} {
      depends_lib-append port:netcdf
      configure.args-delete --without-netcdf
      configure.args-append --with-netcdf=${prefix}
      }

      Variant: jasper description {Enable JasPer JPEG-2000 file format} {
      depends_lib-append port:jasper
      configure.args-delete --without-jasper
      configure.args-append --with-jasper=${prefix}
      }

      Variant: xerces description {Enable xerces XML support for GML file format} {
      depends_lib-append port:xercesc
      configure.args-delete --without-xerces
      configure.args-append --with-xerces=${prefix}
      }

      # Python variants
      Variant: python24 description {Enable Python 2.4 support} {
      depends_lib-append port:python24 port:py-numpy
      configure.args-delete --without-python
      configure.args-append --with-python
      build.args-append PYTHON=python2.4
      }

      Variant: python25 description {Enable Python 2.5 support} {
      depends_lib-append port:python25 port:py25-numpy
      configure.args-delete --without-python
      configure.args-append --with-python
      build.args-append PYTHON=python2.5
      }

      Variant: python26 description {Enable Python 2.6 support} {
      depends_lib-append port:python26 port:py26-numpy
      configure.args-delete --without-python
      configure.args-append --with-python
      build.args-append PYTHON=python2.6
      }

      # Database variants
      Variant: postgresql81 description {Enable PostgreSQL 8.1 support} {
      depends_lib-append port:postgresql81
      configure.args-delete --without-pg
      configure.args-append --with-pg=${prefix}/lib/postgresql81/bin/pg_config
      }

      Variant: postgresql82 description {Enable PostgreSQL 8.2 support} {
      depends_lib-append port:postgresql82
      configure.args-delete --without-pg
      configure.args-append --with-pg=${prefix}/lib/postgresql82/bin/pg_config
      }

      Variant: postgresql83 description {Enable PostgreSQL 8.3 support} {
      depends_lib-append port:postgresql83
      configure.args-delete --without-pg
      configure.args-append --with-pg=${prefix}/lib/postgresql83/bin/pg_config
      }

      Variant: postgresql84 description {Enable PostgreSQL 8.4 support} {
      depends_lib-append port:postgresql84
      configure.args-delete --without-pg
      configure.args-append --with-pg=${prefix}/lib/postgresql84/bin/pg_config
      }

      Variant: mysql5 description {Enable MySQL 5 support} {
      depends_lib-append path:bin/mysql_config5:mysql5
      configure.args-delete --without-mysql
      configure.args-append --with-mysql=${prefix}/lib/mysql5/bin/mysql_config
      }

      Variant: sqlite3 description {Enable SQLite3 support} {
      depends_lib-append port:sqlite3
      configure.args-delete --without-sqlite
      configure.args-append --with-sqlite=${prefix}
      }

      Variant: odbc description {Enable ODBC support} {
      depends_lib-append port:unixODBC
      configure.args-delete --without-odbc
      configure.args-append --with-odbc=${prefix}
      }

      # OS X Framework
      Variant: framework description {Build as a Mac OS X framework} {
      configure.args-append --with-macosx-framework
      }

      post-destroot {
      xinstall -m 755 -d ${destroot}${prefix}/share/doc/${name}
      xinstall -m 644 -W ${worksrcpath} HOWTO-RELEASE NEWS VERSION ${destroot}${prefix}/share/doc/${name}
      }

    If you haven't already installed Darwin Ports, you can find easy instructions for doing so at the main Darwin Ports page.

    Once Darwin Ports has been installed, in a terminal window and while online, type the following and hit return:


      %  cd /opt/local/bin/portslocation/dports/gdal
      % sudo port install gdal
      Password:
    You will then be prompted for your root password, which you should enter. You may have to wait for a few minutes while the software is retrieved from the network and installed for you. Y ou should see something that looks similar to:

      ---> Fetching gdal
      ---> Verifying checksum for gdal
      ---> Extracting gdal
      ---> Configuring gdal
      ---> Building gdal with target all
      ---> Staging gdal into destroot
      ---> Installing gdal
    - Make sure that you do not close the terminal window while Darwin Ports is working. Once the software has been installed, you can find further information about using gdal with these commands:
      %  man gdal
      % apropos gdal
      % which gdal
      % locate gdal

     Where to find more information:

    Darwin Ports



    Lightbox this page.