mirror of
https://develop.openfoam.com/Development/openfoam.git
synced 2025-11-28 03:28:01 +00:00
- for codedFunctionObject and CodedSource the main code snippets
were not included in the SHA1 calculation, which meant that many
changes would not be noticed and no new library would be compiled.
As a workaround, a dummy 'code' entry could be used solely for the
purposes of generating a SHA1, but this is easily forgotten.
We now allow tracking of the dynamicCodeContext for the coded
objects and append to the SHA1 hasher with specific entries.
This should solve the previous misbehaviour.
We additionally add information about the ordering of the code
sections. Suppose we have a coded function object (all code
segments are optional) with the following:
codeExecute "";
codeWrite #{ Info<< "Called\n"; #};
which we subsequently change to this:
codeExecute #{ Info<< "Called\n"; #};
codeWrite "";
If the code strings are simply concatenated together, the SHA1 hashes
will be identical. We thus 'salt' with their semantic locations,
choosing tags that are unlikely to occur within the code strings
themselves.
- simplify the coded templates with constexpr for the SHA1sum
information.
- Correct the CodedSource to use 'codeConstrain' instead of
'codeSetValue' for consistency with the underlying functions.
OpenFOAM Configuration
The main OpenFOAM settings are located in the parent etc/ directory.
Both POSIX (bash, dash,...) and csh shells are supported.
To configure OpenFOAM, source either the etc/bashrc or the
etc/cshrc file, as appropriate for your shell.
These source the following files in the config.sh/ or
config.csh/ directories:
setup: finalize setup of OpenFOAM environment (called by bashrc,cshrc)settings: core settingsaliases: aliases for interactive shellsunset: sourced to clear as many OpenFOAM environment settings as possiblempi: MPI communications library settingsparaview: application settings for ParaViewscotch: application settings for compiling against scotchmetis: application settings for compiling against metis
The config.*/example directories contain additional example configuration
files for the corresponding shell:
compiler: an example of fine tuning ThirdParty compiler settingsopenmpi: an example of fine tuning openmpi settings for OpenFOAMparaview: an example of chaining to the standard config/paraview with a different ParaView_VERSIONprefs: an example of supplying alternative site-defined settings