configure get error in AIX(ksh)
While I run this commond in parallel-netcdf-1.10.0
./configure --prefix=/gza/u/xiaohui/g6/code_test/PnetCDF --host power
I got this error
checking if Fortran compiler is NAG... ./configure[28135]: conftest.ver: bad file unit number
and can not get makefile so on I wonder how to solve it Thank you!
The error message indicates your MPI Fortran compiler has a problem with command-line argument -V. Please provide the link to your config.log file and I will take a look.
Thank you for your reply. Here is the link: https://github.com/poohRui/someIssues/blob/master/config.log
Could you please apply the following patch and let me know if it works?
--- a/acinclude.m4
+++ b/acinclude.m4
@@ -1578,8 +1578,7 @@ dnl
AC_DEFUN([UD_CHECK_FC_NAG],[
AC_CACHE_CHECK([if Fortran compiler is NAG], [ac_cv_fc_compiler_nag],
[ac_cv_fc_compiler_nag=no
- eval $MPIF90 -V </dev/null >& conftest.ver
- _FC_VENDOR=`head -c 3 conftest.ver`
+ _FC_VENDOR=`eval $MPIF90 -V 2>&1 | head -c 3`
if test "x${_FC_VENDOR}" = xNAG ; then
ac_cv_fc_compiler_nag=yes
fi
- ${RM} -f conftest.ver
unset _FC_VENDOR
])
])
I have never tested PnetCDF on ksh. It appears that ksh's stdout and stderr redirection is different from bash.
I think you mean this file. Here is the link: https://github.com/poohRui/someIssues/blob/master/acinclude.m4
Yes.
It appears ksh does not work well with automake. A bug report of configure hanging can be found in https://lists.gnu.org/archive/html/bug-automake/2015-04/msg00000.html
Thank you! After I changed the shell to bash, The error disappeared.
Close this issue, as ksh is not supported. It can be reopened, if ksh is to be supported in the future.