|
[Sponsors] |
October 4, 2016, 16:47 |
Compiling cfMesh with OpenFOAM 4.x
|
#1 | |
Member
Dan Kokron
Join Date: Dec 2012
Posts: 33
Rep Power: 13 |
Quote:
Code:
git clone git://git.code.sf.net/p/cfmesh/code cfmesh Here's the compile time error. Code:
icpc -std=c++11 -fp-trap=common -fp-model precise -Dlinux64 -DWM_ARCH_OPTION=64 -DWM_DP -DWM_LABEL_SIZE=32 -Wall -Wextra -Wnon-virtual-dtor -Wno-unused-parameter -Wno-invalid-offsetof -diag-disable 327,654,1125,2289,2304,11062,11074,11076 -O3 -DNoRepository -I../../meshLibrary/lnInclude -I/home/dkokron/OpenFOAM/OpenFOAM-4.x/src/triSurface/lnInclude -I/home/dkokron/OpenFOAM/OpenFOAM-4.x/src/meshTools/lnInclude -I/home/dkokron/OpenFOAM/OpenFOAM-4.x/src/edgeMesh/lnInclude -IlnInclude -I. -I/home/dkokron/OpenFOAM/OpenFOAM-4.x/src/OpenFOAM/lnInclude -I/home/dkokron/OpenFOAM/OpenFOAM-4.x/src/OSspecific/POSIX/lnInclude -fPIC -c FLMAToSurface.C -o Make/linux64IccDPInt32Opt/FLMAToSurface.o ../../meshLibrary/lnInclude/DynListI.H(42): error #373: "void Foam::UList<T>::operator=(const Foam::UList<T> &) [with T=Foam::label={int32_t={int}}]" (declared at line 93 of "/home/dkokron/OpenFOAM/OpenFOAM-4.x/src/OpenFOAM/lnInclude/UList.H") is inaccessible this->UList<T>::operator=(UList<T>(newData, s)); ^ detected during: instantiation of "void Foam::DynList<T, staticSize>::allocateSize(Foam::label={int32_t={int}}) [with T=Foam::label={int32_t={int}}, staticSize=16]" at line 214 instantiation of "void Foam::DynList<T, staticSize>::append(const T &) [with T=Foam::label={int32_t={int}}, staticSize=16]" at line 98 of "../../meshLibrary/lnInclude/triSurfPointsI.H" Last edited by wyldckat; October 10, 2016 at 19:59. Reason: see "Moderator note:" |
||
October 9, 2016, 16:58 |
|
#2 |
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,982
Blog Entries: 45
Rep Power: 128 |
Quick answer: You need to checkout the "development" branch. Complete list of commands:
Code:
git clone git://git.code.sf.net/p/cfmesh/code cfmesh cd cfmesh git checkout development export WM_NCOMPPROCS=4 time ./Allwmake > log.make 2>&1
__________________
|
|
October 10, 2016, 14:53 |
|
#3 |
Member
Dan Kokron
Join Date: Dec 2012
Posts: 33
Rep Power: 13 |
I confirmed that the 'development' branch does indeed build and run under 4.x. I also confirmed essentially zero-diff output for one of my geometries compared with cfMesh-1.1.1 built against OF-3.0+.
Thanks again Bruno. |
|
October 11, 2016, 17:26 |
|
#4 | |
Retired Super Moderator
Bruno Santos
Join Date: Mar 2009
Location: Lisbon, Portugal
Posts: 10,982
Blog Entries: 45
Rep Power: 128 |
Just a quick note: They have released cfMesh 1.2.1 recently: https://twitter.com/CFieldsHR/status/785774036206755840
Quote:
|
||
April 6, 2017, 07:43 |
|
#5 |
New Member
Giampaolo Cetraro
Join Date: Oct 2012
Posts: 14
Rep Power: 14 |
Hello I've successfully compiled cfMesh-v1.1.2 with OpenFOAM-4.1 and it works very well.
However when I try to mesh something with a smaller cell size I get this error Code:
Create time Setting root cube size and refinement parameters Root box (-16.4988893 -17.6854167 -15.189) (16.2691107 15.0825833 17.579) Requested cell size corresponds to octree level 10 Refining boundary Refining boundary boxes to the given size --> FOAM FATAL ERROR: Negative size requested. From function template<class T, Foam::label Offset> inline void Foam::LongList<T, Offset>::allocateSize(const label) in file lnInclude/LongListI.H at line 73. FOAM aborting #0 Foam::error::printStack(Foam::Ostream&) at ??:? #1 Foam::error::abort() at ??:? #2 Foam::meshOctreeCube::findLeaves(Foam::LongList<Foam::meshOctreeCube*, 19>&) const at ??:? #3 Foam::meshOctreeCube::findLeaves(Foam::LongList<Foam::meshOctreeCube*, 19>&) const at ??:? #4 Foam::meshOctreeCube::findLeaves(Foam::LongList<Foam::meshOctreeCube*, 19>&) const at ??:? #5 Foam::meshOctreeCube::findLeaves(Foam::LongList<Foam::meshOctreeCube*, 19>&) const at ??:? I thought I had too many cells so I tried to compile cfMesh against OpenFOAM-4.1 with WM_LABEL_SIZE=64 Unfortunately I get this compilation error Code:
lnInclude/DynListI.H: In instantiation of ‘Foam::DynList<T, staticSize>::DynList(const ListType&) [with ListType = int; T = long int; long int staticSize = 16l]’: lnInclude/helperFunctionsTopologyManipulationI.H:491:34: required from here lnInclude/DynListI.H:195:15: error: request for member ‘size’ in ‘l’, which is of non-class type ‘const int’ setSize(l.size()); ~~^~~~ lnInclude/DynListI.H:197:32: error: subscripted value is neither array nor pointer this->operator[](i) = l[i]; ~^ lnInclude/DynListI.H: In instantiation of ‘Foam::DynList<T, staticSize>::DynList(const ListType&) [with ListType = int; T = Foam::Vector2D<double>; long int staticSize = 6l]’: lnInclude/helperFunctionsGeometryQueriesI.H:1059:37: required from here lnInclude/DynListI.H:195:15: error: request for member ‘size’ in ‘l’, which is of non-class type ‘const int’ setSize(l.size()); ~~^~~~ lnInclude/DynListI.H:197:32: error: subscripted value is neither array nor pointer this->operator[](i) = l[i]; ~^ make: *** [Make/linux64Gcc62DPInt64Opt/utilities/meshes/polyMeshGenModifier/polyMeshGenModifierAddBufferCells.o] Error 1 Thank you Giampaolo |
|
August 17, 2017, 22:18 |
OpenFOAM-dev not compiling due to metaDict_
|
#6 |
New Member
Bernard
Join Date: Feb 2017
Posts: 4
Rep Power: 9 |
*Edit* I have gone further along in the compilation. The original problem was metaDict_
Here is the list of steps I encountered and what I did to combat them: 1. metaDict_ not declared. Added "IOdictionary.H to polyMeshGen.H 2. The annoying tautology warning can be removed by changing ms.type_ != ms.type_ to ms.type != type_ in meshSubsetI.H 3. edgeMesh has been incorporated into meshTools in OF5 and dev. I did an in-place replacement of -ledgeMesh with nothing 4. Pstream::blocking and Pstream::scheduled have been replaced by Pstream::commsTypes::blocking and Pstream::commsTypes::scheduled - I replaced these 5. My foam compilation was done with WM_LABEL_SIZE=64. This seems to kill the compilation as it can't recognise a list in these circumstances (see Giampalo's error) 6. Set the WM_LABEL_SIZE to 32, meshLibrary compiles, but errors occur straight away once we try and build the executables. I saw the approach proposed by laurent in thread 160757 but that has since changed. I am thinking of going back to LABEL_SIZE of 64 and trying to sort out the problem there. I now have heaps more problems after this. First errors start at first program in the rank: cartesian2DMesh. See error message attached. Any help would be greatly appreciated. Last edited by berny.tuegs; August 18, 2017 at 02:57. Reason: moved along in compilation |
|
October 9, 2017, 04:12 |
Compilation of cfMesh works
|
#7 | |
New Member
Stefan Hildenbrand
Join Date: Aug 2009
Location: Stuttgart, Germany
Posts: 24
Rep Power: 17 |
Quote:
|
||
November 2, 2017, 17:12 |
|
#8 | |
Member
Join Date: Nov 2012
Posts: 83
Rep Power: 13 |
Openfoam v1706 will compile with:
Quote:
|
||
November 7, 2017, 00:29 |
|
#9 | |||
Senior Member
|
Quote:
Quote:
Quote:
|
||||
November 8, 2017, 18:34 |
|
#10 |
Senior Member
|
I was able to partially compile the library, by fixing point 1 adding to:
../meshLibrary/lnInclude/polyMeshGen.H Code:
#include "polyMeshGenCells.H" #include "dictionary.H" #include "IOdictionary.H" Code:
find ./ -exec sed -i -e 's/Pstream::blocking/Pstream::commsTypes::blocking/' {} \; Code:
find ./ -exec sed -i -e 's/Pstream::scheduled/Pstream::commsTypes::scheduled/' {} \; Code:
utilities/smoothers/geometry/meshOptimizer/tetMeshOptimisation/tetMeshOptimisation.C:505:67: error: no matching function for call to ‘eigenVector(Foam::symmTensor&, const double&)’ vector normal1 = eigenVector(nt, ev[1]); Code:
utilities/smoothers/geometry/meshOptimizer/tetMeshOptimisation/tetMeshOptimisation.C:498:66: error: no matching function for call to ‘eigenVector(Foam::symmTensor&, const double&)’ vector normal = eigenVector(nt, ev[2]); Thanks a lot I'm compiling on Linux Mint 18.2 with openfoam-dev (last update) |
|
November 10, 2017, 16:03 |
|
#11 |
Senior Member
|
Hi,
please can somebody helps me with this issue? Code:
utilities/smoothers/geometry/meshOptimizer/tetMeshOptimisation/tetMeshOptimisation.C:507:67: error: no matching function for call to ‘eigenVector(Foam::symmTensor&, const double&)’ vector normal2 = eigenVector(nt, ev[2]); ^ In file included from /opt/openfoam-dev/src/OpenFOAM/lnInclude/fieldTypes.H:38:0, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/flipOp.H:40, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/mapDistributeBaseTemplates.C:29, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/mapDistributeBase.H:489, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/FieldMapper.H:35, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/Field.C:26, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/Field.H:408, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/labelField.H:39, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/primitiveFields.H:37, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/pointField.H:36, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/boundBox.H:35, from utilities/smoothers/geometry/meshOptimizer/tetMeshOptimisation/tetMeshOptimisation.H:40, from utilities/smoothers/geometry/meshOptimizer/tetMeshOptimisation/tetMeshOptimisation.C:29: /opt/openfoam-dev/src/OpenFOAM/lnInclude/tensor.H:54:8: note: candidate: Foam::vector Foam::eigenVector(const tensor&, Foam::scalar, const vector&, const vector&) vector eigenVector Regards Last edited by student666; November 11, 2017 at 16:08. |
|
November 13, 2017, 06:16 |
|
#12 |
New Member
Stefan Hildenbrand
Join Date: Aug 2009
Location: Stuttgart, Germany
Posts: 24
Rep Power: 17 |
I downloaded the latest version in git today and now the source compiles without any modifications from the source.
|
|
November 13, 2017, 17:15 |
|
#14 |
Senior Member
|
Hi,
I can't understand, but I'm not able to run the compilation on LinuxMint 18.2. I used Code:
git clone git://git.code.sf.net/p/cfmesh/code cfmesh-code After fixing point 1,3,4, and ./Allwmake, I got this Code:
wmakeLnInclude: linking include files to ./lnInclude could not open file foamTime.H for source file utilities/workflowControls/workflowControls.C due to No such file or directory could not open file foamTime.H for source file utilities/dataConversion/foamToFPMA/fpmaMesh.C due to No such file or directory could not open file foamTime.H for source file utilities/dataConversion/foamToFPMA/writeMeshFPMA.C due to No such file or directory could not open file foamTime.H for source file voronoiMesh/voronoiMeshGenerator/voronoiMeshGenerator.C due to No such file or directory could not open file foamTime.H for source file voronoiMesh/voronoiMeshExtractor/voronoiMeshExtractorCreateMesh.C due to No such file or directory could not open file foamTime.H for source file voronoiMesh/voronoiMeshExtractor ... ... ... ... Code:
utilities/smoothers/geometry/meshOptimizer/tetMeshOptimisation/tetMeshOptimisation.C: In member function ‘void Foam::tetMeshOptimisation::optimiseBoundaryVolumeOptimizer(Foam::label, bool)’: utilities/smoothers/geometry/meshOptimizer/tetMeshOptimisation/tetMeshOptimisation.C:498:66: error: no matching function for call to ‘eigenVector(Foam::symmTensor&, const double&)’ vector normal = eigenVector(nt, ev[2]); ^ In file included from /opt/openfoam-dev/src/OpenFOAM/lnInclude/fieldTypes.H:38:0, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/flipOp.H:40, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/mapDistributeBaseTemplates.C:29, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/mapDistributeBase.H:489, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/FieldMapper.H:35, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/Field.C:26, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/Field.H:408, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/labelField.H:39, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/primitiveFields.H:37, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/pointField.H:36, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/boundBox.H:35, from utilities/smoothers/geometry/meshOptimizer/tetMeshOptimisation/tetMeshOptimisation.H:40, from utilities/smoothers/geometry/meshOptimizer/tetMeshOptimisation/tetMeshOptimisation.C:29: /opt/openfoam-dev/src/OpenFOAM/lnInclude/tensor.H:54:8: note: candidate: Foam::vector Foam::eigenVector(const tensor&, Foam::scalar, const vector&, const vector&) vector eigenVector ^ /opt/openfoam-dev/src/OpenFOAM/lnInclude/tensor.H:54:8: note: candidate expects 4 arguments, 2 provided /opt/openfoam-dev/src/OpenFOAM/lnInclude/tensor.H:65:8: note: candidate: Foam::vector Foam::eigenVector(const symmTensor&, Foam::scalar, const vector&, const vector&) vector eigenVector ^ /opt/openfoam-dev/src/OpenFOAM/lnInclude/tensor.H:65:8: note: candidate expects 4 arguments, 2 provided utilities/smoothers/geometry/meshOptimizer/tetMeshOptimisation/tetMeshOptimisation.C:505:67: error: no matching function for call to ‘eigenVector(Foam::symmTensor&, const double&)’ vector normal1 = eigenVector(nt, ev[1]); ^ In file included from /opt/openfoam-dev/src/OpenFOAM/lnInclude/fieldTypes.H:38:0, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/flipOp.H:40, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/mapDistributeBaseTemplates.C:29, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/mapDistributeBase.H:489, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/FieldMapper.H:35, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/Field.C:26, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/Field.H:408, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/labelField.H:39, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/primitiveFields.H:37, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/pointField.H:36, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/boundBox.H:35, from utilities/smoothers/geometry/meshOptimizer/tetMeshOptimisation/tetMeshOptimisation.H:40, from utilities/smoothers/geometry/meshOptimizer/tetMeshOptimisation/tetMeshOptimisation.C:29: /opt/openfoam-dev/src/OpenFOAM/lnInclude/tensor.H:54:8: note: candidate: Foam::vector Foam::eigenVector(const tensor&, Foam::scalar, const vector&, const vector&) vector eigenVector ^ /opt/openfoam-dev/src/OpenFOAM/lnInclude/tensor.H:54:8: note: candidate expects 4 arguments, 2 provided /opt/openfoam-dev/src/OpenFOAM/lnInclude/tensor.H:65:8: note: candidate: Foam::vector Foam::eigenVector(const symmTensor&, Foam::scalar, const vector&, const vector&) vector eigenVector ^ /opt/openfoam-dev/src/OpenFOAM/lnInclude/tensor.H:65:8: note: candidate expects 4 arguments, 2 provided utilities/smoothers/geometry/meshOptimizer/tetMeshOptimisation/tetMeshOptimisation.C:507:67: error: no matching function for call to ‘eigenVector(Foam::symmTensor&, const double&)’ vector normal2 = eigenVector(nt, ev[2]); ^ In file included from /opt/openfoam-dev/src/OpenFOAM/lnInclude/fieldTypes.H:38:0, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/flipOp.H:40, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/mapDistributeBaseTemplates.C:29, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/mapDistributeBase.H:489, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/FieldMapper.H:35, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/Field.C:26, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/Field.H:408, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/labelField.H:39, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/primitiveFields.H:37, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/pointField.H:36, from /opt/openfoam-dev/src/OpenFOAM/lnInclude/boundBox.H:35, from utilities/smoothers/geometry/meshOptimizer/tetMeshOptimisation/tetMeshOptimisation.H:40, from utilities/smoothers/geometry/meshOptimizer/tetMeshOptimisation/tetMeshOptimisation.C:29: /opt/openfoam-dev/src/OpenFOAM/lnInclude/tensor.H:54:8: note: candidate: Foam::vector Foam::eigenVector(const tensor&, Foam::scalar, const vector&, const vector&) vector eigenVector ^ /opt/openfoam-dev/src/OpenFOAM/lnInclude/tensor.H:54:8: note: candidate expects 4 arguments, 2 provided /opt/openfoam-dev/src/OpenFOAM/lnInclude/tensor.H:65:8: note: candidate: Foam::vector Foam::eigenVector(const symmTensor&, Foam::scalar, const vector&, const vector&) vector eigenVector ^ /opt/openfoam-dev/src/OpenFOAM/lnInclude/tensor.H:65:8: note: candidate expects 4 arguments, 2 provided make: *** [Make/linux64GccDPInt32Opt/utilities/smoothers/geometry/meshOptimizer/tetMeshOptimisation/tetMeshOptimisation.o] Error 1 could not open file foamTime.H for source file cartesian2DMesh.C due to No such file or directory /usr/bin/ld: cannot find -ledgeMesh /usr/bin/ld: cannot find -lmeshLibrary collect2: error: ld returned 1 exit status make[1]: *** [/home/michele/OpenFOAM/michele-dev/platforms/linux64GccDPInt32Opt/bin/cartesian2DMesh] Error 1 make: *** [cartesian2DMesh] Error 2 /usr/bin/ld: cannot find -ledgeMesh /usr/bin/ld: cannot find -lmeshLibrary collect2: error: ld returned 1 exit status make[1]: *** [/home/michele/OpenFOAM/michele-dev/platforms/linux64GccDPInt32Opt/bin/checkSurfaceMesh] Error 1 make: *** [checkSurfaceMesh] Error 2 |
|
November 14, 2017, 03:51 |
|
#15 |
New Member
Stefan Hildenbrand
Join Date: Aug 2009
Location: Stuttgart, Germany
Posts: 24
Rep Power: 17 |
You need to get the development branch, see post #2
Code:
git checkout development |
|
August 15, 2018, 12:26 |
|
#17 | |
Senior Member
Zander Meiring
Join Date: Jul 2018
Posts: 125
Rep Power: 8 |
Quote:
also getting this issue. Did you manage to solve it? |
||
|
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
Frequently Asked Questions about Installing OpenFOAM | wyldckat | OpenFOAM Installation | 3 | November 14, 2023 12:58 |
Error compiling DES in OpenFoam v1612+ | VisMart | OpenFOAM Programming & Development | 4 | July 18, 2017 10:11 |
OpenFOAM Training Jan-Jul 2017, Virtual, London, Houston, Berlin | CFDFoundation | OpenFOAM Announcements from Other Sources | 0 | January 4, 2017 07:15 |
UNIGE February 13th-17th - 2107. OpenFOAM advaced training days | joegi.geo | OpenFOAM Announcements from Other Sources | 0 | October 1, 2016 20:20 |
Compiling OpenFOAM on hpc-fe.gbar.dtu.dk | kaergaard | OpenFOAM Installation | 1 | June 16, 2011 02:33 |