You are not logged in.

#1 2013-02-25 22:01:07

nponeccop
Member
Registered: 2011-09-05
Posts: 14

Why time package is not in base - it's required by IEEE Std 1003.1

http://pubs.opengroup.org/onlinepubs/00 … /time.html

Without `time` package from `extra` repo standard-compliant `time -p foo bar` doesn't work in `sh` or `sh --posix`.

Unfortunately I couldn't find discussion if any, as `time` is so common keyword.

Offline

#2 2013-02-25 22:07:01

falconindy
Developer
From: New York, USA
Registered: 2009-10-22
Posts: 4,095
Website

Re: Why time package is not in base - it's required by IEEE Std 1003.1

I fail to see the relevance. You're drawing imaginary correlations between package groups and (outdated) POSIX standards.

Offline

#3 2013-02-25 22:58:04

Trilby
Forum Moderator
From: Massachusetts, USA
Registered: 2011-11-29
Posts: 13,994
Website

Re: Why time package is not in base - it's required by IEEE Std 1003.1

The POSIX standard doesnt/didn't require that `time` be a separate installed package.  Time is a bash shell built in, and the bash built-in version meets the POSIX standard.  How does `time -p foo bar` not work?


InterrobangSlider
• How's my coding? See this page.
• How's my moderating? Feel free to email any concerns, complaints, or objections.

Online

#4 2013-02-26 10:08:04

nponeccop
Member
Registered: 2011-09-05
Posts: 14

Re: Why time package is not in base - it's required by IEEE Std 1003.1

The POSIX standard requires `sh` utility to be present and requires `sh -c "time -p ls"` to work. In Archlinux this doesn't work in the base system as it only works if `time` package outside of `base` group is installed . It is irrelevant whether it works in bash or not.

So adding `time` package to `base` group will improve POSIX compliance as more standard-compliant scripts will run.

So I have 3 questions:

1) Is compliance to IEEE Std 1003.1 among design goals of `base` package group?
2) Is it a bug that sh -c "time ls" fails to run `time` builtin utility and looks for an executable instead?
3) If answer to (1) is "yes" and answer to (2) is "no" is it a bug that `time` is not in `base`?

Offline

#5 2013-02-26 11:51:33

Trilby
Forum Moderator
From: Massachusetts, USA
Registered: 2011-11-29
Posts: 13,994
Website

Re: Why time package is not in base - it's required by IEEE Std 1003.1

nponeccop wrote:

The POSIX standard requires ... `sh -c "time -p ls"` to work.

Where is this requirement?  It's not in the link you posted.


InterrobangSlider
• How's my coding? See this page.
• How's my moderating? Feel free to email any concerns, complaints, or objections.

Online

#6 2013-02-26 12:42:46

nponeccop
Member
Registered: 2011-09-05
Posts: 14

Re: Why time package is not in base - it's required by IEEE Std 1003.1

sh - says `sh -c command` should work with utilities.
time - says `time` is a valid utility and -p is a valid option

`time -p ls` I think is not required to work as `ls` may be built-in. But it's only an example - feel free to replace it with an executable of your choice.

Last edited by nponeccop (2013-02-26 12:56:17)

Offline

#7 2013-02-26 13:11:08

brebs
Member
Registered: 2007-04-03
Posts: 3,439

Re: Why time package is not in base - it's required by IEEE Std 1003.1

So, GNU time last saw a release in 1996, and has to be patched in Linux so as not to produce garbage output. Not a very good standard piece of software!

I don't even see it in e.g. opensuse at all. And I've never heard of any software that requires it.

nponeccop wrote:

feel free to replace it with an executable of your choice.

No, *you* come up with a decent example of something worth caring about wink

Offline

#8 2013-02-26 13:11:18

Allan
Developer
From: Brisbane, AU
Registered: 2007-06-09
Posts: 10,416
Website

Re: Why time package is not in base - it's required by IEEE Std 1003.1

"Arch is what you make it".   If you want your system to conform to some outdated standard, you can by installing the needed packages.  It is not a very strong consideration in Arch development...

Offline

Board footer

Powered by FluxBB