You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying to add the lib glm as an external repository but Bazel gives me undeclared inclusion error but if I build it separetly ( in an other workspace) with the same build script it works.
Bugs: what's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.
bazel build @glmExt//:glm --verbose_failures --sandbox_debug
ERROR: C:/users/...../external/glmExt/BUILD.bazel:121:1: undeclared inclusion(s) in rule '@glmExt//:glm':
this rule is missing dependency declarations for the following files included by 'external/glmExt/glm/detail/glm.cpp':
'external/glmext/glm/detail/_fixes.hpp'
'external/glmext/glm/detail/setup.hpp'
'external/glmext/glm/simd/platform.h'
'external/glmext/glm/fwd.hpp'
'external/glmext/glm/detail/setup.hpp'
'external/glmext/glm/detail/type_int.hpp'
'external/glmext/glm/detail/setup.hpp'
'external/glmext/glm/detail/type_float.hpp'
...
I just updated bazel to 0.15.0 and it still doesn't work ( aka, it was not working in 0.14.0)
Have you found anything relevant by searching the web?
Nothing really, I would like to know more about the check of the include algorithm but i couldn't find anything. I can only print the result of the glob but I couldn't find a way to ask bazel what it actually has for its hdrs, srcs,...
Any other information, logs, or outputs that you want to share?
I found the culprit is case-sensitivity. On Windows file path is case insensitive, so Bazel converts file path to lower case to make path comparison simpler.
But when doing include checking for external repository, we calculate repository name from file path. It doesn't match when the actual repository name contains upper case.
Thanks for reporting this. It's definitely a bug on Windows. You can work around it by renaming glmExt to glmext. We'll try to fix it.
meteorcloudy
changed the title
Bazel give me undeclared inclusion error when the header is specified but only if building the lib as an external.
Windows: Include checking failed when external repository name contains upper case
Jun 29, 2018
Description of the problem / feature request:
I am trying to add the lib glm as an external repository but Bazel gives me undeclared inclusion error but if I build it separetly ( in an other workspace) with the same build script it works.
Bugs: what's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.
My folder structure
glmExtBuild
---- WORKSPACE
---- externals
-------- glm.BUILD
This is my WORKSPACE file
This is my glm.BUILD file
And this is the errors that I get when I run
The working case:
My folder structure
glmBuild2
---- WORKSPACE
---- BUILD
---- glmSrc
-------- https://github.com/g-truc/glm/archive/0.9.9.0.tar.gz extracted here
My WORKSPACE file is empty
And this is my BUILD file
What operating system are you running Bazel on?
windows
What's the output of
bazel info release
?I just updated bazel to 0.15.0 and it still doesn't work ( aka, it was not working in 0.14.0)
Have you found anything relevant by searching the web?
Nothing really, I would like to know more about the check of the include algorithm but i couldn't find anything. I can only print the result of the glob but I couldn't find a way to ask bazel what it actually has for its hdrs, srcs,...
Any other information, logs, or outputs that you want to share?
I asked the question on stackoverflow too but I have no solution for now.
https://stackoverflow.com/questions/51053215/why-do-i-get-undeclared-inclusion-error-when-using-the-lib-as-external-library
The text was updated successfully, but these errors were encountered: