On Fri, Dec 1, 2023 at 8:50 PM Pedro Falcato via groups.io <pedro.falcato=gmail....@groups.io> wrote: > > On Fri, Dec 1, 2023 at 5:07 PM Michael Kubacki > <mikub...@linux.microsoft.com> wrote: > > > > Hi Pedro, > > > > Visual Studio NOOPT builds result in linker errors. I combined your > > patch series with the test instruction change in this PR - > > https://github.com/tianocore/edk2/pull/5096. > > > > You can use a PR to test the VS build. > > Thanks for the heads up, but I ended up booting Windows to expedite the > process. > > So, I noticed from the build logs that libcmtd.lib was having issues > doing a /WHOLEARCHIVE link (not unheard of, had the same problems with > Linux system libraries). Then I noticed in MSDN: > "The /WHOLEARCHIVE option forces the linker to include every object > file from either a specified static library, or if no library is > specified, from all static libraries specified to the LINK command" > Note the "from all static libraries specified to the LINK command". So > I noticed libcmtd.lib was being specified manually, and I simply > deleted > > /NODEFAULTLIB:libcmt.lib libcmtd.lib
... Forgot to mention that deleting this line allows the link to complete and /WHOLEARCHIVE has the intended effect. -- Pedro -=-=-=-=-=-=-=-=-=-=-=- Groups.io Links: You receive all messages sent to this group. View/Reply Online (#111986): https://edk2.groups.io/g/devel/message/111986 Mute This Topic: https://groups.io/mt/102904623/21656 Group Owner: devel+ow...@edk2.groups.io Unsubscribe: https://edk2.groups.io/g/devel/unsub [arch...@mail-archive.com] -=-=-=-=-=-=-=-=-=-=-=-