diff -Nru sysdig-0.19.1/debian/changelog sysdig-0.19.1/debian/changelog --- sysdig-0.19.1/debian/changelog 2018-11-23 06:05:36.000000000 -0800 +++ sysdig-0.19.1/debian/changelog 2019-05-14 12:32:24.000000000 -0700 @@ -1,3 +1,11 @@ +sysdig (0.19.1-1ubuntu1.1) bionic; urgency=medium + + * Fix build for Linux 5.0 (LP: #1826845) + - debian/patches/0001-Update-for-change-to-access_ok-in-Linux-5.0.patch + - debian/patches/Fix-build-failures-due-to-undefined-syscall-numbers.patch + + -- Connor Kuehl Tue, 14 May 2019 12:32:24 -0700 + sysdig (0.19.1-1ubuntu1) bionic; urgency=medium * Add patch to fix errors caused by proto_ops.getname() prototype change diff -Nru sysdig-0.19.1/debian/patches/0001-Update-for-change-to-access_ok-in-Linux-5.0.patch sysdig-0.19.1/debian/patches/0001-Update-for-change-to-access_ok-in-Linux-5.0.patch --- sysdig-0.19.1/debian/patches/0001-Update-for-change-to-access_ok-in-Linux-5.0.patch 1969-12-31 16:00:00.000000000 -0800 +++ sysdig-0.19.1/debian/patches/0001-Update-for-change-to-access_ok-in-Linux-5.0.patch 2019-05-14 11:55:58.000000000 -0700 @@ -0,0 +1,33 @@ +From 3ac0505886a30cc3cd5d78057b8b10fa596f2a0e Mon Sep 17 00:00:00 2001 +From: Colin Ian King +Date: Thu, 31 Jan 2019 10:54:00 +0000 +Subject: [PATCH] Update for change to access_ok in Linux 5.0 + +Linux 5.0 removed the 1st argument 'type' from the access_ok macro. +Update the ppm_access_ok() macro to cater for this change for Linux +5.0 + +Bug: https://github.com/draios/sysdig/issues/1299 + +Signed-off-by: Colin Ian King +--- + driver/ppm_events.c | 6 +++++- + 1 file changed, 5 insertions(+), 1 deletion(-) + +Index: sysdig-0.19.1/driver/ppm_events.c +=================================================================== +--- sysdig-0.19.1.orig/driver/ppm_events.c ++++ sysdig-0.19.1/driver/ppm_events.c +@@ -56,7 +56,11 @@ along with sysdig. If not, see consumer->snaplen; -@@ -182,7 +196,6 @@ inline u32 compute_snaplen(struct event_filler_arguments *args, char *buf, u32 l +@@ -183,7 +197,6 @@ inline u32 compute_snaplen(struct event_ sa_family_t family; struct sockaddr_storage sock_address; struct sockaddr_storage peer_address; @@ -51,7 +51,7 @@ int peer_address_len; u16 sport, dport; -@@ -233,7 +246,7 @@ inline u32 compute_snaplen(struct event_filler_arguments *args, char *buf, u32 l +@@ -234,7 +247,7 @@ inline u32 compute_snaplen(struct event_ if (sock) { if (sock->sk) { @@ -60,7 +60,7 @@ if (err == 0) { if(args->event_type == PPME_SOCKET_SENDTO_X) -@@ -254,7 +267,7 @@ inline u32 compute_snaplen(struct event_filler_arguments *args, char *buf, u32 l +@@ -255,7 +268,7 @@ inline u32 compute_snaplen(struct event_ /* * Suppose is a connected socket, fall back to fd */ @@ -69,7 +69,7 @@ } else { /* * Get the address len -@@ -274,7 +287,7 @@ inline u32 compute_snaplen(struct event_filler_arguments *args, char *buf, u32 l +@@ -275,7 +288,7 @@ inline u32 compute_snaplen(struct event_ /* * This case should be very rare, fallback again to sock */ @@ -78,7 +78,7 @@ } } } else if (args->event_type == PPME_SOCKET_SENDMSG_X) { -@@ -327,9 +340,9 @@ inline u32 compute_snaplen(struct event_filler_arguments *args, char *buf, u32 l +@@ -328,9 +341,9 @@ inline u32 compute_snaplen(struct event_ /* * Suppose it is a connected socket, fall back to fd */ @@ -90,7 +90,7 @@ if (err == 0) { family = sock->sk->sk_family; -@@ -863,8 +876,6 @@ u16 fd_to_socktuple(int fd, +@@ -963,8 +976,6 @@ u16 fd_to_socktuple(int fd, char *dest; struct sockaddr_storage sock_address; struct sockaddr_storage peer_address; @@ -99,7 +99,7 @@ /* * Get the socket from the fd -@@ -882,7 +893,7 @@ u16 fd_to_socktuple(int fd, +@@ -982,7 +993,7 @@ u16 fd_to_socktuple(int fd, return 0; } @@ -108,7 +108,7 @@ ASSERT(err == 0); family = sock->sk->sk_family; -@@ -893,7 +904,7 @@ u16 fd_to_socktuple(int fd, +@@ -993,7 +1004,7 @@ u16 fd_to_socktuple(int fd, switch (family) { case AF_INET: if (!use_userdata) { @@ -117,7 +117,7 @@ if (err == 0) { if (is_inbound) { sip = ((struct sockaddr_in *) &peer_address)->sin_addr.s_addr; -@@ -945,7 +956,7 @@ u16 fd_to_socktuple(int fd, +@@ -1045,7 +1056,7 @@ u16 fd_to_socktuple(int fd, break; case AF_INET6: if (!use_userdata) { @@ -126,7 +126,7 @@ ASSERT(err == 0); if (is_inbound) { -@@ -1020,7 +1031,7 @@ u16 fd_to_socktuple(int fd, +@@ -1120,7 +1131,7 @@ u16 fd_to_socktuple(int fd, if (is_inbound) { us_name = ((struct sockaddr_un *) &sock_address)->sun_path; } else { @@ -135,6 +135,3 @@ ASSERT(err == 0); us_name = ((struct sockaddr_un *) &peer_address)->sun_path; --- -2.17.0 - diff -Nru sysdig-0.19.1/debian/patches/Fix-build-failures-due-to-undefined-syscall-numbers.patch sysdig-0.19.1/debian/patches/Fix-build-failures-due-to-undefined-syscall-numbers.patch --- sysdig-0.19.1/debian/patches/Fix-build-failures-due-to-undefined-syscall-numbers.patch 1969-12-31 16:00:00.000000000 -0800 +++ sysdig-0.19.1/debian/patches/Fix-build-failures-due-to-undefined-syscall-numbers.patch 2019-05-14 12:32:24.000000000 -0700 @@ -0,0 +1,372 @@ +From 15e820dd1739045aaa66125afc9c075d5cef2622 Mon Sep 17 00:00:00 2001 +From: Seth Forshee +Date: Thu, 14 Feb 2019 09:26:31 -0600 +Subject: [PATCH] Fix build failures due to undefined syscall numbers (#1203) + +Signed-off-by: Seth Forshee + +Forwarded: https://github.com/draios/sysdig/pull/1318 +Bug: https://github.com/draios/sysdig/issues/1203 +--- + driver/syscall_table.c | 114 +++++++++++++++++++++++++++++++++++++++++ + 1 file changed, 114 insertions(+) + +Index: sysdig-0.19.1/driver/syscall_table.c +=================================================================== +--- sysdig-0.19.1.orig/driver/syscall_table.c ++++ sysdig-0.19.1/driver/syscall_table.c +@@ -46,26 +46,46 @@ along with sysdig. If not, see