"C或gcc"表示就像“鸡还是蛋" ? :( [英] "C or gcc" is like "Chicken or the egg" ? :(

查看:118
本文介绍了"C或gcc"表示就像“鸡还是蛋" ? :(的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

可能重复:
如何引导gcc/g ++?

Possible Duplicate:
How are gcc/g++ bootstrapped?

我想知道gcc是如何编译的,因为我们都知道它是用C编写的.

I would like to know how gcc is compiled as we all know it is written in C.

他们是否使用了其他一些编译器来编写gcc?

Did they used some other compiler to come up with gcc?

如果是这样,我可以使用相同的编译器来编译我的C程序吗?

If so, can I use the same compile to compile my C program?

推荐答案

这里没有鸡肉和鸡蛋. glibc是使用您使用的编译器进行编译的.

There is no chicken and egg here. glibc is compiled with the compiler you are using.

该编译器首先使用同一编译器的早期版本进行编译.然后它也可以自行编译.

That compiler was first compiled with a previous version of the same compiler. Then it can compile itself as well.

真正的鸡和蛋问题在1950年代解决,当时有人不得不编写世界上第一个编译器.之后,您可以使用一个编译器来编译下一个.

The real chicken-and-egg problem was solved in the 1950's when someone had to write the world's first compiler. After that, you can use one compiler to compile the next one.

这篇关于"C或gcc"表示就像“鸡还是蛋" ? :(的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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