-
Type: Improvement
-
Resolution: Duplicate
-
Priority: Major - P3
-
None
-
Affects Version/s: None
-
Component/s: Build
Currently, our libraries that we make as part of our build process are not composable. This is a result of three separate issues.
1. Libraries don't always list libraries that they depend on as LIBDEPS
2. Libraries can be "codependent" on another library (circular dependency)
3. Libraries can depend on symbols at a higher level (multiple definitions of the same symbol)
This prevents us from:
a. Writing unittests that only pull in the dependencies they need
b. Writing mongo tools that only pull in the dependencies they need
c. Writing mongo tools that have a clear boundary between the tool code and the server code
d. Clearly defining/unittesting the external interface to a library
e. Replacing libraries independently
f. Proving that changes to unrelated libraries will not affect each other (for example, changes to the C++ driver should not break journaling, and that should be clear from our library structure)
g. Sharing the same unittested code effectively (currently the fact that we have to define "stubs" to make the build link means that code that appears to be properly shared calls code that is not shared. For example, "inShutdown" is defined in 14 different places, with different implementations. Some implementations are thread safe, and some implementations are static initialization safe, and it is unclear whether we are depending on that behavior)
f. Enabling the compilation of a variety of different executables, with behavior and functionality based on what libraries and subsystems the executable is compiled with
g. Making the libraries into shared libraries to reduce build times during development
I think this ticket should be split into sub tasks, but this parent ticket can keep the problem description and any general comments on this task.
- depends on
-
SERVER-10307 Break unlisted circular dependency between logger and foundation libraries.
- Closed
- duplicates
-
SERVER-9666 Reorganize relationship between sources, targets, and SConscripts.
- Closed
- related to
-
SERVER-13863 JS engines shouldn't be linked in to mongos or tools
- Closed
-
SERVER-11538 libserver_options.a does not depend on what it needs to link
- Closed
-
SERVER-9704 break out socket "library" and use it to initialize Windows sockets
- Closed