I have one solution with several projects. Say ProjectA
is the one that will produce the exe file, and ProjectB
simply produces a .lib
file. I have checked that ProjectA
depends on ProjectB
, so that ProjectB
will always compile before ProjectA
.
When I compile ProjectB
everything goes fine. But if I compile ProjectA
I get linking errors saying that some method of B does not exist. I have checked, and it does exist.
¿What is going on?
Thanks for your help!
项目属性,链接器,常规:将“链接库依赖项”设置为“是”。
I found there were several things I needed to check to fix the vexing link error:
"link.exe" exited with code 1104.
Project -> Linker -> General -> Link Library Dependencies: Yes
Project Depdendencies
and ensure Project A
references Project B
ProjectA
ensure that you don't have an additional linker library dependency on ProjectB.lib
. This seems to encourage to look VS to look for another library called ProjectB.lib
, elsewhere.$(SolutionDir)$(Platform)\$(Configuration)\
).
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.