交叉編譯log4cxx

HOST:PC

Architecture:                       x86_64

Model name:          Intel(R) Xeon(R) Gold 6354 CPU @ 3.00GHz

 

TARGET:ORINX

Architecture:                    aarch64

Model name:           ARMv8 Processor rev 1 (v8l) CPU @ 2.01GHZ

 

OS:

Distributor ID: Ubuntu
Description: Ubuntu 20.04.2 LTS
Release: 20.04
Codename: focal

 

THIRD_PARTY=/your/install/prefix/path

 

https://apr.apache.org/download.cgi

 

APR 1.7.4

https://dlcdn.apache.org//apr/apr-1.7.4.tar.gz

mkdir abuild &&  cd abuild

../configure --host=$TARGET --prefix=$THIRD_PARTY  ac_cv_file__dev_zero=yes

 make -j4

make test

make install

 

note:modified configure

 #as_fn_error $? "cannot run test program while cross compiling See \`config.log' for more details" "$LINENO" 5;

 

 

APR-util 1.6.3

https://dlcdn.apache.org//apr/apr-util-1.6.3.tar.gz

mkdir abuild &&  cd abuild

../configure --host=$TARGET --prefix=$THIRD_PARTY --with-apr=$THIRD_PARTY

 

 

log4cxx-1.1.0

https://www.apache.org/dyn/closer.cgi/logging/log4cxx/1.1.0/apache-log4cxx-1.1.0.tar.gz

https://dlcdn.apache.org/logging/log4cxx/1.1.0/apache-log4cxx-1.1.0.tar.gz

mkdir build &&  cd build

cmake .. -DCMAKE_INSTALL_PREFIX=$THIRD_PARTY

 

Prepare:

modified FindAPR/FindAPR-Util

line:23

#separate_arguments(_apr_output)

line:52

#PATHS /usr/local/opt/apr/bin $ENV{ProgramFiles}/apr/bin
HITS $ENV{THIRD_PARTY}/bin NO_DEFAULT_PATH)

 

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章