#210 Building 12.7.1 msvc with GMP_TYPE = p3 fails

HEAD
closed
nobody
None
1
2014-09-23
2012-10-02
Anonymous
No

In msvc\Makefile, setting GMP_TYPE = p3 yields for target ecl_min$(EXE):

    cl /Feecl_min.exe cinit.obj c\all_symbols.obj ...
eclgmp.lib(divrem_1.obj) : error LNK2005: ___gmpn_divrem_1c already defined in object eclgmp.lib(divrem_1.obj).
eclgmp.lib(divrem_1.obj) : error LNK2005: ___gmpn_divrem_1 already defined in object eclgmp.lib(divrem_1.obj).

.
ecl_min.exe : fatal error LNK1169: one or more multiply defined symbols found.

Reason:

In msvc\gmp\Makefile by target mpn_p3.lib, macro MPN_P3_OBJS generates these files twice:
- divrem_1.obj
- lshift.obj
- popham.obj
- rshift.obj

Solution:

In my case, I erased in macro MPN_P3_ASM_SOURCES the lines

.
mpn\x86i\divrem_1.asm \
mpn\x86i\lshift.asm \
.
mpn\x86i\rshift.asm \
.
mpn\x86i\p6\mmx\popham.asm \
.

and build successfully.

Greetings and Thanks.
Martin Schell

Discussion


Anonymous


Cancel   Add attachments