Move extern crate into lib.rs instead of encoding.rs