FSI.exe在Ubuntu 10.10下不起作用 [英] FSI.exe does not work under Ubuntu 10.10

查看:101
本文介绍了FSI.exe在Ubuntu 10.10下不起作用的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

更新: 试过11月CTP版本.相同的错误消息. 忘记提及此服务器已安装Ubuntu服务器版本.我在运行Desktop 10.10的Ubuntu桌面上没有此问题. 所以我怀疑可能是缺少一些与命令行相关的库.安装libreadline-dev和libreadline5之后,错误消息消失了.但是,fsi卡住的问题仍然存在.

Update: Tried November CTP release. Same error message. Forgot to mention that this server has the Ubuntu server edition installed. I don't have this issue on my Ubuntu desktop that runs Desktop 10.10. So I suspected that it could be some command line related libraries missing. After I installed libreadline-dev and libreadline5, the error message disappeared. However, the issue that fsi stuck is still there.

Update2: 尝试了新的Mono 2.8.1.相同的FSI卡住问题.

Update2: Tried the new Mono 2.8.1. Same FSI stuck issue.

Update3: 由于此问题非常容易重现,因此我将其作为fsi.exe中的错误报告给了Microsoft.让我们看看进展如何.

Update3: As this issue is very reproducible, I reported it as a bug in fsi.exe to Microsoft. Let's see how it goes.

Update4: 得到了唐·塞姆的快速回应.他建议的解决方案解决了这个问题.我自己创建了答案.

Update4: Got quick response from Don Syme. The solution he suggested resolved this issue. I created the answer myself.

我在运行Ubuntu 10.10和Mono 2.8的服务器上安装了F#2.0. fsc.exe运行完美,我在编译fs文件时没有问题.但是,当我按如下方式运行fsi.exe时: 单声道/usr/local/FSharp/bin/fsi.exe

I installed F# 2.0 in a server running Ubuntu 10.10 and Mono 2.8. fsc.exe runs perfect, I have no problem in compiling fs files. However, when I run fsi.exe as follows: mono /usr/local/FSharp/bin/fsi.exe

我收到FSI提示,但错误消息不断重复

I got the FSI prompt, but an error message keep repeating

无法安装ctrl-c处理程序-Ctrl-C处理将不可用.错误为: 调用的目标引发了异常.

"Failed to install ctrl-c handler - Ctrl-C handling will not be available. Error was: Exception has been thrown by the target of an invocation"

我在这里错过了什么吗?

Am I missing anything here?

Mono 2.8是从源代码编译并安装的.

The Mono 2.8 was compiled and installed from source.

推荐答案

回答我自己的问题真的很尴尬.无论如何,我会回答,以便其他人可以从中受益.

Feel really awkward to answer my own question. Anyway, I'll answer it so other people can benefit from.

首先,安装libreadline-dev和libreadline5,以便摆脱以下错误消息

First of all, install libreadline-dev and libreadline5 so you can get rid of the following error message

无法安装ctrl-c处理程序-Ctrl-C处理将不可用.错误是:调用的目标抛出了异常

如果遇到fsi.exe卡住的问题,请尝试

If you encounter fsi.exe stuck issue, try

 fsi --gui-

在我的情况下,它可以很好地工作.

It works perfectly in my case.

这是我对为何发生此问题的理解.如果看一下代码,您会发现fsi.exe实际上引用了System.Windows.Forms,它进一步链接到Window系统.就我而言,我在未安装X系统的服务器上运行了fsi.因此,fsi坚持在那里尝试与不存在的X对话.这解释了为什么我的桌面上没有这个问题.

Here is my understanding of why such an issue happened. If you look into the code, you will find out fsi.exe actually references System.Windows.Forms, which further links to the Window system. In my case, I ran fsi in a server without X system installed. Consequently, fsi stuck there trying to talk to the nonexistent X. That explains why I don't have the issue in my desktop.

这篇关于FSI.exe在Ubuntu 10.10下不起作用的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆