GNU bug report logs - #25304
Libtool's ltmain.sh should have its shebang preserved

Previous Next

Package: guix;

Reported by: ludo <at> gnu.org (Ludovic Courtès)

Date: Fri, 30 Dec 2016 23:35:02 UTC

Severity: important

Merged with 25508, 26749

Done: Miguel Ángel Arruga Vivas <rosen644835 <at> gmail.com>

Bug is archived. No further changes may be made.

To add a comment to this bug, you must first unarchive it, by sending
a message to control AT debbugs.gnu.org, with unarchive 25304 in the body.
You can then email your comments to 25304 AT debbugs.gnu.org in the normal way.

Toggle the display of automated, internal messages from the tracker.

View this report as an mbox folder, status mbox, maintainer mbox


Report forwarded to bug-guix <at> gnu.org:
bug#25304; Package guix. (Fri, 30 Dec 2016 23:35:02 GMT) Full text and rfc822 format available.

Acknowledgement sent to ludo <at> gnu.org (Ludovic Courtès):
New bug report received and forwarded. Copy sent to bug-guix <at> gnu.org. (Fri, 30 Dec 2016 23:35:02 GMT) Full text and rfc822 format available.

Message #5 received at submit <at> debbugs.gnu.org (full text, mbox):

From: ludo <at> gnu.org (Ludovic Courtès)
To: Ricardo Wurmus <rekado <at> elephly.net>
Cc: help-guix <at> gnu.org, ng0 <ng0 <at> libertad.pw>, bug-guix <at> gnu.org
Subject: Re: Seeking advice: preparing releases on GuixSD.
Date: Sat, 31 Dec 2016 00:34:40 +0100
Hi!

Ricardo Wurmus <rekado <at> elephly.net> skribis:

> “ltmain.sh” is instantiated from a template by libtool.  It originally
> contains a /bin/sh shebang, and I think it should not be patched when
> installed to
>
>     /gnu/store/…-libtool-2.4.6/share/libtool/build-aux/ltmain.sh
>
> This seems like a bug to me.

Definitely:

--8<---------------cut here---------------start------------->8---
$ head -1 $(find $(guix build libtool) -name ltmain.sh)
#!/gnu/store/qkw4zrwfybxww8f56nkb6hggxambk89b-bash-4.4.0/bin/sh
--8<---------------cut here---------------end--------------->8---

Opening a new bug now.  This is with v0.12.0-176-ge087671.

Ludo’.




Changed bug title to 'Libtool's ltmain.sh should have its shebang preserved' from 'Seeking advice: preparing releases on GuixSD.' Request was from ludo <at> gnu.org (Ludovic Courtès) to control <at> debbugs.gnu.org. (Tue, 31 Jan 2017 21:02:01 GMT) Full text and rfc822 format available.

Reply sent to ludo <at> gnu.org (Ludovic Courtès):
You have taken responsibility. (Tue, 31 Jan 2017 21:04:01 GMT) Full text and rfc822 format available.

Notification sent to ludo <at> gnu.org (Ludovic Courtès):
bug acknowledged by developer. (Tue, 31 Jan 2017 21:04:02 GMT) Full text and rfc822 format available.

Message #12 received at 25304-done <at> debbugs.gnu.org (full text, mbox):

From: ludo <at> gnu.org (Ludovic Courtès)
To: Ricardo Wurmus <rekado <at> elephly.net>
Cc: 25304-done <at> debbugs.gnu.org, ng0 <at> libertad.pw
Subject: Re: bug#25304: Seeking advice: preparing releases on GuixSD.
Date: Tue, 31 Jan 2017 22:03:14 +0100
ludo <at> gnu.org (Ludovic Courtès) skribis:

> Ricardo Wurmus <rekado <at> elephly.net> skribis:
>
>> “ltmain.sh” is instantiated from a template by libtool.  It originally
>> contains a /bin/sh shebang, and I think it should not be patched when
>> installed to
>>
>>     /gnu/store/…-libtool-2.4.6/share/libtool/build-aux/ltmain.sh
>>
>> This seems like a bug to me.
>
> Definitely:
>
> $ head -1 $(find $(guix build libtool) -name ltmain.sh)
> #!/gnu/store/qkw4zrwfybxww8f56nkb6hggxambk89b-bash-4.4.0/bin/sh
>
> Opening a new bug now.  This is with v0.12.0-176-ge087671.

This was fixed by ng0 in 98341757c8c45fca8d2b53f9972f5c6a32cf2c95.

Ludo’.




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Wed, 01 Mar 2017 12:24:03 GMT) Full text and rfc822 format available.

Did not alter fixed versions and reopened. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Fri, 21 Apr 2017 14:25:01 GMT) Full text and rfc822 format available.

bug unarchived. Request was from ludo <at> gnu.org (Ludovic Courtès) to control <at> debbugs.gnu.org. (Fri, 21 Apr 2017 14:27:02 GMT) Full text and rfc822 format available.

Information forwarded to bug-guix <at> gnu.org:
bug#25304; Package guix. (Fri, 21 Apr 2017 14:31:02 GMT) Full text and rfc822 format available.

Message #21 received at 25304 <at> debbugs.gnu.org (full text, mbox):

From: ludo <at> gnu.org (Ludovic Courtès)
To: 25304 <at> debbugs.gnu.org
Subject: Libtool’s ltmain.sh still contains a /gnu/store
 shebang
Date: Fri, 21 Apr 2017 16:30:43 +0200
Hi,

Commit 98341757c8c45fca8d2b53f9972f5c6a32cf2c95, which was meant to fix
this bug¹, actually failed to do so:

--8<---------------cut here---------------start------------->8---
$ head -1 $(./pre-inst-env guix build libtool)/share/libtool/build-aux/ltmain.sh
#!/gnu/store/k7029k5va68lkapbzcycdzj7m5bjb4b8-bash-4.4.12/bin/sh
$ git describe
v0.12.0-3136-g7312c62d3
--8<---------------cut here---------------end--------------->8---

I think the problem is that we’re patching ltmain.in when we should
really be patching the final file, after the ‘patch-shebangs’ phase.

Ludo’.

¹ <http://bugs.gnu.org/25304>




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Sat, 20 May 2017 11:24:03 GMT) Full text and rfc822 format available.

Did not alter fixed versions and reopened. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Wed, 18 Mar 2020 20:32:01 GMT) Full text and rfc822 format available.

Severity set to 'important' from 'normal' Request was from Jack Hill <jackhill <at> jackhill.us> to control <at> debbugs.gnu.org. (Wed, 18 Mar 2020 20:32:01 GMT) Full text and rfc822 format available.

bug unarchived. Request was from Jack Hill <jackhill <at> jackhill.us> to control <at> debbugs.gnu.org. (Wed, 18 Mar 2020 20:38:01 GMT) Full text and rfc822 format available.

Did not alter fixed versions and reopened. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Wed, 18 Mar 2020 20:38:01 GMT) Full text and rfc822 format available.

Severity set to 'important' from 'normal' Request was from Jack Hill <jackhill <at> jackhill.us> to control <at> debbugs.gnu.org. (Wed, 18 Mar 2020 20:38:01 GMT) Full text and rfc822 format available.

Merged 25304 25508 26749. Request was from Jack Hill <jackhill <at> jackhill.us> to control <at> debbugs.gnu.org. (Wed, 18 Mar 2020 20:38:01 GMT) Full text and rfc822 format available.

Information forwarded to bug-guix <at> gnu.org:
bug#25304; Package guix. (Fri, 13 Nov 2020 15:33:01 GMT) Full text and rfc822 format available.

Message #38 received at 25304 <at> debbugs.gnu.org (full text, mbox):

From: Miguel Ángel Arruga Vivas <rosen644835 <at> gmail.com>
To: ludo <at> gnu.org (Ludovic Courtès)
Cc: 25304 <at> debbugs.gnu.org
Subject: Re: bug#25304: Libtool’s ltmain.sh still
 contains a /gnu/store shebang
Date: Fri, 13 Nov 2020 16:32:04 +0100
[Message part 1 (text/plain, inline)]
Hi,

I was looking through the lists because I have a patch that does exactly
what you describe here.  I guess this goes to core updates, so this
version is on top of it.  WDYT?

Happy hacking!
Miguel

ludo <at> gnu.org (Ludovic Courtès) writes:
> Hi,
>
> Commit 98341757c8c45fca8d2b53f9972f5c6a32cf2c95, which was meant to fix
> this bug¹, actually failed to do so:
>
> $ head -1 $(./pre-inst-env guix build libtool)/share/libtool/build-aux/ltmain.sh
> #!/gnu/store/k7029k5va68lkapbzcycdzj7m5bjb4b8-bash-4.4.12/bin/sh
> $ git describe
> v0.12.0-3136-g7312c62d3
>
> I think the problem is that we’re patching ltmain.in when we should
> really be patching the final file, after the ‘patch-shebangs’ phase.
>
> Ludo’.
>
> ¹ <http://bugs.gnu.org/25304>

[0001-gnu-libtool-Restore-shebangs-on-all-libtoolize-files.patch (text/x-patch, attachment)]
[signature.asc (application/pgp-signature, inline)]

Information forwarded to bug-guix <at> gnu.org:
bug#25304; Package guix. (Sun, 15 Nov 2020 11:09:02 GMT) Full text and rfc822 format available.

Message #41 received at 25304 <at> debbugs.gnu.org (full text, mbox):

From: Ludovic Courtès <ludo <at> gnu.org>
To: Miguel Ángel Arruga Vivas <rosen644835 <at> gmail.com>
Cc: 25304 <at> debbugs.gnu.org
Subject: Re: bug#25304: Libtool’s ltmain.sh still
 contains a /gnu/store shebang
Date: Sun, 15 Nov 2020 12:08:26 +0100
Hi!

Miguel Ángel Arruga Vivas <rosen644835 <at> gmail.com> skribis:

> I was looking through the lists because I have a patch that does exactly
> what you describe here.  I guess this goes to core updates, so this
> version is on top of it.  WDYT?

Yes, looks like a change for ‘core-updates’.

> From 145273418d3131bcf3b73d416d19f641645cf3f8 Mon Sep 17 00:00:00 2001
> From: =?UTF-8?q?Miguel=20=C3=81ngel=20Arruga=20Vivas?=
>  <rosen644835 <at> gmail.com>
> Date: Fri, 13 Nov 2020 15:24:46 +0100
> Subject: [PATCH] gnu: libtool: Restore shebangs on all libtoolize files.

You can add “Fixes <https://bugs.gnu.org/25304>.”

> * gnu/packages/autotools.scm (libtool)[restore-build-aux-shebang]: New
> phase after install.
> [restore-ltmain-shebang]: Remove phase, it is now performed by the phase
> restore-build-aux-shebang.

LGTM, thanks for digging through old bugs!

Ludo’.




Reply sent to Miguel Ángel Arruga Vivas <rosen644835 <at> gmail.com>:
You have taken responsibility. (Mon, 16 Nov 2020 16:18:02 GMT) Full text and rfc822 format available.

Notification sent to ludo <at> gnu.org (Ludovic Courtès):
bug acknowledged by developer. (Mon, 16 Nov 2020 16:18:02 GMT) Full text and rfc822 format available.

Message #46 received at 25304-done <at> debbugs.gnu.org (full text, mbox):

From: Miguel Ángel Arruga Vivas <rosen644835 <at> gmail.com>
To: Ludovic Courtès <ludo <at> gnu.org>
Cc: 25304-done <at> debbugs.gnu.org
Subject: Re: bug#25304: Libtool’s ltmain.sh still
 contains a /gnu/store shebang
Date: Mon, 16 Nov 2020 17:17:05 +0100
[Message part 1 (text/plain, inline)]
Hi!

Ludovic Courtès <ludo <at> gnu.org> writes:
> Hi!
>
> Miguel Ángel Arruga Vivas <rosen644835 <at> gmail.com> skribis:
>
>> I was looking through the lists because I have a patch that does exactly
>> what you describe here.  I guess this goes to core updates, so this
>> version is on top of it.  WDYT?
>
> Yes, looks like a change for ‘core-updates’.
>
>> From 145273418d3131bcf3b73d416d19f641645cf3f8 Mon Sep 17 00:00:00 2001
>> From: =?UTF-8?q?Miguel=20=C3=81ngel=20Arruga=20Vivas?=
>>  <rosen644835 <at> gmail.com>
>> Date: Fri, 13 Nov 2020 15:24:46 +0100
>> Subject: [PATCH] gnu: libtool: Restore shebangs on all libtoolize files.
>
> You can add “Fixes <https://bugs.gnu.org/25304>.”
>
>> * gnu/packages/autotools.scm (libtool)[restore-build-aux-shebang]: New
>> phase after install.
>> [restore-ltmain-shebang]: Remove phase, it is now performed by the phase
>> restore-build-aux-shebang.
>
> LGTM, thanks for digging through old bugs!
>
> Ludo’.

Pushed as 8d263ff254292c9e13a9848f90b52263da52d570 to core-updates with
that line added.  Thanks for the quick review.  :-)

Happy hacking!
Miguel
[signature.asc (application/pgp-signature, inline)]

Reply sent to Miguel Ángel Arruga Vivas <rosen644835 <at> gmail.com>:
You have taken responsibility. (Mon, 16 Nov 2020 16:18:02 GMT) Full text and rfc822 format available.

Notification sent to Leo Famulari <leo <at> famulari.name>:
bug acknowledged by developer. (Mon, 16 Nov 2020 16:18:02 GMT) Full text and rfc822 format available.

Reply sent to Miguel Ángel Arruga Vivas <rosen644835 <at> gmail.com>:
You have taken responsibility. (Mon, 16 Nov 2020 16:18:02 GMT) Full text and rfc822 format available.

Notification sent to ng0 <ng0 <at> pragmatique.xyz>:
bug acknowledged by developer. (Mon, 16 Nov 2020 16:18:03 GMT) Full text and rfc822 format available.

Information forwarded to bug-guix <at> gnu.org:
bug#25304; Package guix. (Mon, 16 Nov 2020 18:12:02 GMT) Full text and rfc822 format available.

Message #59 received at 25304 <at> debbugs.gnu.org (full text, mbox):

From: Miguel Ángel Arruga Vivas <rosen644835 <at> gmail.com>
To: Leo Famulari <leo <at> famulari.name>
Cc: 25304 <at> debbugs.gnu.org, 25508 <at> debbugs.gnu.org, John Darrington <jmd <at> gnu.org>
Subject: Re: bug#25508: Git hook shebangs should not be rewritten
Date: Mon, 16 Nov 2020 19:10:59 +0100
[Message part 1 (text/plain, inline)]
Sorry, I've closed this with the libtool one.

The attached patch fixes this one too, should I push it to master (as
the last change for git) or to core-updates or staging (as it might seem
looking at the dependencies)?

Happy hacking!
Miguel
[0001-gnu-git-Add-phase-to-restore-hooks-shebang.patch (text/x-patch, attachment)]
[Message part 3 (text/plain, inline)]
Leo Famulari <leo <at> famulari.name> writes:

> From: John Darrington <john <at> darrington.wattle.id.au>
> Subject: Not patching shebang in git hook samples ?
> To: guix-devel <at> gnu.org
> Date: Sun, 22 Jan 2017 14:01:24 +0100 (3 years, 42 weeks, 4 days ago)
>
> The git package ships with a number of sample hook files.  These are shell scripts and
> therefore the #!/bin/sh line gets substituted at  build time.
>
> However these files get installed into every git repostory that is created, and users
> are invited to use them as templates for their own hooks.
>
> This will be fine until both git and bash are updated.  Now the original bash is free
> to be garbage collected.  If that happens, the path: 
> #!/gnu/store/qkw4zrwfybxww8f56nkb6hggxambk89b-bash-4.4.0/bin/sh
> will no longer exist.
>
> I suggest what we turn off the shebang patching for the files in share/templates for git.
>
> J'
[signature.asc (application/pgp-signature, inline)]

Information forwarded to bug-guix <at> gnu.org:
bug#25304; Package guix. (Mon, 16 Nov 2020 18:43:02 GMT) Full text and rfc822 format available.

Message #62 received at 25304 <at> debbugs.gnu.org (full text, mbox):

From: Marius Bakke <marius <at> gnu.org>
To: Miguel Ángel Arruga Vivas <rosen644835 <at> gmail.com>, Leo
 Famulari <leo <at> famulari.name>
Cc: 25304 <at> debbugs.gnu.org, 25508 <at> debbugs.gnu.org, John Darrington <jmd <at> gnu.org>
Subject: Re: bug#25304: bug#25508: Git hook shebangs should not be rewritten
Date: Mon, 16 Nov 2020 19:42:26 +0100
[Message part 1 (text/plain, inline)]
Miguel Ángel Arruga Vivas <rosen644835 <at> gmail.com> writes:

> The attached patch fixes this one too, should I push it to master (as
> the last change for git) or to core-updates or staging (as it might seem
> looking at the dependencies)?

LGTM.  Git (+ git-minimal) is below the 300 rebuild limit for 'master'
(and I try to keep it that way!).
[signature.asc (application/pgp-signature, inline)]

Information forwarded to bug-guix <at> gnu.org:
bug#25304; Package guix. (Mon, 16 Nov 2020 20:52:02 GMT) Full text and rfc822 format available.

Message #65 received at 25304 <at> debbugs.gnu.org (full text, mbox):

From: Miguel Ángel Arruga Vivas <rosen644835 <at> gmail.com>
To: Marius Bakke <marius <at> gnu.org>
Cc: 25304 <at> debbugs.gnu.org, 25508 <at> debbugs.gnu.org, John Darrington <jmd <at> gnu.org>,
 Leo Famulari <leo <at> famulari.name>
Subject: Re: bug#25304: bug#25508: Git hook shebangs should not be rewritten
Date: Mon, 16 Nov 2020 21:51:43 +0100
Marius Bakke <marius <at> gnu.org> writes:

> Miguel Ángel Arruga Vivas <rosen644835 <at> gmail.com> writes:
>
>> The attached patch fixes this one too, should I push it to master (as
>> the last change for git) or to core-updates or staging (as it might seem
>> looking at the dependencies)?
>
> LGTM.  Git (+ git-minimal) is below the 300 rebuild limit for 'master'
> (and I try to keep it that way!).

Thanks for the info and the fast review, I wasn't sure if it was 109+242
or just 242.  I've pushed it to master as
46ce24fb2d8c9f7dce16c4c08919f0fc108dbfae.

Happy hacking!
Miguel




bug archived. Request was from Debbugs Internal Request <help-debbugs <at> gnu.org> to internal_control <at> debbugs.gnu.org. (Tue, 15 Dec 2020 12:24:04 GMT) Full text and rfc822 format available.

This bug report was last modified 3 years and 132 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.