Re: More than 10% of all Fedora spec files are not POSIX sh compliant

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

 



> > > Fedora is based on GNU tools versus strict POSIX compliant ones. As
> > > such, packagers can expect that /bin/sh is /bin/bash, /bin/awk is
> > > /bin/gawk, /bin/cc is /bin/gcc ad naseum. This means that unless
> > > specified elsewhere that a 'bashism', 'gawkism', 'gcc-ism' is not to
> > > be used, packagers may rely on tools to act as the upstream GNU tools
> > > in their spec files.

> So please write the spec you want to see.

Good point! Here is a variation on your proposal:

> Fedora is based on GNU tools versus strict POSIX compliant ones. As
> such, package maintainers can expect RPM build steps and scriptlets
> to be run with bash and that core programs come with GNU extensions.
> This means that unless specified elsewhere that a 'bashism', 'gawkism',
> 'gcc-ism' or other GNUism is not to be used, they may rely on tools to
> act as the upstream GNU tools in their spec files.
>
> When shipping scripts from upstream, care should be taken to check
> whether they rely on such GNUisms and report portability bugs upstream.

Funny enough, people often tell me not to use $(...) and switch to
`...` because the former "is" a bashism (spoiler alert, it isn't) and
as a result the only thing reported to me in this regard is always a
false positive :(

Dridi
_______________________________________________
devel mailing list -- devel@xxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe send an email to devel-leave@xxxxxxxxxxxxxxxxxxxxxxx
Fedora Code of Conduct: https://getfedora.org/code-of-conduct.html
List Guidelines: https://fedoraproject.org/wiki/Mailing_list_guidelines
List Archives: https://lists.fedoraproject.org/archives/list/devel@xxxxxxxxxxxxxxxxxxxxxxx




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Fedora Announce]     [Fedora Users]     [Fedora Kernel]     [Fedora Testing]     [Fedora Formulas]     [Fedora PHP Devel]     [Kernel Development]     [Fedora Legacy]     [Fedora Maintainers]     [Fedora Desktop]     [PAM]     [Red Hat Development]     [Gimp]     [Yosemite News]

  Powered by Linux