LinuxQuestions.org
Latest LQ Deal: Complete CCNA, CCNP & Red Hat Certification Training Bundle
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 07-08-2012, 03:00 AM   #1
singburisam
LQ Newbie
 
Registered: Jul 2012
Posts: 8

Rep: Reputation: Disabled
Please help me install gcc without Internet


I have just installed Fedora 17 on a laptop. I have "dual boot" but only the Windows side can access the Internet. For some reason, the Fedora I installed did not have development tools. That's OK; I just want gcc.

I can find lots of ways to fetch gcc source but that seems unnecessary and won't work directly anyway: I don't have any C compiler.

I see that it's "real easy" with 'yum' but I don't have Internet from the machine that would be yumming.

With Google I can find prepared binaries, but the ones I saw are 8 years old or more. Is that the best option?

Is there a simple way for me to download a current binary or 'rpm' package for gcc?

Please go easy on me. I'm a newbie!
 
Old 07-08-2012, 03:30 AM   #2
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1976Reputation: 1976Reputation: 1976Reputation: 1976Reputation: 1976Reputation: 1976Reputation: 1976Reputation: 1976Reputation: 1976Reputation: 1976Reputation: 1976
You can still use yum ro install from the dvd.. http://www.cyberciti.biz/faq/centos-...dvd-using-yum/
 
Old 07-08-2012, 06:21 AM   #3
pixellany
LQ Veteran
 
Registered: Nov 2005
Location: Annapolis, MD
Distribution: Arch/XFCE
Posts: 17,802

Rep: Reputation: 738Reputation: 738Reputation: 738Reputation: 738Reputation: 738Reputation: 738Reputation: 738
Why not fix the internet issue?? What is your network setup, and why won't the Linux side access it?
 
Old 07-08-2012, 09:19 AM   #4
singburisam
LQ Newbie
 
Registered: Jul 2012
Posts: 8

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by acid_kewpie View Post
You can still use yum ro install from the dvd.. http://www.cyberciti.biz/faq/centos-...dvd-using-yum/
Thank you. My dvd (actually cd) didn't work originally; let me explain how I've come here in case that helps.

I followed instructions which seemed correct and booted a Fedora CD, but this failed with error messages:
Quote:
mount: /dev/loop2: can't read superblock
umount: /run/initramfs/squashfs: not mounted
mount: unknown file system type: 'DM_snapshot_cow'
mount: unknown file system type: 'DM_snapshot_cow'
...
In another forum I was advised that this error was explicable and not uncommon and that the easiest workaround was to use LinuxLive to copy a CD Fedora image to Memory Stick, and boot/install from Stick instead of from CD. I did this. That image was 646 MB and has the name "Fedora-17-i686-Live-Desktop." I booted the Memory Stick, installed Fedora; this all seemed to work fine.

But I do not have 'gcc'. Is there an easy way to tell if 'gcc' was even on the 646 MB image I started with?

While I'm asking, let me ask a "Meta-question":

The system is also missing 'tcsh' and 'gimp', two programs I like to use. I notice that 'python', on the other hand, is present.

Is there some legal or other reason why 'python' installs by default, but other useful programs (like 'gcc') do not?
 
Old 07-08-2012, 10:30 AM   #5
suicidaleggroll
LQ Guru
 
Registered: Nov 2010
Location: Colorado
Distribution: OpenSUSE, CentOS
Posts: 5,562

Rep: Reputation: 2127Reputation: 2127Reputation: 2127Reputation: 2127Reputation: 2127Reputation: 2127Reputation: 2127Reputation: 2127Reputation: 2127Reputation: 2127Reputation: 2127
Quote:
Originally Posted by singburisam View Post
Is there some legal or other reason why 'python' installs by default, but other useful programs (like 'gcc') do not?
Packages are only installed if they
1) are required by another package, or
2) are selected by the user

Python is required by YUM, which is why it's installed. GCC is not required by anybody, so unless you select it during installation, it won't be installed.

Fedora is an experimental OS, you REALLY need regular updates to fix the bugs with it. This means that it's pretty important you get your internet working. Until then you should be able to mount your install USB and set it up as a repository for YUM so you can grab a few of these missing binaries off of it. Keep it mind though that the live CD image only includes a minimal set of packages to keep the size down. It may not even have GCC on it, you might need the DVD image to get that.
 
Old 07-08-2012, 12:25 PM   #6
singburisam
LQ Newbie
 
Registered: Jul 2012
Posts: 8

Original Poster
Rep: Reputation: Disabled
I've been using Fedora for many years, without Internet, and with essentially no trouble. This may be partly because my needs are very simple. Hardware problems meant I needed a new laptop fast, though my old machine (with Fedora 8 installed) works well enough to get files off of. I've already transferred one binary successfully from the old machine.

If no simpler solution presents itself, I may just copy the pieces of 'gcc' via external drive from old machine to new; I do realize this would be tedious and error-prone. I would much prefer to have a simple tarball (or equivalent) to get 'gcc' but the solutions suggested do not allow that. (How much variability can there be in Fedora 17 gcc? Why can't someone point me to a simple tarball or equivalent to download without using 'yum' utility?) I could find a simple C compiler binary; download that and 'make gcc' (I already did download 'gcc' source, hoping it would have usable binaries); if someone recommends a simple C compiler good enough to make 'gcc' but simple enough to install without 'yum' I may try that.

When I selected my 'iso' Fedora image for flash drive in the first place, I noticed no option for 'Linux with gcc'. I could start from scratch, preparing a LinuxLive memory stick with a more complete Linux and reinstalling, but am reluctant to try that without better confidence.

ETA: The stick I created had Fedora 17 "Beefy Miracle". Googling around to pages like
http://docs.fedoraproject.org/en-US/...ide/index.html
I find no mention that 'gcc' is omitted (not that it is included). If I boot that stick I get 'gcc not found' etc., but is that definitive? [U]I do not see any "Very Beefy Miracle" whose name would suggest it is "beefier" than "Beefy Miracle".

Is there a Fedora forum where I can get a definitive answer?

Last edited by singburisam; 07-08-2012 at 01:01 PM.
 
Old 07-08-2012, 01:02 PM   #7
suicidaleggroll
LQ Guru
 
Registered: Nov 2010
Location: Colorado
Distribution: OpenSUSE, CentOS
Posts: 5,562

Rep: Reputation: 2127Reputation: 2127Reputation: 2127Reputation: 2127Reputation: 2127Reputation: 2127Reputation: 2127Reputation: 2127Reputation: 2127Reputation: 2127Reputation: 2127
Quote:
Originally Posted by singburisam View Post
Why can't someone point me to a simple tarball or equivalent to download without using 'yum' utility?)
Because you can't just install gcc. It has a lot of dependencies that must be installed as well in order for it to function properly. yum will handle all of this for you, otherwise you're going to be going through a LOT of back and forth acquiring packages on the system with internet, copying them over, trying the installation, finding a new dependency, downloading it on the other system, copy it over, try again, etc.

Quote:
Originally Posted by singburisam View Post
When I selected my 'iso' Fedora image for flash drive in the first place, I noticed no option for 'Linux with gcc'. I could start from scratch, preparing a LinuxLive memory stick with a more complete Linux and reinstalling, but am reluctant to try that without better confidence.
It's because you downloaded the live CD iso. This only has a minimal set of packages required for the installation. Had you downloaded the DVD instead, you would have been prompted during the installation to select which packages you wanted to install, gcc and its dependencies being one of them.

If I were in your place right now, I would download the DVD iso on the system with internet, use a big enough USB drive to copy it over, mount the iso on your F17 system, and then set it up as a repo for yum.
 
Old 07-08-2012, 01:02 PM   #8
TobiSGD
Moderator
 
Registered: Dec 2009
Location: Germany
Distribution: Whatever fits the task best
Posts: 17,148
Blog Entries: 2

Rep: Reputation: 4853Reputation: 4853Reputation: 4853Reputation: 4853Reputation: 4853Reputation: 4853Reputation: 4853Reputation: 4853Reputation: 4853Reputation: 4853Reputation: 4853
So why don't you just download the DVD to use it as repository for installing programs?
EDIT: Oh, too slow.

Last edited by TobiSGD; 07-08-2012 at 01:03 PM.
 
Old 07-08-2012, 01:24 PM   #9
singburisam
LQ Newbie
 
Registered: Jul 2012
Posts: 8

Original Poster
Rep: Reputation: Disabled
Arrow

Quote:
Originally Posted by suicidaleggroll View Post
If I were in your place right now, I would download the DVD iso on the system with internet, use a big enough USB drive to copy it over, mount the iso on your F17 system, and then set it up as a repo for yum.
Thank you. After preparing this DVD iso on a USB drive, I wonder if it would be simplest to then just use it to re-install from scratch. ... Well I can try 'yum's first and see if they work fine.

I would have done this to begin with, but was too ignorant to even know of this alternative. :-(
LinuxLive doesn't present it as an option (though I should use LinuxLive to "burn" the USB drive, is that correct?)
I Googled for something like "Download Fedora" but went to pages that never mentioned the alternative.

Please help me avoid making yet another mistake! I'm looking at two choices at
http://fedoraproject.org/en/get-fedora-options#formats
Quote:
Intel & AMD / PC compatible
32-bit
Download Now!Most Compatible

3.6GB ISO disk image for 32-bit PC
Intel & AMD / PC compatible
64-bit
Download Now!

3.6GB ISO disk image for 64-bit PC
I do have 64-bit laptop, but should I download the 32-bit which is "Most compatible"?
 
Old 07-08-2012, 01:42 PM   #10
suicidaleggroll
LQ Guru
 
Registered: Nov 2010
Location: Colorado
Distribution: OpenSUSE, CentOS
Posts: 5,562

Rep: Reputation: 2127Reputation: 2127Reputation: 2127Reputation: 2127Reputation: 2127Reputation: 2127Reputation: 2127Reputation: 2127Reputation: 2127Reputation: 2127Reputation: 2127
Quote:
Originally Posted by singburisam View Post
Thank you. After preparing this DVD iso on a USB drive, I wonder if it would be simplest to then just use it to re-install from scratch. ... Well I can try 'yum's first and see if they work fine.

I would have done this to begin with, but was too ignorant to even know of this alternative. :-(
LinuxLive doesn't present it as an option (though I should use LinuxLive to "burn" the USB drive, is that correct?)
Depends on if you want to use the USB drive as the repo itself, or if you just want to use it to copy the iso over to your F17 system (where you can then set up a local repo). If you just want to set up a local repo and use the USB drive to copy the iso over, then you could just drag and drop the iso onto the USB drive, then do the same to get it onto the F17 system. If you want to use the USB drive as the repo itself, then you would need to "burn" the iso to the USB using something like LinuxLive.

Quote:
Originally Posted by singburisam View Post
I Googled for something like "Download Fedora" but went to pages that never mentioned the alternative.

Please help me avoid making yet another mistake! I'm looking at two choices at
http://fedoraproject.org/en/get-fedora-options#formats

I do have 64-bit laptop, but should I download the 32-bit which is "Most compatible"?
If you have <3GB of RAM then you can use the 32-bit without a problem, otherwise I would go with the 64-bit. I've been using 64-bit Fedora for close to seven years now and have never run into a compatibility problem as far as I can remember. A 64-bit OS can run both 32 and 64-bit binaries, a 32-bit OS can only run 32-bit binaries...so in some respects the 64-bit OS can be MORE compatible, as long as the hardware supports it.

Last edited by suicidaleggroll; 07-08-2012 at 01:43 PM.
 
Old 07-09-2012, 12:05 AM   #11
singburisam
LQ Newbie
 
Registered: Jul 2012
Posts: 8

Original Poster
Rep: Reputation: Disabled
Talking

Quote:
Originally Posted by suicidaleggroll View Post
Depends on if you want to use the USB drive as the repo itself, or if you just want to use it to copy the iso over to your F17 system (where you can then set up a local repo). If you just want to set up a local repo and use the USB drive to copy the iso over, then you could just drag and drop the iso onto the USB drive, then do the same to get it onto the F17 system. If you want to use the USB drive as the repo itself, then you would need to "burn" the iso to the USB using something like LinuxLive.
Thank you. I hope I'm not wearing out my welcome by asking newbie questions but an old motto is "Understand fully or copy exactly." I definitely do not understand fully.

You describe two options: "copy iso" and "burn repo." It sounds like the latter option makes more sense, especially since in the instructions linked to upthread, the step 'createrepo' seems to require a repo already for 'yum install' :
Quote:
Type the following command (replace iso file name with the actual iso file):
# yum install createrepo
# mkdir -p /mnt/iso/{1,2,3}
# mount -o loop /path/to/centos1.iso /mnt/iso/1

# cd /mnt/iso
# createrepo .

# yum clean all

# vi /etc/yum.repos.d/iso.repo
{Appending following text:}
[My ISO Repository]
baseurl=file:///mnt/iso
enabled=1

# yum install package-name
With the "burn repo" option, once I have the burned repo, would I start at
vi /etc/yum.repos.d/iso.repo
using USB drive as the baseurl?

Last edited by singburisam; 07-09-2012 at 12:07 AM.
 
Old 07-09-2012, 01:31 AM   #12
pascor
LQ Newbie
 
Registered: Jul 2012
Location: near Philadelphia, PA, USA
Distribution: Ubuntu 12.04 LTE 32-bit on all platforms
Posts: 6

Rep: Reputation: Disabled
Why don't you replace Fedora with a distro that has gcc, python and good hardware support to get your LAN hardware working, etc., already in it ? What's indispensible about Fedora ?

I've had good luck so far with the Ubuntu so-called "special" installer versions, both the 32-bit and the 64-bit flavors. The "special" versions seem to have better hardware support than the standard versions, which installed on some strange motherboards I have on which the standard version installer bombed.

It would be a lot more straight-forward and easier to use an optical drive, USB or internal desktop type, to install with an ISO file burned to a CD or DVD disc. You could download and burn the ISO images in Windows.
 
Old 07-09-2012, 03:02 AM   #13
acid_kewpie
Moderator
 
Registered: Jun 2001
Location: UK
Distribution: Gentoo, RHEL, Fedora, Centos
Posts: 43,417

Rep: Reputation: 1976Reputation: 1976Reputation: 1976Reputation: 1976Reputation: 1976Reputation: 1976Reputation: 1976Reputation: 1976Reputation: 1976Reputation: 1976Reputation: 1976
Quote:
Originally Posted by pascor View Post
Why don't you replace Fedora with a distro that has gcc, python and good hardware support to get your LAN hardware working, etc., already in it ? What's indispensible about Fedora ?
It's not about the distro, it's about the way they installed it, and they environment they're in. Fedora does have GCC etc. that's not relevant.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
yum install gcc doesn't set the lastest gcc ver 4.3.x kim,jw Linux - Newbie 3 12-23-2008 12:51 AM
How to install gcc in mandriva 2009 (with NO internet @linux)? morganxl Mandriva 10 12-14-2008 02:06 PM
how to install gcc offline because my computer is not connected to internet sumeet inani Linux - Newbie 4 10-29-2008 04:24 AM
How to install gcc without internet? karuci Ubuntu 10 07-09-2006 02:47 PM
gcc wont install, 'failed dependencies: glibc-devel is needed by gcc-3.3.3-41' TdlSnare SUSE / openSUSE 3 11-29-2004 03:13 PM

LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 03:57 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration