Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 751472 - app-crypt/eid-mw: if dash is selected as system sh
Summary: app-crypt/eid-mw: if dash is selected as system sh
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Vincent Hardy
URL:
Whiteboard:
Keywords: PATCH
Depends on:
Blocks: nonbash
  Show dependency tree
 
Reported: 2020-10-27 15:53 UTC by jan vereecke
Modified: 2021-01-03 20:55 UTC (History)
3 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments
eid-mw-5.0.8-use-printf-in-Makefile.patch (eid-mw-5.0.8-use-printf-in-Makefile.patch,1.41 KB, patch)
2020-12-21 21:14 UTC, Kerin Millar
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description jan vereecke 2020-10-27 15:53:26 UTC
when I emerge app-crypt/eid-mw-4.4.27 I get compile time errors.
The cause is that the source contains a jpg (coat-of-arms.nl.jpg) file that the autogenerated makefile converts to an include file.

This conversion uses 'echo -e "#include ...."'
When the system shell is bash, this works fine, and the resulting file coat-of-arms.nl.c compiles without issue.

When the system shell is dash (eselect sh set dash), it interpretes the echo command differently, and the coat-of-arms.nl.c file starts with '-e #include ...."'.

Of course, the compiler chokes on the -e.

That means that either something must be done upstream (let autoconf detect what system shell is in use and adapt the Makefile accordingly), or that the ebuild must check that the shell is of a type that recognizes 'echo -e'.
Comment 1 Kerin Millar 2020-12-21 21:13:32 UTC
(In reply to jan vereecke from comment #0)
> That means that either something must be done upstream (let autoconf detect
> what system shell is in use and adapt the Makefile accordingly), or that the
> ebuild must check that the shell is of a type that recognizes 'echo -e'.

Rather, it should use printf. Please try the impending patch.
Comment 2 Kerin Millar 2020-12-21 21:14:58 UTC
Created attachment 679152 [details, diff]
eid-mw-5.0.8-use-printf-in-Makefile.patch
Comment 3 jan vereecke 2020-12-22 12:00:34 UTC
I confirm that this patch works works with dash
Comment 4 Vincent Hardy 2021-01-02 18:34:15 UTC
(In reply to Kerin Millar from comment #2)
> Created attachment 679152 [details, diff] [details, diff]
> eid-mw-5.0.8-use-printf-in-Makefile.patch

Thank you for the patch

I asked @amynka to commit new ebuild with your patch (eid-mw-5.0.11 + live ebuild)
Comment 5 Sam James archtester gentoo-dev Security 2021-01-02 19:54:58 UTC
My plan is to go through and commit a bunch of Kerin’s patches in bulk when I get a chance, but of course Amy is welcome to if she does it first (very welcome, in fact!)
Comment 6 Larry the Git Cow gentoo-dev 2021-01-03 20:55:12 UTC
The bug has been closed via the following commit(s):

https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=0cf87b70d683bb210882ef7f171bbd8b44123d63

commit 0cf87b70d683bb210882ef7f171bbd8b44123d63
Author:     Amy Liffey <amynka@gentoo.org>
AuthorDate: 2021-01-03 20:50:57 +0000
Commit:     Amy Liffey <amynka@gentoo.org>
CommitDate: 2021-01-03 20:54:57 +0000

    app-crypt/eid-mw: version bump 5.0.11, fix bug #751472
    
    Closes: https://bugs.gentoo.org/751472
    Submitted-by: Vincent Hardy <vincent.hardy.be@gmail.com>
    
    Package-Manager: Portage-3.0.9, Repoman-2.3.23
    Signed-off-by: Amy Liffey <amynka@gentoo.org>

 app-crypt/eid-mw/Manifest                          |   1 +
 app-crypt/eid-mw/eid-mw-5.0.11.ebuild              | 111 +++++++++++++++++++++
 app-crypt/eid-mw/eid-mw-9999.ebuild                |   5 +-
 .../eid-mw/files/use-printf-in-Makefile.patch      |  21 ++++
 4 files changed, 137 insertions(+), 1 deletion(-)