CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > OpenFOAM Installation

Compilation Error (V 1.7.1; Icc 12.1.0, OpenMPI 1.4.3)

Register Blogs Members List Search Today's Posts Mark Forums Read

Reply
 
LinkBack Thread Tools Display Modes
Old   December 15, 2011, 09:32
Default Compilation Error (V 1.7.1; Icc 12.1.0, OpenMPI 1.4.3)
  #1
New Member
 
Soon-Heum "Jeff" Ko
Join Date: Dec 2011
Posts: 5
Rep Power: 5
floydfan is on a distinguished road
Hello,

I followed the instruction from the wiki, while compilation continuously fails.


System:
-- Linux 2.6.18-274.7.1.el5 (CentOS 5)
-- Use system-installed intel compiler (v 12.1.0)
-- Use system-installed OpenMPI (v 1.4.3)
-- Use system-installed paraView (v 3.10.1)
-- default gcc v. 4.1.2, thus gcc44 replaces gcc function calls


Configuration changes:

in etc/bashrc
-- Line 118 (Default Compiler)
WM_COMPILER:=Icc
-- Line 135 (MPI setup)
WM_MPLIB:=SYSTEMOPENMPI
-- Line 170,171 (Environment setup for x86_64, 64bit)
export WM_CC='gcc44'
export WM_CXX='g++44'

-- Line 260 (paraView source)
Comment out _foamSource paraview3/bashrc

in etc/settings.sh
-- edit SYSTEMOPENMPI's PINC and PLIBS flag (add system-supported optimization flag)


and tried the compilation under OpenFOAM-1.7.1 directory with
./Allwmake >& makeAll.log



The first compilation error comes with

compilation aborted for derivedFvPatchFields/turbulentHeatFluxTemperature/turbulentHeatFluxTemperatureFvPatchScalarField.C (code 2)
2make: *** [Make/linux64IccDPOpt/turbulentHeatFluxTemperatureFvPatchScalarField.o] Error 2

and a number of error are followed due to the absence of libcompressibleRASModel.so

ld: cannot find -lcompressibleRASModels
make: *** [$USERS_HOME/OpenFOAM/OpenFOAM-1.7.1/lib/linux64IccDPOpt/liblagrangianIntermediate.so] Error 1


I wonder if the error could be caused either by
the false compilation of third-party libraries (especially scotch - replacing WM_CC variable to gcc44 does not seem to work properly) or
false compilation flag (some OpenFOAM functions incompiatible with latest intel compiler) or
any other reason which I cannot estimate.


I am enclosing the complete log file (which is split into 4 due to the file size limitation on wiki).

Can anybody help me with this?


Best,
Jeff
Attached Files
File Type: gz makeThird.tar.gz (12.7 KB, 2 views)
File Type: gz makeAll.1.tar.gz (85.9 KB, 3 views)
File Type: gz makeAll.2.tar.gz (81.2 KB, 2 views)
File Type: gz makeAll.3.tar.gz (85.6 KB, 3 views)
floydfan is offline   Reply With Quote

Old   December 17, 2011, 20:32
Default
  #2
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 8,511
Blog Entries: 34
Rep Power: 86
wyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nice
Greetings Jeff and welcome to the forum!

I won't be able to try and reproduce your steps for a few more days, but I suggest the following ideas:
  • About the issue with Scotch, use "ThirdParty-2.0.1" instead of "ThirdParty-1.7.1". Or at the very least, check the changes made in the "Allwmake" between both versions.
  • After searching for the error, I found in the 2nd "makeAll" log file:
    Quote:
    Code:
    derivedFvPatchFields/turbulentHeatFluxTemperature/turbulentHeatFluxTemperatureFvPatchScalarField.C(44): error: member "Foam::NamedEnum<Enum, nEnum>::names [with Enum=Foam::compressible::turbulentHeatFluxTemperatureFvPatchScalarField::heatSourceType, nEnum=2]" cannot be specialized in the current scope
      names[] =
      ^
    Compare the old file with the new file: https://github.com/OpenCFD/OpenFOAM-...hScalarField.C vs https://github.com/OpenFOAM/OpenFOAM...hScalarField.C
    You should be able to see that the comment on the new file which indicates what needs to be placed outside of the deeper namespace onto just the "Foam" namespace:
    Code:
    // declare specialization within 'Foam' namespace
You can save yourself some punishment by either using:
  • gcc 4.5 + OpenFOAM 1.7.1 - Gcc 4.5 has been known to be faster than Icc.
  • Icc 12.1 + OpenFOAM 2.0.1 (preferably 2.0.x) - the latest OpenFOAM is compatible with the newer Icc versions.
Otherwise, there are a few more errors that you are going to trip on and have to compare the two versions for figuring out those errors.


Best regards,
Bruno
wyldckat is offline   Reply With Quote

Old   December 18, 2011, 08:38
Default
  #3
New Member
 
Soon-Heum "Jeff" Ko
Join Date: Dec 2011
Posts: 5
Rep Power: 5
floydfan is on a distinguished road
Dear Bruno,
  • gcc 4.5 + OpenFOAM 1.7.1 - Gcc 4.5 has been known to be faster than Icc.
  • Icc 12.1 + OpenFOAM 2.0.1 (preferably 2.0.x) - the latest OpenFOAM is compatible with the newer Icc versions.

Thanks for your suggestion. Let me try with the latest OpenFOAM first and come back to you with the result.

Best,
Jeff
floydfan is offline   Reply With Quote

Old   December 18, 2011, 11:36
Default
  #4
New Member
 
Soon-Heum "Jeff" Ko
Join Date: Dec 2011
Posts: 5
Rep Power: 5
floydfan is on a distinguished road
Dear Bruno,

Following your suggestion, I tried OpenFOAM 2.0.1. I started with Third Party compilation. As I mentioned earlier, I am considering to use ICC, OpenMPI (with Intel compiler), system-installed paraview. Thus, third-party installation will only compile scotch library.

In a word, compilation ends up with the error (line 1056 in enclosed file):

cp -f ../bin/[agm]* $HOME/OpenFOAM/ThirdParty-2.0.1/platforms/linux64Icc/scotch_5.1.11/bin
cp: cannot stat `../bin/[agm]*': No such file or directory
make: [install] Error 1 (ignored)

The MPI compiling seems to have failed and I assume if scotch library requires gcc + gcc-based MPI library (as I mentioned above, MPICC refers to intel compiler, while gcc44 is used to compile sequential part).

Questions are,

1) GCC-based MPI is mandatory for scotch?
2) If scotch is compiled under Intel compiler, that library is still compatible with OpenFOAM? If so, how do I set the configuration file (Makefile.inc.i686_pc_linux2.shlib-OpenFOAM-64) and Allwmake?

Thank you in advance.

Best,
Jeff

p.s. FYI, I am presenting some of environmental variables for OpenFOAM configuration:

declare -x WM_ARCH="linux64"
declare -x WM_ARCH_OPTION="64"
declare -x WM_CC="gcc44"
declare -x WM_CFLAGS="-m64 -fPIC"
declare -x WM_COMPILER="Icc"
declare -x WM_COMPILER_LIB_ARCH="64"
declare -x WM_COMPILE_OPTION="Opt"
declare -x WM_CXX="g++44"
declare -x WM_CXXFLAGS="-m64 -fPIC"
declare -x WM_LDFLAGS="-m64"
declare -x WM_LINK_LANGUAGE="c++"
declare -x WM_MPLIB="SYSTEMOPENMPI"
declare -x WM_OPTIONS="linux64IccDPOpt"
declare -x WM_OSTYPE="POSIX"
Attached Files
File Type: gz makeThird.tar.gz (10.4 KB, 2 views)
floydfan is offline   Reply With Quote

Old   December 18, 2011, 12:30
Default
  #5
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 8,511
Blog Entries: 34
Rep Power: 86
wyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nice
Hi Jeff,

Quote:
cp: cannot stat `../bin/[agm]*': No such file or directory
make: [install] Error 1 (ignored)
Don't worry about this error, because the Scotch executables aren't needed for OpenFOAM.
According to the log, everything went fine. Run Allwmake in the "ThirdParty-2.0.1" again if you don't believe me

Well, technically not 100% fine, because Intel's libraries gave out this warning:
Quote:
warning: feupdateenv is not implemented and will always fail
I'm not sure if this will hurt execution, but after you finish building OpenFOAM 2.0.1, run the tutorial located at "incompressible/windSimpleFoam", which will confirm if ptscotch is working as intended.

Good luck!
Bruno
wyldckat is offline   Reply With Quote

Old   December 18, 2011, 12:36
Default
  #6
New Member
 
Soon-Heum "Jeff" Ko
Join Date: Dec 2011
Posts: 5
Rep Power: 5
floydfan is on a distinguished road
Quote:
Originally Posted by wyldckat View Post
after you finish building OpenFOAM 2.0.1, run the tutorial located at "incompressible/windSimpleFoam", which will confirm if ptscotch is working as intended.
Thanks Bruno. Let me proceed with the compilation and come back to you with the result.

Best,
Jeff
floydfan is offline   Reply With Quote

Old   December 20, 2011, 06:44
Default
  #7
New Member
 
Soon-Heum "Jeff" Ko
Join Date: Dec 2011
Posts: 5
Rep Power: 5
floydfan is on a distinguished road
Dear Bruno,

Fortunately it seems to be running fine. Testrun on windSimpleFoam finishes without any error. Thanks for lots of help.

BTW, how can I link the OpenFOAM with system-supported paraview? Which wrapper do I need to touch to set up environmental variables? Could you recommend me any webpages I can refer to?

Thanks,
Jeff
floydfan is offline   Reply With Quote

Old   December 20, 2011, 06:56
Default
  #8
Super Moderator
 
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 8,511
Blog Entries: 34
Rep Power: 86
wyldckat is just really nicewyldckat is just really nicewyldckat is just really nicewyldckat is just really nice
Hi Jeff,

If you can run "paraview" without any changes on the command line, then there is no need to change anything, although you'll have to use the "-builtin" argument:
Code:
paraFoam -builtin
If it's not visible by default, edit the file "OpenFOAM-2.0.1/etc/config/paraview.sh".

If you need the official OpenFOAM plug-ins, you'll need to build your own custom build of ParaView. With any luck, if you build the same version of ParaView as the one on your system, perhaps you can then use the then newly built plug-ins with the system's ParaView.

Check my signature link, there is a link in there for another blog post of mine about ParaView+OpenFOAM

Best regards,
Bruno
wyldckat is offline   Reply With Quote

Reply

Tags
1.7.1, icc, openfoam, openmpi

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
openfoam 1.7.1 compilation ehsan OpenFOAM 5 December 6, 2010 21:44


All times are GMT -4. The time now is 05:55.