Something similar to emconfigure/emmake?

Asked by Steven G. Messervey

Hello,
  One of the killer features of Emscripten is the ability to configure and build a C/C++ library, and then use
that libraries' functionality in the javascript environment. For example, libogg and libvorbis.

  The way I understand it, currently I would have to 'configure' (basically, suss out compile-time defines and
compiler flags) on my own, compile the library files individually, compile my wrapper, and then link them together.

  Do I understand the current situation correctly?
  Are there plans for creating tools similar to emconfigure and emmake,
or is there an established convention for using/porting libraries?

Thank you,
  Steve

Question information

Language:
English Edit question
Status:
Solved
For:
Cheerp Edit question
Assignee:
No assignee Edit question
Solved by:
Alessandro Pignotti
Solved:
Last query:
Last reply:
Revision history for this message
Best Alessandro Pignotti (a-pignotti) said :
#1

Hello,

Cheerp provides a cmake toolchain file.
https://github.com/leaningtech/cheerp-wiki/wiki/Getting-started#using-cmake

The main limitation is that feature detection does not work at this time, this will be fixed in Cheerp 1.2

configure is as this time not supported, you may be able to get it to work by letting configure first run using system compilers and then overriding the following environment variables

CC=/opt/cheerp/bin/clang
CXX=/opt/cheerp/bin/clang++

Revision history for this message
Steven G. Messervey (nuke48386) said :
#2

Great, thank you!

Revision history for this message
Steven G. Messervey (nuke48386) said :
#3

Thanks Alessandro Pignotti, that solved my question.