-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add verilator as a linter tool
- Loading branch information
Showing
5 changed files
with
24 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,28 @@ | ||
.PHONY: all test test_src test_examples | ||
.PHONY: all lint lint_verilator test test_src test_examples | ||
|
||
all: test | ||
export SVJSON_ROOT := $(realpath .) | ||
|
||
all: lint test | ||
|
||
lint: lint_verilator | ||
|
||
# VARHIDDEN - too strict, method arguments may overlap with class property names | ||
# UNDRIVEN - has false positives on interface classes and custom constructors | ||
lint_verilator: | ||
@echo "Lint sources with Verilator" | ||
verilator --lint-only -f $(SVJSON_ROOT)/src/filelist.f \ | ||
-Wall -Wno-VARHIDDEN -Wno-UNDRIVEN | ||
|
||
test: test_src test_examples | ||
|
||
test_src: | ||
@echo "Run tests for main sources" | ||
make -C tests test | ||
|
||
test_examples: | ||
@echo "Run tests for documentation example snippets" | ||
make -C docs/modules/ROOT/examples/selftest test | ||
|
||
clean: | ||
make -C tests clean | ||
make -C docs/modules/ROOT/examples/selftest clean | ||
make -C docs/modules/ROOT/examples/selftest clean |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters