rake aborts with "File exists @ dir_s_mkdir - ./rake.d/dependency.d" error
I started getting this rake error when building mkvtoolnix 19.0.0 after Fedora upgraded Ruby to version 2.5:
rake aborted! File exists @ dir_s_mkdir - ./rake.d/dependency.d
An analysis by Vít Ondruch suggests this is a race condition when running
-jN option, though I'm not sure why it didn't show up with Ruby 2.4.x.
This was originally reported in Fedora as bug #1532391.
One fix could be to do something like:
sed -i 's/Dir\.mkdir.*$/FileUtils.mkdir_p(dir)/' rake.d/helpers.rb