为C ++安装li​​bxls库时出错

时间:2019-11-23 09:08:38

标签: c++ excel

我正在尝试在ubuntu中使用c ++代码读取Excel文件,我试图安装Libxls库进行读取,但是在执行步骤{/ 3}中提供的步骤{./configure}时出现以下错误。

checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... /bin/mkdir -p
checking for gawk... gawk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking whether make supports nested variables... (cached) yes
checking build system type... x86_64-pc-linux-gnu
checking host system type... x86_64-pc-linux-gnu
checking how to print strings... printf
checking for style of include used by make... GNU
checking for gcc... gcc
checking whether the C compiler works... yes
checking for C compiler default output file name... a.out
checking for suffix of executables...
checking whether we are cross compiling... configure: error: in `/mnt/e/MIVT/library/libxls':
configure: error: cannot run C compiled programs.
If you meant to cross compile, use `--host'.
See `config.log' for more details

config.log中的详细信息:

configure:3825: checking whether we are cross compiling
configure:3833: gcc -o conftest    conftest.c  >&5
In file included from /usr/include/stdio.h:33:0,
                 from conftest.c:14:
/usr/bin/clang_9.0.0/lib/clang/9.0.0/include/stddef.h:41:39: error: missing binary operator before token "("
 #if !defined(_SIZE_T) || __has_feature(modules)

               ^
/usr/include/stdio.h:739:15: error: expected '=', ',', ';', 'asm' or '__attribute__' before 'fwrite_unlocked'
 extern size_t fwrite_unlocked (const void *__restrict __ptr, size_t __size,
               ^
configure:3837: $? = 1
configure:3844: ./conftest
./configure: line 3846: ./conftest: No such file or directory
configure:3848: $? = 127
configure:3855: error: in `/mnt/e/MIVT/library/libxls':
configure:3857: error: cannot run C compiled programs.
If you meant to cross compile, use `--host'.
See `config.log' for more details

0 个答案:

没有答案