diff options
author | Chris Robinson <chris.kcat@gmail.com> | 2021-03-28 01:47:27 -0700 |
---|---|---|
committer | Chris Robinson <chris.kcat@gmail.com> | 2021-03-28 01:47:27 -0700 |
commit | 819e0297fff72fab0745985db8640d2652437189 (patch) | |
tree | e27932270e8dd5fa60554c1eeb0330533c9bcdc6 | |
parent | f045694ce0e65360ebf21bc26fcf5a757760c1dd (diff) |
Add the export definitions to the library projects
Instead of the config.h header.
-rw-r--r-- | CMakeLists.txt | 6 | ||||
-rw-r--r-- | config.h.in | 4 |
2 files changed, 4 insertions, 6 deletions
diff --git a/CMakeLists.txt b/CMakeLists.txt index f255e942..954753f9 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -1236,7 +1236,8 @@ else() router/al.cpp ) target_compile_definitions(OpenAL - PRIVATE AL_BUILD_LIBRARY AL_ALEXT_PROTOTYPES ${CPP_DEFS}) + PRIVATE AL_BUILD_LIBRARY AL_ALEXT_PROTOTYPES "ALC_API=${EXPORT_DECL}" + "AL_API=${EXPORT_DECL}" ${CPP_DEFS}) target_compile_options(OpenAL PRIVATE ${C_FLAGS}) target_link_libraries(OpenAL PRIVATE common ${LINKER_FLAGS}) target_include_directories(OpenAL @@ -1321,7 +1322,8 @@ set_target_properties(${IMPL_TARGET} PROPERTIES OUTPUT_NAME ${LIBNAME} SOVERSION ${LIB_MAJOR_VERSION} ) target_compile_definitions(${IMPL_TARGET} - PRIVATE AL_BUILD_LIBRARY AL_ALEXT_PROTOTYPES ${CPP_DEFS}) + PRIVATE AL_BUILD_LIBRARY AL_ALEXT_PROTOTYPES "ALC_API=${EXPORT_DECL}" "AL_API=${EXPORT_DECL}" + ${CPP_DEFS}) target_compile_options(${IMPL_TARGET} PRIVATE ${C_FLAGS}) if(TARGET build_version) diff --git a/config.h.in b/config.h.in index a28204ef..f43b3f73 100644 --- a/config.h.in +++ b/config.h.in @@ -1,7 +1,3 @@ -/* API declaration export attribute */ -#define AL_API ${EXPORT_DECL} -#define ALC_API ${EXPORT_DECL} - /* Define if HRTF data is embedded in the library */ #cmakedefine ALSOFT_EMBED_HRTF_DATA |