messense / mupdf-rs

Rust binding to mupdf
GNU Affero General Public License v3.0
104 stars 23 forks source link

build: use features to control build configuration #13

Closed NBonaparte closed 4 years ago

NBonaparte commented 4 years ago

Adds features to the mupdf-sys crate which map to some of the options in fitz/config.h. Of course, more or all of the options could be added as features if deemed necessary; I found these to be the most effective in reducing the size of the library.

NBonaparte commented 4 years ago

I've inverted the FZ_ENABLE_* features, so now they should work as intended. I also had to create another layer of dependencies within the outer crate (mupdf) to make the features usable when importing the crate externally.