Re: Re: Re: [PATCH 2/2] make: install/uninstall tools symlinks to kmod

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, 6 Feb 2024 at 16:15, Lucas De Marchi <lucas.demarchi@xxxxxxxxx> wrote:
>
> On Mon, Feb 05, 2024 at 05:50:54PM +0000, Emil Velikov wrote:
> >On Mon, 5 Feb 2024 at 14:30, Lucas De Marchi <lucas.demarchi@xxxxxxxxx> wrote:
> >
> >[snip]
> >
> >> >I'm not a huge fan of using relative symlinks, especially if the tool> >is run as root. In my experience that makes things harder to audit and
> >> >prevent accidental breakages.
> >>
> >> I'm completely in the opposite camp. Relative symlinks actually make
> >> sure the thing you are running is what you are expecting. Nothing should
> >> really point outside of $prefix expecting that is mounted on /.
> >>
> >
> >That is true and I fully agree. Yet the contents of DESTDIR are not
> >meant to be run as-is - it's used for "staging" [1].
> >
> >[1] https://www.gnu.org/software/make/manual/html_node/DESTDIR.html
> >
> >> Several years back there was also the issue with packaging, which would
> >> complain when symlinks pointed outside what was being packaged.  It is
> >> dangerous when using absolute symlinks because if the tool used to copy
> >> follows the symlinks, it ends up with the wrong binary, copying the host
> >> bin rather than what was just built.
> >>
> >
> >That sounds like a horrible bug, which can easily break your system
> >regardless of the project.
> >
> >Would you consider dropping the leading `./` aka can we use `$(LN_S)
> >kmod $(DESTDIR)$(bindir)/$$tool;`?
> >Seems to be prevailing on my system with over 90% instances.
>
> seems good to me. I will squash that and push.
>

Respectful poke?

Thanks
Emil




[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux