From: Pierre Gondois <pierre.gond...@arm.com>

The '-march=armv8-a+nofp' flag abort the following build:
  build -a AARCH64 -p Platform/ARM/SgiPkg/PlatformStandaloneMm.dsc
  -t GCC5 -D SECURE_STORAGE_ENABLE
Error message:
  CryptoPkg/Library/OpensslLib/openssl/crypto/rand/drbg_lib.c:1009:12:
  error: ‘+nofp’ feature modifier is incompatible with the use of
  floating-point types
  static int drbg_add(const void *buf, int num, double randomness)
                         ^~~~~~~~

In SgiPlatformMm.dsc.inc, the '-march=armv8-a+nofp' flag was
originally added in:
commit 1974293d1975 ("Platform/ARM/SgiPkg: Build infrastructure for
StandaloneMm image")
as a linker flag. The flag seem to have been added to avoid triggering
an exception due to the floating point unit missing in RTL. With the
latest RTL, the exception is not triggered anymore.

commit 936e8dd57524 ("Platform/Sgi: Cleanup build options for
StandaloneMM context")
moves the flag from the linker to the compiler, making the build fail.

Remove the '-march=armv8-a+nofp' flag as it is not necessary anymore
for SgiPlatformMm.dsc.inc, and is probably not necessary for
PlatformStandaloneMmRpmb.dsc.

CC: Omkar Anand Kulkarni <omkar.kulka...@arm.com>
CC: Pranav Madhu <pranav.ma...@arm.com>
CC: Sayanta Pattanayak <sayanta.pattana...@arm.com>
Signed-off-by: Pierre Gondois <pierre.gond...@arm.com>
---
 Platform/ARM/SgiPkg/SgiPlatformMm.dsc.inc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/Platform/ARM/SgiPkg/SgiPlatformMm.dsc.inc 
b/Platform/ARM/SgiPkg/SgiPlatformMm.dsc.inc
index 01f0a7657c51..f9a516b341f0 100644
--- a/Platform/ARM/SgiPkg/SgiPlatformMm.dsc.inc
+++ b/Platform/ARM/SgiPkg/SgiPlatformMm.dsc.inc
@@ -146,5 +146,5 @@ [Components.AARCH64]
 #
 
###################################################################################################
 [BuildOptions.AARCH64]
-  GCC:*_*_*_CC_FLAGS = -mstrict-align -march=armv8-a+nofp -D 
DISABLE_NEW_DEPRECATED_INTERFACES
+  GCC:*_*_*_CC_FLAGS = -mstrict-align -D DISABLE_NEW_DEPRECATED_INTERFACES
   GCC:*_*_*_DLINK_FLAGS = -z common-page-size=0x1000
-- 
2.25.1



-=-=-=-=-=-=-=-=-=-=-=-
Groups.io Links: You receive all messages sent to this group.
View/Reply Online (#99009): https://edk2.groups.io/g/devel/message/99009
Mute This Topic: https://groups.io/mt/96518042/21656
Group Owner: devel+ow...@edk2.groups.io
Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-


Reply via email to