All of lore.kernel.org
 help / color / mirror / Atom feed
From: Luc Van Oostenryck <luc.vanoostenryck@gmail.com>
To: "Uwe Kleine-König" <uwe@kleine-koenig.org>
Cc: linux-sparse@vger.kernel.org
Subject: Re: [PATCH 28/36] build: use a dot file name instead of local.mk: .sparse.mk
Date: Thu, 9 Nov 2017 21:48:03 +0100	[thread overview]
Message-ID: <20171109204802.iezm2l5uhkfrxxys@ltop.local> (raw)
In-Reply-To: <120cc3cf-e27c-b5a3-0bb0-f56c2805608e@kleine-koenig.org>

On Thu, Nov 09, 2017 at 08:06:40PM +0100, Uwe Kleine-König wrote:
> Hello Luc,
> 
> On 11/06/2017 04:43 PM, Luc Van Oostenryck wrote:
> > On Mon, Nov 06, 2017 at 09:57:23AM +0100, Uwe Kleine-König wrote:
> >>> -local.mk
> >>> +.sparse.mk
> >>
> >> what is the motivation to hide this file? IMHO it is better to be aware
> >> of eventual changes to the build system and so don't hide the file.
> >>
> >> Having said that I question if it is a good idea at all to provide a way
> >> to change the build without dirtying the working copy.
> > 
> > I confess that this change is just for my own confort.
> > I often need to change change the CFLAGS while debugging or profiling.
> > I want that to be in a file, the file must of course not be under
> > version control and like .bashrc, kernel's .config or GCC's generated
> > .*.o.d files, I don't need to see this file and so I prefer it's an 
> > hidden one.
> >
> > I understand your worries but since it's a file purposely changed
> > so that files are compiled differently, there is no surprises.
> 
> <sarcasm>
> We could also add
> 
> 	#include ".sparse.c"
> 
> at the end of sparse.c (and touch this file in Makefile) in case you
> want to add a function there without dirtying the working copy. This
> could be used to overwrite weak functions for example.
> 
> Oh, and given that order in Makefile sometimes matter, we could add an
> sinclude sparse-pre.mk at the start of Makefile.
> </sarcasm>
> 
> IMHO these suggestions (that I hope you find absurd, too) are only
> little worse than your justification above.

:)

Yes, it's absurd.
I certainly don't want to hide .c files or .h, the Makefile also I don't
want to hide. These files contains the meat, the logic, they are the
objects on which developement are done, it make no sense to me to hide them.

It's very different for this file: I suppose for most dev, most of the time
we even don't need of this file but sometimes, for a specific purpose, for
a little while, we need some other flags. While this file is needed (for me,
it's 98% of the time for debugging and 2% of the time for profiling), I'll
make some commits, use 'git status' or 'git add -p' and such, so the strict
minima is that this file is ignored by the version control.

*Personally*, I also prefer that this file is not in the way in any possible
way, so yes, I prefer to not see it, I prefer even more that it's even not
in the tree.

For me, it's very very similar to all the .dot file we have in our home dirs
or simply the .git and .gitignore in the working tree.
Why are those files hidden? Will it be a good thing to make them visible?
I don't think so.

Others may have other preferences and other way of working, no problem,
I totally respect that and try to find the best for everyone.

> If I'd want to change CFLAGS, I'd do that directly in Makefile.

Doing it in the Makefile, is exactly the thing I don't want to do:
I want and I need to have my tree clean of this sort of things.

> git is
> powerful enough that this isn't in the way of committing and I
> personally like being remembered that I changed something. Of course
> this is subjective.

Yes, like this whole subject.

> > For dirtying the build ... yes, something could be done but really,
> > personnaly, I don't need this, I know when I need to clean my tree
> 
> famous words. How often did it happen to you that you thought you'd
> remember stuff when you need it and then only managed to do this after a
> 2 hour long debug session?

Honestly, it doesn't matter.
Even if I forget, what matters to me is "how much time will I waste?"
a few seconds, a few minutes or several hours of work?
In this case, it's a few seconds or at worst two minutes.

-- Luc

  reply	other threads:[~2017-11-09 20:48 UTC|newest]

Thread overview: 67+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-11-05 16:24 [PATCH 00/36] Makefile reorganization Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 01/36] build: make PREFIX overwritable from the environment Luc Van Oostenryck
2017-11-05 17:44   ` Josh Triplett
2017-11-05 18:54     ` Uwe Kleine-König
2017-11-05 20:30       ` Josh Triplett
2017-11-05 16:25 ` [PATCH 02/36] build: put comment about local.mk to the place where it is included Luc Van Oostenryck
2017-11-05 17:44   ` Josh Triplett
2017-11-05 16:25 ` [PATCH 03/36] build: drop BASIC_CFLAGS and ALL_CFLAGS Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 04/36] build: drop -g from LDFLAGS Luc Van Oostenryck
2017-11-05 17:45   ` Josh Triplett
2017-11-05 16:25 ` [PATCH 05/36] build: pass CPPFLAGS to compiler Luc Van Oostenryck
2017-11-05 17:46   ` Josh Triplett
2017-11-05 16:25 ` [PATCH 06/36] build: fix effectiveness of generated dependencies Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 07/36] build: remove unused support for pkgconfig Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 08/36] build: use '_OBJS' instead of '_EXTRA_DEPS' Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 09/36] build: use '_LDLIBS' instead of '_EXTRA_OBJS' Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 10/36] build: allow target-specific CFLAGS, CPPFLAGS, LDFLAGS & LDLIBS Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 11/36] build: allow CFLAGS & friends from command line Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 12/36] build: avoid rule-specific CFLAGS Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 13/36] build: use $LIBS directly in the dependency list Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 14/36] build: no need to use wildcards for generated dependencies Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 15/36] build: reuse rule for ALL_OBJS Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 16/36] build: CHECKER_FLAGS=-Wno-vla for all targets Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 17/36] build: move tests near their use Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 18/36] build: only generate version.h when needed Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 19/36] build: add note about overwritable vars Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 20/36] build: remove references to unexisting pre-process.h Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 21/36] build: no need to clean *.so and SLIB_FILE Luc Van Oostenryck
2017-11-05 17:48   ` Josh Triplett
2017-11-05 20:06     ` Luc Van Oostenryck
2017-11-05 20:30       ` Josh Triplett
2017-11-05 16:25 ` [PATCH 22/36] build: move clean & clean-check together Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 23/36] build: make clean targets quieter Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 24/36] build: remove rule for shared lib, it's unused Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 25/36] build: normalize rules Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 26/36] build: remove the dist rule since unused Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 27/36] build: use one line per item Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 28/36] build: use a dot file name instead of local.mk: .sparse.mk Luc Van Oostenryck
2017-11-06  8:57   ` Uwe Kleine-König
2017-11-06 15:43     ` Luc Van Oostenryck
2017-11-09 19:06       ` Uwe Kleine-König
2017-11-09 20:48         ` Luc Van Oostenryck [this message]
2017-11-09 19:29     ` Christopher Li
2017-11-05 16:25 ` [PATCH 29/36] build: use git-clean Luc Van Oostenryck
2017-11-05 17:41   ` Josh Triplett
2017-11-05 20:16     ` Luc Van Oostenryck
2017-11-05 20:38       ` Josh Triplett
2017-11-05 20:50         ` Uwe Kleine-König
2017-11-05 20:58           ` Luc Van Oostenryck
2017-11-05 20:56         ` Luc Van Oostenryck
2017-11-05 23:09     ` Christopher Li
2017-11-08 11:42   ` Jeff Layton
2017-11-08 12:01     ` Uwe Kleine-König
2017-11-08 19:55     ` Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 30/36] build: use standard rules for install Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 31/36] build: remove unused QUIET_INST_SH Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 32/36] build: let quiet commands use less indentation Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 33/36] build: simpler logic for quiet commands Luc Van Oostenryck
2017-11-06  8:15   ` Uwe Kleine-König
2017-11-06  8:28     ` Luc Van Oostenryck
2017-11-06  8:44       ` Uwe Kleine-König
2017-11-06  8:55         ` Luc Van Oostenryck
2017-11-06 19:40           ` Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 34/36] build: avoid foreach Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 35/36] build: reorg & add comment Luc Van Oostenryck
2017-11-05 16:25 ` [PATCH 36/36] build: use a single space before assignments Luc Van Oostenryck
2017-11-06  5:50 ` [PATCH 00/36] Makefile reorganization Luc Van Oostenryck

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=20171109204802.iezm2l5uhkfrxxys@ltop.local \
    --to=luc.vanoostenryck@gmail.com \
    --cc=linux-sparse@vger.kernel.org \
    --cc=uwe@kleine-koenig.org \
    /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.