Skip to content

CMake: Replace use of OBJECT with STATIC #13237

@magnesj

Description

@magnesj

ResInsight is split into several libraries that are linked into ResInsight. The libraries are defined using the OBJECT type

add_library(${PROJECT_NAME} OBJECT ${ALL_SOURCE_FILES})

Class view information is not displayed correctly in Visual Studio when using this concept. Consider replace with STATIC for all libraries linked with the ResInsight target. Testing revealed a required the following to be added

  Q_INIT_RESOURCE( ApplicationLibCode );

to main() in RiaMain.cpp

Some examples when the OBJECT keyword was introduced:
77ef87f
01921a5

Metadata

Metadata

Assignees

No one assigned

    Labels

    SystemRefactoring or build/test system issues. Code improvments not directly affecting the user.

    Type

    No type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions