[flac-dev] [PATCH] Fix compilation on OS/2
Dave Yeo
dave.r.yeo at gmail.com
Wed Feb 3 14:37:02 PST 2016
On 01/24/16 12:29 PM, Erik de Castro Lopo wrote:> Dave Yeo wrote:
>
>> After this the build dies with,
>> util.c: In function 'benchmark_function':
>> util.c:124:17: error: 'CLOCK_PROCESS_CPUTIME_ID' undeclared (first use
>> in this function)
>> clock_gettime (CLOCK_PROCESS_CPUTIME_ID, &start) ;
>>
>> Would using gettimeofday() be accurate enough?
>
> AS a fall back yes, but not as replacement on platforms with clock_gettime().
>
>> Perhaps simpler just to
>> disable the microbench test on OS/2 as gettimeofday() would require a
>> configure test and OS/2 is a minor platform?
>
>
> I would accept a patch that disables the microsbenchmark on OS/2 I would
> also accept one that uses gettimeofday() when clock_gettime() is not
> available.
Here's one attempt, added configure options to disable AVX and clock_gettime, only tested on OS/2.
With this compilation succeeds on OS/2. Make check does eventually fail with,
...
WAVE fixup test... prepare... encode... decode... compare... OK
AIFF fixup test... prepare... encode... decode... compare... OK
Generating multiple input files from noise...
ERROR: creating files with dd
...
which I don't understand. Perhaps buggy dd. I take it this succeeds on Windows. Since $COMSPEC is set here we take the if_win path.
Dave
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0001-Enable-disabling-AVX-and-AVX2-instructions-through-a.patch
Type: application/x-patch
Size: 1903 bytes
Desc: not available
Url : http://lists.xiph.org/pipermail/flac-dev/attachments/20160203/a1593929/attachment.bin
-------------- next part --------------
A non-text attachment was scrubbed...
Name: 0002-Use-gettimeofday-for-benchmarking.patch
Type: application/x-patch
Size: 2802 bytes
Desc: not available
Url : http://lists.xiph.org/pipermail/flac-dev/attachments/20160203/a1593929/attachment-0001.bin
More information about the flac-dev
mailing list