From 4a68f0ba2e3ed329664bfeda92fa7bc9c056d102 Mon Sep 17 00:00:00 2001 From: Charlie Sharpsteen Date: Sun, 11 Nov 2012 12:30:45 -0800 Subject: Clean up lib path searching for Spatialite Anything linking against SpatiaLite also needs to use Homebrew's SQLite so that loadable extensions are enabled along with RTree indices. This commit cleans up several formulae to use the specific `opt/sqlite/lib` prefix rather than `HOMEBREW_PREFIX/lib` and also adds this searching to `gdal`. However, this hack is getting a little large. The best fix would probably be to flag SQLite as `keg_only` so that lib path munging is handled automagically for everything with a dependency tree that includes SQLite. --- Library/Formula/libspatialite.rb | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'Library/Formula/libspatialite.rb') diff --git a/Library/Formula/libspatialite.rb b/Library/Formula/libspatialite.rb index 9ee46b6b7..2b31bc2bc 100644 --- a/Library/Formula/libspatialite.rb +++ b/Library/Formula/libspatialite.rb @@ -25,7 +25,8 @@ class Libspatialite < Formula def install # Ensure Homebrew's libsqlite is found before the system version. - ENV.append 'LDFLAGS', "-L#{HOMEBREW_PREFIX}/lib" + sqlite = Formula.factory 'sqlite' + ENV.append 'LDFLAGS', "-L#{sqlite.opt_prefix}/lib" args = %W[ --disable-dependency-tracking -- cgit v1.2.3