diff --git a/libxml2 b/libxml2 index 726f67e..48dba1e 160000 --- a/libxml2 +++ b/libxml2 @@ -1 +1 @@ -Subproject commit 726f67e2f140f8d936dfe993bf9ded3180d750d2 +Subproject commit 48dba1e21f8f1a7d8a817eaf65831396e74b78d2 diff --git a/script/clean b/script/clean index ea3c7d3..4608b38 100755 --- a/script/clean +++ b/script/clean @@ -2,4 +2,10 @@ rm -rf ./build rm -rf ./libxml2/compile -rm -rf ./libxml2/m4 + +# some file in ./libxml2/m4 are provided by the project +rm -f ./libxml2/m4/libtool.m4 +rm -f ./libxml2/m4/lt~obsolete.m4 +rm -f ./libxml2/m4/ltoptions.m4 +rm -f ./libxml2/m4/ltsugar.m4 +rm -f ./libxml2/m4/ltversion.m4 \ No newline at end of file diff --git a/script/compile b/script/compile index a09b70a..577c1e1 100755 --- a/script/compile +++ b/script/compile @@ -1,8 +1,7 @@ #!/bin/bash emcc -O2 -s EMULATE_FUNCTION_POINTER_CASTS=1 \ - --memory-init-file 0 \ - ./build/xmllint.o ./build/.libs/libxml2.a ./libz.a \ + ./build/xmllint-xmllint.o ./build/.libs/libxml2.so ./libz.a \ -o xmllint.raw.js --pre-js ./src/pre.js sed '/\/\* XMLLINT.RAW.JS \*\// { diff --git a/script/libxml2 b/script/libxml2 index 3c9ca1f..eb1210d 100755 --- a/script/libxml2 +++ b/script/libxml2 @@ -1,10 +1,9 @@ #!/bin/bash mkdir -p ./build -mkdir -p ./libxml2/m4 cd ./libxml2 autoreconf -if -Wall cd ../build -emconfigure ../libxml2/configure --with-http=no --with-ftp=no --with-python=no --with-threads=no +emconfigure ../libxml2/configure --with-http=no --with-ftp=no --with-python=no --with-threads=no --with-modules=no emmake make cd .. diff --git a/script/test b/script/test index 80e7190..e638174 100755 --- a/script/test +++ b/script/test @@ -1,7 +1,7 @@ #!/bin/bash -emcc -O2 -s EMULATE_FUNCTION_POINTER_CASTS=1 ./build/xmllint.o \ - ./build/.libs/libxml2.a ./libz.a -o ./xmllint.test.js \ +emcc -O2 -s EMULATE_FUNCTION_POINTER_CASTS=1 ./build/xmllint-xmllint.o \ + ./build/.libs/libxml2.so ./libz.a -o ./xmllint.test.js \ --embed-file ./test/test.xml --embed-file ./test/test.xsd node ./xmllint.test.js --noout --schema ./test/test.xsd ./test/test.xml rm -rf ./xmllint.test.js