2017-02-12 10 views
0

Installation des "tm" Paket mit:kann nicht installiert "tm", "NLP" oder "slam" Paket auf R 3.3.2 (macOS Sierra)

install.packages("tm", dependencies = TRUE) 

schlägt mit der folgenden Ausgabe:

During startup - Warning messages: 
1: Setting LC_TIME failed, using "C" 
2: Setting LC_MESSAGES failed, using "C" 
3: Setting LC_MONETARY failed, using "C" 
* installing *source* package ‘NLP’ ... 
** package ‘NLP’ successfully unpacked and MD5 sums checked 
** R 
** inst 
** preparing package for lazy loading 
** help 
*** installing help indices 
** building package indices 
** testing if installed package can be loaded 
*** arch - R 
ERROR: sub-architecture 'R' is not installed 
*** arch - R.html 
ERROR: sub-architecture 'R.html' is not installed 
ERROR: loading failed for ‘R’, ‘R.html’ 
* removing ‘/usr/local/lib/R/3.3/site-library/NLP’ 
During startup - Warning messages: 
1: Setting LC_TIME failed, using "C" 
2: Setting LC_MESSAGES failed, using "C" 
3: Setting LC_MONETARY failed, using "C" 
* installing *source* package ‘slam’ ... 
** package ‘slam’ successfully unpacked and MD5 sums checked 
** libs 
make: *** No rule to make target `apply.o', needed by `slam.so'. Stop. 
*** arch - R.html 
Warning in file(con, "r") : 
    cannot open file '/usr/local/Cellar/r/3.3.2/R.framework/Resources/etc/R.html/Makeconf': No such file or directory 
Error in file(con, "r") : cannot open the connection 
* removing ‘/usr/local/lib/R/3.3/site-library/slam’ 
During startup - Warning messages: 
1: Setting LC_TIME failed, using "C" 
2: Setting LC_MESSAGES failed, using "C" 
3: Setting LC_MONETARY failed, using "C" 
* installing *source* package ‘filehash’ ... 
** package ‘filehash’ successfully unpacked and MD5 sums checked 
** libs 
make: *** No rule to make target `hash.o', needed by `filehash.so'. Stop. 
*** arch - R.html 
Warning in file(con, "r") : 
    cannot open file '/usr/local/Cellar/r/3.3.2/R.framework/Resources/etc/R.html/Makeconf': No such file or directory 
Error in file(con, "r") : cannot open the connection 
* removing ‘/usr/local/lib/R/3.3/site-library/filehash’ 
During startup - Warning messages: 
1: Setting LC_TIME failed, using "C" 
2: Setting LC_MESSAGES failed, using "C" 
3: Setting LC_MONETARY failed, using "C" 
* installing *source* package ‘Rpoppler’ ... 
** package ‘Rpoppler’ successfully unpacked and MD5 sums checked 
checking for pkg-config... /usr/local/bin/pkg-config 
checking whether pkg-config knows about poppler-glib >= 0.18.0... no 
configure: error: cannot determine poppler-glib compile/link flags 
ERROR: configuration failed for package ‘Rpoppler’ 
* removing ‘/usr/local/lib/R/3.3/site-library/Rpoppler’ 
During startup - Warning messages: 
1: Setting LC_TIME failed, using "C" 
2: Setting LC_MESSAGES failed, using "C" 
3: Setting LC_MONETARY failed, using "C" 
* installing *source* package ‘SnowballC’ ... 
** package ‘SnowballC’ successfully unpacked and MD5 sums checked 
** libs 
make: *** No rule to make target `api.o', needed by `SnowballC.so'. Stop. 
*** arch - R.html 
Warning in file(con, "r") : 
    cannot open file '/usr/local/Cellar/r/3.3.2/R.framework/Resources/etc/R.html/Makeconf': No such file or directory 
Error in file(con, "r") : cannot open the connection 
* removing ‘/usr/local/lib/R/3.3/site-library/SnowballC’ 
During startup - Warning messages: 
1: Setting LC_TIME failed, using "C" 
2: Setting LC_MESSAGES failed, using "C" 
3: Setting LC_MONETARY failed, using "C" 
ERROR: dependencies ‘NLP’, ‘slam’ are not available for package ‘tm’ 
* removing ‘/usr/local/lib/R/3.3/site-library/tm’ 

The downloaded source packages are in 
    ‘/private/var/folders/19/b59kndv96js71_09xrz9ssdc0000gn/T/RtmptEhVgC/downloaded_packages’ 
Warning messages: 
1: In install.packages("tm", dependencies = TRUE) : 
    installation of package ‘NLP’ had non-zero exit status 
2: In install.packages("tm", dependencies = TRUE) : 
    installation of package ‘slam’ had non-zero exit status 
3: In install.packages("tm", dependencies = TRUE) : 
    installation of package ‘filehash’ had non-zero exit status 
4: In install.packages("tm", dependencies = TRUE) : 
    installation of package ‘Rpoppler’ had non-zero exit status 
5: In install.packages("tm", dependencies = TRUE) : 
    installation of package ‘SnowballC’ had non-zero exit status 
6: In install.packages("tm", dependencies = TRUE) : 
    installation of package ‘tm’ had non-zero exit status 

Session info:

> sessionInfo() 
R version 3.3.2 (2016-10-31) 
Platform: x86_64-apple-darwin16.1.0 (64-bit) 
Running under: macOS Sierra 10.12.2 

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

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

loaded via a namespace (and not attached): 
[1] tools_3.3.2 

PS: Der Versuch, insta ll "NLP" oder "Slam" scheitert auch separat.

> install.packages("NLP", dependencies = TRUE) 
Installing package into ‘/usr/local/lib/R/3.3/site-library’ 
(as ‘lib’ is unspecified) 
trying URL 'https://lib.ugent.be/CRAN/src/contrib/NLP_0.1-9.tar.gz' 
Content type 'application/x-gzip' length 134347 bytes (131 KB) 
================================================== 
downloaded 131 KB 

During startup - Warning messages: 
1: Setting LC_TIME failed, using "C" 
2: Setting LC_MESSAGES failed, using "C" 
3: Setting LC_MONETARY failed, using "C" 
* installing *source* package ‘NLP’ ... 
** package ‘NLP’ successfully unpacked and MD5 sums checked 
** R 
** inst 
** preparing package for lazy loading 
** help 
*** installing help indices 
** building package indices 
** testing if installed package can be loaded 
*** arch - R 
ERROR: sub-architecture 'R' is not installed 
*** arch - R.html 
ERROR: sub-architecture 'R.html' is not installed 
ERROR: loading failed for ‘R’, ‘R.html’ 
* removing ‘/usr/local/lib/R/3.3/site-library/NLP’ 

The downloaded source packages are in 
    ‘/private/var/folders/19/b59kndv96js71_09xrz9ssdc0000gn/T/RtmptEhVgC/downloaded_packages’ 
Warning message: 
In install.packages("NLP", dependencies = TRUE) : 
    installation of package ‘NLP’ had non-zero exit status 


> install.packages("slam", dependencies = TRUE) 
Installing package into ‘/usr/local/lib/R/3.3/site-library’ 
(as ‘lib’ is unspecified) 
trying URL 'https://lib.ugent.be/CRAN/src/contrib/slam_0.1-40.tar.gz' 
Content type 'application/x-gzip' length 50146 bytes (48 KB) 
================================================== 
downloaded 48 KB 

During startup - Warning messages: 
1: Setting LC_TIME failed, using "C" 
2: Setting LC_MESSAGES failed, using "C" 
3: Setting LC_MONETARY failed, using "C" 
* installing *source* package ‘slam’ ... 
** package ‘slam’ successfully unpacked and MD5 sums checked 
** libs 
make: *** No rule to make target `apply.o', needed by `slam.so'. Stop. 
*** arch - R.html 
Warning in file(con, "r") : 
    cannot open file '/usr/local/Cellar/r/3.3.2/R.framework/Resources/etc/R.html/Makeconf': No such file or directory 
Error in file(con, "r") : cannot open the connection 
* removing ‘/usr/local/lib/R/3.3/site-library/slam’ 

The downloaded source packages are in 
    ‘/private/var/folders/19/b59kndv96js71_09xrz9ssdc0000gn/T/RtmptEhVgC/downloaded_packages’ 
Warning message: 
In install.packages("slam", dependencies = TRUE) : 
    installation of package ‘slam’ had non-zero exit status 

Links:

+0

Haben Sie Java ordnungsgemäß installiert und konfiguriert, ich erinnere mich, ich hatte ein ähnliches Problem, wenn meine Java-Version wurde nicht von Paket NLP –

+0

Ich habe 1,8 installiert, nicht sicher, ob es die richtige Version ist. Ich kann auch keine Erwähnung von Java auf der NLP-Paketseite finden. – maartencls

+0

können Sie versuchen, 'rJava' und dann 'sudo R CMD javareconf' auf Ihrem Macbook zu installieren. Wenn diese beiden funktionieren, dann lasst uns nach vorne schauen –

Antwort

2

Ok, etwas seltsam war falsch.

R verwendet diese Linie, welche die Architekturen zu bestimmen:

archs <- dir(file.path(R.home("bin"), "exec")) 

Wie hier zu sehen: src/library/toolsR/install.R#1479

In meinem Fall das ist/exec Verzeichnis hier gefunden werden: Für

> R.home("bin/exec") 
[1] "/usr/local/Cellar/r/3.3.2/R.framework/Resources/bin/exec" 

aus irgendeinem Grund enthielt das Verzeichnis eine R.html Datei mit dem Inhalt NA. Dies veranlasste R zu der Annahme, dass es eine Architektur namens R.html gäbe.

Nach dem Entfernen der Datei konnte ich alles installieren.

Verwandte Themen