From 39f6499e3abcf473bdcbade38aba9a7490470e6a Mon Sep 17 00:00:00 2001 From: Loren Merritt Date: Wed, 30 Sep 2009 22:39:13 +0000 Subject: [PATCH] rm msvc project files and related ifdefs --- build/win32/libx264.vcproj | 995 ------------------------------------- build/win32/x264.sln | 30 -- build/win32/x264.vcproj | 178 ------- common/mdate.c | 5 +- common/osdep.h | 19 +- doc/standards.txt | 4 +- encoder/analyse.c | 2 - encoder/set.c | 2 - extras/getopt.c | 21 +- muxers.c | 3 - x264.c | 3 - 11 files changed, 6 insertions(+), 1256 deletions(-) delete mode 100644 build/win32/libx264.vcproj delete mode 100644 build/win32/x264.sln delete mode 100644 build/win32/x264.vcproj diff --git a/build/win32/libx264.vcproj b/build/win32/libx264.vcproj deleted file mode 100644 index 8497a354..00000000 --- a/build/win32/libx264.vcproj +++ /dev/null @@ -1,995 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/build/win32/x264.sln b/build/win32/x264.sln deleted file mode 100644 index 8fb518d0..00000000 --- a/build/win32/x264.sln +++ /dev/null @@ -1,30 +0,0 @@ -Microsoft Visual Studio Solution File, Format Version 8.00 -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "libx264", "libx264.vcproj", "{A8D6E4CD-1885-4B03-8E41-5F3DB825BAA6}" - ProjectSection(ProjectDependencies) = postProject - EndProjectSection -EndProject -Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "x264", "x264.vcproj", "{22E1814D-7955-4456-AEA5-0C9BA7500792}" - ProjectSection(ProjectDependencies) = postProject - {A8D6E4CD-1885-4B03-8E41-5F3DB825BAA6} = {A8D6E4CD-1885-4B03-8E41-5F3DB825BAA6} - EndProjectSection -EndProject -Global - GlobalSection(SolutionConfiguration) = preSolution - Debug = Debug - Release = Release - EndGlobalSection - GlobalSection(ProjectConfiguration) = postSolution - {22E1814D-7955-4456-AEA5-0C9BA7500792}.Debug.ActiveCfg = Debug|Win32 - {22E1814D-7955-4456-AEA5-0C9BA7500792}.Debug.Build.0 = Debug|Win32 - {22E1814D-7955-4456-AEA5-0C9BA7500792}.Release.ActiveCfg = Release|Win32 - {22E1814D-7955-4456-AEA5-0C9BA7500792}.Release.Build.0 = Release|Win32 - {A8D6E4CD-1885-4B03-8E41-5F3DB825BAA6}.Debug.ActiveCfg = Debug|Win32 - {A8D6E4CD-1885-4B03-8E41-5F3DB825BAA6}.Debug.Build.0 = Debug|Win32 - {A8D6E4CD-1885-4B03-8E41-5F3DB825BAA6}.Release.ActiveCfg = Release|Win32 - {A8D6E4CD-1885-4B03-8E41-5F3DB825BAA6}.Release.Build.0 = Release|Win32 - EndGlobalSection - GlobalSection(ExtensibilityGlobals) = postSolution - EndGlobalSection - GlobalSection(ExtensibilityAddIns) = postSolution - EndGlobalSection -EndGlobal diff --git a/build/win32/x264.vcproj b/build/win32/x264.vcproj deleted file mode 100644 index c5672657..00000000 --- a/build/win32/x264.vcproj +++ /dev/null @@ -1,178 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/common/mdate.c b/common/mdate.c index 1a02cdf5..7a1c8a5c 100644 --- a/common/mdate.c +++ b/common/mdate.c @@ -18,7 +18,7 @@ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02111, USA. *****************************************************************************/ -#if !(defined(_MSC_VER) || defined(__MINGW32__)) +#ifndef __MINGW32__ #include #else #include @@ -31,9 +31,8 @@ int64_t x264_mdate( void ) { -#if !(defined(_MSC_VER) || defined(__MINGW32__)) +#ifndef __MINGW32__ struct timeval tv_date; - gettimeofday( &tv_date, NULL ); return( (int64_t) tv_date.tv_sec * 1000000 + (int64_t) tv_date.tv_usec ); #else diff --git a/common/osdep.h b/common/osdep.h index 71780a24..194990b8 100644 --- a/common/osdep.h +++ b/common/osdep.h @@ -39,19 +39,6 @@ #include // _O_BINARY #endif -#ifdef _MSC_VER -#define inline __inline -#define strcasecmp stricmp -#define strncasecmp strnicmp -#define snprintf _snprintf -#define fseek _fseeki64 -#define ftell _ftelli64 -#define isfinite _finite -#define strtok_r strtok_s -#define _CRT_SECURE_NO_DEPRECATE -#define X264_VERSION "" // no configure script for msvc -#endif - #if (defined(SYS_OPENBSD) && !defined(isfinite)) || defined(SYS_SunOS) #define isfinite finite #endif @@ -62,11 +49,7 @@ #endif #endif -#ifdef _MSC_VER -#define DECLARE_ALIGNED( var, n ) __declspec(align(n)) var -#else #define DECLARE_ALIGNED( var, n ) var __attribute__((aligned(n))) -#endif #define ALIGNED_16( var ) DECLARE_ALIGNED( var, 16 ) #define ALIGNED_8( var ) DECLARE_ALIGNED( var, 8 ) #define ALIGNED_4( var ) DECLARE_ALIGNED( var, 4 ) @@ -161,7 +144,7 @@ static inline int x264_pthread_create( x264_pthread_t *t, void *a, void *(*f)(vo #define WORD_SIZE sizeof(void*) #if !defined(_WIN64) && !defined(__LP64__) -#if defined(_MSC_VER) || defined(__INTEL_COMPILER) +#if defined(__INTEL_COMPILER) #define BROKEN_STACK_ALIGNMENT /* define it if stack is not mod16 */ #endif #endif diff --git a/doc/standards.txt b/doc/standards.txt index 4ebb165a..db9a6917 100644 --- a/doc/standards.txt +++ b/doc/standards.txt @@ -1,5 +1,5 @@ -x264 is written in C. The particular variant of C is: intersection of gcc-2.95 and msvc. This means C89 + a few C99 features. -The extra utilities (mostly checkasm) are written in C99, with no attempt at compatibility with old compilers. +x264 is written in C. The particular variant of C is: intersection of C99 and gcc>=3.4. +checkasm is written in gcc, with no attempt at compatibility with anything else. We make the following additional assumptions which are true of real systems but not guaranteed by C99: * Two's complement. diff --git a/encoder/analyse.c b/encoder/analyse.c index 8a8ead4a..b9415575 100644 --- a/encoder/analyse.c +++ b/encoder/analyse.c @@ -24,9 +24,7 @@ #define _ISOC99_SOURCE #include -#ifndef _MSC_VER #include -#endif #include "common/common.h" #include "common/cpu.h" diff --git a/encoder/set.c b/encoder/set.c index 49ca340e..f6dd8303 100644 --- a/encoder/set.c +++ b/encoder/set.c @@ -24,9 +24,7 @@ #include #include "common/common.h" -#ifndef _MSC_VER #include "config.h" -#endif #include "set.h" #define bs_write_ue bs_write_ue_big diff --git a/extras/getopt.c b/extras/getopt.c index d2dbd306..4c0cb101 100644 --- a/extras/getopt.c +++ b/extras/getopt.c @@ -202,11 +202,7 @@ static char *posixly_correct; # if HAVE_STRING_H # include # else -# ifdef _MSC_VER -# include -# else -# include -# endif +# include # endif /* Avoid depending on library functions or files @@ -984,21 +980,6 @@ getopt (argc, argv, optstring) 0); } -#ifdef _MSC_VER - -int -getopt_long (argc, argv, optstring, long_options, opt_index) - int argc; - char *const *argv; - const char *optstring; - const struct option *long_options; - int *opt_index; -{ - return _getopt_internal (argc, argv, optstring, long_options, opt_index, 0); -} - -#endif - #endif /* Not ELIDE_CODE. */ #ifdef TEST diff --git a/muxers.c b/muxers.c index 7100877e..c9b8dfa2 100644 --- a/muxers.c +++ b/muxers.c @@ -25,10 +25,7 @@ #include "x264.h" #include "matroska.h" #include "muxers.h" - -#ifndef _MSC_VER #include "config.h" -#endif #include diff --git a/x264.c b/x264.c index ec4a3782..ab76a938 100644 --- a/x264.c +++ b/x264.c @@ -32,10 +32,7 @@ #include "common/cpu.h" #include "x264.h" #include "muxers.h" - -#ifndef _MSC_VER #include "config.h" -#endif #ifdef _WIN32 #include -- 2.47.3