LNK9112001: LINK Won't Use Multiple Libraries with Same Name

ID Number: Q78930

3.x 4.0x 4.10 5.0x 5.1x 5.20 | 5.0x 5.10 5.11 5.13

MS-DOS | OS/2

buglist5.13 buglist5.15 buglist5.20

Summary:

PROBLEM ID: LNK9112001

SYMPTOMS

In the Microsoft LINK utility versions 3.0 through 5.2, when an

application is linked to multiple libraries with the same name in

different directories, the following error may be generated:

LINK : error L2029: 'symbol' : unresolved external

CAUSE

LINK will search for symbols only in the first library with the

name that was listed. This causes all referenced symbols in the

additional libraries to be unresolved externals.

RESOLUTION

To work around this problem, rename the libraries so that they all

have unique names.

STATUS

Microsoft has confirmed this to be a problem in LINK versions 3.65,

3.69, 4.06, 4.07, 4.1, 5.01.2, 5.01.21, 5.03, 5.05, 5.1, 5.11,

5.13, 5.15, and 5.2. We are researching this problem and will post

new information here as it becomes available.

More Information:

The following linker response file will cause all the referenced

symbols in the TEST.LIB file in the \LIB2 directory to be unresolved.

Changing the name of at least one of the two libraries will solve the

problem.

TEST.LRF

--------

TEST.OBJ

TEST.EXE

TEST.MAP

Additional reference words: buglist3.65 buglist3.69 buglist4.06

buglist4.07 buglist4.10 buglist5.01 buglist5.03 buglist5.05 buglist501.20

buglist501.21 buglist5.10 buglist5.11 3.00 3.01 3.02 3.04 3.05 3.06 3.51

3.55 3.60 3.61 3.64 4.10 5.02 5.05