Commit 36f1016f authored by Henry Weller's avatar Henry Weller
Browse files

wmakeFunctions: Added a faster bash version of 'depToSource'

parent af5e1cc4
......@@ -102,12 +102,25 @@ findObjectDir()
fi
}
depToSource()
{
sourceFile=$(echo ${depFile%.dep} | \
sed -e s%platforms/${WM_OPTIONS}/%% -e s%Make/${WM_OPTIONS}/%% \
-e s%platforms/${WM_OPTIONS}${WM_MPLIB}/%% \
-e s%Make/${WM_OPTIONS}${WM_MPLIB}/%% )
}
if [ -n "$BASH_VERSION" ]; then
depToSource()
{
sourceFile=${depFile%.dep}
sourceFile="${sourceFile/platforms\/${WM_OPTIONS}\//}"
sourceFile="${sourceFile/Make\/${WM_OPTIONS}\//}"
sourceFile="${sourceFile/platforms\/${WM_OPTIONS}${WM_MPLIB}\//}"
sourceFile="${sourceFile/Make\/${WM_OPTIONS}${WM_MPLIB}\//}"
}
else
depToSource
{
sourceFile=$(echo ${depFile%.dep} | \
sed -e s%platforms/${WM_OPTIONS}/%% \
-e s%Make/${WM_OPTIONS}/%% \
-e s%platforms/${WM_OPTIONS}${WM_MPLIB}/%% \
-e s%Make/${WM_OPTIONS}${WM_MPLIB}/%% )
}
fi
#------------------------------------------------------------------------------
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment