blueCFD / Core

Coordination repository for the blueCFD-Core: Issue tracking, Wiki, project webpage and miscellaneous scripts
http://bluecfd.github.io/Core
53 stars 10 forks source link

In DOS_Mode, dynamic code execution fails due to path without quotes #168

Open kastnerp opened 3 years ago

kastnerp commented 3 years ago

Dear Bruno,

When trying to run this case in DOS_Mode (DOS_Mode.bat), I noticed that the dynamic code execution within the blockMeshDict file fails.

I am not exactly sure why this happens but I suspect it is due to the path being passed to sh.exe without quotes. In case of the default installation folder C:\Program Files\blueCFD-Core-2017, this leads to:

make: C:\Program: No such file or directory
make: *** No rule to make target 'C:\Program'.  Stop.

Here is the full cli output:

Creating block mesh from
    "C:/Users/pkastner/Desktop/periodicHill/steadyState/system/blockMeshDict"
Using #codeStream at line 39 in file "C:/Users/pkastner/Desktop/periodicHill/steadyState/system/blockMeshDict"
Using #codeStream with "C:/Users/pkastner/Desktop/periodicHill/steadyState/dynamicCode/platforms/mingw_w64GccDPInt32Opt/lib/libcodeStream_15c64612def8d72da14ee2504008aa693df9b1ad.so"
Creating new library in "dynamicCode/_15c64612def8d72da14ee2504008aa693df9b1ad/platforms/mingw_w64GccDPInt32Opt/lib/libcodeStream_15c64612def8d72da14ee2504008aa693df9b1ad.so"
Invoking "wmake -s libso C:/Users/pkastner/Desktop/periodicHill/steadyState/dynamicCode/_15c64612def8d72da14ee2504008aa693df9b1ad"

C:\Users\pkastner\Desktop\periodicHill\steadyState>sh.exe -c "wmake -s libso C:/Users/pkastner/Desktop/periodicHill/steadyState/dynamicCode/_15c64612def8d72da14ee2504008aa693df9b1ad"
/c/Program Files/blueCFD-Core-2017/OpenFOAM-5.x/wmake/wmake: line 74: /c/Program: No such file or directory
/c/Program Files/blueCFD-Core-2017/OpenFOAM-5.x/wmake/wmake: line 217: checkEnv: command not found
wmake libso C:/Users/pkastner/Desktop/periodicHill/steadyState/dynamicCode/_15c64612def8d72da14ee2504008aa693df9b1ad
/c/Program Files/blueCFD-Core-2017/OpenFOAM-5.x/wmake/wmake: line 378: cdSource: command not found
make: C:\Program: No such file or directory
make: *** No rule to make target 'C:\Program'.  Stop.
make: C:\Program: No such file or directory
make: *** No rule to make target 'C:\Program'.  Stop.
make: C:\Program: No such file or directory
make: *** No rule to make target 'C:\Program'.  Stop.
make: C:\Program: No such file or directory
make: *** No rule to make target 'C:\Program'.  Stop.
wmake error: file 'Make/mingw_w64GccDPInt32Opt/sourceFiles' could not be created in /c/Users/pkastner/Desktop/periodicHill/steadyState/dynamicCode/_15c64612def8d72da14ee2504008aa693df9b1ad

Running blockMesh within blueCFD-Core terminal works without any issues. I am not sure if this can be fixed but I wanted to add it here nevertheless.

Best,

Patrick

wyldckat commented 3 years ago

Hi Patrick,

Many thanks for your detailed report! I have tried to tackle this issue in the past, but there should be a temporary workaround at the moment:

Best regards, Bruno