dynamicLibrary::compileTemplate: Standardised naming convention for the dynamic compilation template files

which now all have Template.H or Template.C appended to differentiate them from
standard OpenFOAM library files.
This commit is contained in:
Henry Weller
2021-05-20 10:52:57 +01:00
parent 811abdfc4b
commit 4064161331
16 changed files with 17 additions and 19 deletions

View File

@ -7,7 +7,7 @@ EXE_INC = \
-I$(LIB_SRC)/finiteVolume/cfdTools \
-I$(LIB_SRC)/finiteVolume/lnInclude \
-I$(LIB_SRC)/sampling/lnInclude \
-I$(LIB_SRC)/meshTools/lnInclude \
-I$(LIB_SRC)/meshTools/lnInclude
EXE_LIBS = \
-lfluidThermophysicalModels \

View File

@ -1 +0,0 @@
fluidThermo.C

View File

@ -0,0 +1 @@
fluidThermoTemplate.C

View File

@ -1 +0,0 @@
fluidReactionThermo.C

View File

@ -0,0 +1 @@
fluidReactionThermoTemplate.C

View File

@ -1 +0,0 @@
fluidThermo.C

View File

@ -0,0 +1 @@
fluidThermoTemplate.C

View File

@ -123,7 +123,7 @@ void Foam::compileTemplate::prepare
}
// Compile filtered C template
dynCode.addCompileFile(templateName_ + ".C");
dynCode.addCompileFile(codeTemplateC(templateName_));
// Define Make/options
dynCode.setMakeOptions(context.options() + "\n\n" + context.libs());

View File

@ -76,7 +76,9 @@ typename Table::iterator Foam::basicThermo::lookupCstrIter
<< "Compilation and linkage of "
<< Thermo::typeName << " type " << nl
<< "thermoType" << thermoTypeDict << nl << nl
<< "failed." << exit(FatalError);
<< "failed." << nl << nl
<< "Valid " << Thermo::typeName << " types are:"
<< nl << nl;
}
}
else
@ -87,7 +89,10 @@ typename Table::iterator Foam::basicThermo::lookupCstrIter
<< "thermoType" << thermoTypeDict << nl << nl
<< "Valid " << Thermo::typeName << " types are:"
<< nl << nl;
}
if (cstrIter == tablePtr->end())
{
// Get the list of all the suitable thermo packages available
wordList validThermoTypeNames(tablePtr->sortedToc());

View File

@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
\\ / A nd | Copyright (C) 2011-2020 OpenFOAM Foundation
\\ / A nd | Copyright (C) 2011-2021 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@ -34,7 +34,7 @@ License
namespace Foam
{
forGases(makeThermos, psiThermo, hePsiThermo, pureMixture);
forGases(makeThermo, psiThermo, hePsiThermo, pureMixture);
}
// ************************************************************************* //

View File

@ -36,9 +36,9 @@ License
namespace Foam
{
forGases(makeThermos, rhoThermo, heRhoThermo, pureMixture);
forLiquids(makeThermos, rhoThermo, heRhoThermo, pureMixture);
forTabulated(makeThermos, rhoThermo, heRhoThermo, pureMixture);
forGases(makeThermo, rhoThermo, heRhoThermo, pureMixture);
forLiquids(makeThermo, rhoThermo, heRhoThermo, pureMixture);
forTabulated(makeThermo, rhoThermo, heRhoThermo, pureMixture);
}
// ************************************************************************* //

View File

@ -2,7 +2,7 @@
========= |
\\ / F ield | OpenFOAM: The Open Source CFD Toolbox
\\ / O peration | Website: https://openfoam.org
\\ / A nd | Copyright (C) 2020 OpenFOAM Foundation
\\ / A nd | Copyright (C) 2020-2021 OpenFOAM Foundation
\\/ M anipulation |
-------------------------------------------------------------------------------
License
@ -72,13 +72,6 @@ Description
\
defineThermo(BaseThermo, CThermo, Mixture, ThermoPhys); \
\
addThermo(BaseThermo, CThermo, Mixture, ThermoPhys)
#define makeThermos(BaseThermo, CThermo, Mixture, ThermoPhys) \
\
defineThermo(BaseThermo, CThermo, Mixture, ThermoPhys); \
\
addThermo(basicThermo, CThermo, Mixture, ThermoPhys); \
addThermo(fluidThermo, CThermo, Mixture, ThermoPhys); \
addThermo(BaseThermo, CThermo, Mixture, ThermoPhys)