diff options
| author | Michele Calgaro <michele.calgaro@yahoo.it> | 2020-12-20 23:01:54 +0900 |
|---|---|---|
| committer | Michele Calgaro <michele.calgaro@yahoo.it> | 2020-12-22 11:50:09 +0900 |
| commit | 112ca8677b9b024de5529712e559c968da40a67a (patch) | |
| tree | a8e93a0b05d61aeaab1dab3288c5fc518cdd05c6 /debian/uncrustify-trinity/uncrustify-trinity-0.72.0/emscripten/build.sh | |
| parent | b37f44d6c7444ca20c48a07fdcaf7b2a812db5bd (diff) | |
| download | extra-dependencies-112ca8677b9b024de5529712e559c968da40a67a.tar.gz extra-dependencies-112ca8677b9b024de5529712e559c968da40a67a.zip | |
DEB uncrustify: added first version of uncrustify-trinity. This is basically the upstream 0.72.0 version of uncrustify, repackaged.
Signed-off-by: Michele Calgaro <michele.calgaro@yahoo.it>
Diffstat (limited to 'debian/uncrustify-trinity/uncrustify-trinity-0.72.0/emscripten/build.sh')
| -rwxr-xr-x | debian/uncrustify-trinity/uncrustify-trinity-0.72.0/emscripten/build.sh | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/debian/uncrustify-trinity/uncrustify-trinity-0.72.0/emscripten/build.sh b/debian/uncrustify-trinity/uncrustify-trinity-0.72.0/emscripten/build.sh new file mode 100755 index 00000000..df4b6fe3 --- /dev/null +++ b/debian/uncrustify-trinity/uncrustify-trinity-0.72.0/emscripten/build.sh @@ -0,0 +1,33 @@ +#!/bin/sh +# script to build without cmake, +# manually generate header files usually created by CMake, +# past those inside Uncrustifys 'src' dir +# run this script in the 'emscripten' dir + +sh_dir="$(dirname "$(readlink -f "$0")")" +outTmp="temp.bak" +out="libUncrustify.js" + +#https://github.com/kripken/emscripten/blob/master/src/settings.js + +em++ -O3 \ + ${COMMENT# initialy increase memory for big input files } \ + -s TOTAL_MEMORY=67108864 \ + ${COMMENT# let the memory grow dynamically if even more is needed } \ + -s ALLOW_MEMORY_GROWTH=1 \ + -s VERBOSE=1 \ + -s MODULARIZE=1 \ + -s EXPORT_NAME="'libUncrustify'" \ + -s ERROR_ON_UNDEFINED_SYMBOLS=1 \ + -s ALLOW_MEMORY_GROWTH=1 \ + -s "EXTRA_EXPORTED_RUNTIME_METHODS=['UTF8ToString', 'stringToUTF8', 'lengthBytesUTF8', 'writeAsciiToMemory']" \ + --bind \ + --pre-js prefix_module.js \ + --post-js postfix_module.js \ + ${COMMENT# TODO: handle async ajax load to enable this } \ + --memory-init-file 0 \ + -o $out \ + ../src/*.cpp \ +&& cat "./prefix_file" "$out" "./postfix_file" > "$outTmp" \ +&& mv "$outTmp" "$out" \ +&& ./test/run_tests.py "$sh_dir/libUncrustify.js" "$sh_dir/test" |
