This is all a bit hairy and magical, and I don't entirely understand how this works, but here is what I am trying to achieve:
- debuginfo-tests needs to be able to depend on both clang and lld.
- It needs to work both with and without the monorepo
- It should be opt-in
Currently the assumption is that you clone it under the clang/test folder, but the fact that it needs to depend on lld means that clang isn't really the best place for it. Besides, this is already broken in the mono-repo unless you manually symlink it from clang/test which seems odd.
It currently runs automatically as part of ninja check-clang, and this satisfies the opt in requirement by saying that you opt in by cloning the repo into the clang tree the first place. With this patch, the opt-in requirement is satisfied by creating a new cmake target for it, so if you want to run it you just run ninja check-debuginfo.
In order for all of this to work, I had to give it its own lit configs, and this is where things start going crazy. These lit configs are a bit of magic to me, so I'm not sure if I did this right. I copied the clang lit configs as the starting poitn, and deleted a bunch of stuff from them that I don't think we need for the purposes of debug info tests. sanitizer stuff, clang tool stuff, etc. in any case, on windows I can now run ninja check-debuginfo and it actually runs the test suite.
They all fail for me, but this is because it's trying to run a perl script to kick off the test, and my machine doesn't have perl on it.
What i need help with is:
- Am I going about this all wrong? Am I close?
- Am I missing anything obvious with the lit configs? Or not obvious?
- I don't have a non mono-repo anymore, I would appreciate it if someone could help me test the non mono-repo case.
why does it need lld? Shouldn't the system linker be good enough?