Skip to content

Commit 34769d8

Browse files
committed
Use an alternative approach to prevent Spotlight from indexing the build directory.
llvm-svn: 324115
1 parent 78809e5 commit 34769d8

File tree

3 files changed

+7
-10
lines changed

3 files changed

+7
-10
lines changed

lldb/packages/Python/lldbsuite/test/dotest.py

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1200,14 +1200,6 @@ def run_suite():
12001200
build_dir = configuration.test_build_dir
12011201
lldbutil.mkdir_p(build_dir)
12021202

1203-
# Create a marker for Spotlight to never index $BUILD_DIR. LLDB
1204-
# queries Spotlight to locate .dSYM bundles based on the UUID
1205-
# embedded in a binary, and because the UUID is a hash of filename
1206-
# and .text section, there *will* be conflicts inside $BUILD_DIR.
1207-
if platform.system() == "Darwin":
1208-
with open(os.path.join(build_dir, '.metadata_never_index'), 'w+'):
1209-
pass
1210-
12111203
target_platform = lldb.DBG.GetSelectedPlatform().GetTriple().split('-')[2]
12121204

12131205
checkLibcxxSupport()

lldb/packages/Python/lldbsuite/test/dotest_args.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -163,7 +163,7 @@ def create_parser():
163163
'--build-dir',
164164
dest='test_build_dir',
165165
metavar='Test build directory',
166-
default='lldb-test-build',
166+
default='lldb-test-build.noindex',
167167
help='The root build directory for the tests. It will be removed before running.')
168168

169169
# Configuration options

lldb/test/CMakeLists.txt

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,13 +57,18 @@ set(LLDB_TEST_USER_ARGS
5757
""
5858
CACHE STRING "Specify additional arguments to pass to test runner. For example: '-C gcc -C clang -A i386 -A x86_64'")
5959

60+
# The .nodindex suffix is a marker for Spotlight to never index the
61+
# build directory. LLDB queries Spotlight to locate .dSYM bundles
62+
# based on the UUID embedded in a binary, and because the UUID is a
63+
# hash of filename and .text section, there *will* be conflicts inside
64+
# the build directory.
6065
set(LLDB_TEST_COMMON_ARGS
6166
--arch=${LLDB_TEST_ARCH}
6267
--executable $<TARGET_FILE:lldb>
6368
-s
6469
${CMAKE_BINARY_DIR}/lldb-test-traces
6570
--build-dir
66-
${CMAKE_BINARY_DIR}/lldb-test-build
71+
${CMAKE_BINARY_DIR}/lldb-test-build.noindex
6772
-S nm
6873
-u CXXFLAGS
6974
-u CFLAGS

0 commit comments

Comments
 (0)