diff options
author | Michal Gorny <mgorny@gentoo.org> | 2018-12-17 19:14:08 +0000 |
---|---|---|
committer | Michal Gorny <mgorny@gentoo.org> | 2018-12-17 19:14:08 +0000 |
commit | c32d47c6a83dec619c1dd911cb8b544952a5a2df (patch) | |
tree | a5c828ff679ee704c56fe8297cfe18bcf515dab9 /libcxx/utils | |
parent | 916bf993a2ec4b31b7f8dbfdce7c5153c7acfcb1 (diff) | |
download | bcm5719-llvm-c32d47c6a83dec619c1dd911cb8b544952a5a2df.tar.gz bcm5719-llvm-c32d47c6a83dec619c1dd911cb8b544952a5a2df.zip |
[test] Add target_info for NetBSD, and XFAIL some of locale tests
Add a target_info definition for NetBSD. The definition is based
on the one used by FreeBSD, with libcxxrt replaced by libc++abi,
and using llvm-libunwind since we need to use its unwinder
implementation to build anyway.
Additionally, XFAIL the 30 tests that fail because of non-implemented
locale features. According to the manual, NetBSD implements only
LC_CTYPE part of locale handling. However, there is a locale database
in the system and locale specifications are validated against it,
so it makes sense to list the common locales as supported.
If I'm counting correctly, this change enables additional 43 passing
tests.
Differential Revision: https://reviews.llvm.org/D55767
llvm-svn: 349379
Diffstat (limited to 'libcxx/utils')
-rw-r--r-- | libcxx/utils/libcxx/test/target_info.py | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/libcxx/utils/libcxx/test/target_info.py b/libcxx/utils/libcxx/test/target_info.py index 3181d4bd313..32bbb2e1150 100644 --- a/libcxx/utils/libcxx/test/target_info.py +++ b/libcxx/utils/libcxx/test/target_info.py @@ -182,6 +182,18 @@ class FreeBSDLocalTI(DefaultTargetInfo): flags += ['-lc', '-lm', '-lpthread', '-lgcc_s', '-lcxxrt'] +class NetBSDLocalTI(DefaultTargetInfo): + def __init__(self, full_config): + super(NetBSDLocalTI, self).__init__(full_config) + + def add_locale_features(self, features): + add_common_locales(features, self.full_config.lit_config) + + def add_cxx_link_flags(self, flags): + flags += ['-lc', '-lm', '-lpthread', '-lgcc_s', '-lc++abi', + '-lunwind'] + + class LinuxLocalTI(DefaultTargetInfo): def __init__(self, full_config): super(LinuxLocalTI, self).__init__(full_config) @@ -280,6 +292,7 @@ def make_target_info(full_config): target_system = platform.system() if target_system == 'Darwin': return DarwinLocalTI(full_config) if target_system == 'FreeBSD': return FreeBSDLocalTI(full_config) + if target_system == 'NetBSD': return NetBSDLocalTI(full_config) if target_system == 'Linux': return LinuxLocalTI(full_config) if target_system == 'Windows': return WindowsLocalTI(full_config) return DefaultTargetInfo(full_config) |