diff options
Diffstat (limited to 'webassembly/Makefile')
-rw-r--r-- | webassembly/Makefile | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/webassembly/Makefile b/webassembly/Makefile index e2898e4..df81e19 100644 --- a/webassembly/Makefile +++ b/webassembly/Makefile @@ -5,10 +5,17 @@ OBJS=diff.o CXX=em++ -CXXFLAGS=-I/usr/include -std=c++20 +CXXFLAGS=-I./include -O2 -std=c++20 LDFLAGS=-s WASM=1 -s LINKABLE=1 -s EXPORT_ALL=1 + default: $(TARGET) +$(OBJS): include + +include: + mkdir include + cp -r /usr/include/boost include/boost + $(TARGET): $(OBJS) $(CXX) $(LDFLAGS) $(OBJS) -o $(TARGETJS) cp $(TARGETJS) $(TARGET) ../html/ @@ -18,3 +25,4 @@ diff.o: ../diff.cpp clean: -rm -f *.o *.js *.wasm *.html + -rm -rf include |