]> git.sesse.net Git - mlt/commitdiff
Cleanup Win32 build.
authorDan Dennedy <dan@dennedy.org>
Sat, 18 Jun 2011 01:46:05 +0000 (18:46 -0700)
committerDan Dennedy <dan@dennedy.org>
Sat, 18 Jun 2011 01:46:05 +0000 (18:46 -0700)
src/framework/Makefile
src/framework/mlt_types.h
src/melt/Makefile
src/modules/avformat/Makefile
src/modules/gtk2/Makefile
src/modules/sdl/Makefile
src/win32/fnmatch.c

index 4cecdba00254478665d461a482e75de10b4ee6a4..f7a3b9b85abaa47ab3ba68d9c686912d64540686 100644 (file)
@@ -73,6 +73,11 @@ INCS = mlt_consumer.h \
 
 SRCS := $(OBJS:.o=.c)
 
+ifeq ($(targetos), MinGW)
+OBJS += ../win32/win32.o
+SRCS += ../win32/win32.c
+endif
+
 CFLAGS += $(RDYNAMIC) -DPREFIX="\"$(prefix)\"" -DLIBDIR="\"$(libdir)\""
 
 LDFLAGS += $(LIBDL) -lpthread
index 50c60e01cec747e77bca7df00df6cb1ca2c032bd..3f79453ef5c2147882a8ac57d3d1b43d85ed59de 100644 (file)
@@ -128,4 +128,12 @@ typedef char *( *mlt_serialiser )( void *, int length );/**< pointer to serializ
 #define MLT_CONSUMER(x) ( ( mlt_consumer )( x ) )       /**< Cast to a Consumer pointer */
 #define MLT_FRAME(x)      ( ( mlt_frame )( x ) )        /**< Cast to a Frame pointer */
 
+#ifdef WIN32
+#include <pthread.h>
+/* Win32 compatibility function declarations */
+extern int usleep(unsigned int useconds);
+extern int nanosleep( const struct timespec * rqtp, struct timespec * rmtp );
+extern int setenv(const char *name, const char *value, int overwrite);
+#endif
+
 #endif
index 4084b271d651db45fe29124f6bfa0a9f6415b8f0..6d501d96793a2dc8bc5f7cd149ebfbf1054148f4 100644 (file)
@@ -13,8 +13,6 @@ SRCS := $(OBJS:.o=.c)
 ifeq ($(targetos), MinGW)
 CFLAGS += `sdl-config --cflags`
 LDFLAGS += `sdl-config --libs`
-OBJS += ../win32/win32.o
-SRCS += ../win32/win32.c
 bindir = $(prefix)
 endif
 
index b3f96553309fc0d9fa005fd2b9913a209584b353..d67b6d39aea743b9d8c76e9e84d503200c3f75c1 100644 (file)
@@ -56,11 +56,6 @@ endif
 
 SRCS := $(OBJS:.o=.c)
 
-ifeq ($(targetos), MinGW)
-OBJS += ../../win32/win32.o
-SRCS += ../../win32/win32.c
-endif
-
 all:   $(TARGET)
 
 $(LOCAL_FFMPEG_OBJS):
index e6b2266cec58fcdeb4329d96c8e08e4bc25da2d0..c5b3e1118aa30720a32d638f0034b60aa3fc3a04 100644 (file)
@@ -49,11 +49,6 @@ endif
 
 SRCS := $(OBJS:.o=.c)
 
-ifeq ($(targetos), MinGW)
-OBJS += ../../win32/win32.o
-SRCS += ../../win32/win32.c
-endif
-
 all:   $(TARGET)
 
 $(TARGET): $(OBJS) $(ASM_OBJS)
index 20a3eafc4e5158cb2b7a089eea3d46efb38d55f3..6fab5d41ad7fb9b69f32b63f349367a7826d9c88 100644 (file)
@@ -37,11 +37,6 @@ OBJS += consumer_sdl_osx.o
 SRCS += consumer_sdl_osx.m consumer_sdl_osx.h
 endif
 
-ifeq ($(targetos), MinGW)
-OBJS += ../../win32/win32.o
-SRCS += ../../win32/win32.c
-endif
-
 all:   $(TARGET)
 
 $(TARGET): $(OBJS)
index 1fbc5484f2889d0cd0a3f0cf3d38ec3ed996e45c..27cf36f9c7beff5fbba776904c684898d5a1175f 100644 (file)
@@ -138,8 +138,8 @@ int fnmatch(const char *pattern, const char *string, int flags)
                                  tolower((unsigned char)*string)))
                                ;
                        else if ((flags & FNM_PREFIX_DIRS) && *string == EOS &&
-                            (c == '/' && string != stringstart ||
-                            string == stringstart+1 && *stringstart == '/') )
+                                ((c == '/' && string != stringstart) ||
+                                (string == stringstart+1 && *stringstart == '/')) )
                                return (0);
                        else
                                return (FNM_NOMATCH);