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

Having trouble developing/compiling OpenFOAM on Mac

Register Blogs Community New Posts Updated Threads Search

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   June 27, 2018, 12:44
Default Having trouble developing/compiling OpenFOAM on Mac
  #1
Sgs
New Member
 
S
Join Date: Jun 2016
Posts: 15
Rep Power: 9
Sgs is on a distinguished road
I have OpenFOAM installed on a Mac and can use the software just fine (e.g. the cavity tutorial and my own setup scripts run fine) but I'm having trouble developing the code.

I run into a couple permissions errors while trying to run Allwmake from /opt/OpenFOAM/OpenFOAM-v1712, though I do have permissions to execute Allwmake. The error output is attached.

I don't have permissions to edit files in /opt/src and cannot seem to use chmod to change this.

I can log in to Docker as root with
docker run -u 0 -it mycontainerID bash
rather than with
./startMacOpenFOAM

and then I can edit files in the src directory with vi, but cannot run Allwmake because of the error
./Allwmake
Error (Allwmake) : not located in $WM_PROJECT_DIR
Check your OpenFOAM environment and installation

and
$ echo $WM_PROJECT_DIR

shows that this variable is not defined.

Also, after I detach from the container and then re-attach, my edit to a file in src vanished.

Any advice would be greatly appreciated.
Attached Files
File Type: txt allwmakeError.txt (3.8 KB, 7 views)
Sgs is offline   Reply With Quote

Old   July 16, 2018, 15:50
Default
  #2
Member
 
Hasan Celik
Join Date: Sep 2016
Posts: 64
Rep Power: 9
PositronCascade is on a distinguished road
Why don't you directly compile the source code on Mac instead of considering Docker? I think it should work.
PositronCascade is offline   Reply With Quote

Old   July 29, 2018, 13:44
Default error using wmake on Docker for Mac
  #3
Sgs
New Member
 
S
Join Date: Jun 2016
Posts: 15
Rep Power: 9
Sgs is on a distinguished road
Using Docker seems to be the recommended way to run OpenFOAM according to
https://www.openfoam.com/download/in...binary-mac.php


And the site suggests that there is
A complete development environment to compile local modifications and create executables.

and also that
The Docker environment contains a full OpenFOAM development environment so all Allwmake, wmake, wclean etc. commands work (it is running the actual environment OpenFOAM was compiled in!)

so it would be great to understand why wmake isn't working.
Sgs is offline   Reply With Quote

Old   August 7, 2018, 17:06
Default one solution
  #4
Sgs
New Member
 
S
Join Date: Jun 2016
Posts: 15
Rep Power: 9
Sgs is on a distinguished road
https://cfd.direct/openfoam/user-gui...-applications/
Sgs is offline   Reply With Quote

Reply

Tags
allwmake, development environment, mac, openfoam, src


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
OpenFOAM v3.0+ ?? SBusch OpenFOAM 22 December 26, 2016 14:24
[OpenFOAM.org] Mac OS X 10.11 and OpenFOAM 3.0: Error when running ParaFoam with "command not found" hua OpenFOAM Installation 9 February 10, 2016 23:45
OpenFOAM Training: Programming CFD Course 12-13 and 19-20 April 2016 cfd.direct OpenFOAM Announcements from Other Sources 0 January 14, 2016 10:19
Trouble with sampleDict syntax for OpenFOAM 2.3.1 rawdoggity OpenFOAM Post-Processing 1 February 1, 2015 05:24
OpenFOAM 1.7 installation on Mac pepe.aero OpenFOAM Installation 0 April 16, 2011 12:32


All times are GMT -4. The time now is 23:41.