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

Re: [XEN PATCH 22/57] tools/console: have one Makefile per program/directory


  • To: Andrew Cooper <amc96@xxxxxxxx>
  • From: Anthony PERARD <anthony.perard@xxxxxxxxxx>
  • Date: Tue, 21 Dec 2021 17:25:36 +0000
  • Authentication-results: esa5.hc3370-68.iphmx.com; dkim=none (message not signed) header.i=none
  • Cc: <xen-devel@xxxxxxxxxxxxxxxxxxxx>, Anthony PERARD <anthony.perard@xxxxxxxxx>, Andrew Cooper <andrew.cooper3@xxxxxxxxxx>, "George Dunlap" <george.dunlap@xxxxxxxxxx>, Ian Jackson <iwj@xxxxxxxxxxxxxx>, "Jan Beulich" <jbeulich@xxxxxxxx>, Julien Grall <julien@xxxxxxx>, "Stefano Stabellini" <sstabellini@xxxxxxxxxx>, Wei Liu <wl@xxxxxxx>
  • Delivery-date: Tue, 21 Dec 2021 17:26:42 +0000
  • Ironport-data: A9a23:rTUDj6PJjb8qV+rvrR0PkMFynXyQoLVcMsEvi/4bfWQNrUojhmRRy jEXWmGEP6uDN2ryetoiaoW2oE9UvZXUx9ZlSgto+SlhQUwRpJueD7x1DKtR0wB+jCHnZBg6h ynLQoCYdKjYdpJYz/uUGuCJQUNUjMlkfZKhTr6UUsxNbVU8En5400g6w7VRbrNA2rBVPSvc4 bsenOWHULOV82Yc3rU8sv/rRLtH5ZweiRtA1rAMTakjUGz2zhH5OKk3N6CpR0YUd6EPdgKMq 0Qv+5nilo/R109F5tpICd8XeGVSKlLZFVDmZna7x8FOK/WNz8A/+v9TCRYSVatYozCiufdt4 vVvjLu1ajgXZKidpKcTbBYNRkmSPYUekFPGCX22sMjVxEzaaXr8hf5pCSnaP6VBpLwxWzsXs 6VFdnZdNXhvhMrvqF6/YuBqmsQkKtitJI4Fs2ts5TrYEewnUdbIRKCiCdpwgm9o3JwRR622i 8wxdBsyPSmeQRJ2N0o5N5Bgu/WyikPEWmgNwL6SjfVuuDWCpOBr65DvLd7Ud9qiVch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/GnrfGipRd2lHGIig6GnX61OZAgYgD5UJRx1gYKlXVwtfIi5fbBvGKHejbmuiN8ih67g==
  • Ironport-hdrordr: A9a23:1flLMKOrjwnkAMBcTsGjsMiBIKoaSvp037Eqv3oedfVwSL39qy nOpoV/6faaslsssR0b9exofZPwJk80lqQFg7X5X43DYOCOggLBR+tfBMnZsl7d8kXFh4hgPM xbEpSWZueeMWRH
  • Ironport-sdr: nTtVF0yl2JT9To0kyOIL+yF2/loZ2iTHvQi4VWlsZ6WjsUvQz5zD2wBHLaoeu5AJ9Zu5iKJjX2 3rrHdCnyh7cs22XIZJG+htapSBH49M/XpI2sUUnuq09Thd/dQohxvyNIatt095cUIecNMtj93J FzbKqyh8V6ZclUXfg4T5wMDw9csLKBEi6NnaxKLkkOM+aqoOt/XvHa42RamW5/fzIlJ78fOqTj 6jknLrgJ5y/gAy0giy1ManHUN+1dVj9iGHX2dSmxzCmzlcfbooVwaFxFCBpGhJxwJgCcWZ8AtG qOjAq1ZUB7rf5H4zInwXQkCV
  • List-id: Xen developer discussion <xen-devel.lists.xenproject.org>

On Thu, Dec 16, 2021 at 05:26:49PM +0000, Andrew Cooper wrote:
> On 06/12/2021 17:02, Anthony PERARD wrote:
> > Sources of both xenconsoled and xenconsole are already separated into
> > different directory and don't share anything in common. Having two
> > different Makefile means it's easier to deal with *FLAGS.
> >
> > Some common changes:
> > Rename $(BIN) to $(TARGETS), this will be useful later.
> > Stop removing *.so *.rpm *.a as they aren't created here.
> > Use $(OBJS-y) to list objects.
> > Update $(CFLAGS) for the directory rather than a single object.
> >
> > daemon:
> >     Remove the need for $(LDLIBS_xenconsoled), use $(LDLIBS) instead.
> >     Remove the need for $(CONSOLE_CFLAGS-y) and use $(CFLAGS-y)
> >     instead.
> >
> > client:
> >     Remove the unused $(LDLIBS_xenconsole)
> >
> > Signed-off-by: Anthony PERARD <anthony.perard@xxxxxxxxxx>
> > ---
> >  .gitignore                    |  4 +--
> >  tools/console/Makefile        | 49 +++-------------------------------
> >  tools/console/client/Makefile | 39 +++++++++++++++++++++++++++
> >  tools/console/daemon/Makefile | 50 +++++++++++++++++++++++++++++++++++
> >  4 files changed, 94 insertions(+), 48 deletions(-)
> >  create mode 100644 tools/console/client/Makefile
> >  create mode 100644 tools/console/daemon/Makefile
> >
> > diff --git a/.gitignore b/.gitignore
> > index b39b996718..c31fa9b841 100644
> > --- a/.gitignore
> > +++ b/.gitignore
> > @@ -159,8 +159,8 @@ tools/libs/util/libxenutil.map
> >  tools/libs/vchan/headers.chk
> >  tools/libs/vchan/libxenvchan.map
> >  tools/libs/vchan/xenvchan.pc
> > -tools/console/xenconsole
> > -tools/console/xenconsoled
> > +tools/console/client/xenconsole
> > +tools/console/daemon/xenconsoled
> 
> $ git ls-files -- :/ | grep gitignore
> ../.gitignore
> ../tools/fuzz/cpu-policy/.gitignore
> ../tools/libs/.gitignore
> ../tools/misc/.gitignore
> ../tools/tests/cpu-policy/.gitignore
> ../tools/tests/resource/.gitignore
> ../tools/tests/tsx/.gitignore
> ../tools/tests/vhpet/.gitignore
> ../tools/tests/xenstore/.gitignore
> tools/kconfig/.gitignore
> xsm/flask/.gitignore
> 
> 
> We're starting to use per-dir gitignores, because it has far less
> problematic behaviour for code movement.

You mean "we", I don't think everyone agree we that yet ;-). They aren't
any "xen/.gitignore" yet, despite me trying to add one at some point.

> I think we ought to take this opportunity to clean things up for the better.

Sounds good to me, I'll make the change.

> > diff --git a/tools/console/client/Makefile b/tools/console/client/Makefile
> > new file mode 100644
> > index 0000000000..44176c6d93
> > --- /dev/null
> > +++ b/tools/console/client/Makefile
> > @@ -0,0 +1,39 @@
> > +XEN_ROOT=$(CURDIR)/../../..
> > +include $(XEN_ROOT)/tools/Rules.mk
> > +
> > +CFLAGS += -Werror
> 
> -Werror really ought to come from somewhere common, seeing as we expect
> it to be unilaterally set.

Yes. I think I'll also look at having "./configure --disable-werror" or
similar so -Werror could be easly disable, by for example someone
building an ancient release and not wanting to deal with warnings.

Thanks,

-- 
Anthony PERARD



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.