[PATCH v2] build: Add TLS_MODEL_FLAGS
Sebastian Huber
sebastian.huber at embedded-brains.de
Thu Jul 21 05:48:59 UTC 2022
Update #4560.
---
v2:
* Do not use -ftls-model=local-exec for targets without TLS support.
spec/build/bsps/bspopts.yml | 2 ++
spec/build/bsps/opttlsmodelflags.yml | 28 ++++++++++++++++++++++++++++
2 files changed, 30 insertions(+)
create mode 100644 spec/build/bsps/opttlsmodelflags.yml
diff --git a/spec/build/bsps/bspopts.yml b/spec/build/bsps/bspopts.yml
index 4a4c06d321..330be27a83 100644
--- a/spec/build/bsps/bspopts.yml
+++ b/spec/build/bsps/bspopts.yml
@@ -13,6 +13,8 @@ links:
uid: optcpukitoptflags
- role: build-dependency
uid: opttestoptflags
+- role: build-dependency
+ uid: opttlsmodelflags
- role: build-dependency
uid: optabi
- role: build-dependency
diff --git a/spec/build/bsps/opttlsmodelflags.yml b/spec/build/bsps/opttlsmodelflags.yml
new file mode 100644
index 0000000000..7d910276b1
--- /dev/null
+++ b/spec/build/bsps/opttlsmodelflags.yml
@@ -0,0 +1,28 @@
+SPDX-License-Identifier: CC-BY-SA-4.0 OR BSD-2-Clause
+actions:
+- get-string: null
+- split: null
+- env-append: ABI_FLAGS
+build-type: option
+copyrights:
+- Copyright (C) 2022 embedded brains GmbH (http://www.embedded-brains.de)
+default:
+- -ftls-model=local-exec
+default-by-variant:
+- value: null
+ variants:
+ - bfin/.*
+ - lm32/.*
+ - mips/.*
+ - moxie/.*
+ - or1k/.*
+ - sh/.*
+ - sparc64/.*
+ - v850/.*
+description: |
+ Defines the compiler flags setting the thread-local storage (TLS) model. The
+ flags are added to the ABI_FLAGS.
+enabled-by: true
+links: []
+name: TLS_MODEL_FLAGS
+type: build
--
2.35.3
More information about the devel
mailing list