fppimenta / rheoTool

Toolbox to simulate GNF and viscoelastic fluid flows in OpenFOAM®
GNU General Public License v3.0
159 stars 66 forks source link

blockOperators.C error #52

Closed connorourke closed 3 years ago

connorourke commented 3 years ago

I get the following error compiling with arm compilers (which I know you don't support).

Wondering if you have seen anything similar before, or know what the fix could be?

In file included from operators/blockOperators.C:26:
In file included from operators/blockOperators.H:39:
In file included from operators/div.H:39:
In file included from /lustre/home/ba-corourke/bin/XCI/BUILD_FOAM_TEST/ARM/OpenFOAM-7/src/finiteVolume/lnInclude/volFields.H:37:
In file included from /lustre/home/ba-corourke/bin/XCI/BUILD_FOAM_TEST/ARM/OpenFOAM-7/src/OpenFOAM/lnInclude/GeometricFields.H:34:
In file included from /lustre/home/ba-corourke/bin/XCI/BUILD_FOAM_TEST/ARM/OpenFOAM-7/src/OpenFOAM/lnInclude/GeometricScalarField.H:38:
In file included from /lustre/home/ba-corourke/bin/XCI/BUILD_FOAM_TEST/ARM/OpenFOAM-7/src/OpenFOAM/lnInclude/GeometricField.H:42:
In file included from /lustre/home/ba-corourke/bin/XCI/BUILD_FOAM_TEST/ARM/OpenFOAM-7/src/OpenFOAM/lnInclude/regIOobject.H:41:
In file included from /lustre/home/ba-corourke/bin/XCI/BUILD_FOAM_TEST/ARM/OpenFOAM-7/src/OpenFOAM/lnInclude/IOobject.H:79:
In file included from /lustre/home/ba-corourke/bin/XCI/BUILD_FOAM_TEST/ARM/OpenFOAM-7/src/OpenFOAM/lnInclude/NamedEnum.H:38:
In file included from /lustre/home/ba-corourke/bin/XCI/BUILD_FOAM_TEST/ARM/OpenFOAM-7/src/OpenFOAM/lnInclude/HashTable.H:566:
In file included from /lustre/home/ba-corourke/bin/XCI/BUILD_FOAM_TEST/ARM/OpenFOAM-7/src/OpenFOAM/lnInclude/HashTable.C:30:
In file included from /lustre/home/ba-corourke/bin/XCI/BUILD_FOAM_TEST/ARM/OpenFOAM-7/src/OpenFOAM/lnInclude/List.H:316:
/lustre/home/ba-corourke/bin/XCI/BUILD_FOAM_TEST/ARM/OpenFOAM-7/src/OpenFOAM/lnInclude/List.C:211:26: error: no matching function for call to 'distance'
    List<T>(first, last, std::distance(first, last))
                         ^~~~~~~~~~~~~
operators/div.C:147:13: note: in instantiation of function template specialization 'Foam::List<long>::List<int>' requested here
  labelList cT(6,-1);
            ^
/opt/allinea/20.0.0.0/gcc-9.2.0_Generic-AArch64_SUSE-12_aarch64-linux/lib/gcc/aarch64-linux-gnu/9.2.0/../../../../include/c++/9.2.0/bits/stl_iterator_base_funcs.h:138:5: note: candidate template ignored: substitution failure [with _InputIterator = int]: no type named 'difference_type' in 'std::iterator_traits<int>'
    distance(_InputIterator __first, _InputIterator __last)
    ^
1 error generated.
make: *** [/lustre/home/ba-corourke/bin/XCI/BUILD_FOAM_TEST/ARM/OpenFOAM-7/wmake/rules/General/transform:26: Make/linuxAArch64ClangDPInt64Opt/operators/blockOperators.o] Error 1
connorourke commented 3 years ago

Actually - clearly picking up some gcc libs here gcc-9.2.0_Generic-AArch64_SUSE-12_aarch64-linux. I'll try recompiling OpenFOAM.