scc

A fork of https://git.simple-cc.org/scc/ for Qute

git clone https://git.8pit.net/scc.git

 1#!/bin/sh
 2
 3trap 'rm -f $tmp1 f f.?' EXIT
 4trap 'exit $?' HUP INT TERM
 5
 6tmp1=tmp1.$$
 7
 8cat >f.c <<'EOF'
 9int
10main(void)
11{
12	return 0;
13}
14EOF
15
16touch -d '1970-01-01 00:00:01' f.h
17touch -d '1970-01-01 00:00:03' f
18touch -d '1970-01-01 00:00:04' f.c
19
20$EXEC scc make -f- <<'EOF' > $tmp1 2>&1
21f: f.h
22
23f.h:
24	touch $@
25EOF
26
27diff $tmp1 - <<EOF
28c99 -O1  -o f f.c
29EOF