We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 85af160 commit 312e589Copy full SHA for 312e589
Rakefile
@@ -44,7 +44,7 @@ def patch_cmake_static_jemalloc
44
return unless File.file?(file)
45
46
orig = "#{file}.orig"
47
- return if File.exist?(orig)
+ orig = nil if File.exist?(orig)
48
49
content = File.read(file)
50
@@ -56,7 +56,7 @@ def patch_cmake_static_jemalloc
56
return if content.include?('add_library(jemalloc STATIC IMPORTED)')
57
58
content = jemalloc_declaration + "\n" + content
59
- File.write(orig, File.read(file))
+ File.write(orig, File.read(file)) if orig
60
File.write(file, content)
61
puts "Inserted static jemalloc declaration into: #{file}"
62
end
0 commit comments