On 01/01/2015 10:52 PM, Ernest L Williams wrote:
Hi I am trying to cross-compile hdf5 for a different architecture: I get the following error in the configuration stage: ======================================= configure:23533: error: cannot run test program while cross compiling ========================================
HDF5 uses AC_TRY_RUN in way too many places. It makes cross compiling a gigantic pain.
Workaround: set a pile of environment variables. Most of the tests are obvious: checking for example if you are not running on an HP-UX machine with a buggy compiler from 1998 (I think I have exaggerated that slightly... but only slightly)
Fortunately, they do not seem to be adding any *new* instances of AC_TRY_RUN, so once you set up all the needed environment variables, you'll be set for the next several release cycles.
To get you started, here's a shell script (attached) I use with lots of the necessary environment variables set. Richard Hedges got me most of the way a few years back (in the 1.6 days), and so I pay it forward to you. I did this for Blue Gene, so usual caveats apply: I have no idea what the right values should be for your environment.
Oh, note the one odd step: you have to make one c file in normal mode, then re-configure everything for cross compiling.
==rob -- Rob Latham Mathematics and Computer Science Division Argonne National Lab, IL USA
bgq-hdf5build18.sh
Description: application/shellscript
_______________________________________________ Hdf-forum is for HDF software users discussion. [email protected] http://mail.lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org Twitter: https://twitter.com/hdf5
