Skip to content

Linker error when compiling basic example on arm64 macOS (Apple Silicon) #129

Description

@fwcd

Running cargo run --example basic fails with

Compiling iui v0.3.0 (/Users/<USER>/git/libui-rs/iui)
error: linking with `cc` failed: exit status: 1
  |
  = note: "cc" "-arch" "arm64" "/var/folders/bp/fvm0x9c92xb3x02w8qsg21jh0000gn/T/rustcKwuGFH/symbols.o" "/Users/<USER>/git/libui-rs/target/debug/examples/basic-30c3e9d504c70d07.1eg50zitgxgbicbn.rcgu.o" "/Users/<USER>/git/libui-rs/target/debug/examples/basic-30c3e9d504c70d07.1hzmr3kmtdl4bpu6.rcgu.o" "/Users/<USER>/git/libui-rs/target/debug/examples/basic-30c3e9d504c70d07.1waonrue2ebuqotl.rcgu.o" "/Users/<USER>/git/libui-rs/target/debug/examples/basic-30c3e9d504c70d07.20ztt15mm307dcuu.rcgu.o" "/Users/<USER>/git/libui-rs/target/debug/examples/basic-30c3e9d504c70d07.28ai7bk0ozpb747k.rcgu.o" "/Users/<USER>/git/libui-rs/target/debug/examples/basic-30c3e9d504c70d07.2bwmwf0y9h1kvb7i.rcgu.o" "/Users/<USER>/git/libui-rs/target/debug/examples/basic-30c3e9d504c70d07.2jgg6gvqkej70ken.rcgu.o" "/Users/<USER>/git/libui-rs/target/debug/examples/basic-30c3e9d504c70d07.2m250s2nyall65sk.rcgu.o" "/Users/<USER>/git/libui-rs/target/debug/examples/basic-30c3e9d504c70d07.2rb0l2rzwr6qiymd.rcgu.o" "/Users/<USER>/git/libui-rs/target/debug/examples/basic-30c3e9d504c70d07.36o0ci94gohjhfu3.rcgu.o" "/Users/<USER>/git/libui-rs/target/debug/examples/basic-30c3e9d504c70d07.3f8kd3sucr20xwpv.rcgu.o" "/Users/<USER>/git/libui-rs/target/debug/examples/basic-30c3e9d504c70d07.3mzql2h5s6w62lms.rcgu.o" "/Users/<USER>/git/libui-rs/target/debug/examples/basic-30c3e9d504c70d07.4het468j4pimbdd0.rcgu.o" "/Users/<USER>/git/libui-rs/target/debug/examples/basic-30c3e9d504c70d07.4jfrlt2v0z6ewcf7.rcgu.o" "/Users/<USER>/git/libui-rs/target/debug/examples/basic-30c3e9d504c70d07.4juvumgh5opa9dbf.rcgu.o" "/Users/<USER>/git/libui-rs/target/debug/examples/basic-30c3e9d504c70d07.4kozp9viwoysmhvs.rcgu.o" "/Users/<USER>/git/libui-rs/target/debug/examples/basic-30c3e9d504c70d07.4moziqv3e6d97v9a.rcgu.o" "/Users/<USER>/git/libui-rs/target/debug/examples/basic-30c3e9d504c70d07.4tic7b0ypau0rz83.rcgu.o" "/Users/<USER>/git/libui-rs/target/debug/examples/basic-30c3e9d504c70d07.6498p94ltcsvyqy.rcgu.o" "/Users/<USER>/git/libui-rs/target/debug/examples/basic-30c3e9d504c70d07.r40mpuhpw4nyz8s.rcgu.o" "/Users/<USER>/git/libui-rs/target/debug/examples/basic-30c3e9d504c70d07.2yw09zevliiahdcj.rcgu.o" "-L" "/Users/<USER>/git/libui-rs/target/debug/deps" "-L" "/Users/<USER>/git/libui-rs/target/debug/build/ui-sys-ede8d110f88ed187/out" "-L" "/Users/<USER>/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib" "/Users/<USER>/git/libui-rs/target/debug/deps/libiui-c7a222012eaacb61.rlib" "/Users/<USER>/git/libui-rs/target/debug/deps/libui_sys-782b16aaf43ef527.rlib" "/Users/<USER>/git/libui-rs/target/debug/deps/libfailure-6174e4141902b113.rlib" "/Users/<USER>/git/libui-rs/target/debug/deps/libbacktrace-d3450263fd03ad97.rlib" "/Users/<USER>/git/libui-rs/target/debug/deps/libobject-bff620247865f019.rlib" "/Users/<USER>/git/libui-rs/target/debug/deps/libmemchr-6c9fbfeda127ffa9.rlib" "/Users/<USER>/git/libui-rs/target/debug/deps/liblibc-ef6cde88ceaed937.rlib" "/Users/<USER>/git/libui-rs/target/debug/deps/libaddr2line-6efda82b849ca163.rlib" "/Users/<USER>/git/libui-rs/target/debug/deps/libgimli-a73a1349c0cb74aa.rlib" "/Users/<USER>/git/libui-rs/target/debug/deps/libcfg_if-f043d77383bd547c.rlib" "/Users/<USER>/git/libui-rs/target/debug/deps/librustc_demangle-4adf5b50d94bbdd4.rlib" "/Users/<USER>/git/libui-rs/target/debug/deps/libbitflags-6db4b7a1a2354e6b.rlib" "/Users/<USER>/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libstd-8b48f6cefff7b1fb.rlib" "/Users/<USER>/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libpanic_unwind-77aeaad8f850e496.rlib" "/Users/<USER>/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libobject-4374cc9e76b48de5.rlib" "/Users/<USER>/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libmemchr-71ce82846aaede9b.rlib" "/Users/<USER>/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libaddr2line-88478a43231eec41.rlib" "/Users/<USER>/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libgimli-219a0c42f67a2534.rlib" "/Users/<USER>/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/librustc_demangle-967edde4cff44b15.rlib" "/Users/<USER>/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libstd_detect-5e9bad2c7ec1f53a.rlib" "/Users/<USER>/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libcfg_if-f2d3de7828f2e1f2.rlib" "/Users/<USER>/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libhashbrown-39feb0179b2f197f.rlib" "/Users/<USER>/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libminiz_oxide-fe7523d51d4e2154.rlib" "/Users/<USER>/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libadler-1fb439e2b08a54ae.rlib" "/Users/<USER>/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/librustc_std_workspace_alloc-0ece1873dc3050cd.rlib" "/Users/<USER>/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libunwind-1094a874bdfc7dbb.rlib" "/Users/<USER>/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libcfg_if-8cd76113b92d6775.rlib" "/Users/<USER>/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/liblibc-3a7cb21921429c0e.rlib" "/Users/<USER>/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/liballoc-5b42fb3902d391c7.rlib" "/Users/<USER>/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/librustc_std_workspace_core-b495777441600026.rlib" "/Users/<USER>/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libcore-cba95c4386a21469.rlib" "/Users/<USER>/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib/libcompiler_builtins-b8f163a13cf94b5d.rlib" "-framework" "AppKit" "-liconv" "-lSystem" "-lc" "-lm" "-L" "/Users/<USER>/.rustup/toolchains/stable-aarch64-apple-darwin/lib/rustlib/aarch64-apple-darwin/lib" "-o" "/Users/<USER>/git/libui-rs/target/debug/examples/basic-30c3e9d504c70d07" "-Wl,-dead_strip" "-nodefaultlibs"
  = note: Undefined symbols for architecture arm64:
            "_uiprivSendKeyboardEditEvents", referenced from:
                -[uiprivApplicationClass sendEvent:] in libui_sys-782b16aaf43ef527.rlib(main.o)
          ld: symbol(s) not found for architecture arm64
          clang: error: linker command failed with exit code 1 (use -v to see invocation)
          

error: could not compile `iui` due to previous error

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions