ltib
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Ltib] Make rpmbuild invoke bash instead of sh?


From: Stuart Hughes
Subject: Re: [Ltib] Make rpmbuild invoke bash instead of sh?
Date: Tue, 30 Jun 2009 09:52:14 +0100
User-agent: Thunderbird 2.0.0.16 (X11/20080707)

Hi Svein,

Welcome to the list. I agree with most of your observations. A while back I went through an exercise of making ltib and the rpm spec files safe in dash as well as dash so LTIB should be fine on Ubuntu even if it uses dash. If there are any places left in qtopia.spec that are not dash safe, maybe you could indicate them or send a patch that fixes them.

So far as changing /bin/sh to point to bash, I don't think this would break your install of Ubuntu as bash's command set is a superset of dash AFAIK. I think the idea of dash is that it maybe boots a bit faster?

BTW: take a look at the public project, maybe its already fixed (the Freescale BSP tend to lag).

        http://cvs.savannah.gnu.org/viewvc/ltib/?root=ltib

Regards, Stuart

Svein Seldal wrote:
Hello guys!

I'm new to this list (and to LTIB) and I have to admit that I'm struggling a bit. I have a Freescale iMX35PDK and am running Debian 9.04 on host.

This mail might ruin my first impression, yet I think I can handle it :D

My compilation has stopped at building of qtopia because of a script error. Now, I know why it fails:

The qtopia spec files uses bash script syntaxes, while rpmbuild seem to invoke the script as #/bin/sh. On a Debian and Ubuntu based system, /bin/sh is not bash, it's dash.

http://en.wikipedia.org/wiki/Debian_Almquist_shell

It was proposed earlier on this list to change the /bin/sh symlink to bash. This is NOT a recommended solution, because it may break Debian/Ubuntu bootup.

How can I then configure rpmbuild to invoke the script as a proper bash script (which is should)? There's nothing in the .spec file specifying which script engine to use. According to google, it's seems the bond to /bin/sh might be hardcoded. Anybody knows?

IMHO we can't and shouldn't assume that /bin/sh is bash. (Hence if my above statements are true, rpmbuild is broken.) Coming from a non-rpm based linux, I'd propose fixing this for our little world by either not rely on bash features, or to invoke the bash script separately.


Best regards,
Svein Seldal



_______________________________________________
LTIB home page: http://bitshrine.org

Ltib mailing list
address@hidden
http://lists.nongnu.org/mailman/listinfo/ltib





reply via email to

[Prev in Thread] Current Thread [Next in Thread]