File tree 8 files changed +388
-56
lines changed
json_validator_winrt_client_cpp 8 files changed +388
-56
lines changed Load Diff Large diffs are not rendered by default.
Load Diff This file was deleted.
Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ fn main() {
4
4
}
5
5
6
6
println ! ( "cargo:rerun-if-changed=src/client.cpp" ) ;
7
- println ! ( "cargo:rustc-link-lib=windows.0.52.0 " ) ;
7
+ println ! ( "cargo:rustc-link-lib=onecoreuap " ) ;
8
8
9
9
cc:: Build :: new ( )
10
10
. cpp ( true )
Original file line number Diff line number Diff line change @@ -4,7 +4,7 @@ fn main() {
4
4
}
5
5
6
6
println ! ( "cargo:rerun-if-changed=src/client.cpp" ) ;
7
- println ! ( "cargo:rustc-link-lib=windows.0.52.0 " ) ;
7
+ println ! ( "cargo:rustc-link-lib=onecoreuap " ) ;
8
8
9
9
let include = std:: env:: var ( "OUT_DIR" ) . unwrap ( ) ;
10
10
Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ fn main() {
4
4
}
5
5
6
6
println ! ( "cargo:rerun-if-changed=src/interop.cpp" ) ;
7
+ println ! ( "cargo:rustc-link-lib=onecoreuap" ) ;
7
8
8
9
windows_bindgen:: bindgen ( [
9
10
"--in" ,
Original file line number Diff line number Diff line change @@ -4,6 +4,7 @@ fn main() {
4
4
}
5
5
6
6
println ! ( "cargo:rerun-if-changed=src/interop.cpp" ) ;
7
+ println ! ( "cargo:rustc-link-lib=onecoreuap" ) ;
7
8
8
9
windows_bindgen:: bindgen ( [
9
10
"--in" ,
Original file line number Diff line number Diff line change @@ -7,7 +7,7 @@ fn main() {
7
7
let metadata_dir = format ! ( "{}\\ System32\\ WinMetadata" , env!( "windir" ) ) ;
8
8
let mut command = std:: process:: Command :: new ( "midlrt.exe" ) ;
9
9
println ! ( "cargo:rerun-if-changed=src/interop.cpp" ) ;
10
- println ! ( "cargo:rustc-link-lib=windows.0.52.0 " ) ;
10
+ println ! ( "cargo:rustc-link-lib=onecoreuap " ) ;
11
11
12
12
command. args ( [
13
13
"/winrt" ,
Original file line number Diff line number Diff line change 1
1
use std:: fmt:: Write ;
2
2
3
3
fn main ( ) {
4
- test_yml ( ) ;
4
+ test_yml ( "test" , false ) ;
5
+ test_yml ( "raw-dylib" , true ) ;
5
6
clippy_yml ( ) ;
6
7
no_default_features_yml ( ) ;
7
8
}
8
9
9
- fn test_yml ( ) {
10
- let mut yml = r"name: test
10
+ fn test_yml ( name : & str , raw_dylib : bool ) {
11
+ let mut yml = format ! (
12
+ r"name: {name}
11
13
12
14
on:
13
15
pull_request:
17
19
- 'web/**'
18
20
branches:
19
21
- master
22
+ "
23
+ ) ;
20
24
25
+ if raw_dylib {
26
+ write ! (
27
+ & mut yml,
28
+ r"
29
+ env:
30
+ RUSTFLAGS: --cfg windows_raw_dylib
31
+ "
32
+ )
33
+ . unwrap ( ) ;
34
+ }
35
+
36
+ write ! ( & mut yml, r"
21
37
jobs:
22
38
check:
23
39
runs-on: windows-2022
@@ -54,14 +70,14 @@ jobs:
54
70
- name: Checkout
55
71
uses: actions/checkout@v4
56
72
- name: Update toolchain
57
- run: rustup update --no-self-update ${{ matrix.version }} && rustup default ${{ matrix.version }}-${{ matrix.host }}
73
+ run: rustup update --no-self-update ${{{{ matrix.version }}}} && rustup default ${{{{ matrix.version }}}} -${{{{ matrix.host }} }}
58
74
- name: Add toolchain target
59
- run: rustup target add ${{ matrix.target }}
75
+ run: rustup target add ${{{{ matrix.target }} }}
60
76
- name: Install fmt
61
77
run: rustup component add rustfmt
62
78
- name: Fix environment
63
79
uses: ./.github/actions/fix-environment"
64
- . to_string ( ) ;
80
+ ) . unwrap ( ) ;
65
81
66
82
// This unrolling is required since "cargo test --all" consumes too much memory for the GitHub hosted runners
67
83
// and the occasional "cargo clean" is required to avoid running out of disk space in the same runners.
98
114
)
99
115
. unwrap ( ) ;
100
116
101
- std:: fs:: write ( ".github/workflows/test .yml" , yml. as_bytes ( ) ) . unwrap ( ) ;
117
+ std:: fs:: write ( format ! ( ".github/workflows/{name} .yml" ) , yml. as_bytes ( ) ) . unwrap ( ) ;
102
118
}
103
119
104
120
fn clippy_yml ( ) {
You can’t perform that action at this time.
0 commit comments