Fix a warning about undeclared call to abort().


git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@212232 91177308-0d34-0410-b5e6-96231b3b80d8
Add a cmake build system.

Will add support for tests with lit in a later patch.
This does not yet support building the unwinder in src/Unwind.


git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@212286 91177308-0d34-0410-b5e6-96231b3b80d8
Add lit configs for libcxxabi tests.

This makes running libcxxabi tests on Linux _much_ easier.
Adds a check-libcxxabi target to cmake.

Also defaults to building a dynamic libc++abi. This is so that the
default options still test the libc++abi that is being built. There are
two problems with testing a static libc++abi. In the case of a
standalone build, the tests will link the system's libc++, which might
not have been built against our libc++abi. In the case of an in tree
build, libc++ will prefer a dynamic libc++abi from the system over a
static libc++abi from the output directory.


git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@212672 91177308-0d34-0410-b5e6-96231b3b80d8
Make cmake cxxflags match those in lib/buildit.


git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@212768 91177308-0d34-0410-b5e6-96231b3b80d8
Add support for building and testing the unwinder.

Note: The unwinder currently only works on Darwin and on ARM Linux.
Non-ARM Linux support is not yet implemented, and will fail to build.


git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@212824 91177308-0d34-0410-b5e6-96231b3b80d8
Support LLVM_LIBDIR_SUFFIX.

This is useful for distros installing under /usr/lib64.

Patch from İsmail Dönmez.


git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@212826 91177308-0d34-0410-b5e6-96231b3b80d8
Fix for libc++abi when using -Wl,--as-needed.

The cmake files for libc++abi and the unwinder weren't linking against
libpthread or an unwind library. If the tests were linked with
-Wl,--as-needed, these libraries wouldn't be linked, causing them to
fail.

Patch contributed by İsmail Dönmez.


git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@212958 91177308-0d34-0410-b5e6-96231b3b80d8
libcxxabi cmake: Use HandleLLVMOptions.cmake, don't manually add -std=c++11.

No intended behavior change on Linux and Mac OS X.  On Windows, having libcxxabi
in one's checkout should now no longer break running cmake. (cl.exe supports
c++11, but doesn't understand a -std= flag.)


git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@213214 91177308-0d34-0410-b5e6-96231b3b80d8
[unwinder] Tell the assembler that functions are functions so that the linker knows how to link them.

This fixes an interworking problem when the unwinder/libcxxabi is built for
Thumb. When unw_getcontext is not marked as a function, 'bl' is used for the
branch instead of 'bx'.


git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@214573 91177308-0d34-0410-b5e6-96231b3b80d8
Fix a copy-pasta in r214573

git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@214873 91177308-0d34-0410-b5e6-96231b3b80d8
Update CREDITS.txt with the list of folks who worked on ARM EHABI support

git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@214877 91177308-0d34-0410-b5e6-96231b3b80d8
Fix the CMake build on Mac when setting MACOSX_DEPLOYMENT_TARGET=10.6

The build file was trying to use LIBCXXABI_VERSION, which isn't set
anywhere.

git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@215465 91177308-0d34-0410-b5e6-96231b3b80d8
libcxxabi must link to dl if using bundled unwind

Patch by Ismail Donmez
http://reviews.llvm.org/D4953


git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@215950 91177308-0d34-0410-b5e6-96231b3b80d8
Improve logging of aborts for Android.

In Android, stderr only goes to the console, and as such will only ever
be seen by adb shell users. Since very few developers will ever actually
see that, also send the abort message to logcat and the tombstone.


git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@215983 91177308-0d34-0410-b5e6-96231b3b80d8
Add baremetal ARM support to libcxxabi/libunwind

http://reviews.llvm.org/D4993


git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@216202 91177308-0d34-0410-b5e6-96231b3b80d8
Remove strict dependency on llvm-config.

Depending on llvm-config allows for a few nice things (auto-detecting
LLVM source tree, version numbers, etc), but it's makes bootstrapping a
pain. Keep the llvm-config features around, but also fall back to being
able to configure based on -DLLVM_PATH=path/to/llvm.

Reviewers: jroelofs, loladiro

Reviewed By: loladiro

Subscribers: cfe-commits

Differential Revision: http://reviews.llvm.org/D5016


git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@216482 91177308-0d34-0410-b5e6-96231b3b80d8
Make _Unwind_Backtrace() work on ARM.

Summary: Since the personality functions do the actual unwinding on ARM,
and will also stop unwinding when they encounter a handler, we invoke
_Unwind_VRS_Interpret() directly form _Unwind_Backtrace().

To simplify, the logic for decoding an EHT is moved out of
unwindOneFrame() and into its own function, decode_eht_entry(). Unlike
unwindOneFrame(), which could only handle ARM's compact personality
function entries (section 6.3) decode_eht_entry() can handle the generic
entries (section 6.2).

Reviewers: jroelofs

Reviewed By: jroelofs

Subscribers: piman, aemerson, cfe-commits

Differential Revision: http://reviews.llvm.org/D5112


git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@216730 91177308-0d34-0410-b5e6-96231b3b80d8
Add missing include to a test case.

Some platforms get size_t defined transitively by another include, but
Android does not.


git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@216738 91177308-0d34-0410-b5e6-96231b3b80d8
Allow LIBCXXABI_SINGLE_THREADED to be defined by build scripts

git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@216952 91177308-0d34-0410-b5e6-96231b3b80d8
s/LIBCXXABI_SINGLE_THREADED/LIBCXXABI_HAS_NO_THREADS/ for consistency with libcxx

Also remove the audotedection part so that if you're crazy enough to want a
single-threaded abi library, you'll say so explicitly in the build.


git-svn-id: https://llvm.org/svn/llvm-project/libcxxabi/trunk@217262 91177308-0d34-0410-b5e6-96231b3b80d8