@@ -103,12 +103,18 @@ A specific compiler can be chosen by setting the CC argument for example:
103
103
104
104
make CC=clang
105
105
106
+
107
+ #### Development targets
108
+
106
109
There are a number of other targets that are useful for library development
107
110
purposes:
108
111
109
112
make test [SANITIZE=yes] # Run the unit test suite, optionally building using LLVM sanitizers.
110
113
make fuzzer # Build fuzzers for exercising the individual encoders. Requires LLVM libfuzzer.
111
114
115
+
116
+ #### JavaScript / WASM build
117
+
112
118
The WASM build artifacts can be generated by first installing and activating
113
119
the Emscripten SDK and then running:
114
120
@@ -120,6 +126,24 @@ launched from the project home directory with:
120
126
docker run --rm -v $(pwd):/src -u $(id -u):$(id -g) emscripten/emsdk make -C src/c-lib wasm [JSONLY=yes]
121
127
122
128
129
+ #### Java wrapper
130
+
131
+ The Java wrapper for the Syntax Engine can be built by first compiling the
132
+ Syntax Engine C library as a static library, and then building the wrapper
133
+ itself:
134
+
135
+ make -C src/c-lib -j `nproc` libstatic
136
+ ant -f src/java/build.xml test
137
+
138
+ To use the wrapper in a Java project it is sufficient to place the generated
139
+ ` src/java/libgs1encoders.{jar,so} ` files into accessible locations, then:
140
+
141
+ * At compile time and runtime, add the .jar file into the project's
142
+ classpath.
143
+ * At runtime, add the directory containing the .so file into
144
+ ` java.library.path ` .
145
+
146
+
123
147
Installing the Pre-built Demo Console Application
124
148
-------------------------------------------------
125
149
0 commit comments