From e9b185f702240aefc64d2c4842199ef3e6fbbda1 Mon Sep 17 00:00:00 2001 From: Duke Date: Mon, 29 Dec 2025 19:18:57 -0500 Subject: [PATCH] Allow custom compiler via environment variable for src/cc The build system supports using CC to control the C compiler and CXX to control the c++ compiler used but src/cc was hardcoded to use the binary "gcc". Now it respects the custom value of $CC environment variable if it exists. --- src/cc/Makefile_custom | 1 - util/build.sh | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/src/cc/Makefile_custom b/src/cc/Makefile_custom index 9db01b106..d3ecf9c25 100644 --- a/src/cc/Makefile_custom +++ b/src/cc/Makefile_custom @@ -1,5 +1,4 @@ SHELL = /bin/sh -CC = gcc CC_DARWIN = g++-8 CC_WIN = x86_64-w64-mingw32-gcc-posix CC_AARCH64 = aarch64-linux-gnu-g++ diff --git a/util/build.sh b/util/build.sh index ea7acfb33..51c2c5687 100755 --- a/util/build.sh +++ b/util/build.sh @@ -137,7 +137,7 @@ CONFIG_SITE="$PWD/depends/$HOST/share/config.site" ./configure "$HARDENING_ARG" WD=$PWD cd src/cc echo $PWD -./makecustom +CC=${CC:-gcc} ./makecustom cd $WD # Build RandomX