【问题标题】:Linker failed in D compiler (dmd)D 编译器 (dmd) 中的链接器失败
【发布时间】:2021-01-18 05:04:55
【问题描述】:

我不知道如何解决这个错误,请帮我解决这个问题。

  RDMD   volt
lib/src/volta/parser/base.d(470): Deprecation: opSub is deprecated.  Use opBinary(string op)(...) if (op == "-") instead.
lib/src/volta/ir/location.d(130): Deprecation: opSub is deprecated.  Use opBinary(string op)(...) if (op == "-") instead.
lib/src/volta/parser/toplevel.d(680): Deprecation: opSub is deprecated.  Use opBinary(string op)(...) if (op == "-") instead.
lib/src/volta/parser/templates.d(236): Deprecation: opSub is deprecated.  Use opBinary(string op)(...) if (op == "-") instead.
lib/src/volta/parser/templates.d(350): Deprecation: opSub is deprecated.  Use opBinary(string op)(...) if (op == "-") instead.
lib/src/volta/parser/expression.d(1048): Deprecation: opSub is deprecated.  Use opBinary(string op)(...) if (op == "-") instead.
lib/src/volta/parser/expression.d(1076): Deprecation: opSub is deprecated.  Use opBinary(string op)(...) if (op == "-") instead.
lib/src/volta/parser/expression.d(1261): Deprecation: opSub is deprecated.  Use opBinary(string op)(...) if (op == "-") instead.
lib/src/volta/parser/expression.d(1404): Deprecation: opSub is deprecated.  Use opBinary(string op)(...) if (op == "-") instead.
lib/src/volta/parser/expression.d(1427): Deprecation: opSub is deprecated.  Use opBinary(string op)(...) if (op == "-") instead.
lib/src/volta/parser/expression.d(1935): Deprecation: opSub is deprecated.  Use opBinary(string op)(...) if (op == "-") instead.
lib/src/volta/parser/declaration.d(421): Deprecation: opSub is deprecated.  Use opBinary(string op)(...) if (op == "-") instead.
lib/src/volta/parser/declaration.d(435): Deprecation: opSub is deprecated.  Use opBinary(string op)(...) if (op == "-") instead.
lib/src/volta/parser/declaration.d(446): Deprecation: opSub is deprecated.  Use opBinary(string op)(...) if (op == "-") instead.
lib/src/volta/parser/declaration.d(871): Deprecation: opSub is deprecated.  Use opBinary(string op)(...) if (op == "-") instead.
lib/src/volta/parser/declaration.d(908): Deprecation: opSub is deprecated.  Use opBinary(string op)(...) if (op == "-") instead.
lib/src/volta/parser/declaration.d(918): Deprecation: opSub is deprecated.  Use opBinary(string op)(...) if (op == "-") instead.
lib/src/volta/parser/declaration.d(940): Deprecation: opSub is deprecated.  Use opBinary(string op)(...) if (op == "-") instead.
lib/src/volta/parser/declaration.d(954): Deprecation: opSub is deprecated.  Use opBinary(string op)(...) if (op == "-") instead.
lib/src/volta/parser/declaration.d(1277): Deprecation: opSub is deprecated.  Use opBinary(string op)(...) if (op == "-") instead.
dsupport/src/watt/text/sink.d(57): Deprecation: returning &this.sink escapes a reference to parameter this, perhaps annotate with return
ld: unknown option: -Wl,-search_paths_first
clang: error: linker command failed with exit code 1 (use -v to see invocation)
Error: linker exited with status 1
make: *** [GNUmakefile:150: volt] Error 1
  • 操作系统: macOS

  • DMD 安装: brew install dmd

  • Clang 字符串:

clang version 10.0.1 
Target: x86_64-apple-darwin17.7.0
Thread model: posix
InstalledDir: /usr/local/opt/llvm/bin
  • 链接器字符串:
@(#)PROGRAM:ld  PROJECT:ld64-253.9
configured to support archs: armv6 armv7 armv7s arm64 i386 x86_64 x86_64h armv6m armv7k armv7m armv7em (tvOS)
LTO support using: Apple LLVM 7.0.2 (clang-700.1.81)

【问题讨论】:

    标签: linker-errors d ld dmd linker-flags


    【解决方案1】:

    你为什么使用 LD64 ?在 OSX 上还是有很多 bug,你应该改用系统链接器。

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 1970-01-01
      • 2021-02-26
      • 2015-11-28
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      相关资源
      最近更新 更多