ive been trying to set up GCC cross compiling on my cygwin
and ive been having some problems.
is there a stable version i can use of the gcc and binutils?
ive tried 3 different ones and they all left me with problems when i try to follow the bare bones tutorial.
is there something special i need to do to uninstall the old versons? or just delete the folders they are in?
gcc cross compiler
Re:gcc cross compiler
You'll probably want to run:
"make clean"
if you left any of the half-done builds in place, but it shouldn't cause problems not to. Make should be smart enough to know it needs updating....
What kind of errors?
"make clean"
if you left any of the half-done builds in place, but it shouldn't cause problems not to. Make should be smart enough to know it needs updating....
What kind of errors?
Re:gcc cross compiler
From the BareBones "troubleshooting" section:
Stable binutils is 2.16.1. Stable GCC is 3.4.6 or 4.1.1.
Make sure you are actually using the cross-compiler tools you've created using the GCC Cross-Compiler tutorial, i.e. the executables in /usr/cross/... .I get Error: junk at end of line, first unrecognized character is ',' ...
Chances are the GNU as you use is not targeted at ELF - it chokes on the .comm stack, STACKSIZE, 32 line, as three arguments to .comm are only supported for ELF targets. Try setting up a GCC Cross-Compiler.
Stable binutils is 2.16.1. Stable GCC is 3.4.6 or 4.1.1.
Every good solution is obvious once you've found it.
Re:gcc cross compiler
what would be the usage for:
as -o loader.o loader.s
gcc -o kernel.o -c kernel.c -Wall -Werror -nostdlib -nostartfiles -nodefaultlibs
or
ld -T linker.ld loader.o kernel.o
to unpack the packages, i just use 'tar -xf' and itll make a folder, and from there i use the tutorial?
as -o loader.o loader.s
gcc -o kernel.o -c kernel.c -Wall -Werror -nostdlib -nostartfiles -nodefaultlibs
or
ld -T linker.ld loader.o kernel.o
to unpack the packages, i just use 'tar -xf' and itll make a folder, and from there i use the tutorial?
Re:gcc cross compiler
If you download the .gz packages, you unpack with -xzf; if you have the .bz2 packages, unpack with -xjf.simmy wrote: ck the packages, i just use 'tar -xf' and itll make a folder, and from there i use the tutorial?
Just follow the tutorial. Basically, GCC Cross-Compiler and BareBones are two chapters of the same tutorial: From Cygwin to your first working kernel.
Every good solution is obvious once you've found it.
Re:gcc cross compiler
Basically, you have to include /usr/cross/bin in your &PATH variable and then, invoke the binaries you find in that folder, e.g. i386-elf-gcc and i386-elf-ld (depending on the target).
Look it up at http://www.osdev.org/osfaq2/index.php/GCC Cross-Compiler
Candamir
Look it up at http://www.osdev.org/osfaq2/index.php/GCC Cross-Compiler
Candamir
Re:gcc cross compiler
Hi,
I successfully made the cross-compiler using the tutorial in faq.
I want to test this cross-compiler on Brian Kernel development tutorial. Is the batch file in Brian tutorial applicable to my cross-compiler, or do we have to change the syntax, especially the options. Or I should say what is the equivalent of build.bat file in Brian tutorial to my cross-compiler in Cygwin? Can I make script file and then type name of script file as command line? Sorry I am not Unix/Linux guy, I don't know about batch file in Unix/Linux.
Can someone please guide me on how to do this?
Your help will be appreciated.
Thanks.
I successfully made the cross-compiler using the tutorial in faq.
I want to test this cross-compiler on Brian Kernel development tutorial. Is the batch file in Brian tutorial applicable to my cross-compiler, or do we have to change the syntax, especially the options. Or I should say what is the equivalent of build.bat file in Brian tutorial to my cross-compiler in Cygwin? Can I make script file and then type name of script file as command line? Sorry I am not Unix/Linux guy, I don't know about batch file in Unix/Linux.
Can someone please guide me on how to do this?
Your help will be appreciated.
Thanks.