lopdf 0.30.0 fails to build with default_features = false
tyilo opened this issue · comments
Asger Hautop Drewsen commented
Steps to reproduce:
$ cargo new lopdf-test
$ cd lopdf-test
$ cargo add lopdf@=0.30.0 --no-default-features
$ cargo build
Compiling cfg-if v1.0.0
Compiling crc32fast v1.3.2
Compiling log v0.4.17
Compiling adler v1.0.2
Compiling time-core v0.1.0
Compiling itoa v1.0.6
Compiling weezl v0.1.7
Compiling linked-hash-map v0.5.6
Compiling encoding_rs v0.8.32
Compiling miniz_oxide v0.6.2
Compiling time v0.3.20
Compiling flate2 v1.0.25
Compiling lopdf v0.30.0
error[E0432]: unresolved import `object_stream`
--> /home/tyilo/.cargo/registry/src/github.com-1ecc6299db9ec823/lopdf-0.30.0/src/lib.rs:13:9
|
13 | pub use object_stream::ObjectStream;
| ^^^^^^^^^^^^^ use of undeclared crate or module `object_stream`
error[E0432]: unresolved import `reader`
--> /home/tyilo/.cargo/registry/src/github.com-1ecc6299db9ec823/lopdf-0.30.0/src/lib.rs:41:9
|
41 | pub use reader::Reader;
| ^^^^^^ use of undeclared crate or module `reader`
For more information about this error, try `rustc --explain E0432`.
error: could not compile `lopdf` due to 2 previous errors
warning: build failed, waiting for other jobs to finish...
Arif Driessen commented
Thanks for the simple reproducible steps, while i'm sure a patch is trivial to implement, in the meantime,
cargo add lopdf@=0.30.0 --no-default-features --features nom_parser
will build, and will make lopdf much faster anyway.
Asger Hautop Drewsen commented
I'm only using lopdf
to create PDF's not parse existing ones. So I don't really care how slow parsing is :)