Build fails with ppp 2.5.0
I cannot build current stable release (1.42.4) with ppp 2.5.0:
../src/core/ppp/nm-pppd-plugin.c: In function ‘nm_phasechange’:
../src/core/ppp/nm-pppd-plugin.c:128:34: error: ‘ifname’ undeclared (first use in this function); did you mean ‘tzname’?
128 | ifindex = if_nametoindex(ifname);
| ^~~~~~
| tzname
../src/core/ppp/nm-pppd-plugin.c:128:34: note: each undeclared identifier is reported only once for each function it appears in
In file included from ../src/core/ppp/nm-pppd-plugin.c:14:
../src/core/ppp/nm-pppd-plugin.c: In function ‘nm_ip_up’:
../src/core/ppp/nm-pppd-plugin.c:169:63: error: ‘ifunit’ undeclared (first use in this function)
169 | guint32 pppd_made_up_address = htonl(0x0a404040 + ifunit);
| ^~~~~~
../src/core/ppp/nm-pppd-plugin.c:189:48: error: ‘ifname’ undeclared (first use in this function); did you mean ‘tzname’?
189 | g_variant_new_string(ifname));
| ^~~~~~
| tzname
../src/core/ppp/nm-pppd-plugin.c: In function ‘nm_ip6_up’:
../src/core/ppp/nm-pppd-plugin.c:295:48: error: ‘ifname’ undeclared (first use in this function); did you mean ‘tzname’?
295 | g_variant_new_string(ifname));
| ^~~~~~
| tzname
../src/core/ppp/nm-pppd-plugin.c: In function ‘add_ip6_notifier’:
../src/core/ppp/nm-pppd-plugin.c:409:9: warning: implicit declaration of function ‘add_notifier’; did you mean ‘add_ip6_notifier’? [-Wimplicit-function-declaration]
409 | add_notifier(notifier, nm_ip6_up, NULL);
| ^~~~~~~~~~~~
| add_ip6_notifier
In file included from /usr/include/glib-2.0/glib/gstring.h:37,
from /usr/include/glib-2.0/glib/giochannel.h:36,
from /usr/include/glib-2.0/glib.h:56,
from ../src/libnm-glib-aux/nm-default-glib.h:18,
from ../src/core/ppp/nm-pppd-plugin.c:23:
../src/core/ppp/nm-pppd-plugin.c: In function ‘plugin_init’:
../src/core/ppp/nm-pppd-plugin.c:430:27: error: ‘ipparam’ undeclared (first use in this function)
430 | gl.ipparam = g_strdup(ipparam);
| ^~~~~~~
/usr/include/glib-2.0/glib/gstrfuncs.h:324:38: note: in definition of macro ‘g_strdup’
324 | #define g_strdup(x) g_strdup_inline (x)
| ^
../src/core/ppp/nm-pppd-plugin.c:432:5: error: ‘chap_passwd_hook’ undeclared (first use in this function)
432 | chap_passwd_hook = get_credentials;
| ^~~~~~~~~~~~~~~~
../src/core/ppp/nm-pppd-plugin.c:433:5: error: ‘chap_check_hook’ undeclared (first use in this function)
433 | chap_check_hook = get_chap_check;
| ^~~~~~~~~~~~~~~
../src/core/ppp/nm-pppd-plugin.c:434:5: error: ‘pap_passwd_hook’ undeclared (first use in this function)
434 | pap_passwd_hook = get_credentials;
| ^~~~~~~~~~~~~~~
../src/core/ppp/nm-pppd-plugin.c:435:5: error: ‘pap_check_hook’ undeclared (first use in this function)
435 | pap_check_hook = get_pap_check;
| ^~~~~~~~~~~~~~
../src/core/ppp/nm-pppd-plugin.c:437:19: error: ‘phasechange’ undeclared (first use in this function); did you mean ‘nm_phasechange’?
437 | add_notifier(&phasechange, nm_phasechange_hook, NULL);
| ^~~~~~~~~~~
| nm_phasechange
../src/core/ppp/nm-pppd-plugin.c:438:19: error: ‘ip_up_notifier’ undeclared (first use in this function); did you mean ‘add_ip6_notifier’?
438 | add_notifier(&ip_up_notifier, nm_ip_up, NULL);
| ^~~~~~~~~~~~~~
| add_ip6_notifier
../src/core/ppp/nm-pppd-plugin.c:439:19: error: ‘exitnotify’ undeclared (first use in this function); did you mean ‘nm_exit_notify’?
439 | add_notifier(&exitnotify, nm_exit_notify, NULL);
| ^~~~~~~~~~
| nm_exit_notify
I think, this commit causes the problem: https://github.com/ppp-project/ppp/commit/ba7f7e053daae846a54a1d08d3d133a5f1266ace
Edited by Thomas Haller