{"thread":{"id":"54175","subject":"[Suggestion] Documentation: quick-install-man not propagating DESTDIR","startedAt":"2020-09-01T22:28:12Z","lastAt":"2020-09-02T19:53:01Z","messageCount":3,"participants":["Randall S. Becker","Junio C Hamano"],"isPatch":false,"patchVersion":null,"patchTotal":null},"messages":[{"id":"404887","messageId":"077a01d680af$2ad65510$8082ff30$@nexbridge.com","threadId":"54175","inReplyTo":null,"subject":"[Suggestion] Documentation: quick-install-man not propagating DESTDIR","fromName":"Randall S. Becker","fromEmail":"rsbecker@nexbridge.com","sentAt":"2020-09-01T22:28:02Z","receivedAt":"2020-09-01T22:28:12Z","isPatch":false,"sender":{"key":"randall.becker@nexbridge.ca","avatar":"https://avatars.githubusercontent.com/u/28956764?v=4"},"body":"The make quick-install-man rule is not propagating DESTDIR when GNU Make\n4.2.1 is used.\n\nIt seems like a bit of a nit to report this, but I discovered that the\ninstallation is not putting the manuals in the same place as git. Its a\npretty simple fix. I can put a patch together if desired.\n\ndiff --git a/Makefile b/Makefile\nindex 372139f1f2..dae2d99a7f 100644\n--- a/Makefile\n+++ b/Makefile\n@@ -2992,10 +2992,10 @@ install-gitweb:\n        $(MAKE) -C gitweb install\n\ninstall-doc: install-man-perl\n-       $(MAKE) -C Documentation install\n+       $(MAKE) -C Documentation install DESTDIR=$(DESTDIR)\n\ninstall-man: install-man-perl\n-       $(MAKE) -C Documentation install-man\n+       $(MAKE) -C Documentation install-man DESTDIR=$(DESTDIR)\n\ninstall-man-perl: man-perl\n        $(INSTALL) -d -m 755 '$(DESTDIR_SQ)$(mandir_SQ)/man3'\n@@ -3006,19 +3006,19 @@ install-html:\n        $(MAKE) -C Documentation install-html\n\ninstall-info:\n-       $(MAKE) -C Documentation install-info\n+       $(MAKE) -C Documentation install-info DESTDIR=$(DESTDIR)\n\ninstall-pdf:\n-       $(MAKE) -C Documentation install-pdf\n+       $(MAKE) -C Documentation install-pdf DESTDIR=$(DESTDIR)\n\nquick-install-doc:\n-       $(MAKE) -C Documentation quick-install\n+       $(MAKE) -C Documentation quick-install DESTDIR=$(DESTDIR)\n\nquick-install-man:\n-       $(MAKE) -C Documentation quick-install-man\n+       $(MAKE) -C Documentation quick-install-man DESTDIR=$(DESTDIR)\n\nquick-install-html:\n-       $(MAKE) -C Documentation quick-install-html\n+       $(MAKE) -C Documentation quick-install-html DESTDIR=$(DESTDIR)\n\n-- Brief whoami:\nNonStop developer since approximately 211288444200000000\nUNIX developer since approximately 421664400\n-- In my real life, I talk too much.\n\n\n"},{"id":"404932","messageId":"xmqqft80arpy.fsf@gitster.c.googlers.com","threadId":"54175","inReplyTo":"077a01d680af$2ad65510$8082ff30$@nexbridge.com","subject":"Re: [Suggestion] Documentation: quick-install-man not propagating DESTDIR","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2020-09-02T19:44:41Z","receivedAt":"2020-09-02T19:44:50Z","isPatch":false,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"\"Randall S. Becker\" <rsbecker@nexbridge.com> writes:\n\n> The make quick-install-man rule is not propagating DESTDIR when GNU Make\n> 4.2.1 is used.\n\nI wonder, instead of having to change all \"$(MAKE) -C elsewhere\", we\ncan add DESTDIR to the list of variables that are exported.\n\n... goes and looks ...\n\nHmph, DESTDIR is exported together with DIFF, TAR, INSTALL and\nSHELL_PATH.  We do rely on SHELL_PATH to be exported correctly to\nt/Makefile for \"make test\" to work, so it is puzzling.\n\nIt is doubly puzzling that we use $(INSTALL) in Documentation/Makefile\non the same line as $(DESTDIR) is used, and apparently you are not\nreporting problem on that one.\n\n> It seems like a bit of a nit to report this, but I discovered that the\n> installation is not putting the manuals in the same place as git. It’s a\n> pretty simple fix. I can put a patch together if desired.\n\nI do not think we want that patch.  Instead I think we'd want a\npatch that uses the same trick as what makes INSTALL work.\n\nThanks.\n\n> diff --git a/Makefile b/Makefile\n> index 372139f1f2..dae2d99a7f 100644\n> --- a/Makefile\n> +++ b/Makefile\n> @@ -2992,10 +2992,10 @@ install-gitweb:\n>         $(MAKE) -C gitweb install\n>\n> install-doc: install-man-perl\n> -       $(MAKE) -C Documentation install\n> +       $(MAKE) -C Documentation install DESTDIR=$(DESTDIR)\n>\n> install-man: install-man-perl\n> -       $(MAKE) -C Documentation install-man\n> +       $(MAKE) -C Documentation install-man DESTDIR=$(DESTDIR)\n>\n> install-man-perl: man-perl\n>         $(INSTALL) -d -m 755 '$(DESTDIR_SQ)$(mandir_SQ)/man3'\n> @@ -3006,19 +3006,19 @@ install-html:\n>         $(MAKE) -C Documentation install-html\n>\n> install-info:\n> -       $(MAKE) -C Documentation install-info\n> +       $(MAKE) -C Documentation install-info DESTDIR=$(DESTDIR)\n>\n> install-pdf:\n> -       $(MAKE) -C Documentation install-pdf\n> +       $(MAKE) -C Documentation install-pdf DESTDIR=$(DESTDIR)\n>\n> quick-install-doc:\n> -       $(MAKE) -C Documentation quick-install\n> +       $(MAKE) -C Documentation quick-install DESTDIR=$(DESTDIR)\n>\n> quick-install-man:\n> -       $(MAKE) -C Documentation quick-install-man\n> +       $(MAKE) -C Documentation quick-install-man DESTDIR=$(DESTDIR)\n>\n> quick-install-html:\n> -       $(MAKE) -C Documentation quick-install-html\n> +       $(MAKE) -C Documentation quick-install-html DESTDIR=$(DESTDIR)\n>\n> -- Brief whoami:\n> NonStop developer since approximately 211288444200000000\n> UNIX developer since approximately 421664400\n> -- In my real life, I talk too much.\n"},{"id":"404934","messageId":"00c101d68162$a598c900$f0ca5b00$@nexbridge.com","threadId":"54175","inReplyTo":"xmqqft80arpy.fsf@gitster.c.googlers.com","subject":"RE: [Suggestion] Documentation: quick-install-man not propagating DESTDIR","fromName":"Randall S. Becker","fromEmail":"rsbecker@nexbridge.com","sentAt":"2020-09-02T19:52:47Z","receivedAt":"2020-09-02T19:53:01Z","isPatch":false,"sender":{"key":"randall.becker@nexbridge.ca","avatar":"https://avatars.githubusercontent.com/u/28956764?v=4"},"body":"On September 2, 2020 3:45 PM, Junio C Hamano wrote:\n> \"Randall S. Becker\" <rsbecker@nexbridge.com> writes:\n> \n> > The make quick-install-man rule is not propagating DESTDIR when GNU\n> > Make\n> > 4.2.1 is used.\n> \n> I wonder, instead of having to change all \"$(MAKE) -C elsewhere\", we can\n> add DESTDIR to the list of variables that are exported.\n> \n> ... goes and looks ...\n> \n> Hmph, DESTDIR is exported together with DIFF, TAR, INSTALL and\n> SHELL_PATH.  We do rely on SHELL_PATH to be exported correctly to\n> t/Makefile for \"make test\" to work, so it is puzzling.\n> \n> It is doubly puzzling that we use $(INSTALL) in Documentation/Makefile on\n> the same line as $(DESTDIR) is used, and apparently you are not reporting\n> problem on that one.\n> \n> > It seems like a bit of a nit to report this, but I discovered that the\n> > installation is not putting the manuals in the same place as git. It’s\n> > a pretty simple fix. I can put a patch together if desired.\n> \n> I do not think we want that patch.  Instead I think we'd want a patch that\n> uses the same trick as what makes INSTALL work.\n\nI'll look into that approach. Thanks for the direction.\n\nRegards,\nRandall\n\n"}]}