Issues with following instructions building Skia

321 views
Skip to first unread message

Kalen White

unread,
Aug 9, 2023, 1:18:10 PM8/9/23
to skia-discuss
I synced build deps which successfully got everything in third_party, including libjpeg-turbo

python3 tools/git-sync-deps <- runs fine.

When I build it does not find the jpeg headers:

FAILED: obj/src/codec/jpeg_decode.SkJpegCodec.o 

c++ -MD -MF obj/src/codec/jpeg_decode.SkJpegCodec.o.d -DNDEBUG -DSK_ENABLE_SKSL -DSK_ENABLE_PRECOMPILE -DSK_ASSUME_GL=1 -DSK_GANESH -DSK_USE_PERFETTO -DSK_ENABLE_API_AVAILABLE -DSK_GAMMA_APPLY_TO_A8 -DSKIA_IMPLEMENTATION=1 -DSK_CODEC_DECODES_JPEG -I../.. -Wno-attributes -ffp-contract=off -fstrict-aliasing -fPIC -fvisibility=hidden -isysroot /Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/SDKs/MacOSX13.3.sdk -target arm64-apple-macos11 -O3 -std=c++17 -fvisibility-inlines-hidden -fno-exceptions -fno-rtti -c ../../src/codec/SkJpegCodec.cpp -o obj/src/codec/jpeg_decode.SkJpegCodec.o

In file included from ../../src/codec/SkJpegCodec.cpp:28:

In file included from ../../src/codec/SkJpegDecoderMgr.h:14:

../../src/codec/SkJpegPriv.h:21:14: fatal error: 'jpeglib.h' file not found

    #include "jpeglib.h"


Its in third_party & externals.  It fetched it fine.  It must be my M2 mac architecture skipping it from being included without error.  Its not including the jpeg headers there.  Something in GN must be skipping it.


Can someone inform me of a very plain set of args for building for:


Vulkan & TTF Fonts and absolutely NOTHING else?  No system font manager or anything my apps always just have a set of .ttf.  In my case I need vulkan, fonts, and thats it.




Kalen White

unread,
Aug 9, 2023, 1:25:08 PM8/9/23
to skia-discuss
I've currently got:

is_official_build=false is_component_build=false is_trivial_abi=true werror=true skia_use_angle=false skia_use_dng_sdk=false skia_use_dawn=false skia_use_webgl=false skia_use_webgpu=false skia_use_expat=false skia_use_fontconfig=false skia_use_freetype=true skia_use_libheif=false skia_use_libjpeg_turbo_decode=false skia_use_libjpeg_turbo_encode=false skia_use_no_jpeg_encode=false skia_use_libpng_decode=false skia_use_libpng_encode=false skia_use_no_png_encode=false skia_use_libwebp_decode=false skia_use_libwebp_encode=false skia_use_no_webp_encode=false  skia_use_lua=false skia_use_piex=false skia_use_system_freetype2=false  skia_use_system_libpng=false skia_use_system_zlib=false skia_use_vulkan=true skia_use_wuffs=false skia_use_zlib=false skia_enable_ganesh=false skia_enable_sksl=false skia_build_for_debugger=false skia_enable_sksl_tracing=false skia_enable_skshaper=false skia_enable_skparagraph=false skia_enable_pdf=false skia_canvaskit_force_tracing=false skia_canvaskit_profile_build=false skia_canvaskit_enable_skp_serialization=false skia_canvaskit_enable_effects_deserialization=false skia_canvaskit_enable_skottie=false skia_canvaskit_include_viewer=false skia_canvaskit_enable_pathops=false skia_canvaskit_enable_rt_shader=false skia_canvaskit_enable_matrix_helper=false skia_canvaskit_enable_canvas_bindings=false skia_canvaskit_enable_font=false skia_canvaskit_enable_embedded_font=false skia_canvaskit_enable_alias_font=false skia_canvaskit_legacy_draw_vertices_blend_mode=false skia_canvaskit_enable_debugger=false skia_canvaskit_enable_paragraph=false skia_canvaskit_enable_webgl=false skia_canvaskit_enable_webgpu=false

The script I got them from (canvaskit/compile.sh) had some stale properties such as skia_use_system_libjpeg_turbo, skia_use_system_libwebp.  I thought I would report that

Kalen White

unread,
Aug 9, 2023, 1:26:41 PM8/9/23
to skia-discuss
This is m112 branch

Kalen White

unread,
Aug 10, 2023, 8:53:44 AM8/10/23
to skia-discuss
When you disable jpeg, it still builds the jpeg tests in ganesh.
Reply all
Reply to author
Forward
0 new messages