Skip to content

Instantly share code, notes, and snippets.

./configure \
--with-local=yes \
--prefix=/Users/zacmcc/local \
--with-threads \
--with-libtool \
--with-libtiff=internal \
--with-geotiff=internal \
--with-pcraster=internal \
--with-pcidsk=internal \
--with-bsb \
./configure \
--with-local=yes \
--prefix=/Users/zacmcc/local \
--with-threads \
--with-libtool \
--with-libtiff=internal \
--with-geotiff=internal \
--with-pcraster=internal \
--with-pcidsk=internal \
--with-bsb \
➜ ~ otool -L ~/local/lib/libgdal.dylib
/Users/zacmcc/local/lib/libgdal.dylib:
/Users/zacmcc/local/lib/libgdal.1.dylib (compatibility version 18.0.0, current version 18.0.0)
/usr/local/lib/libpoppler.19.dylib (compatibility version 20.0.0, current version 20.0.0)
/usr/local/lib/libfreexl.1.dylib (compatibility version 2.0.0, current version 2.0.0)
/usr/local/lib/libgeos_c.1.dylib (compatibility version 9.0.0, current version 9.2.0)
/usr/local/lib/libwebp.2.dylib (compatibility version 3.0.0, current version 3.0.0)
/usr/local/lib/libodbc.2.dylib (compatibility version 3.0.0, current version 3.0.0)
/usr/local/lib/libodbcinst.2.dylib (compatibility version 3.0.0, current version 3.0.0)
/usr/lib/libexpat.1.dylib (compatibility version 7.0.0, current version 7.2.0)
g++ -dynamiclib -o .libs/libgdal.1.dylib /Users/zacmcc/Downloads/gdal-1.9.0/frmts/o/.libs/EnvisatFile.o /Users/zacmcc/Downloads/gdal-1.9.0/frmts/o/.libs/IdrisiDataset.o /Users/zacmcc/Downloads/gdal-1.9.0/frmts/o/.libs/IngrTypes.o /Users/zacmcc/Downloads/gdal-1.9.0/frmts/o/.libs/IntergraphBand.o /Users/zacmcc/Downloads/gdal-1.9.0/frmts/o/.libs/IntergraphDataset.o /Users/zacmcc/Downloads/gdal-1.9.0/frmts/o/.libs/JpegHelper.o /Users/zacmcc/Downloads/gdal-1.9.0/frmts/o/.libs/_getcell.o /Users/zacmcc/Downloads/gdal-1.9.0/frmts/o/.libs/_getrow.o /Users/zacmcc/Downloads/gdal-1.9.0/frmts/o/.libs/_gsomece.o /Users/zacmcc/Downloads/gdal-1.9.0/frmts/o/.libs/_putcell.o /Users/zacmcc/Downloads/gdal-1.9.0/frmts/o/.libs/_rputrow.o /Users/zacmcc/Downloads/gdal-1.9.0/frmts/o/.libs/aaigriddataset.o /Users/zacmcc/Downloads/gdal-1.9.0/frmts/o/.libs/ace2dataset.o /Users/zacmcc/Downloads/gdal-1.9.0/frmts/o/.libs/adrgdataset.o /Users/zacmcc/Downloads/gdal-1.9.0/frmts/o/.libs/aigccitt.o /Users/zacmcc/Downloads/gdal-1.9.0/frmts/o/.
Building GDAL 1.9 with MDB (PGeo) support on OS X Lion
- Download and install the "Java for Mac OS X 10.7 Update 1 Developer Package" from https://developer.apple.com/downloads/index.action
- Download jackcess-1.2.6.jar from http://sourceforge.net/projects/jackcess/files/jackcess/1.2.6/jackcess-1.2.6.jar/download
- Download http://mdb-sqlite.googlecode.com/files/mdb-sqlite-1.0.2.tar.bz2 to get commons-lang-2.4.jar and commons-logging-1.1.1.jar. They will go alongside jackcess in the $CLASSPATH after it builds.
- In the GDAL source root, edit the configure.in and replace it with https://gist.github.com/1975654
@zhm
zhm / configure.in
Created March 5, 2012 00:37
GDAL 1.9 configure.in
dnl ***************************************************************************
dnl $Id: configure.in 23690 2012-01-03 18:56:17Z rouault $
dnl
dnl Project: GDAL
dnl Purpose: Configure source file.
dnl Author: Frank Warmerdam, warmerdam@pobox.com
dnl
dnl ***************************************************************************
dnl Copyright (c) 2000, Frank Warmerdam
dnl
for file in ~/postgres_backups/*
do
dbname=$(basename $file | sed s/\.gz//g)
createdb $dbname
gunzip -c $file | sed 's/Library\/PostgreSQL\/9.0\/lib\/postgis-1.5/usr\/local\/Cellar\/postgresql\/9.1.3\/lib\/postgis-1.5/g' | psql $dbname
done
@zhm
zhm / gist:1414632
Created December 1, 2011 07:25
merge GeoJSON quick&dirty
var fs = require('fs');
var files = process.argv.slice(2);
var output = { type: 'LineString', coordinates: [ ] };
for (var i = 0; i < files.length; ++i) {
output.coordinates.append(JSON.parse(fs.readFileSync(files[i])).coordinates);
}
fs.writeFileSync('output.json', JSON.stringify(output, null, '\t'));
@zhm
zhm / typemaps_ruby.i
Created November 30, 2011 06:20
GDAL Ruby 1.9 fix typemaps_ruby.i
/******************************************************************************
* $Id$
*
* Name: typemaps_ruby.i
* Project: GDAL Ruby Interface
* Purpose: GDAL Core SWIG Interface declarations.
* Author: Charles F. I. Savage
*
@zhm
zhm / gdal_ruby.i
Created November 30, 2011 06:17
GDAL Ruby 1.9 fix gdal_ruby.i
/*
* $Id$
*
* ruby specific code for gdal bindings.
*/
/*
* $Log$
* Revision 1.2 2005/09/26 08:18:55 cfis
* Copied over code from the Python version of gdal_ruby.i. Will have to port the code to Ruby.