Giter Site home page Giter Site logo

rust-ffi-boilerplate's People

Contributors

zsmatrix62 avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

rust-ffi-boilerplate's Issues

根据你的模版教程出现以下错误

系统版本

  • mac sonoma 14.3.1

xcode版本

  • xcode 15.2

软件版本

  • rustup 1.26.0 (5af9b9484 2023-04-05)
  • uniffi-bindgen 0.25.3
  • Apple Swift version 5.9.2 (swiftlang-5.9.2.2.56 clang-1500.1.0.2.5)

错误提示

Showing Recent Errors Only
Ld /Users/vv/Library/Developer/Xcode/DerivedData/WhyNotTry-esffdomtkfhylzduvibnowbmbewd/Build/Products/Debug-iphonesimulator/WhyNotTry.app/WhyNotTry normal (in target 'WhyNotTry' from project 'WhyNotTry')
    cd /Users/vv/proj/swift/WhyNotTry
    /Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/clang -Xlinker -reproducible -target x86_64-apple-ios17.2-simulator -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneSimulator.platform/Developer/SDKs/iPhoneSimulator17.2.sdk -O0 -L/Users/vv/Library/Developer/Xcode/DerivedData/WhyNotTry-esffdomtkfhylzduvibnowbmbewd/Build/Intermediates.noindex/EagerLinkingTBDs/Debug-iphonesimulator -L/Users/vv/Library/Developer/Xcode/DerivedData/WhyNotTry-esffdomtkfhylzduvibnowbmbewd/Build/Products/Debug-iphonesimulator -F/Users/vv/Library/Developer/Xcode/DerivedData/WhyNotTry-esffdomtkfhylzduvibnowbmbewd/Build/Intermediates.noindex/EagerLinkingTBDs/Debug-iphonesimulator -F/Users/vv/Library/Developer/Xcode/DerivedData/WhyNotTry-esffdomtkfhylzduvibnowbmbewd/Build/Products/Debug-iphonesimulator/PackageFrameworks -F/Users/vv/Library/Developer/Xcode/DerivedData/WhyNotTry-esffdomtkfhylzduvibnowbmbewd/Build/Products/Debug-iphonesimulator -filelist /Users/vv/Library/Developer/Xcode/DerivedData/WhyNotTry-esffdomtkfhylzduvibnowbmbewd/Build/Intermediates.noindex/WhyNotTry.build/Debug-iphonesimulator/WhyNotTry.build/Objects-normal/x86_64/WhyNotTry.LinkFileList -Xlinker -rpath -Xlinker /Users/vv/Library/Developer/Xcode/DerivedData/WhyNotTry-esffdomtkfhylzduvibnowbmbewd/Build/Products/Debug-iphonesimulator/PackageFrameworks -Xlinker -rpath -Xlinker @executable_path/Frameworks -dead_strip -Xlinker -object_path_lto -Xlinker /Users/vv/Library/Developer/Xcode/DerivedData/WhyNotTry-esffdomtkfhylzduvibnowbmbewd/Build/Intermediates.noindex/WhyNotTry.build/Debug-iphonesimulator/WhyNotTry.build/Objects-normal/x86_64/WhyNotTry_lto.o -Xlinker -export_dynamic -Xlinker -no_deduplicate -Xlinker -objc_abi_version -Xlinker 2 -fobjc-link-runtime -L/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/iphonesimulator -L/usr/lib/swift -Xlinker -add_ast_path -Xlinker /Users/vv/Library/Developer/Xcode/DerivedData/WhyNotTry-esffdomtkfhylzduvibnowbmbewd/Build/Intermediates.noindex/WhyNotTry.build/Debug-iphonesimulator/WhyNotTry.build/Objects-normal/x86_64/WhyNotTry.swiftmodule -Wl,-no_warn_duplicate_libraries -Xlinker -sectcreate -Xlinker __TEXT -Xlinker __entitlements -Xlinker /Users/vv/Library/Developer/Xcode/DerivedData/WhyNotTry-esffdomtkfhylzduvibnowbmbewd/Build/Intermediates.noindex/WhyNotTry.build/Debug-iphonesimulator/WhyNotTry.build/WhyNotTry.app-Simulated.xcent -Xlinker -sectcreate -Xlinker __TEXT -Xlinker __ents_der -Xlinker /Users/vv/Library/Developer/Xcode/DerivedData/WhyNotTry-esffdomtkfhylzduvibnowbmbewd/Build/Intermediates.noindex/WhyNotTry.build/Debug-iphonesimulator/WhyNotTry.build/WhyNotTry.app-Simulated.xcent.der -framework MyPkgFFI -framework MyPkgFFI -Xlinker -no_adhoc_codesign -Xlinker -dependency_info -Xlinker /Users/vv/Library/Developer/Xcode/DerivedData/WhyNotTry-esffdomtkfhylzduvibnowbmbewd/Build/Intermediates.noindex/WhyNotTry.build/Debug-iphonesimulator/WhyNotTry.build/Objects-normal/x86_64/WhyNotTry_dependency_info.dat -o /Users/vv/Library/Developer/Xcode/DerivedData/WhyNotTry-esffdomtkfhylzduvibnowbmbewd/Build/Products/Debug-iphonesimulator/WhyNotTry.app/WhyNotTry -Xlinker -add_ast_path -Xlinker /Users/vv/Library/Developer/Xcode/DerivedData/WhyNotTry-esffdomtkfhylzduvibnowbmbewd/Build/Intermediates.noindex/MyPkg.build/Debug-iphonesimulator/MyPkg.build/Objects-normal/x86_64/MyPkg.swiftmodule

ld: Undefined symbols:
  _ffi_rust_ffi_rustbuffer_free, referenced from:
      closure #1 (Swift.UnsafeMutablePointer<__C.RustCallStatus>) -> () in (extension in MyPkg):__C.RustBuffer.(deallocate in _62A0FF1B6F7E9159EC59F512CEA897E1)() -> () in MyPkg.o
  _ffi_rust_ffi_rustbuffer_from_bytes, referenced from:
      closure #1 (Swift.UnsafeMutablePointer<__C.RustCallStatus>) -> __C.RustBuffer in static (extension in MyPkg):__C.RustBuffer.(from in _62A0FF1B6F7E9159EC59F512CEA897E1)(Swift.UnsafeBufferPointer<Swift.UInt8>) -> __C.RustBuffer in MyPkg.o
  _ffi_rust_ffi_uniffi_contract_version, referenced from:
      MyPkg.(initializationResult in _62A0FF1B6F7E9159EC59F512CEA897E1).getter : MyPkg.(InitializationResult in _62A0FF1B6F7E9159EC59F512CEA897E1) in MyPkg.o
  _uniffi_rust_ffi_checksum_func_hello, referenced from:
      MyPkg.(initializationResult in _62A0FF1B6F7E9159EC59F512CEA897E1).getter : MyPkg.(InitializationResult in _62A0FF1B6F7E9159EC59F512CEA897E1) in MyPkg.o
  _uniffi_rust_ffi_fn_func_hello, referenced from:
      closure #1 (Swift.UnsafeMutablePointer<__C.RustCallStatus>) -> __C.RustBuffer in MyPkg.hello(search: Swift.String) -> Swift.String in MyPkg.o
clang: error: linker command failed with exit code 1 (use -v to see invocation)

Undefined symbols:

Linker command failed with exit code 1 (use -v to see invocation)

请问如何解决,谢谢!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.