install@sodium:~/gmp-4.1.2/mpz> /usr/local/bin/gcc -DHAVE_CONFIG_H -I. -I. - I.. -D__GMP_WITHIN_GMP -I.. -g -O2 -fomit-frame-pointer -mcpu=pentium4 - march=pentium4 -c aorsmul.c `-mcpu=' is deprecated. Use `-mtune=' or '-march=' instead. aorsmul.c:44: error: conflicting types for '__gmpz_aorsmul' aorsmul.c:39: error: previous declaration of '__gmpz_aorsmul' was here aorsmul.c:44: error: conflicting types for '__gmpz_aorsmul' aorsmul.c:39: error: previous declaration of '__gmpz_aorsmul' was here Torbjörn Granlund says: I think this is a bug in the gcc 3.4 parser that causes it to reject regparm attributes. I have tried to figure out some alternative syntax that gcc 3.4 could accept, but found nil.
Can you attach the preprocessed source?
Created attachment 6149 [details] preprocessed source of mpz/aorsmul.c from gmp-4.1.2
See <http://gcc.gnu.org/ml/gcc/2004-03/msg00039.html> for why this was changed.
*** Bug 15132 has been marked as a duplicate of this bug. ***
*** Bug 17830 has been marked as a duplicate of this bug. ***
*** Bug 17932 has been marked as a duplicate of this bug. ***
*** Bug 25415 has been marked as a duplicate of this bug. ***
The problem still exist. My working environment is : GCC : gcc (GCC) 3.4.4 (cygming special, gdc 0.12, using dmd 0.125) GMP : the latest release version (gmp4.1) During compiling, the error will occur. But I fount if I remove the code "static void __gmpz_aorsmul _PROTO ((REGPARM_3_1 (mpz_ptr w, mpz_srcptr x, mpz_srcptr y, mp_size_t sub))) REGPARM_ATTR (1);" , it can be passed. So to solve the problem, you can remove the static declaration for the functions that have conflicting type. But I am not sure whether is correct or not. It only make the process of compiling passed.