Commit 87865bf6 authored by James Almer's avatar James Almer

Merge commit 'abf1c058'

* commit 'abf1c058':
  msvc: Properly specify dllexport for data symbols shared across dll boundaries
Merged-by: 's avatarJames Almer <jamrial@gmail.com>
parents f87ad3a0 abf1c058
......@@ -31,6 +31,8 @@ define RULES
$(TOOLS): THISLIB = $(FULLNAME:%=$(LD_LIB))
$(TESTPROGS): THISLIB = $(SUBDIR)$(LIBNAME)
$(LIBOBJS): CPPFLAGS += -DBUILDING_$(NAME)
$(TESTPROGS) $(TOOLS): %$(EXESUF): %.o
$$(LD) $(LDFLAGS) $(LDEXEFLAGS) $$(LD_O) $$(filter %.o,$$^) $$(THISLIB) $(FFEXTRALIBS) $$(EXTRALIBS-$$(*F)) $$(ELIBS)
......
......@@ -26,10 +26,11 @@
#include "libavutil/internal.h"
#include "ac3.h"
#include "internal.h"
extern const uint16_t ff_ac3_frame_size_tab[38][3];
extern const uint8_t ff_ac3_channels_tab[8];
extern av_export const uint16_t avpriv_ac3_channel_layout_tab[8];
extern av_export_avcodec const uint16_t avpriv_ac3_channel_layout_tab[8];
extern const uint8_t ff_ac3_enc_channel_map[8][2][6];
extern const uint8_t ff_ac3_dec_channel_map[8][2][6];
extern const uint16_t ff_ac3_sample_rate_tab[3];
......
......@@ -29,10 +29,10 @@
#include <stdint.h>
#include "libavutil/common.h"
#include "libavutil/internal.h"
#include "libavutil/intreadwrite.h"
#include "get_bits.h"
#include "internal.h"
#define DCA_CORE_FRAME_HEADER_SIZE 18
......@@ -195,7 +195,7 @@ enum DCADownMixType {
DCA_DMIX_TYPE_COUNT
};
extern av_export const uint32_t avpriv_dca_sample_rates[16];
extern av_export_avcodec const uint32_t avpriv_dca_sample_rates[16];
extern const uint32_t ff_dca_sampling_freqs[16];
extern const uint8_t ff_dca_freq_ranges[16];
......
......@@ -414,4 +414,14 @@ int ff_alloc_a53_sei(const AVFrame *frame, size_t prefix_len,
*/
int64_t ff_guess_coded_bitrate(AVCodecContext *avctx);
#if defined(_MSC_VER) && CONFIG_SHARED
#ifdef BUILDING_avcodec
# define av_export_avcodec __declspec(dllexport)
#else
# define av_export_avcodec __declspec(dllimport)
#endif
#else
# define av_export_avcodec
#endif
#endif /* AVCODEC_INTERNAL_H */
......@@ -23,18 +23,18 @@
#include <stdint.h>
#include "libavutil/internal.h"
#include "internal.h"
extern av_export const uint8_t avpriv_mjpeg_bits_dc_luminance[];
extern av_export const uint8_t avpriv_mjpeg_val_dc[];
extern av_export_avcodec const uint8_t avpriv_mjpeg_bits_dc_luminance[];
extern av_export_avcodec const uint8_t avpriv_mjpeg_val_dc[];
extern av_export const uint8_t avpriv_mjpeg_bits_dc_chrominance[];
extern av_export_avcodec const uint8_t avpriv_mjpeg_bits_dc_chrominance[];
extern av_export const uint8_t avpriv_mjpeg_bits_ac_luminance[];
extern av_export const uint8_t avpriv_mjpeg_val_ac_luminance[];
extern av_export_avcodec const uint8_t avpriv_mjpeg_bits_ac_luminance[];
extern av_export_avcodec const uint8_t avpriv_mjpeg_val_ac_luminance[];
extern av_export const uint8_t avpriv_mjpeg_bits_ac_chrominance[];
extern av_export const uint8_t avpriv_mjpeg_val_ac_chrominance[];
extern av_export_avcodec const uint8_t avpriv_mjpeg_bits_ac_chrominance[];
extern av_export_avcodec const uint8_t avpriv_mjpeg_val_ac_chrominance[];
void ff_mjpeg_build_huffman_codes(uint8_t *huff_size, uint16_t *huff_code,
const uint8_t *bits_table,
......
......@@ -27,6 +27,7 @@
#include "libavutil/attributes.h"
#include "get_bits.h"
#include "internal.h"
#include "put_bits.h"
typedef struct MPEG4AudioConfig {
......@@ -44,7 +45,7 @@ typedef struct MPEG4AudioConfig {
int frame_length_short;
} MPEG4AudioConfig;
extern av_export const int avpriv_mpeg4audio_sample_rates[16];
extern av_export_avcodec const int avpriv_mpeg4audio_sample_rates[16];
extern const uint8_t ff_mpeg4audio_channels[8];
/**
......
......@@ -29,13 +29,13 @@
#include <stdint.h>
#include "libavutil/internal.h"
#include "internal.h"
#define MODE_EXT_MS_STEREO 2
#define MODE_EXT_I_STEREO 1
extern av_export const uint16_t avpriv_mpa_bitrate_tab[2][3][15];
extern av_export const uint16_t avpriv_mpa_freq_tab[3];
extern av_export_avcodec const uint16_t avpriv_mpa_bitrate_tab[2][3][15];
extern av_export_avcodec const uint16_t avpriv_mpa_freq_tab[3];
extern const int ff_mpa_sblimit_table[5];
extern const int ff_mpa_quant_steps[17];
extern const int ff_mpa_quant_bits[17];
......
......@@ -28,6 +28,7 @@
#define AVCODEC_RAW_H
#include "avcodec.h"
#include "internal.h"
#include "libavutil/internal.h"
typedef struct PixelFormatTag {
......@@ -41,7 +42,7 @@ const struct PixelFormatTag *avpriv_get_raw_pix_fmt_tags(void);
enum AVPixelFormat avpriv_find_pix_fmt(const PixelFormatTag *tags, unsigned int fourcc);
extern av_export const PixelFormatTag avpriv_pix_fmt_bps_avi[];
extern av_export const PixelFormatTag avpriv_pix_fmt_bps_mov[];
extern av_export_avcodec const PixelFormatTag avpriv_pix_fmt_bps_avi[];
extern av_export_avcodec const PixelFormatTag avpriv_pix_fmt_bps_mov[];
#endif /* AVCODEC_RAW_H */
......@@ -64,9 +64,13 @@
#endif
#if defined(_MSC_VER) && CONFIG_SHARED
# define av_export __declspec(dllimport)
#ifdef BUILDING_avutil
# define av_export_avutil __declspec(dllexport)
#else
# define av_export
# define av_export_avutil __declspec(dllimport)
#endif
#else
# define av_export_avutil
#endif
#if HAVE_PRAGMA_DEPRECATED
......
......@@ -29,7 +29,7 @@
#include <stdint.h>
#include "internal.h"
extern av_export const uint8_t avpriv_cga_font[2048];
extern av_export const uint8_t avpriv_vga16_font[4096];
extern av_export_avutil const uint8_t avpriv_cga_font[2048];
extern av_export_avutil const uint8_t avpriv_vga16_font[4096];
#endif /* AVUTIL_XGA_FONT_DATA_H */
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment