mint에 wgrib2를 설치하려고 할 때 구성 오류가 발생했습니다. 구성: 오류: C 컴파일러가 실행 파일을 생성할 수 없습니다.

mint에 wgrib2를 설치하려고 할 때 구성 오류가 발생했습니다. 구성: 오류: C 컴파일러가 실행 파일을 생성할 수 없습니다.

다음에서 wgrib2를 설치하려고 합니다.https://www.cpc.ncep.noaa.gov/products/wesley/wgrib2/compile_questions.html

링크에 제공된 단계를 따르고 있지만 마지막 명령을 실행하면 make오류가 발생합니다. 출력의 마지막 부분은 다음과 같습니다.

cd "/home/santiago/grib2/libaec-1.0.2" && export CFLAGS="-I/home/santiago/grib2/include -O2 -DIFORT -cxxlib -qopenmp -I/home/santiago/grib2/jasper-1.900.1/src/libjasper/include -I/usr/include " && ./configure --disable-shared --prefix=/home/santiago/grib2 && make check install
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 gcc... icc
checking whether the C compiler works... no
configure: error: in `/home/santiago/grib2/libaec-1.0.2':
configure: error: C compiler cannot create executables
See `config.log' for more details
makefile:657: recipe for target '/home/santiago/grib2/lib/libaec.a' failed
make: *** [/home/santiago/grib2/lib/libaec.a] Error 77

주위를 둘러보았 config.log으나 무엇을 해야 할지 전혀 감이 오지 않았습니다.

 This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.

It was created by libaec configure 1.0.2, which was
generated by GNU Autoconf 2.69.  Invocation command line was

  $ ./configure --disable-shared --prefix=/home/santiago/grib2

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

hostname = rossby
uname -m = x86_64
uname -r = 5.3.0-46-generic
uname -s = Linux
uname -v = #38~18.04.1-Ubuntu SMP Tue Mar 31 04:17:56 UTC 2020

/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: /usr/local/sbin
PATH: /usr/local/bin
PATH: /usr/sbin
PATH: /usr/bin
PATH: /sbin
PATH: /bin
PATH: /usr/games
PATH: /usr/local/games
PATH: /snap/bin


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

configure:2423: checking build system type
configure:2437: result: x86_64-pc-linux-gnu
configure:2457: checking host system type
configure:2470: result: x86_64-pc-linux-gnu
configure:2511: checking how to print strings
configure:2538: result: printf
configure:2610: checking for gcc
configure:2637: result: icc
configure:2866: checking for C compiler version
configure:2875: icc --version >&5
./configure: line 2877: icc: command not found
configure:2886: $? = 127
configure:2875: icc -v >&5
./configure: line 2877: icc: command not found
configure:2886: $? = 127
configure:2875: icc -V >&5
./configure: line 2877: icc: command not found
configure:2886: $? = 127
configure:2875: icc -qversion >&5
./configure: line 2877: icc: command not found
configure:2886: $? = 127
configure:2906: checking whether the C compiler works
configure:2928: icc -I/home/santiago/grib2/include -O2 -DIFORT -cxxlib -qopenmp -I/home/santiago/grib2/jasper-1.900.1/src/libjasper/include -I/usr/include    conftest.c  >&5
./configure: line 2930: icc: command not found
configure:2932: $? = 127
configure:2970: result: no
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME "libaec"
| #define PACKAGE_TARNAME "libaec"
| #define PACKAGE_VERSION "1.0.2"
| #define PACKAGE_STRING "libaec 1.0.2"
| #define PACKAGE_BUGREPORT "[email protected]"
| #define PACKAGE_URL ""
| /* end confdefs.h.  */
| 
| int
| main ()
| {
| 
|   ;
|   return 0;
| }
configure:2975: error: in `/home/santiago/grib2/libaec-1.0.2':
configure:2977: error: C compiler cannot create executables
See `config.log' for more details

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

ac_cv_build=x86_64-pc-linux-gnu
ac_cv_env_CC_set=set
ac_cv_env_CC_value=icc
ac_cv_env_CFLAGS_set=set
ac_cv_env_CFLAGS_value='-I/home/santiago/grib2/include -O2 -DIFORT -cxxlib -qopenmp -I/home/santiago/grib2/jasper-1.900.1/src/libjasper/include -I/usr/include '
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_LT_SYS_LIBRARY_PATH_set=
ac_cv_env_LT_SYS_LIBRARY_PATH_value=
ac_cv_env_build_alias_set=
ac_cv_env_build_alias_value=
ac_cv_env_host_alias_set=
ac_cv_env_host_alias_value=
ac_cv_env_target_alias_set=
ac_cv_env_target_alias_value=
ac_cv_host=x86_64-pc-linux-gnu
ac_cv_prog_ac_ct_CC=icc

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

ACLOCAL=''
AMDEPBACKSLASH=''
AMDEP_FALSE=''
AMDEP_TRUE=''
AMTAR=''
AM_BACKSLASH=''
AM_DEFAULT_V=''
AM_DEFAULT_VERBOSITY=''
AM_V=''
AR=''
AUTOCONF=''
AUTOHEADER=''
AUTOMAKE=''
AWK=''
CC='icc'
CCDEPMODE=''
CFLAGS='-I/home/santiago/grib2/include -O2 -DIFORT -cxxlib -qopenmp -I/home/santiago/grib2/jasper-1.900.1/src/libjasper/include -I/usr/include '
CPP=''
CPPFLAGS=''
CYGPATH_W=''
DEFS=''
DEPDIR=''
DLLTOOL=''
DSYMUTIL=''
DUMPBIN=''
ECHO_C=''
ECHO_N='-n'
ECHO_T=''
EGREP=''
EXEEXT=''
FGREP=''
GREP=''
INSTALL_DATA=''
INSTALL_PROGRAM=''
INSTALL_SCRIPT=''
INSTALL_STRIP_PROGRAM=''
LD=''
LDFLAGS=''
LIBOBJS=''
LIBS=''
LIBTOOL=''
LIPO=''
LN_S=''
LTLIBOBJS=''
LT_SYS_LIBRARY_PATH=''
MAINT=''
MAINTAINER_MODE_FALSE=''
MAINTAINER_MODE_TRUE=''
MAKEINFO=''
MANIFEST_TOOL=''
MKDIR_P=''
NM=''
NMEDIT=''
OBJDUMP=''
OBJEXT=''
OTOOL64=''
OTOOL=''
PACKAGE=''
PACKAGE_BUGREPORT='[email protected]'
PACKAGE_NAME='libaec'
PACKAGE_STRING='libaec 1.0.2'
PACKAGE_TARNAME='libaec'
PACKAGE_URL=''
PACKAGE_VERSION='1.0.2'
PATH_SEPARATOR=':'
RANLIB=''
SED=''
SET_MAKE=''
SHELL='/bin/bash'
STRIP=''
VERSION=''
ac_ct_AR=''
ac_ct_CC='icc'
ac_ct_DUMPBIN=''
am__EXEEXT_FALSE=''
am__EXEEXT_TRUE=''
am__fastdepCC_FALSE=''
am__fastdepCC_TRUE=''
am__include=''
am__isrc=''
am__leading_dot=''
am__nodep=''
am__quote=''
am__tar=''
am__untar=''
bindir='${exec_prefix}/bin'
build='x86_64-pc-linux-gnu'
build_alias=''
build_cpu='x86_64'
build_os='linux-gnu'
build_vendor='pc'
datadir='${datarootdir}'
datarootdir='${prefix}/share'
docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
dvidir='${docdir}'
exec_prefix='NONE'
host='x86_64-pc-linux-gnu'
host_alias=''
host_cpu='x86_64'
host_os='linux-gnu'
host_vendor='pc'
htmldir='${docdir}'
includedir='${prefix}/include'
infodir='${datarootdir}/info'
install_sh=''
libdir='${exec_prefix}/lib'
libexecdir='${exec_prefix}/libexec'
localedir='${datarootdir}/locale'
localstatedir='${prefix}/var'
mandir='${datarootdir}/man'
mkdir_p=''
oldincludedir='/usr/include'
pdfdir='${docdir}'
prefix='/home/santiago/grib2'
program_transform_name='s,x,x,'
psdir='${docdir}'
sbindir='${exec_prefix}/sbin'
sharedstatedir='${prefix}/com'
sysconfdir='${prefix}/etc'
target_alias=''

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

/* confdefs.h */
#define PACKAGE_NAME "libaec"
#define PACKAGE_TARNAME "libaec"
#define PACKAGE_VERSION "1.0.2"
#define PACKAGE_STRING "libaec 1.0.2"
#define PACKAGE_BUGREPORT "[email protected]"

내 시스템 정보는 다음과 같습니다.

  Operating System: Linux Mint 19.3
            Kernel: Linux 5.3.0-46-generic
      Architecture: x86-64

편집하다:

출력 을 추가 type -a cc하고echo $CCls -Alh $(command -v cc)

type -a cc
cc is /usr/bin/cc

echo $CC
icc

ls -Alh $(command -v cc)
lrwxrwxrwx 1 root root 20 mar 28 13:37 /usr/bin/cc -> /etc/alternatives/cc

답변1

CC이를 설정했으므로 스크립트 iccconfigure이를 사용하려는 것으로 가정하고 icc설치되지 않았기 때문에 실패합니다.

이를 설정 해제 CC하거나 Intel 컴파일러(제공 icc)를 설치해야 합니다. icc설치되었지만 컴퓨터에 설치되어 있지 않은 PATH경우 전체 CC경로를 제공해야 합니다 icc.

관련 정보