Cygwin 中库的 Linux 或 Windows 版本?

Linux or Windows version of a library in Cygwin?

我在 Linux 中开发了一些使用 boost::serialization 库的代码。现在我想将我的文件复制到 Cygwin 中并编译它们以生成 Windows 的可执行文件。我知道我应该使用 Mingw-64 g++ 编译器。但是boost库怎么样?我应该下载这个库的 Windows 版本还是 Linux 版本?

在 Cygwin 中,您按照 Unix/Linux 安装 Boost 库。来自 the documentation

Getting Started on Windows

A note to Cygwin and MinGW users

If you plan to use your tools from the Windows command prompt, you're in the right place. If you plan to build from the Cygwin bash shell, you're actually running on a POSIX platform and should follow the instructions for getting started on Unix variants. Other command shells, such as MinGW's MSYS, are not supported—they may or may not work.