<h3>Contribution description</h3>
<p>This adds a simple syslog module that prints string whose format is compatible with rfc5424.</p>
<p>This module is organized into 2 layers:</p>
<ul>
<li>a core that receives logs, format them, and dispatch them to backends</li>
<li>backends that actually print strings. At the moment stdio and file backend are implemented.</li>
</ul>
<p>stdio backend simply prints out to stdio.<br>
File backend prints in a file and take care of file rotation (configurable at build time).</p>
<p>API-wise, it is inspired by Linux' syslog API. The entry point is <code>(v)syslog</code> and optionally <code>openlog</code> and <code>closelog</code> can be built to allow adding different log entries.</p>
<h3>Testing procedure</h3>
<p><code>tests/syslog</code> provides some simple commands to do basic tests.</p>
<h3>Issues/PRs references</h3>
<p>Some parts of header files were initially inspired by <a class="issue-link js-issue-link" data-error-text="Failed to load title" data-id="431019898" data-permission-text="Title is private" data-url="https://github.com/RIOT-OS/RIOT/issues/11362" data-hovercard-type="pull_request" data-hovercard-url="/RIOT-OS/RIOT/pull/11362/hovercard" href="https://github.com/RIOT-OS/RIOT/pull/11362">#11362</a></p>

<hr>

<h4>You can view, comment on, or merge this pull request online at:</h4>
<p>  <a href='https://github.com/RIOT-OS/RIOT/pull/15739'>https://github.com/RIOT-OS/RIOT/pull/15739</a></p>

<h4>Commit Summary</h4>
<ul>
  <li>syslog: add basic syslog implementation</li>
  <li>shell: add syslog commands</li>
  <li>tests: add syslog test app</li>
</ul>

<h4>File Changes</h4>
<ul>
  <li>
    <strong>M</strong>
    <a href="https://github.com/RIOT-OS/RIOT/pull/15739/files#diff-4aa223e6cede5347163d1859fbd80e29f26bc5135189cec8bba2f8258d3b83df">core/include/log.h</a>
    (23)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/RIOT-OS/RIOT/pull/15739/files#diff-d2e4f5b2cddc5eddb20e42bf88b7b16085ba4599fab8081e6f6168f60e12fedb">makefiles/pseudomodules.inc.mk</a>
    (1)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/RIOT-OS/RIOT/pull/15739/files#diff-40221b527f89f8921510187a75904a945b2dad9b19c4c175025c2dbe148dd6e1">sys/Kconfig</a>
    (1)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/RIOT-OS/RIOT/pull/15739/files#diff-df69fd2c7840fcaca7dae211c7df24745d202e8482f8d5f0957cc15ef90b948f">sys/Makefile.dep</a>
    (8)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/RIOT-OS/RIOT/pull/15739/files#diff-f320667a845b6ce54eaca933c2f1c91090cd2681de834fe09ed871c8cf229ca8">sys/auto_init/auto_init.c</a>
    (4)
  </li>
  <li>
    <strong>A</strong>
    <a href="https://github.com/RIOT-OS/RIOT/pull/15739/files#diff-1645a1a6c5b0e4572639165e2078c0f5225e5f4e48c2783e5f8da3dbf42ef422">sys/include/syslog.h</a>
    (276)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/RIOT-OS/RIOT/pull/15739/files#diff-953fa46b81da7551b516591c87c1a22bd2c152aac8c8d6b3018c969bcd388bd4">sys/shell/commands/Makefile</a>
    (4)
  </li>
  <li>
    <strong>A</strong>
    <a href="https://github.com/RIOT-OS/RIOT/pull/15739/files#diff-110e9110794437c9c1ddc1e392cdb5bda94ea5ed742502f354e8b7702282dafe">sys/shell/commands/sc_syslog.c</a>
    (64)
  </li>
  <li>
    <strong>M</strong>
    <a href="https://github.com/RIOT-OS/RIOT/pull/15739/files#diff-641eee708eaa24de4a324f1a813ac62bd6b4e3bc62977d40f364987c8e9bea7c">sys/shell/commands/shell_commands.c</a>
    (7)
  </li>
  <li>
    <strong>A</strong>
    <a href="https://github.com/RIOT-OS/RIOT/pull/15739/files#diff-ff06726a34b03f9e011ed2bc2bf0b9e06cc14333074afcb9e10f0333477f4d0a">sys/syslog/Kconfig</a>
    (100)
  </li>
  <li>
    <strong>A</strong>
    <a href="https://github.com/RIOT-OS/RIOT/pull/15739/files#diff-f8d28482e977fc8dc085899abba90f0d6a712833035a1a18d1ecdbaa0aae614e">sys/syslog/Makefile</a>
    (7)
  </li>
  <li>
    <strong>A</strong>
    <a href="https://github.com/RIOT-OS/RIOT/pull/15739/files#diff-4232b1b3a460a81d164d7273804e4bcbc6b3b9c6955a6c2bf68454f62020f7f5">sys/syslog/backend.c</a>
    (50)
  </li>
  <li>
    <strong>A</strong>
    <a href="https://github.com/RIOT-OS/RIOT/pull/15739/files#diff-9c834c307e6bcfeb4edc782d2f404de895d709823c46f8cd7905db5ec77606e7">sys/syslog/backend.h</a>
    (109)
  </li>
  <li>
    <strong>A</strong>
    <a href="https://github.com/RIOT-OS/RIOT/pull/15739/files#diff-f778d0816862c4c4c248c98708993e4aa5c0f8e28d78323ad2a85c93e2e41748">sys/syslog/backend_file.c</a>
    (211)
  </li>
  <li>
    <strong>A</strong>
    <a href="https://github.com/RIOT-OS/RIOT/pull/15739/files#diff-ba597c9a91245886439d351fb547c14ef2d96e87eef59edd9ce5179921385940">sys/syslog/syslog.c</a>
    (621)
  </li>
  <li>
    <strong>A</strong>
    <a href="https://github.com/RIOT-OS/RIOT/pull/15739/files#diff-9ad6a4fdb3e17e13f8e13df049d4ef21a5c4f03c7c6761294f974f0a8b9f3d6f">tests/syslog/Makefile</a>
    (18)
  </li>
  <li>
    <strong>A</strong>
    <a href="https://github.com/RIOT-OS/RIOT/pull/15739/files#diff-90c874ac72c1a4fa8c7784ddc7434531f5b8ddf7dd96e4abc6592985b63263e9">tests/syslog/main.c</a>
    (96)
  </li>
</ul>

<h4>Patch Links:</h4>
<ul>
  <li><a href='https://github.com/RIOT-OS/RIOT/pull/15739.patch'>https://github.com/RIOT-OS/RIOT/pull/15739.patch</a></li>
  <li><a href='https://github.com/RIOT-OS/RIOT/pull/15739.diff'>https://github.com/RIOT-OS/RIOT/pull/15739.diff</a></li>
</ul>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/RIOT-OS/RIOT/pull/15739">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/ABE7WYD4MLLOQE65N7NPEZLSZMMQXANCNFSM4V5YB65Q">unsubscribe</a>.<img src="https://github.com/notifications/beacon/ABE7WYELARISNGZCFORIV3DSZMMQXA5CNFSM4V5YB652YY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4LVTA5JA.gif" height="1" width="1" alt="" /></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/RIOT-OS/RIOT/pull/15739",
"url": "https://github.com/RIOT-OS/RIOT/pull/15739",
"name": "View Pull Request"
},
"description": "View this Pull Request on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>