Closed algorythmic closed 6 months ago
Thanks for the report! The motivation is described in the commit you linked to, but we definetly need to add the standard version as well then!
The futimesat function takes an extra argument compared to bionic one: int flags, due to that unar expects that type of futimesat function
AFAICT the unar
package just needs lutimes
, and to implement this, the termux-added sys_time.c
used a static 4-argument futimesat
function:
i.e. no upstream code actually expects a 4-argument form.
@algorythmic Yeah, you are right.
Should be fixed by https://github.com/termux/termux-packages/pull/19615.
Thanks! Though I think the change of argument type for lutimes
in https://github.com/termux/libandroid-utimes/commit/155baa814a96c4888253c5b182144483a6f1a82e isn't quite right.
lutimes
takes a timeval
. If it is to be implemented via utimensat
, it needs to convert to a timespec
.
Right, was misled by some compilation warnings there.
Fixed in https://github.com/termux/libandroid-utimes/commit/5e813795e9288cf09ef949355731bd89b7839fd8 (hopefully)
Problem description
futimesat
was changed in fbc59da0 (and https://github.com/termux/libandroid-utimes/commit/5316690c7452ff71f1bcea93cccf5be142818196) from the usual 3-argument form to one with an extra argument.I'm not sure what the motivation was for adding the extra argument, but this (obviously) breaks any existing code that uses
futimesat
.For example, building GNU coreutils fails with:
What steps will reproduce the bug?
Try building code that uses
futimesat
as it is documented.What is the expected behavior?
No response
System information
termux-info: