mirror of
https://git.planet-casio.com/Lephenixnoir/OpenLibm.git
synced 2024-12-28 20:43:41 +01:00
0418324ca4
On x86_64, openlibm_fenv.h is silently coupled to openlibm_complex.h due to the inclusion of math_private.h inside of openlibm_fenv_amd64.h. The math_private.h header was included to gain access to the OLM_DLLEXPORT macro. However, this macro is redefined, since it is originally defined in openlibm_math.h. This inclusion also exposes math_private.h to public clients, which is undesirable. Instead, a standalone header is created to contain the OLM_DLLEXPORT definition. This header is used included in the appropriate files. openlibm_fenv_amd64.h is no longer coupled to math_private.h.
14 lines
298 B
C
14 lines
298 B
C
#ifndef OPENLIBM_DEFS_H_
|
|
#define OPENLIBM_DEFS_H_
|
|
|
|
#ifdef _WIN32
|
|
# ifdef IMPORT_EXPORTS
|
|
# define OLM_DLLEXPORT __declspec(dllimport)
|
|
# else
|
|
# define OLM_DLLEXPORT __declspec(dllexport)
|
|
# endif
|
|
#else
|
|
#define OLM_DLLEXPORT __attribute__ ((visibility("default")))
|
|
#endif
|
|
|
|
#endif // OPENLIBM_DEFS_H_
|