You've already forked FFmpeg
mirror of
https://github.com/FFmpeg/FFmpeg.git
synced 2025-11-23 21:54:53 +02:00
check for prefix on extern symbols in configure
Originally committed as revision 12484 to svn://svn.ffmpeg.org/ffmpeg/trunk
This commit is contained in:
7
configure
vendored
7
configure
vendored
@@ -1491,6 +1491,12 @@ if test "$?" != 0; then
|
|||||||
die "C compiler test failed."
|
die "C compiler test failed."
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
check_cc <<EOF || die "Symbol mangling check failed."
|
||||||
|
int ff_extern;
|
||||||
|
EOF
|
||||||
|
sym=$(nm -P $TMPO)
|
||||||
|
extern_prefix=${sym%%ff_extern*}
|
||||||
|
|
||||||
check_asm inline_asm '""'
|
check_asm inline_asm '""'
|
||||||
|
|
||||||
if enabled x86; then
|
if enabled x86; then
|
||||||
@@ -2070,6 +2076,7 @@ enabled asmalign_pot &&
|
|||||||
printf '#define ASMALIGN(ZEROBITS) ".align " #ZEROBITS "\\n\\t"\n' >> $TMPH ||
|
printf '#define ASMALIGN(ZEROBITS) ".align " #ZEROBITS "\\n\\t"\n' >> $TMPH ||
|
||||||
printf '#define ASMALIGN(ZEROBITS) ".align 1<<" #ZEROBITS "\\n\\t"\n' >> $TMPH
|
printf '#define ASMALIGN(ZEROBITS) ".align 1<<" #ZEROBITS "\\n\\t"\n' >> $TMPH
|
||||||
|
|
||||||
|
echo "#define EXTERN_PREFIX \"${extern_prefix}\"" >> $TMPH
|
||||||
|
|
||||||
echo "#endif /* FFMPEG_CONFIG_H */" >> $TMPH
|
echo "#endif /* FFMPEG_CONFIG_H */" >> $TMPH
|
||||||
|
|
||||||
|
|||||||
@@ -119,18 +119,10 @@
|
|||||||
#endif
|
#endif
|
||||||
|
|
||||||
// Use rip-relative addressing if compiling PIC code on x86-64.
|
// Use rip-relative addressing if compiling PIC code on x86-64.
|
||||||
#if defined(__MINGW32__) || defined(__CYGWIN__) || defined(__DJGPP__) || \
|
#if defined(ARCH_X86_64) && defined(PIC)
|
||||||
defined(__OS2__) || defined(__APPLE__) || \
|
# define MANGLE(a) EXTERN_PREFIX #a"(%%rip)"
|
||||||
(defined (__OpenBSD__) && !defined(__ELF__))
|
|
||||||
# if defined(ARCH_X86_64) && defined(PIC)
|
|
||||||
# define MANGLE(a) "_" #a"(%%rip)"
|
|
||||||
# else
|
|
||||||
# define MANGLE(a) "_" #a
|
|
||||||
# endif
|
|
||||||
#elif defined(ARCH_X86_64) && defined(PIC)
|
|
||||||
# define MANGLE(a) #a"(%%rip)"
|
|
||||||
#else
|
#else
|
||||||
# define MANGLE(a) #a
|
# define MANGLE(a) EXTERN_PREFIX #a
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
/* debug stuff */
|
/* debug stuff */
|
||||||
|
|||||||
Reference in New Issue
Block a user