Install v2006 on macOS Mojave failed
1 Attachment(s)
Hi,
I tried to install OpenFOAM v2006 from terminal on macOS Mojave. I followed the instruction https://develop.openfoam.com/Develop...p/doc/Build.md. step1, source ~/OpenFOAM/OpenFOAM-v2006/etc/bashrc, it shows Quote:
Quote:
step4, I got the trouble as shown below Quote:
Then I tried to change the string.H to another name, but it doesn't work. Any help or suggestion on this issue would be greatly appreciated. Best regards |
Would you mind to report the issue to the GitLab? Thanks.
|
Quote:
Did you solve this issue? I'm also bothered by this issue while installing OpenFOAM v2106 on the macOS bigsur. Best regards, Gang |
Quote:
Hi! I have problems too... I can not figure out how to compile OpenFOAM (9) on Bug Sur -Apple m1, compiling from source code... Is there a guide to do it? Thanks |
Quote:
I've successfully installed the OpenFOAM v2106 on Big-sur. I think you need to create a virtual volume, by following the guidance here: https://github.com/mrklein/openfoam-os-x Best regards, Gang Wang |
Quote:
Best regards, Gang |
Same problem here
Hello,
is there any update on this? I have exactly the same problem even after applying the patch. Thanks for the help. Best regards Federico Carminati |
I believe the problem is due to the fact that in the OpenFoam files there are some files that are distinguishable only by their case. While this is perfectly file in most Linux systems, on the Mac by default the filesystem is case preserving but not distinguishing. This means that if you create a file, say “hello.dat”, it will be indistinguishable from a file “Hello.dat” in another directory. This probably causes some confusions in the include directives that pick up the wrong file and compilation fails. I found the (admittedly baroque) solution of creating a virtual file system on my Mac that is case discriminating and to compile OpenFoam there. The instructions (that I will post in the forum), are the following:
hdiutil create -size 5g -fs 'Case-sensitive Journaled HFS+' -volname openfoam openfoam sudo hdiutil attach -mountpoint /usr/local/openfoam openfoam.dmg cd /usr/local/openfoam and there one can deploy the normal installation instructions. To increase portability of the openfoam project it would perhaps be worth considering to disambiguate files not only via their case, but by using different combinations of letters. |
Quote:
Thank you Federico! Where can I find the normal installation instructions? |
|
Quote:
Thank you! To be honest, is too difficult to me... i’ve tried several times, but nothing.... I found that docker for M1 SoC works, but openFoam image is always emulated, and so is very very slow... I don’t know what to do.... |
I am really new to OF, but I have *a lot* of experience installing "stuff". Mind posting your problems? Might be I can be of help. Best,
|
Quote:
First: I create and mount an image disk as you suggested --> No problem with this. And then? I'm sorry but I'm new to install from terminal all this things, I'm getting confused in all the instruction reported in the guide you linked before. Are the preliminaries necessary? Maybe I need, if exist, a noob guide to do it... |
Can you mount it on /usr/local/openfoam?
if yes do cd /usr/local/openfoam df -k . and you should see "something" like Filesystem 1024-blocks Used Available Capacity iused ifree %iused Mounted on /dev/disk9s2 4382680 3621640 761040 83% 203807 4294763472 0% /usr/local/openfoam |
Quote:
/dev/disk4s2 4906968 28840 4878128 1% 6 4294967273 0% /usr/local/openfoam |
good, now download the two tar files here
Source: https://dl.openfoam.com/source/v2106/OpenFOAM-v2106.tgz ThirdParty: https://dl.openfoam.com/source/v2106...arty-v2106.tgz and untar them into /usr/local/openfoam if you do not know how to do that, download the files and let me know. Best, |
Thank you, you are very kind!
I think I've done it, I "untarned" both files... under /usr/local/openfoam I see (ls command): OpenFOAM-v2106 ThirdParty-v2106 |
you are almost there!!
$ source /usr/local/openfoam/OpenFOAM-v2106/etc/bashrc $ cd /usr/local/openfoam/OpenFOAM-v2106 $ foamSystemCheck $ ./Allwmake -s -l and go for a coffee ;-) |
Unfortunately it doesn't work...
Maybe with all the tries before, I messed up something... A lot of warning in the log file, e.g.: warning: overriding currently unsupported use of floating point exceptions on this target [-Wunsupported-floating-point-opt] and errors, e.g.: signals/feexceptErsatz.H:39:24: error: no member named '__control' in 'fenv_t' old_excepts = fenv.__control & FE_ALL_EXCEPT; ~~~~ ^ |
Did you delete all your previous tries from disk? Best
|
Quote:
Is there a command to clear evertihing in order to restart from the beginning? |
Quote:
|
Quote:
We supply all of the docker files and resource files here: https://develop.openfoam.com/packaging/containers You will want to create an image using the openSUSE packages. This is described in the corresponding file https://develop.openfoam.com/packagi...eap-Dockerfile After running docker build on this, you can either tag it with the "opencfd/.." prefix so that the openfoam-docker script finds it, or run the openfoam-docker with -image=<your-image> |
Quote:
Thank you Olsen, i did what you suggested... it works much better! Thanks |
Hello All
The reason for this error is that "feexceptErsatz.H" refers to the x86_64 structure of fenv.h. "feexceptErsatz.H" needs to be rewritten so that it uses the arm64 structure. Here is how I built it, for your reference. https://ttsyshmz.github.io/howtoFoam...2106-on-m1mac/ |
Quote:
But, is your Mac equipped with an M1 SoC or with a x86 cpu? In another post, a forum member suggested this: "You'll need to remove the sigfpe part(seems like Apple silicon doesn't support this feature?) then it should compile. https://github.com/mrklein/openfoam-...ment-850090915 " But I don't know exactly what this means... |
Quote:
|
Following the wonderful advice of LongGe and Federico, I managed to install OpenFoam-v2106 on Mac M1!
In a final step, I need to define LD_LIBRARY_PATH to set the path to the third party libraries. How do I do so? Thx! |
Update:
Various of the third party packages fail compile with Clang version 12.0 on Darwin. I failed to see this earlier. (Switch to gcc on Darwin is not supported). E.g. scotch fails to compile due to the gettimneoftheday function being implicitly declared in src/libskotch/conmon.c. I was not yet able to turn this error of using -Wno-error=implicit-function-declaration. Kahip fails due to the compiler not finding misc/omp.h . I was not yet able to extern the include directory with this path. Metis does compile after manual download and installation of cmake using brew. I am currently trying to run decomposePar using Metis. After installation LD_LIBRARY_PATH remains empty. Setting LD_LIBRARY_PATH manually does not cure the issue. |
Hello All
In my case, I installed the third party with brew. As described here. https://github.com/mrklein/openfoam-...ster/README.md |
Further updates:
(1/3): good news: I managed to install Cmake using brew, to download Metis from the repository, to install Metis, to set DYLD_LIBRARY_PATH (observe MAC-OS convention) manually and to run decomposePar to obtain a decomposition. So far, so good. (2/3): first question: A parallel run of simpleFoam fails, that is, "mpirun -np 4 simpleFoam -parallel" returns with "The dummy Pstream library cannot be used in parallel mode". The same issue however was however reported e.g. here https://develop.openfoam.com/Develop.../-/issues/1970. Will need to give it a look. (3/3): second question: the compilation of the third party mesher cfMesh using Clang fails. I will give specifics in a next update. |
All times are GMT -4. The time now is 16:21. |