15 lines
355 B
CMake
15 lines
355 B
CMake
|
cmake_minimum_required(VERSION 3.0)
|
||
|
function(em_file name)
|
||
|
execute_process(COMMAND
|
||
|
emcc --bind
|
||
|
${CMAKE_SOURCE_DIR}/libmad.bc
|
||
|
${CMAKE_SOURCE_DIR}/${name}.cpp
|
||
|
-o ${CMAKE_BINARY_DIR}/${name}.js
|
||
|
-s WASM=0
|
||
|
)
|
||
|
endfunction(em_file)
|
||
|
|
||
|
configure_file(index.html index.html)
|
||
|
|
||
|
em_file(wrapper)
|