harrelfe / Hmisc

Harrell Miscellaneous
Other
208 stars 81 forks source link

Cannot install package for R4.2 on Mac M1 OS #154

Closed ShouyeLiu closed 2 years ago

ShouyeLiu commented 2 years ago

When I install this package in Mac M1 os, R 4.2 version, the following problems occur:

Warning: Label 23007 at (1) defined but not used [-Wunused-label]
clang -mmacosx-version-min=10.13 -dynamiclib -Wl,-headerpad_max_install_names -undefined dynamic_lookup -single_module -multiply_defined suppress -L/Library/Frameworks/R.framework/Resources/lib -L/usr/local/lib -o Hmisc.so Hmisc.o cidxcn.o cidxcp.o hoeffd.o init.o jacklins.o largrec.o mChoice.o maxempr.o nstr.o ranksort.o rcorr.o string_box.o wclosest.o -L/usr/local/gfortran/lib/gcc/x86_64-apple-darwin18/8.2.0 -L/usr/local/gfortran/lib -lgfortran -lquadmath -lm -F/Library/Frameworks/R.framework/.. -framework R -Wl,-framework -Wl,CoreFoundation
ld: warning: directory not found for option '-L/usr/local/gfortran/lib/gcc/x86_64-apple-darwin18/8.2.0'
ld: warning: ignoring file cidxcn.o, building for macOS-x86_64 but attempting to link with file built for unknown-arm64
ld: warning: ignoring file cidxcp.o, building for macOS-x86_64 but attempting to link with file built for unknown-arm64
ld: warning: ignoring file hoeffd.o, building for macOS-x86_64 but attempting to link with file built for unknown-arm64
ld: warning: ignoring file jacklins.o, building for macOS-x86_64 but attempting to link with file built for unknown-arm64
ld: warning: ignoring file largrec.o, building for macOS-x86_64 but attempting to link with file built for unknown-arm64
ld: warning: ignoring file maxempr.o, building for macOS-x86_64 but attempting to link with file built for unknown-arm64
ld: warning: ignoring file wclosest.o, building for macOS-x86_64 but attempting to link with file built for unknown-arm64
ld: warning: ignoring file rcorr.o, building for macOS-x86_64 but attempting to link with file built for unknown-arm64
installing to /Users/uqsliu28/Library/R/x86_64/4.2/library/00LOCK-Hmisc/00new/Hmisc/libs
** R
** inst
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
** building package indices
** testing if installed package can be loaded from temporary location
Error: package or namespace load failed for ‘Hmisc’ in dyn.load(file, DLLpath = DLLpath, ...):
 unable to load shared object '/Users/uqsliu28/Library/R/x86_64/4.2/library/00LOCK-Hmisc/00new/Hmisc/libs/Hmisc.so':
  dlopen(/Users/uqsliu28/Library/R/x86_64/4.2/library/00LOCK-Hmisc/00new/Hmisc/libs/Hmisc.so, 0x0006): symbol not found in flat namespace '_cidxcn_'
Error: loading failed
Execution halted
ERROR: loading failed
* removing ‘/Users/uqsliu28/Library/R/x86_64/4.2/library/Hmisc’
Warning message:
In i.p(...) :
  installation of package ‘/var/folders/2c/ly7g9pgs6m9cdv3ycwyfjq9c0000gr/T//Rtmp4xwuth/file17e9177c9249/Hmisc_4.7-0.tar.gz’ had non-zero exit status