[CMake] Fix linker-as-ld to symlink instead of copy lld
authorChris Bieneman <beanz@apple.com>
Mon, 12 Sep 2016 22:38:43 +0000 (22:38 +0000)
committerChris Bieneman <beanz@apple.com>
Mon, 12 Sep 2016 22:38:43 +0000 (22:38 +0000)
Summary: This test fails if you're building with BUILD_SHARED_LIBS because the LLVM libraries are found via @rpath. Symlinking instead of copying should be sufficiently robust for the test case.

Reviewers: llvm-commits

Subscribers: davide

Differential Revision: https://reviews.llvm.org/D24476

llvm-svn: 281271

lld/test/mach-o/linker-as-ld.yaml

index f0bf189..21afdb2 100644 (file)
@@ -1,7 +1,7 @@
 # REQUIRES: system-linker-mach-o
 #
-# RUN: mkdir -p %t.dir && cp `which lld` %t.dir/ld \
-# RUN:  && %t.dir/ld -arch x86_64 -macosx_version_min 10.8 %s \
+# RUN: rm -rf %T/ld && ln -s `which lld` %T/ld \
+# RUN:  && %T/ld -arch x86_64 -macosx_version_min 10.8 %s \
 # RUN: %p/Inputs/linker-as-ld.yaml -o %t \
 # RUN:  && llvm-nm %t | FileCheck %s
 #