-
Notifications
You must be signed in to change notification settings - Fork 32
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
Over 100 MB of warnings emitted during bindgen build #47
Comments
Really? I haven’t noticed this. I have disabled a number of warnings, are you using this is some other way than the existing import done in the pg_sys module? |
Apparently But more curiously, the rustfmt issue only occurs on my macOS laptop. On Linux, the generated
Not knowing much about bindgen, my question is: why is it even generating stubs for functions that are in the C standard library, not PostgreSQL itself? Can that be avoided in the first place? |
I’m not actually sure about this. It might be possible to disable libc bindings being generated. The libc crate might be compatible with the bindgen types, but I haven’t done any investigation of this. |
What likely happens is that you don't have rustfmt installed, or it's not in you $PATH, but bindgen doesn't error out in that case. I had the same issue, fwiw, and filed both #1600 and rust-lang/rust#62999 |
Oh thanks a lot @glandium, that makes sense. This issue can be closed. |
For the record, link to bindgen issue too: rust-lang/rust-bindgen#1600 |
You can disable this warning by using: |
When building the
postgres.rs
file generated by bindgen, lots and lots of warnings are emitted like the following:This is annoying because line number 3 contains all the code in the generated bindings file, multiplying its size, which results in console output of 183 MB! This can also hide other more relevant warnings.
I couldn't figure out a way to suppress this warning. But I don't understand why all the generated code is on one line, given that bindgen is instructed to use rustfmt:
Do you have any idea why this is or should I contact bindgen upstream?
Any idea if there may be other solutions to this issue?
The text was updated successfully, but these errors were encountered: