Skip to content

Commit

Permalink
Moving no-publish tool crates into /tools (#3036)
Browse files Browse the repository at this point in the history
  • Loading branch information
robertbastian authored Jan 30, 2023
1 parent ec659c3 commit ed91bab
Show file tree
Hide file tree
Showing 47 changed files with 70 additions and 818 deletions.
2 changes: 1 addition & 1 deletion .cargo/config.toml
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ wasm-build-release = "panic-abort-build --target wasm32-unknown-unknown --profil
rustflags = [
# 100 KiB, working around a bug in older rustc
# https://github.com/unicode-org/icu4x/issues/2753
# keep in sync with wasm's build.sh
# keep in sync with wasm's and tinywasm's build.sh
"-C", "link-args=-z stack-size=100000",
"-C", "panic=abort",
"-C", "opt-level=s"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/build-test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -449,7 +449,7 @@ jobs:
with:
path: |
ffi/gn/third_party_tools
key: ${{ runner.os }}-${{ hashFiles('tools/scripts/gn.toml') }}
key: ${{ runner.os }}-${{ hashFiles('tools/make/gn.toml') }}
- name: Install GN Third-Party Tools
if: steps.gn-third-party-tools-cache.outputs.cache-hit != 'true'
uses: actions-rs/[email protected]
Expand Down
2 changes: 1 addition & 1 deletion CODEOWNERS
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ provider/testdata/ @unicode-org/icu4x-owners
tools/benchmark/binsize/ @gnrunge
tools/benchmark/macros/ @gregtatum
tools/benchmark/memory/ @gregtatum
tools/scripts/ @Manishearth @sffc
tools/make/ @Manishearth @sffc
utils/fixed_decimal/ @sffc
utils/litemap/ @Manishearth @sffc
utils/pattern/ @zbraniecki
Expand Down
44 changes: 22 additions & 22 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 6 additions & 8 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -25,14 +25,10 @@ members = [
"experimental/displaynames",
"experimental/ixdtf",
"experimental/relativetime",
"experimental/tutorials",
"utils/databake",
"utils/databake/derive",
"experimental/segmenter",
"ffi/capi_cdylib",
"ffi/capi_staticlib",
"ffi/diplomat",
"ffi/diplomat/ffi_coverage",
"ffi/freertos",
"provider/adapters",
"provider/blob",
Expand All @@ -41,10 +37,14 @@ members = [
"provider/fs",
"provider/macros",
"provider/testdata",
"provider/testdata/scripts",
"tools/benchmark/binsize",
"tools/benchmark/macros",
"tools/benchmark/memory",
"tools/benchmark/binsize",
"tools/ffi_coverage",
"tools/testdata-scripts",
"tools/tutorials-test",
"utils/databake",
"utils/databake/derive",
"utils/deduplicating_array",
"utils/fixed_decimal",
"utils/litemap",
Expand All @@ -65,8 +65,6 @@ exclude = [
"ffi/ecma402",
# GNaw needs to be run from outside the workspace for features to work
"ffi/gn",
# Special linker flags shouldn't overwrite the top-level target directory
"ffi/tinywasm",
]

# LTO is needed for WASM and other size-optimized builds,
Expand Down
14 changes: 7 additions & 7 deletions Makefile.toml
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,13 @@
# (online at: https://github.com/unicode-org/icu4x/blob/main/LICENSE ).

extend = [
{ path = "./tools/scripts/data.toml"}, #
{ path = "./tools/scripts/valgrind.toml"}, #
{ path = "./tools/scripts/tidy.toml"}, #
{ path = "./tools/scripts/wasm.toml"}, #
{ path = "./tools/scripts/tests.toml"}, #
{ path = "./tools/scripts/ffi.toml"}, #
{ path = "./tools/scripts/gn.toml"}, #
{ path = "./tools/make/data.toml"}, #
{ path = "./tools/make/valgrind.toml"}, #
{ path = "./tools/make/tidy.toml"}, #
{ path = "./tools/make/wasm.toml"}, #
{ path = "./tools/make/tests.toml"}, #
{ path = "./tools/make/ffi.toml"}, #
{ path = "./tools/make/gn.toml"}, #
]

[config]
Expand Down
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes
7 changes: 0 additions & 7 deletions experimental/tutorials/README.md

This file was deleted.

2 changes: 1 addition & 1 deletion ffi/diplomat/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -94,7 +94,7 @@ icu_testdata = { version = "1.1.0", path = "../../provider/testdata", optional =
# Run `cargo make diplomat-install` to get the right diplomat binary installed
# The version here can either be a `version = ".."` spec or `git = "https://github.com/rust-diplomat/diplomat", rev = ".."`
# Since this crate is published, Diplomat must be published preceding a new ICU4X release but may use git versions in between
# ALSO MAKE SURE TO UPDATE ffi_coverage/Cargo.toml!
# ALSO MAKE SURE TO UPDATE /tools/ffi_coverage/Cargo.toml!
diplomat = "0.5"
diplomat-runtime = "0.5"

Expand Down
7 changes: 0 additions & 7 deletions ffi/diplomat/ffi_coverage/README.md

This file was deleted.

File renamed without changes.
1 change: 1 addition & 0 deletions ffi/diplomat/js/examples/tinywasm/README.md

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -21,18 +21,21 @@ BASEDIR=$(dirname "$(realpath "$0")")

# Build the WASM library
# TODO: This likely doesn't work if $BASEDIR has spaces
RUSTFLAGS="-Cpanic=abort -Copt-level=s -C link-arg=-zstack-size=${WASM_STACK_SIZE} -Clinker-plugin-lto -Ccodegen-units=1 -C linker=${BASEDIR}/ld.py -C linker-flavor=wasm-ld" cargo +${ICU4X_NIGHTLY_TOOLCHAIN} build \
RUSTFLAGS="-Cpanic=abort -Copt-level=s -C link-arg=-zstack-size=${WASM_STACK_SIZE} -Clinker-plugin-lto -Ccodegen-units=1 -C linker=${BASEDIR}/ld.py -C linker-flavor=wasm-ld" \
CARGO_TARGET_DIR="target" `# Special linker flags shouldn't overwrite the top-level target directory` \
cargo +${ICU4X_NIGHTLY_TOOLCHAIN} build \
-Z build-std=std,panic_abort -Z build-std-features=panic_immediate_abort \
--target wasm32-unknown-unknown \
--release \
--package icu_capi_tinywasm
--package icu_capi_cdylib \
--features buffer_provider,logging \

cp target/wasm32-unknown-unknown/release/icu_capi_tinywasm.wasm icu_capi.wasm
cp target/wasm32-unknown-unknown/release/icu_capi_cdylib.wasm icu_capi.wasm

# Don't regen the postcard data by default; delete the file to regen
if ! test -f "icu4x_data.postcard"; then
# Regen all data
cargo run --manifest-path ../../provider/datagen/Cargo.toml -- \
cargo run -p icu_datagen -- \
--keys-for-bin icu_capi.wasm \
--locales full \
--format blob \
Expand All @@ -42,4 +45,4 @@ fi
# Refresh the lib folder
rm -rf lib
mkdir -p lib
cp ../diplomat/js/include/* lib
cp ../../include/* lib
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
File renamed without changes.
Loading

0 comments on commit ed91bab

Please sign in to comment.