Skip to content

Commit

Permalink
WIP: second try at MinGW symbol export
Browse files Browse the repository at this point in the history
  • Loading branch information
speth committed Jan 31, 2023
1 parent f7d82c8 commit 8485cb3
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 9 deletions.
2 changes: 1 addition & 1 deletion ext/eigen
Submodule eigen updated from 21ae2a to 314739
8 changes: 0 additions & 8 deletions include/cantera/extensions/PythonExtensionManager.h
Expand Up @@ -8,12 +8,6 @@

#include "cantera/base/ExtensionManager.h"

#define BOOST_DLL_USE_STD_FS
#ifdef __MINGW32__
#define BOOST_DLL_FORCE_ALIAS_INSTANTIATION
#endif
#include <boost/dll/alias.hpp>

namespace Cantera
{

Expand Down Expand Up @@ -49,8 +43,6 @@ class PythonExtensionManager : public ExtensionManager
static bool s_imported;
};

BOOST_DLL_ALIAS(Cantera::PythonExtensionManager::registerSelf, registerPythonExtensionManager);

}

#endif
10 changes: 10 additions & 0 deletions src/extensions/PythonExtensionManager.cpp
Expand Up @@ -20,6 +20,16 @@
#include <windows.h>
#endif

#define BOOST_DLL_USE_STD_FS
#ifdef __MINGW32__
#define BOOST_DLL_FORCE_ALIAS_INSTANTIATION
#endif
#include <boost/dll/alias.hpp>

// This creates and exports the name that is imported from Application::loadExtension
BOOST_DLL_ALIAS(Cantera::PythonExtensionManager::registerSelf,
registerPythonExtensionManager);

namespace ba = boost::algorithm;
using namespace std;

Expand Down

0 comments on commit 8485cb3

Please sign in to comment.