Re: [PD-dev] Win32 - unicode support for files, with public API for externals

2012-12-18 Thread Hans-Christoph Steiner
Yeah, let's skip Solaris support. The current version you just pushed works for me. .hc On Dec 18, 2012, at 12:57 PM, Miller Puckette wrote: > OK... my suggestion would be just to try not to worry about Solaris :) > > M > > On Tue, Dec 18, 2012 at 06:54:29PM +0100, IOhannes m zmoelnig wrote:

Re: [PD-dev] Win32 - unicode support for files, with public API for externals

2012-12-18 Thread Miller Puckette
OK... my suggestion would be just to try not to worry about Solaris :) M On Tue, Dec 18, 2012 at 06:54:29PM +0100, IOhannes m zmoelnig wrote: > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA1 > > On 2012-12-18 18:44, Miller Puckette wrote: > > OK.. so how's this: > > > > For close I'll just edi

Re: [PD-dev] Win32 - unicode support for files, with public API for externals

2012-12-18 Thread IOhannes m zmoelnig
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 2012-12-18 18:44, Miller Puckette wrote: > OK.. so how's this: > > For close I'll just edit in your sys_close hack :) good. > > For sys_open, let's just unconditionally say: > > int imode = va_arg (ap, int); mode=(mode_t)imode; > > without the

Re: [PD-dev] Win32 - unicode support for files, with public API for externals

2012-12-18 Thread Miller Puckette
try out what I just pushed which is probably no worse than Hannes's.. cheers M On Tue, Dec 18, 2012 at 06:42:17PM +0100, IOhannes m zmoelnig wrote: > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA1 > > On 2012-12-18 18:22, Hans-Christoph Steiner wrote: > > /* close a previously opened file this

Re: [PD-dev] Win32 - unicode support for files, with public API for externals

2012-12-18 Thread Miller Puckette
OK.. so how's this: For close I'll just edit in your sys_close hack :) For sys_open, let's just unconditionally say: int imode = va_arg (ap, int); mode=(mode_t)imode; without the surrounding if(sizeof(mode_t) < sizeof(int)). I'll hack that in by hand and push to see how

Re: [PD-dev] Win32 - unicode support for files, with public API for externals

2012-12-18 Thread IOhannes m zmoelnig
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 2012-12-18 18:22, Hans-Christoph Steiner wrote: > /* close a previously opened file this is needed on platforms where > you cannot open/close resources across dll-boundaries */ int > sys_close(int fd) { #ifdef _WIN32 return _close(fd); #else return

Re: [PD-dev] Win32 - unicode support for files, with public API for externals

2012-12-18 Thread Hans-Christoph Steiner
Windows is most definitely not POSIX compliant. If it was, we wouldn't be having this discussion since the Win32 open() would just work. It has lots POSIX compliant things, but is also missing many key ones. For example, WIN32 does not define any of the POSIX open() flags (O_CREAT, O_TRUNC,

Re: [PD-dev] Win32 - unicode support for files, with public API for externals

2012-12-18 Thread Miller Puckette
... but if POSIX has a close() I think there's no issue here - MSW is POSIX compliant, they say, and hence they're committeed to maintaining close(). So I think it's fine just to use close() and not have a sys_close() at all (or if someone is actually using sys_close() we choud just: > int sys_clo

Re: [PD-dev] Win32 - unicode support for files, with public API for externals

2012-12-18 Thread Hans-Christoph Steiner
On Dec 18, 2012, at 4:56 AM, IOhannes m zmölnig wrote: > On 12/18/2012 04:40, Hans-Christoph Steiner wrote: >> >> I think this approach works. > > thanks > >> The patch you provided seems totally untested, as in not even compiled on >> GNU/Linux or Mac OS X. It includes the _close() function

Re: [PD-dev] Win32 - unicode support for files, with public API for externals

2012-12-18 Thread IOhannes m zmölnig
On 12/18/2012 04:40, Hans-Christoph Steiner wrote: I think this approach works. thanks The patch you provided seems totally untested, as in not even compiled on GNU/Linux or Mac OS X. It includes the _close() function in sys_close() which only works on Win32 and it gives this warning when

Re: [PD-dev] Win32 - unicode support for files, with public API for externals

2012-12-17 Thread Hans-Christoph Steiner
On Dec 17, 2012, at 6:05 AM, IOhannes m zmoelnig wrote: > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA1 > > On 2012-12-17 10:55, IOhannes m zmoelnig wrote: >> this makes packaging externals for e.g. Debian a nightmare, as it >> basically should trigger a .so-name change, but since we are >> l

Re: [PD-dev] Win32 - unicode support for files, with public API for externals

2012-12-17 Thread IOhannes m zmoelnig
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On 2012-12-17 10:55, IOhannes m zmoelnig wrote: > this makes packaging externals for e.g. Debian a nightmare, as it > basically should trigger a .so-name change, but since we are > linking against the application instead of an ordinary library, all >

Re: [PD-dev] Win32 - unicode support for files, with public API for externals

2012-12-17 Thread IOhannes m zmoelnig
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 the recent commit 78b81aa3cb90 on the puredata/master branch breaks ABI compatibility with externals compiled for Pd-0.43. the problem is that the "sys_close()" symbol is removed for non-w32 platforms. therefore all the externals on non-w32 that (alre