All of lore.kernel.org
 help / color / mirror / Atom feed
* [meta-security][PATCH] samhain: hash fix for aarch64 and mips64
@ 2019-04-03  8:55 mingli.yu
  2019-04-03 10:05 ` akuster808
  2019-04-03 10:27 ` Adrian Bunk
  0 siblings, 2 replies; 3+ messages in thread
From: mingli.yu @ 2019-04-03  8:55 UTC (permalink / raw)
  To: yocto

From: Mingli Yu <Mingli.Yu@windriver.com>

samhain fails on both aarch64 and mips64 targets with:
| samhain[3013]: FATAL: x_dnmalloc.c: 2790: hashval < AMOUNTHASH

Though there is already a patch samhain-mips64-aarch64-dnmalloc-hash-fix.patch
to fix this issue, the logic is incomplete and
pass -DCONFIG_ARCH_MIPS64=1 and -DCONFIG_ARCH_AARCH64=1
during do_configure phase respectively to fix the
issue.

Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
---
 recipes-security/samhain/samhain.inc | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/recipes-security/samhain/samhain.inc b/recipes-security/samhain/samhain.inc
index dcd72b9..90da813 100644
--- a/recipes-security/samhain/samhain.inc
+++ b/recipes-security/samhain/samhain.inc
@@ -97,6 +97,11 @@ EOF
 
 do_configure () {
 	autoconf -f
+	if [ "${TARGET_ARCH}" = "mips64" ]; then
+	    export CFLAGS="${CFLAGS} -DCONFIG_ARCH_MIPS64=1"
+	elif [ "${TARGET_ARCH}" = "aarch64" ]; then
+	    export CFLAGS="${CFLAGS} -DCONFIG_ARCH_AARCH64=1"
+	fi
 	./configure \
 	--build=${BUILD_SYS} \
 	--host=${HOST_SYS} \
-- 
2.7.4



^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [meta-security][PATCH] samhain: hash fix for aarch64 and mips64
  2019-04-03  8:55 [meta-security][PATCH] samhain: hash fix for aarch64 and mips64 mingli.yu
@ 2019-04-03 10:05 ` akuster808
  2019-04-03 10:27 ` Adrian Bunk
  1 sibling, 0 replies; 3+ messages in thread
From: akuster808 @ 2019-04-03 10:05 UTC (permalink / raw)
  To: mingli.yu, yocto



On 4/3/19 1:55 AM, mingli.yu@windriver.com wrote:
> From: Mingli Yu <Mingli.Yu@windriver.com>
>
> samhain fails on both aarch64 and mips64 targets with:
> | samhain[3013]: FATAL: x_dnmalloc.c: 2790: hashval < AMOUNTHASH
>
> Though there is already a patch samhain-mips64-aarch64-dnmalloc-hash-fix.patch
> to fix this issue, the logic is incomplete and
> pass -DCONFIG_ARCH_MIPS64=1 and -DCONFIG_ARCH_AARCH64=1
> during do_configure phase respectively to fix the
> issue.
This does not apply. Can you rebase with master.

thanks,
Armin
>
> Signed-off-by: Mingli Yu <Mingli.Yu@windriver.com>
> ---
>  recipes-security/samhain/samhain.inc | 5 +++++
>  1 file changed, 5 insertions(+)
>
> diff --git a/recipes-security/samhain/samhain.inc b/recipes-security/samhain/samhain.inc
> index dcd72b9..90da813 100644
> --- a/recipes-security/samhain/samhain.inc
> +++ b/recipes-security/samhain/samhain.inc
> @@ -97,6 +97,11 @@ EOF
>  
>  do_configure () {
>  	autoconf -f
> +	if [ "${TARGET_ARCH}" = "mips64" ]; then
> +	    export CFLAGS="${CFLAGS} -DCONFIG_ARCH_MIPS64=1"
> +	elif [ "${TARGET_ARCH}" = "aarch64" ]; then
> +	    export CFLAGS="${CFLAGS} -DCONFIG_ARCH_AARCH64=1"
> +	fi
>  	./configure \
>  	--build=${BUILD_SYS} \
>  	--host=${HOST_SYS} \



^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [meta-security][PATCH] samhain: hash fix for aarch64 and mips64
  2019-04-03  8:55 [meta-security][PATCH] samhain: hash fix for aarch64 and mips64 mingli.yu
  2019-04-03 10:05 ` akuster808
@ 2019-04-03 10:27 ` Adrian Bunk
  1 sibling, 0 replies; 3+ messages in thread
From: Adrian Bunk @ 2019-04-03 10:27 UTC (permalink / raw)
  To: mingli.yu; +Cc: yocto

On Wed, Apr 03, 2019 at 04:55:14PM +0800, mingli.yu@windriver.com wrote:
> From: Mingli Yu <Mingli.Yu@windriver.com>
> 
> samhain fails on both aarch64 and mips64 targets with:
> | samhain[3013]: FATAL: x_dnmalloc.c: 2790: hashval < AMOUNTHASH
> 
> Though there is already a patch samhain-mips64-aarch64-dnmalloc-hash-fix.patch
> to fix this issue, the logic is incomplete and
> pass -DCONFIG_ARCH_MIPS64=1 and -DCONFIG_ARCH_AARCH64=1
> during do_configure phase respectively to fix the
> issue.
>...

In master this has already been workarounded with --disable-dnmalloc.

cu
Adrian

-- 

       "Is there not promise of rain?" Ling Tan asked suddenly out
        of the darkness. There had been need of rain for many days.
       "Only a promise," Lao Er said.
                                       Pearl S. Buck - Dragon Seed



^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2019-04-03 10:27 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-04-03  8:55 [meta-security][PATCH] samhain: hash fix for aarch64 and mips64 mingli.yu
2019-04-03 10:05 ` akuster808
2019-04-03 10:27 ` Adrian Bunk

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.