|
View:
New views
8 Messages
—
Rating Filter:
Alert me
|
|
|
Trying to move from FOX 1.6.0 (dev) to TnFOX, some errors encountered:The first set of errors was about FOX_BIGENDIAN not being declared. I put a -DFOX_BIGENDIAN in my compile script and now that doesnt yell at me. (I dont know if I _should_ be declaring that though...)
After that I had a couple ambigous errors with timeval and a couple others, commenting out these two includes in my app bypassed this, but caused other errors (missing some defines and commands) #include <sys/time.h> #include <sys/wait.h> Besides those couple errors, which a little bit of research might yeild a solution, I get hundreds of FXFile, FXDir, etc... errors about missing functions. error: `FXSystem' has not been declared error: `getHomeDirectory' undeclared (first use this function) error: `FXSystem' has not been declared error: `FXStat' has not been declared error: `isDirectory' undeclared (first use this function) error: `FXStat' has not been declared error: `isReadable' undeclared (first use this function) error: `FXDir' has not been declared error: `FXDir' has not been declared The offending functions are all File related, do these exist in TnFOX or will I have to write them all from scratch? -- Talent is not something you learn, its something you refine. If you make something that any idiot can use, only idiots will use it. |
|
|
Re: Trying to move from FOX 1.6.0 (dev) to TnFOX, some errors encountered:On 25 Feb 2006 at 22:33, The Devils Jester wrote:
> The first set of errors was about FOX_BIGENDIAN not being declared. I put a > -DFOX_BIGENDIAN in my compile script and now that doesnt yell at me. (I > dont know if I _should_ be declaring that though...) If you're using scons, the SConstruct file asks python for the endian and sets it for you. If you're not using scons, then yes you need to specify it. > After that I had a couple ambigous errors with timeval and a couple others, > commenting out these two includes in my app bypassed this, but caused other > errors (missing some defines and commands) Someone else reported this and I have a potential fix in SVN. However, regarding timeval problems, this issue only arises if you use "using namespace FX;". And I'm stuck in a real hole here because if you use Jeroen's solution, it breaks on win32 in an unportable way. If you go with mine, it works everywhere except it sometimes clashes with the system timeval which requires minor source surgery. Either way, you can't win but at least with my mechanism you avoid having to include win32 only headers in otherwise totally portable code. > Besides those couple errors, which a little bit of research might yeild a > solution, I get hundreds of FXFile, FXDir, etc... errors about missing > functions. > > error: `FXSystem' has not been declared > error: `getHomeDirectory' undeclared (first use this function) > error: `FXSystem' has not been declared > error: `FXStat' has not been declared > error: `isDirectory' undeclared (first use this function) > error: `FXStat' has not been declared > error: `isReadable' undeclared (first use this function) > error: `FXDir' has not been declared > error: `FXDir' has not been declared > > The offending functions are all File related, do these exist in TnFOX or > will I have to write them all from scratch? All these exist in TnFOX though some (eg; FXThread or FXMemMap) require the FOX compatibility layer to be enabled. See config.py. You shouldn't get any errors. It should all just compile. FXSystem, FXStat and FXDir are all certainly in there and working as FOX code uses them itself internally. It is possible that maybe you aren't directly including FXDir.h, FXSystem.h etc in your code and relying on other headers to do it for you. You do want to include the header for any class you use, or else simply include fx.h which includes everything. Cheers, Niall ------------------------------------------------------- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642 _______________________________________________ Tnfox-discussion mailing list Tnfox-discussion@... https://lists.sourceforge.net/lists/listinfo/tnfox-discussion |
|
|
Re: Trying to move from FOX 1.6.0 (dev) to TnFOX, some errors encountered:I dont use scons or make or anything of the sort, its always been too complicated and too many files just to compile an app. I use a simple .sh script which calls g++ with my options (and a .bat which calls borland on win), it may not be as portable as a makefile or scons, but it is much cleaner, smaller and easier.
I dont mind a portable workarround for the timeval issue, as you stated I would rather do this than make an unportable solution. What is your solution here? I include fx.h and fx3d.h as the very first thing in my code so its not related to that in anyway. I get hundreds of errors from these FXFile and friends because I have so many used in my app. I can attempt to include the FXSystem, FXDir, FXFile, etc... directly and see if that changes anything. I dont use any fox thread or memory functions, or any similar low level functions, just the gui, string manipulation and file info. The only errors that I get are the file and directory missing function ones. Everything else looks like it will compile without a hitch. On 2/26/06, Niall Douglas <s_sourceforge@...> wrote: On 25 Feb 2006 at 22:33, The Devils Jester wrote: -- Talent is not something you learn, its something you refine. If you make something that any idiot can use, only idiots will use it. <a href=" http://www.spreadfirefox.com/?q=affiliates&id=0&t=1">Get Firefox!</a> |
|
|
Re: Trying to move from FOX 1.6.0 (dev) to TnFOX, some errors encountered:On 26 Feb 2006 at 9:53, The Devils Jester wrote:
> I dont use scons or make or anything of the sort, its always been too > complicated and too many files just to compile an app. I use a simple .sh > script which calls g++ with my options (and a .bat which calls borland on > win), it may not be as portable as a makefile or scons, but it is much > cleaner, smaller and easier. Ok, but you'll understand you may run into problems I can't see because of this. > I dont mind a portable workarround for the timeval issue, as you stated I > would rather do this than make an unportable solution. What is your > solution here? Well, try the latest from SVN. In fx.h it tells the compiler to always use FX::timeval rather than ::timeval. This is fine unless you do direct calls into Unix, then you'll need to put a '::' before your timeval. > I include fx.h and fx3d.h as the very first thing in my code so its not > related to that in anyway. I get hundreds of errors from these FXFile and > friends because I have so many used in my app. I can attempt to include the > FXSystem, FXDir, FXFile, etc... directly and see if that changes anything. fx.h includes everything. I don't see that as the problem. > I dont use any fox thread or memory functions, or any similar low level > functions, just the gui, string manipulation and file info. The only errors > that I get are the file and directory missing function ones. Everything > else looks like it will compile without a hitch. It should all compile definitely - for example, nearly the entire FOX examples suite compiles and runs perfectly even without the FOX compat layer. Some of the FOX emulations aren't well tested and may cause problems, but they should all compile. Can you give me an example of some source which causes errors? Cheers, Niall ------------------------------------------------------- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642 _______________________________________________ Tnfox-discussion mailing list Tnfox-discussion@... https://lists.sourceforge.net/lists/listinfo/tnfox-discussion |
|
|
Re: Trying to move from FOX 1.6.0 (dev) to TnFOX, some errors encountered:I will attempt to make a small test app using the same functions that I am using, see if it compiles (if not, I will mail the source). I can also attempt to compile the test suite to see if its the compiler or not.
Do you have any quick and easy ways to make a scons setup so I can use that to compile my app and maybe get a better understanding of whats going on? On 2/26/06,
Niall Douglas <s_sourceforge@...> wrote: On 26 Feb 2006 at 9:53, The Devils Jester wrote: -- Talent is not something you learn, its something you refine. If you make something that any idiot can use, only idiots will use it. <a href=" http://www.spreadfirefox.com/?q=affiliates&id=0&t=1">Get Firefox!</a> |
|
|
Re: Trying to move from FOX 1.6.0 (dev) to TnFOX, some errors encountered:On 26 Feb 2006 at 12:16, The Devils Jester wrote:
> I will attempt to make a small test app using the same functions that I am > using, see if it compiles (if not, I will mail the source). I can also > attempt to compile the test suite to see if its the compiler or not. You can try the new set of FOX tests in SVN. Actually, I haven't uploaded it yet but I will within the hour. > Do you have any quick and easy ways to make a scons setup so I can use that > to compile my app and maybe get a better understanding of whats going on? Scons is very easy to use. I'd recommend copying the foxtests/SConstruct file and altering as appropriate. I derived that SConstruct from the TestSuite/CommonSConstruct.py in about five minutes. Obviously, you may find the scons man page useful. There are FAQ's and tutorials on the web too. BTW, I'll apologise now for the structure of my SConstruct files - I began them well before scons matured and I had to work around misfeatures. Cheers, Niall ------------------------------------------------------- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642 _______________________________________________ Tnfox-discussion mailing list Tnfox-discussion@... https://lists.sourceforge.net/lists/listinfo/tnfox-discussion |
|
|
Re: Trying to move from FOX 1.6.0 (dev) to TnFOX, some errors encountered:I dont see a foxtests folder, I will look at the one in TestSUite and
see I can make heads or tails of it, this is how I normally compile my
app:
(a shell script that does the following) g++ main.cpp -o myapp -L/usr/lib -L/usr/X11R6/lib -lGL -L./system -lpng -lfmod-3.74.1 -lFOX-1.6 -lXext -ldl -lpthread -lX11 -lz -fpic -DHAVE_GL_H=1 -DHAVE_PNG_H=1 -I ./include/FOX -I ./include/FMOD I need to somehow make scons do that exact thing, is there some kind of auto scon file generator? On 2/26/06, Niall Douglas <s_sourceforge@...> wrote: On 26 Feb 2006 at 12:16, The Devils Jester wrote: -- Talent is not something you learn, its something you refine. If you make something that any idiot can use, only idiots will use it. <a href="http://www.spreadfirefox.com/?q=affiliates&id=0&t=1">Get Firefox!</a> |
|
|
Re: Trying to move from FOX 1.6.0 (dev) to TnFOX, some errors encountered:On 26 Feb 2006 at 17:37, The Devils Jester wrote:
> I dont see a foxtests folder, I will look at the one in TestSUite and see I > can make heads or tails of it, this is how I normally compile my app: Sorry, got bogged down with fixing a separate issue. It's in SVN now. > g++ main.cpp -o myapp -L/usr/lib -L/usr/X11R6/lib -lGL -L./system -lpng - > lfmod-3.74.1 -lFOX-1.6 -lXext -ldl -lpthread -lX11 -lz -fpic -DHAVE_GL_H=1 > -DHAVE_PNG_H=1 -I ./include/FOX -I ./include/FMOD > > I need to somehow make scons do that exact thing, is there some kind of auto > scon file generator? It can be as simple as: env=Environment() env.Program("main.cpp", LIBPATH=['/usr/lib', '/usr/X11R6/lib'], LIBS=['GL', 'png', 'fmod-3.74.1', 'FOX-1.6', 'Xext', 'dl', 'pthread', 'X11', 'z'], CPPFLAGS=['-fpic'], CPPDEFINES=[('HAVE_GL_H', 1), ('HAVE_PNG_H', 1)], INCLUDES=['./include/FOX', './include/FMOD']) However, both FOX and TnFOX require a little more than that and more importantly, a lot of the above is autogenerated for you. Look at that foxtests folder. Cheers, Niall ------------------------------------------------------- This SF.Net email is sponsored by xPML, a groundbreaking scripting language that extends applications into web and mobile media. Attend the live webcast and join the prime developer group breaking into this new coding territory! http://sel.as-us.falkag.net/sel?cmd=lnk&kid=110944&bid=241720&dat=121642 _______________________________________________ Tnfox-discussion mailing list Tnfox-discussion@... https://lists.sourceforge.net/lists/listinfo/tnfox-discussion |
| Free embeddable forum powered by Nabble | Forum Help |