[h5py] 89/455: Windows compile info doc; fix HDF5 vs MinGW ssize_t issue

Ghislain Vaillant ghisvail-guest at moszumanska.debian.org
Thu Jul 2 18:19:21 UTC 2015


This is an automated email from the git hooks/post-receive script.

ghisvail-guest pushed a commit to annotated tag 1.3.0
in repository h5py.

commit 6e8ef9109da73d19393b35176897f69104a0a64d
Author: andrewcollette <andrew.collette at gmail.com>
Date:   Wed Jul 30 04:10:17 2008 +0000

    Windows compile info doc; fix HDF5 vs MinGW ssize_t issue
---
 docs/windows_build.txt | 45 +++++++++++++++++++++++++++++++++++++++++++++
 setup.py               |  2 +-
 2 files changed, 46 insertions(+), 1 deletion(-)

diff --git a/docs/windows_build.txt b/docs/windows_build.txt
new file mode 100644
index 0000000..6cc222e
--- /dev/null
+++ b/docs/windows_build.txt
@@ -0,0 +1,45 @@
+Building on Windows (experimental)
+
+Python setup:
+1. Install Python 2.5
+2. Go into c:\Python25\Lib\distutils and create distutils.cfg containing:
+[build]
+compiler=mingw32
+
+MinGW setup:
+1. Download and install MinGW to C:\MinGW
+2. Download "pexports" (google for it) utility and put in c:\MinGW\bin
+3. Add C:\MinGW\bin to Windows PATH
+
+HDF5 setup:
+You MUST use the versions build with VS2005!
+
+1. Download pre-build HDF5 1.8.1 (with DLLS) compiled with VS2005:
+ftp://ftp.hdfgroup.org/HDF5/current/bin/windows/5-181-win-vs2005.zip
+2. Download SZIP
+ftp://ftp.hdfgroup.org/lib-external/szip/2.1/bin/windows/szip21-vs2005-enc.zip
+3. Download ZLIB
+ftp://ftp.hdfgroup.org/lib-external/zlib/1.2/bin/windows/zlib123-vs2005.zip
+
+4. Unzip HDF5 to "C:\h181"  You should now have C:\h181\include, etc.
+5. Open SZIP and ZLIB archives and copy their dlls to "C:\h181\dll"
+
+6. Download and install "Microsoft Visual C++ 2005 SP1 Redistributable Package"
+   It must be EXACTLY this, note it's **SP1**, or the HDF5 dll won't load.
+   This is available from Microsoft's web site.
+   
+Create import library
+1. Open a terminal and cd to C:\h181\lib
+2. Run "pexports hdf5dll.dll > hdf5dll.def" to get the list of HDF5 exports
+3. Run "dlltool -D hdf5dll.dll -d hdf5dll.def -l hdf5dll.dll.a" to create
+   an import library that MinGW can handle.
+3. Create the directory C:\h181\dll2
+4. Copy the new file c:\h181\dll\hdf5dll.dll.a into c:\h181\dll2
+5. Add the directory c:\h181\dll (NOT c:\h181\dll2) to your Windows PATH
+
+Compile h5py
+1. Extract h5py to c:\h5py
+2. Run python setup.py build --hdf5=c:\h181
+3. Run python setup.py test --hdf5=c:\h181
+
+Isn't Windows easy to use?
diff --git a/setup.py b/setup.py
index 2134bd8..b4d5897 100644
--- a/setup.py
+++ b/setup.py
@@ -179,7 +179,7 @@ if os.name == 'nt':
     include_dirs = [numpy.get_include(), op.join(opts.HDF5_DIR, 'include')]
     library_dirs = [op.join(opts.HDF5_DIR, 'dll2')]  # Must contain only "hdf5dll.dll.a"
     runtime_dirs = []
-    extra_compile_args = ['-DH5_USE_16_API', '-D_HDF5USEDLL_']
+    extra_compile_args = ['-DH5_USE_16_API', '-D_HDF5USEDLL_', '-DH5_SIZEOF_SSIZE_T=4']
     extra_link_args = []
 
 else:

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/debian-science/packages/h5py.git



More information about the debian-science-commits mailing list