Added documentation about clang-uml-wrapped script for Nix
This commit is contained in:
@@ -11,6 +11,7 @@
|
|||||||
* [Use '--query-driver' command line option](#use---query-driver-command-line-option)
|
* [Use '--query-driver' command line option](#use---query-driver-command-line-option)
|
||||||
* [Manually add and remove compile flags from the compilation database](#manually-add-and-remove-compile-flags-from-the-compilation-database)
|
* [Manually add and remove compile flags from the compilation database](#manually-add-and-remove-compile-flags-from-the-compilation-database)
|
||||||
* [Using 'CMAKE_CXX_IMPLICIT_INCLUDE_DIRECTORIES'](#using-cmake_cxx_implicit_include_directories)
|
* [Using 'CMAKE_CXX_IMPLICIT_INCLUDE_DIRECTORIES'](#using-cmake_cxx_implicit_include_directories)
|
||||||
|
* [Nix wrapper](#nix-wrapper)
|
||||||
|
|
||||||
<!-- tocstop -->
|
<!-- tocstop -->
|
||||||
|
|
||||||
@@ -224,4 +225,12 @@ Yet another option, for CMake based projects, is to use the following CMake opti
|
|||||||
set(CMAKE_CXX_STANDARD_INCLUDE_DIRECTORIES ${CMAKE_CXX_IMPLICIT_INCLUDE_DIRECTORIES})
|
set(CMAKE_CXX_STANDARD_INCLUDE_DIRECTORIES ${CMAKE_CXX_IMPLICIT_INCLUDE_DIRECTORIES})
|
||||||
```
|
```
|
||||||
|
|
||||||
|
### Nix wrapper
|
||||||
|
On NixOS or when using `nix`, `clang-uml` provides a wrapper script called
|
||||||
|
`clang-uml-wrapped`, which builds and exports `CPATH` and `CPLUS_INCLUDE_PATH`
|
||||||
|
environment variables before running `clang-uml`, which contain valid
|
||||||
|
system header Clang paths for the current Nix environment.
|
||||||
|
|
||||||
|
The `clang-uml-wrapped` script can be called the same way as `clang-uml` and
|
||||||
|
should resolve the system include paths without the need for any of the above
|
||||||
|
solutions.
|
||||||
|
|||||||
@@ -11,8 +11,8 @@
|
|||||||
* [Cannot generate diagrams from header-only projects](#cannot-generate-diagrams-from-header-only-projects)
|
* [Cannot generate diagrams from header-only projects](#cannot-generate-diagrams-from-header-only-projects)
|
||||||
* [YAML anchors and aliases are not fully supported](#yaml-anchors-and-aliases-are-not-fully-supported)
|
* [YAML anchors and aliases are not fully supported](#yaml-anchors-and-aliases-are-not-fully-supported)
|
||||||
* [Schema validation error is thrown, but the configuration file is correct](#schema-validation-error-is-thrown-but-the-configuration-file-is-correct)
|
* [Schema validation error is thrown, but the configuration file is correct](#schema-validation-error-is-thrown-but-the-configuration-file-is-correct)
|
||||||
* [Class diagrams](#class-diagrams)
|
|
||||||
* ["fatal error: 'stddef.h' file not found"](#fatal-error-stddefh-file-not-found)
|
* ["fatal error: 'stddef.h' file not found"](#fatal-error-stddefh-file-not-found)
|
||||||
|
* [Class diagrams](#class-diagrams)
|
||||||
* [How can I generate class diagram of my entire project](#how-can-i-generate-class-diagram-of-my-entire-project)
|
* [How can I generate class diagram of my entire project](#how-can-i-generate-class-diagram-of-my-entire-project)
|
||||||
* [Cannot generate classes for 'std' namespace](#cannot-generate-classes-for-std-namespace)
|
* [Cannot generate classes for 'std' namespace](#cannot-generate-classes-for-std-namespace)
|
||||||
* [Sequence diagrams](#sequence-diagrams)
|
* [Sequence diagrams](#sequence-diagrams)
|
||||||
@@ -224,8 +224,6 @@ schema validation, and exits if the configuration file is invalid.
|
|||||||
In case there is a bug in the schema validation, the schema validation
|
In case there is a bug in the schema validation, the schema validation
|
||||||
step can be skipped by providing `--no-validate` command line option.
|
step can be skipped by providing `--no-validate` command line option.
|
||||||
|
|
||||||
## Class diagrams
|
|
||||||
|
|
||||||
### "fatal error: 'stddef.h' file not found"
|
### "fatal error: 'stddef.h' file not found"
|
||||||
|
|
||||||
This error means that Clang cannot find some standard headers in include
|
This error means that Clang cannot find some standard headers in include
|
||||||
@@ -285,6 +283,8 @@ clang-uml --add-compile-flag -I/opt/my_toolchain/include \
|
|||||||
Also see
|
Also see
|
||||||
[here](./md_docs_2common__options.html#resolving-include-path-and-compiler-flags-issues).
|
[here](./md_docs_2common__options.html#resolving-include-path-and-compiler-flags-issues).
|
||||||
|
|
||||||
|
## Class diagrams
|
||||||
|
|
||||||
### How can I generate class diagram of my entire project
|
### How can I generate class diagram of my entire project
|
||||||
|
|
||||||
I want to generate a diagram containing all classes and relationships in my
|
I want to generate a diagram containing all classes and relationships in my
|
||||||
|
|||||||
@@ -32,7 +32,7 @@ stdenv.mkDerivation {
|
|||||||
postInstall = ''
|
postInstall = ''
|
||||||
export unwrapped_clang_uml="$out/bin/clang-uml"
|
export unwrapped_clang_uml="$out/bin/clang-uml"
|
||||||
|
|
||||||
# inject clang and unwrapp_clang_uml variables into wrapper
|
# inject clang and unwrap_clang_uml variables into wrapper
|
||||||
substituteAll ${./wrapper} $out/bin/clang-uml-wrapped
|
substituteAll ${./wrapper} $out/bin/clang-uml-wrapped
|
||||||
chmod +x $out/bin/clang-uml-wrapped
|
chmod +x $out/bin/clang-uml-wrapped
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user