Sponsored Content
Full Discussion: gcc for arm process
Top Forums Programming gcc for arm process Post 302452921 by Corona688 on Monday 13th of September 2010 11:42:13 AM
Old 09-13-2010
Quote:
Originally Posted by zing_foru
My question was simple, let me make it more simpler, GCC has got compilation for target options
i.e. mcpu, march, etc How can we use that to compile a C code for ARM, MSP or ARC processors?
Can anyone give me sample steps for compiling?
We're not trying to withhold information from you. This isn't "easy".

Usually to build something you'd
  • Download it
  • Extract it
  • ./configure --help
  • ./configure
  • make
  • Attempt to install without overwriting any files from your good compiler(no sense having 2 broken compilers instead of 1 working one)
The ./configure step involves decisions on not just what architecture to use but where to keep headers, where to keep libraries, and how to use them. Usually these choices'd be made by the people managing your distribution. You may also need patches, again, usually provided by the people managing your distribution.

Last edited by Corona688; 09-13-2010 at 12:49 PM..
 

9 More Discussions You Might Find Interesting

1. Solaris

Installing gcc - recieve error message gcc : cannot execute

AIM- Install Oracle 11g on Solaris using VMWare Steps 1.Logged on as root 2.Created subfolders à /usr/local/bin & /usr/local/bin/gcc 3.Downloaded gcc & libiconv & unzipped them on my harddrive & burnt them on CD 4.Copied files from CD to /usr/local/bin/gcc 5.Terminal (root) à pkgadd -d... (8 Replies)
Discussion started by: Ackers
8 Replies

2. Linux

Kernel internals for ARM

Hi, Does anybody have a good pointer on Linux kernel internals for ARM architecture? I can locate plenty for x86 but since ARM is RISC I think there would be subtle changes. So if somebody has a knowledge of good document on Linux Kernel internals for ARM or even a comparative study of kernel on... (0 Replies)
Discussion started by: Rakesh Ranjan
0 Replies

3. Programming

When a process is down - how to get a coredump in arm board?

Running a multi-threaded program in my arm board one day or more ,The process down . In order to get a coredump to analysis of the stack , . I use commands ulimited -c unlimited . but when the process down . no coredump But I write a test #include <stdio.h> int main(void){ ... (14 Replies)
Discussion started by: aobai
14 Replies

4. UNIX for Advanced & Expert Users

gcc arm compiler

I want to find the ARM assembly language for my sample C code using gcc .I had gcc compiler ,whether it is enough for it or i need to download gcc arm cross compiler.If necessary ,how it configured?I am using fedora (0 Replies)
Discussion started by: sujith4u87
0 Replies

5. Fedora

gcc arm compiler

think only compile is required I wish to compile a sample code int main() { int a=5,b=8,c; c=a+b; } compile using gcc -Wall -g -march=arm922t main.c -o hello I got an error :bad value(arm922t) for -march=switch instead of using march i used mcpu options ,the same... (1 Reply)
Discussion started by: sujith4u87
1 Replies

6. Programming

Cygwin + insight + arm utils

Hello all, I have just installed cygwin and arm tools to do some arm assembly programming, but when i try to initialize insight with arm-elf-insight xxx.xxx I receive the message that arm-elf-insight cannot find cygncurses-8.dll. In my lib directory I have cygncurses-10.dll, but not... (0 Replies)
Discussion started by: Hiox
0 Replies

7. Programming

Running c code in ARM QEMU

I created and Compiled a C program to run in QEMU for ARM. When I run the program using the command #qemu-arm -L /home/arm-2010.09/arm-none-linux-gnueabi/libc ./test it gives me the following error: If 'qemu-arm' is not a typo you can use command-not-found to lookup the package that contains... (0 Replies)
Discussion started by: rupeshkp728
0 Replies

8. Programming

IDE's for the ARM processor on Linux

Hello everyone. I am running Debian on an ARM7 Device (aka my android phone). Everything is great. Works well. I would love to use it for Development. Mainly my interests are in Web Development, and Java development. So far the only useful IDE for debian arm is Netbeans. Which is pretty... (0 Replies)
Discussion started by: CDevelop
0 Replies

9. BSD

Move from Solaris: ARM 64 Bit

Hey all I've been thinking of switching my x86 Solaris out with ARM 64 Bit and FreeBSD. Now i know i can migrate my striped-mirror ZFS to FreeBSD. So to get to the point. I take advantage of Kernel Zones on Solaris (Routing, Firewall, Web Access and Web Page etc.) and from time to time need... (1 Reply)
Discussion started by: Reclzz
1 Replies
RAGG2-CC(1)						    BSD General Commands Manual 					       RAGG2-CC(1)

NAME
ragg2-cc -- CC frontend for compiling shellcodes SYNOPSIS
ragg2-cc [-a arch] [-b bits] [-k kernel] [-o file] [-dscxvh] DESCRIPTION
ragg2-cc is a frontend of CC. It is used to creates tiny binaries (1KB) or shellcodes in binary or hexpairs from a C source. The compiler used is the one configured by the CC environment. This has been tested with gcc, llvm-gcc and clang. Uses sflib (shellforge4) includes to get the syscall definitions. Only linux/darwin x86-32/64 is supported at the moment. Planned support for more architectures. OPTIONS
-a arch set architecture x86, arm -b bits 32 or 64 -k kernel windows, linux or osx -o file output file to write result of compilation -h show help message -v show version -d show assembler code -s generate assembly file -c generate compiled shellcode -x show hexpair bytes EXAMPLE
$ cat hi.c int main() { write (1, "Hello World ", 12); exit (0); } $ ragg2-cc hi.c hi.c.bin # Linked into a tiny binary. This is 294 bytes $ wc -c < hi.c.bin 294 $ ./hi.c.bin Hello World # The compiled shellcode has zeroes $ ragg2-cc -x hi.c e90000000083ec0ce800000000588d882a000000b804000000606a0651 6a0150cd8083c41061b8010000006a0050cd8083c40883c40cc368656c 6c6f0a00 # Use a xor encoder with key 32 to bypass $ ragg2 -e xor -c key=32 -B `ragg2-cc -x hi.c` 6a3e596a205be8ffffffffc15e4883c60d301e48ffc6e2f9c920202020 a3cc2cc82020202078ada80a2020209824202020404a26714a2170eda0 a3e4304198212020204a2070eda0a3e428a3e42ce348454c4c4f2a20 SEE ALSO
radare2(1), rahash2(1), rafind2(1), rabin2(1), rafind2(1), ranal2(1), radiff2(1), rasm2(1), ragg2cc(1), AUTHORS
pancake <pancake@nopcode.org> BSD
Dec 5, 2011 BSD
All times are GMT -4. The time now is 10:46 PM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy