diff options
author | Giuseppe D'Angelo <giuseppe.dangelo@kdab.com> | 2020-05-25 18:53:31 +0200 |
---|---|---|
committer | Giuseppe D'Angelo <giuseppe.dangelo@kdab.com> | 2020-06-02 01:32:36 +0200 |
commit | 61fb2274ff67515c803f4586a490370db17aa017 (patch) | |
tree | c9518f9b0ccbc5132e0d136b7d5d5c04ca3d9a9c /configure.json | |
parent | 4de8dd50d54f0cd5d83105a048d06d16fd89a878 (diff) |
Fix compilation of PCRE2 under Intel CET
Ubuntu 20.04 enables -fcf-protection by default.
PCRE2 10.35 sees this but complains that -mshstk is also necessary
to build its JIT. Detect whether the compiler is enabling Intel CET
automatically, and if so, build PCRE2 with the right options.
Change-Id: I3440e689b81f4f07055f211a4fa7331a43eb410d
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
(cherry picked from commit 7c8c8272b49372b2a9fd4f95b7a7f31347c06497)
(cherry picked from commit fa98adbd04de9d44ce921436b92589a41f285dcd)
Diffstat (limited to 'configure.json')
-rw-r--r-- | configure.json | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/configure.json b/configure.json index d1eb1d8102..50d69b740d 100644 --- a/configure.json +++ b/configure.json @@ -646,6 +646,17 @@ "label": "ccache", "type": "files", "files": [ "ccache" ] + }, + "intelcet": { + "label": "Support for Intel Control-flow Enforcement Technology", + "type": "compile", + "test": { + "main": [ + "#if !defined(__CET__)", + "# error Intel CET not available", + "#endif" + ] + } } }, @@ -1412,6 +1423,11 @@ "autoDetect": "features.shared", "condition": "features.dlopen || config.win32 || !features.shared", "output": [ "privateFeature" ] + }, + "intelcet": { + "label": "Using Intel CET", + "condition": "tests.intelcet", + "output": [ "privateFeature" ] } }, |