Mercurial > mxe-octave
comparison src/netcdf.mk @ 3157:591b3d68b43e
Add netcdf module (and MSVC-specific patch)
author | Michael Goffioul <michael.goffioul@gmail.com> |
---|---|
date | Sat, 20 Jul 2013 22:41:16 -0400 |
parents | |
children | 13be64f9f16d |
comparison
equal
deleted
inserted
replaced
3156:36ac78f420b4 | 3157:591b3d68b43e |
---|---|
1 # This file is part of MXE. | |
2 # See index.html for further information. | |
3 | |
4 PKG := netcdf | |
5 $(PKG)_IGNORE := | |
6 $(PKG)_CHECKSUM := 31b4b3b17146cc8c14a8c7be3fe5f28e5a8a5deb | |
7 $(PKG)_SUBDIR := netcdf-$($(PKG)_VERSION) | |
8 $(PKG)_FILE := netcdf-$($(PKG)_VERSION).tar.gz | |
9 $(PKG)_URL := http://www.unidata.ucar.edu/downloads/netcdf/ftp/netcdf-$($(PKG)_VERSION).tar.gz | |
10 $(PKG)_DEPS := curl hdf5 | |
11 | |
12 define $(PKG)_UPDATE | |
13 $(WGET) -q -O- 'http://www.unidata.ucar.edu/downloads/netcdf/current/index.jsp' | \ | |
14 $(SED) -n 's,.*netcdf-\([0-9][^>]*\)\.tar.*,\1,p' | \ | |
15 head -1 | |
16 endef | |
17 | |
18 $(PKG)_CONFIGURE_POST_HOOK := $(CONFIGURE_POST_HOOK) | |
19 ifeq ($(MXE_SYSTEM),msvc) | |
20 $(PKG)_CONFIGURE_POST_HOOK += -x | |
21 endif | |
22 | |
23 define $(PKG)_BUILD | |
24 if [ $(MXE_SYSTEM) = msvc ]; then \ | |
25 cd '$(1)' && autoreconf -f -i -v; \ | |
26 fi | |
27 cd '$(1)' && ./configure \ | |
28 $(HOST_AND_BUILD_CONFIGURE_OPTIONS) \ | |
29 $(ENABLE_SHARED_OR_STATIC) \ | |
30 --prefix='$(HOST_PREFIX)' \ | |
31 --enable-dll \ | |
32 && $($(PKG)_CONFIGURE_POST_HOOK) | |
33 $(MAKE) -C '$(1)' -j '$(JOBS)' | |
34 $(MAKE) -C '$(1)' -j 1 install | |
35 endef |