-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbuild.rs
35 lines (34 loc) · 1.16 KB
/
build.rs
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
use chrono::{Datelike, Local};
use std::env;
extern crate winres;
fn main() {
let now = Local::now();
let copyright = format!("Copyright © {} Smart Code OOD", now.year());
let exe_name = format!("{}.exe", env::var("CARGO_PKG_NAME").unwrap());
let mut res = winres::WindowsResource::new();
res.set_manifest(
r#"
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
<assembly xmlns="urn:schemas-microsoft-com:asm.v1" manifestVersion="1.0">
<dependency>
<dependentAssembly>
<assemblyIdentity
type="win32"
name="Microsoft.Windows.Common-Controls"
version="6.0.0.0"
processorArchitecture="*"
publicKeyToken="6595b64144ccf1df"
language="*"
/>
</dependentAssembly>
</dependency>
</assembly>
"#,
);
res.set("FileDescription", "Freedom to Stream");
res.set("LegalCopyright", ©right);
res.set("OriginalFilename", &exe_name);
res.set_icon_with_id("images/stremio.ico", "MAINICON");
res.append_rc_content(r##"SPLASHIMAGE IMAGE "images/stremio.png""##);
res.compile().unwrap();
}