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

OpenFOAM 14 problem with file readSTLASCIIL

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   April 12, 2007, 20:36
Default Hello all, Here is a small
  #1
Senior Member
 
Martin Beaudoin
Join Date: Mar 2009
Posts: 332
Rep Power: 22
mbeaudoin will become famous soon enough
Hello all,

Here is a small adjustment proposed to OpenFOAM 1.4 source code.

File : OpenFOAM-1.4/src/triSurface/triSurface/interfaces/STL/readSTLASCII.L

Line : 169:

Original source code: word solidName(string::validate<word>(YYText()));

Proposed change : word solidName(Foam::string::validate<word>(YYText()));

Problem description :
SuSE 10.1 comes with flex++ version 2.5.31-16

With an older version of flex++ (version 2.5.4a-33 from RedHat Fedora Core 3), line 169 generates the following error messages when parsed through flex++ while compiling the library triSurface:

triSurface/interfaces/STL/readSTLASCII.L:169: error: reference to "string" is ambiguous
/home/math/pub/OpenFOAM/OpenFOAM-1.4/src/OpenFOAM/lnInclude/string.H:64: error: candidates are: class Foam::string
/home/math/pub/OpenFOAM/linux/gcc-4.1.2/lib/gcc/i686-pc-linux-gnu/4.1.2/../../.. /../include/c++/4.1.2/bits/stringfwd.h:60: error: typedef struct std::basic_string<char, std::char_
traits<char>, std::allocator<char> > std::string
triSurface/interfaces/STL/readSTLASCII.L:169: erreur: expected primary-expression before token

Solution:
The solution is quite simple: you just need to tell flex++ which "flavor" of the class string you need; in this case, we need Foam::string.

The proposed patch should work for any version of flex++.

Enjoy,

Martin
mbeaudoin is offline   Reply With Quote

Old   April 13, 2007, 03:33
Default Good point, we noticed a simil
  #2
Senior Member
 
Join Date: Mar 2009
Posts: 854
Rep Power: 22
henry is on a distinguished road
Good point, we noticed a similar problem when a new version of the fluentMeshToFoam we are developing was compiled on RedHat. Did you notice any problems compiling any of the other .L files in 1.4?

Henry
henry is offline   Reply With Quote

Old   April 13, 2007, 22:09
Default Nope, the rest of 1.4 compiled
  #3
Senior Member
 
Martin Beaudoin
Join Date: Mar 2009
Posts: 332
Rep Power: 22
mbeaudoin will become famous soon enough
Nope, the rest of 1.4 compiled just fine on that RedHat system.

Still need to adjust for the "demangle.h" problem on non Suse systems, but the solution to that problem is now well documented on this mailing list, and in the recompilation Howto on openfoamwiki.net.

Martin
mbeaudoin is offline   Reply With Quote

Reply


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 Off
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
[Commercial meshers] Conversion Fluent cas and dat file to OpenFoam matteo_gautero OpenFOAM Meshing & Mesh Conversion 11 July 14, 2020 13:09
Flex and readSTLASCIIL podallaire OpenFOAM Installation 2 June 1, 2010 18:00
[OpenFOAM] ParaView 33 canbt open OpenFoam file hariya03 ParaView 7 September 25, 2008 18:33
OPENFoam File Format as XML A Wishlist iyer_arvind OpenFOAM 2 January 2, 2008 05:39
[Other] IDEAS universal file convert to OpenFOAM hsieh OpenFOAM Meshing & Mesh Conversion 0 April 18, 2006 14:57


All times are GMT -4. The time now is 04:48.