[gstreamer-bugs] [Bug 597662] Windows-incompatible changes in gstreamer

GStreamer (bugzilla.gnome.org) bugzilla at gnome.org
Sat Oct 31 03:04:26 PDT 2009


https://bugzilla.gnome.org/show_bug.cgi?id=597662
  GStreamer | gstreamer (core) | git

--- Comment #22 from LRN <lrn1986 at gmail.com> 2009-10-31 10:04:23 UTC ---
Phew. Sorry for the tail of old patches, but i did not master git well enough
to cut it off (or maybe i've been too lazy to do that).

Anyway, here's the proposal: use native process spawning (CreateProcess()) and
pipe I/O (CreateNamedPipe(), CreateFile(), ReadFile(), WriteFile() and
friends).

The advantage is that it has nothing to do with CRT and is not affected by CRT
incompatibility. And it is not affected by the fact that msvcrt is crippled and
cannot select() on non-socket descriptors.
Basically this patch does roughly the same that [i suspect (since i don't know
for sure)] cygwin does - implements more-or-less POSIX-compatible synchronous
file I/O using WinAPI. Not completely, mind you. It doesn't implement select()
or poll(), because gstpoll is full of win32 #ifdefs already and is perfectly
capable of selecting native handles in native way.

It's kinda ugly, because i left process spawning functionality (code ripped
from glib) in gstpluginloader.c, while it should have got a separate file, and
had to leave gst_poll_fd_read and gst_poll_fd_write in gstpoll.c, while
cross-platform I/O should not have anything in common with gstpoll (since i
didn't implement poll/select, gstpoll has to dig deep into the I/O to poll the
handles, that is why the code is still tied to gstpoll and why I/O is
implemented in gstpoll context).

Also, a few pieces of commented code here and there. And a few junk code that
does nothing. And some parts are broken/unimplemented.
I've tried to keep it backward-compatible for winsock, that is - it should work
with sockets on Windows the same way it worked before. In theory. Didn't test
that.

But bottom line is, this code works - at least i was able to run
gst-inspect-0.10 without crashing and got 186 plugins (1 blacklist entry not
shown), 919 features.

-- 
Configure bugmail: https://bugzilla.gnome.org/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.
You are the assignee for the bug.




More information about the Gstreamer-bugs mailing list