Skip to content

Commit

Permalink
chore: missing variables
Browse files Browse the repository at this point in the history
  • Loading branch information
jeromelaban committed Oct 12, 2022
1 parent f17f50a commit 8784f17
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions native/wasm/build.cake
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ Task("libSkiaSharp")
$" '-s', 'WARN_UNALIGNED=1' " + // '-s', 'USE_WEBGL2=1' (experimental)
$"] " +
// SIMD support is based on https://github.com/google/skia/blob/1f193df9b393d50da39570dab77a0bb5d28ec8ef/modules/canvaskit/compile.sh#L57
$"extra_cflags_cc=[ '-frtti' { (hasSimdEnabled ? ", '-msimd128'" : "") { (hasThreadingEnabled ? ", '-pthread'" : "") } } ] " +
$"extra_cflags_cc=[ '-frtti' { (hasSimdEnabled ? ", '-msimd128'" : "") } { (hasThreadingEnabled ? ", '-pthread'" : "") } ] " +
COMPILERS +
ADDITIONAL_GN_ARGS);

Expand Down Expand Up @@ -107,12 +107,15 @@ Task("libHarfBuzzSharp")
.WithCriteria(IsRunningOnLinux())
.Does(() =>
{
bool hasSimdEnabled = EMSCRIPTEN_FEATURES.Contains("simd");
bool hasThreadingEnabled = EMSCRIPTEN_FEATURES.Contains("mt");

GnNinja($"wasm", "HarfBuzzSharp",
$"target_os='linux' " +
$"target_cpu='wasm' " +
$"is_static_skiasharp=true " +
$"visibility_hidden=false " +
$"extra_cflags_cc=[ '-frtti' { (hasSimdEnabled ? ", '-msimd128'" : "") { (hasThreadingEnabled ? ", '-pthread'" : "") } } ] " +
$"extra_cflags_cc=[ '-frtti' { (hasSimdEnabled ? ", '-msimd128'" : "") } { (hasThreadingEnabled ? ", '-pthread'" : "") } ] " +
COMPILERS +
ADDITIONAL_GN_ARGS);

Expand Down

0 comments on commit 8784f17

Please sign in to comment.