Compilation errors src/sksl/generated

37 views
Skip to first unread message

sudo

unread,
Aug 12, 2022, 4:18:26 PMAug 12
to skia-discuss
Hello!

I run the following commands:

cd skia
python3 tools/git-sync-deps
gn gen out/Static
ninja -C out/Static

Using Windows and compiling with msvc, tried clang-cl as well but same errors.

ninja: Entering directory `out/Static'
[926/3642] compile ../../src/sksl/SkSLCompiler.cpp
FAILED: obj/src/sksl/skia.SkSLCompiler.obj
"C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC/Tools/MSVC/14.29.30133/bin/HostX64/x64/cl.exe" /nologo /showIncludes /FC -DSK_HAS_ANDROID_CODEC -DSKSL_ENABLE_TRACING -DSK_ENABLE_SPIRV_VALIDATION -D_CRT_SECURE_NO_WARNINGS -D_HAS_EXCEPTIONS=0 -DWIN32_LEAN_AND_MEAN -DNOMINMAX -DSK_ENABLE_SKSL -DSK_ENABLE_PRECOMPILE -DSK_GAMMA_APPLY_TO_A8 -DSK_ALLOW_STATIC_GLOBAL_INITIALIZERS=1 -DGR_TEST_UTILS=1 -DSKIA_IMPLEMENTATION=1 -DSK_GL -DSK_ENABLE_DUMP_GPU -DSK_SUPPORT_GPU=1 -DSK_SUPPORT_PDF -DSK_CODEC_DECODES_JPEG -DSK_ENCODE_JPEG -DSK_SUPPORT_XPS -DSK_ENABLE_ANDROID_UTILS -DSK_USE_LIBGIFCODEC -DSK_HAS_HEIF_LIBRARY -DSK_CODEC_DECODES_PNG -DSK_ENCODE_PNG -DSKVM_JIT_WHEN_POSSIBLE -DSK_CODEC_DECODES_WEBP -DSK_ENCODE_WEBP -DSK_XML "-IC:/Program Files (x86)/Microsoft Visual Studio/2019/Community/VC/Tools/MSVC/14.29.30133/include" "-IC:/Program Files (x86)/Windows Kits/10/Include/10.0.19041.0/shared" "-IC:/Program Files (x86)/Windows Kits/10/Include/10.0.19041.0/ucrt" "-IC:/Program Files (x86)/Windows Kits/10/Include/10.0.19041.0/um" "-IC:/Program Files (x86)/Windows Kits/10/Include/10.0.19041.0/winrt" -I../.. -I../.. -I../../third_party/externals/libgifcodec -I../../third_party/externals/spirv-tools/include /wd5030 /bigobj /utf-8 /Z7 /W3 /wd4244 /wd4267 /wd4800 /wd4291 /wd4251 /wd4275 /wd5041  /std:c++17 /GR- /c ../../src/sksl/SkSLCompiler.cpp /Foobj/src/sksl/skia.SkSLCompiler.obj /Fd"obj/skia_c.pdb"
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(1): error C2737: 'SKSL_INCLUDE_C': constexpr object must be initialized
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(1): error C2737: 'SKSL_INCLUDE_C': constexpr object must be initialized
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(1): error C2143: syntax error: missing ';' before ':'
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(1): error C2059: syntax error: ':'
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(1): error C2059: syntax error: '/'
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(1): error C2143: syntax error: missing ';' before '{'
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(1): error C2447: '{': missing function header (old-style formal list?)
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(2526): error C2737: 'SKSL_INCLUDE_C': constexpr object must be initialized
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(2526): error C2371: 'SKSL_INCLUDE_C': redefinition; different basic types
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(1): note: see declaration of 'SKSL_INCLUDE_C'
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(2526): error C2143: syntax error: missing ';' before ':'
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(2526): error C2059: syntax error: ':'
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(2526): error C2059: syntax error: '/'
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(2526): error C2059: syntax error: '/'
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(2526): error C2059: syntax error: ')'
C:\skia\src\sksl\generated\sksl_compute.dehydrated.sksl(1): error C2737: 'SKSL_INCLUDE_C': constexpr object must be initialized
C:\skia\src\sksl\generated\sksl_compute.dehydrated.sksl(1): error C2086: 'const uint8_t SKSL_INCLUDE_C': redefinition
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(1): note: see declaration of 'SKSL_INCLUDE_C'
C:\skia\src\sksl\generated\sksl_compute.dehydrated.sksl(1): error C2143: syntax error: missing ';' before ':'
C:\skia\src\sksl\generated\sksl_compute.dehydrated.sksl(1): error C2059: syntax error: ':'
C:\skia\src\sksl\generated\sksl_compute.dehydrated.sksl(1): error C2059: syntax error: '/'
C:\skia\src\sksl\generated\sksl_compute.dehydrated.sksl(1): error C2143: syntax error: missing ';' before '{'
C:\skia\src\sksl\generated\sksl_compute.dehydrated.sksl(1): error C2447: '{': missing function header (old-style formal list?)
C:\skia\src\sksl\generated\sksl_compute.dehydrated.sksl(80): error C2737: 'SKSL_INCLUDE_C': constexpr object must be initialized
C:\skia\src\sksl\generated\sksl_compute.dehydrated.sksl(80): error C2371: 'SKSL_INCLUDE_C': redefinition; different basic types
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(1): note: see declaration of 'SKSL_INCLUDE_C'
C:\skia\src\sksl\generated\sksl_compute.dehydrated.sksl(80): error C2143: syntax error: missing ';' before ':'
C:\skia\src\sksl\generated\sksl_compute.dehydrated.sksl(80): error C2059: syntax error: ':'
C:\skia\src\sksl\generated\sksl_compute.dehydrated.sksl(80): error C2059: syntax error: '/'
C:\skia\src\sksl\generated\sksl_compute.dehydrated.sksl(80): error C2059: syntax error: '/'
C:\skia\src\sksl\generated\sksl_compute.dehydrated.sksl(80): error C2059: syntax error: ')'
C:\skia\src\sksl\generated\sksl_frag.dehydrated.sksl(1): error C2737: 'SKSL_INCLUDE_C': constexpr object must be initialized
C:\skia\src\sksl\generated\sksl_frag.dehydrated.sksl(1): error C2086: 'const uint8_t SKSL_INCLUDE_C': redefinition
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(1): note: see declaration of 'SKSL_INCLUDE_C'
C:\skia\src\sksl\generated\sksl_frag.dehydrated.sksl(1): error C2143: syntax error: missing ';' before ':'
C:\skia\src\sksl\generated\sksl_frag.dehydrated.sksl(1): error C2059: syntax error: ':'
C:\skia\src\sksl\generated\sksl_frag.dehydrated.sksl(1): error C2059: syntax error: '/'
C:\skia\src\sksl\generated\sksl_frag.dehydrated.sksl(1): error C2143: syntax error: missing ';' before '{'
C:\skia\src\sksl\generated\sksl_frag.dehydrated.sksl(1): error C2447: '{': missing function header (old-style formal list?)
C:\skia\src\sksl\generated\sksl_frag.dehydrated.sksl(58): error C2737: 'SKSL_INCLUDE_C': constexpr object must be initialized
C:\skia\src\sksl\generated\sksl_frag.dehydrated.sksl(58): error C2371: 'SKSL_INCLUDE_C': redefinition; different basic types
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(1): note: see declaration of 'SKSL_INCLUDE_C'
C:\skia\src\sksl\generated\sksl_frag.dehydrated.sksl(58): error C2143: syntax error: missing ';' before ':'
C:\skia\src\sksl\generated\sksl_frag.dehydrated.sksl(58): error C2059: syntax error: ':'
C:\skia\src\sksl\generated\sksl_frag.dehydrated.sksl(58): error C2059: syntax error: '/'
C:\skia\src\sksl\generated\sksl_frag.dehydrated.sksl(58): error C2059: syntax error: '/'
C:\skia\src\sksl\generated\sksl_frag.dehydrated.sksl(58): error C2059: syntax error: ')'
C:\skia\src\sksl\generated\sksl_gpu.dehydrated.sksl(1): error C2737: 'SKSL_INCLUDE_C': constexpr object must be initialized
C:\skia\src\sksl\generated\sksl_gpu.dehydrated.sksl(1): error C2086: 'const uint8_t SKSL_INCLUDE_C': redefinition
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(1): note: see declaration of 'SKSL_INCLUDE_C'
C:\skia\src\sksl\generated\sksl_gpu.dehydrated.sksl(1): error C2143: syntax error: missing ';' before ':'
C:\skia\src\sksl\generated\sksl_gpu.dehydrated.sksl(1): error C2059: syntax error: ':'
C:\skia\src\sksl\generated\sksl_gpu.dehydrated.sksl(1): error C2059: syntax error: '/'
C:\skia\src\sksl\generated\sksl_gpu.dehydrated.sksl(1): error C2143: syntax error: missing ';' before '{'
C:\skia\src\sksl\generated\sksl_gpu.dehydrated.sksl(1): error C2447: '{': missing function header (old-style formal list?)
C:\skia\src\sksl\generated\sksl_gpu.dehydrated.sksl(2753): error C2737: 'SKSL_INCLUDE_C': constexpr object must be initialized
C:\skia\src\sksl\generated\sksl_gpu.dehydrated.sksl(2753): error C2371: 'SKSL_INCLUDE_C': redefinition; different basic types
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(1): note: see declaration of 'SKSL_INCLUDE_C'
C:\skia\src\sksl\generated\sksl_gpu.dehydrated.sksl(2753): error C2143: syntax error: missing ';' before ':'
C:\skia\src\sksl\generated\sksl_gpu.dehydrated.sksl(2753): error C2059: syntax error: ':'
C:\skia\src\sksl\generated\sksl_gpu.dehydrated.sksl(2753): error C2059: syntax error: '/'
C:\skia\src\sksl\generated\sksl_gpu.dehydrated.sksl(2753): error C2059: syntax error: '/'
C:\skia\src\sksl\generated\sksl_gpu.dehydrated.sksl(2753): error C2059: syntax error: ')'
C:\skia\src\sksl\generated\sksl_public.dehydrated.sksl(1): error C2737: 'SKSL_INCLUDE_C': constexpr object must be initialized
C:\skia\src\sksl\generated\sksl_public.dehydrated.sksl(1): error C2086: 'const uint8_t SKSL_INCLUDE_C': redefinition
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(1): note: see declaration of 'SKSL_INCLUDE_C'
C:\skia\src\sksl\generated\sksl_public.dehydrated.sksl(1): error C2143: syntax error: missing ';' before ':'
C:\skia\src\sksl\generated\sksl_public.dehydrated.sksl(1): error C2059: syntax error: ':'
C:\skia\src\sksl\generated\sksl_public.dehydrated.sksl(1): error C2059: syntax error: '/'
C:\skia\src\sksl\generated\sksl_public.dehydrated.sksl(1): error C2143: syntax error: missing ';' before '{'
C:\skia\src\sksl\generated\sksl_public.dehydrated.sksl(1): error C2447: '{': missing function header (old-style formal list?)
C:\skia\src\sksl\generated\sksl_public.dehydrated.sksl(76): error C2737: 'SKSL_INCLUDE_C': constexpr object must be initialized
C:\skia\src\sksl\generated\sksl_public.dehydrated.sksl(76): error C2371: 'SKSL_INCLUDE_C': redefinition; different basic types
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(1): note: see declaration of 'SKSL_INCLUDE_C'
C:\skia\src\sksl\generated\sksl_public.dehydrated.sksl(76): error C2143: syntax error: missing ';' before ':'
C:\skia\src\sksl\generated\sksl_public.dehydrated.sksl(76): error C2059: syntax error: ':'
C:\skia\src\sksl\generated\sksl_public.dehydrated.sksl(76): error C2059: syntax error: '/'
C:\skia\src\sksl\generated\sksl_public.dehydrated.sksl(76): error C2059: syntax error: '/'
C:\skia\src\sksl\generated\sksl_public.dehydrated.sksl(76): error C2059: syntax error: ')'
C:\skia\src\sksl\generated\sksl_rt_shader.dehydrated.sksl(1): error C2737: 'SKSL_INCLUDE_C': constexpr object must be initialized
C:\skia\src\sksl\generated\sksl_rt_shader.dehydrated.sksl(1): error C2086: 'const uint8_t SKSL_INCLUDE_C': redefinition
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(1): note: see declaration of 'SKSL_INCLUDE_C'
C:\skia\src\sksl\generated\sksl_rt_shader.dehydrated.sksl(1): error C2143: syntax error: missing ';' before ':'
C:\skia\src\sksl\generated\sksl_rt_shader.dehydrated.sksl(1): error C2059: syntax error: ':'
C:\skia\src\sksl\generated\sksl_rt_shader.dehydrated.sksl(1): error C2059: syntax error: '/'
C:\skia\src\sksl\generated\sksl_rt_shader.dehydrated.sksl(1): error C2143: syntax error: missing ';' before '{'
C:\skia\src\sksl\generated\sksl_rt_shader.dehydrated.sksl(1): error C2447: '{': missing function header (old-style formal list?)
C:\skia\src\sksl\generated\sksl_rt_shader.dehydrated.sksl(16): error C2737: 'SKSL_INCLUDE_C': constexpr object must be initialized
C:\skia\src\sksl\generated\sksl_rt_shader.dehydrated.sksl(16): error C2371: 'SKSL_INCLUDE_C': redefinition; different basic types
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(1): note: see declaration of 'SKSL_INCLUDE_C'
C:\skia\src\sksl\generated\sksl_rt_shader.dehydrated.sksl(16): error C2143: syntax error: missing ';' before ':'
C:\skia\src\sksl\generated\sksl_rt_shader.dehydrated.sksl(16): error C2059: syntax error: ':'
C:\skia\src\sksl\generated\sksl_rt_shader.dehydrated.sksl(16): error C2059: syntax error: '/'
C:\skia\src\sksl\generated\sksl_rt_shader.dehydrated.sksl(16): error C2059: syntax error: '/'
C:\skia\src\sksl\generated\sksl_rt_shader.dehydrated.sksl(16): error C2059: syntax error: ')'
C:\skia\src\sksl\generated\sksl_vert.dehydrated.sksl(1): error C2737: 'SKSL_INCLUDE_C': constexpr object must be initialized
C:\skia\src\sksl\generated\sksl_vert.dehydrated.sksl(1): error C2086: 'const uint8_t SKSL_INCLUDE_C': redefinition
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(1): note: see declaration of 'SKSL_INCLUDE_C'
C:\skia\src\sksl\generated\sksl_vert.dehydrated.sksl(1): error C2143: syntax error: missing ';' before ':'
C:\skia\src\sksl\generated\sksl_vert.dehydrated.sksl(1): error C2059: syntax error: ':'
C:\skia\src\sksl\generated\sksl_vert.dehydrated.sksl(1): error C2059: syntax error: '/'
C:\skia\src\sksl\generated\sksl_vert.dehydrated.sksl(1): error C2143: syntax error: missing ';' before '{'
C:\skia\src\sksl\generated\sksl_vert.dehydrated.sksl(1): error C2447: '{': missing function header (old-style formal list?)
C:\skia\src\sksl\generated\sksl_vert.dehydrated.sksl(48): error C2737: 'SKSL_INCLUDE_C': constexpr object must be initialized
C:\skia\src\sksl\generated\sksl_vert.dehydrated.sksl(48): error C2371: 'SKSL_INCLUDE_C': redefinition; different basic types
C:\skia\src\sksl\generated\sksl_shared.dehydrated.sksl(1): note: see declaration of 'SKSL_INCLUDE_C'
C:\skia\src\sksl\generated\sksl_vert.dehydrated.sksl(48): error C2143: syntax error: missing ';' before ':'
C:\skia\src\sksl\generated\sksl_vert.dehydrated.sksl(48): error C2059: syntax error: ':'
C:\skia\src\sksl\generated\sksl_vert.dehydrated.sksl(48): error C2059: syntax error: '/'
C:\skia\src\sksl\generated\sksl_vert.dehydrated.sksl(48): error C2059: syntax error: '/'
C:\skia\src\sksl\generated\sksl_vert.dehydrated.sksl(48): error C2059: syntax error: ')'
C:\skia\src\sksl\SkSLCompiler.cpp(244): error C2065: 'SKSL_INCLUDE_sksl_shared': undeclared identifier
C:\skia\src\sksl\SkSLCompiler.cpp(244): error C2065: 'SKSL_INCLUDE_sksl_shared_LENGTH': undeclared identifier
C:\skia\src\sksl\SkSLCompiler.cpp(244): error C2660: 'SkSL::Compiler::parseModule': function does not take 2 arguments
C:\skia\src\sksl\SkSLCompiler.cpp(245): fatal error C1003: error count exceeds 100; stopping compilation
[935/3642] compile ../../src/sksl/codegen/SkSLVMCodeGenerator.cpp
ninja: build stopped: subcommand failed.


Brian Osman

unread,
Aug 12, 2022, 5:06:06 PMAug 12
to skia-d...@googlegroups.com
That's strange - some of the symbol names and other characters in your error messages don't actually exist in those files. If you open up one of the files in src/sksl/generated (they're actually C++ source files), do they look correct? For reference, each one should start with a line that declares an array of uint8_t, and then have a big initializer list: https://source.chromium.org/chromium/chromium/src/+/main:third_party/skia/src/sksl/generated/sksl_shared.dehydrated.sksl

From the errors, it almost looks like the preprocessor is somehow replacing part of the declaration of those arrays with something else, but unless you have a header that's doing something like `#define uint8_t`, I'm not sure how that would happen.

--
You received this message because you are subscribed to the Google Groups "skia-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to skia-discuss...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/skia-discuss/c4ba4051-baa0-4456-b04d-d8ebde4b3026n%40googlegroups.com.

sudo

unread,
Aug 13, 2022, 6:17:51 AMAug 13
to skia-discuss
Hmm, I left out a crucial detail in the original post.

This is the actual sequence of commands being run:

cd skia
python3 tools/git-sync-deps
gn gen out/Static --args="skia_compile_modules=true"
*removing out/Static*
gn gen out/Static
ninja -C out/Static

At this point, each file in src/sksl/generated follows a similar pattern:

// from sksl_shared.dehydrated
// line 1
static constexpr uint8_t SKSL_INCLUDE_C:/skia/out/Static/sksl_shared[] = {13,0,200,3,

//last line
static constexpr size_t SKSL_INCLUDE_C:/skia/out/Static/sksl_shared_LENGTH = sizeof(SKSL_INCLUDE_C:/skia/out/Static/sksl_shared);

Now, if I replace all files in src/sksl/generated with clean ones and run only
gn gen out/Static
ninja -C out/Static
it compiles fine and none of the files in src/sksl/generated is modified like above.

Including the output when compiling with clang-cl as well:

ninja: Entering directory `out/Static'
[378/3776] compile ../../modules/skcms/skcms.cc
clang-cl: warning: unknown argument ignored in clang-cl: '-std=c11' [-Wunknown-argument]
[1082/3776] compile ../../src/sksl/SkSLCompiler.cpp
FAILED: obj/src/sksl/skia.SkSLCompiler.obj
"C:/Program Files/LLVM/bin/clang-cl.exe" /nologo /showIncludes /FC -DSK_HAS_ANDROID_CODEC -DSKSL_ENABLE_TRACING -DSK_ENABLE_SPIRV_VALIDATION -D_CRT_SECURE_NO_WARNINGS -D_HAS_EXCEPTIONS=0 -DWIN32_LEAN_AND_MEAN -DNOMINMAX -DSK_ENABLE_SKSL -DSK_ENABLE_PRECOMPILE -DSK_GAMMA_APPLY_TO_A8 -DSK_ALLOW_STATIC_GLOBAL_INITIALIZERS=1 -DGR_TEST_UTILS=1 -DSKIA_IMPLEMENTATION=1 -DSK_GL -DSK_ENABLE_DUMP_GPU -DSK_SUPPORT_GPU=1 -DSK_SUPPORT_PDF -DSK_CODEC_DECODES_JPEG -DSK_ENCODE_JPEG -DSK_SUPPORT_XPS -DSK_ENABLE_ANDROID_UTILS -DSK_USE_LIBGIFCODEC -DSK_HAS_HEIF_LIBRARY -DSK_CODEC_DECODES_PNG -DSK_ENCODE_PNG -DSKVM_JIT_WHEN_POSSIBLE -DSK_CODEC_DECODES_WEBP -DSK_ENCODE_WEBP -DSK_XML -I../.. -I../.. -I../../third_party/externals/libgifcodec -I../../third_party/externals/spirv-tools/include -Wno-attributes /bigobj /utf-8 -imsvc "C:\Program Files (x86)\Microsoft Visual Studio\2019\Community\VC/Tools/MSVC/14.29.30133/include" -imsvc "C:/Program Files (x86)/Windows Kits/10/Include/10.0.19041.0/shared" -imsvc "C:/Program Files (x86)/Windows Kits/10/Include/10.0.19041.0/ucrt" -imsvc "C:/Program Files (x86)/Windows Kits/10/Include/10.0.19041.0/um" -imsvc "C:/Program Files (x86)/Windows Kits/10/Include/10.0.19041.0/winrt" /Z7 -gcodeview-ghash /W3 /wd4244 /wd4267 /wd4800 /wd4291 /wd4251 /wd4275 /wd5041 -Wno-unused-parameter -fcolor-diagnostics -Weverything -Wno-unknown-warning-option -Wno-weak-template-vtables -Wno-nonportable-include-path -Wno-nonportable-system-include-path -Wno-cast-align -Wno-cast-qual -Wno-conversion -Wno-disabled-macro-expansion -Wno-documentation -Wno-documentation-unknown-command -Wno-double-promotion -Wno-exit-time-destructors -Wno-float-equal -Wno-global-constructors -Wno-missing-prototypes -Wno-missing-variable-declarations -Wno-pedantic -Wno-reserved-id-macro -Wno-reserved-identifier -Wno-shift-sign-overflow -Wno-signed-enum-bitfield -Wno-switch-enum -Wno-thread-safety-negative -Wno-undef -Wno-unreachable-code-break -Wno-unreachable-code-return -Wno-unused-macros -Wno-unused-member-function -Wno-non-c-typedef-for-linkage -Wno-covered-switch-default -Wno-deprecated -Wno-missing-noreturn -Wno-old-style-cast -Wno-newline-eof -Wno-padded -Wno-shadow-field-in-constructor -Wno-shadow-uncaptured-local -Wno-zero-as-null-pointer-constant -Wno-declaration-after-statement -Wno-range-loop-analysis -Wrange-loop-construct -Wdeprecated-anon-enum-enum-conversion -Wdeprecated-array-compare -Wdeprecated-attributes -Wdeprecated-comma-subscript -Wdeprecated-copy -Wdeprecated-copy-dtor -Wdeprecated-dynamic-exception-spec -Wdeprecated-enum-compare -Wdeprecated-enum-compare-conditional -Wdeprecated-enum-enum-conversion -Wdeprecated-enum-float-conversion -Wdeprecated-increment-bool -Wdeprecated-register -Wdeprecated-this-capture -Wdeprecated-volatile -Wdeprecated-writable-str  /std:c++17 /GR- -Wno-abstract-vbase-init -Wno-weak-vtables -Wno-c++98-compat -Wno-c++98-compat-pedantic -Wno-undefined-func-template /c ../../src/sksl/SkSLCompiler.cpp /Foobj/src/sksl/skia.SkSLCompiler.obj /Fd"obj/skia_c.pdb"
In file included from ../../src/sksl/SkSLCompiler.cpp:77:
../..\src/sksl/generated/sksl_shared.dehydrated.sksl(1,26): error: default initialization of an object of const type 'const uint8_t' (aka 'const unsigned char')
static constexpr uint8_t SKSL_INCLUDE_C:/skia/out/Static/sksl_shared[] = {13,0,200,3,
                         ^
                                        = '\0'
../..\src/sksl/generated/sksl_shared.dehydrated.sksl(1,40): error: expected ';' after top level declarator
static constexpr uint8_t SKSL_INCLUDE_C:/skia/out/Static/sksl_shared[] = {13,0,200,3,
                                       ^
                                       ;
../..\src/sksl/generated/sksl_shared.dehydrated.sksl(1,41): error: expected unqualified-id
static constexpr uint8_t SKSL_INCLUDE_C:/skia/out/Static/sksl_shared[] = {13,0,200,3,
                                        ^
../..\src/sksl/generated/sksl_shared.dehydrated.sksl(2526,25): error: redefinition of 'SKSL_INCLUDE_C' with a different type: 'const size_t' (aka 'const unsigned long long') vs 'const uint8_t' (aka 'const unsigned char')
static constexpr size_t SKSL_INCLUDE_C:/skia/out/Static/sksl_shared_LENGTH = sizeof(SKSL_INCLUDE_C:/skia/out/Static/sksl_shared);
                        ^
../..\src/sksl/generated/sksl_shared.dehydrated.sksl(1,26): note: previous definition is here
static constexpr uint8_t SKSL_INCLUDE_C:/skia/out/Static/sksl_shared[] = {13,0,200,3,
                         ^
../..\src/sksl/generated/sksl_shared.dehydrated.sksl(2526,39): error: expected ';' after top level declarator
static constexpr size_t SKSL_INCLUDE_C:/skia/out/Static/sksl_shared_LENGTH = sizeof(SKSL_INCLUDE_C:/skia/out/Static/sksl_shared);
                                      ^
                                      ;
../..\src/sksl/generated/sksl_shared.dehydrated.sksl(2526,40): error: expected unqualified-id
static constexpr size_t SKSL_INCLUDE_C:/skia/out/Static/sksl_shared_LENGTH = sizeof(SKSL_INCLUDE_C:/skia/out/Static/sksl_shared);
                                       ^
In file included from ../../src/sksl/SkSLCompiler.cpp:78:
../..\src/sksl/generated/sksl_compute.dehydrated.sksl(1,26): error: redefinition of 'SKSL_INCLUDE_C'
static constexpr uint8_t SKSL_INCLUDE_C:/skia/out/Static/sksl_compute[] = {13,0,111,0,
                         ^
../..\src/sksl/generated/sksl_shared.dehydrated.sksl(1,26): note: previous definition is here
static constexpr uint8_t SKSL_INCLUDE_C:/skia/out/Static/sksl_shared[] = {13,0,200,3,
                         ^
In file included from ../../src/sksl/SkSLCompiler.cpp:78:
../..\src/sksl/generated/sksl_compute.dehydrated.sksl(1,40): error: expected ';' after top level declarator
static constexpr uint8_t SKSL_INCLUDE_C:/skia/out/Static/sksl_compute[] = {13,0,111,0,
                                       ^
                                       ;
../..\src/sksl/generated/sksl_compute.dehydrated.sksl(1,41): error: expected unqualified-id
static constexpr uint8_t SKSL_INCLUDE_C:/skia/out/Static/sksl_compute[] = {13,0,111,0,
                                        ^
../..\src/sksl/generated/sksl_compute.dehydrated.sksl(80,25): error: redefinition of 'SKSL_INCLUDE_C' with a different type: 'const size_t' (aka 'const unsigned long long') vs 'const uint8_t' (aka 'const unsigned char')
static constexpr size_t SKSL_INCLUDE_C:/skia/out/Static/sksl_compute_LENGTH = sizeof(SKSL_INCLUDE_C:/skia/out/Static/sksl_compute);
                        ^
../..\src/sksl/generated/sksl_shared.dehydrated.sksl(1,26): note: previous definition is here
static constexpr uint8_t SKSL_INCLUDE_C:/skia/out/Static/sksl_shared[] = {13,0,200,3,
                         ^
In file included from ../../src/sksl/SkSLCompiler.cpp:78:
../..\src/sksl/generated/sksl_compute.dehydrated.sksl(80,39): error: expected ';' after top level declarator
static constexpr size_t SKSL_INCLUDE_C:/skia/out/Static/sksl_compute_LENGTH = sizeof(SKSL_INCLUDE_C:/skia/out/Static/sksl_compute);
                                      ^
                                      ;
../..\src/sksl/generated/sksl_compute.dehydrated.sksl(80,40): error: expected unqualified-id
static constexpr size_t SKSL_INCLUDE_C:/skia/out/Static/sksl_compute_LENGTH = sizeof(SKSL_INCLUDE_C:/skia/out/Static/sksl_compute);
                                       ^
In file included from ../../src/sksl/SkSLCompiler.cpp:79:
../..\src/sksl/generated/sksl_frag.dehydrated.sksl(1,26): error: redefinition of 'SKSL_INCLUDE_C'
static constexpr uint8_t SKSL_INCLUDE_C:/skia/out/Static/sksl_frag[] = {13,0,96,0,
                         ^
../..\src/sksl/generated/sksl_shared.dehydrated.sksl(1,26): note: previous definition is here
static constexpr uint8_t SKSL_INCLUDE_C:/skia/out/Static/sksl_shared[] = {13,0,200,3,
                         ^
In file included from ../../src/sksl/SkSLCompiler.cpp:79:
../..\src/sksl/generated/sksl_frag.dehydrated.sksl(1,40): error: expected ';' after top level declarator
static constexpr uint8_t SKSL_INCLUDE_C:/skia/out/Static/sksl_frag[] = {13,0,96,0,
                                       ^
                                       ;
../..\src/sksl/generated/sksl_frag.dehydrated.sksl(1,41): error: expected unqualified-id
static constexpr uint8_t SKSL_INCLUDE_C:/skia/out/Static/sksl_frag[] = {13,0,96,0,
                                        ^
../..\src/sksl/generated/sksl_frag.dehydrated.sksl(58,25): error: redefinition of 'SKSL_INCLUDE_C' with a different type: 'const size_t' (aka 'const unsigned long long') vs 'const uint8_t' (aka 'const unsigned char')
static constexpr size_t SKSL_INCLUDE_C:/skia/out/Static/sksl_frag_LENGTH = sizeof(SKSL_INCLUDE_C:/skia/out/Static/sksl_frag);
                        ^
../..\src/sksl/generated/sksl_shared.dehydrated.sksl(1,26): note: previous definition is here
static constexpr uint8_t SKSL_INCLUDE_C:/skia/out/Static/sksl_shared[] = {13,0,200,3,
                         ^
In file included from ../../src/sksl/SkSLCompiler.cpp:79:
../..\src/sksl/generated/sksl_frag.dehydrated.sksl(58,39): error: expected ';' after top level declarator
static constexpr size_t SKSL_INCLUDE_C:/skia/out/Static/sksl_frag_LENGTH = sizeof(SKSL_INCLUDE_C:/skia/out/Static/sksl_frag);
                                      ^
                                      ;
../..\src/sksl/generated/sksl_frag.dehydrated.sksl(58,40): error: expected unqualified-id
static constexpr size_t SKSL_INCLUDE_C:/skia/out/Static/sksl_frag_LENGTH = sizeof(SKSL_INCLUDE_C:/skia/out/Static/sksl_frag);
                                       ^
In file included from ../../src/sksl/SkSLCompiler.cpp:80:
../..\src/sksl/generated/sksl_gpu.dehydrated.sksl(1,26): error: redefinition of 'SKSL_INCLUDE_C'
static constexpr uint8_t SKSL_INCLUDE_C:/skia/out/Static/sksl_gpu[] = {13,0,100,5,
                         ^
../..\src/sksl/generated/sksl_shared.dehydrated.sksl(1,26): note: previous definition is here
static constexpr uint8_t SKSL_INCLUDE_C:/skia/out/Static/sksl_shared[] = {13,0,200,3,
                         ^
fatal error: too many errors emitted, stopping now [-ferror-limit=]
20 errors generated.
[1091/3776] compile ../../src/sksl/SkSLInliner.cpp

ninja: build stopped: subcommand failed.

Brian Osman

unread,
Aug 13, 2022, 9:30:59 AMAug 13
to skia-d...@googlegroups.com
Ah, interesting. This may be a windows issue with the python scripts and/or executable used to generate those .dehydrated files. It's supposed to work, but it's possible that we broke something along the way. Are you modifying the contents of any of the sksl_*.sksl files in src/sksl? If not, you never need to set skia_compile_modules to true. Either way, we'll take a look at this next week, and try to reproduce on a windows machine.

sudo

unread,
Aug 15, 2022, 11:10:41 AMAug 15
to skia-discuss
Alright, and no I'm not modifying any file.

Brian Osman

unread,
Aug 16, 2022, 5:15:57 PMAug 16
to skia-d...@googlegroups.com
As I said - you probably never need to set skia_compile_modules to true, but there was a bug, and it's been fixed: https://skia.googlesource.com/skia/+/6d785ddbfe5ed7987f4cb71844425cf33dce818f

Thanks!

sudo

unread,
Aug 18, 2022, 9:27:30 AMAug 18
to skia-discuss
Gotcha, thanks!
Reply all
Reply to author
Forward
0 new messages