Skip to content

Conversation

dofuuz
Copy link

@dofuuz dofuuz commented Oct 18, 2020

When compiling with MSVC, dynamic and static library had same output filename soundio.lib.

      Creating library D:/a/libsoundio/libsoundio/build/Release/soundio.lib and object D:/a/libsoundio/libsoundio/build/Release/soundio.exp
  libsoundio_shared.vcxproj -> D:\a\libsoundio\libsoundio\build\Release\soundio.dll
   libsoundio_static.vcxproj -> D:\a\libsoundio\libsoundio\build\Release\soundio.lib
sio_list_devices.obj : error LNK2019: unresolved external symbol __imp__soundio_create referenced in function _main [D:\a\libsoundio\libsoundio\build\sio_list_devices.vcxproj]
sio_list_devices.obj : error LNK2019: unresolved external symbol __imp__soundio_destroy referenced in function _main [D:\a\libsoundio\libsoundio\build\sio_list_devices.vcxproj]
sio_list_devices.obj : error LNK2019: unresolved external symbol __imp__soundio_connect referenced in function _main [D:\a\libsoundio\libsoundio\build\sio_list_devices.vcxproj]
...

Link error occurs because dynamic soundio.lib has overwritten by static soundio.lib

To avoid conflict, dynamic/static library should have different name.

- Dynamic and static library had same output filename soundio.lib
- To avoid conflict, dynamic/static library should have different name
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant