Skip to content

Commit

Permalink
mail/rubygem-mail: Fix dependency with Ruby 3.1
Browse files Browse the repository at this point in the history
In Ruby 3.1 net/smtp is distributed as bundled gem. On the other hand,
our ruby ports (lang/rubyXY) don't include bundled gems in their
packages and it also applies to lang/ruby31. That means net/smtp isn't
include in the package of Ruby 3.1. So add mail/rubygem-net-smtp to
RUN_DEPENDS so this port works fine with Ruby 3.1.

PR:		262088
Approved by:	portmgr (blanket: dependency fix)
MFH:		2022Q1 (dependency fix)
  • Loading branch information
Yasuhiro Kimura authored and Yasuhiro Kimura committed Mar 19, 2022
1 parent fd23195 commit da6b780
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 1 deletion.
4 changes: 3 additions & 1 deletion mail/rubygem-mail/Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@

PORTNAME= mail
PORTVERSION= 2.7.1
PORTREVISION= 1
PORTEPOCH= 2
CATEGORIES= mail rubygems
MASTER_SITES= RG
Expand All @@ -12,7 +13,8 @@ COMMENT= Ruby email handler
LICENSE= MIT
LICENSE_FILE= ${WRKSRC}/MIT-LICENSE

RUN_DEPENDS= rubygem-mini_mime>=0.1.1:mail/rubygem-mini_mime
RUN_DEPENDS= rubygem-mini_mime>=0.1.1:mail/rubygem-mini_mime \
rubygem-net-smtp>0:mail/rubygem-net-smtp

USES= cpe gem
CPE_VENDOR= ${PORTNAME}_project
Expand Down
18 changes: 18 additions & 0 deletions mail/rubygem-mail/files/patch-mail.gemspec
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
--- mail.gemspec.orig 2021-11-10 18:38:59 UTC
+++ mail.gemspec
@@ -24,6 +24,7 @@ Gem::Specification.new do |s|
end

if s.respond_to? :add_runtime_dependency then
+ s.add_runtime_dependency(%q<net-smtp>.freeze, [">= 0"])
s.add_runtime_dependency(%q<mini_mime>.freeze, [">= 0.1.1"])
s.add_development_dependency(%q<bundler>.freeze, [">= 1.0.3"])
s.add_development_dependency(%q<rake>.freeze, ["> 0.8.7"])
@@ -31,6 +32,7 @@ Gem::Specification.new do |s|
s.add_development_dependency(%q<rdoc>.freeze, [">= 0"])
s.add_development_dependency(%q<rufo>.freeze, [">= 0"])
else
+ s.add_dependency(%q<net-smtp>.freeze, [">= 0"])
s.add_dependency(%q<mini_mime>.freeze, [">= 0.1.1"])
s.add_dependency(%q<bundler>.freeze, [">= 1.0.3"])
s.add_dependency(%q<rake>.freeze, ["> 0.8.7"])

0 comments on commit da6b780

Please sign in to comment.