As part of the thesis I’ve been looking around for test framework for JavaScript. I’ve found Buster.JS, and its support of mocking, stubbing and asynchronous tests appealed to me. It required Node.JS to work, so I began the task of installing it. I started getting errors, and as I’m not that experienced with the whole compiling-process (I’ve experience from courses where we programmed with C and assembly, but ain’t really fond of it). It took me some time debugging the problem, but the line “/usr/bin/ld: cannot find -lz” stood out after some iterations.
With this in mind, I searched for build error “cannot find -lz”, and the second result was “/usr/bin/ld: cannot find -lz” on StackOverflow. I realized I was cross-compiling, and the answer hinted me to check which libraries were required for the build. Surely enough, target_defaults.libraries in config.gypi were set to [’lz’].
I wasn’t sure of what to do at this point, but I removed the dependency on lz (by changing the value set to libraries to []), and behold! It built, and I could finally install the program!
Now, I’ve began trying to install Buster.JS. There seems to be some problems (as you can see in this snippet), but I’ll return and write an update when/if I tackle it.