Switch to a Cargo build script
Move the generated config.rs into $OUT_DIR
Update for latest rustc master