From: Francesco M. <f18...@ya...> - 2006-05-18 10:57:15
|
John Labenski ha scritto: > On 5/17/06, Francesco Montorsi > <f18...@ya...> wrote: >> Hi, >> I'm experimenting with wx module and I've got a few proposals for it: >> >> 1) the luamodule.wx.lua files in wxLua/apps/luamodule/src is an example, >> isn't it ? Shouldn't then go in wxLua/samples ? >> wrapmodule.wx.lua is an utility so shouldn't it got in wxLua/utils ? > > Eh... I think these are pretty specialized. But, you're probably > right, once things work they should be moved. I just put them into the > dir where I generated the shared lib since I was having trouble with > the paths for require. Ok, another thing which now comes to my mind: "luamodule" directory should probably be moved too, in wxLua/modules. In fact, it does not build any application at all, just a .so/.dll BTW: I'd organize the thing as: -> wx.so/dll is always placed in wxLua/lib (even if, in Unix, you're building from a different build folder, e.g. wxLua/mybuild) -> luamodule.wx.lua sample uses package.cpath = ";;../lib/?.so;..\lib\?.dll" before the call to require("wx") -> on Unix, wx.so is installed in $prefix/lib/lua/5.1 Now, developers using wxLua which want to ship an application entirely written in wxLua, which uses the require("wx") notation, will just need to ship: -> all DLLs/.so of wxLua/lib if they built wxLua as a shared library (SHARED=1) -> wx.so/.dll if they built wxLua as a static library (SHARED=0). In fact, wx.so/.dll should be built regardless of the SHARED option value: when SHARED==1, it will just be a super-small file which tells the OS to load the other .so/.dll libraries; when SHARED==0, it will be a bigger lib (on my Unix, it is about 9,4 MB) which is self-contained. What do you think ? Francesco |