[Pkg-puppet-devel] [SCM] Packaging of Facter for debian branch, upstream, updated. 3a39dd8353b6308cf49522990104cc63e55d7cda

James Turnbull james at lovedthanlost.net
Fri Jan 29 17:22:25 UTC 2010


The following commit has been merged in the upstream branch:
commit aecac08aa3c27c8b7e1441d726a9711da7f6dff4
Author: Benedikt Böhm <bb at xnull.de>
Date:   Tue May 12 08:11:46 2009 +0100

    Fix #2155 - architecture facts on Gentoo
    
    This corrects the architecture results for Gentoo on x86 and amd64
    
    Patch from redmine

diff --git a/lib/facter/architecture.rb b/lib/facter/architecture.rb
index bc9910a..44fc97f 100644
--- a/lib/facter/architecture.rb
+++ b/lib/facter/architecture.rb
@@ -4,9 +4,20 @@ Facter.add(:architecture) do
         model = Facter.value(:hardwaremodel)
         case model
         # most linuxen use "x86_64"
-        when 'x86_64'
-            Facter.value(:operatingsystem) == "Debian" ? "amd64" : model;
-        when /(i[3456]86|pentium)/; "i386"
+        when "x86_64"
+            case Facter.value(:operatingsystem)
+            when "Debian", "Gentoo"
+                "amd64"
+            else
+                model
+            end
+        when /(i[3456]86|pentium)/
+            case Facter.value(:operatingsystem)
+            when "Gentoo"
+                "x86"
+            else
+                "i386"
+            end
         else
             model
         end

-- 
Packaging of Facter for debian



More information about the Pkg-puppet-devel mailing list