Commit Graph

6 Commits

Author SHA1 Message Date
nikolas b24546706e Fix a few docs typos (#10907)
Found with [codespell](https://github.com/codespell-project/codespell)
2018-11-24 04:28:39 +09:00
Zbigniew Jędrzejewski-Szmek cd7bcfa8fe CODING_STYLE: describe log & return operations 2018-11-22 10:54:38 +01:00
Zbigniew Jędrzejewski-Szmek a98dc693e4 CODING_STYLE: fix rules for STRLEN and recommend strjoina more strongly
Again, this mostly matches what is happening in the codebase already.
2018-11-20 07:27:37 +01:00
Zbigniew Jędrzejewski-Szmek a527f70a41 CODING_STYLE: clarify the rules for the src/basic & src/shared split
The rule is changed from "put in basic unless there's a reason not to" to "put
in shared unless there's a reason not to", to match the change done in previous
commit. This minimizes libbasic. See previous commit for the reasons why this
is useful.

Previously, the guideline was based on whether the files in question use
"publicly exported APIs". This distinction is not particularly relevant. Let's
consider all other programs we compile: most of them use "publicly exported
APIs", usually linking to libsystemd-shared.so for the actual code. But those
programs are not forced to be in src/basic, and the distinction whether they
happen to use 'sd-*.h' or not is of no importance. The same is true for files
in src/shared/. If we didn't have publicly exported shared objects, we'd put
everything in libsystemd-shared.so. So let's only move things out of it that we
need to. Previous guideline was not "wrong", in the sense that it created *a*
split that was functional (no code in src/shared was required in the publicly
exported shared objects), but it put more files in basic/ then necessary.

Not much changes in practice, because (as previous commit shows), moving files
between libbasic.a and libsystemd-shared.so mostly just changes compilation
order.

The list of components which cannot use libsystemd-shared.so is adjusted.
2018-11-20 07:27:37 +01:00
Felix Yan 3cc306e667 docs: Fix a typo in CODING_STYLE.md (#10630) 2018-11-03 17:38:41 +09:00
Faheel Ahmad 82143987b3 docs: Convert CODING_STYLE to Markdown
Also fix minor grammatical errors
2018-10-30 15:58:44 +05:30