Fixed rspy check not being called

# Conflicts:
#	Makefile
This commit is contained in:
evandrocoan 2020-04-30 04:11:50 -03:00
parent 36ea980725
commit 2008f2b7bc
3 changed files with 9 additions and 11 deletions

View File

@ -52,7 +52,7 @@ BUILDFLAGS := --release --strip
DEVFLAGS := $(BUILDFLAGS) DEVFLAGS := $(BUILDFLAGS)
RUNFLAGS := RUNFLAGS :=
CHECKABLE_PY := pylib qt CHECKABLE_PY := pylib qt
CHECKABLE_RS := rslib CHECKABLE_RS := rslib rspy
DEVEL := rslib rspy pylib qt DEVEL := rslib rspy pylib qt
.PHONY: all .PHONY: all
@ -155,14 +155,8 @@ clean-dist: buildhash
check: pyenv buildhash prepare check: pyenv buildhash prepare
@set -eu -o pipefail ${SHELLFLAGS}; \ @set -eu -o pipefail ${SHELLFLAGS}; \
.github/scripts/trailing-newlines.sh; \ .github/scripts/trailing-newlines.sh; \
$(SUBMAKE) -C rslib develop; \
for dir in $(CHECKABLE_RS); do \
$(SUBMAKE) -C $$dir check; \
done; \
. "${ACTIVATE_SCRIPT}"; \ . "${ACTIVATE_SCRIPT}"; \
$(SUBMAKE) -C rspy develop; \ for dir in $(CHECKABLE_RS) $(CHECKABLE_PY); do \
$(SUBMAKE) -C pylib develop; \
for dir in $(CHECKABLE_PY); do \
$(SUBMAKE) -C $$dir check; \ $(SUBMAKE) -C $$dir check; \
done; done;
@echo @echo

View File

@ -17,7 +17,7 @@ $(shell mkdir -p .build)
all: check all: check
check: ftl/repo .build/check check: .build/check
fix: fix:
cargo fmt cargo fmt
@ -41,7 +41,7 @@ RUST_TOOLCHAIN := $(shell cat rust-toolchain)
rustup component add clippy-preview --toolchain $(RUST_TOOLCHAIN) rustup component add clippy-preview --toolchain $(RUST_TOOLCHAIN)
@touch $@ @touch $@
.build/check: .build/rs-tools $(ALL_SOURCE) .build/check: ftl/repo .build/rs-tools $(ALL_SOURCE)
cargo test --lib -- --nocapture cargo test --lib -- --nocapture
cargo fmt -- --check cargo fmt -- --check
cargo clippy -- -D warnings cargo clippy -- -D warnings

View File

@ -90,8 +90,12 @@ RUST_TOOLCHAIN := $(shell cat rust-toolchain)
rustup component add clippy-preview --toolchain $(RUST_TOOLCHAIN) rustup component add clippy-preview --toolchain $(RUST_TOOLCHAIN)
@touch $@ @touch $@
.build/check: build # cargo clippy also run build.rs, thus it must be called before calling .build/develop
.build/check: .build/clippy .build/develop
cargo fmt -- --check cargo fmt -- --check
@touch $@
.build/clippy: $(DEPS)
cargo clippy -- -D warnings cargo clippy -- -D warnings
@touch $@ @touch $@