mirror of
https://github.com/uutils/coreutils.git
synced 2026-06-10 15:48:22 -07:00
Fix namespace collision for test.
To avoid linking issues with Rust's libtest, the crate for the test utility was changed to 'uutest'. However, the user doesn't need to see this so a few hoops were jumped through to make this transparent. I also updated the make rules to build the individual features first and then uutils. This makes 'make && make test' look more organized.
This commit is contained in:
@@ -67,7 +67,7 @@ PROGS := \
|
||||
sync \
|
||||
tac \
|
||||
tee \
|
||||
test_uu \
|
||||
test \
|
||||
tr \
|
||||
true \
|
||||
truncate \
|
||||
@@ -163,7 +163,7 @@ build_exe_$(1):
|
||||
endef
|
||||
|
||||
define TEST_INTEGRATION
|
||||
test_integration_$(1):
|
||||
test_integration_$(1): build_exe_$(1)
|
||||
${CARGO} test --test $(1) --features $(1) --no-default-features
|
||||
endef
|
||||
|
||||
@@ -206,11 +206,10 @@ use_default := 1
|
||||
|
||||
$(foreach util,$(EXES),$(eval $(call BUILD_EXE,$(util))))
|
||||
|
||||
build-uutils:
|
||||
build-uutils: $(addprefix build_exe_,$(EXES))
|
||||
${CARGO} build --features "${EXES}" ${PROFILE_CMD} --no-default-features
|
||||
|
||||
build: build-uutils $(addprefix build_exe_,$(EXES))
|
||||
$(foreach util, ${EXES}, $(call build_pkg, ${util}))
|
||||
build: build-uutils
|
||||
|
||||
$(foreach test,$(TESTS),$(eval $(call TEST_INTEGRATION,$(test))))
|
||||
$(foreach test,$(TESTS),$(eval $(call TEST_UNIT,$(test))))
|
||||
|
||||
Reference in New Issue
Block a user