aboutsummaryrefslogtreecommitdiffstats
path: root/unittests
diff options
context:
space:
mode:
authorDimitry Andric <dim@FreeBSD.org>2017-01-02 19:19:15 +0000
committerDimitry Andric <dim@FreeBSD.org>2017-01-02 19:19:15 +0000
commitd93e1dfac8711cfed1a9d9cd1876a788b83945cd (patch)
tree5896fa6c02a262a6148b215487e545d937de58b7 /unittests
parent8d43286d630f9224de07809ea253e83ebb9cdee6 (diff)
downloadsrc-d93e1dfac8711cfed1a9d9cd1876a788b83945cd.tar.gz
src-d93e1dfac8711cfed1a9d9cd1876a788b83945cd.zip
Vendor import of lld trunk r290819:vendor/lld/lld-trunk-r290819
Notes
Notes: svn path=/vendor/lld/dist/; revision=311125 svn path=/vendor/lld/lld-trunk-r290819/; revision=311126; tag=vendor/lld/lld-trunk-r290819
Diffstat (limited to 'unittests')
-rw-r--r--unittests/CMakeLists.txt2
-rw-r--r--unittests/MachOTests/MachONormalizedFileBinaryWriterTests.cpp4
2 files changed, 6 insertions, 0 deletions
diff --git a/unittests/CMakeLists.txt b/unittests/CMakeLists.txt
index bb651b5cfe62..9cd085398c37 100644
--- a/unittests/CMakeLists.txt
+++ b/unittests/CMakeLists.txt
@@ -1,6 +1,8 @@
add_custom_target(LLDUnitTests)
set_target_properties(LLDUnitTests PROPERTIES FOLDER "lld tests")
+set(CMAKE_BUILD_WITH_INSTALL_RPATH OFF)
+
# add_lld_unittest(test_dirname file1.cpp file2.cpp)
#
# Will compile the list of files together and link against lld
diff --git a/unittests/MachOTests/MachONormalizedFileBinaryWriterTests.cpp b/unittests/MachOTests/MachONormalizedFileBinaryWriterTests.cpp
index f44950a8d5ab..51196e6eeba6 100644
--- a/unittests/MachOTests/MachONormalizedFileBinaryWriterTests.cpp
+++ b/unittests/MachOTests/MachONormalizedFileBinaryWriterTests.cpp
@@ -219,6 +219,7 @@ TEST(BinaryWriterTest, obj_relocs_x86_64) {
EXPECT_EQ(signed4.isExtern, true);
EXPECT_EQ(signed4.symbol, 1U);
+ bufferOwner.reset(nullptr);
std::error_code ec = llvm::sys::fs::remove(Twine(tmpFl));
EXPECT_FALSE(ec);
}
@@ -329,6 +330,7 @@ TEST(BinaryWriterTest, obj_relocs_x86) {
EXPECT_EQ(tlv.symbol, 1U);
//llvm::errs() << "temp = " << tmpFl << "\n";
+ bufferOwner.reset(nullptr);
std::error_code ec = llvm::sys::fs::remove(Twine(tmpFl));
EXPECT_FALSE(ec);
}
@@ -458,6 +460,7 @@ TEST(BinaryWriterTest, obj_relocs_armv7) {
EXPECT_EQ(absPointer.symbol, 2U);
//llvm::errs() << "temp = " << tmpFl << "\n";
+ bufferOwner.reset(nullptr);
std::error_code ec = llvm::sys::fs::remove(Twine(tmpFl));
EXPECT_FALSE(ec);
}
@@ -687,6 +690,7 @@ TEST(BinaryWriterTest, obj_relocs_ppc) {
EXPECT_EQ(absloa2.length, 2);
EXPECT_EQ(absloa2.symbol, 0U);
+ bufferOwner.reset(nullptr);
std::error_code ec = llvm::sys::fs::remove(Twine(tmpFl));
EXPECT_FALSE(ec);
}