openbsd-ports/sysutils/ruby-facter/patches/patch-lib_facter_util_virtual_rb
2013-01-14 17:45:36 +00:00

15 lines
601 B
Plaintext

$OpenBSD: patch-lib_facter_util_virtual_rb,v 1.1 2013/01/14 17:45:36 robert Exp $
--- lib/facter/util/virtual.rb.orig Thu Dec 27 19:05:12 2012
+++ lib/facter/util/virtual.rb Mon Jan 14 18:43:57 2013
@@ -11,6 +11,10 @@ module Facter::Util::Virtual
# lspci is a delegating helper method intended to make it easier to stub the
# system call without affecting other calls to Facter::Util::Resolution.exec
def self.lspci(command = "lspci 2>/dev/null")
+ if Facter.value(:kernel) == "OpenBSD"
+ command = "pcidump 2>/dev/null"
+ end
+
Facter::Util::Resolution.exec command
end