Help needed building gcc on Arm

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



I am attempting to build gcc 9.1.0 on an Arm7 (Raspberry Pi) running piCore Linux distribution, but i wish it to be build to also run on Arm6 (older Pi).

My build script looks like this

export CFLAGS="-O2 -pipe -march=armv6zk -mtune=arm1176jzf-s -mcpu=arm1176jzf-s -mfpu=vfp -mfloat-abi=hard-fuse-ld=gold" export CXXFLAGS="-O2 -pipe -fno-exceptions -march=armv6zk -mtune=arm1176jzf-s -mcpu=arm1176jzf-s -mfpu=vfp -mfloat-abi=hard -fuse-ld=gold"
export LDFLAGS="-L/usr/local/lib"

 ../gcc-9.1.0/configure \
    --libdir=/usr/lib \
    --enable-shared \
    --enable-threads=posix \
    --enable-__cxa_atexit \
    --enable-c99 \
    --enable-long-long \
    --enable-clocale=gnu \
    --enable-languages=c,c++ \
    --disable-multilib \
    --disable-libstdcxx-pch \
    --enable-cloog-backend=isl \
    --with-isl=/usr \
    --with-system-zlib \
    --enable-frame-pointer \
    --disable-bootstrap \
    --enable-lto \
    --with-pkgversion=piCore \
    --with-arch=armv6zk \
    --with-tune=arm1176jzf-s \
    --with-fpu=vfp \
    --with-float=hard \
    --with-gxx-include-dir=/usr/include/c++/9.1.0

but this fails with

libtool: compile: /mnt/sda1/piCore/10.x/armv7/tcz/src/gcc/build/./gcc/xgcc -B/mnt/sda1/piCore/10.x/armv7/tcz/src/gcc/build/./gcc/ -B/usr/local/armv7l-unknown-linux-gnueabihf/bin/ -B/usr/local/armv7l-unknown-linux-gnueabihf/lib/ -isystem /usr/local/armv7l-unknown-linux-gnueabihf/include -isystem /usr/local/armv7l-unknown-linux-gnueabihf/sys-include -DHAVE_CONFIG_H -I../../../gcc-9.1.0/libatomic/config/arm -I../../../gcc-9.1.0/libatomic/config/linux/arm -I../../../gcc-9.1.0/libatomic/config/posix -I../../../gcc-9.1.0/libatomic -I. -Wall -Werror -pthread -g -O2 -pipe -march=armv6zk -mtune=arm1176jzf-s -mcpu=arm1176jzf-s -mfpu=vfp -mfloat-abi=hard -fuse-ld=gold -MT load_1_1_.lo -MD -MP -MF .deps/load_1_1_.lo.Ppo -DN=1 -DIFUNC_ALT=1 -march=armv7-a+fp -c ../../../gcc-9.1.0/libatomic/config/linux/arm/load_n.c  -fPIC -DPIC -o .libs/load_1_1_.o cc1: error: switch '-mcpu=arm1176jzf-s' conflicts with '-march=armv7-a' switch [-Werror]
cc1: all warnings being treated as errors
make[4]: *** [Makefile:854: load_1_1_.lo] Error 1

How do I stop it picking up march=armv7-a - presumably it is getting that from the machine I am running on.?

I have tried adding --with-cpu=arm1176jzf-s to the configuration, with this I had to remove with-arch and with-tune, but the build gives exactly the same error.

Any help or suggestuions would be welcome.

Thanks

Tim.




[Index of Archives]     [Linux C Programming]     [Linux Kernel]     [eCos]     [Fedora Development]     [Fedora Announce]     [Autoconf]     [The DWARVES Debugging Tools]     [Yosemite Campsites]     [Yosemite News]     [Linux GCC]

  Powered by Linux