LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
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 03-04-2009, 10:04 AM   #1
meda75
LQ Newbie
 
Registered: Mar 2009
Posts: 4

Rep: Reputation: 0
Trouble with gcc compiler on arm platform


Hello . I am new with linux and of course I have lot questions .
I working on arm based platform .
/home/tools $ uname -a
Linux sbc9261 2.6.24 #28 Thu Dec 25 15:08:43 CST 2008 armv5tejl unknown
Can someone tell me can I install gcc on this ?. I have unpack gcc with
tar -xvjf arm-linux-gcc-3.4.5-glibc-2.3.6-linux.tar.bz2 -C / as it mentioned in manual and I am set PATH to proper value (export PATH=/usr/crosstool/gcc-3.4.5-glibc-2.3.6/arm-linux/bin/:$PATH) but wen i try to compile something or just type arm-linux-gcc -v response is something like :
Syntax error: "(" unexpected
Am I need crosstool ? or something else . Help me please
 
Old 03-10-2009, 11:00 PM   #2
ciotog
Member
 
Registered: Mar 2004
Location: Canada
Distribution: Slackware current
Posts: 727
Blog Entries: 2

Rep: Reputation: 43
I don't think arm-linux-gcc is what you want, it's used to compile code on an i386 machine that will run on an arm. In other words it's a cross-compiler.

I would recommend using the gcc that's distributed with debian, compiled to run on an arm platform (here, for instance), or use arm-linux-gcc to cross-compile code on another i386 PC and copy the compiled binaries over to the ARM machine.
 
Old 03-11-2009, 04:03 AM   #3
meda75
LQ Newbie
 
Registered: Mar 2009
Posts: 4

Original Poster
Rep: Reputation: 0
arm linux gcc

Thanks for answer I have already realize that Now I Am install arm-linux-gcc on Host PC and share rootfs with my arm controller via NFS ( mounted on Host PC ) . I should compile my source on host machine ( of course with arm compiler ) but he will be placed on controller . For executing I could use telnet ( unfortunately I do not know yet how to configure telnetd to work ) or ssh or rsh .? Debugging will be really hard job but I don't have much choice
 
Old 03-11-2009, 04:21 AM   #4
Suresh Maniyath
Member
 
Registered: Feb 2009
Location: India
Distribution: Fedora, Ubuntu
Posts: 37

Rep: Reputation: 19
console=ttyS0,115200n8

Don't know you have a serial port on your board. If you have one, then you will be able to get a console over there with hyperterminal, teraterm or minicom etc.

Regards,
Suresh
 
Old 03-11-2009, 07:06 AM   #5
ciotog
Member
 
Registered: Mar 2004
Location: Canada
Distribution: Slackware current
Posts: 727
Blog Entries: 2

Rep: Reputation: 43
If you're using NFS to mount the rootfs on the controller, then you would just have to place the binary in the rootfs for the controller to use it. If you want to permanently install it on the controller then it really depends on how it's currently configured.

I presume it's this board? http://www.embedinfo.com/english/Product/mini9261-I.asp

Or is it this one? http://www.embedinfo.com/english/Product/SBC9261-I.asp
 
Old 03-14-2009, 09:56 AM   #6
meda75
LQ Newbie
 
Registered: Mar 2009
Posts: 4

Original Poster
Rep: Reputation: 0
gcc issue

10x again my board (from uname -a) is sbc9261 . Weli I Have serial port and i could access to arm ,thats no doubt . Just i want to found best way to develop my own application ( in C ) . Is it to use NFS with mount rfs or just to compile my application on Host PC with arm gcc and make some script to automaticaly trensfer .out to controler ( via wget trough ethernet port for instance ? ) and watch wats happening on minocom ? What's your opinion and expirience ?

Regards
 
Old 03-14-2009, 11:51 AM   #7
ciotog
Member
 
Registered: Mar 2004
Location: Canada
Distribution: Slackware current
Posts: 727
Blog Entries: 2

Rep: Reputation: 43
The second field of uname is just the hostname, so you could make it be anything you want. If you have wget available on the board then that's a reasonable thing to use to transfer compiled applications over, although you would need to have a web server on the host. Personally I use scp, but that requires an sshd on the target board that supports scp. I've also used tftp but there are similar limitations as wget (you need a tftpd to transfer the application) although it's usually included in a build of busybox, assuming that's what's on the board.

Anyway there are too many unknowns to really answer your questions easily, without doing a bunch of research into the board you're using. If you provided more direct information about its capabilities then it would be easier to give recommendations.

You would most certainly want to cross-compile on the host. For one thing it will be much faster. You can use something like scratchbox, or use crosstool. Or Wolfgang Denk's ELDK (which uses crosstool).
 
  


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
Compile the linux2.6.14.1 for arm must ues the arm-linux-gcc-3.4.4? frankyue Linux - Embedded & Single-board computer 2 12-20-2008 07:28 AM
PIC issue on RHEL4 platform gcc 3.3.6 compiler dayalan_cse Programming 0 11-05-2008 07:35 AM
how to port linux kernel 2.6 V to ARM PXA platform. zahidul Linux - Newbie 1 09-26-2008 05:12 PM
query regarding linux kernel debugger on ARM platform mayank_linux Linux - Software 1 06-07-2006 06:06 AM
a doubt with host gcc and arm-linux-gcc renjithgopal Linux - General 1 09-11-2003 04:02 PM


All times are GMT -5. The time now is 05:38 PM.

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