summaryrefslogtreecommitdiffstats
path: root/lldb/unittests/Interpreter/CMakeLists.txt
Commit message (Collapse)AuthorAgeFilesLines
* [CMake] Only the Python scirpt interpreter should link against Python.Jonas Devlieghere2019-04-011-5/+0
| | | | | | This patch removes spurious links against Python. llvm-svn: 357431
* Move Args.cpp from Interpreter to UtilityPavel Labath2018-04-171-1/+0
| | | | | | | | | | | | | | | | | | | | | Summary: The Args class is used in plenty of places besides the command interpreter (e.g., anything requiring an argc+argv combo, such as when launching a process), so it needs to be in a lower layer. Now that the class has no external dependencies, it can be moved down to the Utility module. This removes the last (direct) dependency from the Host module to Interpreter, so I remove the Interpreter module from Host's dependency list. Reviewers: zturner, jingham, davide Subscribers: mgorny, lldb-commits Differential Revision: https://reviews.llvm.org/D45480 llvm-svn: 330200
* Move Args::StringTo*** functions to a new OptionArgParser classPavel Labath2018-04-101-0/+1
| | | | | | | | | | | | | | | | Summary: The idea behind this is to move the functionality which depend on other lldb classes into a separate class. This way, the Args class can be turned into a lightweight arc+argv wrapper and moved into the lower lldb layers. Reviewers: jingham, zturner Subscribers: lldb-commits Differential Revision: https://reviews.llvm.org/D44306 llvm-svn: 329677
* [CMake] Use PRIVATE in target_link_libraries for executablesShoaib Meenai2017-12-051-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | We currently use target_link_libraries without an explicit scope specifier (INTERFACE, PRIVATE or PUBLIC) when linking executables. Dependencies added in this way apply to both the target and its dependencies, i.e. they become part of the executable's link interface and are transitive. Transitive dependencies generally don't make sense for executables, since you wouldn't normally be linking against an executable. This also causes issues for generating install export files when using LLVM_DISTRIBUTION_COMPONENTS. For example, clang has a lot of LLVM library dependencies, which are currently added as interface dependencies. If clang is in the distribution components but the LLVM libraries it depends on aren't (which is a perfectly legitimate use case if the LLVM libraries are being built static and there are therefore no run-time dependencies on them), CMake will complain about the LLVM libraries not being in export set when attempting to generate the install export file for clang. This is reasonable behavior on CMake's part, and the right thing is for LLVM's build system to explicitly use PRIVATE dependencies for executables. Unfortunately, CMake doesn't allow you to mix and match the keyword and non-keyword target_link_libraries signatures for a single target; i.e., if a single call to target_link_libraries for a particular target uses one of the INTERFACE, PRIVATE, or PUBLIC keywords, all other calls must also be updated to use those keywords. This means we must do this change in a single shot. I also fully expect to have missed some instances; I tested by enabling all the projects in the monorepo (except dragonegg), and configuring both with and without shared libraries, on both Darwin and Linux, but I'm planning to rely on the buildbots for other configurations (since it should be pretty easy to fix those). Even after this change, we still have a lot of target_link_libraries calls that don't specify a scope keyword, mostly for shared libraries. I'm thinking about addressing those in a follow-up, but that's a separate change IMO. Differential Revision: https://reviews.llvm.org/D40823 llvm-svn: 319840
* [unittests] Add a helper function for getting an input filePavel Labath2017-06-291-1/+1
| | | | | | | | | | | | | | | | | Summary: Fetching an input file required about five lines of code, and this was repeated in multiple unit tests, with slight variations. Add a helper function for doing that into the lldbUtilityMocks module (which I rename to lldbUtilityHelpers to commemorate the fact it includes more than mocks) Reviewers: zturner, eugene Subscribers: emaste, mgorny, lldb-commits Differential Revision: https://reviews.llvm.org/D34683 llvm-svn: 306668
* Resubmit "Delete the remainder of platform specific code in FileSpec."Zachary Turner2017-03-221-0/+1
| | | | | | | | | | | | | | This was causing a test failure in one of LLDB's tests which specifically dealt with a limitation in LLVM's implementation of home_directory() that LLDB's own implementation had worked around. This limitation has been addressed in r298513 on the LLVM side, so the failing test (which is now unnecessary as the limitation no longer exists) was removed in r298519, allowing this patch to be re-submitted without modification. llvm-svn: 298526
* Revert "Delete the remainder of platform specific code in FileSpec."Pavel Labath2017-03-221-1/+0
| | | | | | | This reverts commit r298465 as it breaks TestLLVM.TestHomeDirectory.test_tilde_home_directory. llvm-svn: 298509
* Delete the remainder of platform specific code in FileSpec.Zachary Turner2017-03-221-0/+1
| | | | | | Differential Revision: https://reviews.llvm.org/D31129 llvm-svn: 298465
* Resubmit "Make file / directory completion work properly on Windows."Zachary Turner2017-03-131-0/+1
| | | | | | This fixes the compilation failures with the original patch. llvm-svn: 297597
* Revert "Make file / directory completion work properly on Windows."Zachary Turner2017-03-121-1/+0
| | | | | | | | | This reverts commit a6a29374662716710f80c8ece96629751697841e. It has a few compilation failures that I don't have time to fix at the moment. llvm-svn: 297589
* Make file / directory completion work properly on Windows.Zachary Turner2017-03-121-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | There were a couple of problems with this function on Windows. Different separators and differences in how tilde expressions are resolved for starters, but in addition there was no clear indication of what the function's inputs or outputs were supposed to be, and there were no tests to demonstrate its use. To more easily paper over the differences between Windows paths, non-Windows paths, and tilde expressions, I've ported this function to use LLVM-based directory iteration (in fact, I would like to eliminate all of LLDB's directory iteration code entirely since LLVM's is cleaner / more efficient (i.e. it invokes fewer stat calls)). and llvm's portable path manipulation library. Since file and directory completion assumes you are referring to files and directories on your local machine, it's safe to assume the path syntax properties of the host in doing so, so LLVM's APIs are perfect for this. I've also added a fairly robust set of unit tests. Since you can't really predict what users will be on your machine, or what their home directories will be, I added an interface called TildeExpressionResolver, and in the unit test I've mocked up a fake implementation that acts like a unix password database. This allows us to configure some fake users and home directories in the test, so we can exercise all of those hard-to-test codepaths that normally otherwise depend on the host. Differential Revision: https://reviews.llvm.org/D30789 llvm-svn: 297585
* [CMake] Update unit tests with accurate dependenciesChris Bieneman2017-02-011-0/+3
| | | | | | This is extending the updates from r293696 to the LLDB unit tests. llvm-svn: 293821
* Fix linking of unit tests via CMake on Windows.Zachary Turner2015-03-181-1/+0
| | | | | | | A previous attempt to make the unit tests link properly on Linux broke it for Windows. This patch fixes it for both platforms. llvm-svn: 232648
* Convert CRLF to LF.Zachary Turner2015-03-171-8/+8
| | | | | | | I accidentally let some Windows line endings slip in. This is a good reminder for me to use core.eol=lf. llvm-svn: 232560
* Fix the clang -Werror build & make the unit tests link under LinuxDavid Blaikie2015-03-171-5/+5
| | | | | | | | The order of libraries passed to the linker didn't work under linux (you need the llvm libraries first, then the lldb libraries). I modelled this after clang's setup here. Seemed simple enough to just be consistent. llvm-svn: 232461
* Fix a bug related to arg escaping, and add unit tests.Zachary Turner2015-03-141-0/+8
A recent refactor had introduced a bug where if you escaped a character, the rest of the string would get processed incorrectly. This patch fixes that bug and adds some unit tests for Args. llvm-svn: 232288
OpenPOWER on IntegriCloud