0
votes

I am compiling code to run on an arm neon and the make files have the following command line included.

-mcpu=cortex-a9 -march=armv7 -mfpu=neon -DARM_NEON

The details of GCC version are as follows: gcc (Ubuntu 4.8.4-2ubuntu1~14.04) 4.8.4

However when I try to compile, gcc keeps throwing the following error: gcc: warning: '-mcpu=' is deprecated; use '-mtune=' or '-march=' instead gcc: error: unrecognized command line option '-mfpu=neon'

I am pretty sure that the code could be compiled previously. Though a long time ago. Could it be changes in version of GCC? or is it do with 32 bit and 64 bit compilers?

1
Are you trying to cross-compile from an x86 host to an ARM target ? If so then you'll need a cross-compiler rather than your native gcc. - Paul R
what is the output of [compiler] --target-help | grep arm - old_timer
@PaulR: thank you, I was indeed cross compiling. I used a arm cross compiler for it and it worked fine. - user4089193

1 Answers

0
votes

I was trying to cross compile for an arm processor on my intel x86_64 Ubuntu machine. I needed to add the configuration for the host in the makefiles and use arm-linux-gnueabihf-gcc instead of gcc.