[lld] r234553 - Reapply r234378, with test fixed (by emaste).

Davide Italiano davide at freebsd.org
Thu Apr 9 18:40:26 PDT 2015


Author: davide
Date: Thu Apr  9 20:40:25 2015
New Revision: 234553

URL: http://llvm.org/viewvc/llvm-project?rev=234553&view=rev
Log:
Reapply r234378, with test fixed (by emaste).

Hopefully this time the build won't be broken.

Modified:
    lld/trunk/lib/Core/LinkingContext.cpp
    lld/trunk/test/elf/dynamic-undef.test

Modified: lld/trunk/lib/Core/LinkingContext.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/lib/Core/LinkingContext.cpp?rev=234553&r1=234552&r2=234553&view=diff
==============================================================================
--- lld/trunk/lib/Core/LinkingContext.cpp (original)
+++ lld/trunk/lib/Core/LinkingContext.cpp Thu Apr  9 20:40:25 2015
@@ -24,7 +24,7 @@ LinkingContext::LinkingContext()
       _warnIfCoalesableAtomsHaveDifferentCanBeNull(false),
       _warnIfCoalesableAtomsHaveDifferentLoadName(false),
       _printRemainingUndefines(true), _allowRemainingUndefines(false),
-      _logInputFiles(false), _allowShlibUndefines(false),
+      _logInputFiles(false), _allowShlibUndefines(true),
       _outputFileType(OutputFileType::Default), _nextOrdinal(0) {}
 
 LinkingContext::~LinkingContext() {}

Modified: lld/trunk/test/elf/dynamic-undef.test
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/test/elf/dynamic-undef.test?rev=234553&r1=234552&r2=234553&view=diff
==============================================================================
--- lld/trunk/test/elf/dynamic-undef.test (original)
+++ lld/trunk/test/elf/dynamic-undef.test Thu Apr  9 20:40:25 2015
@@ -3,14 +3,18 @@
 # to create an executable and a shared library
 #
 # This test will fail because there are unresolved symbols from the shared
-# library and we are not passing --allow-shlib-undefined
+# library and we are passing --no-allow-shlib-undefined
 RUN: not lld -flavor gnu -target x86_64-linux %p/Inputs/tls.x86-64 \
-RUN:   %p/Inputs/shared.so-x86-64 -o %t -e main 2> %t1
+RUN:   %p/Inputs/shared.so-x86-64 -o %t -e main --no-allow-shlib-undefined 2> %t1
 RUN: FileCheck -check-prefix=EXEC %s < %t1
 # This test will pass because of --allow-shlib-undefined
 RUN: lld -flavor gnu -target x86_64-linux %p/Inputs/tls.x86-64 \
 RUN:   %p/Inputs/shared.so-x86-64 -o %t -e main --allow-shlib-undefined \
 RUN:   --defsym=__tls_get_addr=0
+# This test will pass becase --allow-shlib-undefined is the default.
+RUN: lld -flavor gnu -target x86_64-linux %p/Inputs/tls.x86-64 \
+RUN:   %p/Inputs/shared.so-x86-64 -o %t -e main \
+RUN:   --defsym=__tls_get_addr=0
 # Building shared libraries should not fail when there is a undefined symbol.
 # Test creation of shared library, this should pass because we are using
 # shared option and by default, dynamic library wouldn't create undefined atoms





More information about the llvm-commits mailing list