Skip to content

Commit

Permalink
varlink-cli: build to OUT_DIR
Browse files Browse the repository at this point in the history
With Rust 1.28.0:

Cargo will now no longer allow you to publish crates with build scripts
that modify the src directory.
The src directory in a crate should be considered to be immutable.

rust-lang/cargo#5584
  • Loading branch information
haraldh committed Aug 3, 2018
1 parent f942a5a commit 26d5428
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 1 deletion.
2 changes: 1 addition & 1 deletion varlink-cli/build.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
extern crate varlink;

fn main() {
varlink::generator::cargo_build_tosource("src/org.varlink.resolver.varlink", false);
varlink::generator::cargo_build("src/org.varlink.resolver.varlink");
}
5 changes: 5 additions & 0 deletions varlink-cli/src/org_varlink_resolver.rs
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
#![allow(dead_code)]
#![allow(non_camel_case_types)]
#![allow(non_snake_case)]

include!(concat!(env!("OUT_DIR"), "/org.varlink.resolver.rs"));

0 comments on commit 26d5428

Please sign in to comment.