xtk

XTK build Issue


When I tried to build the latest code [ master ]. I am getting lot of warnings as follows and the generated xtk.js is not working.

*-----------------------*
Compiling Code
 /home/george/XTK4_0_217/lib/closure-library/closure/bin/build/closurebuilder.py: Scanning paths...
 /home/george/XTK4_0_217/lib/closure-library/closure/bin/build/closurebuilder.py: 958 sources scanned.
 /home/george/XTK4_0_217/lib/closure-library/closure/bin/build/closurebuilder.py: Building dependency tree..
 /home/george/XTK4_0_217/lib/closure-library/closure/bin/build/closurebuilder.py: Compiling with the following command: java -jar /home/george/XTK4_0_217/lib/closure-library/compiler-latest/compiler.jar --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/base.js --js /home/george/XTK4_0_217/lib/csg/vector.js --js /home/george/XTK4_0_217/X.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/string/string.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/useragent/useragent.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/structs/collection.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/object/object.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/debug/error.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/asserts/asserts.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/array/array.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/structs/structs.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/iter/iter.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/structs/map.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/structs/set.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/debug/debug.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/disposable/idisposable.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/disposable/disposable.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/structs/simplepool.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/debug/logrecord.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/debug/logbuffer.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/debug/logger.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/debug/tracer.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/debug/entrypointregistry.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/debug/errorhandler.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/debug/errorhandlerweakdep.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/events/listener.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/events/browserfeature.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/events/eventwrapper.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/events/eventtype.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/events/event.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/reflect/reflect.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/events/browserevent.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/events/events.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/events/eventtarget.js --js /home/george/XTK4_0_217/core/base.js --js /home/george/XTK4_0_217/lib/csg/vertex.js --js /home/george/XTK4_0_217/lib/csg/plane.js --js /home/george/XTK4_0_217/lib/csg/polygon.js --js /home/george/XTK4_0_217/lib/csg/node.js --js /home/george/XTK4_0_217/lib/csg/csg.js --js /home/george/XTK4_0_217/visualization/indexer.js --js /home/george/XTK4_0_217/core/file.js --js /home/george/XTK4_0_217/injects/loadable.js --js /home/george/XTK4_0_217/core/colortable.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/math/math.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/math/coordinate3.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/math/vec3.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/math/coordinate.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/math/vec2.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/math/size.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/math/matrix.js --js /home/george/XTK4_0_217/math/matrix.js --js /home/george/XTK4_0_217/core/transform.js --js /home/george/XTK4_0_217/core/texture.js --js /home/george/XTK4_0_217/core/triplets.js --js /home/george/XTK4_0_217/injects/displayable.js --js /home/george/XTK4_0_217/injects/thresholdable.js --js /home/george/XTK4_0_217/core/scalars.js --js /home/george/XTK4_0_217/objects/object.js --js /home/george/XTK4_0_217/injects/constructable.js --js /home/george/XTK4_0_217/core/event.js --js /home/george/XTK4_0_217/objects/slice.js --js /home/george/XTK4_0_217/objects/volume.js --js /home/george/XTK4_0_217/io/parser.js --js /home/george/XTK4_0_217/io/parserSTL.js --js /home/george/XTK4_0_217/io/parserVTK.js --js /home/george/XTK4_0_217/io/parserFSM.js --js /home/george/XTK4_0_217/lib/JXG/JXG.js --js /home/george/XTK4_0_217/io/parserNRRD.js --js /home/george/XTK4_0_217/io/parserHelper.js --js /home/george/XTK4_0_217/io/parserMGZ.js --js /home/george/XTK4_0_217/io/parserCRV.js --js /home/george/XTK4_0_217/io/parserIMAGE.js --js /home/george/XTK4_0_217/io/parserLUT.js --js /home/george/XTK4_0_217/io/parserTRK.js --js /home/george/XTK4_0_217/io/loader.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/events/mousewheelhandler.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/events/keycodes.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/events/keyhandler.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/dom/classes.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/dom/tagname.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/dom/browserfeature.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/dom/dom.js --js /home/george/XTK4_0_217/io/interactor.js --js /home/george/XTK4_0_217/io/interactor2D.js --js /home/george/XTK4_0_217/visualization/camera.js --js /home/george/XTK4_0_217/lib/csg/cylinder.js --js /home/george/XTK4_0_217/objects/cylinder.js --js /home/george/XTK4_0_217/lib/csg/sphere.js --js /home/george/XTK4_0_217/objects/sphere.js --js /home/george/XTK4_0_217/objects/labelmap.js --js /home/george/XTK4_0_217/lib/csg/cube.js --js /home/george/XTK4_0_217/objects/cube.js --js /home/george/XTK4_0_217/io/interactor3D.js --js /home/george/XTK4_0_217/math/array.js --js /home/george/XTK4_0_217/visualization/camera2D.js --js /home/george/XTK4_0_217/visualization/camera3D.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/math/box.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/math/rect.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/style/style.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/events/eventhandler.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/ui/idgenerator.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/ui/component.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/ui/rangemodel.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/dom/a11y.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/ui/progressbar.js --js /home/george/XTK4_0_217/ui/progressbar.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/timer/timer.js --js /home/george/XTK4_0_217/visualization/renderer.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/positioning/positioning.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/positioning/abstractposition.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/positioning/anchoredposition.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/fx/transition.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/ui/popupbase.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/positioning/viewportposition.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/positioning/clientposition.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/positioning/viewportclientposition.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/positioning/absoluteposition.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/functions/functions.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/positioning/anchoredviewportposition.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/ui/popup.js --js /home/george/XTK4_0_217/lib/closure-library/closure/goog/ui/tooltip.js --js /home/george/XTK4_0_217/ui/caption.js --js /home/george/XTK4_0_217/visualization/shaders.js --js /home/george/XTK4_0_217/visualization/buffer.js --js /home/george/XTK4_0_217/visualization/renderer3D.js --js /home/george/XTK4_0_217/objects/mesh.js --js /home/george/XTK4_0_217/visualization/renderer2D.js --js /home/george/XTK4_0_217/objects/fibers.js --warning_level=VERBOSE --compilation_level=ADVANCED_OPTIMIZATIONS --jscomp_warning=missingProperties --jscomp_warning=checkTypes --define=goog.DEBUG=false
 /home/george/XTK4_0_217/injects/constructable.js:60: WARNING - Property _points never defined on X.constructable
var numberOfPoints = this._points.count;
^

 /home/george/XTK4_0_217/injects/constructable.js:67: WARNING - Property _points never defined on X.constructable
var point1 = this._points.get(p);
^

 /home/george/XTK4_0_217/injects/constructable.js:68: WARNING - Property _points never defined on X.constructable
var point2 = this._points.get(p + 1);
^

 /home/george/XTK4_0_217/injects/constructable.js:69: WARNING - Property _points never defined on X.constructable
var point3 = this._points.get(p + 2);
^

 /home/george/XTK4_0_217/injects/constructable.js:71: WARNING - Property _normals never defined on X.constructable
var normal1 = this._normals.get(p);
^

 /home/george/XTK4_0_217/injects/constructable.js:72: WARNING - Property _normals never defined on X.constructable
var normal2 = this._normals.get(p + 1);
^

 /home/george/XTK4_0_217/injects/constructable.js:73: WARNING - Property _normals never defined on X.constructable
var normal3 = this._normals.get(p + 2);
^

 /home/george/XTK4_0_217/injects/constructable.js:79: WARNING - Property _colors never defined on X.constructable
if ((this._colors.length > 0)) {
^

 /home/george/XTK4_0_217/injects/constructable.js:83: WARNING - Property _colors never defined on X.constructable
color = this._colors.get(p);
^

 /home/george/XTK4_0_217/injects/constructable.js:122: WARNING - Property _points never defined on X.constructable
this._points.clear();
^

 /home/george/XTK4_0_217/injects/constructable.js:123: WARNING - Property _normals never defined on X.constructable
this._normals.clear();
^

 /home/george/XTK4_0_217/injects/constructable.js:124: WARNING - Property _colors never defined on X.constructable
this._colors.clear();
^

 /home/george/XTK4_0_217/injects/constructable.js:234: WARNING - Property toCSG never defined on csg
csg = csg.toCSG();
^

 /home/george/XTK4_0_217/injects/constructable.js:240: WARNING - Property fromCSG never defined on X.object
result.fromCSG(this.toCSG().union(csg));
^

 /home/george/XTK4_0_217/injects/constructable.js:269: WARNING - Property toCSG never defined on csg
csg = csg.toCSG();
^

 /home/george/XTK4_0_217/injects/constructable.js:275: WARNING - Property fromCSG never defined on X.object
result.fromCSG(this.toCSG().subtract(csg));
^

 /home/george/XTK4_0_217/injects/constructable.js:304: WARNING - Property toCSG never defined on csg
csg = csg.toCSG();
^

 /home/george/XTK4_0_217/injects/constructable.js:310: WARNING - Property fromCSG never defined on X.object
result.fromCSG(this.toCSG().intersect(csg));
^

 /home/george/XTK4_0_217/injects/constructable.js:327: WARNING - Property fromCSG never defined on X.object
result.fromCSG(this.toCSG().inverse());
^

 /home/george/XTK4_0_217/objects/cube.js:265: WARNING - Property fromCSG never defined on X.cube
this.fromCSG(new CSG.cube({
^

 /home/george/XTK4_0_217/objects/cylinder.js:207: WARNING - Property fromCSG never defined on X.cylinder
this.fromCSG(new CSG.cylinder({
^

 /home/george/XTK4_0_217/objects/object.js:151: WARNING - incomplete alias created for namespace X
this._children.push(new X[classname](_oldChildren[i]));
^

 /home/george/XTK4_0_217/objects/sphere.js:173: WARNING - Property fromCSG never defined on X.sphere
this.fromCSG(new CSG.sphere({
^

0 error(s), 23 warning(s), 94.4% typed
/home/george/XTK4_0_217/lib/closure-library/closure/bin/build/closurebuilder.py: JavaScript compilation succeeded.
>> OUTPUT: xtk.js
Code compiled
*-----------------------*
*-----------------------*
Visit us at goxtk.com!!!
Contact us at: dev@goxtk.com
Enjoy XTK
*-----------------------*

Solution

  • The 23 warnings are ok. The compiled xtk.js should work so - just tested against master.