Re: [Python-Dev] a few strdup() questions...

2009-01-08 Thread Ulrich Eckhardt
On Wednesday 07 January 2009 16:30:23 Daniel Stutzbach wrote: > On Wed, Jan 7, 2009 at 5:30 AM, Ulrich Eckhardt wrote: > > MS Windows CE doesn't provide strdup(), so where should I put it? I guess > > I should just compile in Python/strdup.c, right? > > I'm not an expert on Windows CE, but I belie

Re: [Python-Dev] a few strdup() questions...

2009-01-08 Thread Thomas Heller
>> BTW: there is another implementation (called my_strdup) in >> Modules/_ctypes/_ctypes_test.c, why not use the one in Python/strdup.c there? > > I guess that's historical, from the times when ctypes was still a > separate package. my_strdup is an exported function in _ctypes_test.pyd (on Windo

Re: [Python-Dev] a few strdup() questions...

2009-01-07 Thread Martin v. Löwis
> MS Windows CE doesn't provide strdup(), so where should I put it? I guess I > should just compile in Python/strdup.c, right? Right. > However, where should I declare it? I recommend pyport.h. > Also, there is HAVE_STRDUP. I would actually expect that #undef HAVE_STRDUP > would do the trick

Re: [Python-Dev] a few strdup() questions...

2009-01-07 Thread Daniel Stutzbach
On Wed, Jan 7, 2009 at 5:30 AM, Ulrich Eckhardt wrote: > MS Windows CE doesn't provide strdup(), so where should I put it? I guess I > should just compile in Python/strdup.c, right? > I'm not an expert on Windows CE, but I believe it calls the function "_strdup()": http://msdn.microsoft.com/en-

[Python-Dev] a few strdup() questions...

2009-01-07 Thread Ulrich Eckhardt
Greetings! MS Windows CE doesn't provide strdup(), so where should I put it? I guess I should just compile in Python/strdup.c, right? However, where should I declare it? My approach would be to declare it in PC/pyconfig.h. I see that RISCOS also seems to lack that function, which is why it is