From 7fc4d77808a1009c8cfe17e361db388507c8d2c7 Mon Sep 17 00:00:00 2001 From: Chris Kay Date: Mon, 15 Jan 2024 18:45:07 +0000 Subject: [PATCH] build: always use the C compiler to assemble The ROM library is the only component in the repository that compiles assembly files using the assembler directly. This change migrates it to the C compiler instead, like the rest of the project. Change-Id: I6c50660eeb9be2ca8dcb0e626c37c197466b0fa1 Signed-off-by: Chris Kay --- changelog.yaml | 5 ++++- lib/romlib/Makefile | 6 +++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/changelog.yaml b/changelog.yaml index c5e157d9b..326308208 100644 --- a/changelog.yaml +++ b/changelog.yaml @@ -1,5 +1,5 @@ # -# Copyright (c) 2021-2023, Arm Limited. All rights reserved. +# Copyright (c) 2021-2024, Arm Limited. All rights reserved. # # SPDX-License-Identifier: BSD-3-Clause # @@ -774,6 +774,9 @@ subsections: - title: PSCI scope: psci + - title: ROMlib + scope: romlib + - title: GPT scope: gpt diff --git a/lib/romlib/Makefile b/lib/romlib/Makefile index 5359f8fbb..8a437440c 100644 --- a/lib/romlib/Makefile +++ b/lib/romlib/Makefile @@ -4,7 +4,7 @@ # SPDX-License-Identifier: BSD-3-Clause # -AS = $(CROSS_COMPILE)as +AS = $(CROSS_COMPILE)gcc AR = $(CROSS_COMPILE)ar LD = $(CROSS_COMPILE)ld OC = $(CROSS_COMPILE)objcopy @@ -48,11 +48,11 @@ all: $(BUILD_DIR)/romlib.bin $(LIB_DIR)/libwrappers.a %.o: %.s @echo " AS $@" - $(Q)$(AS) $(ASFLAGS) -o $@ $< + $(Q)$(AS) -c $(ASFLAGS) -o $@ $< $(BUILD_DIR)/%.o: %.s @echo " AS $@" - $(Q)$(AS) $(ASFLAGS) -o $@ $< + $(Q)$(AS) -c $(ASFLAGS) -o $@ $< $(BUILD_DIR)/romlib.ld: romlib.ld.S @echo " PP $@"