Data.table: macOSの゜ヌスからむンストヌルするずきに゚ラヌが発生したした

䜜成日 2020幎05月01日  Â·  27コメント  Â·  ゜ヌス: Rdatatable/data.table

https://github.com/Rdatatable/data.table/wiki/Installationのすべおの手順に埓い、StackOverflowを怜玢したしたが、Mac 10.14.6の゜ヌスOpenMPサポヌト甚からdata.tableをむンストヌルできたせん。 R4.0で。 ゜ヌスからむンストヌルしようずするず、この゚ラヌが発生し続けたす。

> install.packages("data.table", type="source", Ncpus = 7)
trying URL 'https://cran.us.r-project.org/src/contrib/data.table_1.12.8.tar.gz'
Content type 'application/octet-stream' length 4948391 bytes (4.7 MB)
==================================================
downloaded 4.7 MB
* installing *source* package ‘data.table’ ...
** package ‘data.table’ successfully unpacked and MD5 sums checked
** using staged installation
zlib 1.2.11 is available ok
** libs
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c assign.c -o assign.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c between.c -o between.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c bmerge.c -o bmerge.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c chmatch.c -o chmatch.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c cj.c -o cj.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c coalesce.c -o coalesce.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c dogroups.c -o dogroups.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c fastmean.c -o fastmean.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c fcast.c -o fcast.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c fifelse.c -o fifelse.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c fmelt.c -o fmelt.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c forder.c -o forder.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c frank.c -o frank.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c fread.c -o fread.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c freadR.c -o freadR.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c froll.c -o froll.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c frollR.c -o frollR.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c frolladaptive.c -o frolladaptive.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c fsort.c -o fsort.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c fwrite.c -o fwrite.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c fwriteR.c -o fwriteR.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c gsumm.c -o gsumm.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c ijoin.c -o ijoin.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c init.c -o init.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c inrange.c -o inrange.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c nafill.c -o nafill.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c nqrecreateindices.c -o nqrecreateindices.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c openmp-utils.c -o openmp-utils.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c quickselect.c -o quickselect.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c rbindlist.c -o rbindlist.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c reorder.c -o reorder.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c shift.c -o shift.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c subset.c -o subset.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c transpose.c -o transpose.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c types.c -o types.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c uniqlist.c -o uniqlist.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c utils.c -o utils.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c vecseq.c -o vecseq.o
/usr/local/opt/llvm/bin/clang -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c wrappers.c -o wrappers.o
/usr/local/opt/llvm/bin/clang -fopenmp -dynamiclib -Wl,-headerpad_max_install_names -undefined dynamic_lookup -single_module -multiply_defined suppress -L/Library/Frameworks/R.framework/Resources/lib -L/usr/local/opt/gettext/lib -L/usr/local/opt/llvm/lib -Wl,-rpath,/usr/local/opt/llvm/lib -o data.table.so assign.o between.o bmerge.o chmatch.o cj.o coalesce.o dogroups.o fastmean.o fcast.o fifelse.o fmelt.o forder.o frank.o fread.o freadR.o froll.o frollR.o frolladaptive.o fsort.o fwrite.o fwriteR.o gsumm.o ijoin.o init.o inrange.o nafill.o nqrecreateindices.o openmp-utils.o quickselect.o rbindlist.o reorder.o shift.o subset.o transpose.o types.o uniqlist.o utils.o vecseq.o wrappers.o -lz -F/Library/Frameworks/R.framework/.. -framework R -Wl,-framework -Wl,CoreFoundation
ld: unknown option: -platform_version
clang-10: error: linker command failed with exit code 1 (use -v to see invocation)
make: *** [data.table.so] Error 1
ERROR: compilation failed for package ‘data.table’
* removing ‘/Library/Frameworks/R.framework/Versions/4.0/Resources/library/data.table’
Warning in install.packages :
  installation of package ‘data.table’ had non-zero exit status

The downloaded source packages are in
    ‘/private/var/folders/fs/7z2xwjxx0vn3kj7x7khc06980000gp/T/RtmpyDidEl/downloaded_packages’
> sessionInfo()
R version 4.0.0 (2020-04-24)
Platform: x86_64-apple-darwin17.0 (64-bit)
Running under: macOS Mojave 10.14.6

Matrix products: default
BLAS:   /System/Library/Frameworks/Accelerate.framework/Versions/A/Frameworks/vecLib.framework/Versions/A/libBLAS.dylib
LAPACK: /Library/Frameworks/R.framework/Versions/4.0/Resources/lib/libRlapack.dylib

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

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

loaded via a namespace (and not attached):
[1] compiler_4.0.0 tools_4.0.0    packrat_0.5.0 
platform-specific

最も参考になるコメント

どうでも。 私はそれを理解し、マルチスレッドサポヌトでむンストヌルするこずができたす。 .R/Makevarsファむルを倉曎する必芁がありたした。 新しいコンテンツは次のずおりです。

LDFLAGS= -L/usr/local/clang4/lib
FLIBS=-L/usr/local/gfortran/lib/gcc/x86_64-apple-darwin16/6.3.0 -L/usr/local/gfortran/lib -lgfortran -lquadmath -lm
CC=/usr/local/clang4/bin/clang
CXX=/usr/local/gfortran/bin/g++
CXX1X=/usr/local/gfortran/bin/g++
CXX98=/usr/local/gfortran/bin/g++
CXX11=/usr/local/gfortran/bin/g++
CXX14=/usr/local/gfortran/bin/g++
CXX17=/usr/local/gfortran/bin/g++

LLVM_LOC = /usr/local/opt/llvm
CC=/usr/local/gfortran/bin/gcc -fopenmp
CXX=/usr/local/gfortran/bin/g++ -fopenmp
# -O3 should be faster than -O2 (default) level optimisation ..
CFLAGS=-g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe
CXXFLAGS=-g -O3 -Wall -pedantic -std=c++11 -mtune=native -pipe
LDFLAGS=-L/usr/local/opt/gettext/lib -L$(LLVM_LOC)/lib -Wl,-rpath,$(LLVM_LOC)/lib
CPPFLAGS=-I/usr/local/opt/gettext/include -I$(LLVM_LOC)/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include

党おのコメント27件

clangの代わりにgccを詊すこずはできたすか

最近これを芋぀けた
https://github.com/su/R-mac-dev
私はマックを持っおいないのでそれを芋おいたせんが、倚分それは圹に立぀でしょう

申し蚳ありたせんが、私はこれでちょっず初心者です。 代わりにgccを䜿甚するにはどうすればよいですか

どうでも。 私はそれを理解し、マルチスレッドサポヌトでむンストヌルするこずができたす。 .R/Makevarsファむルを倉曎する必芁がありたした。 新しいコンテンツは次のずおりです。

LDFLAGS= -L/usr/local/clang4/lib
FLIBS=-L/usr/local/gfortran/lib/gcc/x86_64-apple-darwin16/6.3.0 -L/usr/local/gfortran/lib -lgfortran -lquadmath -lm
CC=/usr/local/clang4/bin/clang
CXX=/usr/local/gfortran/bin/g++
CXX1X=/usr/local/gfortran/bin/g++
CXX98=/usr/local/gfortran/bin/g++
CXX11=/usr/local/gfortran/bin/g++
CXX14=/usr/local/gfortran/bin/g++
CXX17=/usr/local/gfortran/bin/g++

LLVM_LOC = /usr/local/opt/llvm
CC=/usr/local/gfortran/bin/gcc -fopenmp
CXX=/usr/local/gfortran/bin/g++ -fopenmp
# -O3 should be faster than -O2 (default) level optimisation ..
CFLAGS=-g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe
CXXFLAGS=-g -O3 -Wall -pedantic -std=c++11 -mtune=native -pipe
LDFLAGS=-L/usr/local/opt/gettext/lib -L$(LLVM_LOC)/lib -Wl,-rpath,$(LLVM_LOC)/lib
CPPFLAGS=-I/usr/local/opt/gettext/include -I$(LLVM_LOC)/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include

@ jrf1111゜リュヌションを提䟛しおくれおありがずう、それから閉じたす

わざわざ申し蚳ありたせんが、私は同じ問題を抱えおいるので、解決策を解読しようずしおいたすはい、初心者

llvmを䜿甚し、他のCコンパむラヌllvmのコンパむラヌではなく、最初の投皿でその奇劙な゚ラヌを私に䞎えるを䜿甚するず、どのように問題が解決したすか 私がそのgfortranを持っおいない堎合、私は実際にすべおの指瀺https://github.com/Rdatatable/data.table/wiki/Installation#openmp -enabled-compiler-for-macに埓いたしたが、手動むンストヌルでは、䜕ですかdata.tableをマルチスレッドで実行するには、Makevarsに曞き蟌む必芁がありたすか

私はあたりのgfortranに切り替えおいるhttps://mac.r-project.org/tools/ 、 https://cran.r-project.org/bin/macosx/tools/ 、蚭定.R/Makevarsこのような

FLIBS=-L/usr/local/gfortran/lib/gcc/x86_64-apple-darwin18/8.2.0 -L/usr/local/gfortran/lib -lgfortran -lquadmath -lm
CC=/usr/local/gfortran/bin/gcc
CXX=/usr/local/gfortran/bin/g++
CXX1X=/usr/local/gfortran/bin/g++
CXX98=/usr/local/gfortran/bin/g++
CXX11=/usr/local/gfortran/bin/g++
CXX14=/usr/local/gfortran/bin/g++
CXX17=/usr/local/gfortran/bin/g++

LLVM_LOC = /usr/local/gfortran
CC=$(LLVM_LOC)/bin/gcc -fopenmp
CXX=$(LLVM_LOC)/bin/g++ -fopenmp
# -O3 should be faster than -O2 (default) level optimisation ..
CFLAGS=-g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe
CXXFLAGS=-g -O3 -Wall -pedantic -std=c++11 -mtune=native -pipe
LDFLAGS=-L/usr/local/opt/gettext/lib -L$(LLVM_LOC)/lib -Wl,-rpath,$(LLVM_LOC)/lib
CPPFLAGS=-I/usr/local/opt/gettext/include -I$(LLVM_LOC)/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include

そしお今、リポゞトリから開発者バヌゞョンをむンストヌルしようずするず、

data.table::update.dev.pkg()
Warning: unable to access index for repository https://Rdatatable.gitlab.io/data.table/bin/macosx/contrib/4.0:
cannot open URL 'https://Rdatatable.gitlab.io/data.table/bin/macosx/contrib/4.0/PACKAGES'
Package which is only available in source form, and may need compilation of C/C++/Fortran:
‘data.table’
Do you want to attempt to install these from sources? (Yes/no/cancel) Yes
installing the source package ‘data.table’

trying URL 'https://Rdatatable.gitlab.io/data.table/src/contrib/data.table_1.12.9.tar.gz'
Content type 'application/gzip' length 5195275 bytes (5.0 MB)

downloaded 5.0 MB

installing source package ‘data.table’ ...
** using staged installation
*** pkg-config is not installed.
*** Compilation will now be attempted and if it works you can ignore this message. However,
*** if compilation fails, try 'locate zlib.h zconf.h' and ensure the zlib development library
*** is installed :
*** deb: zlib1g-dev (Debian, Ubuntu, ...)
*** rpm: zlib-devel (Fedora, EPEL, ...)
*** brew: zlib (OSX)
*** Note that zlib is required to compile R itself so you may find the advice in the R-admin
*** guide helpful regarding zlib. On Debian/Ubuntu, zlib1g-dev is a dependency of r-base as
*** shown by 'apt-cache showsrc r-base | grep ^Build-Depends | grep zlib', and therefore
*** 'sudo apt-get build-dep r-base' should be sufficient too.
*** To silence this message, please ensure that :
*** 1) 'pkg-config --exists zlib' succeeds (i.e. $? -eq 0)
*** 2) 'pkg-config --libs zlib' contains -lz
*** Compilation will now be attempted ...
** libs
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c assign.c -o assign.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c between.c -o between.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c bmerge.c -o bmerge.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c chmatch.c -o chmatch.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c cj.c -o cj.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c coalesce.c -o coalesce.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c dogroups.c -o dogroups.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c fastmean.c -o fastmean.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c fcast.c -o fcast.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c fifelse.c -o fifelse.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c fmelt.c -o fmelt.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c forder.c -o forder.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c frank.c -o frank.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c fread.c -o fread.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c freadR.c -o freadR.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c froll.c -o froll.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c frollR.c -o frollR.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c frolladaptive.c -o frolladaptive.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c fsort.c -o fsort.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c fwrite.c -o fwrite.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c fwriteR.c -o fwriteR.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c gsumm.c -o gsumm.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c ijoin.c -o ijoin.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c init.c -o init.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c inrange.c -o inrange.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c nafill.c -o nafill.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c nqrecreateindices.c -o nqrecreateindices.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c openmp-utils.c -o openmp-utils.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c quickselect.c -o quickselect.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c rbindlist.c -o rbindlist.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c reorder.c -o reorder.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c shift.c -o shift.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c subset.c -o subset.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c transpose.c -o transpose.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c types.c -o types.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c uniqlist.c -o uniqlist.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c utils.c -o utils.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c vecseq.c -o vecseq.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG -I/usr/local/opt/gettext/include -I/usr/local/gfortran/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -fPIC -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c wrappers.c -o wrappers.o
/usr/local/gfortran/bin/gcc -fopenmp -dynamiclib -Wl,-headerpad_max_install_names -undefined dynamic_lookup -single_module -multiply_defined suppress -L/Library/Frameworks/R.framework/Resources/lib -L/usr/local/opt/gettext/lib -L/usr/local/gfortran/lib -Wl,-rpath,/usr/local/gfortran/lib -o data.table.so assign.o between.o bmerge.o chmatch.o cj.o coalesce.o dogroups.o fastmean.o fcast.o fifelse.o fmelt.o forder.o frank.o fread.o freadR.o froll.o frollR.o frolladaptive.o fsort.o fwrite.o fwriteR.o gsumm.o ijoin.o init.o inrange.o nafill.o nqrecreateindices.o openmp-utils.o quickselect.o rbindlist.o reorder.o shift.o subset.o transpose.o types.o uniqlist.o utils.o vecseq.o wrappers.o -F/Library/Frameworks/R.framework/.. -framework R -Wl,-framework -Wl,CoreFoundation
installing to /Library/Frameworks/R.framework/Versions/4.0/Resources/library/00LOCK-data.table/00new/data.table/libs
** R
** inst
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
** building package indices
** installing vignettes
** testing if installed package can be loaded from temporary location
Error: package or namespace load failed for ‘data.table’ in library.dynam(lib, package, package.lib):
shared object ‘datatable.so’ not found
Error: loading failed
Execution halted
ERROR: loading failed
removing ‘/Library/Frameworks/R.framework/Versions/4.0/Resources/library/data.table’
restoring previous ‘/Library/Frameworks/R.framework/Versions/4.0/Resources/library/data.table’
The downloaded source packages are in
‘/private/var/folders/z7/r94g4j6j4z33r99np7kwns2nwz14jw/T/RtmppDABFK/downloaded_packages’
R data.table package has been updated to NA (1.12.8)
Warning message:
In utils::install.packages(pkg, repos = repo, type = type, lib = lib, :
installation of package ‘data.table’ had non-zero exit status

CRANバヌゞョンは機胜したすが、シングルスレッドで動䜜したす。 このhttps://stackoverflow.com/questions/59658131/error-package-or-namespace-load-failed-for-data-table-in-library-dynamlib-pに関するstackoverflowスレッドがあり、有甚な回答は提䟛されおいたせん。

https://github.com/fxcoudert/gfortran-for-macOS/releases/tag/6.3で入手可胜なgfortranバヌゞョン6.3.0を䜿甚する必芁がある堎合があり

Makevarsファむルも曎新しおください。
FLIBS=-L/usr/local/gfortran/lib/gcc/x86_64-apple-darwin16/6.3.0 -L/usr/local/gfortran/lib -lgfortran -lquadmath -lm

悲しいこずに、いいえ。 この問題は、gfortran6.3.0ず8.2.0の䞡方で解決したせん。

以前にむンストヌルしたdata.tableを削陀したしたか たた、開発者バヌゞョンではなくCRANバヌゞョンをむンストヌルしたしたか

はい、確かにそうしたした。 私はそれらすべおを詊しおみたしたが、同じ結果でした開発者バヌゞョンでの゚ラヌ、むンストヌルは成功したしたが、CRANでのシングルスレッド助けおくれおありがずう

Makevarsファむルず私のファむルにはただいく぀かの違いがあるようです。 Makevarsファむル党䜓を私が䜿甚したものに眮き換えおみおください。

LDFLAGS= -L/usr/local/clang4/lib
FLIBS=-L/usr/local/gfortran/lib/gcc/x86_64-apple-darwin16/6.3.0 -L/usr/local/gfortran/lib -lgfortran -lquadmath -lm
CC=/usr/local/clang4/bin/clang
CXX=/usr/local/gfortran/bin/g++
CXX1X=/usr/local/gfortran/bin/g++
CXX98=/usr/local/gfortran/bin/g++
CXX11=/usr/local/gfortran/bin/g++
CXX14=/usr/local/gfortran/bin/g++
CXX17=/usr/local/gfortran/bin/g++

LLVM_LOC = /usr/local/opt/llvm
CC=/usr/local/gfortran/bin/gcc -fopenmp
CXX=/usr/local/gfortran/bin/g++ -fopenmp
# -O3 should be faster than -O2 (default) level optimisation ..
CFLAGS=-g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe
CXXFLAGS=-g -O3 -Wall -pedantic -std=c++11 -mtune=native -pipe
LDFLAGS=-L/usr/local/opt/gettext/lib -L$(LLVM_LOC)/lib -Wl,-rpath,$(LLVM_LOC)/lib
CPPFLAGS=-I/usr/local/opt/gettext/include -I$(LLVM_LOC)/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include

再起動し、あなたのアドバむスに埓っお、それは今動䜜したす。 ありがずう

お圹に立おお嬉しいです

䞊蚘の提案に埓っお、次の゚ラヌが発生したした

[1]「en_US.UTF-8 / en_US.UTF-8 / en_US.UTF-8 / C / en_US.UTF-8 / en_US.UTF-8」
゚ラヌlibrary.dynamlib、package、package.libの「data.table」のパッケヌゞたたは名前空間のロヌドに倱敗したした
共有オブゞェクト 'datatable.so'が芋぀かりたせん
゚ラヌ読み蟌みに倱敗したした
実行が停止したした
゚ラヌ読み蟌みに倱敗したした

助蚀がありたすか

@likanzhanは別の問題のようです。新しい問題を䜜成し、新しく開始したRセッションにむンストヌルしようずしたすべおの入力ず出力を入力しおください。

@jangorecki

install.packages("data.table", type = "source",  repos = "https://Rdatatable.gitlab.io/data.table")
Installing package into ‘/Users/lzhan/R’
(as ‘lib’ is unspecified)
trying URL 'https://Rdatatable.gitlab.io/data.table/src/contrib/data.table_1.12.9.tar.gz'
Content type 'application/gzip' length 5195275 bytes (5.0 MB)

downloaded 5.0 MB

[1] "en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8"
* installing *source* package ‘data.table’ ...
** using staged installation
*** pkg-config is not installed.
*** Compilation will now be attempted and if it works you can ignore this message. However,
*** if compilation fails, try 'locate zlib.h zconf.h' and ensure the zlib development library
*** is installed :
***   deb: zlib1g-dev (Debian, Ubuntu, ...)
***   rpm: zlib-devel (Fedora, EPEL, ...)
***   brew: zlib (OSX)
*** Note that zlib is required to compile R itself so you may find the advice in the R-admin
*** guide helpful regarding zlib. On Debian/Ubuntu, zlib1g-dev is a dependency of r-base as
*** shown by 'apt-cache showsrc r-base | grep ^Build-Depends | grep zlib', and therefore
*** 'sudo apt-get build-dep r-base' should be sufficient too.
*** To silence this message, please ensure that :
***   1) 'pkg-config --exists zlib' succeeds (i.e. $? -eq 0)
***   2) 'pkg-config --libs zlib' contains -lz
*** Compilation will now be attempted ...
** libs
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c assign.c -o assign.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c between.c -o between.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c bmerge.c -o bmerge.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c chmatch.c -o chmatch.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c cj.c -o cj.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c coalesce.c -o coalesce.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c dogroups.c -o dogroups.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c fastmean.c -o fastmean.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c fcast.c -o fcast.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c fifelse.c -o fifelse.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c fmelt.c -o fmelt.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c forder.c -o forder.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c frank.c -o frank.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c fread.c -o fread.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c freadR.c -o freadR.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c froll.c -o froll.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c frollR.c -o frollR.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c frolladaptive.c -o frolladaptive.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c fsort.c -o fsort.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c fwrite.c -o fwrite.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c fwriteR.c -o fwriteR.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c gsumm.c -o gsumm.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c ijoin.c -o ijoin.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c init.c -o init.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c inrange.c -o inrange.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c nafill.c -o nafill.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c nqrecreateindices.c -o nqrecreateindices.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c openmp-utils.c -o openmp-utils.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c quickselect.c -o quickselect.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c rbindlist.c -o rbindlist.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c reorder.c -o reorder.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c shift.c -o shift.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c subset.c -o subset.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c transpose.c -o transpose.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c types.c -o types.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c uniqlist.c -o uniqlist.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c utils.c -o utils.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c vecseq.c -o vecseq.o
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c wrappers.c -o wrappers.o
/usr/local/gfortran/bin/gcc -fopenmp -dynamiclib -Wl,-headerpad_max_install_names -undefined dynamic_lookup -single_module -multiply_defined suppress -L/Library/Frameworks/R.framework/Resources/lib -L/usr/local/opt/gettext/lib -L/usr/local/opt/llvm/lib -Wl,-rpath,/usr/local/opt/llvm/lib -o data.table.so assign.o between.o bmerge.o chmatch.o cj.o coalesce.o dogroups.o fastmean.o fcast.o fifelse.o fmelt.o forder.o frank.o fread.o freadR.o froll.o frollR.o frolladaptive.o fsort.o fwrite.o fwriteR.o gsumm.o ijoin.o init.o inrange.o nafill.o nqrecreateindices.o openmp-utils.o quickselect.o rbindlist.o reorder.o shift.o subset.o transpose.o types.o uniqlist.o utils.o vecseq.o wrappers.o -F/Library/Frameworks/R.framework/.. -framework R -Wl,-framework -Wl,CoreFoundation
installing to /Users/lzhan/R/00LOCK-data.table/00new/data.table/libs
** R
** inst
** byte-compile and prepare package for lazy loading
[1] "en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8"
** help
*** installing help indices
** building package indices
[1] "en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8"
** installing vignettes
** testing if installed package can be loaded from temporary location
[1] "en_US.UTF-8/en_US.UTF-8/en_US.UTF-8/C/en_US.UTF-8/en_US.UTF-8"
Error: package or namespace load failed for ‘data.table’ in library.dynam(lib, package, package.lib):
 shared object ‘datatable.so’ not found
Error: loading failed
Execution halted
ERROR: loading failed
* removing ‘/Users/lzhan/R/data.table’

The downloaded source packages are in
    ‘/private/var/folders/qz/0srg88cd2459h1cbn623wrt00000gq/T/Rtmpgzby8h/downloaded_packages’
Warning message:
In install.packages("data.table", type = "source", repos = "https://Rdatatable.gitlab.io/data.table") :
  installation of package ‘data.table’ had non-zero exit status

ありがずう 

以䞋の解決策は私のために働いた

どうでも。 私はそれを理解し、マルチスレッドサポヌトでむンストヌルするこずができたす。 .R/Makevarsファむルを倉曎する必芁がありたした。 新しいコンテンツは次のずおりです。

LDFLAGS= -L/usr/local/clang4/lib
FLIBS=-L/usr/local/gfortran/lib/gcc/x86_64-apple-darwin16/6.3.0 -L/usr/local/gfortran/lib -lgfortran -lquadmath -lm
CC=/usr/local/clang4/bin/clang
CXX=/usr/local/gfortran/bin/g++
CXX1X=/usr/local/gfortran/bin/g++
CXX98=/usr/local/gfortran/bin/g++
CXX11=/usr/local/gfortran/bin/g++
CXX14=/usr/local/gfortran/bin/g++
CXX17=/usr/local/gfortran/bin/g++

LLVM_LOC = /usr/local/opt/llvm
CC=/usr/local/gfortran/bin/gcc -fopenmp
CXX=/usr/local/gfortran/bin/g++ -fopenmp
# -O3 should be faster than -O2 (default) level optimisation ..
CFLAGS=-g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe
CXXFLAGS=-g -O3 -Wall -pedantic -std=c++11 -mtune=native -pipe
LDFLAGS=-L/usr/local/opt/gettext/lib -L$(LLVM_LOC)/lib -Wl,-rpath,$(LLVM_LOC)/lib
CPPFLAGS=-I/usr/local/opt/gettext/include -I$(LLVM_LOC)/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include

@jangoreckiむンストヌルwikiのMakevarsファむルを曎新するず䟿利です-あなたずRdatatableチヌムに感謝したす

重芁なのは、Catalinaのために最初から再むンストヌルする必芁があったこずです。 llvmはただ機胜しないこずがわかりたしたが、.Makevarsをgfortranコンパむラヌで蚭定するず䞊蚘のように、バヌゞョン8.2.0でもうたくいきたす。

MojaveずCatalinaの䞡方で、llvmを䜿甚しおコンパむルを完了するこずはできたせんでした。

私もこの問題を抱えおおり、readmeペヌゞで提案されおいる.R / Makevarsファむルそのペヌゞの䞋郚に暙準゚ラヌを報告し、ここに私を導きたしたず䞊蚘の@daynefilerのコヌドの

> install.packages("data.table", type = "source",
+                  repos = "https://Rdatatable.gitlab.io/data.table")
trying URL 'https://Rdatatable.gitlab.io/data.table/src/contrib/data.table_1.12.9.tar.gz'
Content type 'application/gzip' length 5208337 bytes (5.0 MB)
==================================================
downloaded 5.0 MB

* installing *source* package ‘data.table’ ...
** using staged installation
*** pkg-config is not installed.
*** Compilation will now be attempted and if it works you can ignore this message. However,
*** if compilation fails, try 'locate zlib.h zconf.h' and ensure the zlib development library
*** is installed :
***   deb: zlib1g-dev (Debian, Ubuntu, ...)
***   rpm: zlib-devel (Fedora, EPEL, ...)
***   brew: zlib (OSX)
*** Note that zlib is required to compile R itself so you may find the advice in the R-admin
*** guide helpful regarding zlib. On Debian/Ubuntu, zlib1g-dev is a dependency of r-base as
*** shown by 'apt-cache showsrc r-base | grep ^Build-Depends | grep zlib', and therefore
*** 'sudo apt-get build-dep r-base' should be sufficient too.
*** To silence this message, please ensure that :
***   1) 'pkg-config --exists zlib' succeeds (i.e. $? -eq 0)
***   2) 'pkg-config --libs zlib' contains -lz
*** Compilation will now be attempted ...
** libs
/usr/local/gfortran/bin/gcc -fopenmp -I"/Library/Frameworks/R.framework/Resources/include" -DNDEBUG   -I/usr/local/opt/gettext/include -I/usr/local/opt/llvm/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include   -fPIC  -g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe -c assign.c -o assign.o
/bin/sh: /usr/local/gfortran/bin/gcc: No such file or directory
make: *** [assign.o] Error 127
ERROR: compilation failed for package ‘data.table’
* removing ‘/Library/Frameworks/R.framework/Versions/4.0/Resources/library/data.table’
Warning in install.packages :
  installation of package ‘data.table’ had non-zero exit status

The downloaded source packages are in
    ‘/private/var/folders/8n/wm3qzjnn2dx4l_lznyk0fthr00_bd1/T/Rtmp1SObio/downloaded_packages’

通垞のinstall.packages "data.table"を䜿甚したむンストヌルは機胜したすが、この修正で察凊しようずしおいるマルチコアの問題が発生したす

@FarMarは、 install.packages("data.table", type="source")機胜するかどうかを確認できたすか コンパむラがMakevarsで正しく定矩されおいないようです。

@jangoreckiこれはMakevarファむルが削陀された状態で機胜したすが、CRANリポゞトリず同じように「OpenMP゚ラヌなし」をスロヌしたす。 @ jrf1111および䞊蚘の@daynefilerの応答で詳现に説明されおいるMakevarsファむルで倱敗したす

@FarMarカスタムMakevarsを䜿甚しおdata.tableをコンパむルする前に、䜕かをコンパむルするこずを確認しおください。 ずにかく、私はコンパむルされたコヌドを含むパッケヌゞを意味したす。 それ以倖の堎合、問題は実際にはdata.tableコヌドに関連しおいたせん。 コンパむラが䜕でもコンパむルできるようになるず、コンパむルが倱敗したずきにdata.tableの問題が発生する可胜性がありたす。

  1. このスレッドのパスをたどりたい堎合は、䞍足しおいる゜フトりェアをむンストヌルするか、パスを構成する必芁があるため、ここからのMakevarsはコンパむラヌを正しく指定したす。

  2. それ以倖の堎合は、コンパむラが機胜するポむントにロヌルバックしお、 https//github.com/Rdatatable/data.table/wiki/Installation wikiをフォロヌしおみお

どちらの堎合も、コンパむルが䜕に察しおも機胜するこずを確認する必芁がありたす。
コンパむルされたコヌドを含むパッケヌゞのむンストヌルを詊みるこずができるこずを確認したす。 「HelloworldfromC」のおもちゃパッケヌゞがありたす。

install.packages("r.gitlab.ci", repos="https://jangorecki.gitlab.io/r.gitlab.ci")

CRANからパッケヌゞをむンストヌルする堎合、CRANにはパッケヌゞ゜ヌスではなくデフォルトで䜿甚されるmacバむナリがあるため、 type="source"を远加する必芁がありたす。

@FarMarは、むンストヌル出力のこの行に泚意しおください

/ usr / local / gfortran / bin / gccそのようなファむルたたはディレクトリはありたせん

぀たり、マシンはそのパスでgccを怜玢するように構成されおいたす /usr/local/gfortran/bin/gcc

そのファむルがマシンに存圚するかどうかを確認できたす。 私はMacにgccを持っおいたすしかし残念ながら、どうやっおそこにたどり着いたのか完党にはわかりたせん。できればむンストヌルwikiです。

個人的には、むンストヌルwikiから蚭定した/usr/local/opt/llvmでMacのllvmを䜿甚しおいたす。

いずれの堎合も、 ~/.R/Makevars CCずしお定矩する必芁がありたす。

それがお圹に立おば幞いです。

それ以倖の堎合は、コンパむラが機胜するポむントにロヌルバックしお、 https//github.com/Rdatatable/data.table/wiki/Installation wikiをフォロヌしおみお

@jangorecki私はそのルヌトに向かう぀もりです。 readmeの最初のMarkevars線集からのコンパむルが壊れおいるようです。 カスタムMakevars存圚する状態でテストをコンパむルできたせんでしたが、それがなくおも正垞に動䜜したす。

みなさん、こんにちは。このスレッドに感謝したす。 brewからのllvmむンストヌルを䜿甚しおmacOSむンストヌルの指瀺に埓いたしたが、このパッケヌゞをむンストヌルするこずができたせんでした

install.packages("data.table", type = "source", repos = "https://Rdatatable.gitlab.io/data.table")

コンパむルは垞にこの゚ラヌで倱敗したした

Error: package or namespace load failed for ‘data.table’ in library.dynam(lib, package, package.lib):
 shared object ‘datatable.so’ not found

キヌボヌドをヘッドバンギングした埌、この譊告が非垞に圹立぀こずがわかりたした。

** using staged installation
*** pkg-config is not installed.
*** Compilation will now be attempted and if it works you can ignore this message. However,
*** if compilation fails, try 'locate zlib.h zconf.h' and ensure the zlib development library
*** is installed :
***   deb: zlib1g-dev (Debian, Ubuntu, ...)
***   rpm: zlib-devel (Fedora, EPEL, ...)
***   brew: zlib (OSX)
*** Note that zlib is required to compile R itself so you may find the advice in the R-admin
*** guide helpful regarding zlib. On Debian/Ubuntu, zlib1g-dev is a dependency of r-base as
*** shown by 'apt-cache showsrc r-base | grep ^Build-Depends | grep zlib', and therefore
*** 'sudo apt-get build-dep r-base' should be sufficient too.
*** To silence this message, please ensure that :
***   1) 'pkg-config --exists zlib' succeeds (i.e. $? -eq 0)
***   2) 'pkg-config --libs zlib' contains -lz
*** Compilation will now be attempted ...

私の堎合、 locateは機胜したせんでした。 locate zlib.h zconf.hを詊しおみたした

WARNING: The locate database (/var/db/locate.database) does not exist.
To create the database, run the following command:

  sudo launchctl load -w /System/Library/LaunchDaemons/com.apple.locate.plist

私のマシンはほずんど新しいので、おそらくそれが私がこのメッセヌゞを受け取った理由です。 ずにかく、私はそのlaunchctl loadコマンドを実行しお数分埅った埌、 locateはzlib.hずzconf.hが私の䞊にあるいく぀かの堎所を芋぀けるこずができたしたシステム。 それが適切に行われるず、゜ヌスむンストヌルは魅力のように機胜したした。

抂芁やり過ぎかもしれたせんが、私にずっおうたくいったのdata.table 、゜ヌスからbrewむンストヌルを実行するこず

brew update
brew install llvm pkg-config zlib gettext

次に、 locateのデヌタベヌスを構築したす。

sudo launchctl load -w /System/Library/LaunchDaemons/com.apple.locate.plist

そしお、むンストヌルペヌゞの~/.R/Makevarsファむルを、 zlib甚の远加のC ++コンパむラフラグずずもに䜿甚したす。

LLVM_LOC = /usr/local/opt/llvm
CC=$(LLVM_LOC)/bin/clang -fopenmp
CXX=$(LLVM_LOC)/bin/clang++ -fopenmp
# -O3 should be faster than -O2 (default) level optimisation ..
CFLAGS=-g -O3 -Wall -pedantic -std=gnu99 -mtune=native -pipe
CXXFLAGS=-g -O3 -Wall -pedantic -std=c++11 -mtune=native -pipe
LDFLAGS=-L/usr/local/opt/gettext/lib -L$(LLVM_LOC)/lib -Wl,-rpath,$(LLVM_LOC)/libi -L/usr/local/opt/zlib/lib
CPPFLAGS=-I/usr/local/opt/gettext/include -I$(LLVM_LOC)/include -I/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include -I/usr/local/opt/zlib/include

うたくいけば、これは誰かの将来の頭痛を救うこずができたす

このペヌゞは圹に立ちたしたか
0 / 5 - 0 評䟡