Skip to content

Commit

Permalink
- only set 'target' if the --rpm-os flag is set
Browse files Browse the repository at this point in the history
  (Fixes #321, #314, #309, #vagrant/1277)
  • Loading branch information
jordansissel committed Dec 27, 2012
1 parent fa05a0b commit d6f9e83
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions lib/fpm/package/rpm.rb
Expand Up @@ -200,8 +200,10 @@ def output(output_path)
args = ["rpmbuild", "-bb"]

# issue #309
rpm_target = "#{architecture}-unknown-#{attributes[:rpm_os]}"
args += ["--target", rpm_target]
if !attributes[:rpm_os].nil?
rpm_target = "#{architecture}-unknown-#{attributes[:rpm_os]}"
args += ["--target", rpm_target]
end

args += [
"--define", "buildroot #{build_path}/BUILD",
Expand Down

0 comments on commit d6f9e83

Please sign in to comment.