From feb72389aa4e1070fcbc888280ea65b178176460 Mon Sep 17 00:00:00 2001 From: ZoRo Date: Thu, 26 Aug 2021 09:48:17 +0100 Subject: Update source to be compatible with emscripten --- Build/Makefile | 5 ++-- Build/index.html | 80 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 83 insertions(+), 2 deletions(-) create mode 100644 Build/index.html (limited to 'Build') diff --git a/Build/Makefile b/Build/Makefile index e19df12..f56677d 100644 --- a/Build/Makefile +++ b/Build/Makefile @@ -7,10 +7,11 @@ EM_LDFALGS=-s LLD_REPORT_UNDEFINED make: $(CC) -c $(SOURCEDIR)/main.c -g3 - $(CC) main.o -o NaiveFFT $(LDFLAGS) + $(CC) -c $(SOURCEDIR)/fft.c -g3 + $(CC) main.o fft.o -o NaiveFFT $(LDFLAGS) emcc: - $(EMCC) $(SOURCEDIR)/main.c ../NaiveFFT/fft.c -s WASM=1 -O3 -o index.js $(EM_LDFALGS) -s EXTRA_EXPORTED_RUNTIME_METHODS='["ccall", "cwrap"]' + $(EMCC) $(SOURCEDIR)/main.c $(SOURCEDIR)/fft.c -s WASM=1 -O3 -o index.js $(EM_LDFALGS) -s EXTRA_EXPORTED_RUNTIME_METHODS='["ccall", "cwrap"]' web: diff --git a/Build/index.html b/Build/index.html new file mode 100644 index 0000000..8f510ac --- /dev/null +++ b/Build/index.html @@ -0,0 +1,80 @@ + + + + + WebAssembly Example + + + + + + + + + + + FFT demo + + + + + + + \ No newline at end of file -- cgit v1.2.3