首页 > 解决方案 > 在 Windows 10 中使用 Ubuntu 在 trec_eval 中尝试命令“make”或“Makefile”时出错

问题描述

当我在 Ubuntu Windows 10 上的 trec_eval v 8.1 中编写命令“make”或“Makefile”时,出现此错误:

make: gcc: Command not found
Makefile:33: recipe for target 'trec_eval' failed
make: *** [trec_eval] Error 127.

我尝试使用 trec eval 9 执行此操作,但出现此错误:segmentation fault (core dumped).

标签: makefilesegmentation-faultwindows-subsystem-for-linux

解决方案


你得到了一个gcc: Command not found,因为 gcc 目前没有安装在 Ubuntu 中,所以使用以下命令安装它:

sudo apt update  
sudo apt install make gcc  

这将安装 gcc 的默认版本。要安装更新版本的 gcc,请sudo apt install gcc-8改为运行。


推荐阅读