lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20170902170336.piispo3i3xk62pxq@unicorn.suse.cz>
Date:   Sat, 2 Sep 2017 19:03:36 +0200
From:   Michal Kubecek <mkubecek@...e.cz>
To:     greearb@...delatech.com
Cc:     netdev@...r.kernel.org
Subject: Re: [PATCH] Fix build on fedora-14 (and other older systems)

On Sat, Sep 02, 2017 at 07:15:02AM -0700, greearb@...delatech.com wrote:
> From: Ben Greear <greearb@...delatech.com>
> 
> Seems Fedora-20 and below fail, hopefully this fixes
> them.
> 
> Signed-off-by: Ben Greear <greearb@...delatech.com>
> ---
>  include/linux/sysinfo.h | 8 ++++++++
>  ip/ipxfrm.c             | 1 +
>  ip/xfrm_policy.c        | 1 +
>  ip/xfrm_state.c         | 1 +
>  4 files changed, 11 insertions(+)

Works for me from openSUSE Tumbleweed to SLE11 SP4 (kernel 3.0). The
build on SLE11 SP2 (also 3.0 but older headers in /usr/include)
fails with unknown MS_PRIVATE and MS_REC in lib/bpf.c
Newer systems have these defined in <sys/mount.h>

Including <linux/fs.h> directly in lib/bpf.c fixes that but if we do
that, a copy of the file would have to be included.

> diff --git a/include/linux/sysinfo.h b/include/linux/sysinfo.h
> index 934335a..3596b02 100644
> --- a/include/linux/sysinfo.h
> +++ b/include/linux/sysinfo.h
> @@ -3,6 +3,14 @@
>  
>  #include <linux/types.h>
>  
> +/* So we can compile on older OSs, hopefully this is correct. --Ben */
> +#ifndef __kernel_long_t
> +typedef long __kernel_long_t;
> +#endif
> +#ifndef __kernel_ulong_t
> +typedef unsigned long __kernel_ulong_t;
> +#endif
> +
>  #define SI_LOAD_SHIFT	16
>  struct sysinfo {
>  	__kernel_long_t uptime;		/* Seconds since boot */

I'm not sure if it is acceptable to modify a file which is supposed to
be a direct copy of kernel uapi header.

Michal Kubecek

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ