From 593932d3ed180ed7fd502351b2e6a5bcc5f0cd46 Mon Sep 17 00:00:00 2001 From: Thomas Vander Stichele Date: Sun, 16 Oct 2005 10:38:02 +0000 Subject: [PATCH] check for process.h, declares getpid() on Windows Original commit message from CVS: * configure.ac: * win32/common/config.h: * win32/common/config.h.in: check for process.h, declares getpid() on Windows * gst/gstinfo.c: include process.h if we have it * gst/gstmemchunk.c: (populate), (gst_mem_chunk_new): * gst/gstmemchunk.h: fix signedness issues * win32/common/libgstreamer.def: fix get_type's --- ChangeLog | 14 ++++++++++++++ configure.ac | 1 + gst/gstinfo.c | 11 +++++++---- gst/gstmemchunk.c | 4 ++-- gst/gstmemchunk.h | 2 +- win32/common/config.h | 3 +++ win32/common/config.h.in | 3 +++ win32/common/libgstreamer.def | 5 +++-- 8 files changed, 34 insertions(+), 9 deletions(-) diff --git a/ChangeLog b/ChangeLog index 24f472082c..313da33358 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,17 @@ +2005-10-16 Thomas Vander Stichele + + * configure.ac: + * win32/common/config.h: + * win32/common/config.h.in: + check for process.h, declares getpid() on Windows + * gst/gstinfo.c: + include process.h if we have it + * gst/gstmemchunk.c: (populate), (gst_mem_chunk_new): + * gst/gstmemchunk.h: + fix signedness issues + * win32/common/libgstreamer.def: + fix get_type's + 2005-10-16 Julien MOUTTE * gst/gstcaps.c: (gst_caps_intersect): Fix a bad bug with a simple diff --git a/configure.ac b/configure.ac index 8dc6e973fc..80ef94849c 100644 --- a/configure.ac +++ b/configure.ac @@ -260,6 +260,7 @@ dnl Check for ucontext.h AC_CHECK_HEADERS([ucontext.h]) AC_CHECK_HEADERS([sys/socket.h], HAVE_SYS_SOCKET_H=yes) AM_CONDITIONAL(HAVE_SYS_SOCKET_H, test "x$HAVE_SYS_SOCKET_H" = "xyes") +AC_CHECK_HEADERS([process.h]) dnl *** checks for library functions *** diff --git a/gst/gstinfo.c b/gst/gstinfo.c index 1a0d09ab1a..c6927b93b7 100644 --- a/gst/gstinfo.c +++ b/gst/gstinfo.c @@ -92,20 +92,23 @@ #ifndef GST_DISABLE_GST_DEBUG #ifdef HAVE_DLFCN_H -#include +# include #endif #ifdef HAVE_PRINTF_EXTENSION -#include +# include #endif #include /* fprintf */ #ifdef HAVE_UNISTD_H -#include +# include /* getpid on UNIX */ +#endif +#ifdef HAVE_PROCESS_H +# include /* getpid on win32 */ #endif #include /* G_VA_COPY */ #include "gst_private.h" #include "gstutils.h" #ifdef HAVE_VALGRIND -#include +# include #endif #include /* g_sprintf */ diff --git a/gst/gstmemchunk.c b/gst/gstmemchunk.c index 51c3822e55..580e0d1bbc 100644 --- a/gst/gstmemchunk.c +++ b/gst/gstmemchunk.c @@ -83,7 +83,7 @@ static gboolean populate (GstMemChunk * mem_chunk) { guint8 *area; - gint i; + guint i; if (mem_chunk->cleanup) return FALSE; @@ -125,7 +125,7 @@ populate (GstMemChunk * mem_chunk) * MT safe. */ GstMemChunk * -gst_mem_chunk_new (gchar * name, gint atom_size, gulong area_size, gint type) +gst_mem_chunk_new (gchar * name, guint atom_size, gulong area_size, gint type) { GstMemChunk *mem_chunk; diff --git a/gst/gstmemchunk.h b/gst/gstmemchunk.h index 89e032a9f9..620292b308 100644 --- a/gst/gstmemchunk.h +++ b/gst/gstmemchunk.h @@ -32,7 +32,7 @@ G_BEGIN_DECLS typedef struct _GstMemChunk GstMemChunk; GstMemChunk* gst_mem_chunk_new (gchar *name, - gint atom_size, + guint atom_size, gulong area_size, gint type); diff --git a/win32/common/config.h b/win32/common/config.h index f722a59283..dc3a2f85bb 100644 --- a/win32/common/config.h +++ b/win32/common/config.h @@ -126,6 +126,9 @@ /* Defined if we have register_printf_function () */ #undef HAVE_PRINTF_EXTENSION +/* Define to 1 if you have the header file. */ +#define HAVE_PROCESS_H 1 + /* Define if RDTSC is available */ #undef HAVE_RDTSC diff --git a/win32/common/config.h.in b/win32/common/config.h.in index bec367f11d..570c2510a9 100644 --- a/win32/common/config.h.in +++ b/win32/common/config.h.in @@ -126,6 +126,9 @@ /* Defined if we have register_printf_function () */ #undef HAVE_PRINTF_EXTENSION +/* Define to 1 if you have the header file. */ +#define HAVE_PROCESS_H 1 + /* Define if RDTSC is available */ #undef HAVE_RDTSC diff --git a/win32/common/libgstreamer.def b/win32/common/libgstreamer.def index 02c5e72c8c..f6d28c1304 100644 --- a/win32/common/libgstreamer.def +++ b/win32/common/libgstreamer.def @@ -157,11 +157,12 @@ EXPORTS gst_caps_is_fixed gst_caps_to_string gst_caps_from_string - gst_list_get_type - gst_fourcc_get_type gst_double_range_get_type + gst_fourcc_get_type gst_int_range_get_type gst_fraction_get_type + gst_value_list_get_type + gst_value_array_get_type gst_structure_new gst_caps_new_full gst_caps_append