Building on Windows with a focus on generating PDB files

classic Classic list List threaded Threaded
11 messages Options
Reply | Threaded
Open this post in threaded view
|

Building on Windows with a focus on generating PDB files

Ben Rush
I have a desire to build Gstreamer on Windows, more specifically a debug build so that I can track down some crashes that are occurring. Unfortunately, it seems as though this isn't a thing that's well-traveled, or I'm at least getting conflicting information on forums and blog posts about the process. I thought I'd ask on here about the latest state of things since blog posts/forum posts can be depreciated quickly with updates. I'm cool with RTFM, but some sources I'm reading say the manual itself is out of date. 

For example, a couple of blog posts (such as this one:  https://cardinalpeak.com/blog/build-gstreamer-on-windows-an-advanced-tutorial/) that don't appear too old, mention the existing instructions are, and I quote, "woefully out of date" (presumably when specifically targeting Windows) and that the task is "fairly complex". There are Windows builds, and so presumably there is a well-tested method for generating these binaries on Windows. If so, surely there are well-tested steps out there for doing what I want. But if instructions available to me (I'm assuming this blog post meant the official instructions) are out of date, I'd like to keep that in mind as I'm using them. Or if HE is wrong, I'd like to know that. And if the official instructions are NOT out of date, I'm wondering if anyone has had any luck using them to generate any other than release builds? 

Any advice? Pointers? Feedback? Thanks for your time. 



_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Building on Windows with a focus on generating PDB files

David Ing
The official Windows binaries are built using this tool:   https://gitlab.freedesktop.org/gstreamer/cerbero

The official WIndows binaries are built on a Windows machine, although it is possible to build the mingw binaries from Linux using a cross-compile (through cerbero).  The MSVC build is great because it provides *.pdb files, but not all components can be built using msvc, the remainder are built via mingw.  Unfortunately, building on a WIndows machine takes a really really really long time.  (The cross-compile from Linux is much faster.)

With Cerbero, the 1.16 branches use a very old version of the mingw toolchain.  The master branch uses a newer version of the mingw toolchain.

There are a number of known bugs with the Windows version of gstreamer which do not exist on Linux.  (I do not know if anybody is maintaining a list of those bugs.)

On Thu, Sep 5, 2019 at 11:51 AM Ben Rush <[hidden email]> wrote:
I have a desire to build Gstreamer on Windows, more specifically a debug build so that I can track down some crashes that are occurring. Unfortunately, it seems as though this isn't a thing that's well-traveled, or I'm at least getting conflicting information on forums and blog posts about the process. I thought I'd ask on here about the latest state of things since blog posts/forum posts can be depreciated quickly with updates. I'm cool with RTFM, but some sources I'm reading say the manual itself is out of date. 

For example, a couple of blog posts (such as this one:  https://cardinalpeak.com/blog/build-gstreamer-on-windows-an-advanced-tutorial/) that don't appear too old, mention the existing instructions are, and I quote, "woefully out of date" (presumably when specifically targeting Windows) and that the task is "fairly complex". There are Windows builds, and so presumably there is a well-tested method for generating these binaries on Windows. If so, surely there are well-tested steps out there for doing what I want. But if instructions available to me (I'm assuming this blog post meant the official instructions) are out of date, I'd like to keep that in mind as I'm using them. Or if HE is wrong, I'd like to know that. And if the official instructions are NOT out of date, I'm wondering if anyone has had any luck using them to generate any other than release builds? 

Any advice? Pointers? Feedback? Thanks for your time. 


_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Building on Windows with a focus on generating PDB files

Ben Rush
Hi, thanks, David. I really appreciate your response. That clears up a lot. 

So, this brings me to a straightforward question: is GStreamer generally more stable on Linux than Windows? Or at least, more used? I ask not to be negative but to essentially confirm a belief I have picked up after using it on Windows for a while. Honestly, I have dealt with quite a few more ephemeral issues: random access violations, performance issues, etc. on Windows than I have on Linux. Also, comments about it taking so long to build on Windows, and that there are known bugs that people are potentially not tracking, also makes me think Windows isn't as much the focus. 

None of this is meant to be negative (honest), and I definitely believe major products are using it on Windows, but I'm just curious if there is a basis for these feelings? That perhaps getting it to work as well on Windows as it does on Linux perhaps simply means more work for me. 

Thanks again. 

On Thu, Sep 5, 2019 at 2:43 PM David Ing <[hidden email]> wrote:
The official Windows binaries are built using this tool:   https://gitlab.freedesktop.org/gstreamer/cerbero

The official WIndows binaries are built on a Windows machine, although it is possible to build the mingw binaries from Linux using a cross-compile (through cerbero).  The MSVC build is great because it provides *.pdb files, but not all components can be built using msvc, the remainder are built via mingw.  Unfortunately, building on a WIndows machine takes a really really really long time.  (The cross-compile from Linux is much faster.)

With Cerbero, the 1.16 branches use a very old version of the mingw toolchain.  The master branch uses a newer version of the mingw toolchain.

There are a number of known bugs with the Windows version of gstreamer which do not exist on Linux.  (I do not know if anybody is maintaining a list of those bugs.)

On Thu, Sep 5, 2019 at 11:51 AM Ben Rush <[hidden email]> wrote:
I have a desire to build Gstreamer on Windows, more specifically a debug build so that I can track down some crashes that are occurring. Unfortunately, it seems as though this isn't a thing that's well-traveled, or I'm at least getting conflicting information on forums and blog posts about the process. I thought I'd ask on here about the latest state of things since blog posts/forum posts can be depreciated quickly with updates. I'm cool with RTFM, but some sources I'm reading say the manual itself is out of date. 

For example, a couple of blog posts (such as this one:  https://cardinalpeak.com/blog/build-gstreamer-on-windows-an-advanced-tutorial/) that don't appear too old, mention the existing instructions are, and I quote, "woefully out of date" (presumably when specifically targeting Windows) and that the task is "fairly complex". There are Windows builds, and so presumably there is a well-tested method for generating these binaries on Windows. If so, surely there are well-tested steps out there for doing what I want. But if instructions available to me (I'm assuming this blog post meant the official instructions) are out of date, I'd like to keep that in mind as I'm using them. Or if HE is wrong, I'd like to know that. And if the official instructions are NOT out of date, I'm wondering if anyone has had any luck using them to generate any other than release builds? 

Any advice? Pointers? Feedback? Thanks for your time. 


_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Building on Windows with a focus on generating PDB files

David Ing
I have observed that most of the core Gstreamer developers use Fedora 30, and they don't really have a chance to notice Windows-specific problems.  I think they tend to focus on Linux (especially Fedora 30).  But one of the core developers (Nirbheek from Centricular) has done a lot of work on getting the MSVC build to work.

Community members (like us) should try to report and help with Windows stuff.  This is easier now that *.pdb files are available.

I definitely notice better performance and fewer bugs when I run on Fedora 30 (compared to Windows).  I am not sure why performance is better on Linux.  It might have something to do with the ORC (runtime compiler for inner loops), but I am just guessing.  I have also noticed that the VS debugger causes some kind of heap corruption when debugging a process which contains managed together with native gstreamer code (mingw).  Take away the managed code layer and the heap corruption goes away.  I am not sure why this happens.

You should definitely try and work on Fedora 30 if you can.  Here is some setup for the official build:  https://gitlab.freedesktop.org/gstreamer/gst-ci/tree/master/docker/fedora

I wonder if this link is related to the official Windows build?  https://gitlab.freedesktop.org/gstreamer/gst-ci/tree/master/docker/windows

On Thu, Sep 5, 2019 at 1:36 PM Ben Rush <[hidden email]> wrote:
Hi, thanks, David. I really appreciate your response. That clears up a lot. 

So, this brings me to a straightforward question: is GStreamer generally more stable on Linux than Windows? Or at least, more used? I ask not to be negative but to essentially confirm a belief I have picked up after using it on Windows for a while. Honestly, I have dealt with quite a few more ephemeral issues: random access violations, performance issues, etc. on Windows than I have on Linux. Also, comments about it taking so long to build on Windows, and that there are known bugs that people are potentially not tracking, also makes me think Windows isn't as much the focus. 

None of this is meant to be negative (honest), and I definitely believe major products are using it on Windows, but I'm just curious if there is a basis for these feelings? That perhaps getting it to work as well on Windows as it does on Linux perhaps simply means more work for me. 

Thanks again. 

On Thu, Sep 5, 2019 at 2:43 PM David Ing <[hidden email]> wrote:
The official Windows binaries are built using this tool:   https://gitlab.freedesktop.org/gstreamer/cerbero

The official WIndows binaries are built on a Windows machine, although it is possible to build the mingw binaries from Linux using a cross-compile (through cerbero).  The MSVC build is great because it provides *.pdb files, but not all components can be built using msvc, the remainder are built via mingw.  Unfortunately, building on a WIndows machine takes a really really really long time.  (The cross-compile from Linux is much faster.)

With Cerbero, the 1.16 branches use a very old version of the mingw toolchain.  The master branch uses a newer version of the mingw toolchain.

There are a number of known bugs with the Windows version of gstreamer which do not exist on Linux.  (I do not know if anybody is maintaining a list of those bugs.)

On Thu, Sep 5, 2019 at 11:51 AM Ben Rush <[hidden email]> wrote:
I have a desire to build Gstreamer on Windows, more specifically a debug build so that I can track down some crashes that are occurring. Unfortunately, it seems as though this isn't a thing that's well-traveled, or I'm at least getting conflicting information on forums and blog posts about the process. I thought I'd ask on here about the latest state of things since blog posts/forum posts can be depreciated quickly with updates. I'm cool with RTFM, but some sources I'm reading say the manual itself is out of date. 

For example, a couple of blog posts (such as this one:  https://cardinalpeak.com/blog/build-gstreamer-on-windows-an-advanced-tutorial/) that don't appear too old, mention the existing instructions are, and I quote, "woefully out of date" (presumably when specifically targeting Windows) and that the task is "fairly complex". There are Windows builds, and so presumably there is a well-tested method for generating these binaries on Windows. If so, surely there are well-tested steps out there for doing what I want. But if instructions available to me (I'm assuming this blog post meant the official instructions) are out of date, I'd like to keep that in mind as I'm using them. Or if HE is wrong, I'd like to know that. And if the official instructions are NOT out of date, I'm wondering if anyone has had any luck using them to generate any other than release builds? 

Any advice? Pointers? Feedback? Thanks for your time. 


_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Building on Windows with a focus on generating PDB files

Nicolas Dufresne-5
In reply to this post by Ben Rush


Le jeu. 5 sept. 2019 16 h 40, Ben Rush <[hidden email]> a écrit :
Hi, thanks, David. I really appreciate your response. That clears up a lot. 

So, this brings me to a straightforward question: is GStreamer generally more stable on Linux than Windows? Or at least, more used? I ask not to be negative but to essentially confirm a belief I have picked up after using it on Windows for a while. Honestly, I have dealt with quite a few more ephemeral issues: random access violations, performance issues, etc. on Windows than I have on Linux. Also, comments about it taking so long to build on Windows, and that there are known bugs that people are potentially not tracking, also makes me think Windows isn't as much the focus. 

None of this is meant to be negative (honest), and I definitely believe major products are using it on Windows, but I'm just curious if there is a basis for these feelings? That perhaps getting it to work as well on Windows as it does on Linux perhaps simply means more work for me. 

It always depends on what features you are using. But even though windows maintenance is getting bigger, CI now exist and may be able to run automatically in near future, the level or maintenance and testing remains bigger on Linux then any other platforms.

Best is do bring some specific case, specific plugins and from there we can guide you through the known issues, or toward different solutions. It may also just help bringing some attention to specific issue. We have around 3K issues filed in gitlab, so of course we don't remember all of them, and may not hit them in our day to day work.


Thanks again. 

On Thu, Sep 5, 2019 at 2:43 PM David Ing <[hidden email]> wrote:
The official Windows binaries are built using this tool:   https://gitlab.freedesktop.org/gstreamer/cerbero

The official WIndows binaries are built on a Windows machine, although it is possible to build the mingw binaries from Linux using a cross-compile (through cerbero).  The MSVC build is great because it provides *.pdb files, but not all components can be built using msvc, the remainder are built via mingw.  Unfortunately, building on a WIndows machine takes a really really really long time.  (The cross-compile from Linux is much faster.)

With Cerbero, the 1.16 branches use a very old version of the mingw toolchain.  The master branch uses a newer version of the mingw toolchain.

There are a number of known bugs with the Windows version of gstreamer which do not exist on Linux.  (I do not know if anybody is maintaining a list of those bugs.)

On Thu, Sep 5, 2019 at 11:51 AM Ben Rush <[hidden email]> wrote:
I have a desire to build Gstreamer on Windows, more specifically a debug build so that I can track down some crashes that are occurring. Unfortunately, it seems as though this isn't a thing that's well-traveled, or I'm at least getting conflicting information on forums and blog posts about the process. I thought I'd ask on here about the latest state of things since blog posts/forum posts can be depreciated quickly with updates. I'm cool with RTFM, but some sources I'm reading say the manual itself is out of date. 

For example, a couple of blog posts (such as this one:  https://cardinalpeak.com/blog/build-gstreamer-on-windows-an-advanced-tutorial/) that don't appear too old, mention the existing instructions are, and I quote, "woefully out of date" (presumably when specifically targeting Windows) and that the task is "fairly complex". There are Windows builds, and so presumably there is a well-tested method for generating these binaries on Windows. If so, surely there are well-tested steps out there for doing what I want. But if instructions available to me (I'm assuming this blog post meant the official instructions) are out of date, I'd like to keep that in mind as I'm using them. Or if HE is wrong, I'd like to know that. And if the official instructions are NOT out of date, I'm wondering if anyone has had any luck using them to generate any other than release builds? 

Any advice? Pointers? Feedback? Thanks for your time. 


_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Building on Windows with a focus on generating PDB files

Ben Rush
In reply to this post by David Ing
A few remarks: 

1) You said "now that *.pdb files are available", is this when we build it ourselves or are they actually available for download? If they're available for download, I would love to have them as I'm encountering an issue right now that could benefit from the insight a nice stack trace would offer (perhaps I simply missed the PDBs somewhere), 
2) In terms of managed code interop'ing with GStreamer: yes, I have noticed this as well. However, I'm not convinced it's simply GStreamer, but I think anything that is perhaps built with mingw, and I'm not sure as though it's simply the debugger, as I have noticed a great many access violations when wrapping Gstreamer in C++ CLR. In fact, I had to rewrite our entire product to be native VC++ from C++ CLR due to the random errors I was getting. The code didn't really change (it was in C++, after all), but it was just no longer accessible from C# and no longer was blowing up randomly. 

I'm hoping I can help improve this platform for Windows. Because it's a damn cool platform. I just need it to run better on Windows. 

On Thu, Sep 5, 2019 at 4:26 PM David Ing <[hidden email]> wrote:
I have observed that most of the core Gstreamer developers use Fedora 30, and they don't really have a chance to notice Windows-specific problems.  I think they tend to focus on Linux (especially Fedora 30).  But one of the core developers (Nirbheek from Centricular) has done a lot of work on getting the MSVC build to work.

Community members (like us) should try to report and help with Windows stuff.  This is easier now that *.pdb files are available.

I definitely notice better performance and fewer bugs when I run on Fedora 30 (compared to Windows).  I am not sure why performance is better on Linux.  It might have something to do with the ORC (runtime compiler for inner loops), but I am just guessing.  I have also noticed that the VS debugger causes some kind of heap corruption when debugging a process which contains managed together with native gstreamer code (mingw).  Take away the managed code layer and the heap corruption goes away.  I am not sure why this happens.

You should definitely try and work on Fedora 30 if you can.  Here is some setup for the official build:  https://gitlab.freedesktop.org/gstreamer/gst-ci/tree/master/docker/fedora

I wonder if this link is related to the official Windows build?  https://gitlab.freedesktop.org/gstreamer/gst-ci/tree/master/docker/windows

On Thu, Sep 5, 2019 at 1:36 PM Ben Rush <[hidden email]> wrote:
Hi, thanks, David. I really appreciate your response. That clears up a lot. 

So, this brings me to a straightforward question: is GStreamer generally more stable on Linux than Windows? Or at least, more used? I ask not to be negative but to essentially confirm a belief I have picked up after using it on Windows for a while. Honestly, I have dealt with quite a few more ephemeral issues: random access violations, performance issues, etc. on Windows than I have on Linux. Also, comments about it taking so long to build on Windows, and that there are known bugs that people are potentially not tracking, also makes me think Windows isn't as much the focus. 

None of this is meant to be negative (honest), and I definitely believe major products are using it on Windows, but I'm just curious if there is a basis for these feelings? That perhaps getting it to work as well on Windows as it does on Linux perhaps simply means more work for me. 

Thanks again. 

On Thu, Sep 5, 2019 at 2:43 PM David Ing <[hidden email]> wrote:
The official Windows binaries are built using this tool:   https://gitlab.freedesktop.org/gstreamer/cerbero

The official WIndows binaries are built on a Windows machine, although it is possible to build the mingw binaries from Linux using a cross-compile (through cerbero).  The MSVC build is great because it provides *.pdb files, but not all components can be built using msvc, the remainder are built via mingw.  Unfortunately, building on a WIndows machine takes a really really really long time.  (The cross-compile from Linux is much faster.)

With Cerbero, the 1.16 branches use a very old version of the mingw toolchain.  The master branch uses a newer version of the mingw toolchain.

There are a number of known bugs with the Windows version of gstreamer which do not exist on Linux.  (I do not know if anybody is maintaining a list of those bugs.)

On Thu, Sep 5, 2019 at 11:51 AM Ben Rush <[hidden email]> wrote:
I have a desire to build Gstreamer on Windows, more specifically a debug build so that I can track down some crashes that are occurring. Unfortunately, it seems as though this isn't a thing that's well-traveled, or I'm at least getting conflicting information on forums and blog posts about the process. I thought I'd ask on here about the latest state of things since blog posts/forum posts can be depreciated quickly with updates. I'm cool with RTFM, but some sources I'm reading say the manual itself is out of date. 

For example, a couple of blog posts (such as this one:  https://cardinalpeak.com/blog/build-gstreamer-on-windows-an-advanced-tutorial/) that don't appear too old, mention the existing instructions are, and I quote, "woefully out of date" (presumably when specifically targeting Windows) and that the task is "fairly complex". There are Windows builds, and so presumably there is a well-tested method for generating these binaries on Windows. If so, surely there are well-tested steps out there for doing what I want. But if instructions available to me (I'm assuming this blog post meant the official instructions) are out of date, I'd like to keep that in mind as I'm using them. Or if HE is wrong, I'd like to know that. And if the official instructions are NOT out of date, I'm wondering if anyone has had any luck using them to generate any other than release builds? 

Any advice? Pointers? Feedback? Thanks for your time. 


_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Building on Windows with a focus on generating PDB files

David Ing
Yes, you can download PDB files with the published MSVC build for version 1.16.0 here:   https://gstreamer.freedesktop.org/download/  I typically install the runtime installer and the development installer (the PDB files come from one of those).  You will notice that some modules don't have a *.pdb files (those are probably built with mingw).

We are eliminating C++ CLI because we are targetting .NET Core and migrating to Linux (from Windows).  We are P-Invoking everything because C++ CLI isn't friendly with .NET Core (and Linux).  We have observed VS Debugger heap corruption, even when using P-Invoke (without any C++ CLI whatsoever).  But our errors go away when the VS Debugger is taken out of the equation.  And we can use the VS Debugger if Native Code Debugging is turned off.  I agree that it might be a "mingw" thing because I am using "ucrtbase.dll" and not "msvcrt.dll".


On Thu, Sep 5, 2019 at 2:54 PM Ben Rush <[hidden email]> wrote:
A few remarks: 

1) You said "now that *.pdb files are available", is this when we build it ourselves or are they actually available for download? If they're available for download, I would love to have them as I'm encountering an issue right now that could benefit from the insight a nice stack trace would offer (perhaps I simply missed the PDBs somewhere), 
2) In terms of managed code interop'ing with GStreamer: yes, I have noticed this as well. However, I'm not convinced it's simply GStreamer, but I think anything that is perhaps built with mingw, and I'm not sure as though it's simply the debugger, as I have noticed a great many access violations when wrapping Gstreamer in C++ CLR. In fact, I had to rewrite our entire product to be native VC++ from C++ CLR due to the random errors I was getting. The code didn't really change (it was in C++, after all), but it was just no longer accessible from C# and no longer was blowing up randomly. 

I'm hoping I can help improve this platform for Windows. Because it's a damn cool platform. I just need it to run better on Windows. 

On Thu, Sep 5, 2019 at 4:26 PM David Ing <[hidden email]> wrote:
I have observed that most of the core Gstreamer developers use Fedora 30, and they don't really have a chance to notice Windows-specific problems.  I think they tend to focus on Linux (especially Fedora 30).  But one of the core developers (Nirbheek from Centricular) has done a lot of work on getting the MSVC build to work.

Community members (like us) should try to report and help with Windows stuff.  This is easier now that *.pdb files are available.

I definitely notice better performance and fewer bugs when I run on Fedora 30 (compared to Windows).  I am not sure why performance is better on Linux.  It might have something to do with the ORC (runtime compiler for inner loops), but I am just guessing.  I have also noticed that the VS debugger causes some kind of heap corruption when debugging a process which contains managed together with native gstreamer code (mingw).  Take away the managed code layer and the heap corruption goes away.  I am not sure why this happens.

You should definitely try and work on Fedora 30 if you can.  Here is some setup for the official build:  https://gitlab.freedesktop.org/gstreamer/gst-ci/tree/master/docker/fedora

I wonder if this link is related to the official Windows build?  https://gitlab.freedesktop.org/gstreamer/gst-ci/tree/master/docker/windows

On Thu, Sep 5, 2019 at 1:36 PM Ben Rush <[hidden email]> wrote:
Hi, thanks, David. I really appreciate your response. That clears up a lot. 

So, this brings me to a straightforward question: is GStreamer generally more stable on Linux than Windows? Or at least, more used? I ask not to be negative but to essentially confirm a belief I have picked up after using it on Windows for a while. Honestly, I have dealt with quite a few more ephemeral issues: random access violations, performance issues, etc. on Windows than I have on Linux. Also, comments about it taking so long to build on Windows, and that there are known bugs that people are potentially not tracking, also makes me think Windows isn't as much the focus. 

None of this is meant to be negative (honest), and I definitely believe major products are using it on Windows, but I'm just curious if there is a basis for these feelings? That perhaps getting it to work as well on Windows as it does on Linux perhaps simply means more work for me. 

Thanks again. 

On Thu, Sep 5, 2019 at 2:43 PM David Ing <[hidden email]> wrote:
The official Windows binaries are built using this tool:   https://gitlab.freedesktop.org/gstreamer/cerbero

The official WIndows binaries are built on a Windows machine, although it is possible to build the mingw binaries from Linux using a cross-compile (through cerbero).  The MSVC build is great because it provides *.pdb files, but not all components can be built using msvc, the remainder are built via mingw.  Unfortunately, building on a WIndows machine takes a really really really long time.  (The cross-compile from Linux is much faster.)

With Cerbero, the 1.16 branches use a very old version of the mingw toolchain.  The master branch uses a newer version of the mingw toolchain.

There are a number of known bugs with the Windows version of gstreamer which do not exist on Linux.  (I do not know if anybody is maintaining a list of those bugs.)

On Thu, Sep 5, 2019 at 11:51 AM Ben Rush <[hidden email]> wrote:
I have a desire to build Gstreamer on Windows, more specifically a debug build so that I can track down some crashes that are occurring. Unfortunately, it seems as though this isn't a thing that's well-traveled, or I'm at least getting conflicting information on forums and blog posts about the process. I thought I'd ask on here about the latest state of things since blog posts/forum posts can be depreciated quickly with updates. I'm cool with RTFM, but some sources I'm reading say the manual itself is out of date. 

For example, a couple of blog posts (such as this one:  https://cardinalpeak.com/blog/build-gstreamer-on-windows-an-advanced-tutorial/) that don't appear too old, mention the existing instructions are, and I quote, "woefully out of date" (presumably when specifically targeting Windows) and that the task is "fairly complex". There are Windows builds, and so presumably there is a well-tested method for generating these binaries on Windows. If so, surely there are well-tested steps out there for doing what I want. But if instructions available to me (I'm assuming this blog post meant the official instructions) are out of date, I'd like to keep that in mind as I'm using them. Or if HE is wrong, I'd like to know that. And if the official instructions are NOT out of date, I'm wondering if anyone has had any luck using them to generate any other than release builds? 

Any advice? Pointers? Feedback? Thanks for your time. 


_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Building on Windows with a focus on generating PDB files

Ben Rush
I also think there might be a pthread thing -- I'm not sure it mixes well with .NET threads/fibers. 

On Thu, Sep 5, 2019 at 5:47 PM David Ing <[hidden email]> wrote:
Yes, you can download PDB files with the published MSVC build for version 1.16.0 here:   https://gstreamer.freedesktop.org/download/  I typically install the runtime installer and the development installer (the PDB files come from one of those).  You will notice that some modules don't have a *.pdb files (those are probably built with mingw).

We are eliminating C++ CLI because we are targetting .NET Core and migrating to Linux (from Windows).  We are P-Invoking everything because C++ CLI isn't friendly with .NET Core (and Linux).  We have observed VS Debugger heap corruption, even when using P-Invoke (without any C++ CLI whatsoever).  But our errors go away when the VS Debugger is taken out of the equation.  And we can use the VS Debugger if Native Code Debugging is turned off.  I agree that it might be a "mingw" thing because I am using "ucrtbase.dll" and not "msvcrt.dll".


On Thu, Sep 5, 2019 at 2:54 PM Ben Rush <[hidden email]> wrote:
A few remarks: 

1) You said "now that *.pdb files are available", is this when we build it ourselves or are they actually available for download? If they're available for download, I would love to have them as I'm encountering an issue right now that could benefit from the insight a nice stack trace would offer (perhaps I simply missed the PDBs somewhere), 
2) In terms of managed code interop'ing with GStreamer: yes, I have noticed this as well. However, I'm not convinced it's simply GStreamer, but I think anything that is perhaps built with mingw, and I'm not sure as though it's simply the debugger, as I have noticed a great many access violations when wrapping Gstreamer in C++ CLR. In fact, I had to rewrite our entire product to be native VC++ from C++ CLR due to the random errors I was getting. The code didn't really change (it was in C++, after all), but it was just no longer accessible from C# and no longer was blowing up randomly. 

I'm hoping I can help improve this platform for Windows. Because it's a damn cool platform. I just need it to run better on Windows. 

On Thu, Sep 5, 2019 at 4:26 PM David Ing <[hidden email]> wrote:
I have observed that most of the core Gstreamer developers use Fedora 30, and they don't really have a chance to notice Windows-specific problems.  I think they tend to focus on Linux (especially Fedora 30).  But one of the core developers (Nirbheek from Centricular) has done a lot of work on getting the MSVC build to work.

Community members (like us) should try to report and help with Windows stuff.  This is easier now that *.pdb files are available.

I definitely notice better performance and fewer bugs when I run on Fedora 30 (compared to Windows).  I am not sure why performance is better on Linux.  It might have something to do with the ORC (runtime compiler for inner loops), but I am just guessing.  I have also noticed that the VS debugger causes some kind of heap corruption when debugging a process which contains managed together with native gstreamer code (mingw).  Take away the managed code layer and the heap corruption goes away.  I am not sure why this happens.

You should definitely try and work on Fedora 30 if you can.  Here is some setup for the official build:  https://gitlab.freedesktop.org/gstreamer/gst-ci/tree/master/docker/fedora

I wonder if this link is related to the official Windows build?  https://gitlab.freedesktop.org/gstreamer/gst-ci/tree/master/docker/windows

On Thu, Sep 5, 2019 at 1:36 PM Ben Rush <[hidden email]> wrote:
Hi, thanks, David. I really appreciate your response. That clears up a lot. 

So, this brings me to a straightforward question: is GStreamer generally more stable on Linux than Windows? Or at least, more used? I ask not to be negative but to essentially confirm a belief I have picked up after using it on Windows for a while. Honestly, I have dealt with quite a few more ephemeral issues: random access violations, performance issues, etc. on Windows than I have on Linux. Also, comments about it taking so long to build on Windows, and that there are known bugs that people are potentially not tracking, also makes me think Windows isn't as much the focus. 

None of this is meant to be negative (honest), and I definitely believe major products are using it on Windows, but I'm just curious if there is a basis for these feelings? That perhaps getting it to work as well on Windows as it does on Linux perhaps simply means more work for me. 

Thanks again. 

On Thu, Sep 5, 2019 at 2:43 PM David Ing <[hidden email]> wrote:
The official Windows binaries are built using this tool:   https://gitlab.freedesktop.org/gstreamer/cerbero

The official WIndows binaries are built on a Windows machine, although it is possible to build the mingw binaries from Linux using a cross-compile (through cerbero).  The MSVC build is great because it provides *.pdb files, but not all components can be built using msvc, the remainder are built via mingw.  Unfortunately, building on a WIndows machine takes a really really really long time.  (The cross-compile from Linux is much faster.)

With Cerbero, the 1.16 branches use a very old version of the mingw toolchain.  The master branch uses a newer version of the mingw toolchain.

There are a number of known bugs with the Windows version of gstreamer which do not exist on Linux.  (I do not know if anybody is maintaining a list of those bugs.)

On Thu, Sep 5, 2019 at 11:51 AM Ben Rush <[hidden email]> wrote:
I have a desire to build Gstreamer on Windows, more specifically a debug build so that I can track down some crashes that are occurring. Unfortunately, it seems as though this isn't a thing that's well-traveled, or I'm at least getting conflicting information on forums and blog posts about the process. I thought I'd ask on here about the latest state of things since blog posts/forum posts can be depreciated quickly with updates. I'm cool with RTFM, but some sources I'm reading say the manual itself is out of date. 

For example, a couple of blog posts (such as this one:  https://cardinalpeak.com/blog/build-gstreamer-on-windows-an-advanced-tutorial/) that don't appear too old, mention the existing instructions are, and I quote, "woefully out of date" (presumably when specifically targeting Windows) and that the task is "fairly complex". There are Windows builds, and so presumably there is a well-tested method for generating these binaries on Windows. If so, surely there are well-tested steps out there for doing what I want. But if instructions available to me (I'm assuming this blog post meant the official instructions) are out of date, I'd like to keep that in mind as I'm using them. Or if HE is wrong, I'd like to know that. And if the official instructions are NOT out of date, I'm wondering if anyone has had any luck using them to generate any other than release builds? 

Any advice? Pointers? Feedback? Thanks for your time. 


_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Building on Windows with a focus on generating PDB files

Ben Rush
In reply to this post by Nicolas Dufresne-5
I think getting the PDB files and analyzing specific cases will be important as right now my descriptions will be vague without stack traces, et al. Now that I realize there are actual PDB files, I will try to get more information. 

I also try getting a build going so that I can fix issues I find on Windows and make suggestions. 

On Thu, Sep 5, 2019 at 6:25 PM Nicolas Dufresne <[hidden email]> wrote:


Le jeu. 5 sept. 2019 16 h 40, Ben Rush <[hidden email]> a écrit :
Hi, thanks, David. I really appreciate your response. That clears up a lot. 

So, this brings me to a straightforward question: is GStreamer generally more stable on Linux than Windows? Or at least, more used? I ask not to be negative but to essentially confirm a belief I have picked up after using it on Windows for a while. Honestly, I have dealt with quite a few more ephemeral issues: random access violations, performance issues, etc. on Windows than I have on Linux. Also, comments about it taking so long to build on Windows, and that there are known bugs that people are potentially not tracking, also makes me think Windows isn't as much the focus. 

None of this is meant to be negative (honest), and I definitely believe major products are using it on Windows, but I'm just curious if there is a basis for these feelings? That perhaps getting it to work as well on Windows as it does on Linux perhaps simply means more work for me. 

It always depends on what features you are using. But even though windows maintenance is getting bigger, CI now exist and may be able to run automatically in near future, the level or maintenance and testing remains bigger on Linux then any other platforms.

Best is do bring some specific case, specific plugins and from there we can guide you through the known issues, or toward different solutions. It may also just help bringing some attention to specific issue. We have around 3K issues filed in gitlab, so of course we don't remember all of them, and may not hit them in our day to day work.


Thanks again. 

On Thu, Sep 5, 2019 at 2:43 PM David Ing <[hidden email]> wrote:
The official Windows binaries are built using this tool:   https://gitlab.freedesktop.org/gstreamer/cerbero

The official WIndows binaries are built on a Windows machine, although it is possible to build the mingw binaries from Linux using a cross-compile (through cerbero).  The MSVC build is great because it provides *.pdb files, but not all components can be built using msvc, the remainder are built via mingw.  Unfortunately, building on a WIndows machine takes a really really really long time.  (The cross-compile from Linux is much faster.)

With Cerbero, the 1.16 branches use a very old version of the mingw toolchain.  The master branch uses a newer version of the mingw toolchain.

There are a number of known bugs with the Windows version of gstreamer which do not exist on Linux.  (I do not know if anybody is maintaining a list of those bugs.)

On Thu, Sep 5, 2019 at 11:51 AM Ben Rush <[hidden email]> wrote:
I have a desire to build Gstreamer on Windows, more specifically a debug build so that I can track down some crashes that are occurring. Unfortunately, it seems as though this isn't a thing that's well-traveled, or I'm at least getting conflicting information on forums and blog posts about the process. I thought I'd ask on here about the latest state of things since blog posts/forum posts can be depreciated quickly with updates. I'm cool with RTFM, but some sources I'm reading say the manual itself is out of date. 

For example, a couple of blog posts (such as this one:  https://cardinalpeak.com/blog/build-gstreamer-on-windows-an-advanced-tutorial/) that don't appear too old, mention the existing instructions are, and I quote, "woefully out of date" (presumably when specifically targeting Windows) and that the task is "fairly complex". There are Windows builds, and so presumably there is a well-tested method for generating these binaries on Windows. If so, surely there are well-tested steps out there for doing what I want. But if instructions available to me (I'm assuming this blog post meant the official instructions) are out of date, I'd like to keep that in mind as I'm using them. Or if HE is wrong, I'd like to know that. And if the official instructions are NOT out of date, I'm wondering if anyone has had any luck using them to generate any other than release builds? 

Any advice? Pointers? Feedback? Thanks for your time. 


_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Building on Windows with a focus on generating PDB files

Ben Rush
...for example, this is basically all the information I have without the PDB files at the moment for an error I'm encountering. I will try getting those PDB files soon and figuring this out: 

image.png

On Thu, Sep 5, 2019 at 7:00 PM Ben Rush <[hidden email]> wrote:
I think getting the PDB files and analyzing specific cases will be important as right now my descriptions will be vague without stack traces, et al. Now that I realize there are actual PDB files, I will try to get more information. 

I also try getting a build going so that I can fix issues I find on Windows and make suggestions. 

On Thu, Sep 5, 2019 at 6:25 PM Nicolas Dufresne <[hidden email]> wrote:


Le jeu. 5 sept. 2019 16 h 40, Ben Rush <[hidden email]> a écrit :
Hi, thanks, David. I really appreciate your response. That clears up a lot. 

So, this brings me to a straightforward question: is GStreamer generally more stable on Linux than Windows? Or at least, more used? I ask not to be negative but to essentially confirm a belief I have picked up after using it on Windows for a while. Honestly, I have dealt with quite a few more ephemeral issues: random access violations, performance issues, etc. on Windows than I have on Linux. Also, comments about it taking so long to build on Windows, and that there are known bugs that people are potentially not tracking, also makes me think Windows isn't as much the focus. 

None of this is meant to be negative (honest), and I definitely believe major products are using it on Windows, but I'm just curious if there is a basis for these feelings? That perhaps getting it to work as well on Windows as it does on Linux perhaps simply means more work for me. 

It always depends on what features you are using. But even though windows maintenance is getting bigger, CI now exist and may be able to run automatically in near future, the level or maintenance and testing remains bigger on Linux then any other platforms.

Best is do bring some specific case, specific plugins and from there we can guide you through the known issues, or toward different solutions. It may also just help bringing some attention to specific issue. We have around 3K issues filed in gitlab, so of course we don't remember all of them, and may not hit them in our day to day work.


Thanks again. 

On Thu, Sep 5, 2019 at 2:43 PM David Ing <[hidden email]> wrote:
The official Windows binaries are built using this tool:   https://gitlab.freedesktop.org/gstreamer/cerbero

The official WIndows binaries are built on a Windows machine, although it is possible to build the mingw binaries from Linux using a cross-compile (through cerbero).  The MSVC build is great because it provides *.pdb files, but not all components can be built using msvc, the remainder are built via mingw.  Unfortunately, building on a WIndows machine takes a really really really long time.  (The cross-compile from Linux is much faster.)

With Cerbero, the 1.16 branches use a very old version of the mingw toolchain.  The master branch uses a newer version of the mingw toolchain.

There are a number of known bugs with the Windows version of gstreamer which do not exist on Linux.  (I do not know if anybody is maintaining a list of those bugs.)

On Thu, Sep 5, 2019 at 11:51 AM Ben Rush <[hidden email]> wrote:
I have a desire to build Gstreamer on Windows, more specifically a debug build so that I can track down some crashes that are occurring. Unfortunately, it seems as though this isn't a thing that's well-traveled, or I'm at least getting conflicting information on forums and blog posts about the process. I thought I'd ask on here about the latest state of things since blog posts/forum posts can be depreciated quickly with updates. I'm cool with RTFM, but some sources I'm reading say the manual itself is out of date. 

For example, a couple of blog posts (such as this one:  https://cardinalpeak.com/blog/build-gstreamer-on-windows-an-advanced-tutorial/) that don't appear too old, mention the existing instructions are, and I quote, "woefully out of date" (presumably when specifically targeting Windows) and that the task is "fairly complex". There are Windows builds, and so presumably there is a well-tested method for generating these binaries on Windows. If so, surely there are well-tested steps out there for doing what I want. But if instructions available to me (I'm assuming this blog post meant the official instructions) are out of date, I'd like to keep that in mind as I'm using them. Or if HE is wrong, I'd like to know that. And if the official instructions are NOT out of date, I'm wondering if anyone has had any luck using them to generate any other than release builds? 

Any advice? Pointers? Feedback? Thanks for your time. 


_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel

_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel
Reply | Threaded
Open this post in threaded view
|

Re: Building on Windows with a focus on generating PDB files

Nirbheek Chauhan
In reply to this post by Ben Rush
Hello Ben,

On Fri, Sep 6, 2019 at 12:25 AM Ben Rush <[hidden email]> wrote:
>
> I have a desire to build Gstreamer on Windows, more specifically a debug build so that I can track down some crashes that are occurring. Unfortunately, it seems as though this isn't a thing that's well-traveled, or I'm at least getting conflicting information on forums and blog posts about the process. I thought I'd ask on here about the latest state of things since blog posts/forum posts can be depreciated quickly with updates. I'm cool with RTFM, but some sources I'm reading say the manual itself is out of date.
>
> For example, a couple of blog posts (such as this one:  https://cardinalpeak.com/blog/build-gstreamer-on-windows-an-advanced-tutorial/) that don't appear too old,

That blog post is 3+ years old, which is ancient history at this
point. The official GStreamer 1.16 binaries are available in MinGW and
MSVC flavours: https://gstreamer.freedesktop.org/download/#windows

As David has pointed out in the thread already, these are built on
Windows and some of the plugin dependencies are still built with MinGW
since they do not use the Meson build system. You may be seeing access
violations when using one of those plugins due to MSVC-MinGW interop
issues, such as
https://gitlab.freedesktop.org/gstreamer/cerbero/issues/164. The ones
we know of will be fixed in the 1.16.1 release. All MinGW-MSVC interop
issues have been completely eliminated in git master, and will be
available in the 1.18 stable release (the 1.17.1 development release
will also likely be available sometime in October/November, and will
be accompanied with official binaries).

GStreamer is used on Windows quite extensively, especially since we
ported everything to MSVC since it provides a useful debugging and
profiling experience thanks to PDBs.

However, the majority of GStreamer developers use Linux, so issues
sometimes take time to be noticed. Building GStreamer on Windows with
Cerbero is faster than it used to be, but it's still slow. We have
plans to improve that. In the meantime, for many development
environments, gst-build is lightning-fast and has many of the
commonly-used plugins (openh264, libav/ffmpeg, x264):
https://gitlab.freedesktop.org/gstreamer/gst-build/

Cheers,
Nirbheek
_______________________________________________
gstreamer-devel mailing list
[hidden email]
https://lists.freedesktop.org/mailman/listinfo/gstreamer-devel