From 736bbbed715d6db1eec2a9947b86787d8f9e680e Mon Sep 17 00:00:00 2001 From: Michael Drake Date: Wed, 22 Mar 2017 15:35:19 +0000 Subject: Duktape 2.X: Update to Duktape 2.0.2. Note that DUK_OPT_XXX feature selection has been removed. This means we can't use `DUK_OPT_HAVE_CUSTOM_H`, so we need another way to tell duktape about our custom header. This means assembling our own duktape distribution with a duktape "tools/configure.py" invocation. Instructions for updating duktape have been added to NetSurf's `Docs/` directory. See: https://github.com/svaarala/duktape/blob/master/doc/release-notes-v2-0.rst#duk_opt_xxx-feature-option-support-removed --- Docs/updating-duktape.md | 29 +++++++++++++++++++++++++++++ 1 file changed, 29 insertions(+) create mode 100644 Docs/updating-duktape.md (limited to 'Docs/updating-duktape.md') diff --git a/Docs/updating-duktape.md b/Docs/updating-duktape.md new file mode 100644 index 000000000..a3e5a79b1 --- /dev/null +++ b/Docs/updating-duktape.md @@ -0,0 +1,29 @@ +Updating Duktape +================ + +1. Fetch the [latest release](http://duktape.org/download.html) archive. + +2. Extract it somewhere. + +3. That extracts to a `duktape-[VERSION]` directory. + +4. We need to tell duktape about our `duk_custom.h` header: + + 1. Change into the `duktape-[VERSION]` directory. + + 2. Run the following command: + + python2 tools/configure.py \ + --output-directory /tmp/output \ + --source-directory src-input \ + --config-metadata config \ + --fixup-line '#include "duk_custom.h"' + + 3. This generates a suitable set of duktape + sources in `/tmp/output` + +5. Replace the `duktape.c`, `duktape.h` and + `duk_config.h` files in the netsurf source + tree (in `content/handlers/javascript/duktape`) + with those generated in `/tmp/output`. + -- cgit v1.2.3