public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
From: Petr Vorel <pvorel@suse.cz>
To: Andrea Cervesato <andrea.cervesato@suse.de>
Cc: ltp@lists.linux.it
Subject: Re: [LTP] [PATCH v3 2/2] Add Linux Test eXecutor inside tools
Date: Mon, 18 Sep 2023 11:17:56 +0200	[thread overview]
Message-ID: <20230918091756.GB30304@pevik> (raw)
In-Reply-To: <20230918082506.17464-3-andrea.cervesato@suse.de>

> From: Andrea Cervesato <andrea.cervesato@suse.com>

> The ltx program runs on the system under test (SUT). It's primary
> purpose is to run test executables in parallel and serialise the
> results.

> Signed-off-by: Andrea Cervesato <andrea.cervesato@suse.com>
> ---
>  .gitmodules        |  3 +++
>  tools/ltx/Makefile | 31 +++++++++++++++++++++++++++++++
>  tools/ltx/ltx-src  |  1 +
>  3 files changed, 35 insertions(+)
>  create mode 100644 tools/ltx/Makefile
>  create mode 160000 tools/ltx/ltx-src

> diff --git a/.gitmodules b/.gitmodules
> index c389186c9..2a8b7a399 100644
> --- a/.gitmodules
> +++ b/.gitmodules
> @@ -10,3 +10,6 @@
>  [submodule "tools/kirk"]
>  	path = tools/kirk
>  	url = https://github.com/linux-test-project/kirk.git
> +[submodule "tools/ltx/ltx-src"]
> +	path = tools/ltx/ltx-src
> +	url = https://github.com/linux-test-project/ltx.git
> diff --git a/tools/ltx/Makefile b/tools/ltx/Makefile
> new file mode 100644
> index 000000000..4810ec8df
> --- /dev/null
> +++ b/tools/ltx/Makefile
> @@ -0,0 +1,31 @@
> +# SPDX-License-Identifier: GPL-2.0-or-later
> +# Copyright (c) 2023 Cyril Hrubis <chrubis@suse.cz>
> +# Copyright (c) 2023 Andrea Cervesato <andrea.cervesato@suse.com>
> +#
> +# Install script for Linux Test eXecutor
> +
> +top_srcdir		?= ../..
> +
> +include $(top_srcdir)/include/mk/env_pre.mk
> +
> +ifneq ($(wildcard $(abs_srcdir)/ltx-src/*),)
> +
> +BINARY=ltx
> +
> +MAKE_TARGETS := $(BINARY)
> +
> +CFLAGS+=-I$(abs_srcdir)/ltx-src/ -I$(abs_srcdir)/ltx-src/msgpack/
> +
> +$(BINARY): $(wildcard $(abs_srcdir)/ltx-src/*.c $(abs_srcdir)/ltx-src/msgpack/*.c)
> +ifdef VERBOSE
> +	$(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) $^ $(LDLIBS) -o $@
> +else
> +	@echo CC $@
> +	@$(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) $^ $(LDLIBS) -o $@
> +endif
This works, but why we don't use approach used for sparc, i.e.

$(MAKE) -C ltx-src

That way we would not have to redefine the default rules.

Also it detects missing git clone and runs
git submodule update --init if needed.

I'm asking for a same approach, not only because later we can unify and reuse
the code in some make helper, but also because it'd be more user friendly if our
new git submodules work the same way.

But if there is not enough time before release I would not be against this.

Kind regards,
Petr

-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

  reply	other threads:[~2023-09-18  9:18 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-09-18  8:25 [LTP] [PATCH v3 0/2] Add kirk & ltx tools Andrea Cervesato
2023-09-18  8:25 ` [LTP] [PATCH v3 1/2] Replace runltp-ng with kirk framework Andrea Cervesato
2023-09-18  9:01   ` Petr Vorel
2023-09-18  9:06     ` Andrea Cervesato via ltp
2023-09-18  8:25 ` [LTP] [PATCH v3 2/2] Add Linux Test eXecutor inside tools Andrea Cervesato
2023-09-18  9:17   ` Petr Vorel [this message]
2023-09-18  9:35     ` Andrea Cervesato via ltp
2023-09-18  9:38     ` Cyril Hrubis
2023-09-18  9:42       ` Cyril Hrubis
2023-09-18 10:34         ` Petr Vorel
2023-09-18 10:37       ` Petr Vorel

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=20230918091756.GB30304@pevik \
    --to=pvorel@suse.cz \
    --cc=andrea.cervesato@suse.de \
    --cc=ltp@lists.linux.it \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox