void-packages/srcpkgs/mesa/patches/megadriver-symlinks.patch

26 lines
857 B
Diff
Raw Normal View History

This converts megadriver installation to use symlinks so that we do
not have to deal with skipping the strip stage for some files, as
a result simplifying our template greatly.
--- a/bin/install_megadrivers.py
+++ b/bin/install_megadrivers.py
@@ -56,7 +56,7 @@ def main():
if os.path.lexists(abs_driver):
os.unlink(abs_driver)
print('installing {} to {}'.format(args.megadriver, abs_driver))
- os.link(master, abs_driver)
+ os.symlink(os.path.basename(master), abs_driver)
try:
ret = os.getcwd()
@@ -71,8 +71,7 @@ def main():
finally:
os.chdir(ret)
- # Remove meson-created master .so and symlinks
- os.unlink(master)
+ # Remove meson-created symlinks
name, ext = os.path.splitext(master)
while ext != '.so':
if os.path.lexists(name):