Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

library prefix in MSVC files. #14

Open
adrianbroher opened this issue Apr 1, 2016 · 3 comments
Open

library prefix in MSVC files. #14

adrianbroher opened this issue Apr 1, 2016 · 3 comments

Comments

@adrianbroher
Copy link
Contributor

Hello,

currently the MSVC project files define a lib prefix for the ogg library, leading to a libogg.dll shared library, a libogg.lib import library and a libogg_static.lib static library. This is inconsistent with the output generated by CMake, which in the current configuration creates a ogg.dll shared library, a ogg.lib import library and a ogg.lib static library.

But how to fix this? It's possible to change the MSVC projects or to set the prefix in the CMake configuration. The lib prefix isn't removed by the linker during runtime linking so one would always need to link against libogg on windows, making it inconsistent across platforms where you link against ogg, making cross platform builds a bit harder (eg. you would need to update the CMakelists.txt of the vorbis project to search for libogg too instead of just searching for ogg). On the other hand it would break compatibility in the sense that clients who use libogg in their project file, causing link error until the linker dependency is changed from libogg.lib to ogg.lib.

@tdaede
Copy link

tdaede commented Apr 2, 2016

The CMake build files are quite new, so I would guess most projects use the libogg name. In addition, on Linux, it's also libogg. I think changing CMakelists.txt in both Ogg and Vorbis is probably sensible. Other users of Ogg (Opus and Theora) have no cmake support at all.

@ghost
Copy link

ghost commented Feb 27, 2017

@adrianbrohe Cannot reproduce issue. Tested and confirmed resolved.

@Zuzu-Typ
Copy link

Same here.
The ogg.def file defines the library as LIBRARY ogg, whereas the project (libogg.vcxproj) defines it as <RootNamespace>libogg</RootNamespace>.
Thus the dynamic library is called libogg.dll while the linking lib (libogg.lib) points to a nonexistant ogg.lib.

That makes it impossible to link the correct dll without renaming it.

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

No branches or pull requests

3 participants