diff src/hdf4-1-portability-fixes.patch @ 2881:ab8ac5889a4c draft

Add package netcdf and its prerequisites hdf4, hdf5, and portablexdr. Also enable the HDF4, HDF5 and NetCDF drivers for GDAL.
author Martin Lambers <marlam@marlam.de>
date Mon, 03 Dec 2012 19:04:19 +0100
parents
children 88969381a4b5
line wrap: on
line diff
new file mode 100644
--- /dev/null
+++ b/src/hdf4-1-portability-fixes.patch
@@ -0,0 +1,53 @@
+This file is part of MXE.
+See index.html for further information.
+
+--- a/configure.ac	2012-12-02 11:01:36.252405122 +0100
++++ b/configure.ac	2012-12-02 11:00:05.580408916 +0100
+@@ -556,7 +556,6 @@
+ dnl ======================================================================
+ 
+ dnl Always put the /usr/include/rpc directory first in the search list.
+-CPPFLAGS="-I/usr/include/rpc $CPPFLAGS"
+ 
+ dnl ----------------------------------------------------------------------
+ dnl We're trying to link against the rpc library when building on Cygwin,
+@@ -739,6 +739,7 @@
+   *-mac-*)              BAR="mac"         ;;
+   *-apple*)             BAR="apple"       ;;
+   i686-pc-cygwin*)      BAR="linux"       ;;
++  i686-pc-mingw*)	BAR="linux"       ;;
+   *)                    echo "*** unknown host $host!"; exit 1 ;;
+ esac
+ src_files="mfhdf/libsrc/config/netcdf-FOO.h:mfhdf/libsrc/netcdf.h
+--- a.hdf/src/hdfi.h	2012-12-02 11:05:59.140394129 +0100
++++ b/hdf/src/hdfi.h	2012-12-02 11:05:32.528395313 +0100
+@@ -865,8 +865,8 @@
+ #include <sys/stat.h>
+ #include <unistd.h>
+ #else /* !UNIX386 */
+-#include <sys\types.h>      /* for unbuffered file I/O */
+-#include <sys\stat.h>
++#include <sys/types.h>      /* for unbuffered file I/O */
++#include <sys/stat.h>
+ #include <io.h>
+ #include <conio.h>          /* for debugging getch() calls */
+ #include <malloc.h>
+--- a/mfhdf/ncgen/Makefile.am	2012-12-02 19:04:08.512697688 +0100
++++ b/mfhdf/ncgen/Makefile.am	2012-12-02 19:14:01.636713531 +0100
+@@ -23,16 +23,6 @@
+ 
+ bin_PROGRAMS = ncgen
+ 
+-if HDF_BUILD_NETCDF
+-if HDF_BUILD_FORTRAN
+-noinst_PROGRAMS = ctest0 ftest0
+-else 
+-noinst_PROGRAMS = ctest0
+-endif
+-else
+-noinst_PROGRAMS = ctest0
+-endif
+-
+ ## Information for building the "ncgen" program
+ ncgen_SOURCES = close.c escapes.c generate.c genlib.c getfill.c init.c      \
+                 load.c main.c ncgentab.c