# Problem with installation of OpenFoam 5.x adapter

**URL:** <https://precice.discourse.group/t/problem-with-installation-of-openfoam-5-x-adapter/2407>\
**Category:** Official adapters and tutorials\
**Tags:** openfoam, adapters\
**Created:** [April 2, 2025, 4:12am UTC](https://precice.discourse.group/t/problem-with-installation-of-openfoam-5-x-adapter/2407 "2025-04-02T04:12:03Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![zhang](https://avatars.discourse-cdn.com/v4/letter/z/aeb1de/32.png) [@zhang](https://precice.discourse.group/u/zhang)\
**Post date:** [April 2, 2025, 4:12am UTC](https://precice.discourse.group/t/problem-with-installation-of-openfoam-5-x-adapter/2407/1 "2025-04-02T04:12:03Z")

</div>

Some errors occured when i installed OpenFoam 5.x adapter in my system. Here is the discription of my system: precice-3.1.2, openfoam5.x and dealii 9.6 under Ubuntu 20.04. I installed precice-3.1.2 from source. I successfully installed the adapter for dealii but failed to install adapter for openfoam. I checked the version of adapter and it is correct.

```
=== ERROR: Building failed. See wmake.log for more. ===
Possible causes:
- Make sure you are using a compatible version of the adapter for your OpenFOAM version:
https://www.precice.org/adapter-openfoam-support.html
- Is preCICE discoverable at compile time? Check the content of ADAPTER_PKG_CONFIG_CFLAGS above.
Attach your Allwmake.log and wmake.log when asking for help.

```

Here are my log files. Thank you so much.  
[Allwmake.log](https://precice.discourse.group/uploads/short-url/A7J56zpo0EqH8PJ7qdj6Y9xx0Kw.log) (934 Bytes)  
[wmake.log](https://precice.discourse.group/uploads/short-url/zNcaoPDYwa9XSYrbxffVXr4151k.log) (333.4 KB)

---

<div class="post-metadata">

**Author:** ![Makis](https://yyz2.discourse-cdn.com/free1/user_avatar/precice.discourse.group/makis/32/25_2.png) [@Makis](https://precice.discourse.group/u/Makis)\
**Post date:** [April 2, 2025, 1:51pm UTC](https://precice.discourse.group/t/problem-with-installation-of-openfoam-5-x-adapter/2407/2 "2025-04-02T13:51:19Z")

</div>

Hi @zhang,

I am slowly porting the adapter to the Foundation versions. I have already ported to support v6, but not yet officially released: [GitHub - precice/openfoam-org-adapter at OpenFOAM6](https://github.com/precice/openfoam-org-adapter/tree/OpenFOAM6)

Could you try if that (or probably a previous commit that only includes OpenFOAM5-related changes: [GitHub - precice/openfoam-org-adapter at e1515b8f981ef2f19b0b04aaa249b5b0f36ba90e](https://github.com/precice/openfoam-org-adapter/tree/e1515b8f981ef2f19b0b04aaa249b5b0f36ba90e)) works?

Note that you are using very old software: OpenFOAM 5.x was released in 2017. Why do you need such an old version?

---

<div class="post-metadata">

**Author:** ![zhang](https://avatars.discourse-cdn.com/v4/letter/z/aeb1de/32.png) [@zhang](https://precice.discourse.group/u/zhang)\
**Post date:** [April 2, 2025, 2:23pm UTC](https://precice.discourse.group/t/problem-with-installation-of-openfoam-5-x-adapter/2407/3 "2025-04-02T14:23:22Z")

</div>

Thank you for your reply @Makis,  
I will try the code later. I use this version because CFDEM ([About CFDEM®project | CFDEM®project](https://www.cfdem.com/about-cfdemrproject)) uses this version, and I am trying to couple CFDEM with another solver.

---

<div class="post-metadata">

**Author:** ![hoehnp](https://yyz2.discourse-cdn.com/free1/user_avatar/precice.discourse.group/hoehnp/32/2838_2.png) [@hoehnp](https://precice.discourse.group/u/hoehnp)\
**Post date:** [April 2, 2025, 8:29pm UTC](https://precice.discourse.group/t/problem-with-installation-of-openfoam-5-x-adapter/2407/4 "2025-04-02T20:29:07Z")

</div>

Hi @zhang

have you had a look at the PFM fork which uses OF6? [GitHub - ParticulateFlow/CFDEMcoupling-PFM: This is an academic adaptation of the CFDEMcoupling software package, released by the Department of Particulate Flow Modelling at Johannes Kepler University in Linz, Austria http://www.jku.at/pfm](https://github.com/ParticulateFlow/CFDEMcoupling-PFM)

---

<div class="post-metadata">

**Author:** ![zhang](https://avatars.discourse-cdn.com/v4/letter/z/aeb1de/32.png) [@zhang](https://precice.discourse.group/u/zhang)\
**Post date:** [April 3, 2025, 5:54am UTC](https://precice.discourse.group/t/problem-with-installation-of-openfoam-5-x-adapter/2407/5 "2025-04-03T05:54:04Z")

</div>

Hi @hoehnp  
Thank you for your advice. I will check their code.
