diff options
author | sezero <sezero@users.sourceforge.net> | 2019-10-08 15:10:20 +0300 |
---|---|---|
committer | Erik de Castro Lopo <erikd@mega-nerd.com> | 2019-10-10 18:30:39 +1100 |
commit | b917d456d23c3268cc6f466d720605b713d7b9ff (patch) | |
tree | 9f905cab65c0e6b5f7efaccb51cb0640eb1d3708 /configure.ac | |
parent | 19a0e99ac3ac5f1fc24d66612668a277ceba8195 (diff) | |
download | flac-b917d456d23c3268cc6f466d720605b713d7b9ff.tar.gz |
make dllexport work with compilers other than MSVC
the issue is, flac and metaflac exes rely on flac_internal_???_utf8()
procedures from windows_unicode_filenames.c and there is no easy way
to exclude them from exports without breaking things. So export them
explicitly (they are exported anyway w/o this patch), but add a FIXME
note about the kludge in windows_unicode_filenames.c.
Diffstat (limited to 'configure.ac')
-rw-r--r-- | configure.ac | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/configure.ac b/configure.ac index 14e2205a..6efefaf5 100644 --- a/configure.ac +++ b/configure.ac @@ -493,6 +493,22 @@ if test x$enable_stack_smash_protection = "xyes" ; then XIPH_GXX_STACK_PROTECTOR fi +AH_VERBATIM([FLAC_API_EXPORTS], +[/* libtool defines DLL_EXPORT for windows dll builds, + but flac code relies on FLAC_API_EXPORTS instead. */ +#ifdef DLL_EXPORT +#ifdef __cplusplus +# define FLACPP_API_EXPORTS +#else +# define FLAC_API_EXPORTS +#endif +#endif]) + +if test x$enable_shared != "xyes" ; then +dnl for correct FLAC_API + CPPFLAGS="-DFLAC__NO_DLL $CPPFLAGS" + fi + AC_CONFIG_FILES([ \ Makefile \ src/Makefile \ |