DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH] examples/ip_pipeline: fix freebsd build error
@ 2018-04-09 12:06 Jasvinder Singh
  2018-04-09 12:58 ` Dumitrescu, Cristian
                   ` (2 more replies)
  0 siblings, 3 replies; 10+ messages in thread
From: Jasvinder Singh @ 2018-04-09 12:06 UTC (permalink / raw)
  To: dev; +Cc: cristian.dumitrescu

IP_Pipeline app is not supported in FreeBSD environment. Therefore,
skip it while building the sample apps on FreeBSD.

Fixes: 4bbf8e30aa5e ("examples/ip_pipeline: add CLI interface")
Fixes: 2f74ae28e23f ("examples/ip_pipeline: add tap object")

Signed-off-by: Jasvinder Singh <jasvinder.singh@intel.com>
---
 examples/ip_pipeline/Makefile | 5 +++++
 1 file changed, 5 insertions(+)

diff --git a/examples/ip_pipeline/Makefile b/examples/ip_pipeline/Makefile
index c936d1e..6ff2abf 100644
--- a/examples/ip_pipeline/Makefile
+++ b/examples/ip_pipeline/Makefile
@@ -67,6 +67,11 @@ RTE_TARGET ?= x86_64-native-linuxapp-gcc
 
 include $(RTE_SDK)/mk/rte.vars.mk
 
+ifneq ($(CONFIG_RTE_EXEC_ENV),"linuxapp")
+$(error This application can only operate in a linuxapp environment, \
+please change the definition of the RTE_TARGET environment variable)
+endif
+
 INC += $(sort $(wildcard *.h))
 
 SRCS-$(CONFIG_RTE_LIBRTE_PIPELINE) := $(SRCS-y)
-- 
2.9.3

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

* Re: [dpdk-dev] [PATCH] examples/ip_pipeline: fix freebsd build error
  2018-04-09 12:06 [dpdk-dev] [PATCH] examples/ip_pipeline: fix freebsd build error Jasvinder Singh
@ 2018-04-09 12:58 ` Dumitrescu, Cristian
  2018-04-09 22:34 ` Thomas Monjalon
  2018-04-10  9:51 ` [dpdk-dev] [PATCH v2] " Jasvinder Singh
  2 siblings, 0 replies; 10+ messages in thread
From: Dumitrescu, Cristian @ 2018-04-09 12:58 UTC (permalink / raw)
  To: Singh, Jasvinder, dev



> -----Original Message-----
> From: Singh, Jasvinder
> Sent: Monday, April 9, 2018 1:07 PM
> To: dev@dpdk.org
> Cc: Dumitrescu, Cristian <cristian.dumitrescu@intel.com>
> Subject: [PATCH] examples/ip_pipeline: fix freebsd build error
> 
> IP_Pipeline app is not supported in FreeBSD environment. Therefore,
> skip it while building the sample apps on FreeBSD.
> 
> Fixes: 4bbf8e30aa5e ("examples/ip_pipeline: add CLI interface")
> Fixes: 2f74ae28e23f ("examples/ip_pipeline: add tap object")
> 
> Signed-off-by: Jasvinder Singh <jasvinder.singh@intel.com>
> ---
>  examples/ip_pipeline/Makefile | 5 +++++
>  1 file changed, 5 insertions(+)
> 
> diff --git a/examples/ip_pipeline/Makefile b/examples/ip_pipeline/Makefile
> index c936d1e..6ff2abf 100644
> --- a/examples/ip_pipeline/Makefile
> +++ b/examples/ip_pipeline/Makefile
> @@ -67,6 +67,11 @@ RTE_TARGET ?= x86_64-native-linuxapp-gcc
> 
>  include $(RTE_SDK)/mk/rte.vars.mk
> 
> +ifneq ($(CONFIG_RTE_EXEC_ENV),"linuxapp")
> +$(error This application can only operate in a linuxapp environment, \
> +please change the definition of the RTE_TARGET environment variable)
> +endif
> +
>  INC += $(sort $(wildcard *.h))
> 
>  SRCS-$(CONFIG_RTE_LIBRTE_PIPELINE) := $(SRCS-y)
> --
> 2.9.3

Acked-by: Cristian Dumitrescu <cristian.dumitrescu@intel.com>

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

* Re: [dpdk-dev] [PATCH] examples/ip_pipeline: fix freebsd build error
  2018-04-09 12:06 [dpdk-dev] [PATCH] examples/ip_pipeline: fix freebsd build error Jasvinder Singh
  2018-04-09 12:58 ` Dumitrescu, Cristian
@ 2018-04-09 22:34 ` Thomas Monjalon
  2018-04-10  9:53   ` Singh, Jasvinder
  2018-04-10  9:51 ` [dpdk-dev] [PATCH v2] " Jasvinder Singh
  2 siblings, 1 reply; 10+ messages in thread
From: Thomas Monjalon @ 2018-04-09 22:34 UTC (permalink / raw)
  To: Jasvinder Singh; +Cc: dev, cristian.dumitrescu

09/04/2018 14:06, Jasvinder Singh:
> IP_Pipeline app is not supported in FreeBSD environment. Therefore,
> skip it while building the sample apps on FreeBSD.
> 
> Fixes: 4bbf8e30aa5e ("examples/ip_pipeline: add CLI interface")
> Fixes: 2f74ae28e23f ("examples/ip_pipeline: add tap object")
> 
> Signed-off-by: Jasvinder Singh <jasvinder.singh@intel.com>
> ---
> --- a/examples/ip_pipeline/Makefile
> +++ b/examples/ip_pipeline/Makefile
> +ifneq ($(CONFIG_RTE_EXEC_ENV),"linuxapp")
> +$(error This application can only operate in a linuxapp environment, \
> +please change the definition of the RTE_TARGET environment variable)
> +endif

It is not skipping the example, just throwing an error (which is needed).

You should add a test in examples/Makefile to really skip it.

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

* [dpdk-dev] [PATCH v2] examples/ip_pipeline: fix freebsd build error
  2018-04-09 12:06 [dpdk-dev] [PATCH] examples/ip_pipeline: fix freebsd build error Jasvinder Singh
  2018-04-09 12:58 ` Dumitrescu, Cristian
  2018-04-09 22:34 ` Thomas Monjalon
@ 2018-04-10  9:51 ` Jasvinder Singh
  2018-04-10 10:15   ` Thomas Monjalon
  2018-04-10 12:40   ` Thomas Monjalon
  2 siblings, 2 replies; 10+ messages in thread
From: Jasvinder Singh @ 2018-04-10  9:51 UTC (permalink / raw)
  To: dev; +Cc: cristian.dumitrescu

IP_Pipeline app is not supported in FreeBSD environment. Therefore,
skip it while building the sample apps on FreeBSD.

Fixes: 4bbf8e30aa5e ("examples/ip_pipeline: add CLI interface")
Fixes: 2f74ae28e23f ("examples/ip_pipeline: add tap object")

Signed-off-by: Jasvinder Singh <jasvinder.singh@intel.com>
Acked-by: Cristian Dumitrescu <cristian.dumitrescu@intel.com>
---
 examples/ip_pipeline/Makefile | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/examples/ip_pipeline/Makefile b/examples/ip_pipeline/Makefile
index c936d1e..11d2b35 100644
--- a/examples/ip_pipeline/Makefile
+++ b/examples/ip_pipeline/Makefile
@@ -67,6 +67,13 @@ RTE_TARGET ?= x86_64-native-linuxapp-gcc
 
 include $(RTE_SDK)/mk/rte.vars.mk
 
+ifneq ($(CONFIG_RTE_EXEC_ENV),"linuxapp")
+$(info This application can only operate in a linuxapp environment, \
+please change the definition of the RTE_TARGET environment variable)
+all:
+clean:
+else
+
 INC += $(sort $(wildcard *.h))
 
 SRCS-$(CONFIG_RTE_LIBRTE_PIPELINE) := $(SRCS-y)
@@ -79,3 +86,4 @@ CFLAGS += $(WERROR_FLAGS)
 include $(RTE_SDK)/mk/rte.extapp.mk
 
 endif
+endif
-- 
2.9.3

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

* Re: [dpdk-dev] [PATCH] examples/ip_pipeline: fix freebsd build error
  2018-04-09 22:34 ` Thomas Monjalon
@ 2018-04-10  9:53   ` Singh, Jasvinder
  0 siblings, 0 replies; 10+ messages in thread
From: Singh, Jasvinder @ 2018-04-10  9:53 UTC (permalink / raw)
  To: Thomas Monjalon; +Cc: dev, Dumitrescu, Cristian



> -----Original Message-----
> From: Thomas Monjalon [mailto:thomas@monjalon.net]
> Sent: Monday, April 9, 2018 11:34 PM
> To: Singh, Jasvinder <jasvinder.singh@intel.com>
> Cc: dev@dpdk.org; Dumitrescu, Cristian <cristian.dumitrescu@intel.com>
> Subject: Re: [dpdk-dev] [PATCH] examples/ip_pipeline: fix freebsd build error
> 
> 09/04/2018 14:06, Jasvinder Singh:
> > IP_Pipeline app is not supported in FreeBSD environment. Therefore,
> > skip it while building the sample apps on FreeBSD.
> >
> > Fixes: 4bbf8e30aa5e ("examples/ip_pipeline: add CLI interface")
> > Fixes: 2f74ae28e23f ("examples/ip_pipeline: add tap object")
> >
> > Signed-off-by: Jasvinder Singh <jasvinder.singh@intel.com>
> > ---
> > --- a/examples/ip_pipeline/Makefile
> > +++ b/examples/ip_pipeline/Makefile
> > +ifneq ($(CONFIG_RTE_EXEC_ENV),"linuxapp")
> > +$(error This application can only operate in a linuxapp environment,
> > +\ please change the definition of the RTE_TARGET environment
> > +variable) endif
> 
> It is not skipping the example, just throwing an error (which is needed).
> 
> You should add a test in examples/Makefile to really skip it.
> 
Pushed v2 that allows skipping the ip pipeline app on FreeBSD.Thanks. 

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

* Re: [dpdk-dev] [PATCH v2] examples/ip_pipeline: fix freebsd build error
  2018-04-10  9:51 ` [dpdk-dev] [PATCH v2] " Jasvinder Singh
@ 2018-04-10 10:15   ` Thomas Monjalon
  2018-04-10 10:25     ` Singh, Jasvinder
  2018-04-10 12:40   ` Thomas Monjalon
  1 sibling, 1 reply; 10+ messages in thread
From: Thomas Monjalon @ 2018-04-10 10:15 UTC (permalink / raw)
  To: Jasvinder Singh; +Cc: dev, cristian.dumitrescu

10/04/2018 11:51, Jasvinder Singh:
> IP_Pipeline app is not supported in FreeBSD environment. Therefore,
> skip it while building the sample apps on FreeBSD.
[...]
> --- a/examples/ip_pipeline/Makefile
> +++ b/examples/ip_pipeline/Makefile
> @@ -67,6 +67,13 @@ RTE_TARGET ?= x86_64-native-linuxapp-gcc
>  
>  include $(RTE_SDK)/mk/rte.vars.mk
>  
> +ifneq ($(CONFIG_RTE_EXEC_ENV),"linuxapp")

You can use CONFIG_RTE_EXEC_ENV_LINUXAPP

> +$(info This application can only operate in a linuxapp environment, \
> +please change the definition of the RTE_TARGET environment variable)
> +all:
> +clean:
> +else


Copy of my previous comment:
"
It is not skipping the example, just throwing an error (which is needed).

You should add a test in examples/Makefile to really skip it.
"

In this v2, you replaced the error by an info message.
Error was better in my opinion.

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

* Re: [dpdk-dev] [PATCH v2] examples/ip_pipeline: fix freebsd build error
  2018-04-10 10:15   ` Thomas Monjalon
@ 2018-04-10 10:25     ` Singh, Jasvinder
  2018-04-10 12:19       ` Thomas Monjalon
  0 siblings, 1 reply; 10+ messages in thread
From: Singh, Jasvinder @ 2018-04-10 10:25 UTC (permalink / raw)
  To: Thomas Monjalon; +Cc: dev, Dumitrescu, Cristian



> -----Original Message-----
> From: Thomas Monjalon [mailto:thomas@monjalon.net]
> Sent: Tuesday, April 10, 2018 11:15 AM
> To: Singh, Jasvinder <jasvinder.singh@intel.com>
> Cc: dev@dpdk.org; Dumitrescu, Cristian <cristian.dumitrescu@intel.com>
> Subject: Re: [dpdk-dev] [PATCH v2] examples/ip_pipeline: fix freebsd build
> error
> 
> 10/04/2018 11:51, Jasvinder Singh:
> > IP_Pipeline app is not supported in FreeBSD environment. Therefore,
> > skip it while building the sample apps on FreeBSD.
> [...]
> > --- a/examples/ip_pipeline/Makefile
> > +++ b/examples/ip_pipeline/Makefile
> > @@ -67,6 +67,13 @@ RTE_TARGET ?= x86_64-native-linuxapp-gcc
> >
> >  include $(RTE_SDK)/mk/rte.vars.mk
> >
> > +ifneq ($(CONFIG_RTE_EXEC_ENV),"linuxapp")
> 
> You can use CONFIG_RTE_EXEC_ENV_LINUXAPP
> 
> > +$(info This application can only operate in a linuxapp environment, \
> > +please change the definition of the RTE_TARGET environment variable)
> > +all:
> > +clean:
> > +else
> 
> 
> Copy of my previous comment:
> "
> It is not skipping the example, just throwing an error (which is needed).
> 
> You should add a test in examples/Makefile to really skip it.
> "

In V2, we follow the same pattern as followed in other examples such as l3fwd-power, ethtool, etc.

If we put check in examples/Makefile, than how the situation is handled if someone tries to build ip_pipeline straight instead of building all examples. 

> In this v2, you replaced the error by an info message.
> Error was better in my opinion.
> 
> 

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

* Re: [dpdk-dev] [PATCH v2] examples/ip_pipeline: fix freebsd build error
  2018-04-10 10:25     ` Singh, Jasvinder
@ 2018-04-10 12:19       ` Thomas Monjalon
  2018-04-10 12:39         ` Bruce Richardson
  0 siblings, 1 reply; 10+ messages in thread
From: Thomas Monjalon @ 2018-04-10 12:19 UTC (permalink / raw)
  To: Singh, Jasvinder; +Cc: dev, Dumitrescu, Cristian, bruce.richardson

10/04/2018 12:25, Singh, Jasvinder:
> From: Thomas Monjalon [mailto:thomas@monjalon.net]
> > 10/04/2018 11:51, Jasvinder Singh:
> > > IP_Pipeline app is not supported in FreeBSD environment. Therefore,
> > > skip it while building the sample apps on FreeBSD.
> > [...]
> > > --- a/examples/ip_pipeline/Makefile
> > > +++ b/examples/ip_pipeline/Makefile
> > > @@ -67,6 +67,13 @@ RTE_TARGET ?= x86_64-native-linuxapp-gcc
> > >
> > >  include $(RTE_SDK)/mk/rte.vars.mk
> > >
> > > +ifneq ($(CONFIG_RTE_EXEC_ENV),"linuxapp")
> > 
> > You can use CONFIG_RTE_EXEC_ENV_LINUXAPP
> > 
> > > +$(info This application can only operate in a linuxapp environment, \
> > > +please change the definition of the RTE_TARGET environment variable)
> > > +all:
> > > +clean:
> > > +else
> > 
> > 
> > Copy of my previous comment:
> > "
> > It is not skipping the example, just throwing an error (which is needed).
> > 
> > You should add a test in examples/Makefile to really skip it.
> > "
> 
> In V2, we follow the same pattern as followed in other examples such as l3fwd-power, ethtool, etc.

A kind of counter example is:
	ifeq ($(CONFIG_RTE_ARCH_X86_64),y)
	DIRS-y += performance-thread
	endif

But I get your point that it is done this way in several examples.

> If we put check in examples/Makefile, than how the situation is handled if someone tries to build ip_pipeline straight instead of building all examples.

My thought is that if you try to build explicitly this example on FreeBSD,
you should get an error.

> > In this v2, you replaced the error by an info message.
> > Error was better in my opinion.

I will get this v2 and not bother you more about that.
All examples could be fixed at once. Not sure it is worth though,
given this is the legacy build system.

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

* Re: [dpdk-dev] [PATCH v2] examples/ip_pipeline: fix freebsd build error
  2018-04-10 12:19       ` Thomas Monjalon
@ 2018-04-10 12:39         ` Bruce Richardson
  0 siblings, 0 replies; 10+ messages in thread
From: Bruce Richardson @ 2018-04-10 12:39 UTC (permalink / raw)
  To: Thomas Monjalon; +Cc: Singh, Jasvinder, dev, Dumitrescu, Cristian

On Tue, Apr 10, 2018 at 02:19:38PM +0200, Thomas Monjalon wrote:
> 10/04/2018 12:25, Singh, Jasvinder:
> > From: Thomas Monjalon [mailto:thomas@monjalon.net]
> > > 10/04/2018 11:51, Jasvinder Singh:
> > > > IP_Pipeline app is not supported in FreeBSD environment. Therefore,
> > > > skip it while building the sample apps on FreeBSD.
> > > [...]
> > > > --- a/examples/ip_pipeline/Makefile +++
> > > > b/examples/ip_pipeline/Makefile @@ -67,6 +67,13 @@ RTE_TARGET ?=
> > > > x86_64-native-linuxapp-gcc
> > > >
> > > >  include $(RTE_SDK)/mk/rte.vars.mk
> > > >
> > > > +ifneq ($(CONFIG_RTE_EXEC_ENV),"linuxapp")
> > > 
> > > You can use CONFIG_RTE_EXEC_ENV_LINUXAPP
> > > 
> > > > +$(info This application can only operate in a linuxapp
> > > > environment, \ +please change the definition of the RTE_TARGET
> > > > environment variable) +all: +clean: +else
> > > 
> > > 
> > > Copy of my previous comment: " It is not skipping the example, just
> > > throwing an error (which is needed).
> > > 
> > > You should add a test in examples/Makefile to really skip it.  "
> > 
> > In V2, we follow the same pattern as followed in other examples such as
> > l3fwd-power, ethtool, etc.
> 
> A kind of counter example is: ifeq ($(CONFIG_RTE_ARCH_X86_64),y) DIRS-y
> += performance-thread endif
> 
> But I get your point that it is done this way in several examples.
> 
> > If we put check in examples/Makefile, than how the situation is handled
> > if someone tries to build ip_pipeline straight instead of building all
> > examples.
> 
> My thought is that if you try to build explicitly this example on
> FreeBSD, you should get an error.
> 
> > > In this v2, you replaced the error by an info message.  Error was
> > > better in my opinion.
> 
> I will get this v2 and not bother you more about that.  All examples
> could be fixed at once. Not sure it is worth though, given this is the
> legacy build system.
> 

Well, we still need a make-based solution for the example apps, because if
we using meson & ninja for the main DPDK build, we still need to provide a
makefile for each sample app. That makefile should build each app
standalone using the pkg-config info to find DPDK libs. It also needs to
signal to the user when they are trying to compile the app on an
unsupported platform.

The alternative, I suppose, is not to have unsupported examples shipped for
different platforms, but I think that is not as good a solution.

/Bruce

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

* Re: [dpdk-dev] [PATCH v2] examples/ip_pipeline: fix freebsd build error
  2018-04-10  9:51 ` [dpdk-dev] [PATCH v2] " Jasvinder Singh
  2018-04-10 10:15   ` Thomas Monjalon
@ 2018-04-10 12:40   ` Thomas Monjalon
  1 sibling, 0 replies; 10+ messages in thread
From: Thomas Monjalon @ 2018-04-10 12:40 UTC (permalink / raw)
  To: Jasvinder Singh; +Cc: dev, cristian.dumitrescu

10/04/2018 11:51, Jasvinder Singh:
> IP_Pipeline app is not supported in FreeBSD environment. Therefore,
> skip it while building the sample apps on FreeBSD.
> 
> Fixes: 4bbf8e30aa5e ("examples/ip_pipeline: add CLI interface")
> Fixes: 2f74ae28e23f ("examples/ip_pipeline: add tap object")
> 
> Signed-off-by: Jasvinder Singh <jasvinder.singh@intel.com>
> Acked-by: Cristian Dumitrescu <cristian.dumitrescu@intel.com>

Applied, thanks

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

end of thread, other threads:[~2018-04-10 12:40 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-04-09 12:06 [dpdk-dev] [PATCH] examples/ip_pipeline: fix freebsd build error Jasvinder Singh
2018-04-09 12:58 ` Dumitrescu, Cristian
2018-04-09 22:34 ` Thomas Monjalon
2018-04-10  9:53   ` Singh, Jasvinder
2018-04-10  9:51 ` [dpdk-dev] [PATCH v2] " Jasvinder Singh
2018-04-10 10:15   ` Thomas Monjalon
2018-04-10 10:25     ` Singh, Jasvinder
2018-04-10 12:19       ` Thomas Monjalon
2018-04-10 12:39         ` Bruce Richardson
2018-04-10 12:40   ` Thomas Monjalon

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).