summaryrefslogtreecommitdiffstats
path: root/libcxx/CMakeLists.txt
Commit message (Collapse)AuthorAgeFilesLines
...
* Revert "Fix llvm-lit script generation in libcxx."Zachary Turner2017-09-191-10/+0
| | | | | | | | | | | | This reverts commit 4ad71811d45268d81b60f27e3b8b2bcbc23bd7b9. There is a bot that is checking out libcxx and lit with nothing else and then running lit.py against the test tree. Since there's no LLVM source tree, there's no LLVM CMake. CMake actually reports this as a warning saying unsupported libcxx configuration, but I guess someone is depending on it anyway. llvm-svn: 313607
* Fix llvm-lit script generation in libcxx.Zachary Turner2017-09-191-0/+10
| | | | | | Differential Revision: https://reviews.llvm.org/D37997 llvm-svn: 313606
* [libc++] Prevent stale site configuration headersShoaib Meenai2017-09-141-1/+7
| | | | | | | | | | | If we define cmake macros that require a site config, and then undefine all such macros, a stale site config header will be left behind. Explicitly delete any generate site config if we don't need one to avoid this. Differential Revision: https://reviews.llvm.org/D36720 llvm-svn: 313284
* Update _LIBCPP_VERSION and the version in CMakeLists to 6.0Hans Wennborg2017-07-191-1/+1
| | | | llvm-svn: 308468
* [libcxx][CMake] Add install path variable to allow overriding the destinationPetr Hosek2017-07-111-0/+7
| | | | | | | | | This is going to be used by the runtime build in the multi-target setup to allow using different install prefix for each target. Differential Revision: https://reviews.llvm.org/D33762 llvm-svn: 307615
* Fix discovery of cxxabi.h in the monorepo layoutReid Kleckner2017-06-201-0/+1
| | | | llvm-svn: 305841
* Add <experimental/coroutine>Eric Fiselier2017-05-251-0/+5
| | | | | | | This patch adds the library portions of the coroutines PDTS, which should now be supported by Clang. llvm-svn: 303836
* test commitEric Fiselier2017-05-041-0/+1
| | | | llvm-svn: 302122
* test commitEric Fiselier2017-05-041-1/+0
| | | | llvm-svn: 302120
* [libcxx][CMake] Set library dir when built under runtimes/Jonas Hahnfeld2017-05-041-1/+5
| | | | | | | | This will put libraries into the build root's lib/ directory by default. Differential Revision: https://reviews.llvm.org/D32736 llvm-svn: 302117
* CMake: Only add test/ subdirectory when it existsDuncan P. N. Exon Smith2017-05-031-1/+6
| | | | | | | | | | | | | r296685 started adding the test/ subdirectory even when LIBCXX_INCLUDE_TESTS=OFF. This is great for testing libcxx standalone, but it also breaks the build when the test/ subdirectory is removed (and our submission system strips all test/ directories). This patch updates the logic to check for test/ before adding it. rdar://problem/31931366 llvm-svn: 302095
* [libc++] Default to vcruntime when targeting MSVCShoaib Meenai2017-04-201-11/+9
| | | | | | | | | | | | Summary: libc++abi is never the right option for LIBCXX_TARGETING_MSVC, since it targets the Itanium ABI, whereas MSVC uses the Microsoft ABI. Make the default ABI be vcruntime when targeting MSVC even if libc++abi is present in the tree. Differential Revision: https://reviews.llvm.org/D32320 llvm-svn: 300921
* Disable the filesystem library on Windows by defaultEric Fiselier2017-04-201-2/+6
| | | | llvm-svn: 300820
* [CMake][libcxx] Fix the --target and --gcc-toolchain flag handlingPetr Hosek2017-04-161-2/+2
| | | | | | | | | | | CMake has the problem with the single dash variant because of the space, so use the double dash with equal sign version. We also don't have to pass the target triple when checking for compiler-rt since that flag is already included in compile flags now. Differential Revision: https://reviews.llvm.org/D32068 llvm-svn: 300409
* [libc++] Explicitly set output directory for DLLShoaib Meenai2017-04-131-0/+1
| | | | | | | DLLs on Windows are treated as runtime targets. Explicitly set the output directory for them, to be consistent with other platforms. llvm-svn: 300206
* suppress GCC warning about noexcept functions changing manglingEric Fiselier2017-04-031-1/+2
| | | | llvm-svn: 299385
* [libc++] Fix some comment typosShoaib Meenai2017-03-251-2/+2
| | | | | | Remove a stray letter, add a missing letter. No functional change. llvm-svn: 298766
* [libc++] Fix word transposition in commentShoaib Meenai2017-03-251-1/+1
| | | | | | "to due" -> "due to". No functional change. llvm-svn: 298764
* [libc++] Fix capitalization in commentShoaib Meenai2017-03-251-1/+1
| | | | | | | Fix a stray capital letter in the middle of a sentence. No functional change. llvm-svn: 298763
* [libc++] Update package versionShoaib Meenai2017-03-251-1/+1
| | | | | | Make it consistent with the rest of LLVM. llvm-svn: 298762
* Change test coverage generation to use llvm-cov instead of gcov.Eric Fiselier2017-03-111-0/+1
| | | | | | | | | | | | | Clang doesn't produce gcov compatible coverage files. This causes lcov to break because it uses gcov by default. This patch switches lcov to use llvm-cov as the gcov-tool. Unfortunatly llvm-cov doesn't provide a gcov like interface by default so it won't work with lcov. However `llvm-cov gcov` does. For this reason we generate 'llvm-cov-wrapper' script that always passes the gcov flag. llvm-svn: 297553
* Work around GCC linking errors within libc++abi due to missing new/delete ↵Eric Fiselier2017-03-021-1/+6
| | | | | | definitions llvm-svn: 296822
* [libc++] Add option to disable new/delete overloads when libc++abi provides ↵Eric Fiselier2017-03-021-0/+14
| | | | | | | | | | | | | | | | | | | | | them. Summary: Currently both libc++ and libc++abi provide definitions for operator new/delete. However I believe this is incorrect and that one or the other should offer them. This patch adds the CMake option `-DLIBCXX_ENABLE_NEW_DELETE_DEFINITIONS` which defaults no `ON` unless `-DLIBCXXABI_ENABLE_NEW_DELETE_DEFINITIONS=ON` is specified. Reviewers: mclow.lists, mehdi_amini, dexonsmith, danalbert, smeenai, mgorny, rmaprath Reviewed By: mehdi_amini Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D30516 llvm-svn: 296802
* Generate the test configuration even when LIBCXX_INCLUDE_TESTS=OFF.Eric Fiselier2017-03-011-2/+6
| | | | | | | | | | This patch changes the CMake configuration so that it always generates the test/lit.site.cfg file, even when testing is disabled. This allows users to test libc++ without requiring them to have a full LLVM checkout on their machine. llvm-svn: 296685
* Recommit "Split exception.cpp and new.cpp implementation into different ↵Eric Fiselier2017-02-101-0/+3
| | | | | | | | | | | | | | | | | | | | | | files for different runtimes." This recommits r294707 with additional fixes. The main difference is libc++ now correctly builds without any ABI library. exception.cpp is a bloody mess. It's full of confusing #ifdef branches for each different ABI library we support, and it's getting unmaintainable. This patch breaks down exception.cpp into multiple different header files, roughly one per implementation. Additionally it moves the definitions of exceptions in new.cpp into the correct implementation header. This patch also removes an unmaintained libc++abi configuration. This configuration may still be used by Apple internally but there are no other possible users. If it turns out that Apple still uses this configuration internally I will re-add it in a later commit. See http://llvm.org/PR31904. llvm-svn: 294730
* Revert "Split exception.cpp and new.cpp implementation into different files ↵Eric Fiselier2017-02-101-3/+0
| | | | | | | | for different runtimes." The compiler-rt CMake configuration needs some tweaking before this can land. llvm-svn: 294727
* Correctly default to using the system libc++abi on Apple.Eric Fiselier2017-02-101-8/+3
| | | | | | | This patch fixes a regression where libc++ didn't correctly select the system libc++abi when no in-tree version was found. llvm-svn: 294712
* Split exception.cpp and new.cpp implementation into different files for ↵Eric Fiselier2017-02-101-0/+8
| | | | | | | | | | | | | | | | | | | different runtimes. exception.cpp is a bloody mess. It's full of confusing #ifdef branches for each different ABI library we support, and it's getting unmaintainable. This patch breaks down exception.cpp into multiple different header files, roughly one per implementation. Additionally it moves the definitions of exceptions in new.cpp into the correct implementation header. This patch also removes an unmaintained libc++abi configuration. This configuration may still be used by Apple internally but there are no other possible users. If it turns out that Apple still uses this configuration internally I will re-add it in a later commit. See http://llvm.org/PR31904. llvm-svn: 294707
* [libcxx][CMake] Support in-tree libunwind when building as part of runtimesPetr Hosek2017-02-091-0/+1
| | | | | | | | | | | When building as part of runtimes, there is no predefined order in which the runtimes are loaded, so the targets from other projects might not be available. We need to rely on HAVE_<name> variables instead in that case. Differential Revision: https://reviews.llvm.org/D29575 llvm-svn: 294553
* Remove CMake hackEric Fiselier2017-02-051-9/+0
| | | | llvm-svn: 294116
* Recommit [libcxx] Never use <cassert> within libc++Eric Fiselier2017-02-041-1/+2
| | | | | | | | | | It is my opinion that libc++ should never use `<cassert>`, including in the `dylib`. This patch remove all uses of `assert` from within libc++ and replaces most of them with `_LIBCPP_ASSERT` instead. Additionally this patch turn `LIBCXX_ENABLE_ASSERTIONS` off by default, because the standard library should not be aborting user programs unless explicitly asked to. llvm-svn: 294107
* Revert "[libcxx] Never use <cassert> within libc++"Eric Fiselier2017-01-241-2/+1
| | | | | | | | This reverts commit r292883. Unfortunately <string_view> uses _LIBCPP_ASSERT in a way which is not compatible with the C++11 dylib build. I'll investigate more tomorrow. llvm-svn: 292923
* [libcxx] Never use <cassert> within libc++Eric Fiselier2017-01-241-1/+2
| | | | | | | | | | | | | | | | | Summary: It is my opinion that libc++ should never use `<cassert>`, including in the `dylib`. This patch remove all uses of `assert` from within libc++ and replaces most of them with `_LIBCPP_ASSERT` instead. Additionally this patch turn `LIBCXX_ENABLE_ASSERTIONS` off by default, because the standard library should not be aborting user programs unless explicitly asked to. Reviewers: mclow.lists, compnerd, smeenai Reviewed By: mclow.lists Subscribers: mgorny, cfe-commits Differential Revision: https://reviews.llvm.org/D29063 llvm-svn: 292883
* Don't strip -m32 from the user provide command line flags. This fixes the ↵Eric Fiselier2017-01-171-2/+2
| | | | | | compiler-rt 32 bit sanitizer build llvm-svn: 292291
* Improve CMake and LIT support for WindowsEric Fiselier2017-01-161-3/+5
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch contains multiple cleanups and fixes to better support building on Windows. * [Test] Fix handling of library runtime search paths by correctly adding them to the PATH variable when running the tests. * [Test] Don't explicitly force "--target=i686-pc-windows" when running the test suite. Clang++ seems to deduce the correct target. * [Test] Fix `.sh.cpp` tests on Windows by properly escaping flags used in shell commands. Specifically windows style paths which included spaces were causing these tests to fail. * [CMake] Add "vcruntime" to the list of supported C++ ABI libraries in CMake, and teach the test suite how to handle it. For now libc++ defaults to using "vcruntime" on Windows except when libc++abi is in tree; That is probably a bug and should be changed to always use vcruntime, at least for now. * [Misc] Move the "c++-build" include directory to the libc++ binary dir instead of the top level project dir and rename it "c++build". This is just misc cleanup. Libc++ shouldn't be creating internal build files and directories at the top-level projects root. * [Misc] Build type_info's destructor when building for MSVC. This is a temporary work around to prevent link errors until we have a proper type_info implementation. llvm-svn: 292157
* Reland "[CMake][libcxx] Check that we have libcxxabi before using it"Petr Hosek2017-01-161-1/+2
| | | | | | This relands commit r291726. llvm-svn: 292086
* Reland "[CMake][libcxx] Do not rely on the existence of c++abi or unwind ↵Petr Hosek2017-01-161-2/+1
| | | | | | | | targets" This relands commit r291727. llvm-svn: 292085
* Reland "[CMake][libcxx] Move Python check to main CMake file"Petr Hosek2017-01-161-0/+9
| | | | | | This relands commit r291728. llvm-svn: 292084
* [libc++][CMake] Use debug MSVC runtimes when libc++ is built in debug modeEric Fiselier2017-01-141-2/+8
| | | | | | | | | | | | Summary: This patch allows libc++ to be built against the debug MSVC runtimes instead of just the release ones. Reviewers: rnk, majnemer, compnerd, smeenai Subscribers: mgorny, cfe-commits Differential Revision: https://reviews.llvm.org/D28725 llvm-svn: 292006
* [libc++] [CMake] Link with /nodefaultlibs on WindowsEric Fiselier2017-01-141-1/+12
| | | | | | | | | | | | | | | | Summary: This patch attempts to fix the libc++ build/link so that it doesn't use an default C++ libraries on Windows. This is needed to prevent linking to MSVC's STL library. Additionally this patch changes libc++ so that it is always linked with the non-debug DLL's (e.g. `/MD`). This is needed so that the test suite can correctly link the same libraries without needing to know which configuration `c++.dll` was linked with. Reviewers: compnerd, rnk, majnemer, kimgr, awson, halyavin, smeenai Subscribers: cfe-commits, mgorny Differential Revision: https://reviews.llvm.org/D28441 llvm-svn: 292001
* Revert "[CMake][libcxx] Move Python check to main CMake file"Petr Hosek2017-01-111-9/+0
| | | | | | This reverts commit 39441fe9f00a58ffc2fdff92a4b0e8a280a5f444. llvm-svn: 291728
* Revert "[CMake][libcxx] Do not rely on the existence of c++abi or unwind ↵Petr Hosek2017-01-111-1/+2
| | | | | | | | targets" This reverts commit 94fc5a96f58071703d81d14690094dcd266a5e17. llvm-svn: 291727
* Revert "[CMake][libcxx] Check that we have libcxxabi before using it"Petr Hosek2017-01-111-2/+1
| | | | | | This reverts commit 8c91834411b322ab360eb1f193f489327e719652. llvm-svn: 291726
* [CMake][libcxx] Check that we have libcxxabi before using itPetr Hosek2017-01-111-1/+2
| | | | | | | | | When doing standalone build, check that we actually have libcxxabi before attempting to use it. Differential Revision: https://reviews.llvm.org/D28580 llvm-svn: 291723
* [CMake][libcxx] Do not rely on the existence of c++abi or unwind targetsPetr Hosek2017-01-111-2/+1
| | | | | | | | | | | There is no guaranteed order in which CMake files for individual runtimes are invoked and therefore we cannot rely on existence of targets defined in other runtimes. Use the new HAVE_<name> options instead in those cases. Differential Revision: https://reviews.llvm.org/D28391 llvm-svn: 291632
* [CMake][libcxx] Move Python check to main CMake filePetr Hosek2017-01-101-0/+9
| | | | | | | | | | This is to make sure this check is called even when building as part of LLVM runtimes when we are doing standalone but not out of tree build. Differential Revision: https://reviews.llvm.org/D28392 llvm-svn: 291592
* [libcxx] Fix externally-threaded shared library builds after r291275.Asiri Rathnayake2017-01-091-11/+12
| | | | | | | | | | Need to allow unresolved symbols in the dylib. This was previously done for LIBCXX_HAS_EXTERNAL_THREAD_API, but we have since split that into two with LIBCXX_BUILD_EXTERNAL_THREAD_LIBRARY being the externally-threaded variant. Also a minor CMakeLists.txt cleanup. llvm-svn: 291433
* Configure default ABI library as NONE on WindowsEric Fiselier2017-01-061-1/+6
| | | | llvm-svn: 291306
* [libc++] Cleanup and document <__threading_support>Eric Fiselier2017-01-061-0/+15
| | | | | | | | | | | | | | | Summary: This patch attempts to clean up the macro configuration mess in `<__threading_support>`, specifically the mess involving external threading variants. Additionally this patch adds design documentation for `<__threading_support>` and the configuration macros it uses. The primary change in this patch is separating the idea of an "external API" provided by `<__external_threading>` and the idea of having an external threading library. Now `_LIBCPP_HAS_THREAD_API_EXTERNAL` means that libc++ should use `<__external_threading>` and that the header is expected to exist. Additionally the new macro `_LIBCPP_HAS_THREAD_LIBRARY_EXTERNAL` is now used to configure for using an "external library" with the default threading API. Reviewers: compnerd, rmaprath Subscribers: smeenai, cfe-commits, mgorny Differential Revision: https://reviews.llvm.org/D28316 llvm-svn: 291275
* [libcxx] Add build/test support for the externally threaded libc++abi variantAsiri Rathnayake2017-01-031-6/+13
| | | | | | | Differential revision: https://reviews.llvm.org/D27576 Reviewers: EricWF llvm-svn: 290889
OpenPOWER on IntegriCloud