Skip to content

Conversation

@nev3rfail
Copy link

So I've tried to build skiko by myself and encountered few issues:

  1. emscripten contains both emcc (shell script) and emcc.bat files but OS.compilerForTarget returns "emcc" which causes Gradle to create tasks that attempt to execute a non-executable and the fix is to add ".bat" to emcc executable.

  2. Paths to includes are broken with a combination of Windows host and WASM because someone in "emcc.bat -> emcc.py -> clang.exe" chain eats Windows' directory separators. Solution is to create one more arg builder that would convert \ to \\ but also wouldn't convert arguments themselves like BaseVisualStudioBuildToolsArgBuilder does.

So I've tried to build skiko by myself and encountered few issues:

1. [emscripten](https://github.com/emscripten-core/emscripten) contains both `emcc` (shell script) and `emcc.bat` files but [OS.compilerForTarget](https://github.com/nev3rfail/skiko/blob/52c586f9b509715e7466f0355e440a39f12f187a/skiko/buildSrc/src/main/kotlin/properties.kt#L43) returns "emcc" which causes Gradle to create tasks that attempt to execute a non-executable and the fix is to add ".bat" to `emcc` executable.

2. Paths to includes are broken with a combination of Windows host and WASM because someone in "emcc.bat -> emcc.py -> clang.exe" chain eats Windows' directory separators. Solution is to create one more arg builder that would convert `\` to `\\` but also wouldn't convert arguments themselves like BaseVisualStudioBuildToolsArgBuilder does.
@MatkovIvan MatkovIvan requested a review from eymar August 7, 2023 08:52
igordmn pushed a commit that referenced this pull request Jul 2, 2025
### New:  
(related #1019)
1. Adds bindings to GrBackendTextures::MakeGL 
2. Adds bindings to SkImages::AdoptTextureFrom
3. Adds bindings to GrBackendTextures::GLTextureParametersModdified

### Changes in build scripts:
(related #742)
1. Add file paths treating if building on Windows machine
2. Use "emcc.bat" instead of "emcc" if building on Windows machine, as
described on Emscripten website

### Use-case: 
Allows skia to draw images, rendered externally on gpu.
Compose would benefit greatly, allowing to embed VideoPlayer or Browser
without any friction or need to use Swing.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant