]> git.sesse.net Git - ffmpeg/blobdiff - libavutil/internal.h
Revert the merger of LC_ALL declaration and export.
[ffmpeg] / libavutil / internal.h
index 32db7f5d9b958cf9110dd84d3f672c7f0124387d..0eb25d5f6c9eeec3ed7e12f9e25fc019b4d0a6c9 100644 (file)
@@ -23,8 +23,8 @@
  * common internal api header.
  */
 
-#ifndef FFMPEG_INTERNAL_H
-#define FFMPEG_INTERNAL_H
+#ifndef AVUTIL_INTERNAL_H
+#define AVUTIL_INTERNAL_H
 
 #if !defined(DEBUG) && !defined(NDEBUG)
 #    define NDEBUG
 #endif
 #endif
 
-#ifndef M_PI
-#define M_PI    3.14159265358979323846
-#endif
-
 #ifndef INT16_MIN
 #define INT16_MIN       (-0x7fff-1)
 #endif
 #    define offsetof(T,F) ((unsigned int)((char *)&((T *)0)->F))
 #endif
 
-#ifdef CONFIG_FASTMEMCPY
-#    include "libvo/fastmemcpy.h"
-#    define memcpy(a,b,c) fast_memcpy(a,b,c)
-#endif
-
 // Use rip-relative addressing if compiling PIC code on x86-64.
 #if defined(ARCH_X86_64) && defined(PIC)
 #    define LOCAL_MANGLE(a) #a "(%%rip)"
@@ -150,7 +141,10 @@ extern const uint32_t ff_inverse[256];
 static inline av_const int FASTDIV(int a, int b)
 {
     int r;
-    asm volatile("smmul %0, %1, %2" : "=r"(r) : "r"(a), "r"(ff_inverse[b]));
+    asm volatile("cmp   %2, #0        \n\t"
+                 "smmul %0, %1, %2    \n\t"
+                 "rsblt %0, %0, #0    \n\t"
+                 : "=r"(r) : "r"(a), "r"(ff_inverse[b]));
     return r;
 }
 #elif defined(ARCH_ARMV4L)
@@ -248,7 +242,7 @@ if((y)<(x)){\
 #define strcat strcat_is_forbidden_due_to_security_issues_use_av_strlcat
 #undef  exit
 #define exit exit_is_forbidden
-#if !(defined(LIBAVFORMAT_BUILD) || defined(FFMPEG_FRAMEHOOK_H))
+#ifndef LIBAVFORMAT_BUILD
 #undef  printf
 #define printf please_use_av_log
 #undef  fprintf
@@ -303,4 +297,4 @@ static av_always_inline av_const float roundf(float x)
 }
 #endif /* HAVE_ROUNDF */
 
-#endif /* FFMPEG_INTERNAL_H */
+#endif /* AVUTIL_INTERNAL_H */