From 680acef72a84b1d3810ffd88c06639bafd1d4b3a Mon Sep 17 00:00:00 2001 From: Robert Norton Date: Wed, 9 May 2018 16:30:46 +0100 Subject: Add targets for counting lines in mips, cheri and riscv. Can use either sloccount or cloc. sloccount seems to be reliable but lacks a way to tell it that sail files can be treated like ocaml without renaming the files. cloc has a nicer interface is lower quality in other regards like broken ocaml support in versions shipped with Ubuntu (e.g. treats {...} as comment, no nested comments support). For sail2 syntax this is OK because we use the C parser instead which gives the same results as sloccount. --- cheri/Makefile | 2 ++ 1 file changed, 2 insertions(+) (limited to 'cheri/Makefile') diff --git a/cheri/Makefile b/cheri/Makefile index fb54f103..a5df5f1e 100644 --- a/cheri/Makefile +++ b/cheri/Makefile @@ -40,6 +40,8 @@ cheri128: $(CHERI128_SAILS) $(CHERI_MAIN) cheri128_trace: $(CHERI128_SAILS) $(CHERI_MAIN) $(SAIL) -ocaml_trace -o $@ $^ +LOC_FILES:=$(CHERI_SAILS) $(CHERI_MAIN) +include ../etc/loc.mk # TODO Using bit lists for now in Lem generation; for machine words, # monomorphisation is needed due to some variable length bitvectors, e.g. in -- cgit v1.2.3