Skip to content

Conversation

@tiennou
Copy link
Contributor

@tiennou tiennou commented Feb 23, 2019

This updates how we interface with clang so we get better reporting, limited to one error (which is usually a bad sign), the possibility to pass custom compile flags (I need to point clang 7.0 to my SDKs headers), as well as some slight filesystem optimizations.

@tiennou tiennou force-pushed the fix/parser-cleanups branch from 2107eea to e6be4be Compare March 2, 2019 11:11
@tiennou tiennou force-pushed the fix/parser-cleanups branch 3 times, most recently from fe3583b to c68bfbb Compare June 16, 2019 13:30
@tiennou
Copy link
Contributor Author

tiennou commented Jun 16, 2019

Rebased. I've added a comment to describe how the test helper is used. I'm planning to work on "fixing" the parallel processing, and implement "--only-missing" on top of that.

(BTW, I have rebased your cmn/docker branch, and extended it to build the actual gem, instead of using the rubygem version).

@carlosmn
Copy link
Member

This keeps spewing /usr/include/time.h:29:10: fatal error: 'stddef.h' file not found. What's that about? That seems bad, although the tests do end up passing.

@tiennou
Copy link
Contributor Author

tiennou commented Jun 17, 2019

My hunch is that the ffi/clang default configuration isn't actually platform-specific ? I have no idea, but macOS gives me the same error about time.h, thus I've added DOCURIUM_CFLAGS and have to -isysroot stuff, and it only started about a year ago ?

This was referenced Jun 18, 2019
@carlosmn
Copy link
Member

carlosmn commented Aug 1, 2019

https://stackoverflow.com/questions/20587228/clang-error-stddef-file-not-found suggests installing the clang compiler solves the issue.

@carlosmn
Copy link
Member

carlosmn commented Aug 1, 2019

That did not solve it.. I wonder if this is actually just about reporting and we've never really been able to find stddef.h and this is why we've had issues with size_t.

@tiennou
Copy link
Contributor Author

tiennou commented Aug 1, 2019

It is, actually, and the #ifdef DOCURIUM workarounds can be removed after those fixes. IIRC I uncovered that after adding the logging and fixing the problem with not having the correct "include root" (a.k.a. the missing sys header problems). I don't really understand why it matters, but it seems that ffi/clang also needs weird things done on the environment on Darwin, and I couldn't find a way to use that to fix it, so I went with DOCURIUM_CFLAGS

tiennou added 2 commits August 8, 2019 14:21
Any error when parsing will result in a confused clang parser with missing data
@tiennou tiennou force-pushed the fix/parser-cleanups branch from 2a44766 to 3d5f630 Compare August 8, 2019 12:30
@tiennou
Copy link
Contributor Author

tiennou commented Aug 8, 2019

Rebased, I've removed DOCURIUM_CFLAGS since the platform detection works transparently now. I have green runs from all "extracted" PRs (though one failed CI), but #26 still has a bit too much changes going on (though it usually fails because of the switch to "in-memory" parsing at the beginning of the patchset).

@carlosmn carlosmn merged commit a6f8fef into libgit2:master Dec 19, 2019
@tiennou tiennou deleted the fix/parser-cleanups branch April 6, 2020 13:06
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants