diff options
author | Martin Storsjö <martin@martin.st> | 2013-05-06 23:08:41 +0300 |
---|---|---|
committer | Martin Storsjö <martin@martin.st> | 2013-05-08 01:28:25 +0300 |
commit | 06122c253394b10a694d3d95e00e503c89852134 (patch) | |
tree | 8816e8db7f644edf24b23d0e2350ab3471bad6aa | |
parent | bd392785a75d7d51414a9788d50396a8d9f29d77 (diff) | |
download | ffmpeg-06122c253394b10a694d3d95e00e503c89852134.tar.gz |
msvc: Move linker pragma from config.h to libavutil/internal.h
This makes linking succeed for tools that include config.h but
don't link to libavutil.
Signed-off-by: Martin Storsjö <martin@martin.st>
-rwxr-xr-x | configure | 5 | ||||
-rw-r--r-- | libavutil/internal.h | 5 |
2 files changed, 5 insertions, 5 deletions
@@ -4089,11 +4089,6 @@ fi enabled getenv || echo "#define getenv(x) NULL" >> $TMPH -if enabled msvc && ! enabled shared; then - echo '#pragma comment(linker, "/include:"EXTERN_PREFIX"avpriv_strtod")' >> $TMPH - echo '#pragma comment(linker, "/include:"EXTERN_PREFIX"avpriv_snprintf")' >> $TMPH -fi - print_config ARCH_ "$config_files" $ARCH_LIST print_config HAVE_ "$config_files" $HAVE_LIST print_config CONFIG_ "$config_files" $CONFIG_LIST \ diff --git a/libavutil/internal.h b/libavutil/internal.h index 5f4b060926..49534d4b58 100644 --- a/libavutil/internal.h +++ b/libavutil/internal.h @@ -111,6 +111,11 @@ #include "libm.h" +#if defined(_MSC_VER) && !CONFIG_SHARED +#pragma comment(linker, "/include:"EXTERN_PREFIX"avpriv_strtod") +#pragma comment(linker, "/include:"EXTERN_PREFIX"avpriv_snprintf") +#endif + /** * Return NULL if CONFIG_SMALL is true, otherwise the argument * without modification. Used to disable the definition of strings |