typst.ts icon indicating copy to clipboard operation
typst.ts copied to clipboard

Cannot build CLI on macOS

Open OverflowCat opened this issue 2 months ago • 3 comments

cargo install --locked --git https://github.com/Myriad-Dreamin/typst.ts typst-ts-cli
    Updating git repository `https://github.com/Myriad-Dreamin/typst.ts`
    Skipping git submodule `https://github.com/Myriad-Dreamin/typst.git` due to update strategy in .gitmodules
    Skipping git submodule `https://github.com/Myriad-Dreamin/cetz-editor.git` due to update strategy in .gitmodules
    Skipping git submodule `https://github.com/Myriad-Dreamin/typst-book.git` due to update strategy in .gitmodules
    Skipping git submodule `https://github.com/Enter-tainer/typst-preview.git` due to update strategy in .gitmodules
  Installing typst-ts-cli v0.5.0-rc3 (https://github.com/Myriad-Dreamin/typst.ts#e436a75e)
    Updating crates.io index
warning: Patch `typst-svg v0.11.0 (https://github.com/Myriad-Dreamin/typst.git?branch=typst.ts-v0.11.0-3-content-hint#3978d3b3)` was not used in the crate graph.
Check that the patched package version and available features are compatible
with the dependency requirements. If the patch has a different version from
what is locked in the Cargo.lock file, run `cargo update` to use the new
version. This may also occur with an optional dependency that is not enabled.
   Compiling proc-macro2 v1.0.78
   Compiling unicode-ident v1.0.12
   Compiling serde v1.0.197
   Compiling libc v0.2.153
   ...
   Compiling home v0.5.9
   Compiling rustyline v12.0.0
   Compiling clap_mangen v0.2.20
   Compiling env_logger v0.10.2
   Compiling typst-ts-ast-exporter v0.5.0-rc3 (/██████/.cargo/git/checkouts/typst.ts-bd03698c1f5efd74/e436a75/exporter/ast)
   Compiling typst-ts-compiler v0.5.0-rc3 (/██████/.cargo/git/checkouts/typst.ts-bd03698c1f5efd74/e436a75/compiler)
   Compiling human-panic v1.2.3
   Compiling clap_complete_fig v4.5.0
   Compiling typst-ts-serde-exporter v0.5.0-rc3 (/██████/.cargo/git/checkouts/typst.ts-bd03698c1f5efd74/e436a75/exporter/serde)
   Compiling tracing-error v0.2.0
   Compiling typst-ts-pdf-exporter v0.5.0-rc3 (/██████/.cargo/git/checkouts/typst.ts-bd03698c1f5efd74/e436a75/exporter/pdf)
   Compiling typst-ts-text-exporter v0.5.0-rc3 (/██████/.cargo/git/checkouts/typst.ts-bd03698c1f5efd74/e436a75/exporter/text)
   Compiling typst-ide v0.11.0 (https://github.com/Myriad-Dreamin/typst.git?branch=typst.ts-v0.11.0-3-content-hint#3978d3b3)
   Compiling git2 v0.18.2
   Compiling typst-ts-cli v0.5.0-rc3 (/██████/.cargo/git/checkouts/typst.ts-bd03698c1f5efd74/e436a75/cli)
error: linking with `cc` failed: exit status: 1
  |
  = note: env -u IPHONEOS_DEPLOYMENT_TARGET -u TVOS_DEPLOYMENT_TARGET LC_ALL="C" PATH="/██████/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/bin:/opt/local/bin:/opt/local/sbin:/opt/homebrew/bin:/opt/homebrew/sbin:/usr/local/bin:/System/Cryptexes/App/usr/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Library/TeX/texbin:/usr/local/share/dotnet:~/.dotnet/tools:/Library/Apple/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/local/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/bin:/var/run/com.apple.security.cryptexd/codex.system/bootstrap/usr/appleinternal/bin:/opt/local/bin:/opt/local/sbin:/opt/homebrew/bin:/opt/homebrew/sbin:/██████/Library/pnpm:/██████/.cargo/bin:/██████/.dotnet/tools:/██████/.dotnet/tools" VSLANG="1033" ZERO_AR_DATE="1" "cc" "-arch" "arm64" "/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/rustcdMtALa/symbols.o" "/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/build/typst-ts-cli-db1ac51d7cb7afc2/build_script_build-db1ac51d7cb7afc2.1alv9arc0fbiov9z.rcgu.o" "/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/build/typst-ts-cli-db1ac51d7cb7afc2/build_script_build-db1ac51d7cb7afc2.3c84vstlnldi72i4.rcgu.o" "/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/build/typst-ts-cli-db1ac51d7cb7afc2/build_script_build-db1ac51d7cb7afc2.3q7r2tfpvrdj059l.rcgu.o" "/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/build/typst-ts-cli-db1ac51d7cb7afc2/build_script_build-db1ac51d7cb7afc2.4rtu5t047o5n40w9.rcgu.o" "/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/build/typst-ts-cli-db1ac51d7cb7afc2/build_script_build-db1ac51d7cb7afc2.5fj339nsorrnwhpv.rcgu.o" "/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/build/typst-ts-cli-db1ac51d7cb7afc2/build_script_build-db1ac51d7cb7afc2.tcgujsfdx82r5lu.rcgu.o" "/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/build/typst-ts-cli-db1ac51d7cb7afc2/build_script_build-db1ac51d7cb7afc2.x16iz18g635yshy.rcgu.o" "/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/build/typst-ts-cli-db1ac51d7cb7afc2/build_script_build-db1ac51d7cb7afc2.unjr5aasfl8tgut.rcgu.o" "-L" "/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps" "-L" "/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/build/libgit2-sys-9a87911691503771/out/build" "-L" "/opt/local/lib" "-L" "/██████/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libvergen-38f6dbfa48fc20c3.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libgit2-878eff9ad92efc6f.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/liburl-b6fe490e537b03c6.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libidna-ece64fd2ffd9e709.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libunicode_normalization-b17162a99ae06260.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libtinyvec-3972837bd0e02c54.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libtinyvec_macros-0c96bc2b9dac742f.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libunicode_bidi-a8a464def1820ceb.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libform_urlencoded-8010f36cc6a04ae4.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libpercent_encoding-1f072fb765081a11.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/liblog-52f35ea9efc25dbd.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/liblibgit2_sys-be2d350848676e61.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/liblibz_sys-5e9e7dd737b401ce.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libbitflags-d0519b80e766cbcf.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/librustc_version-3043bebcd02df1ff.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libcfg_if-dd94c0b3171f5b06.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libregex-b46bfa72ef5c4942.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libregex_automata-8a964f66dc78f412.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libaho_corasick-ce5b1d9f00dd7fdc.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libmemchr-2c624c29a0fd53dd.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libregex_syntax-c8826260337b1e89.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libcargo_metadata-bfca38e28ed1df94.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libserde_json-0dc088e015141057.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libryu-c1d0f7f556e8ab5b.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libthiserror-fc5bc0f4342a5eda.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libcargo_platform-80c86374b9bf1748.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libsemver-43b63557c56accf2.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libcamino-12c8fdb6bf1db781.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libserde-1d331b65746dc27b.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libtime-c53dcdf7f08ba24b.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libnum_threads-9fa433d018a11078.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/liblibc-737d5f5d9c6d2e8c.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libitoa-af13a70987c517df.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libtime_core-9a87abbfbfcefd27.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libnum_conv-744f50a7aa6cb729.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libderanged-690b4d7abb27c9b2.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libpowerfmt-73cf1fe5230d8ff9.rlib" "/private/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/deps/libanyhow-b628e68d327d4c7f.rlib" "/██████/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libstd-b7bbc4a3799f91ec.rlib" "/██████/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libpanic_unwind-9a832f29e113f2ac.rlib" "/██████/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libobject-187acb73fb221979.rlib" "/██████/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libmemchr-f379d77720ea5d52.rlib" "/██████/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libaddr2line-5f995b6402184362.rlib" "/██████/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libgimli-6d4646231255d040.rlib" "/██████/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/librustc_demangle-ddf92ea3297b7931.rlib" "/██████/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libstd_detect-4bd9fc9ff7289783.rlib" "/██████/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libhashbrown-bbf01e0821f9af8a.rlib" "/██████/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/librustc_std_workspace_alloc-df3ad4119d36f143.rlib" "/██████/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libminiz_oxide-3839cef552c2783c.rlib" "/██████/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libadler-130a17e70576817a.rlib" "/██████/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libunwind-f7bc4dcd41ebfabc.rlib" "/██████/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libcfg_if-3b8c9f0215d4bce7.rlib" "/██████/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/liblibc-8e6430dafe1e0d1f.rlib" "/██████/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/liballoc-9d92a40a452d227c.rlib" "/██████/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/librustc_std_workspace_core-fb23eb00feddf1cb.rlib" "/██████/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libcore-c6577f5d4f5dcd9a.rlib" "/██████/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libcompiler_builtins-6d556b0e8bf6f23e.rlib" "-liconv" "-framework" "Security" "-framework" "CoreFoundation" "-lz" "-liconv" "-lSystem" "-lc" "-lm" "-L" "/██████/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib" "-o" "/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL/release/build/typst-ts-cli-db1ac51d7cb7afc2/build_script_build-db1ac51d7cb7afc2" "-Wl,-dead_strip" "-nodefaultlibs"
  = note: ld: warning: ignoring duplicate libraries: '-liconv'
          ld: Undefined symbols:
            _iconv, referenced from:
                _git_fs_path_iconv in liblibgit2_sys-be2d350848676e61.rlib[114](f0f7908ee800b4e1-fs_path.o)
            _iconv_close, referenced from:
                _git_fs_path_iconv_clear in liblibgit2_sys-be2d350848676e61.rlib[114](f0f7908ee800b4e1-fs_path.o)
            _iconv_open, referenced from:
                _git_fs_path_iconv_init_precompose in liblibgit2_sys-be2d350848676e61.rlib[114](f0f7908ee800b4e1-fs_path.o)
          clang: error: linker command failed with exit code 1 (use -v to see invocation)
          

error: could not compile `typst-ts-cli` (build script) due to 1 previous error
warning: build failed, waiting for other jobs to finish...
error: failed to compile `typst-ts-cli v0.5.0-rc3 (https://github.com/Myriad-Dreamin/typst.ts#e436a75e)`, intermediate artifacts can be found at `/var/folders/ll/yvc_thd911v6ltm1kby4jxk80000gn/T/cargo-install9EiUJL`.
To reuse those artifacts with a future compilation, set the environment variable `CARGO_TARGET_DIR` to that path.
  • macOS v13.6 (22G120)
  • Node.js v21.6.2

OverflowCat avatar Apr 13 '24 16:04 OverflowCat