0
我試圖在Mac OS X 10.6.8上安裝PETSc科學計算庫。在Mac OS X上安裝PETSc時遇到問題
在配置項目時,我遇到了以下錯誤消息:
cls ~/Downloads/petsc-3.2-p6 $ ./configure
===============================================================================
Configuring PETSc to compile on your system
===============================================================================
TESTING: checkFortranNameMangling from config.compilers(config/BuildSystem/config/compilers.py:589) *******************************************************************************
UNABLE to CONFIGURE with GIVEN OPTIONS (see configure.log for details):
-------------------------------------------------------------------------------
Unknown Fortran name mangling: Are you sure the C and Fortran compilers are compatible?
Perhaps one is 64 bit and one is 32 bit?
See http://www.mcs.anl.gov/petsc/petsc-as/documentation/faq.html#gfortran
*******************************************************************************
我有以下版本的gcc
cls ~/Downloads/petsc-3.2-p6 $ gcc --version
i686-apple-darwin10-llvm-gcc-4.2 (GCC) 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2336.1.00)
Copyright (C) 2007 Free Software Foundation, Inc.
和gfortran
cls ~/Downloads/petsc-3.2-p6 $ gfortran --version
GNU Fortran (GCC) 4.2.3
Copyright (C) 2007 Free Software Foundation, Inc.
爲什麼這些不兼容?
按照要求,這裏是二進制文件駐留: 在/ usr/local/bin目錄/ gfortran 在/ usr/bin中/ GCC 「試着找出伴隨gfortran的構建你的gcc編譯」 我在這種情況下,不明白「伴隨構建」是什麼意思。 – clstaudt 2012-03-14 12:45:43
從不同的路徑可以猜測,你的gfortran來自不同的來源,而不是gcc。試着從你有你的gcc的同一個來源找到一個LLVM gfortran。 – 2012-03-14 14:08:52
如果你運行'file/usr/local/bin/gfortran/usr/bin/gcc',它會告訴你這些二進制文件的結構(即32位和/或64位)。 – Deditos 2012-03-14 20:57:35