Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:Leap:42.2:Update
NetworkManager-novellvpn
nm-nvpn-libnl3.patch
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File nm-nvpn-libnl3.patch of Package NetworkManager-novellvpn
--- NetworkManager-novellvpn-0.9.0.orig/configure.in +++ NetworkManager-novellvpn-0.9.0/configure.in @@ -104,7 +104,7 @@ if test x"$with_gnome" != xno; then AC_SUBST(DISABLE_DEPRECATED) fi -PKG_CHECK_MODULES(LIBNL, libnl-1) +PKG_CHECK_MODULES(LIBNL, libnl-3.0 >= 3.1 libnl-route-3.0) AC_SUBST(LIBNL_CFLAGS) AC_SUBST(LIBNL_LIBS) --- NetworkManager-novellvpn-0.9.0.orig/src/mtu.c +++ NetworkManager-novellvpn-0.9.0/src/mtu.c @@ -37,6 +37,12 @@ #include <netlink/route/rtnl.h> #include <netlink/route/route.h> +#define nlmsg_build_simple(a, b) nlmsg_alloc_simple(a, b) +#define nl_recvmsgs_def(handle) nl_recvmsgs_default(handle) +#define nl_handle_alloc_cb nl_socket_alloc_cb +#define nl_handle_destroy nl_socket_free +#define nl_handle nl_sock + static unsigned int mtu = 0; static struct nla_policy route_policy[RTA_MAX+1] = { @@ -84,6 +90,7 @@ int get_mtu(const char *dest_str) struct nl_cache *link_cache, *route_cache; struct nl_addr *dst; struct nl_cb *callback = NULL; + int err; callback = nl_cb_alloc(NL_CB_VERBOSE); if (!callback) @@ -97,16 +104,13 @@ int get_mtu(const char *dest_str) if (nl_connect(nlh, NETLINK_ROUTE) < 0) goto errout_free_handle; - link_cache = rtnl_link_alloc_cache(nlh); - if (!link_cache) + if(rtnl_link_alloc_cache(nlh, AF_UNSPEC, &link_cache) < 0) goto errout_close; - dst = nl_addr_parse(dest_str, AF_UNSPEC); - if (!dst) + if(nl_addr_parse(dest_str, AF_UNSPEC, &dst) < 0) goto errout_link_cache; - route_cache = rtnl_route_alloc_cache(nlh); - if (!route_cache) + if(rtnl_route_alloc_cache(nlh, AF_UNSPEC, NL_AUTO_PROVIDE , &route_cache) < 0) goto errout_addr_put; { @@ -121,9 +125,9 @@ int get_mtu(const char *dest_str) nla_put_addr(m, RTA_DST, dst); //if ((nl_send_auto_complete(nlh, nlmsg_hdr(m))) < 0) { - if ((nl_send_auto_complete(nlh, m)) < 0) { + if ((err = (nl_send_auto_complete(nlh, m))) < 0) { nlmsg_free(m); - fprintf(stderr, "%s\n", nl_geterror()); + fprintf(stderr, "%s\n", nl_geterror(err)); goto errout_route_cache; } @@ -133,8 +137,8 @@ int get_mtu(const char *dest_str) nl_cb_set(callback, NL_CB_VALID, NL_CB_CUSTOM, route_msg_parser, route_cache); - if (nl_recvmsgs_def(nlh) < 0) { - fprintf(stderr, "%s\n", nl_geterror()); + if ((err = nl_recvmsgs_def(nlh)) < 0) { + fprintf(stderr, "%s\n", nl_geterror(err)); goto errout_route_cache; } } --- NetworkManager-novellvpn-0.9.0.orig/src/Makefile.am +++ NetworkManager-novellvpn-0.9.0/src/Makefile.am @@ -23,7 +23,7 @@ nm_novellvpn_service_SOURCES = \ nm-novellvpn-service.c \ nm-novellvpn-service.h - +nm_novellvpn_service_LDFLAGS = -no-undefined nm_novellvpn_service_LDADD = \ $(DBUS_LIBS) \ $(GTHREAD_LIBS) \ @@ -31,7 +31,7 @@ nm_novellvpn_service_LDADD = \ -lnm-glib-vpn - +nm_novellvpn_service_novellvpn_helper_LDFLAGS = -no-undefined nm_novellvpn_service_novellvpn_helper_SOURCES = \ nm-novellvpn-service-novellvpn-helper.c \ mtu.c
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor