mxe/src/gdal.mk

66 lines
2.7 KiB
Makefile
Raw Normal View History

# Copyright (C) 2009 Volker Grabsch
#
# Permission is hereby granted, free of charge, to any person obtaining
# a copy of this software and associated documentation files (the
# "Software"), to deal in the Software without restriction, including
# without limitation the rights to use, copy, modify, merge, publish,
# distribute, sublicense, and/or sell copies of the Software, and to
# permit persons to whom the Software is furnished to do so, subject
# to the following conditions:
#
# The above copyright notice and this permission notice shall be
# included in all copies or substantial portions of the Software.
#
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
# EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
# IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
# CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
# TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
# SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
2008-11-09 02:37:06 +00:00
# GDAL
PKG := gdal
$(PKG)_VERSION := 1.6.2
$(PKG)_CHECKSUM := 1d9e1d8f01f06bca99e7335d7e86dff784eee819
$(PKG)_SUBDIR := gdal-$($(PKG)_VERSION)
$(PKG)_FILE := gdal-$($(PKG)_VERSION).tar.gz
$(PKG)_WEBSITE := http://www.gdal.org/
$(PKG)_URL := http://ftp.remotesensing.org/gdal/$($(PKG)_FILE)
$(PKG)_URL_2 := http://download.osgeo.org/gdal/$($(PKG)_FILE)
$(PKG)_DEPS := gcc zlib libpng tiff libgeotiff jpeg giflib expat curl geos
2008-11-09 02:37:06 +00:00
define $(PKG)_UPDATE
wget -q -O- 'http://trac.osgeo.org/gdal/wiki/DownloadSource' | \
$(SED) -n 's,.*gdal-\([0-9][^>]*\)\.tar.*,\1,p' | \
head -1
endef
define $(PKG)_BUILD
cd '$(1)' && ./configure \
--host='$(TARGET)' \
--disable-shared \
--prefix='$(PREFIX)/$(TARGET)' \
LIBS='-ljpeg' \
--with-threads \
--with-libz='$(PREFIX)/$(TARGET)' \
2008-11-09 02:37:06 +00:00
--with-png='$(PREFIX)/$(TARGET)' \
--with-libtiff='$(PREFIX)/$(TARGET)' \
--with-geotiff='$(PREFIX)/$(TARGET)' \
--with-jpeg='$(PREFIX)/$(TARGET)' \
--with-gif='$(PREFIX)/$(TARGET)' \
2008-11-10 10:09:59 +00:00
--with-expat='$(PREFIX)/$(TARGET)' \
2008-11-09 02:37:06 +00:00
--with-curl='$(PREFIX)/$(TARGET)/bin/curl-config' \
--with-geos='$(PREFIX)/$(TARGET)/bin/geos-config' \
--without-python \
--without-ngpython
$(MAKE) -C '$(1)' -j 1 lib-target
$(MAKE) -C '$(1)' -j 1 install-lib
$(MAKE) -C '$(1)/port' -j 1 install
$(MAKE) -C '$(1)/gcore' -j 1 install
$(MAKE) -C '$(1)/frmts' -j 1 install
$(MAKE) -C '$(1)/alg' -j 1 install
$(MAKE) -C '$(1)/ogr' -j 1 install OGR_ENABLED=
$(MAKE) -C '$(1)/apps' -j 1 install BIN_LIST=
2008-11-09 02:37:06 +00:00
endef