annotate src/hdf5.mk @ 2997:4f9b72cf7ee7

allow native builds too
author John W. Eaton <jwe@octave.org>
date Tue, 28 May 2013 17:31:59 -0400
parents 4b72e7cf4f30
children 100e618349f7
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
2929
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
1 # This file is part of MXE.
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
2 # See index.html for further information.
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
3
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
4 PKG := hdf5
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
5 $(PKG)_IGNORE :=
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
6 $(PKG)_CHECKSUM := 867a91b75ee0bbd1f1b13aecd52e883be1507a2c
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
7 $(PKG)_SUBDIR := $(PKG)-$($(PKG)_VERSION)
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
8 $(PKG)_FILE := $(PKG)-$($(PKG)_VERSION).tar.bz2
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
9 $(PKG)_URL := http://www.hdfgroup.org/ftp/HDF5/current/src/$($(PKG)_FILE)
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
10 $(PKG)_DEPS := gcc
2997
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
11 ifeq ($(MXE_SYSTEM),mingw)
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
12 ifneq ($(MXE_NATIVE_BUILD),yes)
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
13 $(PKG)_CROSS_CONFIG_OPTIONS := \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
14 --disable-largefile \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
15 LIBS=-lws2_32 \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
16 hdf5_cv_gettimeofday_tz=no \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
17 hdf5_cv_vsnprintf_works=yes \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
18 hdf5_cv_printf_ll=l \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
19 hdf5_cv_system_scope_threads=yes \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
20 hdf5_cv_ldouble_to_integer_works=yes \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
21 hdf5_cv_ulong_to_float_accurate=yes \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
22 hdf5_cv_ulong_to_fp_bottom_bit_accurate=no \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
23 hdf5_cv_fp_to_ullong_accurate=yes \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
24 hdf5_cv_fp_to_ullong_right_maximum=no \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
25 hdf5_cv_fp_to_ullong_right_maximum=no \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
26 hdf5_cv_ldouble_to_uint_accurate=yes \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
27 hdf5_cv_ullong_to_ldouble_precision=yes \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
28 hdf5_cv_fp_to_integer_overflow_works=yes \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
29 hdf5_cv_ldouble_to_long_special=no \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
30 hdf5_cv_long_to_ldouble_special=no \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
31 hdf5_cv_ldouble_to_llong_accurate=yes \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
32 hdf5_cv_llong_to_ldouble_correct=yes
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
33 endif
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
34 endif
2929
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
35
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
36 define $(PKG)_UPDATE
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
37 echo 'Warning: Updates are temporarily disabled for package hdf5.' >&2;
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
38 echo $(hdf5_VERSION)
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
39 endef
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
40
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
41 define $(PKG)_BUILD
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
42 # build GCC and support libraries
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
43 cd '$(1)' && autoreconf
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
44 mkdir '$(1)/.build'
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
45 cd '$(1)/.build' && '$(1)/configure' \
2997
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
46 $(CONFIGURE_CPPFLAGS) $(CONFIGURE_LDFLAGS) \
2929
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
47 --host='$(TARGET)' \
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
48 --build="`config.guess`" \
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
49 $(ENABLE_SHARED_OR_STATIC) \
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
50 --prefix='$(PREFIX)/$(TARGET)' \
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
51 --disable-direct-vfd \
2997
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
52 $($(PKG)_CROSS_CONFIG_OPTIONS)
2929
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
53
2997
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
54 case '$(MXE_SYSTEM)' in \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
55 *mingw*) \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
56 echo "#define H5_HAVE_WIN32_API 1" >> $(1)/.build/src/H5pubconf.h; \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
57 echo "#define H5_HAVE_MINGW 1" >> $(1)/.build/src/H5pubconf.h; \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
58 echo "#define HAVE_WINDOWS_PATH 1" >> $(1)/.build/src/H5pubconf.h; \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
59 ;; \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
60 esac
2929
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
61
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
62 $(MAKE) -C '$(1)/.build' -j '$(JOBS)' install
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
63 endef