通过 Cygwin64 安装适用于 Ocaml 的 z3 库(Windows 11)

问题描述 投票:0回答:1

我正在尝试在 Cygwin64 终端(Windows 11)中为 Ocaml 安装 z3 库。我收到以下错误,即使已经安装了库,也找不到 -lstdc++。

# cc1: warning: command-line option ‘-fvisibility-inlines-hidden’ is valid for C++/ObjC++ but not for C
# ocamlmklib -o api/ml/z3ml  -I api/ml -L. api/ml/z3native_stubs.o api/ml/z3enums.cmo api/ml/z3native.cmo api/ml/z3.cmo  -lz3 -lstdc++ -cclib -L/usr/lib/gcc/x86_64-pc-cygwin/11 -ccopt -L$(ocamlfind printconf destdir)/stublibs -dllpath $(ocamlfind printconf destdir)/stublibs
# ** Fatal error: Cannot find file "-lstdc++"
# make: *** [Makefile:5081: api/ml/z3ml.cma] Error 2
# make: Leaving directory '/home/doanha/.opam/4.14.0+flambda+mingw64_for_utop/.opam-switch/build/z3.4.11.2/build'

<><> Error report <><><><><><><><><><><><><><><><><><><><><><><><><><><><><><><>
┌─ The following actions failed
│ λ build z3 4.11.2
└─
╶─ No changes have been performed

有人知道问题是什么或如何解决吗?

我什至设置了 LDFLAGS 指向它:

$ export LDFLAGS="-L/usr/lib/gcc/x86_64-pc-cygwin/11"

或将 -lstdc++ 复制到 /usr/lib/

cygwin ocaml z3 opam
1个回答
0
投票

安装Cygwin时是否选择了

libstdc
软件包?

如果没有,重新安装 Cygwin 及其所有依赖项可能会很有用。

© www.soinside.com 2019 - 2024. All rights reserved.