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

Debian 12 and GCC 12

Register Blogs Community New Posts Updated Threads Search

Like Tree1Likes
  • 1 Post By pipedream

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   August 8, 2023, 19:54
Default Debian 12 and GCC 12
  #1
New Member
 
Jan Groenewald
Join Date: Aug 2023
Posts: 5
Rep Power: 3
pipedream is on a distinguished road
On Debian 12, GCC 12.2.0 is the default compiler.


Compiling OpenFOAM 2012 (I was using this version for solids4foam) fails with gcc 12 as attached.



Compilation succeeds with gcc 11.



It might have to do with the header dependencies as mentioned here:
https://gcc.gnu.org/gcc-12/porting_to.html


I.e. a missing #include <array> somewhere?
Attached Files
File Type: gz log.linux64GccDPInt32Opt.tar.gz (40.8 KB, 2 views)
pipedream is offline   Reply With Quote

Old   August 11, 2023, 06:12
Default
  #2
Senior Member
 
Mark Olesen
Join Date: Mar 2009
Location: https://olesenm.github.io/
Posts: 1,714
Rep Power: 40
olesen has a spectacular aura aboutolesen has a spectacular aura about
Quote:
Originally Posted by pipedream View Post
On Debian 12, GCC 12.2.0 is the default compiler.

Compiling OpenFOAM 2012 (I was using this version for solids4foam) fails with gcc 12 as attached.

Compilation succeeds with gcc 11.

It might have to do with the header dependencies as mentioned here:
https://gcc.gnu.org/gcc-12/porting_to.html

I.e. a missing #include <array> somewhere?
I don't quite understand what is going on here. I assume that you already checked the issue tracker (https://develop.openfoam.com/Development/openfoam) but didn't see
https://develop.openfoam.com/Develop.../-/issues/2714

This has been patched on various maintenance branches, and there are even newer code packs on https://dl.openfoam.com/source if you aren't using git. So I don't understand what is going wrong.
In any case, there will not be that many internal changes to OpenFOAM to prevent you from using more recent versions (Eg, OpenFOAM-v2306) with solids4foam.


EDIT: the include for std::array was patched even well before that (the OpenFOAM-v2012_210414 code pack, which means it was patched and re-released more than two years ago).
olesen is offline   Reply With Quote

Old   August 12, 2023, 01:32
Default
  #3
New Member
 
Jan Groenewald
Join Date: Aug 2023
Posts: 5
Rep Power: 3
pipedream is on a distinguished road
Quote:
Originally Posted by olesen View Post
In any case, there will not be that many internal changes to OpenFOAM to prevent you from using more recent versions (Eg, OpenFOAM-v2306) with solids4foam.

v2306 compiled but solids4foam failed as attached
Attached Files
File Type: txt log.Allwmake.txt (11.0 KB, 10 views)
pipedream is offline   Reply With Quote

Old   August 16, 2023, 12:27
Default
  #4
Senior Member
 
Mark Olesen
Join Date: Mar 2009
Location: https://olesenm.github.io/
Posts: 1,714
Rep Power: 40
olesen has a spectacular aura aboutolesen has a spectacular aura about
Quote:
Originally Posted by pipedream View Post
v2306 compiled but solids4foam failed as attached

I have a pull-request added for that now - if you wanted to try from there.



https://github.com/solids4foam/solids4foam/pull/60
olesen is offline   Reply With Quote

Old   August 16, 2023, 14:19
Default Success
  #5
New Member
 
Jan Groenewald
Join Date: Aug 2023
Posts: 5
Rep Power: 3
pipedream is on a distinguished road
Code:
git fetch origin pull/60/head:development
git checkout development
...
Summary statistics
    Number of cases where a run was attempted: 48
    Number of cases where the solver failed: 0
    Number of cases where another command failed: 0

All tests passed: enjoy solids4foam.
olesen likes this.
pipedream 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



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