2002-09-16 (September 16, 2002) So here we are again... the last time I released any code to the world at large was on July 22, 2002... about two months ago. Now this doesn't mean that I haven't been tcl'ing - I just can't get enough! So what does it mean? It means deployment SUCKS! I WANT TO KILL IT ---- '''Do what your users do''' When developing, its a MUST that you run your code with the interpreter that your users are going to be using. If you don't do this, then you're just going to get so angry when you find that your program just won't run with the binary from that new wrapping tool you're using. Let me give you some concrete examples from my own painful development/deployment. When I write fun code, I choose Tcl/Tk because its fasttttt. I write and it doesn't work what ever, I hack it till it does. Sure I won't win any ACM awards for its engineering, but life is more exciting that way. '''looking for my own head''' So I take my code, usually the bootstrap code is called something like main.tcl, and it calls a bunch of libraries that I write for that app, in something like a scripts/ directory. Now I want this code to run - I don't mean every tiny detail looking the same - I just mean PLEASE RUN when wrapped for distribution to my buddies. But damn it, main.tcl just can't find its scripts when wrapped! This is using [freewrap], which totally munges the paths of files when wrapped. Not to mention doesn't work anymore (5.2 and 5.3 introduced a wicked bug where the freewrap'ed app just sits there when run from a path that contains spaces - like C:\My Documents\My Pictures). Now don't get me wrong, [freewrap] is cool. But talk about a NON-INTUITIVE (read - INSANE) way of packing the paths. It drove me just about nuts trying to figure this out. Btw, this is because it embeds the current working directory of your project inside the wrapped app, i.e. inside your ZVFS. So its like - where you executed the command becomes part of the product. I used to accept this because '''hey its insane, but it works'''. [freewrap] served me well for Mind Web, and it sure looks like it works for a bunch of other people, since my fave mp3 player snackamp[http://snackamp.sourceforge.net/] uses it too for distro to windows boxes. So I'm not trashing [freewrap], just blame it on my psychosis. All this pain that I feel would be better understood if you could witness my sleepless nights, my tossing and turning, my mute silence when with others, and the wild-eyed glare that is so evident when glancing in the mirror. '''what the hell is eq, use string equal''' The second problem with wrapping it, apart from having a hell of a time figuring it out, and then finding weird bugs in it, is that it just totally divorces you from your great users. You develop and test using something like ActiveTcl, then all of a sudden a different version of the Tcl/Tk interpreter gets wrapped with your scripts. This is not good at all, because you might be using 8.4 features but deploying it with 8.3 - '''MADNESS WILL SURELY ENSUE'''. '''all this is moot''' This is all moot anyway, because freewrap is a dud for me now that 5.2 and 5.3 have got that awesome bug that is so noted, also in the sourceforge bug tracker [http://sourceforge.net/tracker/?group_id=15218&atid=115218] And I can't go back to freewrap 5.1, since I use the 8.4 features... plus 5.1 has its own bugs ;) '''my compilation skillz - what skillz????!''' So I can compile my own freewrap - with the bugs fixed. This is open-source after all, isn't it? Not bloody likely - I suck with a compiler. Ya, maybe 3 years ago I could have messed with gcc and visual c++, but not today, not with scripting being so much fun and my compilation skills rotting away. There is no way I am going back to that NIGHTMARE! '''The line must be drawn here.''' '''the result''' I sit here in the darkness. I feel nothing. What was love, what was life? I cannot. I cannot go on. '''life will find a way''' Okay, so I'm in a little quandrary. But I could live with 8.3.4, that is freewrap 5.1 - but I have got to make it so that I can test with the same interpreter that is going to be deployed! This is '''not a feature, it is a tenet'''. So I make a little program that rips off the stub of the interpreter from the freewrap 5.1 binary, then go on to append a new zip to the end of it - basically hacking on the freewrap binary. I learn all these wonderful zip flags like -A and -9r. It makes me feel almost whole. I read about and munge about with the zvfs extension by Richard Hipp [http://www.hwaci.com/drh/index.html], and just generally reinvent the wheel - and a square one at that. I make it so it loads up zip script archives with an extension .ix, and it works. It also loads tcl files so now the interp that runs my development is the same as the one that runs the user-distro. Its basically a really crap [tclkit]. '''whoa! the second time is better''' holy crow! TCLKIT! The last time I used this son-of-a-gun-app it used to crash on win98 on exit. That was a showstopper right there.