Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 18 May 2016 12:07:42 +0000 (UTC)
From:      Baptiste Daroussin <bapt@FreeBSD.org>
To:        ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org
Subject:   svn commit: r415436 - in head/sysutils/puppet37: . files
Message-ID:  <201605181207.u4IC7gO3062171@repo.freebsd.org>

next in thread | raw e-mail | index | archive | help
Author: bapt
Date: Wed May 18 12:07:42 2016
New Revision: 415436
URL: https://svnweb.freebsd.org/changeset/ports/415436

Log:
  Fix with ruby 2.2
  
  Sponsored by:	Gandi.net

Added:
  head/sysutils/puppet37/files/patch-lib_puppet_vendor_safe__yaml_lib_safe__yaml.rb   (contents, props changed)
  head/sysutils/puppet37/files/patch-spec_unit_reports_store__spec.rb   (contents, props changed)
Modified:
  head/sysutils/puppet37/Makefile

Modified: head/sysutils/puppet37/Makefile
==============================================================================
--- head/sysutils/puppet37/Makefile	Wed May 18 11:59:57 2016	(r415435)
+++ head/sysutils/puppet37/Makefile	Wed May 18 12:07:42 2016	(r415436)
@@ -3,7 +3,7 @@
 
 PORTNAME=	puppet
 PORTVERSION=	3.7.5
-PORTREVISION=	1
+PORTREVISION=	2
 CATEGORIES=	sysutils
 MASTER_SITES=	http://downloads.puppetlabs.com/puppet/
 PKGNAMESUFFIX=	37
@@ -34,13 +34,6 @@ SUB_LIST=	RUBY=${RUBY}
 
 OPTIONS_DEFINE=		DOCS EXAMPLES
 
-.include <bsd.port.pre.mk>
-
-# puppet 4.x should support ruby 2.2.x
-.if ${RUBY_VER} >= 2.2
-BROKEN=		Does not work with Ruby 2.2
-.endif
-
 post-patch:
 	@${REINPLACE_CMD} -e "s|/etc/puppet|${ETCDIR}|" \
 		${WRKSRC}/install.rb \
@@ -74,4 +67,4 @@ do-install:
 	cd ${WRKSRC}/examples/ && ${COPYTREE_SHARE} . ${STAGEDIR}${EXAMPLESDIR}
 	${INSTALL_DATA} ${WRKSRC}/ext/rack/example-passenger-vhost.conf ${STAGEDIR}${EXAMPLESDIR}
 
-.include <bsd.port.post.mk>
+.include <bsd.port.mk>

Added: head/sysutils/puppet37/files/patch-lib_puppet_vendor_safe__yaml_lib_safe__yaml.rb
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sysutils/puppet37/files/patch-lib_puppet_vendor_safe__yaml_lib_safe__yaml.rb	Wed May 18 12:07:42 2016	(r415436)
@@ -0,0 +1,11 @@
+--- lib/puppet/vendor/safe_yaml/lib/safe_yaml.rb.orig	2015-03-25 16:32:47 UTC
++++ lib/puppet/vendor/safe_yaml/lib/safe_yaml.rb
+@@ -3,7 +3,7 @@ require "yaml"
+ # This needs to be defined up front in case any internal classes need to base
+ # their behavior off of this.
+ module SafeYAML
+-  YAML_ENGINE = defined?(YAML::ENGINE) ? YAML::ENGINE.yamler : "syck"
++  YAML_ENGINE = defined?(YAML::ENGINE) ? YAML::ENGINE.yamler : (defined?(Psych) && YAML == Psych ? "psych" : "syck")
+ end
+ 
+ require "set"

Added: head/sysutils/puppet37/files/patch-spec_unit_reports_store__spec.rb
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/sysutils/puppet37/files/patch-spec_unit_reports_store__spec.rb	Wed May 18 12:07:42 2016	(r415436)
@@ -0,0 +1,11 @@
+--- spec/unit/reports/store_spec.rb.orig	2015-03-25 16:32:48 UTC
++++ spec/unit/reports/store_spec.rb
+@@ -24,7 +24,7 @@ describe processor do
+     end
+ 
+     it "should write the report to the file in YAML" do
+-      Time.stubs(:now).returns(Time.parse("2011-01-06 12:00:00 UTC"))
++      Time.stubs(:now).returns(Time.utc(2011,01,06,12,00,00))
+       @report.process
+ 
+       File.read(File.join(Puppet[:reportdir], @report.host, "201101061200.yaml")).should == @report.to_yaml



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201605181207.u4IC7gO3062171>