Bug 180246 - [patch] lang/ruby20: update to 2.0.0p247
Summary: [patch] lang/ruby20: update to 2.0.0p247
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Steve Wills
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-07-04 02:40 UTC by mike
Modified: 2013-11-23 03:36 UTC (History)
0 users

See Also:


Attachments
file.diff (5.09 KB, patch)
2013-07-04 02:40 UTC, mike
no flags Details | Diff
smime.p7s (5.91 KB, application/pkcs7-signature)
2013-07-09 00:05 UTC, mike
no flags Details
smime.p7s (5.91 KB, application/pkcs7-signature)
2013-07-09 21:25 UTC, mike
no flags Details

Note You need to log in before you can comment on or make changes to this bug.
Description mike 2013-07-04 02:40:00 UTC
Can we update the Ruby20 port to the latest release on ruby-lang.org?

Fix: see svn diff attached


Patch attached with submission follows:
How-To-Repeat: Just a port update request, no real issue
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2013-07-04 02:40:10 UTC
Responsible Changed
From-To: freebsd-ports-bugs->ruby

Over to maintainer (via the GNATS Auto Assign Tool)
Comment 2 mike 2013-07-09 00:05:37 UTC
The patch I supplied above is not working as I thought...

The problem seems to be with the lib/mkmf.rb patch, its installing 
compiled so' in an invalid location.

For example, installing databases/rubygem-pg installs the pg_ext.so here:

/usr/local/lib/ruby/gems/2.0/gems/pg-0.15.1/lib/usr/local/lib/ruby/site_ruby/2.0/amd64-freebsd9/pg_ext.so

instead of:
/usr/local/lib/ruby/gems/2.0/gems/pg-0.15.1/lib/pg_ext.so

Comment 3 Stanislav Sedov freebsd_committer freebsd_triage 2013-07-09 03:44:27 UTC
On Jul 8, 2013, at 11:30 PM, Mike Carlson <mike@bayphoto.com> wrote:

> The patch I supplied above is not working as I thought...
> 
> The problem seems to be with the lib/mkmf.rb patch, its installing=20
> compiled so' in an invalid location.
> 
> For example, installing databases/rubygem-pg installs the pg_ext.so here:=
> 
> 
> /usr/local/lib/ruby/gems/2.0/gems/pg-0.15.1/lib/usr/local/lib/ruby/site_r=
> uby/2.0/amd64-freebsd9/pg_ext.so
> 
> instead of:
> /usr/local/lib/ruby/gems/2.0/gems/pg-0.15.1/lib/pg_ext.so

That's weird.  Did they change the internal logic of mkmf.rb?

--
ST4096-RIPE
Comment 4 mike 2013-07-09 21:25:48 UTC
On 7/8/2013 7:44 PM, Stanislav Sedov wrote:
> On Jul 8, 2013, at 11:30 PM, Mike Carlson <mike@bayphoto.com> wrote:
>
>> The patch I supplied above is not working as I thought...
>>
>> The problem seems to be with the lib/mkmf.rb patch, its installing=20
>> compiled so' in an invalid location.
>>
>> For example, installing databases/rubygem-pg installs the pg_ext.so here:=
>>
>>
>> /usr/local/lib/ruby/gems/2.0/gems/pg-0.15.1/lib/usr/local/lib/ruby/site_r=
>> uby/2.0/amd64-freebsd9/pg_ext.so
>>
>> instead of:
>> /usr/local/lib/ruby/gems/2.0/gems/pg-0.15.1/lib/pg_ext.so
> That's weird.  Did they change the internal logic of mkmf.rb?
>
> --
> ST4096-RIPE

Yeah, I attempted to just use the same patch from 2.0.0p195, and it did 
not apply cleanly. I removed the patch-lib_mkmf.rb and attempted to use 
the upstream mkmf.rb, but the same issue came up, .so's would get 
installed in the wrong location and loading the module would fail.

Our developer is requesting 2.0.0p247, so I did this in a quick attempt 
to bump the port version. This seems to be more complex than I thought 
and requires an expert set of eyes.

I can help test though.

Mike C
Comment 5 Steve Wills freebsd_committer freebsd_triage 2013-07-19 14:05:34 UTC
Responsible Changed
From-To: ruby->swills

I'll take it.
Comment 6 m87carlson 2013-09-18 02:37:33 UTC
Any update on this?
Comment 7 Steve Wills freebsd_committer freebsd_triage 2013-11-23 03:36:02 UTC
State Changed
From-To: open->closed

Wasn't able to reproduce the gem/mkmf issue, so went ahead and committed 
this with slight changes to remove unneeded changes, fix cont.c and 
update to the newer ruby 2.0.0 which fixes a CVE, see r334630. If the 
gem/mkmf issue appears for others, updating devel/ruby-gems to 1.8.28 
should fix it. That's planned for soon anyway. Thanks for the patch, 
sorry for the slow response time.