libWallModelledLES
libWallModelledLES copied to clipboard
build issue with openfoam-2312
Hi @timofeymukha
As probably noticed by now, there are build issues (non-const dereference from tmp using the old ()
operator instead of ref()
etc). The basic code itself looks okay-ish, but probably stems from the version detection not properly working.
This means that entire #ifdef FOAM_NEW_TMP_RULES
stuff is not being seen.
For the openfoam-com version it would sense to add some robustness and bypass the python script almost totally. For example,
if [ -e "$WM_PROJECT_DIR/META-INFO/api-info" ]
then
echo "openfoam com == $(sed -ne s/api=//p "$WM_PROJECT_DIR"/META-INFO/api-info)"
fi
Or even this (probably preferable):
if openfoam_com="$("$WM_PROJECT_DIR"/bin/foamEtcFile -show-api 2>/dev/null)"
then
echo "openfoam com == $openfoam_com"
else
echo do something funny with python
fi
Of course, the simple echo would be replaced by some more generated text and everything probably better hidden away into a separate shell script.
Hi Mark!
Looking at the various ifdefs, many of them are for really old versions. I think I am comfortable with deprecating support for everything below at least 1806. That's still 5 years old!
I'm not incredibly good with all the bash stuff, and the whole ifdef machinery with the python script I took from swak :-). I will try to figure things out to rely on Python less.
I'm not incredibly good with all the bash stuff, and the whole ifdef machinery with the python script I took from swak :-). I will try to figure things out to rely on Python less.
Can safely ping us about any of this (in the new year).
Removed all the ifdefs, which affected the .com fork. Could still be some stuff in the https://github.com/timofeymukha/libWallModelledLES/blob/master/versionRules/libraryRules that needs to be looked at.