64 bit

vamsi krishna vamsi.krishnak at gmail.com
Mon Jun 13 10:45:50 UTC 2005


Hello,

gcc also has an option of -m64 which will generate 64-bit object file
on 32-bit machines, but the feature stands unimplemented till gcc
version 3.3.2.

To check if your gcc support generation of 64-bit output.

try gcc -m64 test.c, if this is a success then you can get a 64-bit
kernel on a 32-bit machine. Try with latest gcc version on
http://gcc.gnu.org and see if -m64 option is implemented.

If not then as saurabh told you may need to complie the gnu tools.

Or if you have time hack gcc source and force that implementation.

Best,
Vamsi kundeti

On 6/13/05, Saurabh Bathe <sbathe at gmail.com> wrote:
> vamsi krishna wrote:
> 
> >Hello,
> >
> >Add the following flags for 32-bit compilation on amd64 bit machine.
> >
> >gcc: add option -m32
> >ld: add -melf_i386
> >
> >I dont think you need to recompile any gcc/gnu software.
> >
> >Thanks
> >Vamsi kundeti
> >
> >On 6/13/05, Saurabh Bathe <sbathe at gmail.com> wrote:
> >
> >
> >>ravi chandra wrote:
> >>
> >>
> >>
> >>>how to cross compile a 64 bit kernel on 32 bit environment
> >>>
> >>>
> >>>
> >>>__________________________________
> >>>Yahoo! Mail Mobile
> >>>Take Yahoo! Mail with you! Check email on your mobile phone.
> >>>http://mobile.yahoo.com/learn/mail
> >>>
> >>>
> >>>
> >>>
> >>>
> >>Hi,
> >>
> >>This is not impossible but quite difficult to achieve.
> >>I have never done this myself, but what I know is that you need to
> >>recompile the complete gcc-toolchain so that it recognizes and compiles
> >>64 bit. (this includes glibc and gcc and possibly kernel as well)
> >>Please correct me if I am wrong though.
> >>
> >>Infact the reverse is quite possible and simple. If possible I would
> >>prefer to have a 64 bit machine (AMD64 or Intel EM64T) which can do 32
> >>bit compile easily just by installing the proper devel libs.
> >>
> >>Regards,
> >>Saurabh
> >>
> >>--
> >>amd64-list mailing list
> >>amd64-list at redhat.com
> >>https://www.redhat.com/mailman/listinfo/amd64-list
> >>
> >>
> >>
> >
> >
> >
> Hi,
> 
> I think the question was about compiling the kernel to run on 64 bit
> platform using a machine that is running on a 32 bit platform.
> Recompilation of gcc toolkit is required only for compiling 64 bit
> binary on 32 bit platform and not for the reverse.
> 
> Regards,
> Saurabh
>




More information about the amd64-list mailing list