GNOME Bugzilla – Bug 492114
Build issues on Windows/MSVC
Last modified: 2007-11-01 12:54:35 UTC
Please describe the problem: gst-plugins-base doesn't build properly with Windows/MSVC (MSVS2005). There are also some symbols missing in the .def file that need to be exported. Steps to reproduce: 1. 2. 3. Actual results: Expected results: Does this happen every time? Other information:
Created attachment 98250 [details] [review] Some additional symbols need to be exported.
Created attachment 98251 [details] [review] Added two casts needed to avoid MSVC warnings when compiling GstRingBuffer.
Created attachment 98252 [details] [review] Fixed a critical GstRTPHeader packing issue with MSVC. A colleague (Haakon Sporsheim) might already have submitted this patch. Including it just in case.
Created attachment 98253 [details] [review] Fixes a MSVC runtime error when using the debug CRT. MSVC requires you to mask when data loss is intentional. It compiles in run-time checks to catch this when building with the debug C runtime, causing run-time checks failing with videotestsrc.
Created attachment 98266 [details] [review] Fixed some #undefs to shut up MSVC. MSVC doesn't like "#undef FOO 1", unlike gcc, so this results in warnings.
Thanks for the patches. The ringbuffer warning fix I've done slightly differently (just return NULL). The rtp header packing has already been fixed, as you said. The config.h patch should really be against config.h.in :) 2007-11-01 Tim-Philipp Müller <tim at centricular dot net> Patch by: Ole André Vadla Ravnås <ole.andre.ravnas@tandberg.com> * gst-libs/gst/audio/gstringbuffer.c: (build_linear_format), (gst_ring_buffer_parse_caps): Return NULL instead of an enum that happens to be 0, fixes warning on MSVC (#492114). * gst-libs/gst/audio/gstringbuffer.h: No trailing commas in enum list (for gcc-2.9x). * gst/videotestsrc/videotestsrc.c: (random_char): Make information loss explicit instead of implicitly truncating to eight bits via the return value. Fixes runtime error on MSVC when using the debug CRT (#492114). * win32/common/config.h.in: Fix a bunch of '#undef FOO bar', which MSVC doesn't like (#492114). * win32/common/libgstinterfaces.def: * win32/common/libgstrtp.def: Export a few more symbols (#492114).