Danny Backx wrote: > On Mon, 2007-06-11 at 20:59 +0100, Pedro Alves wrote: >> Danny Backx wrote:
> You're right in mentioning that the fwprintf type functions should not > be used from cegcc, because their notion of FILE * comes from coredll > and is incompatible with newlib. > > I knew that but failed to notice it when I sent this message. > > However, there are quite a few other functions that don't have this > problem. Examples are (obviously swprintf), swscanf, wcstod, wcstol, > wcscat, wcschr, wcslen, .. . Again, see <tchar.h> . > Well, what about these kinds of problems? "This could be problematic. Eg: sprintf from newlib accepts a few c99 formatters, while coredll doesn't, which means you would get a discrepancy between the sprintf/swprintf. E.g.: %lld." > A problem I see when inspecting this list is that e.g. wcstol isn't in > our cegcc.dll but wcslen is. Inconsistet. > What do you mean by is in our cegcc.dll or not? Are you looking at output from nm ? > My suggestion : > - Document why we don't have e.g. swprintf in the cegcc universe's > include files > - After the next release, try to figure out what to do about > inconsistencies like the ones I just found. > Ok with me. I don't strongly object against declaring those functions somewhere on the cegcc side. >> When you use cegcc, you are programming on an abstraction on top of coredll. >> The original newlib usage came from a need to develop console/server apps, >> usually ports of unix software. I really recommend to switch to mingw32ce >> for new apps and ports. > > The "and ports" part of this sentence is probably very good advice, but > sometimes very (too ?) hard to accomplish. > There are several categories of problem when porting to CE. Usually they are solved over and over again using the same methods. Perhaps we should document them, in a "how to port" kind of guide. - The missing errno. - The missing notion of cwd. - Missing getopt. - Missing child/parent IPC (pipes). - Others I don't remember off hand. Several problems are solved by importing code into the project. Eg: The missing getopt, is easilly solved by using a getopt from any BSD variant. I'm currently testing freegetopt to build a heavily reduced WinCE version of busybox. Hopefully with busybox we'll have rm, mv, mkdir, etc. With some work, busybox's ash may work too. Cheers, Pedro Alves ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ Cegcc-devel mailing list Cegcc-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/cegcc-devel