You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I built the MacOS version successfully
I built Substrate example successfully
When I added Substate dependencies to MacOS version I get the following error:
error[E0432]: unresolved import sp_core::to_substrate_wasm_fn_return_value
--> ~/.cargo/git/checkouts/substrate-7e08433d4c370a21/f38bd66/primitives/api/src/lib.rs:80:9
|
80 | pub use sp_core::to_substrate_wasm_fn_return_value;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ no to_substrate_wasm_fn_return_value in the root
if [[ -n "${DEVELOPER_SDK_DIR:-}" ]]; then
export LIBRARY_PATH="${DEVELOPER_SDK_DIR}/MacOSX.sdk/usr/lib:${LIBRARY_PATH:-}"
fi
TARGETS=""
if [[ "$PLATFORM_NAME" = "iphonesimulator" ]]; then
TARGETS="aarch64-apple-ios-sim,x86_64-apple-ios"
else
TARGETS="x86_64-apple-darwin,aarch64-apple-darwin"
fi
if [ $ENABLE_PREVIEWS == "NO" ]; then
if [[ $CONFIGURATION == "Release" ]]; then
echo "BUIlDING FOR RELEASE ($TARGETS)"
Closing as I can't understand what this issue is asking.
If you think that this issue is related to swift-bridge, please edit your issue body to clearly explain the problem that you are facing with swift-bridge.
I built the MacOS version successfully
I built Substrate example successfully
When I added Substate dependencies to MacOS version I get the following error:
error[E0432]: unresolved import
sp_core::to_substrate_wasm_fn_return_value
--> ~/.cargo/git/checkouts/substrate-7e08433d4c370a21/f38bd66/primitives/api/src/lib.rs:80:9
|
80 | pub use sp_core::to_substrate_wasm_fn_return_value;
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ no
to_substrate_wasm_fn_return_value
in the rootCan this be my .toml , etc.
#!/bin/bash
##################################################
We call this from an Xcode run script.
##################################################
set -e
if [[ -z "$PROJECT_DIR" ]]; then
echo "Must provide PROJECT_DIR environment variable set to the Xcode project directory." 1>&2
exit 1
fi
cd $PROJECT_DIR
export PATH="$HOME/.cargo/bin:$PATH"
Without this we can't compile on MacOS Big Sur
TimNN/cargo-lipo#41 (comment)
if [[ -n "${DEVELOPER_SDK_DIR:-}" ]]; then
export LIBRARY_PATH="${DEVELOPER_SDK_DIR}/MacOSX.sdk/usr/lib:${LIBRARY_PATH:-}"
fi
TARGETS=""
if [[ "$PLATFORM_NAME" = "iphonesimulator" ]]; then
TARGETS="aarch64-apple-ios-sim,x86_64-apple-ios"
else
TARGETS="x86_64-apple-darwin,aarch64-apple-darwin"
fi
if [ $ENABLE_PREVIEWS == "NO" ]; then
if [[ $CONFIGURATION == "Release" ]]; then
echo "BUIlDING FOR RELEASE ($TARGETS)"
else
echo "BUIlDING FOR DEBUG ($TARGETS)"
fi
else
echo "Skipping the script because of preview mode"
fi
[package]
name = "macos-rust-analyzer"
version = "0.1.0"
edition = "2021"
build = "build.rs"
[build-dependencies]
swift-bridge-build = "0.1"
[lib]
crate-type = ["staticlib"]
[dependencies]
swift-bridge = "0.1"
ide = {git = "https://github.com/rust-analyzer/rust-analyzer"}
petgraph = "0.6.3"
anyhow = "1.0.43"
frame-metadata = { version = "15.0.0", features = ["v13"] }
hex = "0.4.3"
parity-scale-codec = "3.0.0"
reqwest = { version = "0.11.4", features = ["json"] }
serde = "1"
serde_json = "1"
tokio = { version = "1.10.0", features = ["full"] }
jsonrpsee = { version = "0.12.0", features = ["async-client", "client-ws-transport"] }
Various types and functions useful for interacting with substrate exist in these sp (substrate-primitives) crates:
sp-core = { git = "https://github.com/paritytech/substrate", package = "sp-core", default-features = false, branch = "polkadot-v0.9.37" }
sp_runtime = { git = "https://github.com/paritytech/substrate", package = "sp-runtime", default-features = false, branch = "polkadot-v0.9.37" }
sp_keyring = { git = "https://github.com/paritytech/substrate.git", package = "sp-keyring", default-features = false, branch = "polkadot-v0.9.37" }
sp_version = { git = "https://github.com/paritytech/substrate.git", package = "sp-version", default-features = false, branch = "polkadot-v0.9.37" }
XCM utilized for the 06_storage_iter example.
xcm = { version = "0.9", git = "https://github.com/paritytech/polkadot.git", branch = "master", package = "xcm" }
There are some types we want in the pallet crates (if we liked, we could just redefine them to save bringing these in):
pallet_balances = { git = "https://github.com/paritytech/substrate.git", package = "pallet-balances", default-features = false, branch = "polkadot-v0.9.37" }
pallet_system = { git = "https://github.com/paritytech/substrate.git", package = "frame-system", default-features = false, branch = "polkadot-v0.9.37" }
[profile.dev]
panic = 'unwind'
[profile.release]
panic = 'unwind'
The text was updated successfully, but these errors were encountered: