Skip to content

redundant build-depends entry for convenience library with C(++) sources #40

@OlivierSohn

Description

@OlivierSohn

Hello,

I recently came across this corner case: in this cabal file, there is a ("main") library, and a convenience library which just builds C++ sources.

The main library declares the convenience library as a dependance, so that the c++ objects built by the convenience library are available at link time for projects that depend on the main library.

If I remove this dependency, the main library builds, but the projects that depend on this main library have "symbol not found" link errors.

weeder detects the convenience library as a redundant build-depends entry of the main library.

In a way, I think this is a bug, and weeder should consider that dependencies on convenience libraries building C / C++ sources are never redundant (considering that here the semantics of the dependency is "aggregate build results").

What do you think?

Thanks!

PS: The reason I need separate libraries is that one library builds c (for a .hsc file), the other builds c++, and build options are not compatible (and cxx-sources / cxx-options is not yet available in the version of cabal used!).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions