It's very unfortunate that the implementation of JS require is wrong - or at least, it was wrong in the first release of Max 7 (I haven't upgraded, partly for that reason, partly because I have shows coming up and want to wait until there's a break with some time to kill before potentially destabilizing my world. I hear good things about Max 7 but experience with software in general leads me to caution...)
The issue is that you can't refer to files in subdirectories - even though the Common JS spec requires it. It's unfortunate, because most third-party Common JS packages do use subdirectories in their require sections, rendering them incompatible with Max/MSP's JS implementation.
I do hope this gets fixed and I will upgrade to Max 7 the moment it is... hint hint hint! :-) There was some argument last time this came up as to whether this was even a bug but I think the Common JS specification is authoritative in this matter...
Heh, well, I wrote the examples of this, but it actually uses gcc and make, standard tools that are on pretty well every machine!
I'd love to stop having that phase - if nothing else to avoid the error where I change the program and forget to compile them - and perhaps when Max 7 JS handles relative paths I can!
It makes my life much easier when I'm not dragging wires to land on tiny inlets... :-)
Its not popular approach here :) its against Max'ing attitude :D . Since dealing with the coding myself , im patching less for similar reasons , desires and efficiency . But we wont be applaud for this here , its sort of a sin not to wire stuff TOM :)))))))))