@@ -42,9 +42,28 @@ doxygen_extension = use_extension("@rules_doxygen//:extensions.bzl", "doxygen_ex
4242use_repo(doxygen_extension, " doxygen" )
4343```
4444
45- By default, version ` 1.12.0 ` of Doxygen is used. To select a different version, indicate it in the ` version ` module:
45+ By default, version ` 1.12.0 ` of Doxygen is used.
46+ You can override this value with a custom one for each supported platform, i.e. _ windows_ , _ mac_ and _ linux_ .
4647
47- If you don't know the SHA256 of the Doxygen binary, just leave it empty.
48+ ``` bzl
49+ # MODULE.bazel file
50+
51+ bazel_dep(name = " rules_doxygen" , version = " ..." , dev_dependency = True )
52+
53+ doxygen_extension = use_extension(" @rules_doxygen//:extensions.bzl" , " doxygen_extension" )
54+
55+ # Download doxygen version 1.10.0 on linux, default version on all other platforms
56+ doxygen_extension.version(
57+ version = " 1.10.0" ,
58+ sha256 = " dcfc9aa4cc05aef1f0407817612ad9e9201d9bf2ce67cecf95a024bba7d39747" ,
59+ platform = " linux" ,
60+ )
61+
62+ use_repo(doxygen_extension, " doxygen" )
63+ ```
64+
65+ When you do so, you must also provide the SHA256 of the given doxygen installation.
66+ If you don't know the SHA256 value, just leave it empty.
4867The build will fail with an error message containing the correct SHA256.
4968
5069``` bash
@@ -100,6 +119,8 @@ Only the sources are required, the rest of the parameters are optional.
100119``` bzl
101120# My BUILD.bazel file
102121
122+ load(" @doxygen//:doxygen.bzl" , " doxygen" )
123+
103124doxygen(
104125 name = " doxygen" , # Name of the rule, can be anything
105126 srcs = glob([ # List of sources to document.
@@ -137,6 +158,8 @@ For example, if the _BUILD.bazel_ file is in the root of the repository, and the
137158``` bzl
138159# BUILD.bazel file in the root of the repository
139160
161+ load(" @doxygen//:doxygen.bzl" , " doxygen" )
162+
140163doxygen(
141164 name = " doxygen" ,
142165 srcs = glob([
0 commit comments