Error installing 'topicmodels' package, non zero exit status; Ubuntu
I found out that on two of my Ubuntu installations, the non-zero exit status was caused by not having the gsl
package. However, it took me quite sometime before I could figure out which version would cure the error.
In the terminal: sudo apt-get install libgsl0-dev
Error in installing TopicModels package in google collab
Try running this in a code cell before the installation of the topicmodels
package.
system2('sudo', 'apt-get install libgsl0-dev')
This installs a required library in the Unix environment of Colab that you would normally install from a command prompt like this.
sudo apt-get install libgsl0-dev
In Python notebooks, you would do this.
!sudo apt-get install libgsl0-dev
But this doesn't seem to work in R notebooks so the system2
call does the work.
error Installing topicmodels in R Ubuntu
You don't have GSL installed:
sudo apt-get install gsl-bin libgsl0-dev
installation of package had non-zero exit status
When you call install.packages("broom")
(or insert package), it appears the message you receive is:
Do you want to install from sources the packages which need compilation? (Yes/no/cancel)
to which you have answered yes
.
Try no
and compare results. This should fix the issue.
I can't install topicmodels package on OSX in R
This worked for me when trying to install "topicmodels" package on MacOS Mavericks: https://stackoverflow.com/a/24245311/3745085
How can I install topicmodels package in R?
First of all you have to install gsl
. Once you have that installed you can try to install the R package. You can download gsl from here (there you can pick the latest version gsl-latest.tar.gz
). Once it's been downloaded, install it by doing the following:
- Decompress the downloaded file (in my case the "latest" file contained this version:
gsl-1.16
) - Open the "Terminal"
Then (using the Terminal), move inside the folder that you created on step 1. In my case I had the file on the folder called "Downloads", so I moved to the newly created folder by doing:
cd Downloads/gsl-1.16
Once you are within that folder run the following commands (in order):
./configure
make
sudo make installAfter doing it you won't get the previous error saying
fatal error: 'gsl/gsl_rng.h' file not found
, so you can try again the installation.Now go back to your R environment (e.g., RStudio) to try again to install the package by doing:
install.packages("PATH_TO_TOPIC_MODELS.tar.gz", repos=NULL, type="source").
I had the same problem, and after doing this I got the R package correctly installed, I hope it also works in your case.
Warning in install.packages : installation of package ‘tidyverse’ had non-zero exit status
You find the answer in your error message:
------------------------ ANTICONF ERROR ---------------------------
Configuration failed because libcurl was not found. Try installing:
* deb: libcurl4-openssl-dev (Debian, Ubuntu, etc)
....
....
Copy and paste the following to your Terminal and than try installing tidyverse
again. Should solve the problem.
# Required for many packages
sudo apt-get install -y libxml2-dev libcurl4-openssl-dev libssl-dev
Related Topics
How to Start a Process in Its Own Process Group
Library Path Order for Alternate Glibc Dynamic Linker (Ld.So)
Rabbitmq - Get Messages from a Queue Using Curl
Linux/Libusb Get Usb Device Path
Ack & Negative Lookahead Giving Errors
Error Hh604: Error Running JSON-Rpc Server: Error:0308010C:Digital Envelope Routines::Unsupported
Apt-Update in Azure Nvidia Gives Publickey Error
Failed to Load Javahl Library.- Linux/Eclipse
Execute Command as a String in Bash
How to Find Performance of Individual Functions in a Process Using Perf Tool
Error Installing 'Topicmodels' Package, Non Zero Exit Status; Ubuntu
Can an Rpm Spec File "Include" Other Files
Cmake: Don't Set Rpath for a Single Library Used in Link
Difference Between Starting a Command Using Init.D Script and Service Start
List Files That Are in Directory1 But Not in Directory2 and Vice Versa