scc

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

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

 1#!/bin/sh
 2
 3
 4unset LC_ALL
 5LC_COLLATE=C
 6set -e
 7
 8for i
 9do
10	case $i in
11	-c)
12		cpu=$2
13		shift 2
14		;;
15	-*)
16		echo mktbl: incorrect parameter:$i >&2
17		exit 1
18		;;
19	esac
20done
21
22rm -f  $$.c $family/${cpu}tbl.c
23trap 'rm -f $$.c' EXIT
24trap 'exit $?' HUP INT TERM
25
26awk '!/^$/ {print $1,NR,$2,$3,$4,$5,$6}' ops.dat |
27sort -k1 -k2n |
28LC_ALL=C awk -v cpu=`echo $cpu | tr a-z A-Z` -f ../mktbl.awk  > $$.c &&
29mv $$.c ${cpu}tbl.c