It does not look like tinyxml supports shared library builds out of the box.
Here are the steps that I followed to build a DLL from the tinyxml 2.6.2 sources:
- Open the provided SLN file,
tinyxml.sln
, in MS Visual Studio Express 2012 for Windows Desktop. Elect to convert the old project files to the new format when prompted.
- From "Solution Platforms", select "Configuration Manager..."
- From "Active solution platform:" select "<New...>"
- In "Type or select the new platform:" select "x64" if not already selected. Make sure to copy settings from the "Win32" configuration. Click OK. Click Close to exit the Configuration Manager.
- Right click on the tinyxml project in Solution Explorer. Select "Properties".
- For "Configuration:", select "All Configurations". Similarly, for "Platform:" select "All Platforms".
- On the Configuration Properties → General page, change "Configuration Type" to "Dynamic Library (.dll)". Change "Target Extension" to ".dll". Click OK to exit the tinyxml Properties Pages dialog.
- Select the "Release" configuration and "x64" platform.
- Right click on the tinyxml project in Solution Explorer again and select "Rebuild".
Within tinyxml_2_6_2\tinyxml\x64\Release
you will find tinyxml.dll
, but no import library (tinyxml.lib
). This is because no symbols are exported. See How do I build an import library (.lib) AND a DLL in Visual C++?
If you want to go the shared library route, you will need to export the desired symbols via the MSVC-specific __declspec(dllexport)
modifier. See Symbol Visibility in Windows.