git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: [PATCH] make: add install-strip target

From
Johannes Schindelin <johannes.schindelin@gmx.de>
Date
Aug 24, 2021, 13:15 UTC
Message-ID
<nycvar.QRO.7.76.6.2108241513280.55@tvgsbejvaqbjf.bet>
In-Reply-To
<xmqqwnohyzuo.fsf@gitster.g>
Hi Junio,
On Thu, 19 Aug 2021, Junio C Hamano wrote:
Show 22 quoted lines
> Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:
>
> > -install: all
> > +install: all | strip
> >  	$(INSTALL) -d -m 755 '$(DESTDIR_SQ)$(bindir_SQ)'
> >  	$(INSTALL) -d -m 755 '$(DESTDIR_SQ)$(gitexec_instdir_SQ)'
> >  	$(INSTALL) $(ALL_PROGRAMS) '$(DESTDIR_SQ)$(gitexec_instdir_SQ)'
> > -- snap --
> >
> > I am not quite certain that this is compatible with other `make`
> > implementations we still might support (if there are any, I remember that
> > we often have to rely on `gmake` because the native `make` does not
> > understand our `Makefile`?), so that might need to be conditional on GNU
> > Make.
>
> I think we are pretty-much dependent on GNU make already (it is
> possible to raise a weather balloon to confirm by renaming Makefile
> to GNUmakefile and observing if anybody complains, I think).
>
> But I am not sure what such a rule does for a .PHONY target like
> 'strip'.  Does it do the right thing, i.e. "install recipe is run
> after 'strip' recipe has run, iff 'strip' is also asked for"?

My reading of the documentation is that just as with regular dependencies, it does not matter whether order-only dependencies are .PHONY or not.

The only difference between order-only vs regular dependencies seems to be that order-only dependencies are not necessarily built. But if they are, they are guaranteed to be built before the order-only dependencee.

Granted, I did not have time to test it, but from an implementation point of view, I would be surprised if there was any more to it.

Ciao, Dscho

Previous: Junio C HamanoNext: Junio C Hamano
Message 6 of 9 in “make: add install-strip target”
  1. make: add install-strip targetBagas Sanjaya, Aug 17, 2021
  2. Johannes SchindelinAug 17, 2021
  3. Eric SunshineAug 17, 2021
  4. Johannes SchindelinAug 18, 2021
  5. Junio C HamanoAug 19, 2021
  6. Johannes SchindelinAug 24, 2021
  7. Junio C HamanoAug 17, 2021
  8. Johannes SchindelinAug 18, 2021
  9. Junio C HamanoAug 19, 2021

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.