我在我的Ubuntu18.04LTS上安装了代码:块。它现在运行良好,我对它没有任何问题。但是当我更新我的系统时
sudo apt-get update && sudo apt-get upgrade -y我说错了
Err:7 http://ppa.launchpad.net/damien-moore/codeblocks-stable/ubuntu bionic Release
404 Not Found [IP: 91.189.95.83 80]
Reading package lists... Done
E: The repository 'http://ppa.launchpad.net/damien-moore/codeblocks-stable/ubuntu bionic Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default.
N: See apt-secure(8) manpage for repository creation and user configuration details.现在,当我删除软件中心中的http://ppa.launchpad.net/damien-moore/codeblocks-stable/ubuntu bionic时,代码:块并不运行我编写的程序。有这个错误似乎没有什么害处,但它是恼人的。
如何解决这个问题?我在学校上C课程,所以我需要一些编译器来做我的家庭作业,但我开放使用一些不同的东西。谢谢
发布于 2018-12-21 09:48:27
如前所述,ppa:damien-moore/codeblocks-stable没有18.04的软件包。
但是,代码的搜索洗衣板::块相关的PPA会导致其他名为ppa:pasgui/ppa的PPA。
你可以把它和
sudo add-apt-repository ppa:pasgui/ppa
sudo apt-get install codeblocks你将得到CodeBlocks 17.12。
您还可以通过以下方式安装cont肋骨插件
sudo apt-get install codeblocks-contrib享受插件。
发布于 2018-12-21 09:38:24
PPA似乎适用于不包括codeblocks包的现代版本的Ubuntu的旧版本:
请注意,这是为16.04版本的Ubuntu,这就是为什么您的现代(18.04仿生)版本找不到文件的PPA。但是,这并没有什么不同,因为Ubuntu包含了Version: 16.01+dfsg-2.1 of codeblocks。
如果您想在Ubuntu上编译C代码,那么确保编译器及其相关文件的最简单方法是安装build-essential包:
sudo apt install build-essential现在您应该有用于构建C/C++和它支持的其他语言的gcc和g++命令。将其保存为hello.c
#include <stdio.h>
int main() { printf("hello\n"); }然后编译它:
gcc hello.c然后运行它:
./a.outhttps://askubuntu.com/questions/1103526
复制相似问题