mirror of
https://gitlab.com/mbunkus/mkvtoolnix.git
synced 2024-12-24 20:01:53 +00:00
Merged 2192
This commit is contained in:
parent
958b73fdf5
commit
ac7a9ca3c5
76
configure.in
76
configure.in
@ -178,6 +178,82 @@ AC_SUBST(MINGW_LIBS)
|
||||
AC_SUBST(MINGW_GUIAPP)
|
||||
|
||||
|
||||
dnl
|
||||
dnl Test if the 64bit integer types are available, and if not if they
|
||||
dnl can be typedef'ed manually.
|
||||
dnl
|
||||
AC_MSG_CHECKING(for int64_t)
|
||||
AC_LANG_PUSH(C++)
|
||||
AC_CACHE_VAL(has_int64_t,[
|
||||
AC_TRY_RUN([
|
||||
#ifdef __BEOS__
|
||||
#include <inttypes.h>
|
||||
#endif
|
||||
#include <sys/types.h>
|
||||
int64_t foo;
|
||||
int main() {return 0;}
|
||||
],
|
||||
has_int64_t=yes,
|
||||
has_int64_t=no,
|
||||
has_int64_t=no)
|
||||
])
|
||||
AC_MSG_RESULT($has_int64_t)
|
||||
|
||||
AC_MSG_CHECKING(for uint64_t)
|
||||
AC_CACHE_VAL(has_uint64_t,[
|
||||
AC_TRY_RUN([
|
||||
#ifdef __BEOS__
|
||||
#include <inttypes.h>
|
||||
#endif
|
||||
#include <sys/types.h>
|
||||
int64_t foo;
|
||||
int main() {return 0;}
|
||||
],
|
||||
has_uint64_t=yes,
|
||||
has_uint64_t=no,
|
||||
has_uint64_t=no)
|
||||
])
|
||||
AC_MSG_RESULT($has_uint64_t)
|
||||
|
||||
AC_CHECK_SIZEOF(int)
|
||||
AC_CHECK_SIZEOF(long)
|
||||
AC_CHECK_SIZEOF(long long)
|
||||
|
||||
if test x$has_int64_t = "xyes" ; then
|
||||
TYPE64="int64_t"
|
||||
else
|
||||
case 8 in
|
||||
$ac_cv_sizeof_int) TYPE64="int";;
|
||||
$ac_cv_sizeof_long) TYPE64="long";;
|
||||
$ac_cv_sizeof_long_long) TYPE64="long long";;
|
||||
esac
|
||||
AC_DEFINE(HAVE_NO_INT64_T, 1, [int64_t does not exist])
|
||||
AC_DEFINE_UNQUOTED(INT64_TYPE, $TYPE64,
|
||||
[the type to define int64_t manually])
|
||||
fi
|
||||
|
||||
if test x$has_uint64_t = "xyes" ; then
|
||||
TYPEU64="int64_t"
|
||||
else
|
||||
case 8 in
|
||||
$ac_cv_sizeof_int) TYPEU64="unsigned int";;
|
||||
$ac_cv_sizeof_long) TYPEU64="unsigned long";;
|
||||
$ac_cv_sizeof_long_long) TYPEU64="unsigned long long";;
|
||||
esac
|
||||
AC_DEFINE(HAVE_NO_UINT64_T, 1, [uint64_t does not exist])
|
||||
AC_DEFINE_UNQUOTED(UINT64_TYPE, $TYPEU64,
|
||||
[the type to define uint64_t manually])
|
||||
fi
|
||||
|
||||
if test -z "$TYPE64"; then
|
||||
AC_MSG_ERROR(No 64 bit type found on this platform!)
|
||||
fi
|
||||
if test -z "$TYPEU64"; then
|
||||
AC_MSG_ERROR(No unsigned 64 bit type found on this platform!)
|
||||
fi
|
||||
|
||||
AC_LANG_POP
|
||||
|
||||
|
||||
dnl
|
||||
dnl Test for libiconv
|
||||
|
@ -33,6 +33,8 @@
|
||||
# define SYS_UNIX
|
||||
# if defined(__bsdi__) || defined(__FreeBSD__)
|
||||
# define SYS_BSD
|
||||
# elif defined(__sun) && defined(__SVR4)
|
||||
# define SYS_SOLARIS
|
||||
# else
|
||||
# define SYS_LINUX
|
||||
# endif
|
||||
@ -82,6 +84,9 @@ typedef _fsize_t ssize_t;
|
||||
# define LLU "%llu"
|
||||
#endif // COMP_MINGW || COMP_MSC
|
||||
|
||||
#if defined(HAVE_SYS_TYPES_H)
|
||||
#include <sys/types.h>
|
||||
#endif // HAVE_SYS_TYPES_H
|
||||
#if defined(HAVE_STDINT_H)
|
||||
#include <stdint.h>
|
||||
#endif // HAVE_STDINT_H
|
||||
@ -89,6 +94,13 @@ typedef _fsize_t ssize_t;
|
||||
#include <inttypes.h>
|
||||
#endif // HAVE_INTTYPES_H
|
||||
|
||||
#if defined(HAVE_NO_INT64_T)
|
||||
typedef INT64_TYPE int64_t;
|
||||
#endif
|
||||
#if defined(HAVE_NO_UINT64_T)
|
||||
typedef UINT64_TYPE uint64_t;
|
||||
#endif
|
||||
|
||||
#if defined(SYS_WINDOWS)
|
||||
# define PATHSEP '\\'
|
||||
#else
|
||||
|
Loading…
Reference in New Issue
Block a user