Hi,
i added microsoft specific export definitions for the OROCOS-KDL DLLs and made some fixes. The reason is that i am forced to use KDL in windows and compiling a static orocos-kdl library does not match with the KDL license (LGPL 2.1). Thats why i added the export definitions to linka gainst the shared library in windows.
Find the patch attached to this e-mail.
Regards,
Markus
Here is an excerpt from the commit message:
Added Microsoft-specific dllexport and dllimport
storage-class attributes to export and import
functions, data, and objects to or from the OROCOS-KDL
shared libraries (DLL).
The macros and preprocessor defintions that contain the KDL_EXPORT define, which
contains '__declspec(dllexport)' or '__declspec(dllimport)' on windows and
nothing on unix are automatically generated with the CMake function
GENERATE_EXPORT_HEADER() and the accompanying ADD_COMPILER_EXPORT_FLAGS() function.
It generates a 'kdl_export.hpp' in the binary directory that is suitable for
preprocessor inclusion which contains EXPORT macros (SOMELIB_EXPORT,
SOMELIB_NO_EXPORT, SOMELIB_DEPRECATED, SOMELIB_DEPRECATED_EXPORT and
SOMELIB_DEPRECATED_NO_EXPORT) to be used in the OROCOS-KDL library classes.
The resulting hjeader file is included and installed with other headers in the
library.
EXPORTS: All classes and relevant functions in '/orocos_kdl/src/*.hpp', some
constants in '/orocos_kdl/src/utilities/utility.h' and the models in
'/orocos_kdl/models/models.hpp' (if enabled) are exported.
The GENERATE_EXPORT_HEADER function is available since CMake version 2.8.6 and
above. To use the functionality with CMake versions below 2.8.6 (the currently
minumum required CMake version of OROCOS-KDL is 2.4.6) the following files were
added:
* /orocos_kdl/config/GenerateExportHeader.cmake
* /orocos_kdl/config/exportheader.cmake.in
* /orocos_kdl/config/CMakeParseArguments.cmake
FIX: In addions some fixes were applied to convenience the nmake compiler
(missing math.h include and/or missing '#define _USE_MATH_DEFINES', non constant
array length initialization, undefined uint typedef, ambiguous function calls
because of 'using namespace KDL;' e.g. sin, cos, sqrt)
* /orocos_kdl/examples/geometry.cpp
* /orocos_kdl/examples/trajectory_example.cpp
* /orocos_kdl/models/puma560.cpp
* /orocos_kdl/tests/framestest.cpp
* /orocos_kdl/tests/kinfamtest.cpp
* /orocos_kdl/tests/solvertest.cpp
TESTED: Tested that everything compiles (orocos-kdl, orocos-models-kdl, examples,
demos, tests) and that all test succeed and the examples work with the following
compilers:
* WINDOWS: nmake version 10.00.30319.01 (MSVC 2010) compiled from command line
* WINDOWS: Visual Studio Express 2010
* WINDOWS: QtCreator 2.6.1
* LINUX: gcc version 4.7.2 (Latest Debian unstable as of 2012-12-28)
Attachment | Size |
---|---|
0002-Added-Microsoft-specific-dllexport-and-dllimport-sto.patch | 152.37 KB |