Fix build when enable_shared is on (#6924)

Before this change, if enable_shared was true, the directory would have a suffix of -static and be deleted on each make install. This would cause a second make install to fail.
This commit is contained in:
Jimmy Miller 2022-12-14 00:59:21 -05:00 committed by GitHub
parent a7cf39bba8
commit 2d5b723b2f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
Notes: git 2022-12-14 05:59:40 +00:00
Merged-By: k0kubun <takashikkbn@gmail.com>

View File

@ -111,7 +111,7 @@ end
version = RbConfig::CONFIG['ruby_version']
curdir.glob(".bundle/{extensions,.timestamp}/#{platform}/*/") do |dir|
unless File.basename(dir) == version
unless File.basename(dir).start_with?(version)
curdir.rmdir(dir)
end
end