Hi all,
    I was confused with cross compiling, when I built vpp with the new 
version(18.10) using arm build tools.
    
The compiling environment is listed below:
    -----------------------------------------------------------------
    vpp 18.10
    host : ubuntu 16.04 , x86-64 cpu
    target : armv71
    toolchain : arm-linux-gcc alredy exist in my home directory
    ------------------------------------------------------------------

   The compiling process is listed below:
    
--------------------------------------------------------------------------------------------------
   user@vpp-compiler:~/vpp1810$ make build V=1 PLATFORM=arm32 or 
~/vpp1810/build-root$ make V=1 PLATFORM=arm32 TAG=vpp install-deb
make[1]: Entering directory '/home/user/vpp1810/build-root'
@@@@ Arch for platform 'arm32' is arm @@@@
@@@@ Finding source for external @@@@
@@@@ Makefile fragment found in 
/home/user/vpp1810/build-data/packages/external.mk @@@@
@@@@ Source found in /home/user/vpp1810/build @@@@
@@@@ Arch for platform 'arm32' is arm @@@@
@@@@ Finding source for vpp @@@@
@@@@ Makefile fragment found in /home/user/vpp1810/build-data/packages/vpp.mk 
@@@@
@@@@ Source found in /home/user/vpp1810/src @@@@
@@@@ Configuring external in 
/home/user/vpp1810/build-root/build-arm32_debug-arm/external @@@@

@@@@ Building external in 
/home/user/vpp1810/build-root/build-arm32_debug-arm/external @@@@
make[2]: Entering directory '/home/user/vpp1810/build/external'
make check-deb
make[3]: Entering directory '/home/user/vpp1810/build/external'
make[3]: warning: jobserver unavailable: using -j1.  Add '+' to parent make 
rule.
make[3]: Nothing to be done for 'check-deb'.
make[3]: Leaving directory '/home/user/vpp1810/build/external'
make[2]: Leaving directory '/home/user/vpp1810/build/external'
@@@@ Installing external @@@@
make[2]: Entering directory '/home/user/vpp1810/build/external'
make[2]: Nothing to be done for 'ebuild-install'.
make[2]: Leaving directory '/home/user/vpp1810/build/external'
@@@@ Configuring vpp in /home/user/vpp1810/build-root/build-arm32_debug-arm/vpp 
@@@@
-- The C compiler identification is unknown
-- Check for working C compiler using: Ninja
-- Check for working C compiler using: Ninja -- broken
CMake Error at /usr/share/cmake-3.5/Modules/CMakeTestCCompiler.cmake:61 
(message):
  The C compiler "/usr/lib/ccache/cc" is not able to compile a simple test
  program.

  It fails with the following output:

   Change Dir: 
/home/user/vpp1810/build-root/build-arm32l_debug-arm/vpp/CMakeFiles/CMakeTmp

  

  Run Build Command:"/usr/bin/ninja" "cmTC_d3272"

  [1/2] Building C object CMakeFiles/cmTC_d3272.dir/testCCompiler.c.o

  FAILED: /usr/lib/ccache/cc -g -O0 -DCLIB_DEBUG -DFORTIFY_SOURCE=2
  -DVLIB_MAX_CPUS=4 -march=armv7-a -fstack-protector-all -fPIC -Werror -o
  CMakeFiles/cmTC_d3272.dir/testCCompiler.c.o -c testCCompiler.c

  testCCompiler.c:1:0: error: bad value (armv7-a) for -march= switch

   #ifdef __cplusplus
   ^

  ninja: build stopped: subcommand failed.

  

  

  CMake will not be able to correctly generate this project.
Call Stack (most recent call first):
  CMakeLists.txt:16 (project)


-- Configuring incomplete, errors occurred!
See also 
"/home/user/vpp1810/build-root/build-arm32_debug-arm/vpp/CMakeFiles/CMakeOutput.log".
See also 
"/home/user/vpp1810/build-root/build-arm32_debug-arm/vpp/CMakeFiles/CMakeError.log".
Makefile:640: recipe for target 'vpp-configure' failed
make[1]: *** [vpp-configure] Error 1
make[1]: Leaving directory '/home/user/vpp1810/build-root'
Makefile:356: recipe for target 'build' failed
make: *** [build] Error 2   
-------------------------------------------------------------------------------------------------------

Could anyone give me some ticks or some examples how can I build sucess using 
vpp 18.10? 

Any reply will be appreciated!
thanks,



saint_...@aliyun.com
-=-=-=-=-=-=-=-=-=-=-=-
Links: You receive all messages sent to this group.

View/Reply Online (#11691): https://lists.fd.io/g/vpp-dev/message/11691
Mute This Topic: https://lists.fd.io/mt/28800506/21656
Group Owner: vpp-dev+ow...@lists.fd.io
Unsubscribe: https://lists.fd.io/g/vpp-dev/unsub  [arch...@mail-archive.com]
-=-=-=-=-=-=-=-=-=-=-=-

Reply via email to