1

在执行 ./Allwmake 时出现模棱两可的错误。错误如下。

Found nvcc  --  enabling CUDA support.
SOURCE=lduMatrixConversion/lduMatrixConversion.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -O3  -DNoRepository -ftemplate-depth-100 -I/home/suraj/ispm-sparse-lib-master -isystem /usr/local/cuda-7.5/include  -IlnInclude -I. -I/home/suraj/OpenFOAM/OpenFOAM-2.4.x/src/OpenFOAM/lnInclude -I/home/suraj/OpenFOAM/OpenFOAM-2.4.x/src/OSspecific/POSIX/lnInclude   -fPIC -c $SOURCE -o Make/linux64Gcc48DPOpt/lduMatrixConversion.o
SOURCE=GPUPCG/GPUPCG.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -O3  -DNoRepository -ftemplate-depth-100 -I/home/suraj/ispm-sparse-lib-master -isystem /usr/local/cuda-7.5/include  -IlnInclude -I. -I/home/suraj/OpenFOAM/OpenFOAM-2.4.x/src/OpenFOAM/lnInclude -I/home/suraj/OpenFOAM/OpenFOAM-2.4.x/src/OSspecific/POSIX/lnInclude   -fPIC -c $SOURCE -o Make/linux64Gcc48DPOpt/GPUPCG.o
SOURCE=AsyncPrecondProvider/AsyncPrecondProvider.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -O3  -DNoRepository -ftemplate-depth-100 -I/home/suraj/ispm-sparse-lib-master -isystem /usr/local/cuda-7.5/include  -IlnInclude -I. -I/home/suraj/OpenFOAM/OpenFOAM-2.4.x/src/OpenFOAM/lnInclude -I/home/suraj/OpenFOAM/OpenFOAM-2.4.x/src/OSspecific/POSIX/lnInclude   -fPIC -c $SOURCE -o Make/linux64Gcc48DPOpt/AsyncPrecondProvider.o
SOURCE=GPUSolverData/GPUSolverData.C ;  g++ -m64 -Dlinux64 -DWM_DP -Wall -Wextra -Wno-unused-parameter -Wold-style-cast -O3  -DNoRepository -ftemplate-depth-100 -I/home/suraj/ispm-sparse-lib-master -isystem /usr/local/cuda-7.5/include  -IlnInclude -I. -I/home/suraj/OpenFOAM/OpenFOAM-2.4.x/src/OpenFOAM/lnInclude -I/home/suraj/OpenFOAM/OpenFOAM-2.4.x/src/OSspecific/POSIX/lnInclude   -fPIC -c $SOURCE -o Make/linux64Gcc48DPOpt/GPUSolverData.o
In file included from /home/suraj/OpenFOAM/OpenFOAM-2.4.x/src/OpenFOAM/lnInclude/MeshObject.H:281,
                 from lnInclude/solverPersistentData.H:43,
                 from GPUPCG/GPUPCG.H:43,
                 from GPUPCG/GPUPCG.C:32:
/home/suraj/OpenFOAM/OpenFOAM-2.4.x/src/OpenFOAM/lnInclude/MeshObject.C: In static member function ‘static const Type& Foam::MeshObject<Mesh, MeshObjectType, Type>::New(const Mesh&) [with Mesh = Foam::lduMesh, MeshObjectType = Foam::UpdateableMeshObject, Type = Foam::solverPersistentData<Foam::lduMesh, Foam::GPUSolverData>]’:
GPUPCG/GPUPCG.C:65:   instantiated from here
/home/suraj/OpenFOAM/OpenFOAM-2.4.x/src/OpenFOAM/lnInclude/MeshObject.C:48: error: reference to ‘Foam::solverPersistentData<Foam::lduMesh, Foam::GPUSolverData>::typeName’ is ambiguous
/home/suraj/OpenFOAM/OpenFOAM-2.4.x/src/OpenFOAM/lnInclude/IOobject.H:177: error: candidates are: const Foam::word Foam::IOobject::typeName
/home/suraj/OpenFOAM/OpenFOAM-2.4.x/src/OpenFOAM/lnInclude/regIOobject.H:125: error:                 const Foam::word Foam::regIOobject::typeName
/home/suraj/OpenFOAM/OpenFOAM-2.4.x/src/OpenFOAM/lnInclude/MeshObject.H:168: error:                 const Foam::word Foam::meshObject::typeName
lnInclude/solverPersistentData.H:66: error:                 const Foam::word Foam::solverPersistentDataName::typeName
/home/suraj/OpenFOAM/OpenFOAM-2.4.x/src/OpenFOAM/lnInclude/MeshObject.C:59: error: reference to ‘Foam::solverPersistentData<Foam::lduMesh, Foam::GPUSolverData>::typeName’ is ambiguous
/home/suraj/OpenFOAM/OpenFOAM-2.4.x/src/OpenFOAM/lnInclude/IOobject.H:177: error: candidates are: const Foam::word Foam::IOobject::typeName
/home/suraj/OpenFOAM/OpenFOAM-2.4.x/src/OpenFOAM/lnInclude/regIOobject.H:125: error:                 const Foam::word Foam::regIOobject::typeName
/home/suraj/OpenFOAM/OpenFOAM-2.4.x/src/OpenFOAM/lnInclude/MeshObject.H:168: error:                 const Foam::word Foam::meshObject::typeName
lnInclude/solverPersistentData.H:66: error:                 const Foam::word Foam::solverPersistentDataName::typeName
/home/suraj/OpenFOAM/OpenFOAM-2.4.x/src/OpenFOAM/lnInclude/MeshObject.C:65: error: reference to ‘Foam::solverPersistentData<Foam::lduMesh, Foam::GPUSolverData>::typeName’ is ambiguous
/home/suraj/OpenFOAM/OpenFOAM-2.4.x/src/OpenFOAM/lnInclude/IOobject.H:177: error: candidates are: const Foam::word Foam::IOobject::typeName
/home/suraj/OpenFOAM/OpenFOAM-2.4.x/src/OpenFOAM/lnInclude/regIOobject.H:125: error:                 const Foam::word Foam::regIOobject::typeName

并且大多数错误是由于代码中的歧义造成的。这些文件是从 OpenFOAM2.4.x 发行版中使用的。可以在线获得。

4

0 回答 0