From 02c25035219f20fac9aa6d4a60c8e5e52707044c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ricardo=20Monta=C3=B1ana=20G=C3=B3mez?= Date: Sat, 31 Aug 2024 12:54:39 +0200 Subject: [PATCH] Update Makefile to get parallel info from env --- Makefile | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/Makefile b/Makefile index b138f94..def64c8 100644 --- a/Makefile +++ b/Makefile @@ -2,7 +2,6 @@ f_release = build_release f_debug = build_debug app_targets = PyClassifiers test_targets = unit_tests_pyclassifiers -n_procs = -j 16 define ClearTests @for t in $(test_targets); do \ @@ -33,10 +32,10 @@ dependency: ## Create a dependency graph diagram of the project (build/dependenc cd $(f_debug) && cmake .. --graphviz=dependency.dot && dot -Tpng dependency.dot -o dependency.png buildd: ## Build the debug targets - cmake --build $(f_debug) -t $(app_targets) $(n_procs) + cmake --build $(f_debug) -t $(app_targets) --parallel buildr: ## Build the release targets - cmake --build $(f_release) -t $(app_targets) $(n_procs) + cmake --build $(f_release) -t $(app_targets) --parallel clean: ## Clean the tests info @echo ">>> Cleaning Debug PyClassifiers tests..."; @@ -67,7 +66,7 @@ opt = "" test: ## Run tests (opt="-s") to verbose output the tests, (opt="-c='Test Maximum Spanning Tree'") to run only that section @echo ">>> Running PyClassifiers tests..."; @$(MAKE) clean - @cmake --build $(f_debug) -t $(test_targets) $(n_procs) + @cmake --build $(f_debug) -t $(test_targets) --parallel @for t in $(test_targets); do \ if [ -f $(f_debug)/tests/$$t ]; then \ cd $(f_debug)/tests ; \