简体   繁体   English

Cabal在Windows Server 2008上安装带有64位OpenSSL库的HsOpenSSL

[英]Cabal installing HsOpenSSL w/ 64-bit OpenSSL libs on Windows Server 2008

I have a haskell project that I'm trying to build on Windows 2008 64-bit. 我有一个haskell项目,我正在尝试在Windows 2008 64位上构建。 One of the dependencies is HsOpenSSL (not be to confused w/ hopenssl). 其中一个依赖项是HsOpenSSL (不要混淆w / hopenssl)。 Per the GHC docs, in order for this install to go smoothly one must install a binary distribution of openssl from here: http://slproweb.com/products/Win32OpenSSL.html and link during the cabal install process like this: 根据GHC文档,为了使这个安装顺利进行,必须从这里安装openssl的二进制发行版: http//slproweb.com/products/Win32OpenSSL.html并在cabal安装过程中链接如下:

cabal install HsOpenSSL --extra-include-dirs="c:/OpenSSL-Win32/include" --extra-lib-dirs="c:/OpenSSL-Win32"

Now the problem arises when I attempt to install the 64-bit binary distribution and install HsOpenSSL w/ it. 现在,当我尝试安装64位二进制发行版并安装HsOpenSSL时出现问题。

 cabal install HsOpenSSL --extra-include-dirs="c:/OpenSSL-Win64/include" --extra-lib-dirs="c:/OpenSSL-Win64"

This still throws the error of: 这仍然会引发以下错误:

Resolving dependencies...
Configuring HsOpenSSL-0.10.3.5...
cabal.exe: Missing dependencies on foreign libraries:
* Missing C libraries: eay32, ssl32
This problem can usually be solved by installing the system packages that
provide these libraries (you may need the "-dev" versions). If the libraries
are already installed but in a non-standard location then you can use the
flags --extra-include-dirs= and --extra-lib-dirs= to specify where they are.
Failed to install HsOpenSSL-0.10.3.5
cabal.exe: Error: some packages failed to install:
HsOpenSSL-0.10.3.5 failed during the configure step. The exception was:
ExitFailure 1

After inspecting the directories (OpenSSL-Win32 and OpenSSL-Win64) the directories are apparently the exact same with one small difference. 在检查目录(OpenSSL-Win32和OpenSSL-Win64)之后,目录显然完全相同,只有一个小的区别。 There is no MinGW folder in OpenSSL-Win64/libs/ , but there is one in OpenSSL-Win32/libs/ . OpenSSL-Win64/libs/没有MinGW文件夹,但OpenSSL-Win32/libs/有一个。 After removing this directory from the OpenSSL-Win32 install directory, HsOpenSSL still installs fine when linked w/ the 32-bit libs. OpenSSL-Win32安装目录中删除此目录后,HsOpenSSL在与32位库链接时仍然可以正常安装。 So I don't think that difference seems to matter. 所以我不认为这种差异似乎很重要。 All that to ask, Is HsOpenSSL compatible with openssl's 64-bit libs? 要问的是,HsOpenSSL是否与openssl的64位库兼容? Is there anything obviously wrong about what I'm doing? 我正在做的事情有什么明显的错误吗?

I'm using Cygwin, cabal 1.18.0.2, ghc 7.6.3, openSSL version 1.0.1e 我正在使用Cygwin,cabal 1.18.0.2,ghc 7.6.3,openSSL版本1.0.1e

It's four years later, but I just encountered the same problem so I guess its still relevant. 这是四年之后,但我刚遇到同样的问题所以我猜它仍然相关。 I solved it by downloading the latest Win64OpenSSL binaries, and manually cloning the HsOpenSSL repo at https://github.com/vshabanov/HsOpenSSL . 我通过下载最新的Win64OpenSSL二进制文件解决了这个问题,并在https://github.com/vshabanov/HsOpenSSL上手动克隆了HsOpenSSL存储库。 Then I opened the HsOpenSSL.cabal file and changed line 94 from 然后我打开了HsOpenSSL.cabal文件并更改了第94行

Extra-Libraries: eay32 ssl

to: 至:

Extra-Libraries: libeay32 ssleay32

Finally, open cmd and make the repo your current directory. 最后,打开cmd并使repo成为当前目录。 Then use cabal configure --extra-include-dirs="c:/OpenSSL-Win64/include" --extra-lib-dirs="c:/OpenSSL-Win64/lib" and cabal install to install the library. 然后使用cabal configure --extra-include-dirs="c:/OpenSSL-Win64/include" --extra-lib-dirs="c:/OpenSSL-Win64/lib"cabal install来安装库。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Windows Server 2008 64位上的7-Zip执行权限 - 7-Zip execution permissions on Windows Server 2008 64-bit 如何使64位dll与Windows Server 2008,Windows 7和Windows XP的64位版本兼容? - How to make 64 bit dll compatible with 64-bit editions of Windows Server 2008, Windows 7, and Windows XP? 用于64位Windows的OpenSSL和“无共享密码” - OpenSSL for 64-bit Windows and “no shared cipher” 无法使用Windows 7或Windows Server 2008 64位从COM +目录中导出32位ServicedComponent - Cannot export a 32-bit ServicedComponent from COM+ Catalog using Windows 7 or Windows Server 2008 64-bit Windows Server 2003 32位计算机应用程序可以用于Windows Server 2008 64位计算机吗? - Can a Windows Server 2003 32-bit machine application work for a Windows Server 2008 64-bit machine? ElasticSearch:在Windows 64位环境中安装ES插件 - ElasticSearch: Installing ES plugin in Windows 64-bit environment 在 Windows 10 64 位、Python 3.6 上安装 pygraphviz - Installing pygraphviz on Windows 10 64-bit, Python 3.6 在 Windows 64 位上安装 Cloud SQL 代理时出现问题 - Problems installing Cloud SQL Proxy on Windows 64-bit 在我的 Windows 64 位机器上安装 Python 时出错 - Error installing Python on my Windows 64-bit Machine MessageBeep()在64位Server2008上不起作用 - MessageBeep() not working on 64-bit Server2008
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM