-
Notifications
You must be signed in to change notification settings - Fork 182
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
20fa268
commit 0eecb14
Showing
9 changed files
with
323 additions
and
330 deletions.
There are no files selected for viewing
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,31 @@ | ||
// This file is part of ICU4X. For terms of use, please see the file | ||
// called LICENSE at the top level of the ICU4X source tree | ||
// (online at: https://github.com/unicode-org/icu4x/blob/main/LICENSE ). | ||
|
||
use icu_datagen::*; | ||
use std::path::PathBuf; | ||
|
||
fn main() { | ||
if std::env::var("CARGO_FEATURE_BAKED_PROVIDER").is_ok() | ||
&& std::env::var("ICU4X_FFI_BAKED_ROOT").is_err() | ||
{ | ||
let mod_directory = PathBuf::from(std::env::var_os("OUT_DIR").unwrap()).join("empty_bake"); | ||
println!("cargo:rustc-env=ICU4X_FFI_BAKED_ROOT={}", mod_directory.display()); | ||
|
||
if !mod_directory.exists() { | ||
icu_datagen::datagen( | ||
Some(&[]), | ||
&[], | ||
&SourceData::default(), | ||
vec![Out::Module { | ||
mod_directory, | ||
insert_feature_gates: false, | ||
use_separate_crates: true, | ||
overwrite: false, | ||
pretty: false, | ||
}], | ||
) | ||
.unwrap(); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.