Warning: file_get_contents(/data/phpspider/zhask/data//catemap/0/mercurial/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
无法识别arm交叉编译--sysroot选项。(Eclipse)_Eclipse_Eclipse Plugin_Arm_Cross Compiling_Ld - Fatal编程技术网

无法识别arm交叉编译--sysroot选项。(Eclipse)

无法识别arm交叉编译--sysroot选项。(Eclipse),eclipse,eclipse-plugin,arm,cross-compiling,ld,Eclipse,Eclipse Plugin,Arm,Cross Compiling,Ld,我正在尝试对autotools项目使用sysroot进行arm交叉编译 CC=arm-linux-gnueabihf-gcc --with-sysroot=/opt/sysroot/dir \ --host=arm-linux-gnueabihf --sysroot=/opt/sysroot/dir --prefix=/some/dir 但在eclipse插件中,它显示了--sysroot选项无法识别,但相同的命令在终端中工作正常 ERROR: configure: error: unr

我正在尝试对
autotools
项目使用
sysroot
进行arm交叉编译

CC=arm-linux-gnueabihf-gcc --with-sysroot=/opt/sysroot/dir \
   --host=arm-linux-gnueabihf --sysroot=/opt/sysroot/dir --prefix=/some/dir
但在eclipse插件中,它显示了
--sysroot
选项无法识别,但相同的命令在终端中工作正常

ERROR:
configure: error: unrecognized option: --sysroot=/opt/sysroot/dir
configure: error: unrecognized option: --sysroot=/opt/sysroot/dir
Try ./configure --help' for more information
如果我在eclipse中删除了
--sysroot
选项,那么
autogen
工作正常,但是我得到了以下链接器错误

/usr/lib/gcc-cross/arm-linux-gnueabihf/4.8/../../../../arm-linux-gnueabihf/bin/ld: skipping incompatible /usr/lib/../lib/libwebkit_clutter-0.so when searching for -lwebkit_clutter-0
/usr/lib/gcc-cross/arm-linux-gnueabihf/4.8/../../../../arm-linux-gnueabihf/bin/ld: skipping incompatible //usr/lib/libwebkit_clutter-0.so when searching for -lwebkit_clutter-0
make[2]: Leaving directory `/home/dir/workspace/Sharukh/sources/applications'
/usr/lib/gcc-cross/arm-linux-gnueabihf/4.8/../../../../arm-linux-gnueabihf/bin/ld: cannot find -lwebkit_clutter-0
make[1]: Leaving directory `/home/dir/workspace/Sharukh/sources'
/usr/lib/gcc-cross/arm-linux-gnueabihf/4.8/../../../../arm-linux-gnueabihf/bin/ld: skipping incompatible /usr/lib/../lib/libwebkit_clutter_mx.so when searching for -lwebkit_clutter_mx
/usr/lib/gcc-cross/arm-linux-gnueabihf/4.8/../../../../arm-linux-gnueabihf/bin/ld: skipping incompatible //usr/lib/libwebkit_clutter_mx.so when searching for -lwebkit_clutter_mx
/usr/lib/gcc-cross/arm-linux-gnueabihf/4.8/../../../../arm-linux-gnueabihf/bin/ld: cannot find -lwebkit_clutter_mx
/usr/lib/gcc-cross/arm-linux-gnueabihf/4.8/../../../../arm-linux-gnueabihf/bin/ld: skipping incompatible /lib/../lib/libcgroup.so when searching for -lcgroup
/usr/lib/gcc-cross/arm-linux-gnueabihf/4.8/../../../../arm-linux-gnueabihf/bin/ld: skipping incompatible //lib/libcgroup.so when searching for -lcgroup
/usr/lib/gcc-cross/arm-linux-gnueabihf/4.8/../../../../arm-linux-gnueabihf/bin/ld: cannot find -lcgroup
collect2: error: ld returned 1 exit status
make[2]: *** [bin_Sharukh] Error 1
make[1]: *** [install-recursive] Error 1
make: *** [install-recursive] Error 1

我遗漏了什么?

您真的不需要使用
--sysroot
,因为
--sysroot
就足够了

您的配置应该是这样的

CC="arm-linux-gnueabihf-gcc" \
CFLAGS="--sysroot=/opt/sysroot/dir" ./configure \
            --prefix=/some/dir \
            --host=arm-linux-gnueabihf

您的目标Linux发行版是什么?你看过吗?它甚至有一个日食。@Sushant:是的,谢谢sushanth。我做了同样的事情,它工作得很好,但我忘了在这里更新它。再次感谢,投票表决:)