Does anyone have had this same error before while installing ruby 2.0.0 in rails 4.0?
all this in a MAC OS X 10.8.2
Error running 'make -j4'
couldn't find any answers.
I agree with devnull, we would need a log of some sort to narrow down your problem.
Though I did just install ruby 2.0 on a mac 10.8.4 yesterday using RVM.
Try following the instructions here. That made it very simple.
FWIW, here's the process I went through. Some of the commands might be specific to my environment and you may have to adjust accordingly. This process was a mix and mash of recommendations from various sources, but also following along with whatever the output spit out. I found that I was unable to install ruby 2.0 just from following other stack overflow threads as written, so I had to improvise, somewhat. Hope this helps.
Made sure i downloaded the latest Xcode and Command Line tool (seems to be the general recommendation out there)
run 'brew doctor'
run 'brew update'
run 'rvm requirements'
run 'rvm get head'
Kept seeing this error "Can not automatically remove lines with 'rvm_autolibs_flag=' from '/etc/rvmrc', please clean it manually."
run 'rvmsudo --debug' #as recommended in terminal, but this still wasn't fixing the problem, so i tried....
run 'rvmsudo rvm get head' #because the output recommended 'prefix the command with rvmsudo to fix it'
run 'rvm requirements'
run 'rvm install 2.0.0' #error "There is no checksum for 'http://production.cf.rubygems.org/rubygems/rubygems-2.0.5.tgz' or 'rubygems-2.0.5.tgz', it's not possible to validate it.......If that does not resolve the issue and you wish to continue with unverified download
add '--verify-downloads 1' after the command."
run 'rvm reinstall 2.0.0 --verify-downloads 1'
run 'rvm default 2.0.0'
And it finally worked. My Ruby verison is now ruby 2.0.0p247 (2013-06-27 revision 41674) [x86_64-darwin12.4.0].
Related
I'm trying to get a Ruby on Rails project running on my Mac OS Sierra (10.13.3) machine. When I navigate to the Rails folder, RVM tells me the following:
Required ruby-1.9.3-p392 is not installed.
To install do: 'rvm install "ruby-1.9.3-p392"'
However, when I do that install, I get the following:
$ rvm install "ruby-1.9.3-p392"
Searching for binary rubies, this might take some time.
No binary rubies available for: osx/10.13/x86_64/ruby-1.9.3-p392.
Continuing with compilation. Please read 'rvm help mount' to get more information on binary rubies.
Checking requirements for osx.
Installing requirements for osx.
Updating system..........
Installing required custom packages: homebrew/versions.
Error running 'requirements_osx_brew_install_custom homebrew/versions',
please read /Users/petercormack/.rvm/log/1518211184_ruby-1.9.3-p392/install_custom.log
Requirements installation failed with status: 1.
When I look at that log file, I see the following:
[2018-02-09 12:36:30] requirements_osx_brew_install_custom
requirements_osx_brew_install_custom ()
{
\typeset __tap;
for __tap in "$#";
do
brew tap "${__tap}" || return $?;
done
}
current path: /Users/petercormack/podcastsi18n
PATH=/usr/local/opt/qt#5.5/bin:/Users/petercormack/.node/bin:/usr/local/bin:/Applications/Postgres.app/Contents/Versions/latest/bin:/usr/local/bin:/usr/bin:/bin:/usr/sbin:/sbin:/Users/petercormack/.rvm/bin:/usr/local/Cellar/openssl/1.0.2j/bin/openssl
command(2): requirements_osx_brew_install_custom homebrew/versions
+ typeset __tap
+ for __tap in '"$#"'
+ brew tap homebrew/versions
Error: homebrew/versions was deprecated. This tap is now empty as all its formulae were migrated.
+ return 1
So. RVM seems to be stuck on this idea of installing homebrew/versions, which has been completely removed by Homebrew. I've updated Homebrew. I've updated RVM. I've tried to trick Homebrew into having that tap available (not successful). I've tried to trick RVM into thinking that's not a required custom package (couldn't figure out how). Nothing seems to be working. Help!
EDIT
I got around the problem by actually upgrading the project to use ruby-2.1.0 . Worked like a charm, but of course didn't actually resolve the original issue. Thank you for the answers below, and hopefully they'll help out some other poor soul in the same situation!
I tripped up on this as well. While it's not a final answer with the help of a kind soul on Github I was able to find a temporary solution to this issue.
If you are running macOS 10.10 or later then you should run brew install gcc49. This will help RVM as it now won't try to tap the deprecated homebrew versions repository. If you are on an earlier version have a look at this function in RVM for the appropriate version of gcc to install.
I have documented the issue I was encountering over here:
https://github.com/rvm/rvm/issues/4303
Had the same problem. This happens only when installing a ruby version older than 2.0. I was able to get past this using rvm autolibs read-only then install the ruby again. This will tell rvm to use existing dependencies and to skip the error if something is missing. Just then try to manually install all the required packages using Brew.
https://rvm.io/rvm/autolibs
I had the same problem when I tried to install Ruby 3.0 . For me just updating RVM to the latest version fixed the issue:
rvm get stable
I just logged into my Ubuntu workspace on Cloud9. Upon logging in I saw an error.
RVM used your Gemfile for selecting Ruby, it is all fine - Heroku does
that too, you can ignore these warnings with 'rvm rvmrc warning ignore
/home/ubuntu/workspace/Simutronix/Gemfile'. To ignore the warning for
all files run 'rvm rvmrc warning ignore allGemfiles'.
Which I've not seen before and wasn't occurring when I last used the workspace. I then attempted to run the Rails server.
rails server -b $IP -p $PORT
I got an error message back.
bash: rails: command not found
I then tried to run bundle install which also came back with command not found.
ruby -v returns ruby 2.4.1p111 (2017-03-22 revision 58053) [x86_64-linux].
What's likely to have happened to cause this to happen in between logins and what can I do to fix it?
Looks like Ubuntu can't find your Rails installation. Make sure you have Rails installed on your workspace by typing:
rails -v
If it is properly installed, It should return something like
Rails 5.0.2
(depending upon your Rails version.)
If you don't have Rails installed, you can install it by typing
gem install rails
You can append --no-doc to the above command if you don't want it to install documentation, thereby speeding up the installation process (That's totally up to you, though. It won't affect your installation in any other way. I promise!)
If this doesn't solve your problem, please update your answer with your Gemfile.
Likely the Ruby version defined in your Gemfile and/or .ruby-version changed, which means you will have to install bundler and bundle the gems again. Running this should solve the issue:
gem install bundler
bundle install
Versions
Mac OS: OSX 10.10.2
Ruby: 2.2.1p85
Rails: 4.2.0
Context
I am following the "Install Rails" tutorial online at www.installrails.com. Finally made it through after encountering many errors. I am on the last step of creating a sample app, which it worked fine, and then running the server. Now, I run into another error.
Errors
Here is what I am seeing:
/Users/Work/.rvm/gems/ruby-2.2.1/gems/json-1.8.2/lib/json/ext/parser.bundle: [BUG] Segmentation fault at 0x00000000000418
ruby 2.2.1p85 (2015-02-26 revision 49769) [x86_64-darwin14]
-- Crash Report log information --------------------------------------------
See Crash Report log file under the one of following:
* ~/Library/Logs/CrashReporter
* /Library/Logs/CrashReporter
* ~/Library/Logs/DiagnosticReports
* /Library/Logs/DiagnosticReports
for more details.
-- Control frame information -----------------------------------------------
*A lot of information listed here*
-- Ruby level backtrace information ----------------------------------------
*A lot of information listed here*
-- Machine register context ------------------------------------------------
*A lot of information listed here*
-- C level backtrace information -------------------------------------------
*A lot of information listed here*
-- Other runtime information -----------------------------------------------
* Loaded script: bin/rails
* Loaded features:
*And then a long list of files listed here*
[NOTE]
You may have encountered a bug in the Ruby interpreter or extension libraries.
Bug reports are welcome.
Don't forget to include the above Crash Report log file.
For details: http://www.ruby-lang.org/bugreport.html
Abort trap: 6
Help
Now, I am wondering if it is the json gem that is causing a problem?
Let me know if you need any of the removed information. The bug report was really long so I removed the codes where it says A lot of information listed here for brevity.
Per a suggestion by #maxd, I ended up having to uninstall and reinstall ruby.
Here is the process I followed.
I uninstalled Ruby with command line rvm remove 2.2.1
I reinstall 2.2.1 with the command line rvm install 2.2.1
Then I reinstalled rails with command line sudo gem install rails
Then I used bundle install to reinstall missing gems
Next, I used gem install rubygems-update to update Rubygems from 2.0.14 to 2.1.
Then I reset gems to pristine condition with gem pristine --all.
Then for some reason I had to rerun bundle install because actionmailer 4.2.0 was no longer showing as being installed, even though it was in the list after the first bundle install.
Finally running rails -v gave me an output of Rails 4.2.0 instead of error codes.
So, I ran rails server and all is well.
I solved this problem. But I not certain this is a GOOD way.
first, I reinstalled ruby. since, I looks like version problem as I see.
rvm reinstall all
and gem install rails. After this process, I can run server with rails server command.
I hope this could be a your solution too. Have a good day :D
I was experiencing the same problem in my mac mini(M1). The following solution worked for me found in the developer forum.
sudo arch -x86_64 gem install ffi
Then
arch -x86_64 pod install
Just got a new macbook pro and im having troubles installing rails..
I got ruby 1.8.7 already installed and when i try to write 'gem install rails' i get:
ERROR: While executing gem ... (Gem::FilePermissionError)
You don't have write permissions into the /Library/Ruby/Gems/1.8 directory.
I also tried to install a higher version of ruby and it said:
Nirs-MacBook-Pro:~ nirohayon$ rvm install 1.9.3
Fetching yaml-0.1.4.tar.gz to /Users/nirohayon/.rvm/archives
Extracting yaml-0.1.4.tar.gz to /Users/nirohayon/.rvm/src
Configuring yaml in /Users/nirohayon/.rvm/src/yaml-0.1.4.
Error running ' ./configure --prefix="/Users/nirohayon/.rvm/usr" ', please read /Users/nirohayon/.rvm/log/ruby-1.9.3-p125/yaml/configure.log
Compiling yaml in /Users/nirohayon/.rvm/src/yaml-0.1.4.
Error running 'make ', please read /Users/nirohayon/.rvm/log/ruby-1.9.3-p125/yaml/make.log
Database file /Users/nirohayon/.rvm/config/packages does not exist.
Installing Ruby from source to: /Users/nirohayon/.rvm/rubies/ruby-1.9.3-p125, this may take a while depending on your cpu(s)...
ruby-1.9.3-p125 - #fetching
ruby-1.9.3-p125 - #extracted to /Users/nirohayon/.rvm/src/ruby-1.9.3-p125 (already extracted)
ruby-1.9.3-p125 - #configuring
Error running ' ./configure --prefix=/Users/nirohayon/.rvm/rubies/ruby-1.9.3-p125 --enable-shared --disable-install-doc --with-libyaml --with-opt-dir=/Users/nirohayon/.rvm/usr ', please read /Users/nirohayon/.rvm/log/ruby-1.9.3-p125/configure.log
There has been an error while running configure. Halting the installation.
ls: /Users/nirohayon/.rvm/rubies/*/bin/ruby: No such file or directory
PLEASE help me, i used windows before and also pretty new to rails, so i dont know much about which path should i direct my terminal. i need a step by step explanation to put rails up and standing on my mac.
Thanks so much!
Nir
Your use of RVM looks a lot like you don't have the developer tools installed. Grab XCode from the App Store, the install the command line tools!
If you really want to install rails on the platform-provided ruby, all you need to do is to sudo gem install rails, for you need to use administrator privileges to isntall gems in the system gemset.
This tutorial helped me install on mac before with OS X 10.6 (I believe). The only thing that was a trouble was the C compiler, which I figured out was the problem from looking up one of the errors.
Probably you will find by looking up the output Error running 'make ', please read /Users/nirohayon/.rvm/log/ruby-1.9.3-p125/yaml/make.log by typing vi /Users/nirohayon/.rvm/log/ruby-1.9.3-p125/yaml/make.log type esc key followed by typing :q! to quit.
As previous answer suggested, you need to get a compiler. I don't know about Xcode specifics, but I tracked down an installer for GCC compiler for Mac on Github I believe but it is probably better straight from Apple packages, (tutorial here)
Also note that if you end up having to use sudo at all, you've probably gone off-track from the guide to install RVM on your system. In which case your path will be somewhere other than in the home directory and the instruction to adjust your source with echo '[[ -s "$HOME/.rvm/scripts/rvm" ]] && source "$HOME/.rvm/scripts/rvm"' >> ~/.bash_profile will not work. Which may end up being somewhere like "/usr/local/rvm/scripts/rvm"
when I run
rvm install 1.9.2
I get an error trying to run autoconf. This is the stacktrace:
kenmare:ruby-1.9.2-p0 lee$ rvm install 1.9.2-p0
/Users/lee/.rvm/rubies/ruby-1.9.2-p0, this may take a while depending on your cpu(s)...
ruby-1.9.2-p0 - #fetching
ruby-1.9.2-p0 - #extracted to /Users/lee/.rvm/src/ruby-1.9.2-p0 (already extracted)
Running autoconf
Error running 'autoconf', please check /Users/lee/.rvm/log/ruby-1.9.2-p0/autoconf.error.log
Skipping configure step, 'configure' does not exist, did autoconf not run successfully?
ruby-1.9.2-p0 - #compiling
Error running 'make ', please check /Users/lee/.rvm/log/ruby-1.9.2-p0/make.error.log
There has been an error while running make. Halting the installation.
Any ideas? Thanks!
UPDATE: Sorry it was late and didn't give some obvious info. I am on a mac running 10.6.4. The autoconf log says:
autoconf: no input file
To the answer regarding make, when I run
which make
/usr/bin/make
And I have am running 1.8.7 successfully with rvm. I only receive this problem when installing 1.9.2.
Thanks again!
This happened to me because my rvm version was old
rvm list known
wasn't showing ruby 1.9.3 as one of the options for me
I did:
rvm get head
I figured it out. The key is this line:
ruby-1.9.2-p0 - #extracted to /Users/lee/.rvm/src/ruby-1.9.2-p0 (already extracted)
Apparently if there is an error during your first attempt the directory for the 1.9.2 package is not removed. (In my case, the autoconf files were not properly downloaded.) Any subsequent attempts see the directory and does not attempt to download the package again.
You need to remove the ruby-1.9.2-p0 directory. I assume this could be a problem with any version.
Hope this helps someone else.
I just had a similar problem. In addition to what Lee did to solve, I also had to remove the corresponding ruby's tar file from .rvm/archives so it would download a fresh copy that was not corrupt/incomplete.
In my case I had to upgrade RVM. Running this in the shell took care of upgrading:
bash -s stable < <(curl -s https://raw.github.com/wayneeseguin/rvm/master/binscripts/rvm-installer)