Yu-hsin Wang has uploaded this change for review. ( https://gem5-review.googlesource.com/c/public/gem5/+/64652?usp=email )

Change subject: sim: fix systrace header test
......................................................................

sim: fix systrace header test

Latest compilers default checks the unused and uninitialized. Those
checks result in false negative of the header test. We should fix it.

Change-Id: I3b51faf7595b861bfbd131c0a42fd6d78a5e9698
---
M src/sim/SConsopts
1 file changed, 14 insertions(+), 1 deletion(-)



diff --git a/src/sim/SConsopts b/src/sim/SConsopts
index 07997c7..2f56610 100644
--- a/src/sim/SConsopts
+++ b/src/sim/SConsopts
@@ -31,7 +31,8 @@

 with gem5_scons.Configure(main) as conf:
     if conf.CheckLibWithHeader([None, 'execinfo'], 'execinfo.h', 'C',
-            'char temp; backtrace_symbols_fd((void *)&temp, 0, 0);'):
+            '__attribute__((unused)) char temp = 0;'
+            'backtrace_symbols_fd((void *)&temp, 0, 0);'):
         conf.env['BACKTRACE_IMPL'] = 'glibc'
     else:
         conf.env['BACKTRACE_IMPL'] = 'none'

--
To view, visit https://gem5-review.googlesource.com/c/public/gem5/+/64652?usp=email To unsubscribe, or for help writing mail filters, visit https://gem5-review.googlesource.com/settings

Gerrit-Project: public/gem5
Gerrit-Branch: develop
Gerrit-Change-Id: I3b51faf7595b861bfbd131c0a42fd6d78a5e9698
Gerrit-Change-Number: 64652
Gerrit-PatchSet: 1
Gerrit-Owner: Yu-hsin Wang <[email protected]>
Gerrit-MessageType: newchange
_______________________________________________
gem5-dev mailing list -- [email protected]
To unsubscribe send an email to [email protected]

Reply via email to