Compiling external header only libraries

48 views
Skip to first unread message

Michael IV

unread,
Mar 7, 2014, 4:16:37 AM3/7/14
to emscripte...@googlegroups.com
If I need to use a header only template library in a code I want to compile with emcscripten (or just want to compile to JS that library as standalone) ,is it enough just include the headers?Or there is something else I need to setup?

Jukka Jylänki

unread,
Mar 7, 2014, 4:41:02 AM3/7/14
to emscripte...@googlegroups.com
No, Emscripten doesn't have any special setup required for using template code from headers.

If you want to expose any piece of code to JavaScript, you'll need to implement a C++<->JS interface for it so that you can call the functions from handwritten JS, either via embind or manual ccall/cwrap if the interface is C-like.


2014-03-07 11:16 GMT+02:00 Michael IV <explo...@gmail.com>:
If I need to use a header only template library in a code I want to compile with emcscripten (or just want to compile to JS that library as standalone) ,is it enough just include the headers?Or there is something else I need to setup?

--
You received this message because you are subscribed to the Google Groups "emscripten-discuss" group.
To unsubscribe from this group and stop receiving emails from it, send an email to emscripten-disc...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Michael IV

unread,
Mar 7, 2014, 4:53:35 AM3/7/14
to emscripte...@googlegroups.com
Great,thanks!


--
You received this message because you are subscribed to a topic in the Google Groups "emscripten-discuss" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/emscripten-discuss/0eUKeSW_drc/unsubscribe.
To unsubscribe from this group and all its topics, send an email to emscripten-disc...@googlegroups.com.

For more options, visit https://groups.google.com/d/optout.



--
Michael Ivanov
Independent Pixel Commander 
onlygraphix.com
Tel:+972 54 4962254

Reply all
Reply to author
Forward
0 new messages