升级到Mac OS Catalina后,可能无法安装各种R软件包

时间:2020-01-07 14:38:57

标签: r c macos gcc macos-catalina

已经搜索了好几天。。还更新了Xcode,包括命令行工具,我尝试了各种SDK,但未成功。有人找到解决方案了吗?该错误是否有可能是由于Apple不再支持32位程序而导致各种R包不起作用..?

谢谢!

我的rstudio日志:

> install.packages("copula")
also installing the dependency ‘gsl’

trying URL 'https://cran.rstudio.com/src/contrib/gsl_2.1-6.tar.gz'
Content type 'application/x-gzip' length 189794 bytes (185 KB)
==================================================
downloaded 185 KB

trying URL 'https://cran.rstudio.com/src/contrib/copula_0.999-19.1.tar.gz'
Content type 'application/x-gzip' length 5529710 bytes (5.3 MB)
==================================================
downloaded 5.3 MB

* installing *source* package ‘gsl’ ...
** package ‘gsl’ successfully unpacked and MD5 sums checked
** using staged installation
checking for gsl-config... /Users/Philip/opt/anaconda3/bin/gsl-config
checking if GSL version >= 2.1... checking for gcc... x86_64-apple-darwin13.4.0-clang
checking whether the C compiler works... no
configure: error: in `/private/var/folders/v4/0ddh56_173b0vtx6gkypz1d00000gn/T/RtmpmcvvFa/R.INSTALL10b792e7e213f/gsl':
configure: error: C compiler cannot create executables
See `config.log' for more details
ERROR: configuration failed for package ‘gsl’
* removing ‘/Users/Philip/opt/anaconda3/lib/R/library/gsl’
Warning in install.packages :
  installation of package ‘gsl’ had non-zero exit status
ERROR: dependency ‘gsl’ is not available for package ‘copula’
* removing ‘/Users/Philip/opt/anaconda3/lib/R/library/copula’
Warning in install.packages :
  installation of package ‘copula’ had non-zero exit status

The downloaded source packages are in
    ‘/private/var/folders/v4/0ddh56_173b0vtx6gkypz1d00000gn/T/RtmpC6BV8X/downloaded_packages’
Updating HTML index of packages in '.Library'
Making 'packages.html' ... done

会话:

> sessionInfo()
R version 3.6.1 (2019-07-05)
Platform: x86_64-apple-darwin13.4.0 (64-bit)
Running under: macOS Catalina 10.15.2

Matrix products: default
BLAS:   /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /Users/Philip/opt/anaconda3/lib/R/lib/libRblas.dylib

locale:
[1] nl_NL.UTF-8/nl_NL.UTF-8/nl_NL.UTF-8/C/nl_NL.UTF-8/nl_NL.UTF-8

attached base packages:
[1] stats     graphics  grDevices utils     datasets  methods   base     

loaded via a namespace (and not attached):
[1] compiler_3.6.1 tools_3.6.1    yaml_2.2.0   

我的Home / R. / Makevars文件中也有以下设置:

# clang: start
CFLAGS=-isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk
CCFLAGS=-isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk
CXXFLAGS=-isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk
CPPFLAGS=-isysroot /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk -I/usr/local/include

SHLIB_CXXLDFLAGS+=-Wl,-rpath,${R_HOME}/lib ${R_HOME}/lib/libc++abi.1.dylib
SHLIB_CXX14LDFLAGS+=-Wl,-rpath,${R_HOME}/lib ${R_HOME}/lib/libc++abi.1.dylib
# clang: end

在Oo.oO之后,我得到了类似的错误:

(base) MacBook-Pro-van-Philip:gsl-2.6 Philip$ ./configure --prefix=$HOME/opt/usr/local
checking for a BSD-compatible install... /usr/bin/install -c
checking whether build environment is sane... yes
checking for a thread-safe mkdir -p... ./install-sh -c -d
checking for gawk... no
checking for mawk... no
checking for nawk... no
checking for awk... awk
checking whether make sets $(MAKE)... yes
checking whether make supports nested variables... yes
checking whether to enable maintainer-specific portions of Makefiles... no
checking for a sed that does not truncate output... /usr/bin/sed
checking whether make sets $(MAKE)... (cached) yes
checking build system type... x86_64-apple-darwin19.2.0
checking host system type... x86_64-apple-darwin19.2.0
checking for gcc... x86_64-apple-darwin13.4.0-clang
checking whether the C compiler works... no
configure: error: in `/Users/Philip/opt/src/gsl-2.6':
configure: error: C compiler cannot create executables
See `config.log' for more details

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 gsl configure 2.6, which was
generated by GNU Autoconf 2.69.  Invocation command line was

  $ ./configure --prefix=/Users/Philip/opt/usr/local

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

hostname = MacBook-Pro-van-Philip.local
uname -m = x86_64
uname -r = 19.2.0
uname -s = Darwin
uname -v = Darwin Kernel Version 19.2.0: Sat Nov  9 03:47:04 PST 2019; root:xnu-6153.61.1~20/RELEASE_X86_64

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

/bin/arch              = unknown
/usr/bin/arch -k       = unknown
/usr/convex/getsysinfo = unknown
/usr/bin/hostinfo      = Mach kernel version:
     Darwin Kernel Version 19.2.0: Sat Nov  9 03:47:04 PST 2019; root:xnu-6153.61.1~20/RELEASE_X86_64
Kernel configured for up to 8 processors.
4 processors are physically available.
8 processors are logically available.
Processor type: x86_64h (Intel x86-64h Haswell)
Processors active: 0 1 2 3 4 5 6 7
Primary memory available: 16.00 gigabytes
Default processor set: 370 tasks, 1330 threads, 8 processors
Load average: 2.01, Mach factor: 6.01
/bin/machine           = unknown
/usr/bin/oslevel       = unknown
/bin/universe          = unknown

PATH: /usr/local/opt/anaconda3/bin
PATH: /opt/local/bin
PATH: /opt/local/sbin
PATH: /Users/Philip/anaconda3/bin
PATH: /Users/Philip/anaconda/bin
PATH: /Library/Frameworks/Python.framework/Versions/3.6/bin
PATH: /Users/Philip/anaconda/bin
PATH: /usr/local/bin
PATH: /usr/bin
PATH: /bin
PATH: /usr/sbin
PATH: /sbin
PATH: /Library/TeX/texbin
PATH: /usr/local/MacGPG2/bin
PATH: /opt/X11/bin
PATH: /usr/local/opt/anaconda3/bin
PATH: /opt/local/bin
PATH: /opt/local/sbin
PATH: /Users/Philip/anaconda3/bin
PATH: /Users/Philip/anaconda/bin
PATH: /Library/Frameworks/Python.framework/Versions/3.6/bin
PATH: /Users/Philip/opt/anaconda3/bin/r
PATH: /usr/local/clang8/bin
PATH: /Users/Philip/opt/anaconda3/bin
PATH: /usr/local/opt/anaconda3/condabin
PATH: ../../usr/bin


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

configure:2381: checking for a BSD-compatible install
configure:2449: result: /usr/bin/install -c
configure:2460: checking whether build environment is sane
configure:2515: result: yes
configure:2666: checking for a thread-safe mkdir -p
configure:2705: result: ./install-sh -c -d
configure:2712: checking for gawk
configure:2742: result: no
configure:2712: checking for mawk
configure:2742: result: no
configure:2712: checking for nawk
configure:2742: result: no
configure:2712: checking for awk
configure:2728: found /usr/bin/awk
configure:2739: result: awk
configure:2750: checking whether make sets $(MAKE)
configure:2772: result: yes
configure:2801: checking whether make supports nested variables
configure:2818: result: yes
configure:2905: checking whether to enable maintainer-specific portions of Makefiles
configure:2914: result: no
configure:2952: checking for a sed that does not truncate output
configure:3016: result: /usr/bin/sed
configure:3028: checking whether make sets $(MAKE)
configure:3050: result: yes
configure:3064: checking build system type
configure:3078: result: x86_64-apple-darwin19.2.0
configure:3098: checking host system type
configure:3111: result: x86_64-apple-darwin19.2.0
configure:3186: checking for gcc
configure:3213: result: x86_64-apple-darwin13.4.0-clang
configure:3442: checking for C compiler version
configure:3451: x86_64-apple-darwin13.4.0-clang --version >&5
clang version 4.0.1 (tags/RELEASE_401/final)
Target: x86_64-apple-darwin13.4.0
Thread model: posix
InstalledDir: /Users/Philip/opt/anaconda3/bin
configure:3462: $? = 0
configure:3451: x86_64-apple-darwin13.4.0-clang -v >&5
clang version 4.0.1 (tags/RELEASE_401/final)
Target: x86_64-apple-darwin13.4.0
Thread model: posix
InstalledDir: /Users/Philip/opt/anaconda3/bin
configure:3462: $? = 0
configure:3451: x86_64-apple-darwin13.4.0-clang -V >&5
clang-4.0: error: argument to '-V' is missing (expected 1 value)
clang-4.0: error: no input files
configure:3462: $? = 1
configure:3451: x86_64-apple-darwin13.4.0-clang -qversion >&5
clang-4.0: error: unknown argument: '-qversion'
clang-4.0: error: no input files
configure:3462: $? = 1
configure:3482: checking whether the C compiler works
configure:3504: x86_64-apple-darwin13.4.0-clang -march=core2 -mtune=haswell -mssse3 -ftree-vectorize -fPIC -fPIE -fstack-protector-strong -O2 -pipe -D_FORTIFY_SOURCE=2 -mmacosx-version-min=10.9 -Wl,-pie -Wl,-headerpad_max_install_names -Wl,-dead_strip_dylibs conftest.c  >&5
ld: warning: ignoring file /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/lib/libSystem.tbd, file was built for unsupported file format ( 0x2D 0x2D 0x2D 0x20 0x21 0x74 0x61 0x70 0x69 0x2D 0x74 0x62 0x64 0x2D 0x76 0x33 ) which is not the architecture being linked (x86_64): /Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/lib/libSystem.tbd
ld: dynamic main executables must link with libSystem.dylib for architecture x86_64
clang-4.0: error: linker command failed with exit code 1 (use -v to see invocation)
configure:3508: $? = 1
configure:3546: result: no
configure: failed program was:
| /* confdefs.h */
| #define PACKAGE_NAME "gsl"
| #define PACKAGE_TARNAME "gsl"
| #define PACKAGE_VERSION "2.6"
| #define PACKAGE_STRING "gsl 2.6"
| #define PACKAGE_BUGREPORT ""
| #define PACKAGE_URL ""
| #define PACKAGE "gsl"
| #define VERSION "2.6"
| #define RELEASED /**/
| /* end confdefs.h.  */
| 
| int
| main ()
| {
| 
|   ;
|   return 0;
| }
configure:3551: error: in `/Users/Philip/opt/src/gsl-2.6':
configure:3553: error: C compiler cannot create executables
See `config.log' for more details

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

ac_cv_build=x86_64-apple-darwin19.2.0
ac_cv_env_CC_set=set
ac_cv_env_CC_value=x86_64-apple-darwin13.4.0-clang
ac_cv_env_CFLAGS_set=set
ac_cv_env_CFLAGS_value='-march=core2 -mtune=haswell -mssse3 -ftree-vectorize -fPIC -fPIE -fstack-protector-strong -O2 -pipe'
ac_cv_env_CPPFLAGS_set=set
ac_cv_env_CPPFLAGS_value='-D_FORTIFY_SOURCE=2 -mmacosx-version-min=10.9'
ac_cv_env_CPP_set=
ac_cv_env_CPP_value=
ac_cv_env_LDFLAGS_set=set
ac_cv_env_LDFLAGS_value='-Wl,-pie -Wl,-headerpad_max_install_names -Wl,-dead_strip_dylibs'
ac_cv_env_LIBS_set=
ac_cv_env_LIBS_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-apple-darwin19.2.0
ac_cv_path_SED=/usr/bin/sed
ac_cv_path_install='/usr/bin/install -c'
ac_cv_prog_AWK=awk
ac_cv_prog_ac_ct_CC=x86_64-apple-darwin13.4.0-clang
ac_cv_prog_make_make_set=yes
am_cv_make_support_nested_variables=yes

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

ACLOCAL='${SHELL} /Users/Philip/opt/src/gsl-2.6/missing aclocal-1.13'
AMDEPBACKSLASH=''
AMDEP_FALSE=''
AMDEP_TRUE=''
AMTAR='$${TAR-tar}'
AM_BACKSLASH='\'
AM_DEFAULT_V='$(AM_DEFAULT_VERBOSITY)'
AM_DEFAULT_VERBOSITY='1'
AM_V='$(V)'
AR='/Users/Philip/opt/anaconda3/bin/x86_64-apple-darwin13.4.0-ar'
AS='/Users/Philip/opt/anaconda3/bin/x86_64-apple-darwin13.4.0-as'
AUTOCONF='${SHELL} /Users/Philip/opt/src/gsl-2.6/missing autoconf'
AUTOHEADER='${SHELL} /Users/Philip/opt/src/gsl-2.6/missing autoheader'
AUTOMAKE='${SHELL} /Users/Philip/opt/src/gsl-2.6/missing automake-1.13'
AWK='awk'
CC='x86_64-apple-darwin13.4.0-clang'
CCDEPMODE=''
CFLAGS='-march=core2 -mtune=haswell -mssse3 -ftree-vectorize -fPIC -fPIE -fstack-protector-strong -O2 -pipe'
CPP=''
CPPFLAGS='-D_FORTIFY_SOURCE=2 -mmacosx-version-min=10.9'
CYGPATH_W='echo'
DEFS=''
DEPDIR=''
DLLTOOL=''
DSYMUTIL=''
DUMPBIN=''
ECHO_C='\c'
ECHO_N=''
ECHO_T=''
EGREP=''
EXEEXT=''
FGREP=''
GREP=''
GSLCBLAS_LDFLAGS=''
GSL_CFLAGS=''
GSL_LDFLAGS=''
GSL_LIBADD=''
GSL_LIBM=''
GSL_LIBS=''
GSL_LT_CBLAS_VERSION='0:0:0'
GSL_LT_VERSION='25:0:0'
GSL_MAJOR_VERSION='2'
GSL_MINOR_VERSION='6'
HAVE_AIX_IEEE_INTERFACE=''
HAVE_DARWIN86_IEEE_INTERFACE=''
HAVE_DARWIN_IEEE_INTERFACE=''
HAVE_FREEBSD_IEEE_INTERFACE=''
HAVE_GNUM68K_IEEE_INTERFACE=''
HAVE_GNUPPC_IEEE_INTERFACE=''
HAVE_GNUSPARC_IEEE_INTERFACE=''
HAVE_GNUX86_IEEE_INTERFACE=''
HAVE_HPUX11_IEEE_INTERFACE=''
HAVE_HPUX_IEEE_INTERFACE=''
HAVE_IRIX_IEEE_INTERFACE=''
HAVE_NETBSD_IEEE_INTERFACE=''
HAVE_OPENBSD_IEEE_INTERFACE=''
HAVE_OS2EMX_IEEE_INTERFACE=''
HAVE_SOLARIS_IEEE_INTERFACE=''
HAVE_SUNOS4_IEEE_INTERFACE=''
HAVE_TRU64_IEEE_INTERFACE=''
INSTALL_DATA='${INSTALL} -m 644'
INSTALL_PROGRAM='${INSTALL}'
INSTALL_SCRIPT='${INSTALL}'
INSTALL_STRIP_PROGRAM='$(install_sh) -c -s'
LD='/Users/Philip/opt/anaconda3/bin/x86_64-apple-darwin13.4.0-ld'
LDFLAGS='-Wl,-pie -Wl,-headerpad_max_install_names -Wl,-dead_strip_dylibs'
LIBM=''
LIBOBJS=''
LIBS=''
LIBTOOL='/Users/Philip/opt/anaconda3/bin/x86_64-apple-darwin13.4.0-libtool'
LIPO='/Users/Philip/opt/anaconda3/bin/x86_64-apple-darwin13.4.0-lipo'
LN_S='ln -s'
LTLIBOBJS=''
MAINT='#'
MAINTAINER_MODE_FALSE=''
MAINTAINER_MODE_TRUE='#'
MAKEINFO='${SHELL} /Users/Philip/opt/src/gsl-2.6/missing makeinfo'
MANIFEST_TOOL=''
MKDIR_P='./install-sh -c -d'
NM='/Users/Philip/opt/anaconda3/bin/x86_64-apple-darwin13.4.0-nm'
NMEDIT='/Users/Philip/opt/anaconda3/bin/x86_64-apple-darwin13.4.0-nmedit'
OBJDUMP=''
OBJEXT=''
OTOOL64=''
OTOOL='/Users/Philip/opt/anaconda3/bin/x86_64-apple-darwin13.4.0-otool'
PACKAGE='gsl'
PACKAGE_BUGREPORT=''
PACKAGE_NAME='gsl'
PACKAGE_STRING='gsl 2.6'
PACKAGE_TARNAME='gsl'
PACKAGE_URL=''
PACKAGE_VERSION='2.6'
PATH_SEPARATOR=':'
RANLIB='/Users/Philip/opt/anaconda3/bin/x86_64-apple-darwin13.4.0-ranlib'
SED='/usr/bin/sed'
SET_MAKE=''
SHELL='/bin/sh'
STRIP='/Users/Philip/opt/anaconda3/bin/x86_64-apple-darwin13.4.0-strip'
VERSION='2.6'
ac_ct_AR=''
ac_ct_CC='x86_64-apple-darwin13.4.0-clang'
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='$${TAR-tar} chof - "$$tardir"'
am__untar='$${TAR-tar} xf -'
bindir='${exec_prefix}/bin'
build='x86_64-apple-darwin19.2.0'
build_alias=''
build_cpu='x86_64'
build_os='darwin19.2.0'
build_vendor='apple'
datadir='${datarootdir}'
datarootdir='${prefix}/share'
docdir='${datarootdir}/doc/${PACKAGE_TARNAME}'
dvidir='${docdir}'
exec_prefix='NONE'
host='x86_64-apple-darwin19.2.0'
host_alias=''
host_cpu='x86_64'
host_os='darwin19.2.0'
host_vendor='apple'
htmldir='${docdir}'
includedir='${prefix}/include'
infodir='${datarootdir}/info'
install_sh='${SHELL} /Users/Philip/opt/src/gsl-2.6/install-sh'
libdir='${exec_prefix}/lib'
libexecdir='${exec_prefix}/libexec'
localedir='${datarootdir}/locale'
localstatedir='${prefix}/var'
mandir='${datarootdir}/man'
mkdir_p='$(MKDIR_P)'
oldincludedir='/usr/include'
pdfdir='${docdir}'
prefix='/Users/Philip/opt/usr/local'
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 "gsl"
#define PACKAGE_TARNAME "gsl"
#define PACKAGE_VERSION "2.6"
#define PACKAGE_STRING "gsl 2.6"
#define PACKAGE_BUGREPORT ""
#define PACKAGE_URL ""
#define PACKAGE "gsl"
#define VERSION "2.6"
#define RELEASED /**/

configure: exit 77

2 个答案:

答案 0 :(得分:0)

2020-01-07 16:29:51.031 DEBUG 24915 --- [           main] o.s.b.d.LoggingFailureAnalysisReporter   : Application failed to start due to an exception

org.springframework.beans.factory.BeanCurrentlyInCreationException: Error creating bean with name 'receiverOptions': Requested bean is currently in creation: Is there an unresolvable circular reference?
    at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.beforeSingletonCreation(DefaultSingletonBeanRegistry.java:339) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:215) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:321) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:202) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.config.DependencyDescriptor.resolveCandidate(DependencyDescriptor.java:276) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:1287) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:1207) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.ConstructorResolver.resolveAutowiredArgument(ConstructorResolver.java:885) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.ConstructorResolver.createArgumentArray(ConstructorResolver.java:789) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:539) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1338) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1177) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:557) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:517) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:323) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:321) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:202) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.config.DependencyDescriptor.resolveCandidate(DependencyDescriptor.java:276) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.DefaultListableBeanFactory.addCandidateEntry(DefaultListableBeanFactory.java:1503) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.DefaultListableBeanFactory.findAutowireCandidates(DefaultListableBeanFactory.java:1467) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveMultipleBeans(DefaultListableBeanFactory.java:1386) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.DefaultListableBeanFactory.doResolveDependency(DefaultListableBeanFactory.java:1245) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.DefaultListableBeanFactory.resolveDependency(DefaultListableBeanFactory.java:1207) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.ConstructorResolver.resolveAutowiredArgument(ConstructorResolver.java:885) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.ConstructorResolver.createArgumentArray(ConstructorResolver.java:789) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.ConstructorResolver.instantiateUsingFactoryMethod(ConstructorResolver.java:539) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.instantiateUsingFactoryMethod(AbstractAutowireCapableBeanFactory.java:1338) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBeanInstance(AbstractAutowireCapableBeanFactory.java:1177) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:557) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:517) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:323) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:321) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:202) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.beans.factory.support.DefaultListableBeanFactory.preInstantiateSingletons(DefaultListableBeanFactory.java:879) ~[spring-beans-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:878) ~[spring-context-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:550) ~[spring-context-5.2.2.RELEASE.jar:5.2.2.RELEASE]
    at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:747) ~[spring-boot-2.2.2.RELEASE.jar:2.2.2.RELEASE]
    at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:397) ~[spring-boot-2.2.2.RELEASE.jar:2.2.2.RELEASE]
    at org.springframework.boot.SpringApplication.run(SpringApplication.java:315) ~[spring-boot-2.2.2.RELEASE.jar:2.2.2.RELEASE]
    at org.springframework.boot.SpringApplication.run(SpringApplication.java:1226) ~[spring-boot-2.2.2.RELEASE.jar:2.2.2.RELEASE]
    at org.springframework.boot.SpringApplication.run(SpringApplication.java:1215) ~[spring-boot-2.2.2.RELEASE.jar:2.2.2.RELEASE]
    at com.example.demo.DemoApplication.main(DemoApplication.java:19) ~[main/:na]

更新

在您的情况下,看起来情况有点混乱。您的> mkdir -p ~/opt/src > cd ~/opt/src > curl -O http://mirror.us-midwest-1.nexcess.net/gnu/gsl/gsl-2.6.tar.gz > tar zxf gsl-2.6.tar.gz > cd gsl-2.6 > ./configure --prefix=$HOME/opt/usr/local > make > make install > export CFLAGS="-I$HOME/opt/usr/local/include" > export LDFLAGS="-L$HOME/opt/usr/local/lib -lgsl -lgslcblas" > R R version 3.6.1 (2019-07-05) -- "Action of the Toes" Copyright (C) 2019 The R Foundation for Statistical Computing Platform: x86_64-apple-darwin15.6.0 (64-bit) ... ... > install.packages("gsl") ... ... ... There is a binary version available but the source version is later: binary source needs_compilation gsl 1.9-10.3 2.1-6 TRUE Do you want to install from sources the package which needs compilation? (Yes/no/cancel) yes ... ... > install.packages("copula") > library(copula) > 被解析为gcc

尝试编译此代码

x86_64-apple-darwin13.4.0-clang

遵循方式

/* confdefs.h */
#define PACKAGE_NAME "gsl"
#define PACKAGE_TARNAME "gsl"
#define PACKAGE_VERSION "2.6"
#define PACKAGE_STRING "gsl 2.6"
#define PACKAGE_BUGREPORT ""
#define PACKAGE_URL ""
#define PACKAGE "gsl"
#define VERSION "2.6"
#define RELEASED /**/
/* end confdefs.h.  */

int
main ()
{
  ;
  return 0;
}

使用> clang -march=core2 -mtune=haswell -mssse3 -ftree-vectorize -fPIC -fPIE -fstack-protector-strong -O2 -pipe -D_FORTIFY_SOURCE=2 -mmacosx-version-min=10.9 -Wl,-pie -Wl,-headerpad_max_install_names -Wl,-dead_strip_dylibs main.c 安装中的工具

然后,尝试像这样设置XCode编译器。

C

在配置export CC="/usr/bin/clang" 之前。

答案 1 :(得分:0)

我能够在 macOS Catalina R-4.0.2 中构建copula。 我先用gsl安装了brew install gsl,然后又回到R来构建copula

我的~/.R/Makevars有点长,但我希望对您有所帮助:

# --------
# Makevars
# --------

# General note
# - need to repeat options across C++ flavors (e.g., 11, 14)

# Homebrew bin / opt / lib locations
HB=/usr/local/bin
HO=/usr/local/opt
HL=/usr/local/lib
HI=/usr/local/include

# MacOS Xcode header location (August 2019)
# (do "xcrun -show-sdk-path" in terminal to get path; change if yours is different)
# (or xcrun --sdk macosx --show-sdk-path)
# XH=/Library/Developer/CommandLineTools/SDKs/MacOSX10.14.sdk   # Mojave
XH=/Library/Developer/CommandLineTools/SDKs/MacOSX10.15.sdk     # Catalina

# ccache
CCACHE=$(HB)/ccache

# Make using all cores (set # to # of cores on your machine)
MAKE=make -j4

# GNU version (August 2019)
GNU_VER=10

# LLVM (Clang) compiler options
CC=$(CCACHE) $(HO)/llvm/bin/clang
CXX=$(CC)++
CXX98=$(CC)++
CXX11=$(CC)++
CXX14=$(CC)++
CXX17=$(CC)++

# FORTRAN
FC=$(CCACHE) $(HB)/gfortran-$(GNU_VER)
F77=$(FC)
FLIBS=-L$(HL)/gcc/$(GNU_VER) -lgfortran -lquadmath -lm

# STD libraries
CXX1XSTD=-std=c++0x
CXX11STD=-std=c++11
CXX14STD=-std=c++14
CXX17STD=-std=c++17

# FLAGS
STD_FLAGS=-g -O3 -Wall -pedantic -mtune=native -pipe
CFLAGS=$(STD_FLAGS)
CXXFLAGS=$(STD_FLAGS)
CXX98FLAGS=$(STD_FLAGS)
CXX11FLAGS=$(STD_FLAGS)
CXX14FLAGS=$(STD_FLAGS)
CXX17FLAGS=$(STD_FLAGS)

# Preprocessor FLAGS
# NB: -isysroot refigures the include path to the Xcode SDK we set above
CPPFLAGS=-isysroot $(XH) -I$(HI) \
    -I$(HO)/llvm/include -I$(HO)/openssl/include \
    -I$(HO)/gettext/include    -I$(HO)/tcl-tk/include

# Linker flags (suggested by homebrew)
LDFLAGS+=-L$(HO)/llvm/lib -Wl,-rpath,$(HO)/llvm/lib

# Flags for OpenMP support that should allow packages that want to use
# OpenMP to do so (data.table), and other packages that bork with
# -fopenmp flag (stringi) to be left alone
SHLIB_OPENMP_CFLAGS=-fopenmp
SHLIB_OPENMP_CXXFLAGS=-fopenmp
SHLIB_OPENMP_CXX98FLAGS=-fopenmp
SHLIB_OPENMP_CXX11FLAGS=-fopenmp
SHLIB_OPENMP_CXX14FLAGS=-fopenmp
SHLIB_OPENMP_CXX17FLAGS=-fopenmp
SHLIB_OPENMP_FCFLAGS=-fopenmp
SHLIB_OPENMP_FFLAGS=-fopenmp

您将可以在下面的链接中找到更详细的说明。它适用于R-4.0.2的Mojave和Catalina,适用于rattleboostMASSHmiscRccppArmadillo等软件包。< / p>

来源https://www.btskinner.io/code/install-r-with-openblas-and-openmp-on-macos-mojave/