Questions tagged [emmake]

Emmake is a wrapper script of emscripten to easily build projects that already have a build system based on makefiles. Use this tag if your question is related to the usage of this wrapper script.

Main project page: https://emscripten.org/

Tutorial on building projects: https://emscripten.org/docs/compiling/Building-Projects.html

9 questions
8
votes
1 answer

How do I pass 'emcc' options through 'emcmake cmake/emmake make'?

I have a CMake project (C++) that I want to make available in JavaScript through WebAssembly. To configure it, I use emcmake cmake and to build it emmake make. I can compile parts successfully, when I do it manually: emcc --bind test.cpp But I…
stackprotector
  • 10,498
  • 4
  • 35
  • 64
6
votes
2 answers

Emscripten "Permission Denied" even when I sudo enmake

I'm playing around with emscripten and I keep getting this confusing message |[413077]-$>../emmake Makefile Error: Exception thrown when invoking Popen in make with args: "Makefile"! Traceback (most recent call last): File "../emmake", line 24, in…
JKirchartz
  • 17,612
  • 7
  • 60
  • 88
5
votes
3 answers

How to export C function in Emscripten when using CMake

In this tutorial it shows the following example for exporting C functions ./emcc tests/hello_function.cpp -o function.html -s EXPORTED_FUNCTIONS='["_int_sqrt"]' -s EXPORTED_RUNTIME_METHODS='["ccall", "cwrap"]' I would like to do the same except…
alagris
  • 1,838
  • 16
  • 31
4
votes
1 answer

emmake and emconfigure command not found (osx)

I'm trying to use CMake with Emscripten. I followed this official tutorial, cloned the repo with: git clone https://github.com/emscripten-core/emsdk.git I did: ./emsdk install latest ./emsdk activate latest and in general, emcc seems to be…
alagris
  • 1,838
  • 16
  • 31
0
votes
0 answers

emmake: error: unable to find library -lTKernel

guys! I am trying to use emmake to compile a project containing OpenCascade api. When I used cmake .. and make commands, everying works fine! Note that I already installed OpenCascade on my machine. My CMakeLists.txt is as…
Rick.X
  • 513
  • 5
  • 10
0
votes
0 answers

Use the `emconfigure`, `emmake` command to compile it to a `.wasm` file

I am trying to build a cpp project into a wasm file using the command like this ./emcc test/hello_world.c -o hello.html from the link here. That works. However, when I am using a c++ project that has .configure file and the result creates multiple…
Gary
  • 2,293
  • 2
  • 25
  • 47
0
votes
0 answers

What is output of emcmake and emmake (emscripten) on C/C++ project? What is the relation between emcc with emcmake and emmake?

1- I run emcmake (emscripten) on the directory of CMakeList.txt file. what is the expected output? 2- Then, I run emmake (emscripten) on the directory of Makefile file. what is the expected output? 3- What is the relation between these command with…
Arash
  • 1
  • 1
0
votes
0 answers

Emscripten makefile

I am trying to create emscripten logic in Makefile . I am calling cmake command of a CMakeLists.txt. So the logic looks like this ifeq(EXECUTOR, Emscripten) emcmake cmake cmake/CMakeLists.txt else cmake cmake/CMakeLists.txt endif And in…
Hrant Nurijanyan
  • 789
  • 2
  • 9
  • 26
0
votes
1 answer

Make error: emmake make results in error when trying to build libxml2, can't find libxml.so.2

My goal is to compile my C program to wasm with emscripten (which I installed via emsdk). It uses libxml2. I am following the steps outlined here https://github.com/kripken/xml.js/blob/master/script/libxml2 to build libxml2 from source with the…