So, I've written a tool called "obj2yaml". It takes an object file (currently just COFF), and dumps out a textual representation.
Micheal Spencer has written a companion tool (not yet landed) called "yaml2obj".
The primary use for these tools is for generating test cases for lld, though they are general purpose tools, and can be used to generate test cases (or debug) other parts of llvm.
I put obj2yaml into the "utils" directory, and (I thought) all was well.
However, this morning, I noticed that it was not getting built in the configure+make build, just the cmake build.
So, I checked in revision r159014, which added a reference to obj2yaml in the Makefile for /utils. Tested it, and all was well (I thought).
I was wrong. Lots of buildbots failed, all saying (more or less):
make: *** No rule to make target `/Volumes/Macintosh_HD2/buildbots/clang-x86_64-darwin11-self-mingw32/llvm.obj/BuildTools/Debug+Asserts/lib/libLLVMObject.a', needed by `/Volumes/Macintosh_HD2/buildbots/clang-x86_64-darwin11-self-mingw32/llvm.obj/BuildTools/Debug+Asserts/bin/obj2yaml'. Stop.
I asked in the chat room:
marshall:So - what do I link with to get llvm::object::COFFObjectFile ?
d0k:libobject, but I don't think that's accessible from utils/
And I have no reason to doubt him.
grosbach:marshall: perhaps the tool should be in 'tools' not 'utils'?
That sounds reasonable, but it appears to me that all the bits from 'tools' get installed on end-users systems, and I don't think that obj2yaml really deserves that.
So - my question is:
Where should this tool live?
Marshall Clow Idio Software <mailto:firstname.lastname@example.org>
A.D. 1517: Martin Luther nails his 95 Theses to the church door and is promptly moderated down to (-1, Flamebait).
-- Yu Suzuki