emscripten-core / emscripten

Emscripten: An LLVM-to-WebAssembly Compiler
Other
25.63k stars 3.29k forks source link

Whether emscripten supports nasm #20131

Open yangfangfang1204 opened 1 year ago

yangfangfang1204 commented 1 year ago

emcc ffmpeg_demux.cpp -o ffmpeg_demux.o nasm -f elf32 ffmpeg_decoder.asm -o ffmpeg_decoder.o

can i use emar ffmpeg_demux.o ffmpeg_decoder.o - o ffmpeg.a by emscripten?

sbc100 commented 1 year ago

nasm appears to be an assembler for the x86 architecture, so sadly I don't think there is any way emscripten could support that.

You can use emar to create archive files but all the object file in the archive must be compiler with emcc (or at least compiled for the WebAssembly target).