From: Veronika Kabatova <vkabatov@redhat.com>
To: shuah <shuah@kernel.org>
Cc: Veronika Kabatova <veronicca114@gmail.com>,
sbrivio@redhat.com, linux-kselftest@vger.kernel.org
Subject: Re: [PATCH] selftests: introduce gen_tar Makefile target
Date: Mon, 4 May 2020 07:50:00 -0400 (EDT) [thread overview]
Message-ID: <687583033.21650764.1588593000351.JavaMail.zimbra@redhat.com> (raw)
In-Reply-To: <529c2308-0840-a794-fc09-d44272066b08@kernel.org>
----- Original Message -----
> From: "shuah" <shuah@kernel.org>
> To: "Veronika Kabatova" <veronicca114@gmail.com>
> Cc: sbrivio@redhat.com, linux-kselftest@vger.kernel.org, "Veronika Kabatova" <vkabatov@redhat.com>, "shuah"
> <shuah@kernel.org>
> Sent: Friday, May 1, 2020 4:49:34 PM
> Subject: Re: [PATCH] selftests: introduce gen_tar Makefile target
>
> Hi Veronica,
>
Hi,
> On 4/28/20 6:38 AM, Veronika Kabatova wrote:
> > The gen_kselftest_tar.sh always packages *all* selftests and doesn't
> > pass along any variables to `make install` to influence what should be
> > built. This can result in an early error on the command line ("Unknown
> > tarball format TARGETS=XXX"), or unexpected test failures as the
> > tarball contains tests people wanted to skip on purpose.
> >
> > Since the makefile already contains all the logic, we can add a target
> > for packaging. Keep the default .gz target the script uses, and actually
> > extend the supported formats by using tar's autodetection.
> >
>
> Thanks for working on this. gen_kselftest_tar.sh a while back before a
> lot of the install features went in and Makefile supports it fully. It
> makes perfect sense to use Makefile drive this.
>
> > To not break current workflows, keep the gen_kselftest_tar.sh script as
> > it is, with an added suggestion to use the makefile target instead.
> >
>
> Not sure how many people use this. It is a good idea keeping it around
> for now.
>
> > Signed-off-by: Veronika Kabatova <vkabatov@redhat.com>
> > Reviewed-by: Stefano Brivio <sbrivio@redhat.com>
> > ---
> > Documentation/dev-tools/kselftest.rst | 23 ++++++++++++++++++++
> > tools/testing/selftests/Makefile | 9 +++++++-
> > tools/testing/selftests/gen_kselftest_tar.sh | 5 +++++
> > 3 files changed, 36 insertions(+), 1 deletion(-)
> >
> > diff --git a/Documentation/dev-tools/kselftest.rst
> > b/Documentation/dev-tools/kselftest.rst
> > index 61ae13c44f91..3fc559bcb597 100644
> > --- a/Documentation/dev-tools/kselftest.rst
> > +++ b/Documentation/dev-tools/kselftest.rst
> > @@ -151,6 +151,29 @@ note some tests will require root privileges::
> > $ cd kselftest
> > $ ./run_kselftest.sh
> >
> > +Packaging selftests
> > +===================
> > +
> > +In some cases packaging is desired, such as when tests need to run on a
> > +different system. To package selftests, run::
> > +
> > + $ make -C tools/testing/selftests gen_tar
> > +
>
> Does this work in the case of relocatable build.cross-build cases?
>
> > +This generates a tarball in the `INSTALL_PATH/kselftest-packages`
> > directory. By
> > +default, `.gz` format is used. The tar format can be overriden by
> > specifying
> > +a `FORMAT` make variable. Any value recognized by `tar's auto-compress`_
> > option
> > +is supported, such as::
> > +
> > + $ make -C tools/testing/selftests gen_tar FORMAT=.xz
> > +
> > +`make gen_tar` invokes `make install` so you can use it to package a
> > subset of
> > +tests by using variables specified in `Running a subset of selftests`_
> > +section::
> > +
> > + $ make -C tools/testing/selftests gen_tar TARGETS="bpf" FORMAT=.xz
>
> Does this work in the case of relocatable build.cross-build cases?
>
The command only adds a "tar" call on top of "make install" and doesn't
reach outside of INSTALL_PATH. If the cases you mention are supported by
the regular "make install" then they should work with "gen_tar" as well.
Veronika
> Please try these cases as well and let me know.
>
> I would like to get this in for 5.8-rc1.
>
> thanks,
> -- Shuah
>
>
next prev parent reply other threads:[~2020-05-04 11:50 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-04-28 12:38 [PATCH] selftests: introduce gen_tar Makefile target Veronika Kabatova
2020-05-01 14:49 ` shuah
2020-05-04 11:50 ` Veronika Kabatova [this message]
2020-05-06 14:56 ` shuah
2020-05-19 18:39 ` shuah
2020-05-19 19:50 ` Veronika Kabatova
-- strict thread matches above, loose matches on Subject: below --
2020-04-28 12:34 Veronika Kabatova
[not found] <20200427192141.2926018-1-vkabatov@redhat.com>
2020-04-27 19:24 ` Stefano Brivio
2020-04-28 0:17 ` shuah
2020-04-28 7:07 ` Stefano Brivio
2020-04-28 12:46 ` Veronika Kabatova
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=687583033.21650764.1588593000351.JavaMail.zimbra@redhat.com \
--to=vkabatov@redhat.com \
--cc=linux-kselftest@vger.kernel.org \
--cc=sbrivio@redhat.com \
--cc=shuah@kernel.org \
--cc=veronicca114@gmail.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.