-
Notifications
You must be signed in to change notification settings - Fork 163
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Unrecognised COFF object format when using cl.exe /GL #194
Comments
So iiuc we just need to add the magic number to our magic numbers ? Or is something else involved ? |
No, this is the equivalent of clang's |
Given no other tool supports this format, it is reasonable that goblin doesnt either. fwiw, I tried parsing the stream starting at offset 6, which is where the COFF signature starts, and it did seem to get a little way through it, with error |
@jayvdb sure if you want to submit a PR making error messaging better or somehow returning more info feel free! If no I’m going to close this issue though since I don’t think there is much else we can do. Let me know ! |
I think making error messaging better is something I can do, so I would like to try it. |
I would be surprised if the /GL .obj files were alike regular COFF files at all, since according to this Raymond Chen blog post :
|
A bit of the history at gimli-rs/object#154 and motivation at indygreg/PyOxidizer#183
The default Python extension C flags on Windows with
cl.exe
includes/GL
(Whole Program Optimization). The docs sayWhen that is used, the .obj format is very strange. Omit the option, and the usual .obj format is used and
goblin
andobject
process it wonderfully.As I can hack the code involved, omitting that flag is possible, so this doesnt block us, but it would be nice to have the optimisations, and have one less hack. Anyways, I can proceed, so thanks very much for a workable library.
The text was updated successfully, but these errors were encountered: