annotate src/hdf5.mk @ 3557:b1a7cff2d2a9

Add octave forge of-netcdf package (and support files) * src/of-netcdf.mk: New file. * src/netcdf.mk: Update checksum for version 4.3.0, install to DESTDIR. * src/hdf5.mk: make make and make install separate, modify libtool script to enable dynamic build of all sub libraries. * index.html: added of-netcdf * dist-files.mk: add of-netcdf.mk * Makefile.in: add of-netcdf * build_packages.m: add install of netcdf-1.0.2.tar.gz
author John Donoghue <john.donoghue@ieee.org>
date Thu, 06 Mar 2014 18:34:21 -0500
parents 13be64f9f16d
children 6ac813175f6f
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 :=
3480
13be64f9f16d move version info from index.html to src/*.mk files
John W. Eaton <jwe@octave.org>
parents: 3293
diff changeset
6 $(PKG)_VERSION := 1.8.10
2929
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
7 $(PKG)_CHECKSUM := 867a91b75ee0bbd1f1b13aecd52e883be1507a2c
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
8 $(PKG)_SUBDIR := $(PKG)-$($(PKG)_VERSION)
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
9 $(PKG)_FILE := $(PKG)-$($(PKG)_VERSION).tar.bz2
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
10 $(PKG)_URL := http://www.hdfgroup.org/ftp/HDF5/current/src/$($(PKG)_FILE)
3048
5ef49fb3299d treat gcc and binutils as build tools
John W. Eaton <jwe@octave.org>
parents: 3013
diff changeset
11 $(PKG)_DEPS :=
2997
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
12 ifeq ($(MXE_SYSTEM),mingw)
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
13 ifneq ($(MXE_NATIVE_BUILD),yes)
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
14 $(PKG)_CROSS_CONFIG_OPTIONS := \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
15 --disable-largefile \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
16 LIBS=-lws2_32 \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
17 hdf5_cv_gettimeofday_tz=no \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
18 hdf5_cv_vsnprintf_works=yes \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
19 hdf5_cv_printf_ll=l \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
20 hdf5_cv_system_scope_threads=yes \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
21 hdf5_cv_ldouble_to_integer_works=yes \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
22 hdf5_cv_ulong_to_float_accurate=yes \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
23 hdf5_cv_ulong_to_fp_bottom_bit_accurate=no \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
24 hdf5_cv_fp_to_ullong_accurate=yes \
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_fp_to_ullong_right_maximum=no \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
27 hdf5_cv_ldouble_to_uint_accurate=yes \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
28 hdf5_cv_ullong_to_ldouble_precision=yes \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
29 hdf5_cv_fp_to_integer_overflow_works=yes \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
30 hdf5_cv_ldouble_to_long_special=no \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
31 hdf5_cv_long_to_ldouble_special=no \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
32 hdf5_cv_ldouble_to_llong_accurate=yes \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
33 hdf5_cv_llong_to_ldouble_correct=yes
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
34 endif
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
35 endif
2929
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
36
3222
5072829ce458 hdf5.mk: set configure environment for native builds
John W. Eaton <jwe@octave.org>
parents: 3095
diff changeset
37 ifeq ($(MXE_NATIVE_BUILD),yes)
5072829ce458 hdf5.mk: set configure environment for native builds
John W. Eaton <jwe@octave.org>
parents: 3095
diff changeset
38 $(PKG)_CONFIGURE_ENV := LD_LIBRARY_PATH=$(LD_LIBRARY_PATH)
5072829ce458 hdf5.mk: set configure environment for native builds
John W. Eaton <jwe@octave.org>
parents: 3095
diff changeset
39 endif
5072829ce458 hdf5.mk: set configure environment for native builds
John W. Eaton <jwe@octave.org>
parents: 3095
diff changeset
40
2929
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
41 define $(PKG)_UPDATE
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
42 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
43 echo $(hdf5_VERSION)
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
44 endef
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
45
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
46 define $(PKG)_BUILD
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
47 # build GCC and support libraries
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
48 cd '$(1)' && autoreconf
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
49 mkdir '$(1)/.build'
3222
5072829ce458 hdf5.mk: set configure environment for native builds
John W. Eaton <jwe@octave.org>
parents: 3095
diff changeset
50 cd '$(1)/.build' && $($(PKG)_CONFIGURE_ENV) '$(1)/configure' \
2997
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
51 $(CONFIGURE_CPPFLAGS) $(CONFIGURE_LDFLAGS) \
3013
bcc26ffe9a0f use variable for --host and --build configure arguments
John W. Eaton <jwe@octave.org>
parents: 3012
diff changeset
52 $(HOST_AND_BUILD_CONFIGURE_OPTIONS) \
2929
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
53 $(ENABLE_SHARED_OR_STATIC) \
3012
100e618349f7 Improve handling of prefix directories by defining HOST_PREFIX and
John W. Eaton <jwe@octave.org>
parents: 2997
diff changeset
54 --prefix='$(HOST_PREFIX)' \
2929
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
55 --disable-direct-vfd \
3095
f2bbfa69647e [MSVC] enable HDF5 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents: 3048
diff changeset
56 $($(PKG)_CROSS_CONFIG_OPTIONS) && $(CONFIGURE_POST_HOOK)
2929
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
57
2997
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
58 case '$(MXE_SYSTEM)' in \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
59 *mingw*) \
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
60 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
61 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
62 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
63 ;; \
3095
f2bbfa69647e [MSVC] enable HDF5 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents: 3048
diff changeset
64 *msvc*) \
f2bbfa69647e [MSVC] enable HDF5 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents: 3048
diff changeset
65 sed -i -e 's/^\(#define H5_SIZEOF_SSIZE_T\) .*/\1 0/' \
f2bbfa69647e [MSVC] enable HDF5 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents: 3048
diff changeset
66 '$(1)/.build/src/H5pubconf.h'; \
f2bbfa69647e [MSVC] enable HDF5 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents: 3048
diff changeset
67 echo "#define H5_HAVE_WIN32_API 1" >> $(1)/.build/src/H5pubconf.h; \
f2bbfa69647e [MSVC] enable HDF5 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents: 3048
diff changeset
68 echo "#define H5_HAVE_VISUAL_STUDIO 1" >> $(1)/.build/src/H5pubconf.h; \
f2bbfa69647e [MSVC] enable HDF5 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents: 3048
diff changeset
69 echo "#define HAVE_WINDOWS_PATH 1" >> $(1)/.build/src/H5pubconf.h; \
f2bbfa69647e [MSVC] enable HDF5 compilation
Michael Goffioul <michael.goffioul@gmail.com>
parents: 3048
diff changeset
70 ;; \
2997
4f9b72cf7ee7 allow native builds too
John W. Eaton <jwe@octave.org>
parents: 2929
diff changeset
71 esac
2929
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
72
3557
b1a7cff2d2a9 Add octave forge of-netcdf package (and support files)
John Donoghue <john.donoghue@ieee.org>
parents: 3480
diff changeset
73 # libtool is somehow created to effectively disallow shared builds
b1a7cff2d2a9 Add octave forge of-netcdf package (and support files)
John Donoghue <john.donoghue@ieee.org>
parents: 3480
diff changeset
74 $(SED) -i 's,allow_undefined_flag="unsupported",allow_undefined_flag="",g' '$(1)/.build/libtool'
b1a7cff2d2a9 Add octave forge of-netcdf package (and support files)
John Donoghue <john.donoghue@ieee.org>
parents: 3480
diff changeset
75
b1a7cff2d2a9 Add octave forge of-netcdf package (and support files)
John Donoghue <john.donoghue@ieee.org>
parents: 3480
diff changeset
76 $(MAKE) -C '$(1)/.build' -j '$(JOBS)'
b1a7cff2d2a9 Add octave forge of-netcdf package (and support files)
John Donoghue <john.donoghue@ieee.org>
parents: 3480
diff changeset
77 $(MAKE) -C '$(1)/.build' -j 1 install DESTDIR='$(3)'
2929
4b72e7cf4f30 shared libraries and cross build for hdf5
John W. Eaton <jwe@octave.org>
parents:
diff changeset
78 endef