installing from source HOWTO?
im trying to put tuxtype on my RH9 system for my daughter. she is wanting to learn how to type and this looks like it might just do the trick if i can ever figure out how to get it done.
i was able to figure out how to get past the tar.gz and get it to a tar, then was able to get tar -xf filename.tar to work and creat the dir: /home/ray/tuxtype2-1.5.2 i was then able to start part of the ./configure --prefix=/home/ray/tuxtype2-1.5.2/tuxtype but i got a C++ complier error at the end: Code:
[ray@localhost tuxtype2-1.5.2]$ ./configure --prefix=/home/ray/tuxtype2-1.5.2/tuxtype thank you for your help. |
during the install theres a development tool section, you needed to install most of those, If memory serves me, theres a way to re-enter the install menu (similar to when you first installed RH9), from there you will need to install basic development tools,
specifacly you need just about every compiler thats available in the RH9 install. all of them of course being branches of GCC. (it seems that the program you want is writen in c++, so youll want to install g++, although I dont remember if thats bundled in with gcc in red hat) once you have verified that it works, you might consider doing it with prefix=/usr/local so that its binary can be accesed via the comand line, also, you might look into checkinstall, which replaces 'make install' and installs apps as a package so you can remove it. post here if you got any more problems |
thanks for the reply. ill look at that later this afternoon when i get home.
|
hoping i am downloading the right thing now.
ftp://ftp.mirror.ac.uk/sites/sources...c-3.4.0.tar.gz pulling down the 2nd one on that list. ill see about installing that via ssh (boy im so newbiesh i hope i dont screw it up) and see if that will not give me what all i need. correct me if im wrong: first i need to deal with the .gz by gzip -u (ill look up the arguement, but i need the uncompress arguement) then i need to tar -xf then i need to do something with the make command, and at that point i get lost. |
if you are using the RedHat9 CD's, you dont have to
download anything, just go to your menu and find add/remove programs. in the development section, add the gnome development tools but if you do download, and its a tar.gz, you dont have to gzip first....this is built into tar. just use the -z switch...i use tar -xzvf this does it in one step |
ahh kewl. reason i did the download is to get the most current build of gcc, and the fact that im remote atm so i can not put the CD in the system, but i can ssh and install from there.
thank you much for the -z see so neet to learn, but this is what years of windows does to you. it makes one stupid. to install in M$, just put the CD in, or download the program and double click it, follow the wizard. all finished. that makes one rather dumb IMHO on how things work. that sadly is were i am. i love all the power of *nix, its unbeatable. |
Quote:
ok please explain to me how i know what directory to creat. do i just call it gcc, do i put it under / or /var/ or /usr what? wow, so much of that is just foreign to me. any and all help is greatly appricitated. |
What it's telling you there is that the gcc maintainers recommend that you compile gcc in a seperate folder to the one the source code is in. With most things you cd into the folder then do ./configure, make, make install, but with gcc (and a few other things) you need to make a seperate folder to build in, cd into that and then run the configure script in the gcc source folder from there. I mostly compile on my gnome desktop, but you can do it where you like. untar the gcc source code then create an empty folder somewhere to build in. It doesn't matter what it's called or where it is as you will be deleting it after you've done make install. I'm lazy so I would right click on my gnome desktop and choose Create Folder to make an empty folder, then I would delete the word untitled so it is just called folder then
cd /path/to/folder && /path/to/gcc-source/configure --prefix=WHERE-YOU-WANT-TO-INSTALL-IT --enable-languages=c,c++ && make bootstrap && make install make install has to be done as root if you chose to install it in a system wide location. It will work just as well if you choose to play it safe and install it somewhere in your home folder. I suggest you use the --enable-languages=c,c++ option as otherwise it will build compilers for half a dozen other languages that you don't need and it will take forever (slight exaggeration). If you install it somewhere other than --prefix=/usr you can use it when you need it by setting the variable export CC=/path/to/bin/gcc |
Quote:
[qoute]then I would delete the word untitled so it is just called folder then cd /path/to/folder &&[/quote] ok so i could make a folder with this path: /home/ray/gcc what are the '&&' for? Quote:
when i tar -zxf(i think that is the command. i might be missing one argument, but i can find that info in this thread) how do i tell it were to install the source, or will it put it someplace on its own? what is bootstrap? sorry to be so blonde, but as stated i really dont get how things install just yet. to much rpm, and windows setup.exe for me in the past. thank you for the help. |
/home/ray/gcc will be fine. I put the && there for safety reasons. If you copy a string of commands from your browser or a text file into a shell and press enter it will try and execute them one after the other. That may work perfectly, or it may not. If there is an error it will drop to the next command and try and execute that and may then give a very strange error message as the previous commands didn't work properly which would make it hard to work out what went wrong. If you put && at the end of each line it won't move on to the next line and try and do that, it'll just stop at the first problem and print an error message so we can then work through the problems one at a time.
Bootstrap is a way for the compiler to check that it is working properly. It first uses your system C compiler to build a new C compiler, then it uses that to make another one, then it uses that one to make a third. Then it compares the second and third one and if they are identical it is very likely that everything is working properly and you can go ahead and install it. tar xzf gcc-3.4.0.tar.gz will untar the source for you. You can give the tar command other options. man tar can tell you more. |
Quote:
this time i made sure to install the developer portion of the packets. |
Very wise.
|
best thing about mistakes is you can learn from them. i am smarter with linux now then i was yesterday.
|
Code:
[root@fedora pkgs]# ls |
All times are GMT -5. The time now is 09:40 AM. |