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

Buiding on Fedora 12

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

Reply
 
LinkBack Thread Tools Display Modes
Old   January 12, 2010, 04:30
Default Buiding on Fedora 12
  #1
Member
 
Terry Barnaby
Join Date: Mar 2009
Location: Beam Ltd, UK
Posts: 44
Rep Power: 7
terrybarnaby is on a distinguished road
OpenFOAM from git does not build on Fedora 12 at the moment. The core issue appears to be a problem with using cpp to process the Make/options files. The cpp used in F12 "cpp-4.4.2-20.fc12.i686" strips out the backslashes at the end of lines but leaves the newline character intact.
I'm not sure if this is a bug or feature in cpp. However, what part of cpp's processing is actually needed when generating the build options file from Make/options, would
a simple cp do ?
terrybarnaby is offline   Reply With Quote

Old   January 12, 2010, 04:52
Default
  #2
Senior Member
 
Philippose Rajan
Join Date: Mar 2009
Location: Germany
Posts: 525
Rep Power: 15
philippose will become famous soon enough
Hello Terry,

A Good Morning to you!

The issue you are referring to has been delat with in the following thread:

OpenFOAM-1.5-dev SVN15xx with gcc-4.4.2

I am also not yet sure whether it is a bug or a feature of the new C Pre-Processor (cpp) which comes with GCC-4.4.2

Anyway, the command line option "-P" as specified in the link above fixes the issue....

Hope this helps...!

Have a nice day :-)!

Philippose
philippose is offline   Reply With Quote

Old   January 12, 2010, 05:05
Default
  #3
Senior Member
 
Laurence R. McGlashan
Join Date: Mar 2009
Posts: 367
Rep Power: 13
l_r_mcglashan will become famous soon enough
I had that problem too, my fudge was to use an older version of cpp, but this is much better. The manual for cpp says that -P;

"Inhibits generation of linemarkers in the output from the preprocessor. This might be useful when running the preprocessor on something that is not C code, and will be sent to a program which might be confused by the linemarkers."

Thing I find curious is that this problem only appears in Fedora 12. In your other thread you say that the Red Hat forums show complaints about this problem, but remember that Fedora is a test-bed for Red Hat.

Anyway, good work! Might be a good idea to put it up on the wiki.
__________________
Laurence R. McGlashan :: Website
l_r_mcglashan is offline   Reply With Quote

Old   January 12, 2010, 05:44
Default
  #4
Member
 
Terry Barnaby
Join Date: Mar 2009
Location: Beam Ltd, UK
Posts: 44
Rep Power: 7
terrybarnaby is on a distinguished road
Thanks for the info.
Yes, adding the "-P" option worked for me

I have mentioned the issue in the Fedora forums. Maybe that will get back to the CPP developers eventually if it is a bug.
terrybarnaby is offline   Reply With Quote

Old   January 12, 2010, 05:54
Default
  #5
Member
 
Terry Barnaby
Join Date: Mar 2009
Location: Beam Ltd, UK
Posts: 44
Rep Power: 7
terrybarnaby is on a distinguished road
I just had this reply in the Fedora forums from Jakub Jelinek:

----------------------
Yes, the tokens are separated by whitespace, so it is sufficient if they are
again separated by whitespace after preprocessing. See
http://gcc.gnu.org/PR41445 for details why this changed, in short
without the change the tokens have incorrect location and cause unintended
differences in debug info between direct compilation and compilation where
preprocessing happens separately from compilation.
You can use cpp -P to avoid this (then the output won't be cluttered with
# <line> <filename>
either).
----------------------

So it looks like this is now a bug in OpenFOAM...
I will add it to the OpenFOAM Bugs entry.
terrybarnaby is offline   Reply With Quote

Old   February 19, 2010, 07:04
Default
  #6
Member
 
Nick Gardiner
Join Date: Apr 2009
Location: Chichester, UK
Posts: 93
Rep Power: 7
NickG is on a distinguished road
I'm having this problem trying to compile the TurboMachinery SIG rotorStatorInterfaces:
linux64GccDPOpt/options:12: *** missing separator. Stop.

The options file is:

EXE_INC = \
-I$(LIB_SRC)/OpenFOAM/lnInclude \
-I$(LIB_SRC)/finiteVolume/lnInclude \
-I$(LIB_SRC)/meshTools/lnInclude \
-I$(LIB_SRC)/dynamicMesh/lnInclude \
-I./ \
-I./primitiveRotationalPatch
-I./GGIInterpolation

LIB_LIBS = \
-ldynamicMesh \
-lfiniteVolume \
-lOpenFOAM

so there are no hashes for it to ignore. Have tried the two suggested methods but no joy.

Any suggestions anyone?

Thanks
NickG is offline   Reply With Quote

Old   February 19, 2010, 07:05
Default
  #7
Member
 
Nick Gardiner
Join Date: Apr 2009
Location: Chichester, UK
Posts: 93
Rep Power: 7
NickG is on a distinguished road
I'm using 64 bit Ubuntu
NickG is offline   Reply With Quote

Old   February 19, 2010, 07:08
Default
  #8
Senior Member
 
Laurence R. McGlashan
Join Date: Mar 2009
Posts: 367
Rep Power: 13
l_r_mcglashan will become famous soon enough
You're missing a backslash after:

-I./primitiveRotationalPatch
__________________
Laurence R. McGlashan :: Website
l_r_mcglashan is offline   Reply With Quote

Old   February 23, 2010, 07:26
Default
  #9
Member
 
Nick Gardiner
Join Date: Apr 2009
Location: Chichester, UK
Posts: 93
Rep Power: 7
NickG is on a distinguished road
Thanks, I'll try that
NickG is offline   Reply With Quote

Reply

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.5-dev SVN 1563 on Fedora 12 (32-bit) - Successful philippose OpenFOAM Installation 2 January 7, 2010 00:44
Fedora 10 OpenFOAM15 philippose OpenFOAM Installation 7 February 18, 2009 04:37
STAR-CD 3.268in Fedora 8 Thomas Stockheim CD-adapco 3 April 28, 2008 03:43
fedora 7 murash-v CD-adapco 0 November 8, 2007 10:21
FEDORA CORE and PARALLEL processing Tuks CFX 2 August 20, 2005 11:05


All times are GMT -4. The time now is 20:22.