{"action":"created","issue":{"url":"https://api.github.com/repos/jasonroelofs/rice/issues/86","labels_url":"https://api.github.com/repos/jasonroelofs/rice/issues/86/labels{/name}","comments_url":"https://api.github.com/repos/jasonroelofs/rice/issues/86/comments","events_url":"https://api.github.com/repos/jasonroelofs/rice/issues/86/events","html_url":"https://github.com/jasonroelofs/rice/issues/86","id":90896966,"number":86,"title":"Incorrect $RICE_PREFIX when installed via bundler","user":{"login":"gravitystorm","id":360803,"avatar_url":"https://avatars.githubusercontent.com/u/360803?v=3","gravatar_id":"","url":"https://api.github.com/users/gravitystorm","html_url":"https://github.com/gravitystorm","followers_url":"https://api.github.com/users/gravitystorm/followers","following_url":"https://api.github.com/users/gravitystorm/following{/other_user}","gists_url":"https://api.github.com/users/gravitystorm/gists{/gist_id}","starred_url":"https://api.github.com/users/gravitystorm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/gravitystorm/subscriptions","organizations_url":"https://api.github.com/users/gravitystorm/orgs","repos_url":"https://api.github.com/users/gravitystorm/repos","events_url":"https://api.github.com/users/gravitystorm/events{/privacy}","received_events_url":"https://api.github.com/users/gravitystorm/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-06-25T08:43:24Z","updated_at":"2015-06-25T13:28:25Z","closed_at":null,"body":"When I install rice 1.7.0 via bundler (i.e. `bundle install` where the Gemfile contains `rice`) then the $RICE_PREFIX in ruby/lib/mkmf-rice.rb is incorrect:\r\n\r\n```\r\n grep \"RICE_PREFIX =\" /var/lib/gems/2.1.0/gems/rice-1.7.0/ruby/lib/mkmf-rice.rb\r\n  $RICE_PREFIX = \"/tmp/bundler20150625-3815-h5yg1drice-1.7.0/gems/rice-1.7.0/ruby/lib\"\r\n```\r\nWhen I install it using `gem install rice`, then the prefix is correct:\r\n\r\n```\r\n grep \"RICE_PREFIX =\" /var/lib/gems/2.1.0/gems/rice-1.7.0/ruby/lib/mkmf-rice.rb\r\n  $RICE_PREFIX = \"/var/lib/gems/2.1.0/gems/rice-1.7.0/ruby/lib\"\r\n```\r\n\r\nI assume bundler must behave differently, by copying the gem into location after the compilation is complete.\r\n\r\nDo you have any advice?\r\n\r\nCould $RICE_PREFIX be determined when the ruby code runs, rather than during the gem installation? I guess it's also not robust to e.g. bundle install --deployment followed by a directory rename.\r\n"},"comment":{"url":"https://api.github.com/repos/jasonroelofs/rice/issues/comments/115258382","html_url":"https://github.com/jasonroelofs/rice/issues/86#issuecomment-115258382","issue_url":"https://api.github.com/repos/jasonroelofs/rice/issues/86","id":115258382,"user":{"login":"jasonroelofs","id":3223,"avatar_url":"https://avatars.githubusercontent.com/u/3223?v=3","gravatar_id":"","url":"https://api.github.com/users/jasonroelofs","html_url":"https://github.com/jasonroelofs","followers_url":"https://api.github.com/users/jasonroelofs/followers","following_url":"https://api.github.com/users/jasonroelofs/following{/other_user}","gists_url":"https://api.github.com/users/jasonroelofs/gists{/gist_id}","starred_url":"https://api.github.com/users/jasonroelofs/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jasonroelofs/subscriptions","organizations_url":"https://api.github.com/users/jasonroelofs/orgs","repos_url":"https://api.github.com/users/jasonroelofs/repos","events_url":"https://api.github.com/users/jasonroelofs/events{/privacy}","received_events_url":"https://api.github.com/users/jasonroelofs/received_events","type":"User","site_admin":false},"created_at":"2015-06-25T13:28:25Z","updated_at":"2015-06-25T13:28:25Z","body":"That is strange, I had not yet tried installing Rice via bundler and that's weird that it picks up a tmp file like that. I'll have to look and see what bundler is doing and what we can do about this."}}