3

cabal-installを介してインストールしようとしたときに表示されるメッセージは次のとおりです。

$ cabal install --extra-include-dirs="C:\no_spaces\cygwin\usr\include" --extra-lib-dirs="C:\no_spaces\cygwin\lib" readline
Resolving dependencies...
Configuring readline-1.0.1.0...
checking for gcc... gcc
checking for C compiler default output file name... a.exe
checking whether the C compiler works... yes
checking whether we are cross compiling... no
checking for suffix of executables... .exe
checking for suffix of object files... o
checking whether we are using the GNU C compiler... yes
checking whether gcc accepts -g... yes
checking for gcc option to accept ISO C89... none needed
checking for GNUreadline.framework... checking for readline... no
checking for tputs in -lncurses... yes
checking for readline in -lreadline... yes
checking for rl_readline_version... yes
checking for rl_begin_undo_group... yes
checking for rl_erase_empty_line... yes
checking for rl_free_undo_list... yes
checking for rl_completion_word_break_hook in -lreadline... yes
configure: creating ./config.status
config.status: creating config.mk
config.status: creating readline.buildinfo
config.status: creating include/HsReadlineConfig.h
config.status: include/HsReadlineConfig.h is unchanged
cabal.exe: Missing dependencies on foreign libraries:
* Missing header file: HsReadline.h
* Missing C libraries: readline, ncurses
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.
cabal.exe: Error: some packages failed to install:
readline-1.0.1.0 failed during the configure step. The exception was:
ExitFailure 1

私はreadline.hなどを持っていますが、明らかにそれらを見つけているようです。問題であるHsReadline.hの欠如は奇妙に思えます:私がインストールしようとしているパッケージのその部分ではありませんか?

これを機能させる方法についてのアドバイスをいただければ幸いです。gnuWin32 readline、MinGW、cygwinのいずれであっても、これを機能させるために何日もいじくり回してきました。

4

1 に答える 1

1

Cygwin を無効にしているのは、DOS/Windows スタイルのパス「C:\no_spaces\cygwin\usr\include」であると推測してみます。

Cygwin シェルでこれらのファイルに移動してみてください。おそらく「/cygdrive/c/no_spaces/cygwin/usr/include」のようになります

HsReadline.h に関するメッセージは、おそらくニシンです。本当の問題は、Cabal がコンパイル対象の基礎となる開発ライブラリを見つけられないことです。

于 2010-09-24T13:23:37.193 に答える