|Anonymous | Login||2022-06-26 04:34 UTC|
|My View | View Issues | Change Log | Roadmap|
|View Issue Details|
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0000340||OMNeT++||IDE / C++ development||public||2011-06-10 14:12||2011-06-10 14:12|
|Target Version||Fixed in Version|
|Summary||0000340: Missing make target dependency when building with statically linked libraries|
|Description||Let's say that module FOO depends on module BAR. The build system is configured such that BAR builds a statically linked library, and FOO builds an executable linked with the library of BAR. When a build for FOO is requested the build system automatically rebuilds the statically linked library of BAR if one of its C++ source files changed. So far so great!|
The problem is that the FOO executable is not rebuilt! This happens because the makefile dependency between the executable of FOO and the library of BAR is missing.
This not only happens in the same project. It also happens cross project and when only statically linked libraries are involved.
The actual example I found was this:
- INET built as a statically linked library
- MIXIM built as multiple statically linked libraries (depending on the library of INET)
- MIXNET built as a statically linked library (depending on the libraries of MIXIM and INET)
- a MIXNET example built as an executable (depending on the libraries of MIXNET)
Changing a C++ source file in INET caused to rebuild the library of INET and stopped there.
Adding lines such as:
$O/$(TARGET): $(INET_PROJ)/out/$(CONFIGNAME)/src/inet.lib $(MIXIM_PROJ)/out/$(CONFIGNAME)/base/miximbase.lib $(MIXIM_PROJ)/out/$(CONFIGNAME)/modules/miximmodules.lib
etc. could workaround this problem. It is difficult to figure this out and it is very inconvenient when one has a couple of executables and libraries.
Of course we all know that with dynamically linked libraries this looks differently...
|Tags||No tags attached.|
|2011-06-10 14:12||levy||New Issue|
|Copyright © 2000 - 2022 MantisBT Team|