linux-rt-users.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] rt-tests: Makefile: Assume numa_parse_cpustring_all available
@ 2016-04-21 15:38 John Kacur
  2016-04-21 16:08 ` Luiz Capitulino
  0 siblings, 1 reply; 2+ messages in thread
From: John Kacur @ 2016-04-21 15:38 UTC (permalink / raw)
  To: RT; +Cc: Clark Williams, Luiz Capitulino

>From 5e5a1cb500a26b63aff8a19a2669e224c5d6e87a Mon Sep 17 00:00:00 2001
From: John Kacur <jkacur@redhat.com>
Date: Thu, 21 Apr 2016 17:29:51 +0200
Subject: [PATCH] rt-tests: Makefile: Assume numa_parse_cpustring_all available

NUMA users should have long ago stepped up to libs that have
numa_parse_cpustring_all(). Make this the default so that we can include
isolated cpus in the affinity string.

If there are any NUMA users or distros left that have old libraries that
don't have numa_parse_cpu_string_all(), and only numa_parse_cpu_string()
they can compile like this

make HAVE_PARSE_CPUSTRING_ALL=0

Signed-off-by: John Kacur <jkacur@redhat.com>
---
 Makefile | 13 +++++++------
 1 file changed, 7 insertions(+), 6 deletions(-)

diff --git a/Makefile b/Makefile
index 280fd3bec979..ff1d1b0554a3 100644
--- a/Makefile
+++ b/Makefile
@@ -57,16 +57,17 @@ ifneq ($(filter x86_64 i386 ia64 mips powerpc,$(machinetype)),)
 NUMA 	:= 1
 endif
 
-# The default is to assume that you only have numa_parse_cpustring
-# If you are sure you have a version of libnuma with numa_parse_cpustring_all
+# The default is to assume that you have numa_parse_cpustring_all
+# If you have an older version of libnuma that only has numa_parse_cpustring
 # then compile with
-# make HAVE_PARSE_CPUSTRING_ALL=1
+# make HAVE_PARSE_CPUSTRING_ALL=0
+HAVE_PARSE_CPUSTRING_ALL?=1
 ifeq ($(NUMA),1)
 	CFLAGS += -DNUMA
 	NUMA_LIBS = -lnuma
-ifdef HAVE_PARSE_CPUSTRING_ALL
-	CFLAGS += -DHAVE_PARSE_CPUSTRING_ALL
-endif
+	ifeq ($(HAVE_PARSE_CPUSTRING_ALL),1)
+		CFLAGS += -DHAVE_PARSE_CPUSTRING_ALL
+	endif
 endif
 
 include src/arch/android/Makefile
-- 
2.4.11


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

* Re: [PATCH] rt-tests: Makefile: Assume numa_parse_cpustring_all available
  2016-04-21 15:38 [PATCH] rt-tests: Makefile: Assume numa_parse_cpustring_all available John Kacur
@ 2016-04-21 16:08 ` Luiz Capitulino
  0 siblings, 0 replies; 2+ messages in thread
From: Luiz Capitulino @ 2016-04-21 16:08 UTC (permalink / raw)
  To: John Kacur; +Cc: RT, Clark Williams

On Thu, 21 Apr 2016 17:38:43 +0200 (CEST)
John Kacur <jkacur@redhat.com> wrote:

> From 5e5a1cb500a26b63aff8a19a2669e224c5d6e87a Mon Sep 17 00:00:00 2001
> From: John Kacur <jkacur@redhat.com>
> Date: Thu, 21 Apr 2016 17:29:51 +0200
> Subject: [PATCH] rt-tests: Makefile: Assume numa_parse_cpustring_all available
> 
> NUMA users should have long ago stepped up to libs that have
> numa_parse_cpustring_all(). Make this the default so that we can include
> isolated cpus in the affinity string.
> 
> If there are any NUMA users or distros left that have old libraries that
> don't have numa_parse_cpu_string_all(), and only numa_parse_cpu_string()
> they can compile like this
> 
> make HAVE_PARSE_CPUSTRING_ALL=0
> 
> Signed-off-by: John Kacur <jkacur@redhat.com>

Reviewed-and-Tested-by: Luiz Capitulino <lcapitulino@redhat.com>

> ---
>  Makefile | 13 +++++++------
>  1 file changed, 7 insertions(+), 6 deletions(-)
> 
> diff --git a/Makefile b/Makefile
> index 280fd3bec979..ff1d1b0554a3 100644
> --- a/Makefile
> +++ b/Makefile
> @@ -57,16 +57,17 @@ ifneq ($(filter x86_64 i386 ia64 mips powerpc,$(machinetype)),)
>  NUMA 	:= 1
>  endif
>  
> -# The default is to assume that you only have numa_parse_cpustring
> -# If you are sure you have a version of libnuma with numa_parse_cpustring_all
> +# The default is to assume that you have numa_parse_cpustring_all
> +# If you have an older version of libnuma that only has numa_parse_cpustring
>  # then compile with
> -# make HAVE_PARSE_CPUSTRING_ALL=1
> +# make HAVE_PARSE_CPUSTRING_ALL=0
> +HAVE_PARSE_CPUSTRING_ALL?=1
>  ifeq ($(NUMA),1)
>  	CFLAGS += -DNUMA
>  	NUMA_LIBS = -lnuma
> -ifdef HAVE_PARSE_CPUSTRING_ALL
> -	CFLAGS += -DHAVE_PARSE_CPUSTRING_ALL
> -endif
> +	ifeq ($(HAVE_PARSE_CPUSTRING_ALL),1)
> +		CFLAGS += -DHAVE_PARSE_CPUSTRING_ALL
> +	endif
>  endif
>  
>  include src/arch/android/Makefile


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

end of thread, other threads:[~2016-04-21 16:09 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-04-21 15:38 [PATCH] rt-tests: Makefile: Assume numa_parse_cpustring_all available John Kacur
2016-04-21 16:08 ` Luiz Capitulino

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).