Re: [Mesa-dev] [PATCH v5 07/13] meson: extend install_megadrivers script to handle symmlinking
Quoting Eric Engestrom (2017-11-21 02:39:44) > On Monday, 2017-11-20 11:09:39 -0800, Dylan Baker wrote: > > Which is required for the gallium media state trackers. > > > > v4: - Make the full version the hard link and the partial so versiions > > the symlinks > > v5: - drop --so-version all-together. Instead pass the full name of the > > DSO and the script will automatically generate the appropriate > > symlinks as necessary. > > I'm ok with this solution :) > One typo in the commit title ("symmlinking" s/mm/m/), but this patch and > patch 8/13 are: > Reviewed-by: Eric Engestrom > > (sorry for being a bit of a pain with the previous revisions of this patch) > > I had a look at the rest of the series and didn't notice anything wrong, > but that's not an actual review. > No worries, I'd rather have people reviewing my patches and forcing me to make things better than ignoring them. signature.asc Description: signature ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev
Re: [Mesa-dev] [PATCH v5 07/13] meson: extend install_megadrivers script to handle symmlinking
On Monday, 2017-11-20 11:09:39 -0800, Dylan Baker wrote: > Which is required for the gallium media state trackers. > > v4: - Make the full version the hard link and the partial so versiions > the symlinks > v5: - drop --so-version all-together. Instead pass the full name of the > DSO and the script will automatically generate the appropriate > symlinks as necessary. I'm ok with this solution :) One typo in the commit title ("symmlinking" s/mm/m/), but this patch and patch 8/13 are: Reviewed-by: Eric Engestrom (sorry for being a bit of a pain with the previous revisions of this patch) I had a look at the rest of the series and didn't notice anything wrong, but that's not an actual review. > > Signed-off-by: Dylan Baker > --- > bin/install_megadrivers.py | 8 > 1 file changed, 8 insertions(+) > > diff --git a/bin/install_megadrivers.py b/bin/install_megadrivers.py > index a98d7dd177b..587a1f6726d 100755 > --- a/bin/install_megadrivers.py > +++ b/bin/install_megadrivers.py > @@ -44,10 +44,18 @@ def main(): > > for each in args.drivers: > driver = os.path.join(to, each) > + > if os.path.exists(driver): > os.unlink(driver) > print('installing {} to {}'.format(args.megadriver, driver)) > os.link(master, driver) > + > +name, ext = os.path.splitext(driver) > +while ext != '.so': > +if os.path.exists(name): > +os.unlink(name) > +os.symlink(driver, name) > +name, ext = os.path.splitext(name) > os.unlink(master) > > > -- > 2.15.0 > ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev
[Mesa-dev] [PATCH v5 07/13] meson: extend install_megadrivers script to handle symmlinking
Which is required for the gallium media state trackers. v4: - Make the full version the hard link and the partial so versiions the symlinks v5: - drop --so-version all-together. Instead pass the full name of the DSO and the script will automatically generate the appropriate symlinks as necessary. Signed-off-by: Dylan Baker --- bin/install_megadrivers.py | 8 1 file changed, 8 insertions(+) diff --git a/bin/install_megadrivers.py b/bin/install_megadrivers.py index a98d7dd177b..587a1f6726d 100755 --- a/bin/install_megadrivers.py +++ b/bin/install_megadrivers.py @@ -44,10 +44,18 @@ def main(): for each in args.drivers: driver = os.path.join(to, each) + if os.path.exists(driver): os.unlink(driver) print('installing {} to {}'.format(args.megadriver, driver)) os.link(master, driver) + +name, ext = os.path.splitext(driver) +while ext != '.so': +if os.path.exists(name): +os.unlink(name) +os.symlink(driver, name) +name, ext = os.path.splitext(name) os.unlink(master) -- 2.15.0 ___ mesa-dev mailing list mesa-dev@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/mesa-dev