diff --git a/configure.sh b/configure.sh index 207cf07b2571e864ad10c83b66b3f8a9b287ca53..ebf68812c98414c93577f229ae2f1cf4cdc745ea 100755 --- a/configure.sh +++ b/configure.sh @@ -191,8 +191,9 @@ fi try gen_sensors_h "$sensors" "$nb_sensors" >"$target_hdr" try gen_sensors_mk "$sensors" >"$target_mk" -try printf "LDFLAGS += %s\n" "$NVML_LDFLAGS" >>"$target_mk" -try printf "IFLAGS += %s\n" "$NVML_IFLAGS" >>"$target_mk" + +try printf "NVML_LDFLAGS = %s\n" "$NVML_LDFLAGS" >>"$target_mk" +try printf "NVML_IFLAGS = %s\n" "$NVML_IFLAGS" >>"$target_mk" printf -- 'Run `make` to build `bin/mojitos`.\n' >&2 printf -- 'The resulting binary will have the %d following sensors:\n' "$nb_sensors" >&2 diff --git a/makefile b/makefile index 1b636c4e79a946cdbd020bb6661fedf02f2bd33f..8a3c129038d1bcca02fc07510fbfb99a2a01c99a 100644 --- a/makefile +++ b/makefile @@ -9,8 +9,8 @@ TESTS_DIR = tests BIN = mojitos CAPTOR_OBJ = -IFLAGS = -LDFLAGS = +NVML_LDFLAGS = +NVML_IFLAGS = include ./sensors.mk @@ -19,9 +19,9 @@ OBJ = \ $(OBJ_DIR)/util.o CC = gcc -CPPFLAGS = -std=gnu99 -Wall -Wextra -Wpedantic -Wno-unused-function -I./lib $(IFLAGS) +CPPFLAGS = -std=gnu99 -Wall -Wextra -Wpedantic -Wno-unused-function -I./lib $(NVML_IFLAGS) CFLAGS = $(CPPFLAGS) -O3 -Werror -LDFLAGS += +LDFLAGS = $(NVML_LDFLAGS) ASTYLE = astyle --style=kr -xf -s4 -k3 -n -Z -Q