Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1238831

Re: [PATCH] ver_linux: module-init-tools.patch

From Alexander Kapshuk <alexander.kapshuk@gmail.com>
Newsgroups linux.kernel
Subject Re: [PATCH] ver_linux: module-init-tools.patch
Date 2015-10-03 14:20 +0200
Message-ID <qftXb-1xb-3@gated-at.bofh.it> (permalink)
References (3 earlier) <qfels-4sN-5@gated-at.bofh.it> <qfev7-4DY-7@gated-at.bofh.it> <qff7R-5Cf-25@gated-at.bofh.it> <qffAS-6a6-9@gated-at.bofh.it> <qfhMm-10f-7@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


On Sat, Oct 3, 2015 at 2:14 AM, Jim Davis <jim.epost@gmail.com> wrote:
> On Fri, Oct 2, 2015 at 1:57 PM, Alexander Kapshuk
> <alexander.kapshuk@gmail.com> wrote:
>> On Fri, Oct 2, 2015 at 11:22 PM, Alexander Kapshuk
>> <alexander.kapshuk@gmail.com> wrote:
>>> On Fri, Oct 2, 2015 at 10:45 PM, Jim Davis <jim.epost@gmail.com> wrote:
>>>> On Fri, Oct 2, 2015 at 12:35 PM, Jim Davis <jim.epost@gmail.com> wrote:
>>>>> On Fri, Oct 2, 2015 at 12:03 PM, Alexander Kapshuk
>>>>>
>>>>>>>> +depmod=`whereis depmod | awk '{print $2}'`
>>>>>>>
>>>>
>>>>> I suspect it'll be hard to come up with something that's 100%
>>>>> foolproof and respects user's choices.  Sticking with searching the
>>>>> user's $PATH at least won't lead to surprises about which program is
>>>>> being run...
>>>>
>>>> Though looking back at your patch, what might work is to look first
>>>> for depmod in the user's $PATH and then try whereis only if that
>>>> fails.  I'm not convinced that's much better than just searching
>>>> $PATH, but that at least would go with the user's preference first.
>>>>
>>>> --
>>>> Jim
>>>
>>> Seems like the way to go. Thanks.
>>>
>>> I'll resubmit this and the other patches tomorrow with this
>>> consideration in mind.
>>
>> What do you think of this?
>>
>> which depmod >/dev/null 2>&1 && depmod=depmod ||
>> depmod=`whereis depmod | awk '{print $2}'`
>>
>> test -n "$depmod" -a -x "$depmod" &&
>> $depmod -V 2>&1 |
>> sed '
>>     /[0-9]$/!d
>>     s/[^0-9\.]//g
>>     s/^/module-init-tools\t/
>> '
>
> Looks good, thanks.
> --
> Jim

Thanks to you too.
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Please read the FAQ at  http://www.tux.org/lkml/

Back to linux.kernel | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

[PATCH] ver_linux: module-init-tools.patch Alexander Kapshuk <alexander.kapshuk@gmail.com> - 2015-10-01 21:00 +0200
  Re: [PATCH] ver_linux: module-init-tools.patch Jim Davis <jim.epost@gmail.com> - 2015-10-02 20:20 +0200
    Re: [PATCH] ver_linux: module-init-tools.patch Alexander Kapshuk <alexander.kapshuk@gmail.com> - 2015-10-02 21:10 +0200
      Re: [PATCH] ver_linux: module-init-tools.patch Jim Davis <jim.epost@gmail.com> - 2015-10-02 21:40 +0200
        Re: [PATCH] ver_linux: module-init-tools.patch Jim Davis <jim.epost@gmail.com> - 2015-10-02 21:50 +0200
          Re: [PATCH] ver_linux: module-init-tools.patch Alexander Kapshuk <alexander.kapshuk@gmail.com> - 2015-10-02 22:30 +0200
            Re: [PATCH] ver_linux: module-init-tools.patch Alexander Kapshuk <alexander.kapshuk@gmail.com> - 2015-10-02 23:00 +0200
              Re: [PATCH] ver_linux: module-init-tools.patch Jim Davis <jim.epost@gmail.com> - 2015-10-03 01:20 +0200
                Re: [PATCH] ver_linux: module-init-tools.patch Alexander Kapshuk <alexander.kapshuk@gmail.com> - 2015-10-03 14:20 +0200

csiph-web