Skip to content

Commit 312e589

Browse files
committed
Fix Rakefile
1 parent 85af160 commit 312e589

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Rakefile

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ def patch_cmake_static_jemalloc
4444
return unless File.file?(file)
4545

4646
orig = "#{file}.orig"
47-
return if File.exist?(orig)
47+
orig = nil if File.exist?(orig)
4848

4949
content = File.read(file)
5050

@@ -56,7 +56,7 @@ def patch_cmake_static_jemalloc
5656
return if content.include?('add_library(jemalloc STATIC IMPORTED)')
5757

5858
content = jemalloc_declaration + "\n" + content
59-
File.write(orig, File.read(file))
59+
File.write(orig, File.read(file)) if orig
6060
File.write(file, content)
6161
puts "Inserted static jemalloc declaration into: #{file}"
6262
end

0 commit comments

Comments
 (0)