Skip to content

Commit 82ae823

Browse files
committed
fix cross compilation path issue
1 parent 05fb0bf commit 82ae823

File tree

4 files changed

+8
-8
lines changed

4 files changed

+8
-8
lines changed

Cargo.toml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "lazy-static-include"
3-
version = "3.0.6"
3+
version = "3.0.7"
44
authors = ["Magic Len <len@magiclen.org>"]
55
edition = "2018"
66
repository = "https://github.com/magiclen/lazy-static-include"
@@ -14,7 +14,7 @@ include = ["src/**/*", "Cargo.toml", "README.md", "LICENSE", "benches/bench.rs"]
1414

1515
[dependencies]
1616
lazy_static = "1.4"
17-
slash-formatter = "3"
17+
slash-formatter = "3.1"
1818
syn = { version = "1", features = ["full"] }
1919

2020
[dev-dependencies]

src/macro_include_array.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -404,13 +404,13 @@ macro_rules! lazy_static_include_array {
404404
( @unit $(#[$attr: meta])* ($v:tt) $name:ident: [$(& $lt:lifetime)? $t:ident; $s:expr] => $path:expr ) => {
405405
$crate::lazy_static::lazy_static! {
406406
$(#[$attr])*
407-
static ref $name: [$(& $lt)? $t; $s] = include!($crate::slash_formatter::concat_with_file_separator!(env!("CARGO_MANIFEST_DIR"), $path));
407+
static ref $name: [$(& $lt)? $t; $s] = include!($crate::slash_formatter::concat_with_file_separator_debug_release!(env!("CARGO_MANIFEST_DIR"), $path));
408408
}
409409
};
410410
( @unit $(#[$attr: meta])* (pub$(($($v:tt)+))?) $name:ident: [$(& $lt:lifetime)? $t:ident; $s:expr] => $path:expr ) => {
411411
$crate::lazy_static::lazy_static! {
412412
$(#[$attr])*
413-
pub$(($($v)+))? static ref $name: [$(& $lt)? $t; $s] = include!($crate::slash_formatter::concat_with_file_separator!(env!("CARGO_MANIFEST_DIR"), $path));
413+
pub$(($($v)+))? static ref $name: [$(& $lt)? $t; $s] = include!($crate::slash_formatter::concat_with_file_separator_debug_release!(env!("CARGO_MANIFEST_DIR"), $path));
414414
}
415415
};
416416
( $($(#[$attr: meta])* $v:vis $name:ident: [$(& $lt:lifetime)? $t:ident; $s:expr] => $path:expr),* $(,)* ) => {

src/macro_include_bytes.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -126,15 +126,15 @@ macro_rules! lazy_static_include_bytes {
126126
( @unit $(#[$attr: meta])* ($v:tt) $name:ident => $path:expr ) => {
127127
$crate::lazy_static::lazy_static! {
128128
$(#[$attr])*
129-
static ref $name: &'static [u8] = include_bytes!($crate::slash_formatter::concat_with_file_separator!(env!("CARGO_MANIFEST_DIR"), $path));
129+
static ref $name: &'static [u8] = include_bytes!($crate::slash_formatter::concat_with_file_separator_debug_release!(env!("CARGO_MANIFEST_DIR"), $path));
130130
}
131131

132132
$crate::lazy_static_include_bytes!(@impl $name);
133133
};
134134
( @unit $(#[$attr: meta])* (pub$(($($v:tt)+))?) $name:ident => $path:expr ) => {
135135
$crate::lazy_static::lazy_static! {
136136
$(#[$attr])*
137-
pub$(($($v)+))? static ref $name: &'static [u8] = include_bytes!($crate::slash_formatter::concat_with_file_separator!(env!("CARGO_MANIFEST_DIR"), $path));
137+
pub$(($($v)+))? static ref $name: &'static [u8] = include_bytes!($crate::slash_formatter::concat_with_file_separator_debug_release!(env!("CARGO_MANIFEST_DIR"), $path));
138138
}
139139

140140
$crate::lazy_static_include_bytes!(@impl $name);

src/macro_include_str.rs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -164,15 +164,15 @@ macro_rules! lazy_static_include_str {
164164
( @unit $(#[$attr: meta])* ($v:tt) $name:ident => $path:expr ) => {
165165
$crate::lazy_static::lazy_static! {
166166
$(#[$attr])*
167-
static ref $name: &'static str = include_str!($crate::slash_formatter::concat_with_file_separator!(env!("CARGO_MANIFEST_DIR"), $path));
167+
static ref $name: &'static str = include_str!($crate::slash_formatter::concat_with_file_separator_debug_release!(env!("CARGO_MANIFEST_DIR"), $path));
168168
}
169169

170170
$crate::lazy_static_include_str!(@impl $name);
171171
};
172172
( @unit $(#[$attr: meta])* (pub$(($($v:tt)+))?) $name:ident => $path:expr ) => {
173173
$crate::lazy_static::lazy_static! {
174174
$(#[$attr])*
175-
pub$(($($v)+))? static ref $name: &'static str = include_str!($crate::slash_formatter::concat_with_file_separator!(env!("CARGO_MANIFEST_DIR"), $path));
175+
pub$(($($v)+))? static ref $name: &'static str = include_str!($crate::slash_formatter::concat_with_file_separator_debug_release!(env!("CARGO_MANIFEST_DIR"), $path));
176176
}
177177

178178
$crate::lazy_static_include_str!(@impl $name);

0 commit comments

Comments
 (0)