Problem building tuneup...

David Cleaver wraithx at morpheus.net
Sun Jun 26 05:14:06 CEST 2011


On 6/25/2011 7:01 PM, Torbjorn Granlund wrote:
> David Cleaver<wraithx at morpheus.net>  writes:
>
>    $ make tuneup
>    gcc -O2 -pedantic -m64 -std=gnu99 -mtune=k8 -march=k8    tuneup.c   -o tuneup
>
> This is very wrong.  There should be many steps in creating the tuneup
> executable, with -I options passed for each compilation.
>
> Some Windoze developer need to look into this.
>

Actually, looking into the Makefile, all I see is a target for 'tune' and not 
'tuneup'.  This may be a 'bug' in the manual.  I see that this was brought up on 
the gmp-bugs list back in January of 2008 by Jafet.  I have run into the same 
problem.

When I ran 'make tune' it started to compile all the sources, but hit a problem 
in time.c with:
libtool: compile:  gcc -DHAVE_CONFIG_H -I. -I.. -I.. -I../tests -O2 -pedantic 
-m64 -std=gnu99 -mtune=k8 -march=k8 -c time.c -o time.o
time.c: In function 'getrusage_backwards_p':
time.c:650: error: storage size of 'start' isn't known
time.c:650: error: storage size of 'prev' isn't known
time.c:650: error: storage size of 'next' isn't known
make[1]: *** [time.lo] Error 1
make[1]: Leaving directory `/d/Programming/gmp/gmp-5.0.2/tune'
make: *** [tune] Error 2

I see back in 2008 that you suggested changing:
!   struct rusage  start, prev, next;
to
!   struct_rusage  start, prev, next;

This worked for me, and it allowed 'make tune' to run to completion.  At this 
point ./tuneup started to run but quickly reported an error and quit with:
./tuneup
Parameters for ./mpn/generic/gmp-mparam.h
The system cannot find the path specified.
The system cannot find the path specified.
The system cannot find the path specified.
make: *** [tune] Error 128

I think this just needs the '..' and not the '.' in front of the /mpn/, but I'm 
not sure where to change that line.


More information about the gmp-bugs mailing list