mirror of
https://github.com/ARM-software/arm-trusted-firmware.git
synced 2025-04-08 05:43:53 +00:00
build(cert-create): don't generate build_msg.c
This change avoids generating a build message source file on the shell, instead using the `__DATE__` and `__TIME__` macros directly. Change-Id: Ieda75bbac174847c716701bce8dd10b8e9975902 Signed-off-by: Chris Kay <chris.kay@arm.com>
This commit is contained in:
parent
c4d9fbec5e
commit
a004ee8de7
2 changed files with 7 additions and 11 deletions
|
@ -18,6 +18,7 @@ include ${MAKE_HELPERS_DIRECTORY}build_env.mk
|
|||
include ${MAKE_HELPERS_DIRECTORY}common.mk
|
||||
include ${MAKE_HELPERS_DIRECTORY}defaults.mk
|
||||
include ${MAKE_HELPERS_DIRECTORY}toolchain.mk
|
||||
include ${MAKE_HELPERS_DIRECTORY}utilities.mk
|
||||
|
||||
ifneq (${PLAT},none)
|
||||
TF_PLATFORM_ROOT := ../../plat/
|
||||
|
@ -60,7 +61,7 @@ else
|
|||
HOSTCCFLAGS += -O2 -DLOG_LEVEL=20
|
||||
endif
|
||||
|
||||
HOSTCCFLAGS += ${DEFINES}
|
||||
HOSTCCFLAGS += ${DEFINES} -DPLAT_MSG=$(call escape-shell,"$(PLAT_MSG)")
|
||||
# USING_OPENSSL3 flag will be added to the HOSTCCFLAGS variable with the proper
|
||||
# computed value.
|
||||
HOSTCCFLAGS += -DUSING_OPENSSL3=$(USING_OPENSSL3)
|
||||
|
@ -84,10 +85,7 @@ all: --openssl ${BINARY}
|
|||
|
||||
${BINARY}: ${OBJECTS} Makefile
|
||||
$(s)echo " HOSTLD $@"
|
||||
$(q)echo 'const char build_msg[] = "Built : "__TIME__", "__DATE__; \
|
||||
const char platform_msg[] = "${PLAT_MSG}";' | \
|
||||
$(host-cc) -c ${HOSTCCFLAGS} -xc - -o src/build_msg.o
|
||||
$(q)$(host-cc) src/build_msg.o ${OBJECTS} ${LIB_DIR} ${LIB} -o $@
|
||||
$(q)$(host-cc) ${OBJECTS} ${LIB_DIR} ${LIB} -o $@
|
||||
|
||||
%.o: %.c
|
||||
$(s)echo " HOSTCC $<"
|
||||
|
@ -99,7 +97,7 @@ ifeq ($(DEBUG),1)
|
|||
endif
|
||||
|
||||
clean:
|
||||
$(call SHELL_DELETE_ALL, src/build_msg.o ${OBJECTS})
|
||||
$(call SHELL_DELETE_ALL,${OBJECTS})
|
||||
|
||||
realclean: clean
|
||||
$(call SHELL_DELETE,${BINARY})
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
/*
|
||||
* Copyright (c) 2015-2022, Arm Limited and Contributors. All rights reserved.
|
||||
* Copyright (c) 2015-2024, Arm Limited and Contributors. All rights reserved.
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-3-Clause
|
||||
*/
|
||||
|
@ -66,10 +66,8 @@ static int new_keys;
|
|||
static int save_keys;
|
||||
static int print_cert;
|
||||
|
||||
/* Info messages created in the Makefile */
|
||||
extern const char build_msg[];
|
||||
extern const char platform_msg[];
|
||||
|
||||
static const char build_msg[] = "Built : " __TIME__ ", " __DATE__;
|
||||
static const char platform_msg[] = PLAT_MSG;
|
||||
|
||||
static char *strdup(const char *str)
|
||||
{
|
||||
|
|
Loading…
Add table
Reference in a new issue