boostorg / python

Boost.org python module
http://boostorg.github.io/python
Boost Software License 1.0
465 stars 201 forks source link

Normalize static/dynamic link macros and avoid redefinition warnings #427

Closed pdimov closed 8 months ago

pdimov commented 8 months ago

The static/dynamic config macro logic had two issues; first, it used unconventional macro names (BOOST_PYTHON_STATIC_LIB and BOOST_PYTHON_DYNAMIC_LIB instead of BOOST_PYTHON_STATIC_LINK and BOOST_PYTHON_DYNAMIC_LINK as everything else); second, when both BOOST_PYTHON_STATIC_LINK and BOOST_PYTHON_STATIC_LIB were defined, it caused a macro redefinition warning.

This change fixes both.