To test it out, try this: ./do -j10 build cd docs/cookbook/c redo -j10 test It should detect all the compilers on your system and make three separate builds for each one: normal, debug, and optimized. Then it tries to run a test program under each one. If there are windows cross compilers and you also have 'wine' installed, it'll try running the test program under wine as well. redoconf currently has no documentation other than the example program. We'll fix that later.
25 lines
590 B
Text
25 lines
590 B
Text
. ./redoconf.rc
|
|
|
|
# this is called by each call to replaceln() and appendln().
|
|
RC_KEYS="RC_KEYS"
|
|
rc_hook() {
|
|
contains_line "$RC_KEYS" "$1" || RC_KEYS="$RC_KEYS$NL$1"
|
|
}
|
|
rc_include _all.rc
|
|
|
|
# Escape double-quote and backslash so they can
|
|
# be included as a C-style double-quoted string.
|
|
cquote() {
|
|
local v="$(xecho "$1" | sed -e 's,[\"\\],\\&,g' -e 's,$, \\,')"
|
|
printf '"%s"' "${v% \\}"
|
|
}
|
|
|
|
(
|
|
echo "# Automatically generated by autovars.od"
|
|
for k in $(echo "$RC_KEYS" | sort); do
|
|
[ "$k" != "RC_INCLUDES" ] || continue
|
|
eval v=\$$k
|
|
echo "$k=$(shquote "$v")"
|
|
done
|
|
) >$3
|
|
redo-stamp <$3
|