Command 'make' not found, but can be installed with: sudo apt install make # version 4.2.1-1.2, or sudo apt install make-guile # version 4.2.1-1.2
时间: 2024-03-14 07:45:37 浏览: 179
这个错误表示您的系统中缺少 make 工具,您需要先安装它才能使用 Makefile 文件编译程序。可以按照错误提示中给出的命令来安装 make 工具,例如:
```
sudo apt install make
```
如果您使用的是其他发行版的 Linux,可以使用该发行版的包管理器来安装 make 工具。安装完成后,再次尝试使用 make 命令编译程序。
相关问题
root@zxy-virtual-machine:/home/zxy/myFabric# make cryptogen Command 'make' not found, but can be installed with: apt install make # version 4.3-4.1build1, or apt install make-guile # version 4.3-4.1build1 root@zxy-virtual-machine:/home/zxy/myFabric# make cryptogen Command 'make' not found, but can be installed with: apt install make # version 4.3-4.1build1, or apt install make-guile # version 4.3-4.1build1
It seems that the 'make' command is not found on your system. The 'make' command is usually used to compile and build software from source code. To resolve this issue, you can try installing 'make' using the following command:
```
sudo apt install make
```
After the installation is complete, you should be able to run the 'make' command successfully.
Command 'java' not found, but can be installed with: sudo apt install openjdk-11-jre-headless # version 11.0.24+8-1ubuntu3~22.04, or sudo apt install default-jre # version 2:1.11-72build2 sudo apt install openjdk-17-jre-headless # version 1
### Java命令未找到问题的解决方案
对于Java命令未找到的问题,在Ubuntu上可以通过Apt包管理器来安装Java。具体操作如下:
在Ubuntu 18.04上,可以利用`add-apt-repository`命令将PPA存储库加入到系统的软件包源列表之中:`sudo add-apt-repository ppa:linuxuprising/java`[^1]。
之后更新本地数据库以获取最新的软件包信息:`sudo apt update`。
为了确保安装过程顺利进行,建议先刷新现有的软件包索引:`sudo apt-get update`[^2]。
接着就可以通过执行下面这条指令完成OpenJDK的部署工作了:`sudo apt install default-jdk`。
如果仅需安装Java运行环境(JRE),那么应采用此条语句代替上述命令:`sudo apt install default-jre`。
当以上步骤完成后,可通过输入`java -version`验证是否成功安装Java;同样地,想要确认javac编译器是否存在的话,则应当尝试键入`javac -version`来进行检验。
```bash
$ java -version
openjdk version "11.0.17" 2022-10-18
OpenJDK Runtime Environment (build 11.0.17+8-post-Ubuntu-0ubuntu120.04)
OpenJDK 64-Bit Server VM (build 11.0.17+8-post-Ubuntu-0ubuntu120.04, mixed mode, sharing)
$ javac -version
javac 11.0.17
```
#### 注意事项
有时即使已经正确安装了Java,但由于PATH变量配置不当或者存在多个不同版本冲突等原因也可能导致找不到Java命令的情况发生。此时可考虑调整环境变量设置或将特定路径优先级提高等方式解决问题。
阅读全文
相关推荐
















