Skip to content

Commit 90eb55f

Browse files
authored
Support setting BINUTILS_DIR as an env var (#718)
Signed-off-by: Sylvain Bellemare <sbellem@gmail.com>
1 parent 82cd9d4 commit 90eb55f

File tree

2 files changed

+3
-3
lines changed

2 files changed

+3
-3
lines changed

buildenv.mk

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -197,9 +197,9 @@ else ifeq ($(MITIGATION-CVE-2020-0551), CF)
197197
endif
198198

199199
ifneq ($(origin NIX_PATH), environment)
200-
BINUTILS_DIR = /usr/local/bin
200+
BINUTILS_DIR ?= /usr/local/bin
201201
else
202-
BINUTILS_DIR = $(ROOT_DIR)/external/toolset/nix/
202+
BINUTILS_DIR ?= $(ROOT_DIR)/external/toolset/nix/
203203
endif
204204

205205
# enable -B option for all the build

common/buildenv.mk

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ SGX_TRUSTED_LIBRARY_PATH ?= $(SGX_SDK)/lib64
3636
CC ?= gcc
3737
CC_VERSION := $(shell $(CC) -dumpversion)
3838
CC_NO_LESS_THAN_8 := $(shell expr $(CC_VERSION) \>\= "8")
39-
BINUTILS_DIR := /usr/local/bin
39+
BINUTILS_DIR ?= /usr/local/bin
4040

4141
MITIGATION_CFLAGS += -B$(BINUTILS_DIR)
4242
MITIGATION_LDFLAGS += -B$(BINUTILS_DIR)

0 commit comments

Comments
 (0)