Allow build.monolithic to search subdirectories.

Uses `find' rather than `echo' to get a list of all source files within
the module directory. The list is passed to sort. Allows subdirectories
using the nnn_name notation to be included in the correct order.
This commit is contained in:
Laurence Withers 2007-09-26 11:52:40 +00:00
parent 2d542ba184
commit 61e8d27edd
8 changed files with 10 additions and 10 deletions

View File

@ -8,7 +8,7 @@ MONOLITHIC_TESTS="src/@NAME@/build.app src/@NAME@/build.monolithic"
if [ -z "${@CNAME@_MONOLITHIC}" ] if [ -z "${@CNAME@_MONOLITHIC}" ]
then then
PREMOC="${SRC}.premoc.cpp" PREMOC="${SRC}.premoc.cpp"
MONOLITHIC_SOURCE="$(echo src/@NAME@/*.cpp)" MONOLITHIC_SOURCE="$(find src/@NAME@/ -name '*.cpp' | sort)"
make_monolithic ${PREMOC} C || return 1 make_monolithic ${PREMOC} C || return 1
if [ "${PREMOC}" -nt "${SRC}" ] if [ "${PREMOC}" -nt "${SRC}" ]

View File

@ -7,7 +7,7 @@ MONOLITHIC_TESTS="src/@NAME@/build.app src/@NAME@/build.monolithic"
if [ -z "${@CNAME@_MONOLITHIC}" ] if [ -z "${@CNAME@_MONOLITHIC}" ]
then then
MONOLITHIC_SOURCE="$(echo src/@NAME@/*.cpp)" MONOLITHIC_SOURCE="$(find src/@NAME@/ -name '*.cpp' | sort)"
make_monolithic ${SRC} C || return 1 make_monolithic ${SRC} C || return 1
@CNAME@_MONOLITHIC=1 @CNAME@_MONOLITHIC=1

View File

@ -7,7 +7,7 @@ MONOLITHIC_TESTS="src/@NAME@/build.app src/@NAME@/build.monolithic"
if [ -z "${@CNAME@_MONOLITHIC}" ] if [ -z "${@CNAME@_MONOLITHIC}" ]
then then
MONOLITHIC_SOURCE="$(echo src/@NAME@/*.c)" MONOLITHIC_SOURCE="$(find src/@NAME@/ -name '*.c' | sort)"
make_monolithic ${SRC} C || return 1 make_monolithic ${SRC} C || return 1
@CNAME@_MONOLITHIC=1 @CNAME@_MONOLITHIC=1

View File

@ -7,7 +7,7 @@ MONOLITHIC_TESTS="src/@NAME@/build.firmware src/@NAME@/build.monolithic"
if [ -z "${@CNAME@_MONOLITHIC}" ] if [ -z "${@CNAME@_MONOLITHIC}" ]
then then
MONOLITHIC_SOURCE="$(echo src/@NAME@/*.asm)" MONOLITHIC_SOURCE="$(find src/@NAME@/ -name '*.asm' | sort)"
make_monolithic ${SRC} none || return 1 make_monolithic ${SRC} none || return 1
@CNAME@_MONOLITHIC=1 @CNAME@_MONOLITHIC=1

View File

@ -7,7 +7,7 @@ MONOLITHIC_TESTS="src/@NAME@/build.firmware src/@NAME@/build.monolithic"
if [ -z "${@CNAME@_MONOLITHIC}" ] if [ -z "${@CNAME@_MONOLITHIC}" ]
then then
MONOLITHIC_SOURCE="$(echo src/@NAME@/*.c)" MONOLITHIC_SOURCE="$(find src/@NAME@/ -name '*.c' | sort)"
make_monolithic ${SRC} C || return 1 make_monolithic ${SRC} C || return 1
@CNAME@_MONOLITHIC=1 @CNAME@_MONOLITHIC=1

View File

@ -8,10 +8,10 @@ MONOLITHIC_TESTS="src/@NAME@/build.lib src/@NAME@/build.monolithic"
if [ -z "${@CNAME@_MONOLITHIC}" ] if [ -z "${@CNAME@_MONOLITHIC}" ]
then then
MONOLITHIC_SOURCE="$(echo src/@NAME@/*.h)" MONOLITHIC_SOURCE="$(find src/@NAME@/ -name '*.h' | sort)"
make_monolithic ${HDR} Ch || return 1 make_monolithic ${HDR} Ch || return 1
MONOLITHIC_SOURCE="$(echo src/@NAME@/*.cpp)" MONOLITHIC_SOURCE="$(find src/@NAME@/ -name '*.cpp' | sort)"
make_monolithic ${SRC} C || return 1 make_monolithic ${SRC} C || return 1
@CNAME@_MONOLITHIC=1 @CNAME@_MONOLITHIC=1

View File

@ -8,10 +8,10 @@ MONOLITHIC_TESTS="src/@NAME@/build.lib src/@NAME@/build.monolithic"
if [ -z "${@CNAME@_MONOLITHIC}" ] if [ -z "${@CNAME@_MONOLITHIC}" ]
then then
MONOLITHIC_SOURCE="$(echo src/@NAME@/*.h)" MONOLITHIC_SOURCE="$(find src/@NAME@/ -name '*.h' | sort)"
make_monolithic ${HDR} Ch || return 1 make_monolithic ${HDR} Ch || return 1
MONOLITHIC_SOURCE="$(echo src/@NAME@/*.c)" MONOLITHIC_SOURCE="$(find src/@NAME@/ -name '*.c' | sort)"
make_monolithic ${SRC} C || return 1 make_monolithic ${SRC} C || return 1
@CNAME@_MONOLITHIC=1 @CNAME@_MONOLITHIC=1

View File

@ -8,7 +8,7 @@ MONOLITHIC_TESTS="src/@NAME@/build.module src/@NAME@/build.monolithic"
if [ -z "${@CNAME@_MONOLITHIC}" ] if [ -z "${@CNAME@_MONOLITHIC}" ]
then then
MONOLITHIC_SOURCE="$(echo src/@NAME@/*.c)" MONOLITHIC_SOURCE="$(find src/@NAME@/ -name '*.c' | sort)"
make_monolithic ${SRC} C || return 1 make_monolithic ${SRC} C || return 1
@CNAME@_MONOLITHIC=1 @CNAME@_MONOLITHIC=1