Skip to content

Commit a5706ec

Browse files
committed
Fixes for #583.
[SVN r37929]
1 parent a346c57 commit a5706ec

File tree

2 files changed

+6
-21
lines changed

2 files changed

+6
-21
lines changed

include/boost/python/module_init.hpp

Lines changed: 2 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -26,23 +26,7 @@ extern "C" __declspec(dllexport) void init##name() \
2626
} \
2727
void init_module_##name()
2828

29-
# elif defined(_AIX) && !defined(BOOST_PYTHON_STATIC_MODULE)
30-
31-
# include <boost/python/detail/aix_init_module.hpp>
32-
# define BOOST_PYTHON_MODULE_INIT(name) \
33-
void init_module_##name(); \
34-
extern "C" \
35-
{ \
36-
extern PyObject* _PyImport_LoadDynamicModule(char*, char*, FILE *); \
37-
void init##name() \
38-
{ \
39-
boost::python::detail::aix_init_module( \
40-
_PyImport_LoadDynamicModule, #name, &init_module_##name); \
41-
} \
42-
} \
43-
void init_module_##name()
44-
45-
# elif BOOST_PYTHON_USE_GCC_SYMBOL_VISIBILITY
29+
# elif BOOST_PYTHON_USE_GCC_SYMBOL_VISIBILITY
4630

4731
# define BOOST_PYTHON_MODULE_INIT(name) \
4832
void init_module_##name(); \
@@ -52,7 +36,7 @@ extern "C" __attribute__ ((visibility("default"))) void init##name() \
5236
} \
5337
void init_module_##name()
5438

55-
# else
39+
# else
5640

5741
# define BOOST_PYTHON_MODULE_INIT(name) \
5842
void init_module_##name(); \

test/select_from_python_test.cpp

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,9 +5,10 @@
55
#include <boost/python/type_id.hpp>
66
#include <iostream>
77

8-
// gcc 2.95.x and MIPSpro 7.3.1.3 linker seem to demand this definition
9-
#if ((defined(__GNUC__) && __GNUC__ < 3)) \
10-
|| (defined(__sgi) && defined(__EDG_VERSION__) && (__EDG_VERSION__ == 238))
8+
// gcc 2.95.x, MIPSpro 7.3.1.3 and IBM XL for Linux linker seem to demand this definition
9+
#if (defined(__GNUC__) && (__GNUC__ < 3)) \
10+
|| (defined(__sgi) && defined(__EDG_VERSION__) && (__EDG_VERSION__ == 238)) \
11+
|| (defined(__IBMCPP__) && defined(__linux__))
1112
namespace boost { namespace python {
1213
BOOST_PYTHON_DECL bool handle_exception_impl(function0<void>)
1314
{

0 commit comments

Comments
 (0)