diameterc(1)
β¨ NAME β¨
okay so bestie, this is diameterc(1) β the Erlang module definition girlies' fave little compiler. Her whole job? Compile a diameter dictionary to Erlang source. That's it. That's the gig. π
π SYNOPSIS π
diameterc [<options>] <file>
π¦ DESCRIPTION π¦
So the diameterc utility is what you use to compile a diameter dictionary file into Erlang source. The resulting source implements the interface diameter needs to encode and decode the dictionary's messages and AVPs. Slay.
Also, heads up: the module diameter_make provides an alternate compilation interface. Two roads, same destination, pick your fighter. β¨
π USAGE π
Compile a single dictionary file to Erlang source. The valid options are as follows, and yes we're going through every single one, no skips. π
-i <dir>β Prepend the specified directory to the code path. Use this to point at beam files compiled from inherited dictionaries β like,@inheritsin a dictionary file creates a beam dependency, not anerl/hrldependency. Just so you know.
You can specify multiple -i options. Stack 'em up. π«Ά
-o <dir>β Write the generated source to the specified directory. Defaults to the current working directory.-Eβ Suppress.erlfile generation. No.erlfor you. π-Hβ Suppress.hrlfile generation. Similarly, no.hrl. π--name <name>β Name the output module. Give her a name, she deserves one. β--prefix <prefix>β Transform the input dictionary before compilation, setting@nameor@prefixto the specified string.--inherits <arg>β Transform the input dictionary before compilation, appending@inheritsof the specified string.
Two forms of --inherits have special meaning:
--inherits ---inherits Prev/Mod
The first one has the effect of clearing any previous inherits. The second one replaces a previous inherits of Prev to one of Mod. Which like β iconic behaviour, because it lets you change the semantics of the input dictionary without modifying the file itself. No touchy the file. π§
Multiple --inherits options can be specified.
--indirect-inheritsβ Enables the indirect inherits feature, see more here.
π EXIT STATUS π
Returns 0 on success, non-zero on failure. Simple as that, bestie. π
π SEE ALSO π
diameter_makediameter_dict(4)
and that's the whole thing!! π go forth and compile, you absolute main character. this was Ericsson AB's diameterc, from diameter 2.7.2 β ty for coming to my ted talk, mwah πβ¨π
π¦ where this page comes from
- arch rolling: erlang-diameter 29.1.1-1 Β· Apache-2.0
- nixos 26.05: erlang 29.1.2
- nixpkgs unstable: erlang 29.1.2
- ubuntu stonking: erlang-diameter 1:29.0.6+dfsg-1 Β· Apache-2.0
- ubuntu stonking: erlang-doc 1:29.0.6+dfsg-1 Β· Apache-2.0
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms