LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
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 11-18-2010, 01:24 AM   #1
sattulinux
Member
 
Registered: Sep 2010
Posts: 44

Rep: Reputation: 2
cross compile in 64 bit machine for 32 bit arm


hi,
i have fedora 11(64 bit).i want to do the cross compilation for 32 bit arm processor.i install all required thing but any of the make command(make,make mrproper,defconfig) is not working.so plz help me what to do.

thanks.
 
Old 11-18-2010, 08:40 PM   #2
theNbomr
LQ 5k Club
 
Registered: Aug 2005
Distribution: OpenSuse, Fedora, Redhat, Debian
Posts: 5,395
Blog Entries: 2

Rep: Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903
Way too little detail for such a complex operation. 'i install all required thing' leaves us wondering exactly what version and origin of the 'required thing' you are using. And then there is the famous fault report: 'not working'. In how many of the 6 gzillion possible ways does it not work? And what exactly did you do that could have evoked such recalcitrant behavior?

Really, unless we're there looking over your shoulder, you need to be much more explicit about exactly what you're doing, exactly what went wrong (copy + paste error messages), and quite some detail about the products you're trying to use.
--- rod.

Last edited by theNbomr; 11-19-2010 at 09:34 AM.
 
Old 11-18-2010, 10:48 PM   #3
sattulinux
Member
 
Registered: Sep 2010
Posts: 44

Original Poster
Rep: Reputation: 2
sorry for no description.
i use the arm-2008-11-24.
i went for the eldk installation as below:

..................


edit the bashrc file in the home directory,
[go to home directory vi .bashrc to view the bash rc file.. in that u need to edit the env variables.. (. means hidden file)
fi
export ARCH=arm
export CROSS_COMPILE=arm-linux-
export DEPMOD=/opt/ELDK/usr/bin/depmod.pl
export PATH=/opt/ELDK/usr/bin:/opt/ELDK/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games]

copy arm-2008-11-24.iso, and qt-4.6.. (for embedded linux) .. in /opt folder... & workspace tar file in the home directory.. extract tar files in respective folders & continue with following steps for arm iso]
linuxhost > ...means ... /opt folder

problem with 32/64 bit ... reffer URL [http://www.denx.de/wiki/view/DULG/EL...itEnvironment]
(
14.1.7. Using the ELDK on a 64 bit platform
As the ELDK is compiled for 32-bit host systems, a compatibility layer is required on 64-bit systems. This package is usually called ia32-libs. So on a Debian or Ubuntu system a
sudo apt-get install ia32-libs
should be enough to make the ELDK work.
On the U-Boot mailing list, it was reported that for a 64 bit Fedora 11 the following should be enough:
sudo yum -y install glibc.i586 zlib.i586
)
/**/
linuxhost > mkdir eldk
linuxhost > mkdir install_mount [....to mount the .iso]
linuxhost > cd eldk/
linuxhost/eldk > su
linuxhost/eldk # mount -o loop,exec ../arm-2007-01-21.iso ../install_mount/
linuxhost/eldk # exit


linuxhost/eldk > ls install_mount/[to check in install_mount...
. arm ELDK_FIXOWNER etc install RPMS tools
.. common ELDK_MAKEDEV icons README.html sys version.. will be there]


linuxhost/eldk > ../install_mount/install arm
linuxhost/eldk > chmod u+x eldk_init

now unmount the ISO image as root *** not required

linuxhost/eldk > ./eldk_init arm
export these variable to environment,or include them as part of .bashrc file. [in the home directory.. for every user.]
ARCH=arm
CROSS_COMPILE=arm-linux-
DEPMOD=host/eldk/usr/bin/depmod.pl
PATH=host/eldk/usr/bin:host/eldk/bin
/**/

.........


then when i went for make command :


.........

[Bibhu@localhost ~]$ cd /home/suriya/satya/linux-2.6.30.4/


[Bibhu@localhost linux-2.6.30.4]$ make clean
CLEAN include/asm-arm/mach-types.h
[Bibhu@localhost linux-2.6.30.4]$
[Bibhu@localhost linux-2.6.30.4]$
[Bibhu@localhost linux-2.6.30.4]$ make
CHK include/linux/version.h
Generating include/asm-arm/mach-types.h
CHK include/linux/utsrelease.h
ERROR: include/asm is a directory but a symlink was expected
make: *** [include/asm] Error 1

[Bibhu@localhost linux-2.6.30.4]$
[Bibhu@localhost linux-2.6.30.4]$
[Bibhu@localhost linux-2.6.30.4]$
[Bibhu@localhost linux-2.6.30.4]$ make clean
CLEAN include/asm-arm/mach-types.h

[Bibhu@localhost linux-2.6.30.4]$
[Bibhu@localhost linux-2.6.30.4]$
[Bibhu@localhost linux-2.6.30.4]$ make mrproper
CLEAN scripts/basic
CLEAN scripts/kconfig
CLEAN include/config
CLEAN .config include/asm include/linux/autoconf.h include/linux/version.h include/linux/utsrelease.h
rm: cannot remove `include/asm': Is a directory
make: *** [mrproper] Error 1

[Bibhu@localhost linux-2.6.30.4]$


..........
 
Old 11-19-2010, 12:16 AM   #4
sattulinux
Member
 
Registered: Sep 2010
Posts: 44

Original Poster
Rep: Reputation: 2
hi
I am using the tool chain arm-2008-11-24.iso.It is working for 32 bit machine.But now i am using 64 bit.According to the guide i installed glibc.i686 zlib.i586 package.But i am not able to compile.
 
Old 11-19-2010, 09:33 AM   #5
theNbomr
LQ 5k Club
 
Registered: Aug 2005
Distribution: OpenSuse, Fedora, Redhat, Debian
Posts: 5,395
Blog Entries: 2

Rep: Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903
Okay, so it isn't obvious whether the problem is in the toolchain you're using or the sources that you're building. To narrow it down, I suggest using the toolchain to build some other source package, and/or use some other toolchain to build your kernel sources. I don't see anywhere that you've created a config for the kernel sources. Have you done that already, or did your kernel sources come with a pre-built config?

May I suggest using a native 64-bit toolchain, instead of wedging in shims to make a non-native compiler work? I use toolchains for Arm target CPUs built with crosstool-ng.

--- rod.

Last edited by theNbomr; 11-19-2010 at 09:37 AM.
 
Old 11-20-2010, 12:16 AM   #6
sattulinux
Member
 
Registered: Sep 2010
Posts: 44

Original Poster
Rep: Reputation: 2
hi
I changed the tool chain for the same package. But it did not work.I got the same error.

[Bibhu@localhost linux-2.6.30.4]$ make clean
[Bibhu@localhost linux-2.6.30.4]$ make
CHK include/linux/version.h
Generating include/asm-arm/mach-types.h
CHK include/linux/utsrelease.h
ERROR: include/asm is a directory but a symlink was expected
make: *** [include/asm] Error 1
[Bibhu@localhost linux-2.6.30.4]$


Actually this package and tool chain is working for ubuntu 64 bit machine.
I also changed the path for the new tool chain.Previously i used the eldk tool chain which i mention before.Now i used the EABI_4.3.3_EmbedSky_20090812.tar.bz2 tool chain.

Is there any library i have to install for this ?

Last edited by sattulinux; 11-20-2010 at 12:18 AM.
 
Old 11-20-2010, 01:02 AM   #7
theNbomr
LQ 5k Club
 
Registered: Aug 2005
Distribution: OpenSuse, Fedora, Redhat, Debian
Posts: 5,395
Blog Entries: 2

Rep: Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903
I don't know. That's why I recommend creating a native toolchain. Since the same error occurred with different toolchains, I would suspect that your source tree may be faulty. Again, where did you configure the kernel source tree?

--- rod.
 
Old 11-20-2010, 01:18 AM   #8
sattulinux
Member
 
Registered: Sep 2010
Posts: 44

Original Poster
Rep: Reputation: 2
oh sorry. I am using make menuconfig.Is there any other command for configure ?
 
Old 11-20-2010, 09:09 AM   #9
theNbomr
LQ 5k Club
 
Registered: Aug 2005
Distribution: OpenSuse, Fedora, Redhat, Debian
Posts: 5,395
Blog Entries: 2

Rep: Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903Reputation: 903
Yes, but menuconfig should be fine.
Does your source tree build with a native compiler? It isn't a really good test, because it is likely that any asm components are architecture specific, and are probably not used in all builds, but if it does fail, it points strongly to the source tree as the faulty part.

--- rod.
 
  


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
Can we install ubuntu AMD 64 bit on intel 64 bit machine ervaneet82 Linux - General 2 11-11-2010 04:40 PM
[SOLVED] Red Hat Enterprise Desktop 5.3 on 64 bit machine need 32-bit library file hhs1982 Linux - Newbie 4 06-29-2010 11:55 AM
Unable to compile 64 bit kernel on 64 bit machine even after successful compilation. atulsdeshmukh Linux - Kernel 2 09-18-2009 02:28 AM
Compile 32-bit kernel on a 64-bit machine kushalkoolwal Debian 6 06-15-2009 05:48 PM
Errors during the test suite for Glibc-20050926 32 Bit � Cross compile x86_64 Basel Linux From Scratch 3 10-29-2005 06:45 AM


All times are GMT -5. The time now is 01:37 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration