This is an archive of the discontinued LLVM Phabricator instance.

[CMake] Fix standalone builds: make dependency to LLVM's `count` conditional
ClosedPublic

Authored by sgraenitz on Jan 7 2019, 7:23 AM.

Details

Summary

In standalone builds of LLDB we currently have no target count that tests can depend on. This may be fixed in the future by exporting the target from LLVM similar to targets llvm-config, dsymutil and others.

In-tree build with this patch:

$ ninja -t query tools/lldb/lit/check-lldb-lit
tools/lldb/lit/check-lldb-lit:
input: phony
    tools/lldb/lit/CMakeFiles/check-lldb-lit
    bin/FileCheck
    bin/clang
    bin/count
    bin/darwin-debug
    bin/debugserver
    bin/dsymutil
    bin/llc
    bin/lldb
    bin/lldb-mi
    bin/lldb-server
    bin/lldb-test
    bin/llvm-config
    bin/llvm-mc
    bin/llvm-objcopy
    bin/not
    bin/yaml2obj
    lib/liblldb.dylib
    projects/libcxx/lib/cxx
    tools/lldb/unittests/LLDBUnitTests
outputs:
    tools/lldb/test/check-lldb
    check-lldb-lit

Standalone build with this patch:

$ ninja -t query lit/check-lldb-lit
lit/check-lldb-lit:
input: phony
    lit/CMakeFiles/check-lldb-lit
    bin/darwin-debug
    bin/debugserver
    bin/lldb
    bin/lldb-mi
    bin/lldb-server
    bin/lldb-test
    lib/liblldb.dylib
    unittests/LLDBUnitTests
outputs:
    test/check-lldb
    check-lldb-lit

Diff Detail

Repository
rLLDB LLDB

Event Timeline

sgraenitz created this revision.Jan 7 2019, 7:23 AM
davide accepted this revision.Jan 7 2019, 8:07 AM

LGTM

This revision is now accepted and ready to land.Jan 7 2019, 8:07 AM
This revision was automatically updated to reflect the committed changes.