求助在为 ArmLinux-Brcm 编译 tar.gz 源码 package 时出现的问题

2016-01-28 10:41:16 +08:00
 ChowDPa02K

鉴于 LZ 路由器的特殊性(博通 ARM 芯片),刷上了 DD-Wrt 之后很多 package 都要在网上找很久 /求大神编译 /自己编译。所以从没深入接触过 Linux 的小白我打算自己编译 unbound (因为完全找不到),能轻易下载到 unbound 的 tar.gz 源码包,根据教程 http://ahui.us/post/netgear-r6300v2-ngrep.html 进行编译,搭建好文件目录。
工具链使用的是 github 上的 https://github.com/jeremyd2019/hndtools-arm-linux-uclibc ,同时在 64 位 Ubuntu 上安装好了 libc6-dev-i386 以及以下包:
build-essential
ccache
flex
gawk
gettext
git
liblzma-dev
libncurses5-dev
libssl-dev
python
subversion
u-boot-tools
unzip
wget
xsltproc
zlib1g-dev
libmpc2

但是在使用 configure 编译的时候很快就报错退出,如图

查看 log 如下:
This file contains any messages produced by compilers while running configure, to aid debugging if configure makes a mistake.

It was created by unbound configure 1.5.7, which was
generated by GNU Autoconf 2.69.  Invocation command line was

  $ ./configure CC=arm-uclibc-linux-2.6.36-gcc CXX=arm-uclibc-linux-2.6.36-g++ AR=arm-uclibc-linux-2.6.36-ar RANLIB=arm-uclibc-linux-2.6.36-ranlib LD=arm-uclibc-linux-2.6.36-ld --prefix=/projects/unbound --host=arm-linux --build=arm --with-pcap-includes=../libpcap-1.4.0

## --------- ##
## Platform. ##
## --------- ##

hostname = ubuntu
uname -m = x86_64
uname -r = 3.19.0-25-generic
uname -s = Linux
uname -v = #26~14.04.1-Ubuntu SMP Fri Jul 24 21:16:20 UTC 2015

/usr/bin/uname -p = unknown
/bin/uname -X     = unknown

/bin/arch              = unknown
/usr/bin/arch -k       = unknown
/usr/convex/getsysinfo = unknown
/usr/bin/hostinfo      = unknown
/bin/machine           = unknown
/usr/bin/oslevel       = unknown
/bin/universe          = unknown

PATH: /projects/hnd/tools/linux/hndtools-arm-linux-uclibc-master/bin
PATH: /usr/local/sbin
PATH: /usr/local/bin
PATH: /usr/sbin
PATH: /usr/bin
PATH: /sbin
PATH: /bin  

## ----------- ##
## Core tests. ##
## ----------- ##

configure:2785: checking for arm-linux-gcc
configure:2812: result: arm-uclibc-linux-2.6.36-gcc
configure:3081: checking for C compiler version
--version
configure:3091: arm-uclibc-linux-2.6.36-gcc --version >&5
arm-uclibc-linux-2.6.36-gcc (Buildroot 2012.02) 4.5.3
Copyright (C) 2010 Free Software Foundation, Inc.
This is free software; see the source for copying conditions.  There is NO
warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.

configure:3102: $? = 0
-v
configure:3091: arm-uclibc-linux-2.6.36-gcc -v >&5
Using built-in specs.
COLLECT_GCC=arm-uclibc-linux-2.6.36-gcc
COLLECT_LTO_WRAPPER=/projects/hnd/tools/linux/hndtools-arm-linux-uclibc-master/bin/../libexec/gcc/arm-brcm-linux-uclibcgnueabi/4.5.3/lto-wrapper
Target: arm-brcm-linux-uclibcgnueabi
Configured with: /projects/toolchains_build/buildroot-2012.02-brcm/output/toolchain/gcc-4.5.3/configure --prefix=/projects/hnd/tools/linux/hndtools-arm-linux-2.6.36-uclibc-4.5.3 --build=i686-pc-linux-gnu --host=i686-pc-linux-gnu --target=arm-brcm-linux-uclibcgnueabi --enable-languages=c,c++ --with-sysroot=/projects/hnd/tools/linux/hndtools-arm-linux-2.6.36-uclibc-4.5.3/arm-brcm-linux-uclibcgnueabi/sysroot --with-build-time-tools=/projects/hnd/tools/linux/hndtools-arm-linux-2.6.36-uclibc-4.5.3/arm-brcm-linux-uclibcgnueabi/bin --disable-__cxa_atexit --enable-target-optspace --disable-libgomp --with-gnu-ld --disable-libssp --disable-multilib --disable-tls --enable-shared --with-gmp=/projects/hnd/tools/linux/hndtools-arm-linux-2.6.36-uclibc-4.5.3 --with-mpfr=/projects/hnd/tools/linux/hndtools-arm-linux-2.6.36-uclibc-4.5.3 --with-mpc=/projects/hnd/tools/linux/hndtools-arm-linux-2.6.36-uclibc-4.5.3 --enable-threads --disable-decimal-float --with-float=soft --with-abi=aapcs-linux --with-arch=armv7-a --with-tune=cortex-a9 --with-pkgversion='Buildroot 2012.02' --with-bugurl=http://bugs.buildroot.net/
Thread model: posix
gcc version 4.5.3 (Buildroot 2012.02) 
configure:3102: $? = 0
-V
configure:3091: arm-uclibc-linux-2.6.36-gcc -V >&5
arm-uclibc-linux-2.6.36-gcc: '-V' option must have argument
configure:3102: $? = 1
-qversion
configure:3091: arm-uclibc-linux-2.6.36-gcc -qversion >&5
arm-uclibc-linux-2.6.36-gcc: unrecognized option '-qversion'
arm-uclibc-linux-2.6.36-gcc: no input files
configure:3102: $? = 1
configure:3122: checking whether the C compiler works
configure:3144: arm-uclibc-linux-2.6.36-gcc    conftest.c  >&5
/projects/hnd/tools/linux/hndtools-arm-linux-uclibc-master/bin/../libexec/gcc/arm-brcm-linux-uclibcgnueabi/4.5.3/cc1: error while loading shared libraries: libmpc.so.2: cannot open shared object file: No such file or directory
configure:3148: $? = 1
configure:3186: result: no
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME "unbound"
| #define PACKAGE_TARNAME "unbound"
| #define PACKAGE_VERSION "1.5.7"
| #define PACKAGE_STRING "unbound 1.5.7"
| #define PACKAGE_BUGREPORT "unbound-bugs@nlnetlabs.nl"
| #define PACKAGE_URL ""
| /* end confdefs.h.  */
| 
| int
| main ()
| {
| 
|   ;
|   return 0;
| }
configure:3191: error: in `/projects/unbound-1.5.7':
configure:3193: error: C compiler cannot create executables
See `config.log' for more details

## ---------------- ##
## Cache variables. ##
## ---------------- ##

ac_cv_env_CC_set=set
ac_cv_env_CC_value=arm-uclibc-linux-2.6.36-gcc
ac_cv_env_CFLAGS_set=
ac_cv_env_CFLAGS_value=
ac_cv_env_CPPFLAGS_set=
ac_cv_env_CPPFLAGS_value=
ac_cv_env_CPP_set=
ac_cv_env_CPP_value=
ac_cv_env_LDFLAGS_set=
ac_cv_env_LDFLAGS_value=
ac_cv_env_LIBS_set=
ac_cv_env_LIBS_value=
ac_cv_env_PYTHON_VERSION_set=
ac_cv_env_PYTHON_VERSION_value=
ac_cv_env_YACC_set=
ac_cv_env_YACC_value=
ac_cv_env_YFLAGS_set=
ac_cv_env_YFLAGS_value=
ac_cv_env_build_alias_set=set
ac_cv_env_build_alias_value=arm
ac_cv_env_host_alias_set=set
ac_cv_env_host_alias_value=arm-linux
ac_cv_env_target_alias_set=
ac_cv_env_target_alias_value=
ac_cv_prog_CC=arm-uclibc-linux-2.6.36-gcc

## ----------------- ##
## Output variables. ##
## ----------------- ##

ALLTARGET=''
AR='arm-uclibc-linux-2.6.36-ar'
AWK=''
CC='arm-uclibc-linux-2.6.36-gcc'
CFLAGS=''
CHECKLOCK_OBJ=''
COMMON_OBJ_ALL_SYMBOLS=''
CONFIG_DATE=''
CPP=''
CPPFLAGS=''
DEFS=''
DEPFLAG=''
DLLTOOL=''
DNSTAP_OBJ=''
DNSTAP_SRC=''
DSYMUTIL=''
DUMPBIN=''
ECHO_C=''
ECHO_N='-n'
ECHO_T=''
EGREP=''
ENABLE_DNSTAP=''
EXEEXT=''
EXTRALINK=''
FGREP=''
GREP=''
HAVE_SSL=''
INSTALLTARGET=''
LD='arm-uclibc-linux-2.6.36-ld'
LDFLAGS=''
LEX=''
LEXLIB=''
LEX_OUTPUT_ROOT=''
LIBOBJS=''
LIBOBJ_WITHOUT_CTIME=''
LIBOBJ_WITHOUT_CTIMEARC4=''
LIBS=''
LIBTOOL=''
LIBUNBOUND_AGE='3'
LIBUNBOUND_CURRENT='5'
LIBUNBOUND_REVISION='10'
LIPO=''
LN_S=''
LTLIBOBJS=''
MANIFEST_TOOL=''
NETBSD_LINTFLAGS=''
NM=''
NMEDIT=''
OBJDUMP=''
OBJEXT=''
OTOOL64=''
OTOOL=''
PACKAGE_BUGREPORT='unbound-bugs@nlnetlabs.nl'
PACKAGE_NAME='unbound'
PACKAGE_STRING='unbound 1.5.7'
PACKAGE_TARNAME='unbound'
PACKAGE_URL=''
PACKAGE_VERSION='1.5.7'
PATH_SEPARATOR=':'
PROTOC_C=''
PTHREAD_CC=''
PTHREAD_CFLAGS=''
PTHREAD_LIBS=''
PYTHON=''
PYTHONMOD_HEADER=''
PYTHONMOD_INSTALL=''
PYTHONMOD_OBJ=''
PYTHONMOD_UNINSTALL=''
PYTHON_CPPFLAGS=''
PYTHON_LDFLAGS=''
PYTHON_SITE_PKG=''
PYTHON_VERSION=''
PYUNBOUND_INSTALL=''
PYUNBOUND_OBJ=''
PYUNBOUND_TARGET=''
PYUNBOUND_UNINSTALL=''
PY_MAJOR_VERSION=''
RANLIB='arm-uclibc-linux-2.6.36-ranlib'
RUNTIME_PATH=''
SED=''
SHELL='/bin/bash'
SOURCEDETERMINE=''
SOURCEFILE=''
SSLLIB=''
STRIP=''
SWIG=''
SWIG_LIB=''
UBSYMS=''
UNBOUND_CHROOT_DIR=''
UNBOUND_EVENT_INSTALL=''
UNBOUND_EVENT_UNINSTALL=''
UNBOUND_PIDFILE=''
UNBOUND_ROOTCERT_FILE=''
UNBOUND_ROOTKEY_FILE=''
UNBOUND_RUN_DIR=''
UNBOUND_SHARE_DIR=''
UNBOUND_USERNAME=''
UNBOUND_VERSION_MAJOR='1'
UNBOUND_VERSION_MICRO='7'
UNBOUND_VERSION_MINOR='5'
WINAPPS=''
WINDRES=''
WIN_CHECKCONF_OBJ_LINK=''
WIN_CONTROL_OBJ_LINK=''
WIN_DAEMON_OBJ=''
WIN_DAEMON_OBJ_LINK=''
WIN_DAEMON_SRC=''
WIN_HOST_OBJ_LINK=''
WIN_UBANCHOR_OBJ_LINK=''
WITH_PYTHONMODULE=''
WITH_PYUNBOUND=''
YACC=''
YFLAGS=''
ac_ct_AR=''
ac_ct_CC=''
ac_ct_DUMPBIN=''
ax_pthread_config=''
bindir='${exec_prefix}/bin'
build='arm'
build_alias='arm'
build_cpu=''
build_os=''
build_vendor=''
datadir='${datarootdir}'
datarootdir='${prefix}/share'
date=''
debug_enabled=''
docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
doxygen=''
dvidir='${docdir}'
exec_prefix='NONE'
host='arm-linux'
host_alias='arm-linux'
host_cpu=''
host_os=''
host_vendor=''
htmldir='${docdir}'
includedir='${prefix}/include'
infodir='${datarootdir}/info'
libdir='${exec_prefix}/lib'
libexecdir='${exec_prefix}/libexec'
libtool=''
localedir='${datarootdir}/locale'
localstatedir='${prefix}/var'
mandir='${datarootdir}/man'
oldincludedir='/usr/include'
opt_dnstap_socket_path=''
pdfdir='${docdir}'
prefix='/projects/unbound'
program_transform_name='s,x,x,'
psdir='${docdir}'
sbindir='${exec_prefix}/sbin'
sharedstatedir='${prefix}/com'
staticexe=''
swig=''
sysconfdir='${prefix}/etc'
target_alias=''
ub_conf_dir=''
ub_conf_file=''
version=''

## ----------- ##
## confdefs.h. ##
## ----------- ##

/* confdefs.h */
#define PACKAGE_NAME "unbound"
#define PACKAGE_TARNAME "unbound"
#define PACKAGE_VERSION "1.5.7"
#define PACKAGE_STRING "unbound 1.5.7"
#define PACKAGE_BUGREPORT "unbound-bugs@nlnetlabs.nl"
#define PACKAGE_URL ""

    configure: exit 77

请问如何解决这样的问题,顺利完成编译?

535 次点击
所在节点    OpenWrt
0 条回复

这是一个专为移动设备优化的页面(即为了让你能够在 Google 搜索结果里秒开这个页面),如果你希望参与 V2EX 社区的讨论,你可以继续到 V2EX 上打开本讨论主题的完整版本。

https://www.v2ex.com/t/253929

V2EX 是创意工作者们的社区,是一个分享自己正在做的有趣事物、交流想法,可以遇见新朋友甚至新机会的地方。

V2EX is a community of developers, designers and creative people.

© 2021 V2EX