Re: [PATCH 2/2] dhcp: Add missing include to systemd DHCP client



On Fri, 2018-01-05 at 14:17 +0100, Iñigo Martínez wrote:
In a recent commit 686afe531ab3774cd818feda8361de74101971f5, a new
macro called `_NM_SD_MAX_CLIENT_ID_LEN` was introduced. However, the
systemd DHCP client handler did not include the file where the
macro was defined, `nm-types.h`. Although this worked in autotools,
it fails on meson.

The include has been added to the `sd-dhcp-client.c` file and due
to two existing `nm-types.h` files, to avoid any issue finding the
macro, the `libnm` directory include has been removed.
---
 src/systemd/meson.build                             | 1 -
 src/systemd/src/libsystemd-network/sd-dhcp-client.c | 1 +
 2 files changed, 1 insertion(+), 1 deletion(-)


Hi,


the patch is parly wrong, and the commit message too.

"src/nm-types.h" gets automatically included by "shared/nm-default.h".
It should never be included directly. Also, the files under
src/systemd/src are a fork from systemd code. We should do only minimal
changes to that code. Like, only include "nm-sd-adapt.h", nothing else.

The build failure was caused by the wrong "libnm_inc" in
src/systemd/meson.build. With this, it would include "libnm/nm-
types.h", instead of "src/nm-types.h".


Merged a modified version of this patch, after rewording the commit
message:

https://cgit.freedesktop.org/NetworkManager/NetworkManager/commit/?id=876de69e08140ff34ede23fe457117f5d815ab48


Thanks!
Thomas

Attachment: signature.asc
Description: This is a digitally signed message part



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]