Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!

Bug 517426

Summary: sys-libs/libfaketime - faketime 'last friday 5 pm' /bin/date -//- Error: Timestamp to fake not recognized, please re-try with a different timestamp.
Product: Gentoo Linux Reporter: Renato Alves <simpledark>
Component: [OLD] Core systemAssignee: Tim Harder <radhermit>
Status: RESOLVED FIXED    
Severity: normal    
Priority: Normal    
Version: unspecified   
Hardware: AMD64   
OS: Linux   
Whiteboard:
Package list:
Runtime testing required: ---

Description Renato Alves 2014-07-18 16:00:52 UTC
With sys-libs/libfaketime-0.9.1 the following commands fail:

% faketime 'last friday 5 pm' /bin/date
Error: Timestamp to fake not recognized, please re-try with a different timestamp.

% faketime -f '+2y' /bin/date
zsh: segmentation fault  faketime -f '+2y' /bin/date

The segmentation fault has been fixed upstream in a more recent version.
However both sys-libs/libfaketime-0.9.5 and 0.9.6 display the following errors:

% faketime 'last friday 5 pm' /bin/date
ERROR: ld.so: object '/usr/local/lib/faketime/libfaketime.so.1' from LD_PRELOAD cannot be preloaded: ignored.
Sex Jul 18 16:54:53 WEST 2014

% faketime -f '+2y' /bin/date          
ERROR: ld.so: object '/usr/local/lib/faketime/libfaketime.so.1' from LD_PRELOAD cannot be preloaded: ignored.
Sex Jul 18 16:54:56 WEST 2014

The binary is looking for libfaketime.so.1 in the wrong folder effectively making the command useless given that the date is unchanged.


I am aware that you can still use LD_PRELOAD and FAKETIME if one points to the library directly but you need to know where to find the library beforehand.
Comment 1 Tim Harder gentoo-dev 2014-07-18 16:37:20 UTC
Fixed in 0.9.6-r1.
Comment 2 Renato Alves 2014-07-18 16:44:57 UTC
Thanks, that was a quick one.

Cheers,
R