summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDimitry Andric <dimitry@andric.com>2018-09-22 14:37:49 +0000
committerDimitry Andric <dimitry@andric.com>2018-09-22 14:37:49 +0000
commitf3b94728c708df60741bf6c6f054f10c4474fd7f (patch)
tree9c7f5cc8af5b0e4f4ee94ef211a5cdfa04a55366
parentbfc5ef6c5b707e8112846fc5ccecbfe4d0efdbad (diff)
downloadbcm5719-llvm-f3b94728c708df60741bf6c6f054f10c4474fd7f.tar.gz
bcm5719-llvm-f3b94728c708df60741bf6c6f054f10c4474fd7f.zip
Similar to the handling of darwin target triples, strip the version
numbers off of freebsd target triples, when generating the name of the ABI list file for check-cxx-abilist target. Also remove unnecessary parentheses in the regex for darwin, and slightly reword the comment. llvm-svn: 342805
-rw-r--r--libcxx/lib/abi/CMakeLists.txt11
1 files changed, 7 insertions, 4 deletions
diff --git a/libcxx/lib/abi/CMakeLists.txt b/libcxx/lib/abi/CMakeLists.txt
index e42e96173f5..e65df03b5de 100644
--- a/libcxx/lib/abi/CMakeLists.txt
+++ b/libcxx/lib/abi/CMakeLists.txt
@@ -1,9 +1,12 @@
if (DEFINED TARGET_TRIPLE)
- # Ignore the major, minor, and patchlevel versions of the darwin
- # target.
- string(REGEX REPLACE "darwin([0-9]+)\\.([0-9]+)\\.([0-9]+)" "darwin"
- GENERIC_TARGET_TRIPLE "${TARGET_TRIPLE}")
+ # Ignore the major, minor, and patchlevel versions of darwin targets.
+ string(REGEX REPLACE "darwin[0-9]+\\.[0-9]+\\.[0-9]+" "darwin"
+ GENERIC_TARGET_TRIPLE "${TARGET_TRIPLE}")
+
+ # Ignore the major and minor versions of freebsd targets.
+ string(REGEX REPLACE "freebsd[0-9]+\\.[0-9]+" "freebsd"
+ GENERIC_TARGET_TRIPLE "${TARGET_TRIPLE}")
endif()
# Detect if we are building in the same configuration used to generate
OpenPOWER on IntegriCloud