I've always thought that any Linux distro would include gcc (or at least a C compiler), but according to one of my teachers, this is not the case.

Do you know any distro matching this case, and also, for what reason there wouldn't be any C compiler?

  • Please clarify "included". Is "installable from default repositories/physical install media but not installed by default" "included"? – Ulrich Schwarz Mar 6 '15 at 16:14
  • By included, I mean that once your distro is installed you can run gcc without having to install anything more. This seems to depend on options during the installation, but no distro that I've ever installed asked me if wanted to install gcc – Tloz Mar 6 '15 at 16:28

Almost all PC-targeting distros are going to have a way to install GCC, as you can't compile the Linux kernel without it. But it won't always be installed by default, and even if it is, can be removed by the admin.

Example: I don't think it's installed by default on Debian. (Though the installer gives you a wide selection of which packages to install, so there are many default package sets.)

You also surely won't find it installed (or possibly even available) on embedded Linux distros as GCC is fairly big, in both storage and RAM requirements to run. Instead, it's installed on a non-embedded machine and everything is cross-compiled.

| improve this answer | |
  • 1
    There is a well defined core of packages in Debian, normally termed essential, I believe, which Debian insists on having installed, and complains about if you try to remove it. And yes, this does not include gcc. – Faheem Mitha Mar 6 '15 at 16:29
  • @FaheemMitha All of the default installs include more than Essential: yes packages. E.g., dpkg is Essential, but I don't believe apt-get is. – derobert Mar 6 '15 at 16:32
  • apt is priority important. I guess Debian insists on those being installed too. Though when you try to remove apt, dpkg says: "WARNING: The following essential packages will be removed. This should NOT be done unless you know exactly what you are doing!" The rules must be listed somewhere in policy. – Faheem Mitha Mar 6 '15 at 17:05
  • Indeed, see debian.org/doc/debian-policy/ch-binary.html#s3.7 for the criteria. – Stephen Kitt Mar 6 '15 at 17:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.