wmake: Simplified and standardised the Make/files files
cpp is no longer used to pre-process Make/files files allowing standard make '#'
syntax for comments, 'ifdef', 'ifndef' conditionals etc. This is make possible
by automatically pre-pending SOURCE += to each of the source file names in
Make/files.
The list of source files compile can be specified either as a simple list of
files in Make/files e.g.
# Note: fileMonitor assumes inotify by default. Compile with -DFOAM_USE_STAT
# to use stat (=timestamps) instead of inotify
fileMonitor.C
ifdef SunOS64
dummyPrintStack.C
else
printStack.C
endif
LIB = $(FOAM_LIBBIN)/libOSspecific
or
or directly as the SOURCE entry which is used in the Makefile:
SOURCE = \
adjointOutletPressure/adjointOutletPressureFvPatchScalarField.C \
adjointOutletVelocity/adjointOutletVelocityFvPatchVectorField.C \
adjointShapeOptimizationFoam.C
EXE = $(FOAM_APPBIN)/adjointShapeOptimizationFoam
In either form make syntax for comments and conditionals is supported.
This commit is contained in:
@ -27,7 +27,7 @@ PDRModels/XiGModels/basicXiSubG/basicXiSubG.C
|
||||
|
||||
laminarFlameSpeed/SCOPE/SCOPELaminarFlameSpeed.C
|
||||
|
||||
/*PDRFoamAutoRefine.C*/
|
||||
# PDRFoamAutoRefine.C
|
||||
PDRFoam.C
|
||||
|
||||
EXE = $(FOAM_APPBIN)/PDRFoam
|
||||
|
||||
@ -1,8 +1,6 @@
|
||||
Test-alloc.C
|
||||
/*
|
||||
Test-new.C
|
||||
Test-malloc.C
|
||||
Test.C
|
||||
*/
|
||||
# Test-new.C
|
||||
# Test-malloc.C
|
||||
# Test.C
|
||||
|
||||
EXE = $(FOAM_USER_APPBIN)/Test-alloc
|
||||
|
||||
@ -1,7 +1,6 @@
|
||||
/*
|
||||
fvMeshGeometry.C
|
||||
fvMesh.C
|
||||
*/
|
||||
# fvMeshGeometry.C
|
||||
# fvMesh.C
|
||||
|
||||
Test-fieldMapping.C
|
||||
|
||||
EXE = $(FOAM_USER_APPBIN)/Test-fieldMapping
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
coupledFacePair.C
|
||||
starMesh.C
|
||||
readPoints.C
|
||||
/*readSeparatedPoints.C*/
|
||||
# readSeparatedPoints.C
|
||||
readCells.C
|
||||
readBoundary.C
|
||||
fixCollapsedEdges.C
|
||||
|
||||
@ -29,7 +29,7 @@ $(cellSizeAndAlignmentControl)/cellSizeAndAlignmentControls.C
|
||||
$(cellSizeAndAlignmentControl)/cellSizeAndAlignmentControl/cellSizeAndAlignmentControl.C
|
||||
$(cellSizeAndAlignmentControl)/fileControl/fileControl.C
|
||||
$(cellSizeAndAlignmentControl)/searchableSurfaceControl/searchableSurfaceControl.C
|
||||
/*cellShapeControl/pQuadCoorControl/pQuadCoorControl.C*/
|
||||
# cellShapeControl/pQuadCoorControl/pQuadCoorControl.C
|
||||
|
||||
cellShapeControl/cellAspectRatioControl/cellAspectRatioControl.C
|
||||
|
||||
@ -37,7 +37,7 @@ cellShapeControl/smoothAlignmentSolver/smoothAlignmentSolver.C
|
||||
|
||||
cellShapeControl/controlMeshRefinement/controlMeshRefinement.C
|
||||
|
||||
/*cellSizeControlSurfaces/cellSizeControlSurfaces.C*/
|
||||
# cellSizeControlSurfaces/cellSizeControlSurfaces.C
|
||||
|
||||
cellSizeFunctions = cellSizeControlSurfaces/cellSizeFunction
|
||||
$(cellSizeFunctions)/cellSizeFunction/cellSizeFunction.C
|
||||
|
||||
@ -1,21 +1,17 @@
|
||||
/*
|
||||
foamyHexMeshSurfaceSimplify_non_octree.C
|
||||
MarchingCubes/MarchingCubes.cpp
|
||||
MarchingCubes/ply.c
|
||||
*/
|
||||
# foamyHexMeshSurfaceSimplify_non_octree.C
|
||||
# MarchingCubes/MarchingCubes.cpp
|
||||
# MarchingCubes/ply.c
|
||||
|
||||
/*
|
||||
MarchingCubes = fastdualoctree_sgp
|
||||
# MarchingCubes = fastdualoctree_sgp
|
||||
|
||||
$(MarchingCubes)/data_access.cpp
|
||||
$(MarchingCubes)/fparser.cpp
|
||||
$(MarchingCubes)/fpoptimizer.cpp
|
||||
$(MarchingCubes)/MarchingCubes.cpp
|
||||
$(MarchingCubes)/mc_draw.cpp
|
||||
$(MarchingCubes)/morton.cpp
|
||||
$(MarchingCubes)/opt_octree.cpp
|
||||
$(MarchingCubes)/hash_octree.cpp
|
||||
*/
|
||||
# $(MarchingCubes)/data_access.cpp
|
||||
# $(MarchingCubes)/fparser.cpp
|
||||
# $(MarchingCubes)/fpoptimizer.cpp
|
||||
# $(MarchingCubes)/MarchingCubes.cpp
|
||||
# $(MarchingCubes)/mc_draw.cpp
|
||||
# $(MarchingCubes)/morton.cpp
|
||||
# $(MarchingCubes)/opt_octree.cpp
|
||||
# $(MarchingCubes)/hash_octree.cpp
|
||||
|
||||
foamyHexMeshSurfaceSimplify.C
|
||||
|
||||
|
||||
@ -20,12 +20,12 @@ $(LESfilters)/laplaceFilter/laplaceFilter.C
|
||||
$(LESfilters)/anisotropicFilter/anisotropicFilter.C
|
||||
|
||||
|
||||
/* Turbulence BCs */
|
||||
# Turbulence BCs
|
||||
derivedFvPatchFields/fixedShearStress/fixedShearStressFvPatchVectorField.C
|
||||
derivedFvPatchFields/porousBafflePressure/porousBafflePressureFvPatchField.C
|
||||
|
||||
|
||||
/* Wall function BCs */
|
||||
# Wall function BCs
|
||||
wallFunctions = derivedFvPatchFields/wallFunctions
|
||||
|
||||
nutWallFunctions = $(wallFunctions)/nutWallFunctions
|
||||
@ -58,7 +58,7 @@ $(fWallFunctions)/fWallFunction/fWallFunctionFvPatchScalarField.C
|
||||
|
||||
RASBCs = RAS/derivedFvPatchFields
|
||||
|
||||
/* Inlet turbulence BCs */
|
||||
# Inlet turbulence BCs
|
||||
$(RASBCs)/turbulentMixingLengthDissipationRateInlet/turbulentMixingLengthDissipationRateInletFvPatchScalarField.C
|
||||
$(RASBCs)/turbulentMixingLengthFrequencyInlet/turbulentMixingLengthFrequencyInletFvPatchScalarField.C
|
||||
|
||||
|
||||
@ -12,16 +12,14 @@ cpuTime/cpuTime.C
|
||||
clockTime/clockTime.C
|
||||
memInfo/memInfo.C
|
||||
|
||||
/*
|
||||
* Note: fileMonitor assumes inotify by default. Compile with -DFOAM_USE_STAT
|
||||
* to use stat (=timestamps) instead of inotify
|
||||
*/
|
||||
# Note: fileMonitor assumes inotify by default. Compile with -DFOAM_USE_STAT
|
||||
# to use stat (=timestamps) instead of inotify
|
||||
fileMonitor.C
|
||||
|
||||
#ifdef SunOS64
|
||||
ifdef SunOS64
|
||||
dummyPrintStack.C
|
||||
#else
|
||||
else
|
||||
printStack.C
|
||||
#endif
|
||||
endif
|
||||
|
||||
LIB = $(FOAM_LIBBIN)/libOSspecific
|
||||
|
||||
@ -1,6 +1,6 @@
|
||||
global/global.Cver
|
||||
/* global/constants/constants.C in global.Cver */
|
||||
/* global/constants/dimensionedConstants.C in global.Cver */
|
||||
# global/constants/constants.C in global.Cver
|
||||
# global/constants/dimensionedConstants.C in global.Cver
|
||||
global/argList/argList.C
|
||||
global/clock/clock.C
|
||||
global/etcFiles/etcFiles.C
|
||||
@ -66,10 +66,10 @@ primitives/Tensor/lists/symmTensorList.C
|
||||
primitives/Tensor/lists/tensorList.C
|
||||
|
||||
primitives/Vector/complexVector/complexVector.C
|
||||
#if !defined(WM_SP)
|
||||
ifndef $(WM_SP)
|
||||
primitives/Vector/floatVector/floatVector.C
|
||||
primitives/Tensor/floatTensor/floatTensor.C
|
||||
#endif
|
||||
endif
|
||||
primitives/Vector/labelVector/labelVector.C
|
||||
primitives/Vector/vector/vector.C
|
||||
primitives/Vector/lists/vectorList.C
|
||||
@ -88,7 +88,7 @@ primitives/quaternion/quaternion.C
|
||||
primitives/septernion/septernion.C
|
||||
primitives/triad/triad.C
|
||||
|
||||
/* Run-time selectable functions */
|
||||
# Run-time selectable functions
|
||||
primitives/functions/Function1/makeFunction1s.C
|
||||
primitives/functions/Function1/reverseRamp/reverseRamp.C
|
||||
primitives/functions/Function1/linearRamp/linearRamp.C
|
||||
@ -193,7 +193,7 @@ $(StringStreams)/StringStreamsPrint.C
|
||||
Pstreams = $(Streams)/Pstreams
|
||||
$(Pstreams)/UIPstream.C
|
||||
$(Pstreams)/IPstream.C
|
||||
/* $(Pstreams)/UPstream.C in global.Cver */
|
||||
# $(Pstreams)/UPstream.C in global.Cver
|
||||
$(Pstreams)/UPstreamCommsStruct.C
|
||||
$(Pstreams)/Pstream.C
|
||||
$(Pstreams)/UOPstream.C
|
||||
|
||||
@ -296,9 +296,7 @@ $(schemes)/quadraticFit/quadraticFit.C
|
||||
$(schemes)/quadraticLinearUpwindFit/quadraticLinearUpwindFit.C
|
||||
$(schemes)/quadraticUpwindFit/quadraticUpwindFit.C
|
||||
$(schemes)/cubicUpwindFit/cubicUpwindFit.C
|
||||
/*
|
||||
$(schemes)/quadraticLinearPureUpwindFit/quadraticLinearPureUpwindFit.C
|
||||
*/
|
||||
# $(schemes)/quadraticLinearPureUpwindFit/quadraticLinearPureUpwindFit.C
|
||||
$(schemes)/linearPureUpwindFit/linearPureUpwindFit.C
|
||||
$(schemes)/linearUpwind/linearUpwind.C
|
||||
$(schemes)/linearUpwind/linearUpwindV.C
|
||||
|
||||
@ -5,7 +5,7 @@ interRegionOption/interRegionOption.C
|
||||
interRegionOption/interRegionOptionIO.C
|
||||
|
||||
|
||||
/* Sources */
|
||||
# Sources
|
||||
|
||||
generalSources=sources/general
|
||||
$(generalSources)/codedSource/codedSource.C
|
||||
@ -53,13 +53,13 @@ $(interRegion)/interRegionHeatTransfer/variableHeatTransfer/variableHeatTransfer
|
||||
$(interRegion)/interRegionExplicitPorositySource/interRegionExplicitPorositySource.C
|
||||
|
||||
|
||||
/* Constraints */
|
||||
# Constraints
|
||||
|
||||
constraints/fixedValueConstraint/fixedValueConstraints.C
|
||||
constraints/fixedTemperatureConstraint/fixedTemperatureConstraint.C
|
||||
|
||||
|
||||
/* Corrections */
|
||||
# Corrections
|
||||
|
||||
corrections/limitTemperature/limitTemperature.C
|
||||
corrections/limitVelocity/limitVelocity.C
|
||||
|
||||
@ -1,10 +1,10 @@
|
||||
/* Parcels */
|
||||
# Parcels
|
||||
parcels/derived/dsmcParcel/dsmcParcel.C
|
||||
|
||||
/* Cloud name */
|
||||
# Cloud name
|
||||
clouds/Templates/DSMCCloud/DSMCCloudName.C
|
||||
|
||||
/* Sub-models */
|
||||
# Sub-models
|
||||
parcels/derived/dsmcParcel/defineDSMCParcel.C
|
||||
parcels/derived/dsmcParcel/makeDSMCParcelBinaryCollisionModels.C
|
||||
parcels/derived/dsmcParcel/makeDSMCParcelWallInteractionModels.C
|
||||
|
||||
@ -6,13 +6,13 @@ CLOUDS=clouds
|
||||
BASECLOUDS=$(CLOUDS)/baseClasses
|
||||
DERIVEDCLOUDS=$(CLOUDS)/derived
|
||||
|
||||
/* parcel cloud */
|
||||
# parcel cloud
|
||||
parcelCloud/parcelCloudBase.C
|
||||
parcelCloud/parcelCloud.C
|
||||
parcelCloud/parcelCloudNew.C
|
||||
parcelCloudList/parcelCloudList.C
|
||||
|
||||
/* cloud names */
|
||||
# cloud names
|
||||
$(CLOUDS)/Templates/MomentumCloud/MomentumCloudName.C
|
||||
$(CLOUDS)/Templates/CollidingCloud/CollidingCloudName.C
|
||||
$(CLOUDS)/Templates/MPPICCloud/MPPICCloudName.C
|
||||
@ -21,7 +21,7 @@ $(CLOUDS)/Templates/ReactingCloud/ReactingCloudName.C
|
||||
$(CLOUDS)/Templates/ReactingMultiphaseCloud/ReactingMultiphaseCloudName.C
|
||||
$(CLOUDS)/Templates/SprayCloud/SprayCloudName.C
|
||||
|
||||
/* clouds */
|
||||
# clouds
|
||||
$(DERIVEDCLOUDS)/momentumCloud/momentumCloud.C
|
||||
$(DERIVEDCLOUDS)/collidingCloud/collidingCloud.C
|
||||
$(DERIVEDCLOUDS)/mppicCloud/mppicCloud.C
|
||||
@ -30,7 +30,7 @@ $(DERIVEDCLOUDS)/reactingCloud/reactingCloud.C
|
||||
$(DERIVEDCLOUDS)/reactingMultiphaseCloud/reactingMultiphaseCloud.C
|
||||
$(DERIVEDCLOUDS)/sprayCloud/sprayCloud.C
|
||||
|
||||
/* parcel names */
|
||||
# parcel names
|
||||
$(PARCELS)/Templates/MomentumParcel/MomentumParcelName.C
|
||||
$(PARCELS)/Templates/CollidingParcel/CollidingParcelName.C
|
||||
$(PARCELS)/Templates/MPPICParcel/MPPICParcelName.C
|
||||
@ -39,7 +39,7 @@ $(PARCELS)/Templates/ReactingParcel/ReactingParcelName.C
|
||||
$(PARCELS)/Templates/SprayParcel/SprayParcelName.C
|
||||
$(PARCELS)/Templates/ThermoParcel/ThermoParcelName.C
|
||||
|
||||
/* sub-models */
|
||||
# sub-models
|
||||
$(DERIVEDPARCELS)/momentumParcel/makeMomentumParcelSubmodels.C
|
||||
$(DERIVEDPARCELS)/collidingParcel/makeCollidingParcelSubmodels.C
|
||||
$(DERIVEDPARCELS)/mppicParcel/makeMppicParcelSubmodels.C
|
||||
@ -48,7 +48,7 @@ $(DERIVEDPARCELS)/reactingParcel/makeReactingParcelSubmodels.C
|
||||
$(DERIVEDPARCELS)/reactingMultiphaseParcel/makeReactingMultiphaseParcelSubmodels.C
|
||||
$(DERIVEDPARCELS)/sprayParcel/makeSprayParcelSubmodels.C
|
||||
|
||||
/* bolt-on models */
|
||||
# bolt-on models
|
||||
RADIATION=submodels/addOns/radiation
|
||||
$(RADIATION)/absorptionEmission/cloudAbsorptionEmission/cloudAbsorptionEmission.C
|
||||
$(RADIATION)/scatter/cloudScatter/cloudScatter.C
|
||||
@ -96,21 +96,21 @@ $(MPPICTIMESCALE)/equilibrium/equilibrium.C
|
||||
$(MPPICTIMESCALE)/nonEquilibrium/nonEquilibrium.C
|
||||
$(MPPICTIMESCALE)/isotropic/isotropic.C
|
||||
|
||||
/* integration schemes */
|
||||
# integration schemes
|
||||
integrationScheme/integrationScheme/integrationScheme.C
|
||||
integrationScheme/integrationScheme/integrationSchemeNew.C
|
||||
integrationScheme/Euler/Euler.C
|
||||
integrationScheme/analytical/analytical.C
|
||||
|
||||
/* phase properties */
|
||||
# phase properties
|
||||
phaseProperties/phaseProperties/phaseProperties.C
|
||||
phaseProperties/phaseProperties/phasePropertiesIO.C
|
||||
phaseProperties/phasePropertiesList/phasePropertiesList.C
|
||||
|
||||
/* additional helper classes */
|
||||
# additional helper classes
|
||||
clouds/Templates/MomentumCloud/cloudSolution/cloudSolution.C
|
||||
|
||||
/* averaging methods */
|
||||
# averaging methods
|
||||
submodels/MPPIC/AveragingMethods/makeAveragingMethods.C
|
||||
|
||||
LIB = $(FOAM_LIBBIN)/liblagrangianParcel
|
||||
|
||||
@ -1,7 +1,7 @@
|
||||
PARCELS=parcels
|
||||
DERIVEDPARCELS=$(PARCELS)/derived
|
||||
|
||||
/* sub-models */
|
||||
# sub-models
|
||||
$(DERIVEDPARCELS)/momentumParcel/makeMomentumParcelSubmodels.C
|
||||
$(DERIVEDPARCELS)/collidingParcel/makeCollidingParcelSubmodels.C
|
||||
$(DERIVEDPARCELS)/mppicParcel/makeMppicParcelSubmodels.C
|
||||
|
||||
@ -1,5 +1,5 @@
|
||||
snappyHexMeshDriver/snappyLayerDriver.C
|
||||
/* snappyHexMeshDriver/snappyLayerDriverShrink.C */
|
||||
# snappyHexMeshDriver/snappyLayerDriverShrink.C
|
||||
snappyHexMeshDriver/snappySnapDriver.C
|
||||
snappyHexMeshDriver/snappySnapDriverFeature.C
|
||||
snappyHexMeshDriver/snappyRefineDriver.C
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
/* Radiation model */
|
||||
# Radiation model
|
||||
radiationModels/radiationModel/radiationModel.C
|
||||
radiationModels/radiationModel/radiationModelNew.C
|
||||
radiationModels/noRadiation/noRadiation.C
|
||||
@ -10,13 +10,13 @@ radiationModels/fvDOM/absorptionCoeffs/absorptionCoeffs.C
|
||||
radiationModels/viewFactor/viewFactor.C
|
||||
radiationModels/opaqueSolid/opaqueSolid.C
|
||||
|
||||
/* Scatter model */
|
||||
# Scatter model
|
||||
scatterModels/scatterModel/scatterModel.C
|
||||
scatterModels/scatterModel/scatterModelNew.C
|
||||
scatterModels/noScatter/noScatter.C
|
||||
scatterModels/constantScatter/constantScatter.C
|
||||
|
||||
/* Absorption/Emission model */
|
||||
# Absorption/Emission model
|
||||
absorptionEmissionModels/absorptionEmissionModel/absorptionEmissionModel.C
|
||||
absorptionEmissionModels/absorptionEmissionModel/absorptionEmissionModelNew.C
|
||||
absorptionEmissionModels/noAbsorptionEmission/noAbsorptionEmission.C
|
||||
@ -26,12 +26,12 @@ absorptionEmissionModels/greyMean/greyMean.C
|
||||
absorptionEmissionModels/wideBand/wideBand.C
|
||||
absorptionEmissionModels/interpolationLookUpTable/interpolationLookUpTable.C
|
||||
|
||||
/* Soot model */
|
||||
# Soot model
|
||||
sootModels/sootModel/sootModel.C
|
||||
sootModels/sootModel/sootModelNew.C
|
||||
sootModels/noSoot/noSoot.C
|
||||
|
||||
/* Boundary conditions */
|
||||
# Boundary conditions
|
||||
derivedFvPatchFields/MarshakRadiation/MarshakRadiationFvPatchScalarField.C
|
||||
derivedFvPatchFields/MarshakRadiationFixedTemperature/MarshakRadiationFixedTemperatureFvPatchScalarField.C
|
||||
derivedFvPatchFields/greyDiffusiveRadiation/greyDiffusiveRadiationMixedFvPatchScalarField.C
|
||||
@ -39,7 +39,7 @@ derivedFvPatchFields/wideBandDiffusiveRadiation/wideBandDiffusiveRadiationMixedF
|
||||
derivedFvPatchFields/radiationCoupledBase/radiationCoupledBase.C
|
||||
derivedFvPatchFields/greyDiffusiveViewFactor/greyDiffusiveViewFactorFixedValueFvPatchScalarField.C
|
||||
|
||||
/* fvOptions */
|
||||
# fvOptions
|
||||
fvOptions/radiation/radiation.C
|
||||
|
||||
LIB = $(FOAM_LIBBIN)/libradiationModels
|
||||
|
||||
@ -1,9 +1,9 @@
|
||||
/* Region models */
|
||||
# Region models
|
||||
regionModel/regionModel.C
|
||||
singleLayerRegion/singleLayerRegion.C
|
||||
regionModel1D/regionModel1D.C
|
||||
|
||||
/* Boundary conditions */
|
||||
# Boundary conditions
|
||||
derivedFvPatches/mappedVariableThicknessWall/mappedVariableThicknessWallFvPatch.C
|
||||
|
||||
regionProperties/regionProperties.C
|
||||
|
||||
@ -1,4 +1,4 @@
|
||||
/* Surface film models */
|
||||
# Surface film models
|
||||
surfaceFilmModel/surfaceFilmModel.C
|
||||
surfaceFilmModel/surfaceFilmModelNew.C
|
||||
surfaceFilmRegionModel/surfaceFilmRegionModel.C
|
||||
@ -7,7 +7,7 @@ kinematicSingleLayer/kinematicSingleLayer.C
|
||||
thermoSingleLayer/thermoSingleLayer.C
|
||||
|
||||
|
||||
/* Sub-models */
|
||||
# Sub-models
|
||||
submodels/filmSubModelBase.C
|
||||
|
||||
KINEMATICMODELS=submodels/kinematic
|
||||
@ -71,7 +71,7 @@ $(THERMOMODELS)/filmViscosityModel/function1Viscosity/function1Viscosity.C
|
||||
$(THERMOMODELS)/filmViscosityModel/waxSolventViscosity/waxSolventViscosity.C
|
||||
|
||||
|
||||
/* Boundary conditions */
|
||||
# Boundary conditions
|
||||
PATCHFIELDS=derivedFvPatchFields
|
||||
$(PATCHFIELDS)/filmHeightInletVelocity/filmHeightInletVelocityFvPatchVectorField.C
|
||||
$(PATCHFIELDS)/inclinedFilmNusseltHeight/inclinedFilmNusseltHeightFvPatchScalarField.C
|
||||
|
||||
@ -1,13 +1,11 @@
|
||||
topoChangerFvMesh/topoChangerFvMesh.C
|
||||
rawTopoChangerFvMesh/rawTopoChangerFvMesh.C
|
||||
|
||||
/*
|
||||
linearValveFvMesh/linearValveFvMesh.C
|
||||
linearValveLayersFvMesh/linearValveLayersFvMesh.C
|
||||
*/
|
||||
# linearValveFvMesh/linearValveFvMesh.C
|
||||
# linearValveLayersFvMesh/linearValveLayersFvMesh.C
|
||||
|
||||
movingConeTopoFvMesh/movingConeTopoFvMesh.C
|
||||
/*
|
||||
mixerFvMesh/mixerFvMesh.C
|
||||
*/
|
||||
|
||||
# mixerFvMesh/mixerFvMesh.C
|
||||
|
||||
LIB = $(FOAM_LIBBIN)/libtopoChangerFvMesh
|
||||
|
||||
@ -27,9 +27,8 @@
|
||||
# Description
|
||||
# A Makefile to process Make/files for gmake
|
||||
#
|
||||
# If the Make/files file does not contain a SOURCE entry it is parsed by cpp
|
||||
# to filter comments, expands macros and variable and the source file list
|
||||
# is converted into the SOURCE entry for gmake.
|
||||
# If the Make/files file does not contain a SOURCE list the source file
|
||||
# names in it are converted into the SOURCE list for gmake.
|
||||
#------------------------------------------------------------------------------
|
||||
|
||||
GENERAL_RULES = $(WM_DIR)/rules/General
|
||||
@ -54,22 +53,12 @@ include $(OPTIONS)
|
||||
|
||||
all : $(FILES)
|
||||
|
||||
# Create a grep pattern from the source file suffix list
|
||||
SUFFIX_PATTERN = \
|
||||
$(shell echo $(SUFFIXES) \
|
||||
| sed -e "s/\([a-zA-Z]\) \./\1\\\|./g" -e "s/\./\\\./g")
|
||||
# Create a sed pattern from the source file suffix list
|
||||
SUFFIX_SED = $(foreach s,$(SUFFIXES),'-e s/\(^ *[^ ]*\$(s)$$\)/SOURCE += \1/')
|
||||
|
||||
# Prepend SOURCE += to each of the source file names
|
||||
$(FILES): $(MAKE_DIR)/files
|
||||
@$(CPP) $(GFLAGS) $(MAKE_DIR)/files | sed -e 's@ *@ @g' \
|
||||
> $(OBJECTS_DIR)/cppdFiles
|
||||
# Use the suffix pattern to find all non source file lines in files
|
||||
@grep -v "$(SUFFIX_PATTERN)" $(OBJECTS_DIR)/cppdFiles > $(FILES)
|
||||
# Use the suffix pattern to create the SOURCE entry from the source files
|
||||
@echo "SOURCE = \\" >> $(FILES)
|
||||
@grep "$(SUFFIX_PATTERN)" $(OBJECTS_DIR)/cppdFiles \
|
||||
| sed -e 's,$$, \\,' -e '$$s,\\,,' >> $(FILES)
|
||||
# Remove the temporary cpp'd files file
|
||||
@rm -f $(OBJECTS_DIR)/cppdFiles
|
||||
@sed $(SUFFIX_SED) $(MAKE_DIR)/files > $(FILES)
|
||||
|
||||
|
||||
#------------------------------------------------------------------------------
|
||||
|
||||
@ -106,12 +106,17 @@ include $(GENERAL_RULES)/general
|
||||
|
||||
|
||||
#------------------------------------------------------------------------------
|
||||
# Include PROJECT directory tree file and
|
||||
# source, object and dependency list files.
|
||||
# These are constructed by makefiles/files
|
||||
# Include the options file which might contain specific rules, suffixes etc.
|
||||
#------------------------------------------------------------------------------
|
||||
|
||||
include $(OPTIONS)
|
||||
include $(GENERAL_RULES)/transform
|
||||
|
||||
|
||||
#------------------------------------------------------------------------------
|
||||
# Include the files file containing the list of source files to compile
|
||||
#------------------------------------------------------------------------------
|
||||
|
||||
include $(FILES)
|
||||
DEPENDENCIES=$(SOURCE:%=$(OBJECTS_DIR)/%.dep)
|
||||
BASENAMES=$(basename $(SOURCE))
|
||||
|
||||
@ -28,7 +28,6 @@ include $(DEFAULT_RULES)/general
|
||||
include $(DEFAULT_RULES)/$(WM_LINK_LANGUAGE)
|
||||
-include $(RULES)/general
|
||||
-include $(RULES)/$(WM_LINK_LANGUAGE)
|
||||
include $(GENERAL_RULES)/transform
|
||||
|
||||
|
||||
#------------------------------------------------------------------------------
|
||||
|
||||
Reference in New Issue
Block a user