|
From: Ray G. <ray...@sc...> - 2005-06-15 04:51:42
|
I wrote it, and I looked at it and had to think twice....
Generally,=20
1. create a ctags file
2. run ctag2dat - parses ctag file into a lua data file (ldat)
3. run dat2i - loads dat file and creates *.i files
4. run genwxbind.lua - reads *.i files and generates code
The .rule files configure parsing rules. A rule file can be written to
tell the scripts on what to ignore, hints etc
Steps 2 and 3 where written to generate new interfaces for 3rd party
libs. Not for generating wx inferface files. I am currently modifying
them to be able to extract wx interfaces.
Firstly I have have alreadly extracted all the hand coded wx
conditionals. I am now working on a little parser to extract conditional
compile macros (wxUSE_xxx) directly from wx headers. Once I have that I
can regenerate a complete set of interface files. This can be
automatically create new interfaces for each version. I was thinking of
moving all depreciated classes to their own wx version *.i file.
Ray
-----Original Message-----
From: wxl...@li...
[mailto:wxl...@li...] On Behalf Of John
Labenski
Sent: Wednesday, 15 June 2005 13:18
To: wxl...@li...
Subject: Re: [Wxlua-users] Bakefile
On 6/14/05, Francesco Montorsi <f18...@ya...> wrote:
> Hi,
> now wxLua bakefiles are in good state: you should be able to use=20
> them (from command-line) to build all modules & bin2c.
> I have some problem with apps\wxlua: when compiling with
>=20
> nmake -fmakefile.vc WX_UNICODE=3D1
From what dir?
> I get:
> Microsoft (R) Program Maintenance Utility Version 6.00.8168.0
> Copyright (C) Microsoft Corp 1988-1998. All rights reserved.
> ..\..\..\bin\lua -e"target=3D\"msw\"" =
..\..\wxlua\src\wrap.lua=20
> Finding wxWindows Path Using Environment Variable : =
WXWIN=3Dc:\wxWidgets
> Target is : msw Parsing wxWindows Version File:=20
> c:\wxWidgets/include/wx/version.h Parsing wxWindows Setup File:=20
> c:\wxWidgets/include/wx/msw/setup.h
> Setup: Compatibility For wxWindows Version 2.4 Output File:=20
> wxluawrap.cpp Parsing Lua Setup File: luasetup.h.in
> ..\..\..\bin\lua: ../../../bindings/wxluawrap.lua:1834: bad argument=20
> #1 to `line s' (No such file or directory) stack traceback:
> [C]: in function `lines'
> ../../../bindings/wxluawrap.lua:1834: in function
`ReadSetupFiles'
> ../../../bindings/wxluawrap.lua:1909: in function `main'
> ../../../bindings/wxluawrap.lua:3225: in main chunk
> [C]: in function `dofile'
> ..\..\wxlua\src\wrap.lua:11: in main chunk
> [C]: ?
> NMAKE : fatal error U1077: '..\..\..\bin\lua' : return code '0x1'
> Stop.
> NMAKE : fatal error U1077: '"C:\Programmi\Microsoft Visual=20
> Studio\VC98\bin\NMAKE .EXE"' : return code '0x2'
> Stop.
>=20
> I put that step (..\..\..\bin\lua -e"target=3D\"msw\""
> ..\..\wxlua\src\wrap.lua) looking at the DSP file... what am I missing
?
You need to make sure that the dirs are correct. We have to use all
relative paths so that if you're building in wxLua/build/msw you
probably have to have something like this.
First go to apps/wxlua/src dir then run wrap.bat (or directly call
wrap.lua as you do) then go back to build/msw.
cd ..\..\apps\wxlua\src && "wrap.bat" && cd ..\..\..\build\msw=20
> >> When you run bindings/wxluawrap.lua it takes either the=20
> >> luasetup.h.in the bindings dir or in your own program's dir and=20
> >> generates luasetup.h that may exclude other classes automatically
using their dependencies.
> >> It can be updated by hand. Please see apps/wxlua/wrap.bat/lua and=20
> >> Makefile_import to see how the wrappers are generated. It's build=20
> >> is also automated in apps/wxlua/src/wxlua_wx26.dsp running wrap.bat
> >> to generate wxluawrap.cpp, can bakefile do this sort of thing?
> as you can see from the output log above, I created a target in=20
> makefiles ("wrap") which calls the lua.exe file on=20
> apps/wxlua/src/wrap.lua... the only problem is that bakefile does not=20
> know how to build files with extension ".i" so I had to include in=20
> apps\wxlua sources the file bindings\wxwidgets\wxluawrap.c which the=20
> makefiles generate just copying the bindings\wxwidgets\wxluawrap.i=20
> file... this is the only problem I've found.
Don't spend too much time on this, we'll be using a whole different set
to wrappers soon.
Something like this, where we can build a lib out of it or just include
them in your project.
=20
http://cvs.sourceforge.net/viewcvs.py/wxstudio/wxIDE/parts/cdlua/wxbind/
I'm having a hard time understanding the code to do it though.
-John Labenski
-------------------------------------------------------
SF.Net email is sponsored by: Discover Easy Linux Migration Strategies
from IBM. Find simple to follow Roadmaps, straightforward articles,
informative Webcasts and more! Get everything you need to get up to
speed, fast. http://ads.osdn.com/?ad_idt77&alloc_id=16492&op=3Dick
_______________________________________________
Wxlua-users mailing list
Wxl...@li...
https://lists.sourceforge.net/lists/listinfo/wxlua-users
|