OctaBuild/example/obuild.cfg

38 lines
556 B
INI
Raw Normal View History

CC = (getenv CC cc)
2015-08-15 02:21:20 +02:00
OBJ = (extreplace (glob *.c) .c .o)
2015-08-15 02:21:20 +02:00
rule test $OBJ [
echo " LD" $target
2015-09-21 21:44:48 +02:00
shell $CC -o $target $sources
2015-08-15 02:21:20 +02:00
]
rule %.o %.c [
echo " CC" $target
2015-09-21 21:44:48 +02:00
shell $CC -c -o $target $source
2015-08-15 02:21:20 +02:00
]
2015-10-26 18:58:47 +01:00
action clean [
2015-08-15 02:21:20 +02:00
echo " CLEAN" $OBJ test
shell rm -f $OBJ test
]
2015-10-26 18:58:47 +01:00
action info [
2015-10-26 19:02:26 +01:00
echo "compiler:" $CC
2015-10-25 19:30:01 +01:00
echo "number of CPUs:" $numcpus
echo "number of jobs:" $numjobs
]
action test_invoke [
invoke test
]
2015-08-15 02:21:20 +02:00
// dependencies
depend foo.o foo.h
depend bar.o bar.h
depend test.o [foo.h bar.h]
// default rule
rule default test