gdal 1.10.1

Apply patch for build failure on OS X 10.6/7.

Closes Homebrew/homebrew#22438.

Signed-off-by: Mike McQuaid <mike@mikemcquaid.com>
master
Kyungdahm Yun 2013-09-10 22:14:59 +09:00 committed by Mike McQuaid
parent 24f42dc953
commit 7c4ce471cc
1 changed files with 24 additions and 2 deletions

View File

@ -2,8 +2,8 @@ require 'formula'
class Gdal < Formula
homepage 'http://www.gdal.org/'
url 'http://download.osgeo.org/gdal/1.10.0/gdal-1.10.0.tar.gz'
sha1 'e522b95056905e4c41047fdb42c0ca172ef3ad25'
url 'http://download.osgeo.org/gdal/1.10.1/gdal-1.10.1.tar.gz'
sha1 'b4df76e2c0854625d2bedce70cc1eaf4205594ae'
head 'https://svn.osgeo.org/gdal/trunk/gdal'
@ -181,6 +181,13 @@ class Gdal < Formula
return args
end
def patches
# Prevent build failure on 10.6 / 10.7
# TODO: Remove when 1.10.2 releases
# http://trac.osgeo.org/gdal/ticket/5197
DATA
end
def install
# Linking flags for SQLite are not added at a critical moment when the GDAL
# library is being assembled. This causes the build to fail due to missing
@ -236,3 +243,18 @@ class Gdal < Formula
end
end
end
__END__
diff --git a/port/cpl_spawn.cpp b/port/cpl_spawn.cpp
index d702594..69ea3c2 100644
--- a/port/cpl_spawn.cpp
+++ b/port/cpl_spawn.cpp
@@ -464,7 +464,7 @@ void CPLSpawnAsyncCloseErrorFileHandle(CPLSpawnedProcess* p)
#ifdef __APPLE__
#include <TargetConditionals.h>
#endif
- #if defined(__APPLE__) && !defined(TARGET_OS_IPHONE)
+ #if defined(__APPLE__) && (!defined(TARGET_OS_IPHONE) || TARGET_OS_IPHONE==0)
#include <crt_externs.h>
#define environ (*_NSGetEnviron())
#else