File: build.rs

package info (click to toggle)
rust-stacker 0.1.15-2
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 160 kB
  • sloc: makefile: 12; ansic: 9
file content (13 lines) | stat: -rw-r--r-- 316 bytes parent folder | download | duplicates (16)
1
2
3
4
5
6
7
8
9
10
11
12
13
use std::env;

fn main() {
    let target = env::var("TARGET").unwrap();
    let mut cfg = cc::Build::new();
    if target.contains("windows") {
        cfg.define("WINDOWS", None);
        cfg.file("src/arch/windows.c");
        cfg.include("src/arch").compile("libstacker.a");
    } else {
        return;
    }
}