Skip to content

Commit 4291e5e

Browse files
committed
Fix ext/rabbitmq/Rakefile to remove unnecessary files on install.
1 parent 222184a commit 4291e5e

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

ext/rabbitmq/Rakefile

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ require 'ffi'
44

55
FILES = {}
66

7-
task :default => :build
7+
task :default => [:build, :compact]
88

99
def self.file_task(filename, opts, &block)
1010
name, dep = opts.is_a?(Hash) ? opts.to_a.first : [opts, nil]
@@ -45,3 +45,9 @@ file_task "librabbitmq.#{::FFI::Platform::LIBSUFFIX}", :build => :configure do
4545
cmd "/usr/bin/env sh -c 'cd #{FILES[:download]} && make'"
4646
cmd "cp #{FILES[:download]}/librabbitmq/.libs/#{FILES[:build]} ."
4747
end
48+
49+
task :compact => FILES[:build] do
50+
FILES.each do |key, filename|
51+
cmd "rm -rf #{filename}" unless key == :build
52+
end
53+
end

0 commit comments

Comments
 (0)