mirror of
https://gitlab.com/libvirt/libvirt.git
synced 2025-01-05 12:35:20 +00:00
c957791859
Signed-off-by: Pavel Hrdina <phrdina@redhat.com> Reviewed-by: Peter Krempa <pkrempa@redhat.com> Reviewed-by: Neal Gompa <ngompa13@gmail.com>
16 lines
288 B
Python
16 lines
288 B
Python
#!/usr/bin/env python3
|
|
|
|
import os
|
|
import sys
|
|
|
|
destdir = os.environ.get('DESTDIR', os.sep)
|
|
dirname = sys.argv[1]
|
|
target = sys.argv[2]
|
|
link = sys.argv[3]
|
|
|
|
workdir = os.path.join(destdir, dirname.strip(os.sep))
|
|
|
|
os.makedirs(workdir, exist_ok=True)
|
|
os.chdir(workdir)
|
|
os.symlink(target, link)
|