diff --git a/doc/Install_develop.rst b/doc/Install_develop.rst index bf4fb03102316f5f2e6e0b85337892317b0f0483..9704ada8e982dd7881a220433cce101c4f4def97 100644 --- a/doc/Install_develop.rst +++ b/doc/Install_develop.rst @@ -4,7 +4,7 @@ How to use and develop libcaosdb Dependencies ------------ -- See the `dependencies <DEPENDENCIES.md>`__ file, install with ``pip install -r requiremens.txt``. +- See the `dependencies <DEPENDENCIES.md>`__ file, install with ``pip install -r requirements.txt``. Build ----- @@ -26,9 +26,9 @@ We use `cmake <https://cmake.org>`__ as build tool, with Conan as package manager. The compiler must support the C++17 standard. 1. clone/update the subrepo ``git submodule update --init proto`` -2. ``mkdir build && cd build`` -3. ``conan install .. -s "compiler.libcxx=libstdc++11"`` -4. ``cmake -B . ..`` +2. ``conan install . -s build_type=Release --build=missing`` +3. ``cd build/Release`` +4. ``cmake .`` 5. ``cmake --build .`` You may also want to install libcaosdb system-wide to @@ -38,7 +38,7 @@ You may also want to install libcaosdb system-wide to The default install prefix is ``~/.local``. It can be set by adding ``-DCMAKE_INSTALL_PREFIX=/path/to/install/prefix`` to the first cmake -command (3.). +command (4.). .. Note:: @@ -54,15 +54,7 @@ to merge requests which support multiple ways of installation. How to build on MacOS ~~~~~~~~~~~~~~~~~~~~~ -If you use apple-clang as the compiler: Instead of the above conan -command (2.) use - -1. ``conan install .. -s "compiler.cppstd=17"`` - -and continue as you would when building on a Linux system. You may have -to add ``build/lib/`` (or, alternatively after installation, -``CMAKE_INSTALL_PREFIX/lib``) to your ``DYLD_LIBRARY_PATH`` -environmental variable. +... is currently untested. Problems and solutions ^^^^^^^^^^^^^^^^^^^^^^ @@ -77,14 +69,13 @@ How to build on Windows ~~~~~~~~~~~~~~~~~~~~~~~ We use `Visual Studio -2019 <https://visualstudio.microsoft.com/de/vs/features/cplusplus/>`__ +2022 <https://visualstudio.microsoft.com/de/vs/features/cplusplus/>`__ as compiler. We use `cmake <https://cmake.org/download/>`__ as build tool. 1. clone/update the subrepo ``git submodule update --init proto`` -2. ``mkdir build`` -3. ``cd build`` -4. ``conan install .. -g visual_studio -s arch=x86_64 -s build_type=Release -s compiler.toolset=v142 -s compiler.version=16 -s compiler.runtime=MD --build=missing --update`` +2. ``conan install .. -g visual_studio -s arch=x86_64 -s build_type=Release -s compiler.toolset=v142 -s compiler.version=16 -s compiler.runtime=MD --build=missing --update`` +3. ``cd build/Release`` 5. ``cmake -B . ..`` 6. open ``libcaosdb.sln`` with Visual Studio, change the buildtype to ``Release`` and build the project. (You can open Tools/Command @@ -103,6 +94,17 @@ Known problems Troubleshooting ~~~~~~~~~~~~~~~ +ERROR: The default build profile '~/.conan2/profiles/default' doesn't exist +^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + +Follow the instructions and run + +.. code:: console + + conan profile detect + +Check the output and adjust settings if necessary. + Warning: WARNING: GCC OLD ABI COMPATIBILITY ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -175,13 +177,11 @@ Unit tests Build ^^^^^ -For the tests there is a slightly different setup required (with option -``-D CMAKE_BUILD_TYPE=Debug``) +For the tests the build type has to be Debug. As a shorthand you can run ``make +test``. If you want to build manually, follow these steps: -1. ``mkdir build && cd build/`` -2. ``conan install ..`` (with gcc, append - ``-s "compiler.libcxx=libstdc++11"``, with apple-clang, append - ``-s compiler.cppstd=17``) +1. ``conan install . -s build_type=Debug`` +2. ``cd build/Debug`` 3. ``cmake -B . -D CMAKE_BUILD_TYPE=Debug ..`` - If your clang-format version is too old, formatting, linting etc. can be skipped: