New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 703005 link

Starred by 2 users

Issue metadata

Status: WontFix
Owner:
Last visit > 30 days ago
Closed: May 2017
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: Windows
Pri: 3
Type: Bug



Sign in to add a comment

Win10 x64 incremental build fails building third_party/opus/opus.lib on uuid.lib(oaidl_i.obj).

Project Member Reported by wkorman@chromium.org, Mar 19 2017

Issue description

Filing bug as breakout from https://groups.google.com/a/chromium.org/d/msg/chromium-dev/jnofouwbn0k/FYhAA8qYAwAJ

Not limited to opus, I saw error building test_ime_driver.service.exe as well, detail below.

I am working through building Chrome Win10 at home with ToT sans-goma just now. This is my first time checking out and building on this machine, which is a fairly vanilla PC with VS 2015, VS 2017 and WDK installed.

gn args:

is_debug = true
is_component_build = true
enable_nacl = false

but I saw same error previously with entirely empty thus default gn args. Error as:

D:\chromium\src>ninja -C out\Debug content_shell
ninja: Entering directory `out\Debug'
[3440/17879] LINK(DLL) base.dll base.dll.lib base.dll.pdb
FAILED: base.dll base.dll.lib base.dll.pdb
D:/depot_tools/python276_bin/python.exe ../../build/toolchain/win/tool_wrapper.py link-wrapper environment.x64 False link.exe /nologo /IMPLIB:./base.dll.lib /DLL /OUT:./base.dll /PDB:./base.dll.pdb @./base.dll.rsp
uuid.lib(oaidl_i.obj) : MSIL .netmodule or module compiled with /GL found; restarting link with /LTCG; add /LTCG to the link command line to improve linker performance
LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/LTCG' specification
LINK : error LNK1218: warning treated as error; no output file generated
[3449/17879] LIB obj/third_party/opus/opus.lib
ninja: build stopped: subcommand failed.

I tried rebuilding with is_component_build = false and got much farther but eventually saw failure with:

D:\chromium\src>ninja -C out\Debug content_shell
ninja: Entering directory `out\Debug'
[12406/18055] LINK test_ime_driver.service.exe test_ime_driver.service.exe.pdb
FAILED: test_ime_driver.service.exe test_ime_driver.service.exe.pdb
D:/depot_tools/python276_bin/python.exe ../../build/toolchain/win/tool_wrapper.py link-wrapper environment.x64 False link.exe /nologo /OUT:./test_ime_driver.service.exe /PDB:./test_ime_driver.service.exe.pdb @./test_ime_driver.service.exe.rsp
uuid.lib(unknwn_i.obj) : MSIL .netmodule or module compiled with /GL found; restarting link with /LTCG; add /LTCG to the link command line to improve linker performance
LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/LTCG' specification
LINK : error LNK1218: warning treated as error; no output file generated
[12407/18055] ACTION //v8:run_mksnapshot(//build/toolchain/win:x64)
ninja: build stopped: subcommand failed.

Before turning off component build I tried cleaning and rebuilding but still saw same error.

I looked through opus BUILD.gn and didn't see obvious error though I don't spend much time in build files, I see this as something I would investigate to understand detail re: incremental build flag ramifications:

  configs -= [ "//build/config/compiler:chromium_code" ]
  configs += [ "//build/config/compiler:no_chromium_code" ]

Marking P2 but may be a P1 since it appears at least some Windows builds are broken.
 

Comment 1 by thakis@chromium.org, Mar 20 2017

Owner: w...@chromium.org
As mentioned on the thread, `fatal_linker_warnings = false` in your gn.args should fix this (can you confirm)? If so, this is due to https://codereview.chromium.org/2581893002/
Yes, that fixes build of content_shell. Below are the affected targets in case helpful.

[3647/17316] LINK(DLL) base.dll base.dll.lib base.dll.pdb
uuid.lib(oaidl_i.obj) : MSIL .netmodule or module compiled with /GL found; restarting link with /LTCG; add /LTCG to the link command line to improve linker performance
LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/LTCG' specification
[3755/17316] LINK(DLL) device_battery.dll device_battery.dll.lib device_battery.dll.pdb
uuid.lib(uuids.obj) : MSIL .netmodule or module compiled with /GL found; restarting link with /LTCG; add /LTCG to the link command line to improve linker performance
LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/LTCG' specification
[5139/17316] LINK(DLL) skia.dll skia.dll.lib skia.dll.pdb
uuid.lib(unknwn_i.obj) : MSIL .netmodule or module compiled with /GL found; restarting link with /LTCG; add /LTCG to the link command line to improve linker performance
LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/LTCG' specification
[8221/17316] LINK(DLL) gfx.dll gfx.dll.lib gfx.dll.pdb
uuid.lib(directmanipulation_i.obj) : MSIL .netmodule or module compiled with /GL found; restarting link with /LTCG; add /LTCG to the link command line to improve linker performance
LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/LTCG' specification
[8349/17316] LINK(DLL) sensors.dll sensors.dll.lib sensors.dll.pdb
uuid.lib(cguid_i.obj) : MSIL .netmodule or module compiled with /GL found; restarting link with /LTCG; add /LTCG to the link command line to improve linker performance
LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/LTCG' specification
[8449/17316] LINK(DLL) ui_base.dll ui_base.dll.lib ui_base.dll.pdb
uuid.lib(shguids2.obj) : MSIL .netmodule or module compiled with /GL found; restarting link with /LTCG; add /LTCG to the link command line to improve linker performance
LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/LTCG' specification
[8457/17316] LINK(DLL) ui_base_ime.dll ui_base_ime.dll.lib ui_base_ime.dll.pdb
uuid.lib(unknwn_i.obj) : MSIL .netmodule or module compiled with /GL found; restarting link with /LTCG; add /LTCG to the link command line to improve linker performance
LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/LTCG' specification
[8458/17316] LINK(DLL) bluetooth.dll bluetooth.dll.lib bluetooth.dll.pdb
uuid.lib(bthguid.obj) : MSIL .netmodule or module compiled with /GL found; restarting link with /LTCG; add /LTCG to the link command line to improve linker performance
LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/LTCG' specification
[8476/17316] LINK(DLL) accessibility.dll accessibility.dll.lib accessibility.dll.pdb
uuid.lib(cguid_i.obj) : MSIL .netmodule or module compiled with /GL found; restarting link with /LTCG; add /LTCG to the link command line to improve linker performance
LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/LTCG' specification
[10795/17313] LINK(DLL) media.dll media.dll.lib media.dll.pdb
uuid.lib(unknwn_i.obj) : MSIL .netmodule or module compiled with /GL found; restarting link with /LTCG; add /LTCG to the link command line to improve linker performance
LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/LTCG' specification
[10808/17313] LINK(DLL) capture_lib.dll capture_lib.dll.lib capture_lib.dll.pdb
uuid.lib(unknwn_i.obj) : MSIL .netmodule or module compiled with /GL found; restarting link with /LTCG; add /LTCG to the link command line to improve linker performance
LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/LTCG' specification
[10855/17313] LINK(DLL) views.dll views.dll.lib views.dll.pdb
uuid.lib(ieguids.obj) : MSIL .netmodule or module compiled with /GL found; restarting link with /LTCG; add /LTCG to the link command line to improve linker performance
LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/LTCG' specification
[17291/17313] LINK(DLL) content.dll content.dll.lib content.dll.pdb
uuid.lib(cguid_i.obj) : MSIL .netmodule or module compiled with /GL found; restarting link with /LTCG; add /LTCG to the link command line to improve linker performance
LINK : warning LNK4075: ignoring '/INCREMENTAL' due to '/LTCG' specification

Building chrome target is failing with a different error that looks unrelated, I'll look into that separately but pasting for posterity:

FAILED: gen/third_party/dom_distiller_js/test_sample.pb.h gen/third_party/dom_distiller_js/test_sample.pb.cc pyproto/third_party/dom_distiller_js/test_sample_pb2.py gen/third_party/dom_distiller_js/test_sample_json_converter.h
D:/depot_tools/python276_bin/python.exe ../../tools/protoc_wrapper/protoc_wrapper.py test_sample.proto --protoc ./protoc.exe --proto-in-dir ../../third_party/dom_distiller_js --cc-out-dir gen/third_party/dom_distiller_js --py-out-dir pyproto/third_party/dom_distiller_js --plugin ../../third_party/dom_distiller_js/protoc_plugins/json_values_converter.bat --plugin-out-dir gen/third_party/dom_distiller_js --plugin-options output_dir=:
--plugin_out: protoc-gen-plugin: Plugin output is unparseable: \r\nD:\\chromium\\src\\out\\Debug>setlocal\r\n\r\nD:\\chromium\\src\\out\\Debug>set PATH=D:\\depot_tools\\python276_bin;D:\\depot_tools\\python276_bin\\Scripts;C:\\Program Files\\Oculus\\Support\\oculus-runtime;C:\\Program Files (x86)\\Razer Chroma SDK\\bin;C:\\Program Files\\Razer Chroma SDK\\bin;C:\\Program Files (x86)\\Intel\\iCLS Client\\;C:\\Program Files\\Intel\\iCLS Client\\;C:\\Windows\\system32;C:\\Windows;C:\\Windows\\System32\\Wbem;C:\\Windows\\System32\\WindowsPowerShell\\v1.0\\;C:\\Program Files (x86)\\Intel\\Intel(R) Management Engine Components\\DAL;C:\\Program Files\\Intel\\Intel(R) Management Engine Components\\DAL;C:\\Program Files (x86)\\Intel\\Intel(R) Management Engine Components\\IPT;C:\\Program Files\\Intel\\Intel(R) Management Engine Components\\IPT;C:\\Program Files (x86)\\NVIDIA Corporation\\PhysX\\Common;D:\\depot_tools;C:\\WINDOWS\\system32;C:\\WINDOWS;C:\\WINDOWS\\System32\\Wbem;C:\\WINDOWS\\System32\\WindowsPowerShell\\v1.0\\;C:\\Users\\Walter Korman\\.dnx\\bin;C:\\Program Files\\Microsoft DNX\\Dnvm\\;C:\\Program Files\\Microsoft SQL Server\\130\\Tools\\Binn\\;C:\\Program Files (x86)\\Windows Kits\\10\\Windows Performance Toolkit\\;C:\\WINDOWS\\SysWOW64\\WindowsPowerShell\\v1.0\\Modules\\TShell\\TShell\\;C:\\Users\\Walter Korman\\AppData\\Local\\Microsoft\\WindowsApps; \r\n\r\nD:\\chromium\\src\\out\\Debug>\"D:\\depot_tools\\python276_bin\\python.exe\" D:\\chromium\\src\\third_party\\dom_distiller_js\\protoc_plugins\\\\json_values_converter.py \r\nz\220Z\n\034test_sample_json_converter.hz\357Y// GENERATED FILE\n// This file generated by DomDistillerJs protoc plugin.\n#include \"test_sample.pb.h\"\n\n// base dependencies\n#include \"base/values.h\"\n\n#include <memory>\n#include <string>\n#include <utility>\n\nnamespace dom_distiller {\n  namespace test_sample {\n    namespace proto {\n      namespace json {\n        class TypeTest {\n         public:\n          class Message {\n           public:\n            static bool ReadFromValue(const base::Value* json, dom_distiller::test_sample::proto::TypeTest::Message* message) {\n              const base::DictionaryValue* dict;\n              if (!json->GetAsDictionary(&dict)) goto error;\n              if (dict->HasKey(\"1\")) {\n                bool field_value;\n                if (!dict->GetBoolean(\"1\", &field_value)) {\n                  goto error;\n                }\n                message->set_dummy(field_value);\n              }\n              return true;\n\n            error:\n              return false;\n            }\n\n            static std::unique_ptr<base::DictionaryValue> WriteToValue(const dom_distiller::test_sample::proto::TypeTest::Message& message) {\n              std::unique_ptr<base::DictionaryValue> dict(new base::DictionaryValue());\n              if (message.has_dummy()) {\n                dict->SetBoolean(\"1\", message.dummy());\n              }\n              return dict;\n            }\n          };\n\n          static bool ReadFromValue(const base::Value* json, dom_distiller::test_sample::proto::TypeTest* message) {\n            const base::DictionaryValue* dict;\n            if (!json->GetAsDictionary(&dict)) goto error;\n            if (dict->HasKey(\"1\")) {\n              float field_value;\n              if (!dict->GetDouble(\"1\", &field_value)) {\n                goto error;\n              }\n              message->set_float_value(field_value);\n            }\n            if (dict->HasKey(\"2\")) {\n              double field_value;\n              if (!dict->GetDouble(\"2\", &field_value)) {\n                goto error;\n              }\n              message->set_double_value(field_value);\n            }\n            if (dict->HasKey(\"3\")) {\n              int field_value;\n              if (!dict->GetInteger(\"3\", &field_value)) {\n                goto error;\n              }\n              message->set_int32_value(field_value);\n            }\n            if (dict->HasKey(\"4\")) {\n              bool field_value;\n              if (!dict->GetBoolean(\"4\", &field_value)) {\n                goto error;\n              }\n              message->set_bool_value(field_value);\n            }\n            if (dict->HasKey(\"5\")) {\n              std::string field_value;\n              if (!dict->GetString(\"5\", &field_value)) {\n                goto error;\n              }\n              message->set_string_value(field_value);\n            }\n            if (dict->HasKey(\"6\")) {\n              const base::Value* inner_message_value;\n              if (!dict->Get(\"6\", &inner_message_value)) {\n                goto error;\n              }\n              if (!dom_distiller::test_sample::proto::json::TypeTest::Message::ReadFromValue(inner_message_value, message->mutable_message_value())) {\n                goto error;\n              }\n            }\n            return true;\n\n          error:\n            return false;\n          }\n\n          static std::unique_ptr<base::DictionaryValue> WriteToValue(const dom_distiller::test_sample::proto::TypeTest& message) {\n            std::unique_ptr<base::DictionaryValue> dict(new base::DictionaryValue());\n            if (message.has_float_value()) {\n              dict->SetDouble(\"1\", message.float_value());\n            }\n            if (message.has_double_value()) {\n              dict->SetDouble(\"2\", message.double_value());\n            }\n            if (message.has_int32_value()) {\n              dict->SetInteger(\"3\", message.int32_value());\n            }\n            if (message.has_bool_value()) {\n              dict->SetBoolean(\"4\", message.bool_value());\n            }\n            if (message.has_string_value()) {\n              dict->SetString(\"5\", message.string_value());\n            }\n            if (message.has_message_value()) {\n              std::unique_ptr<base::Value> inner_message_value =\n                  dom_distiller::test_sample::proto::json::TypeTest::Message::WriteToValue(message.message_value());\n              dict->Set(\"6\", std::move(inner_message_value));\n            }\n            return dict;\n          }\n        };\n\n        class Repeated {\n         public:\n          class Message {\n           public:\n            static bool ReadFromValue(const base::Value* json, dom_distiller::test_sample::proto::Repeated::Message* message) {\n              const base::DictionaryValue* dict;\n              if (!json->GetAsDictionary(&dict)) goto error;\n              if (dict->HasKey(\"1\")) {\n                const base::ListValue* field_list;\n                if (!dict->GetList(\"1\", &field_list)) {\n                  goto error;\n                }\n                for (size_t i = 0; i < field_list->GetSize(); ++i) {\n                  bool field_value;\n                  if (!field_list->GetBoolean(i, &field_value)) {\n                    goto error;\n                  }\n                  message->add_dummy(field_value);\n                }\n              }\n              return true;\n\n            error:\n              return false;\n            }\n\n            static std::unique_ptr<base::DictionaryValue> WriteToValue(const dom_distiller::test_sample::proto::Repeated::Message& message) {\n              std::unique_ptr<base::DictionaryValue> dict(new base::DictionaryValue());\n              {\n                base::ListValue* field_list = new base::ListValue();\n                dict->Set(\"1\", field_list);\n                for (int i = 0; i < message.dummy_size(); ++i) {\n                  field_list->AppendBoolean(message.dummy(i));\n                }\n              }\n              return dict;\n            }\n          };\n\n          static bool ReadFromValue(const base::Value* json, dom_distiller::test_sample::proto::Repeated* message) {\n            const base::DictionaryValue* dict;\n            if (!json->GetAsDictionary(&dict)) goto error;\n            if (dict->HasKey(\"1\")) {\n              const base::ListValue* field_list;\n              if (!dict->GetList(\"1\", &field_list)) {\n                goto error;\n              }\n              for (size_t i = 0; i < field_list->GetSize(); ++i) {\n                float field_value;\n                if (!field_list->GetDouble(i, &field_value)) {\n                  goto error;\n                }\n                message->add_float_value(field_value);\n              }\n            }\n            if (dict->HasKey(\"2\")) {\n              const base::ListValue* field_list;\n              if (!dict->GetList(\"2\", &field_list)) {\n                goto error;\n              }\n              for (size_t i = 0; i < field_list->GetSize(); ++i) {\n                double field_value;\n                if (!field_list->GetDouble(i, &field_value)) {\n                  goto error;\n                }\n                message->add_double_value(field_value);\n              }\n            }\n            if (dict->HasKey(\"3\")) {\n              const base::ListValue* field_list;\n              if (!dict->GetList(\"3\", &field_list)) {\n                goto error;\n              }\n              for (size_t i = 0; i < field_list->GetSize(); ++i) {\n                int field_value;\n                if (!field_list->GetInteger(i, &field_value)) {\n                  goto error;\n                }\n                message->add_int32_value(field_value);\n              }\n            }\n            if (dict->HasKey(\"4\")) {\n              const base::ListValue* field_list;\n              if (!dict->GetList(\"4\", &field_list)) {\n                goto error;\n              }\n              for (size_t i = 0; i < field_list->GetSize(); ++i) {\n                bool field_value;\n                if (!field_list->GetBoolean(i, &field_value)) {\n                  goto error;\n                }\n                message->add_bool_value(field_value);\n              }\n            }\n            if (dict->HasKey(\"5\")) {\n              const base::ListValue* field_list;\n              if (!dict->GetList(\"5\", &field_list)) {\n                goto error;\n              }\n              for (size_t i = 0; i < field_list->GetSize(); ++i) {\n                std::string field_value;\n                if (!field_list->GetString(i, &field_value)) {\n                  goto error;\n                }\n                message->add_string_value(field_value);\n              }\n            }\n            if (dict->HasKey(\"6\")) {\n              const base::ListValue* field_list;\n              if (!dict->GetList(\"6\", &field_list)) {\n                goto error;\n              }\n              for (size_t i = 0; i < field_list->GetSize(); ++i) {\n                const base::Value* inner_message_value;\n                if (!field_list->Get(i, &inner_message_value)) {\n                  goto error;\n                }\n                if (!dom_distiller::test_sample::proto::json::Repeated::Message::ReadFromValue(inner_message_value, message->add_message_value())) {\n                  goto error;\n                }\n              }\n            }\n            return true;\n\n          error:\n            return false;\n          }\n\n          static std::unique_ptr<base::DictionaryValue> WriteToValue(const dom_distiller::test_sample::proto::Repeated& message) {\n            std::unique_ptr<base::DictionaryValue> dict(new base::DictionaryValue());\n            {\n              base::ListValue* field_list = new base::ListValue();\n              dict->Set(\"1\", field_list);\n              for (int i = 0; i < message.float_value_size(); ++i) {\n                field_list->AppendDouble(message.float_value(i));\n              }\n            }\n            {\n              base::ListValue* field_list = new base::ListValue();\n              dict->Set(\"2\", field_list);\n              for (int i = 0; i < message.double_value_size(); ++i) {\n                field_list->AppendDouble(message.double_value(i));\n              }\n            }\n            {\n              base::ListValue* field_list = new base::ListValue();\n              dict->Set(\"3\", field_list);\n              for (int i = 0; i < message.int32_value_size(); ++i) {\n                field_list->AppendInteger(message.int32_value(i));\n              }\n            }\n            {\n              base::ListValue* field_list = new base::ListValue();\n              dict->Set(\"4\", field_list);\n              for (int i = 0; i < message.bool_value_size(); ++i) {\n                field_list->AppendBoolean(message.bool_value(i));\n              }\n            }\n            {\n              base::ListValue* field_list = new base::ListValue();\n              dict->Set(\"5\", field_list);\n              for (int i = 0; i < message.string_value_size(); ++i) {\n                field_list->AppendString(message.string_value(i));\n              }\n            }\n            {\n              base::ListValue* field_list = new base::ListValue();\n              dict->Set(\"6\", field_list);\n              for (int i = 0; i < message.message_value_size(); ++i) {\n                std::unique_ptr<base::Value> inner_message_value =\n                    dom_distiller::test_sample::proto::json::Repeated::Message::WriteToValue(message.message_value(i));\n                field_list->Append(std::move(inner_message_value));\n              }\n            }\n            return dict;\n          }\n        };\n\n      }\n    }\n  }\n}\n
Protoc has returned non-zero status: 1 .
[4387/8151] CXX obj/third_party/crashpad/crashpad/util/util/thread.obj
ninja: build stopped: subcommand failed.

Comment 3 by w...@chromium.org, Mar 20 2017

Cc: wkorman@chromium.org
Labels: Build-Toolchain Needs-Feedback M-59
Status: Assigned (was: Unconfirmed)
wkorman: I'm not able to repro this with Win10 building using the VS2015 toolchain that we have as the default right now - you mention having both VS2015 and VS2017 - which are you building with?
Sanity check: This is a clean build w/out any patches, right? :)

When I switched linker warnings to being fatal I recall one of these linker-performance warnings was actually not a proper warning, just an output message - in your output I see the /INCREMENTAL vs /LTCG is a proper numbered warning, so perhaps something is different in the 2017 toolchain?
Yes, clean build, no patches, running entirely as external non-Googler, so no goma, and with DEPOT_TOOLS_WIN_TOOLCHAIN=0 per note at https://chromium.googlesource.com/chromium/src/+/master/docs/windows_build_instructions.md

I installed VS2017 first, and didn't see initially that it has (apparently) a way to add the VS 2015 compiler toolchain. I thought VS2017 might just work out of the box, but I hit the VS error noted in  http://crbug.com/702697  so then I also separately subsequently installed VS2015. Both are Community Edition.

Next I hit the no-cdb.exe part of  http://crbug.com/702697  and ended up installing the full WDK.

When you say VS2015 toolchain as default, are you using the Google-internal one? Can you try with the local install and DEPOT_TOOLS_WIN_TOOLCHAIN=0? If that still doesn't do it we either need to try on a clean Windows VM/install or try diffing my installed packages, versions, etc. with yours.
uuid.lib should be coming from the Platform SDK. Can you look in this directory to see if the file matches the version that I have:

>dir "C:\Program Files (x86)\Windows Kits\10\Lib\10.0.14393.0\um\x86\Uuid.Lib"
 Volume in drive C has no label.
 Volume Serial Number is 18D4-8BE5

 Directory of C:\Program Files (x86)\Windows Kits\10\Lib\10.0.14393.0\um\x86

01/05/2017  10:29 PM         8,228,184 Uuid.Lib
               1 File(s)      8,228,184 bytes

You might try using procmon or some similar tool/technique to see if this is version of Uuid.lib that is actually getting pulled in. It appears that for some reason some people are getting an odd version of this file.

I have done builds both with the installed version of VS 2015 and the depot tools toolchain and I never hit this error. It is likely that the difference is something in Uuid.lib. That file should not be built with /GL, but it appears that it was.

You could also try this:

    C:\Program Files (x86)\Windows Kits\10\Lib>dir uuid.lib /s

On my machine this shows me four different versions of uuid.lib, all with similar sizes, for arm, arm64, x86, and x64.

On another test machine I find 12 copies of uuid.lib, from three different Windows 10 SDK versions. All are in the ~8.2 to ~9.4 MB range. Building base on this machine with these gn args:

is_debug = true
is_component_build = true
enable_nacl = false

worked without any warnings. This is with VS 2015 Community Edition.

It continues to look like an odd-ball uuid.lib is the problem, and this problem does not easily reproduce - or at least I cannot reproduce it.

I have three version dirs under Lib\, see below. Probably from my multiple attempts to install the WDK. I tried three different approaches, one via VS 2017 and two via downloads from MS site. There were various instructions I found while attempting to find cdb.exe, some said to use full Windows device driver kit setup but custom-choose only the needed items, another said to download Windows SDK 10.0, another said WDK (which is maybe the same as one of the previous), I forget exact detail unfortunately.

If you'd like I can probably reconstruct more of what I did from my browser history, just let me know.

 Directory of C:\Program Files (x86)\Windows Kits\10\Lib

03/19/2017  03:40 PM    <DIR>          .
03/19/2017  03:40 PM    <DIR>          ..
03/19/2017  02:12 PM    <DIR>          10.0.10150.0
03/19/2017  02:13 PM    <DIR>          10.0.10240.0
03/19/2017  03:40 PM    <DIR>          10.0.14393.0
03/19/2017  03:40 PM    <DIR>          wdf
03/19/2017  03:40 PM    <DIR>          win7
03/19/2017  03:40 PM    <DIR>          win8
03/19/2017  03:40 PM    <DIR>          winv6.3

In my downloads directory I see wdksetup.exe @ 3:14pm and tooltip shows version info as 10.0.14393.0.
And SDKSETUP.EXE @ 3:17pm with tooltip version as 10.0.14393.33.

Only one of those dirs contains the uuid.lib files though, listing details below.

Walter Korman@DESKTOP-93T44S5 /cygdrive/c/Program Files (x86)/Windows Kits/10/Lib
$ find . -name "uuid.lib" | xargs ls -la
-rwxr-x---+ 1 SYSTEM SYSTEM 8829332 Jul 15  2016 ./10.0.14393.0/um/arm/uuid.lib
-rwxr-x---+ 1 SYSTEM SYSTEM 9072118 Jul 15  2016 ./10.0.14393.0/um/arm64/uuid.lib
-rwxr-x---+ 1 SYSTEM SYSTEM 8345028 Jul 15  2016 ./10.0.14393.0/um/x64/uuid.lib
-rwxr-x---+ 1 SYSTEM SYSTEM 8072200 Jul 15  2016 ./10.0.14393.0/um/x86/uuid.lib

C:\Program Files (x86)\Windows Kits\10\Lib>dir uuid.lib /s
 Volume in drive C has no label.
 Volume Serial Number is DAAE-8AEB

 Directory of C:\Program Files (x86)\Windows Kits\10\Lib\10.0.14393.0\um\arm

07/15/2016  05:52 PM         8,829,332 uuid.lib
               1 File(s)      8,829,332 bytes

 Directory of C:\Program Files (x86)\Windows Kits\10\Lib\10.0.14393.0\um\arm64

07/15/2016  05:36 PM         9,072,118 uuid.lib
               1 File(s)      9,072,118 bytes

 Directory of C:\Program Files (x86)\Windows Kits\10\Lib\10.0.14393.0\um\x64

07/15/2016  06:40 PM         8,345,028 uuid.lib
               1 File(s)      8,345,028 bytes

 Directory of C:\Program Files (x86)\Windows Kits\10\Lib\10.0.14393.0\um\x86

07/15/2016  05:58 PM         8,072,200 uuid.lib
               1 File(s)      8,072,200 bytes

     Total Files Listed:
               4 File(s)     34,318,678 bytes
               0 Dir(s)  806,029,705,216 bytes free
SDKSETUP.EXE came from the link at bottom of https://developer.microsoft.com/en-us/windows/hardware/windows-driver-kit where link text says "Get Debugging Tools for Windows (WinDbg) (from the SDK)". I think I saw this described in either chromium message group, or chromium site docs, as the way to get the right installer to get cdb.exe.

wdksetup.exe must have come from the download link in step 2 in that page.

I think I tried wdksetup.exe first, then SDKSETUP. Oh, and then I switched to a different downloads dir, where I see:

wdksetup.exe @ 3:14pm

and dirs as:

WDK @ 3:39pm (which contains sdksetup.exe @ 3:17pm, note lowercase here in contrast to other refs)
Win10SDK @ 3:19pm

Anyway, archaeology, but maybe it will help in figuring out why I have a strange version.

Here's md5 of my x64 uuid.lib in case helpful:

$ md5sum.exe ./10.0.14393.0/um/x64/uuid.lib
8986ddea9782db261e63b7fad378108a *./10.0.14393.0/um/x64/uuid.lib

So, reviewing the above, my x64 uuid.lib has different file size than yours, and is dated Jul 2016 rather than Jan 2017.

Maybe there are different SDKSETUP.EXE binaries that both install as 10.0.14393.0 (.0 vs .33) but actually put in place different files?

Hmm, I just did a 'git branch' and see:

D:\chromium\src>git branch
* (HEAD detached from b56e716)
  master

I had done a 'git pull' earlier today aiming to ensure I'm at ToT and attempt repeat of everything. Maybe pull didn't complete successfully. Gah, and now a new error on 'git pull', 'gclient sync', 'ninja -C out\Debug content_shell' below.

D:\chromium\src>ninja -C out\Debug content_shell
ninja: Entering directory `out\Debug'
[1/1] Regenerating ninja files
FAILED: build.ninja
D:/chromium/src/buildtools/win/gn.exe --root=D:/chromium/src -q gen .
WARNING Could not find python on path, using just "python.exe"
ERROR at //build_overrides/build.gni:58:13: Could not execute python.
  _result = exec_script("//build/mac/should_use_hermetic_xcode.py",
            ^----------
I was trying to execute "python.exe".
See //build/toolchain/toolchain.gni:8:1: whence it was imported.
import("//build_overrides/build.gni")
^-----------------------------------
See //build/config/sanitizers/sanitizers.gni:6:1: whence it was imported.
import("//build/toolchain/toolchain.gni")
^---------------------------------------
See //build/config/compiler/compiler.gni:9:1: whence it was imported.
import("//build/config/sanitizers/sanitizers.gni")
^------------------------------------------------
See //BUILD.gn:11:1: whence it was imported.
import("//build/config/compiler/compiler.gni")
^--------------------------------------------
ninja: error: rebuilding 'build.ninja': subcommand failed
Microsoft has complicated this issue by releasing multiple versions of the 10.0.14393.0 SDK. Yes, that is correct. They have updated the SDK one or more times without changing the version numbers, so there is no clear way to tell what version you *really* have. I installed VS 2017 which is apparently the latest time that these files were updated. The old x86/x64 versions are:

 Directory of ...\Lib\10.0.14393.0\um\x64
12/08/2016  11:25 AM         8,298,964 Uuid.Lib

 Directory of ...\Lib\10.0.14393.0\um\x86
12/08/2016  11:25 AM         8,228,184 Uuid.Lib


These are the new versions that came with VS 2017:

 Directory of ...\Lib\10.0.14393.0\um\x64
03/21/2017  10:54 AM         8,298,964 Uuid.Lib

 Directory of ...\Lib\10.0.14393.0\um\x86
03/21/2017  10:54 AM         8,228,184 Uuid.Lib


Same size, but the files have changed (I did a binary compare).

Okay, last bit of data and then I think you'll need to figure this out on your own since I can't repro it. Microsoft may also have ideas on how to investigate, especially if it is (as seems possible) their bug. You could also try small-scale experiments - link with uuid.lib (you need to have references to symbols in it for this to be meaningful) to see if you get the warning.

Consider this setup:
>type file1.cpp
extern void DoNothing();
int main(int argc, char* argv[]) {
  DoNothing();
  return 0;
}

>type file2.cpp
void DoNothing() {
}

>cl /c file1.cpp
Microsoft (R) C/C++ Optimizing Compiler Version 19.00.24213.1 for x86
Copyright (C) Microsoft Corporation.  All rights reserved.

file1.cpp

>cl /c /GL file2.cpp
Microsoft (R) C/C++ Optimizing Compiler Version 19.00.24213.1 for x86
Copyright (C) Microsoft Corporation.  All rights reserved.

file2.cpp

>link file1.obj file2.obj
Microsoft (R) Incremental Linker Version 14.00.24213.1
Copyright (C) Microsoft Corporation.  All rights reserved.

file2.obj : MSIL .netmodule or module compiled with /GL found; restarting link with /LTCG; add /LTCG to the link command line to improve linker performance
Microsoft (R) Incremental Linker Version 14.00.24213.1
Copyright (C) Microsoft Corporation.  All rights reserved.

Generating code
Finished generating code



In short, two trivial source files. Compile them both, one with /GL. Then link them. You get the warning. Okay, let's put file2.obj into a library and then link with that:

>lib file2.obj /ltcg /out:file2.lib
Microsoft (R) Library Manager Version 14.00.24213.1
Copyright (C) Microsoft Corporation.  All rights reserved.

>link file2.lib file1.obj
Microsoft (R) Incremental Linker Version 14.00.24213.1
Copyright (C) Microsoft Corporation.  All rights reserved.

file2.lib(file2.obj) : MSIL .netmodule or module compiled with /GL found; restarting link with /LTCG; add /LTCG to the link command line to improve linker performance
Microsoft (R) Incremental Linker Version 14.00.24213.1
Copyright (C) Microsoft Corporation.  All rights reserved.

Generating code
Finished generating code



The warning is totally clear. File2.obj (whether in the library or not) was compiled with /GL. This is inappropriate for a library that is designed to be linked into debug and release binaries. It is a bug in uuid.lib, as present on your machine. You can paper over the problem with "fatal_linker_warnings = false" but that means your builds will be slower. I'm going to chat with wez@ but I think we have to close this as external.

Aside: Microsoft says that the recommended version of 10.0.14393.0 is this one:

https://developer.microsoft.com/en-us/windows/downloads/windows-10-sdk

Creating a limited repro of the problematic uuid.lib and then testing that repro with a clean install of this version seems useful.

Comment 14 by w...@chromium.org, Mar 23 2017

Thanks for the detailed input, Bruce, and for the extra details, wkorman@.

It does seem that this is just a broken uuid.lib, so nothing much we can do here, but if we can identify e.g. does it only affect users with a particular LIBS path in their environment, or identify which uuid.lib is being used and causing problems, that seems useful in helping others who hit this issue.

I wonder if we have had lots of Chromium devs on Windows hitting broken uuid.lib for a while, and just never noticed it before we added /WX...?
> does it only affect users with a particular LIBS path in their environment

That's a good point. Manual inspection of the LIB environment variable might reveal problems. Or procmon monitoring to see where uuid.lib is actually coming from. My guess would be that it is *not* coming from the 10.0.14393.0 SDK.
Thanks indeed for the detailed review. I installed procmon at home the other day but hit some other issue (see my last note above) that caused build to fail ahead of VS toolchain running to allow me to see uuid.lib detail. I'll try again tonight or this weekend.

At minimum it seems worth a FAQ/troubleshooting type of addition to the Windows build notes re: multiple versions of the lib, and which one is recommended.

Better would be to somehow detect if it's the wrong one when building and provide an informative message, but life is filled with dreams. :)

I will follow up with more and in particular if I can't fix my new build failure re: python.exe I'll seek insight from chromium-dev.

Comment 17 by w...@chromium.org, Mar 23 2017

Labels: -Pri-2 -M-59 Pri-3
Owner: wkorman@chromium.org
De-prioritizing since this does is outside the scope of our build/tooling, and assigning to wkorman@ to follow-up on the LIB path and uuid.lib details. Feel free to assign back to me once you have those details - thanks.
Status: WontFix (was: Assigned)
I uninstalled my existing WinSDK, installed the one linked to from chromium.org, did a git pull and sync, and was able to build successfully. So, my WinSDK install though it was the right version number must not have been the right actual binary. Lost in the annals of time now...

Sign in to add a comment