Skip to contentSkip to conversation

net/octeontx: meson build fix if octeontx drivers are disabled

PATCH Superseded [email protected] 5 participants 14 messages Feb 17, 2020 – Apr 6, 2020

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 net/octeontx: meson build fix if octeontx drivers are disabled

From: Amit Gupta <[email protected]>

Add a condition to check if octeontx drivers are disabled. octeontx drivers are built only if dependent drivers i.e. ethdev, mempool and common/octeontx are enabled.

BugZilla ID # BUG 387

---
 drivers/net/octeontx/base/meson.build | 32 ++++++++++++++++++++++++--------
 1 file changed, 24 insertions(+), 8 deletions(-)
drivers/net/octeontx/base/meson.build +24 -8
index a06a2c8..50e7972 100644
@@ -9,17 +9,33 @@ sources = [
 
 depends = ['ethdev', 'mempool_octeontx']
 static_objs = []
-foreach d: depends
-	static_objs += [get_variable('static_rte_' + d)]
+
+disabled_drivers = get_option('disable_drivers').split(',')
+
+build = true
+foreach disable_path: disabled_drivers
+        if (('net/octeontx' == disable_path) or
+	   ('event/octeontx' == disable_path) or
+	   ('common/octeontx' == disable_path) or
+	   ('mempool/octeontx' == disable_path))
+                build = false
+        endif
 endforeach
 
 c_args = cflags
 if allow_experimental_apis
-	c_args += '-DALLOW_EXPERIMENTAL_API'
+        c_args += '-DALLOW_EXPERIMENTAL_API'
 endif
-base_lib = static_library('octeontx_base', sources,
-	c_args: c_args,
-	dependencies: static_objs,
-)
 
-base_objs = base_lib.extract_all_objects()
+if build
+        foreach d: depends
+                static_objs += [get_variable('static_rte_' + d)]
+        endforeach
+
+        base_lib = static_library('octeontx_base', sources,
+                c_args: c_args,
+                dependencies: static_objs,
+        )
+
+        base_objs = base_lib.extract_all_objects()
+endif
Signature · 1 line
1.8.3.1
#1 lore raw
Quoted 8 lines · On Mon, Feb 17, 2020 at 8:48 AM <[email protected]> wrote:

From: Amit Gupta <[email protected]>

Add a condition to check if octeontx drivers are disabled. octeontx drivers are built only if dependent drivers i.e. ethdev, mempool and common/octeontx are enabled.

BugZilla ID # BUG 387

Interesting format, but we prefer consistency, you can see this in git history. Bugzilla ID: xxx

This can be caught by running the devtools/check-git-log.sh script.

Quoted 18 lines
---
 drivers/net/octeontx/base/meson.build | 32 ++++++++++++++++++++++++--------
 1 file changed, 24 insertions(+), 8 deletions(-)
drivers/net/octeontx/base/meson.build +2 -2
index a06a2c8..50e7972 100644
@@ -9,17 +9,33 @@ sources = [
 
 depends = ['ethdev', 'mempool_octeontx']
 static_objs = []
-foreach d: depends
-       static_objs += [get_variable('static_rte_' + d)]
+
+disabled_drivers = get_option('disable_drivers').split(',')

drivers/net/octeontx/base/meson.build sources = [ · line 23

Quoted 10 lines
drivers/net/octeontx/base/meson.build +9 -0
+
+build = true
+foreach disable_path: disabled_drivers
+        if (('net/octeontx' == disable_path) or
+          ('event/octeontx' == disable_path) or
+          ('common/octeontx' == disable_path) or
+          ('mempool/octeontx' == disable_path))
+                build = false
+        endif
 endforeach

I am no meson expert, but I'd say you can put a subdir_done() if your check is false and then you don't need to check the build variable later.
Besides, you can most likely do this check at the top of this file alongside "depends".

Cc Bruce who commented on this bz.

drivers/net/octeontx/base/meson.build sources = [ · line 27

Quoted 5 lines
drivers/net/octeontx/base/meson.build +1 -1
 c_args = cflags
 if allow_experimental_apis
-       c_args += '-DALLOW_EXPERIMENTAL_API'
+        c_args += '-DALLOW_EXPERIMENTAL_API'

Unrelated change + whitespace damage after.

Quoted 20 lines
drivers/net/octeontx/base/meson.build +12 -6
 endif
-base_lib = static_library('octeontx_base', sources,
-       c_args: c_args,
-       dependencies: static_objs,
-)
 
-base_objs = base_lib.extract_all_objects()
+if build
+        foreach d: depends
+                static_objs += [get_variable('static_rte_' + d)]
+        endforeach
+
+        base_lib = static_library('octeontx_base', sources,
+                c_args: c_args,
+                dependencies: static_objs,
+        )
+
+        base_objs = base_lib.extract_all_objects()
+endif
--
Quoted 2 lines

1.8.3.1

--
David Marchand

author
#2 lore raw
Quoted 22 lines

-----Original Message-----
From: David Marchand <[email protected]>
Sent: Monday, February 17, 2020 3:24 PM
To: Amit Gupta <[email protected]>
Cc: Harman Kalra <[email protected]>; dev <[email protected]>; Bruce Richardson <[email protected]>
Subject: [EXT] Re: [dpdk-dev] [PATCH] net/octeontx: meson build fix if octeontx drivers are disabled

External Email

----------------------------------------------------------------------

Quoted 7 lines · On Mon, Feb 17, 2020 at 8:48 AM <[email protected]> wrote:

From: Amit Gupta <[email protected]>

Add a condition to check if octeontx drivers are disabled. octeontx drivers are built only if dependent drivers i.e. ethdev, mempool and common/octeontx are enabled.

Quoted 6 lines
Quoted 1 line

BugZilla ID # BUG 387

Interesting format, but we prefer consistency, you can see this in git history. Bugzilla ID: xxx

This can be caught by running the devtools/check-git-log.sh script.

ACK, will update the same in V2

Quoted 28 lines
Quoted 28 lines
---
 drivers/net/octeontx/base/meson.build | 32
++++++++++++++++++++++++--------
 1 file changed, 24 insertions(+), 8 deletions(-)
drivers/net/octeontx/base/meson.build +0 -0
index a06a2c8..50e7972 100644
@@ -9,17 +9,33 @@ sources = [
 
 depends = ['ethdev', 'mempool_octeontx']  static_objs = [] -foreach

d: depends

drivers/net/octeontx/base/meson.build +9 -1
-       static_objs += [get_variable('static_rte_' + d)]
+
+disabled_drivers = get_option('disable_drivers').split(',')
+
+build = true
+foreach disable_path: disabled_drivers
+        if (('net/octeontx' == disable_path) or
+          ('event/octeontx' == disable_path) or
+          ('common/octeontx' == disable_path) or
+          ('mempool/octeontx' == disable_path))
Quoted 8 lines

drivers/net/octeontx/base/meson.build sources = [ · line 23

Quoted 3 lines
drivers/net/octeontx/base/meson.build +2 -0
+                build = false
+        endif
 endforeach

I am no meson expert, but I'd say you can put a subdir_done() if your check is false and then you don't need to check the build variable later. Besides, you can most likely do this check at the top of this file alongside "depends".

ACK, will update the same in V2

Quoted 11 lines
Cc Bruce who commented on this bz.

drivers/net/octeontx/base/meson.build sources = [ · line 27

Quoted 5 lines

c_args = cflags
if allow_experimental_apis

drivers/net/octeontx/base/meson.build +1 -1
-       c_args += '-DALLOW_EXPERIMENTAL_API'
+        c_args += '-DALLOW_EXPERIMENTAL_API'

Unrelated change + whitespace damage after.

ACK, will update the same in V2

Quoted 28 lines
Quoted 22 lines

endif

drivers/net/octeontx/base/meson.build +11 -6
-base_lib = static_library('octeontx_base', sources,
-       c_args: c_args,
-       dependencies: static_objs,
-)
 
-base_objs = base_lib.extract_all_objects()
+if build
+        foreach d: depends
+                static_objs += [get_variable('static_rte_' + d)]
+        endforeach
+
+        base_lib = static_library('octeontx_base', sources,
+                c_args: c_args,
+                dependencies: static_objs,
+        )
+
+        base_objs = base_lib.extract_all_objects() endif
--
Quoted 2 lines

1.8.3.1

--
David Marchand

#3 lore raw
In reply to [email protected]
Quoted 49 lines · On Mon, Feb 17, 2020 at 01:17:49PM +0530, [email protected] wrote:

From: Amit Gupta <[email protected]>

Add a condition to check if octeontx drivers are disabled. octeontx drivers are built only if dependent drivers i.e. ethdev, mempool and common/octeontx are enabled.

BugZilla ID # BUG 387

---
 drivers/net/octeontx/base/meson.build | 32 ++++++++++++++++++++++++--------
 1 file changed, 24 insertions(+), 8 deletions(-)
drivers/net/octeontx/base/meson.build +14 -8
index a06a2c8..50e7972 100644
@@ -9,17 +9,33 @@ sources = [
 
 depends = ['ethdev', 'mempool_octeontx']
 static_objs = []
-foreach d: depends
-	static_objs += [get_variable('static_rte_' + d)]
+
+disabled_drivers = get_option('disable_drivers').split(',')
+
+build = true
+foreach disable_path: disabled_drivers
+        if (('net/octeontx' == disable_path) or
+	   ('event/octeontx' == disable_path) or
+	   ('common/octeontx' == disable_path) or
+	   ('mempool/octeontx' == disable_path))
+                build = false
+        endif
 endforeach
 
 c_args = cflags
 if allow_experimental_apis
-	c_args += '-DALLOW_EXPERIMENTAL_API'
+        c_args += '-DALLOW_EXPERIMENTAL_API'
 endif
-base_lib = static_library('octeontx_base', sources,
-	c_args: c_args,
-	dependencies: static_objs,
-)
 
-base_objs = base_lib.extract_all_objects()
+if build
+        foreach d: depends

drivers/net/octeontx/base/meson.build sources = [ · line 41

Quoted 10 lines
drivers/net/octeontx/base/meson.build +10 -0
+                static_objs += [get_variable('static_rte_' + d)]
+        endforeach
+
+        base_lib = static_library('octeontx_base', sources,
+                c_args: c_args,
+                dependencies: static_objs,
+        )
+
+        base_objs = base_lib.extract_all_objects()
+endif

A better fix here might be possible using the fact that the get_variable() call allows passing a fallback value in the case of failure. Therefore something like the below might work cleaner:

foreach d: depends

	static_obj = [get_variable('static_rte_' + d, '']
	if static_obj == ''
		build = false
		reason = '....'
		subdir_done()
	endif
	static_objs += static_obj

...

Maybe a disabler object could be used also.

Regards,
/Bruce

author
#4 lore raw
Quoted 61 lines

-----Original Message-----
From: Bruce Richardson <[email protected]>
Sent: Monday, February 17, 2020 4:19 PM
To: Amit Gupta <[email protected]>
Cc: Harman Kalra <[email protected]>; [email protected]
Subject: [EXT] Re: [dpdk-dev] [PATCH] net/octeontx: meson build fix if octeontx drivers are disabled

External Email

----------------------------------------------------------------------

Quoted 47 lines · On Mon, Feb 17, 2020 at 01:17:49PM +0530, [email protected] wrote:

From: Amit Gupta <[email protected]>

Add a condition to check if octeontx drivers are disabled. octeontx drivers are built only if dependent drivers i.e. ethdev, mempool and common/octeontx are enabled.

BugZilla ID # BUG 387

---
 drivers/net/octeontx/base/meson.build | 32
++++++++++++++++++++++++--------
 1 file changed, 24 insertions(+), 8 deletions(-)
drivers/net/octeontx/base/meson.build +0 -0
index a06a2c8..50e7972 100644
@@ -9,17 +9,33 @@ sources = [
 
 depends = ['ethdev', 'mempool_octeontx']  static_objs = [] -foreach

d: depends

drivers/net/octeontx/base/meson.build +12 -6
-	static_objs += [get_variable('static_rte_' + d)]
+
+disabled_drivers = get_option('disable_drivers').split(',')
+
+build = true
+foreach disable_path: disabled_drivers
+        if (('net/octeontx' == disable_path) or
+	   ('event/octeontx' == disable_path) or
+	   ('common/octeontx' == disable_path) or
+	   ('mempool/octeontx' == disable_path))
+                build = false
+        endif
 endforeach
 
 c_args = cflags
 if allow_experimental_apis
-	c_args += '-DALLOW_EXPERIMENTAL_API'
+        c_args += '-DALLOW_EXPERIMENTAL_API'
 endif
-base_lib = static_library('octeontx_base', sources,
-	c_args: c_args,
-	dependencies: static_objs,
-)
Quoted 16 lines

drivers/net/octeontx/base/meson.build sources = [

Quoted 12 lines
drivers/net/octeontx/base/meson.build +11 -1
-base_objs = base_lib.extract_all_objects()
+if build
+        foreach d: depends
+                static_objs += [get_variable('static_rte_' + d)]
+        endforeach
+
+        base_lib = static_library('octeontx_base', sources,
+                c_args: c_args,
+                dependencies: static_objs,
+        )
+
+        base_objs = base_lib.extract_all_objects() endif

A better fix here might be possible using the fact that the get_variable() call allows passing a fallback value in the case of failure. Therefore something like the below might work cleaner:

ACK, will update the same in V2

Quoted 15 lines

foreach d: depends

	static_obj = [get_variable('static_rte_' + d, '']
	if static_obj == ''
		build = false
		reason = '....'
		subdir_done()
	endif
	static_objs += static_obj

...

Maybe a disabler object could be used also.

Regards,
/Bruce

#5 lore raw

PATCH v2 1/1 net/octeontx: fix meson build for disabled octeontx drivers

In reply to [email protected]

From: Amit Gupta <[email protected]>

Add a additional condition to check if all required internal dependencies are met before building octeontx drivers using meson.

Bugzilla ID: 387

Fixes 7f615033d64f ("drivers/net: build Cavium NIC PMDs with meson")

---
v2:
- rebased to v20.02
- upstream comments incorporated.

 drivers/net/octeontx/base/meson.build | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
drivers/net/octeontx/base/meson.build +5 -1
index a06a2c8..035aeda 100644
@@ -10,7 +10,11 @@ sources = [
 depends = ['ethdev', 'mempool_octeontx']
 static_objs = []
 foreach d: depends
-	static_objs += [get_variable('static_rte_' + d)]
+	test_dep_obj = '@0@'.format(get_variable('static_rte_' + d, ''))
+	if test_dep_obj == ''
+		subdir_done()
+	endif
+	static_objs += get_variable('static_rte_' + d)
 endforeach
 
 c_args = cflags
Signature · 1 line
1.8.3.1
#6 lore raw

Re: [dpdk-dev] [PATCH v2 1/1] net/octeontx: fix meson build for disabled octeontx drivers

Quoted 23 lines · On Mon, Mar 02, 2020 at 12:01:55PM +0530, [email protected] wrote:

From: Amit Gupta <[email protected]>

Add a additional condition to check if all required internal dependencies are met before building octeontx drivers using meson.

Bugzilla ID: 387

Fixes 7f615033d64f ("drivers/net: build Cavium NIC PMDs with meson")

---
v2:
- rebased to v20.02
- upstream comments incorporated.

 drivers/net/octeontx/base/meson.build | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
drivers/net/octeontx/base/meson.build +0 -0
index a06a2c8..035aeda 100644

drivers/net/octeontx/base/meson.build sources = [ · line 18

Quoted 10 lines
drivers/net/octeontx/base/meson.build +5 -1
@@ -10,7 +10,11 @@ sources = [
 depends = ['ethdev', 'mempool_octeontx']
 static_objs = []
 foreach d: depends
-	static_objs += [get_variable('static_rte_' + d)]
+	test_dep_obj = '@0@'.format(get_variable('static_rte_' + d, ''))
+	if test_dep_obj == ''
+		subdir_done()
+	endif
+	static_objs += get_variable('static_rte_' + d)
 endforeach

very minor nit - you can use "test_dep_obj" here rather than calling get_variable twice.

/Bruce

author
#7 lore raw

Re: [dpdk-dev] [EXT] Re: [PATCH v2 1/1] net/octeontx: fix meson build for disabled octeontx drivers

test_dep_obj is being formatted as string object, so can't be used as static obj..

Amit

Quoted 50 lines

-----Original Message-----
From: Bruce Richardson <[email protected]>
Sent: Monday, March 2, 2020 4:23 PM
To: Amit Gupta <[email protected]>
Cc: Harman Kalra <[email protected]>; [email protected]; [email protected]
Subject: [EXT] Re: [dpdk-dev] [PATCH v2 1/1] net/octeontx: fix meson build for disabled octeontx drivers

External Email

----------------------------------------------------------------------

Quoted 26 lines · On Mon, Mar 02, 2020 at 12:01:55PM +0530, [email protected] wrote:

From: Amit Gupta <[email protected]>

Add a additional condition to check if all required internal dependencies are met before building octeontx drivers using meson.

Bugzilla ID: 387

Fixes 7f615033d64f ("drivers/net: build Cavium NIC PMDs with meson")

---
v2:
- rebased to v20.02
- upstream comments incorporated.

 drivers/net/octeontx/base/meson.build | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
drivers/net/octeontx/base/meson.build +0 -0
index a06a2c8..035aeda 100644
@@ -10,7 +10,11 @@ sources = [
 depends = ['ethdev', 'mempool_octeontx']  static_objs = []  foreach

d: depends

drivers/net/octeontx/base/meson.build sources = [ · line 18

Quoted 7 lines
drivers/net/octeontx/base/meson.build +5 -1
-	static_objs += [get_variable('static_rte_' + d)]
+	test_dep_obj = '@0@'.format(get_variable('static_rte_' + d, ''))
+	if test_dep_obj == ''
+		subdir_done()
+	endif
+	static_objs += get_variable('static_rte_' + d)
 endforeach

very minor nit - you can use "test_dep_obj" here rather than calling get_variable twice.

/Bruce

#8 lore raw

Re: [dpdk-dev] [EXT] Re: [PATCH v2 1/1] net/octeontx: fix meson build for disabled octeontx drivers

Quoted 50 lines · Amit Gupta
Quoted 41 lines

-----Original Message-----
From: Bruce Richardson <[email protected]>
Sent: Monday, March 2, 2020 4:23 PM
To: Amit Gupta <[email protected]>
Cc: Harman Kalra <[email protected]>; [email protected]; [email protected]
Subject: [EXT] Re: [dpdk-dev] [PATCH v2 1/1] net/octeontx: fix meson build for disabled octeontx drivers

External Email

----------------------------------------------------------------------

Quoted 28 lines · On Mon, Mar 02, 2020 at 12:01:55PM +0530, [email protected] wrote:

From: Amit Gupta <[email protected]>

Add a additional condition to check if all required internal dependencies are met before building octeontx drivers using meson.

Bugzilla ID: 387

Fixes 7f615033d64f ("drivers/net: build Cavium NIC PMDs with meson")

---
v2:
- rebased to v20.02
- upstream comments incorporated.

 drivers/net/octeontx/base/meson.build | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
drivers/net/octeontx/base/meson.build +0 -0
index a06a2c8..035aeda 100644
@@ -10,7 +10,11 @@ sources = [
 depends = ['ethdev', 'mempool_octeontx']  static_objs = []  foreach

d: depends

drivers/net/octeontx/base/meson.build +1 -1
-	static_objs += [get_variable('static_rte_' + d)]
+	test_dep_obj = '@0@'.format(get_variable('static_rte_' + d, ''))
Quoted 9 lines

drivers/net/octeontx/base/meson.build sources = [ · line 18

Quoted 5 lines
drivers/net/octeontx/base/meson.build +4 -0
+	if test_dep_obj == ''
+		subdir_done()
+	endif
+	static_objs += get_variable('static_rte_' + d)
 endforeach

very minor nit - you can use "test_dep_obj" here rather than calling get_variable twice.

Quoted 1 line

test_dep_obj is being formatted as string object, so can't be used as static obj..

Apologies, you are quite right, I missed that.

One final suggestion - the "is_variable" function is probably want you want rather than using get_variable with a fallback. It should save the use of a temporary variable completely.

/Bruce

author
#9 lore raw

Re: [dpdk-dev] [EXT] Re: [PATCH v2 1/1] net/octeontx: fix meson build for disabled octeontx drivers

ACK

Quoted 73 lines

-----Original Message-----
From: Bruce Richardson <[email protected]>
Sent: Tuesday, March 3, 2020 4:47 PM
To: Amit Gupta <[email protected]>
Cc: Harman Kalra <[email protected]>; [email protected]; [email protected]
Subject: Re: [EXT] Re: [dpdk-dev] [PATCH v2 1/1] net/octeontx: fix meson build for disabled octeontx drivers

Quoted 6 lines · Amit Gupta
Quoted 6 lines

-----Original Message-----
From: Bruce Richardson <[email protected]>
Sent: Monday, March 2, 2020 4:23 PM
To: Amit Gupta <[email protected]>
Cc: Harman Kalra <[email protected]>; [email protected];

[email protected]

Quoted 47 lines
Quoted 38 lines

Subject: [EXT] Re: [dpdk-dev] [PATCH v2 1/1] net/octeontx: fix meson build for disabled octeontx drivers

External Email

--------------------------------------------------------------------
-- On Mon, Mar 02, 2020 at 12:01:55PM +0530, [email protected]

Quoted 30 lines · wrote:

From: Amit Gupta <[email protected]>

Add a additional condition to check if all required internal dependencies are met before building octeontx drivers using meson.

Bugzilla ID: 387

Fixes 7f615033d64f ("drivers/net: build Cavium NIC PMDs with

meson")

---
v2:
- rebased to v20.02
- upstream comments incorporated.

 drivers/net/octeontx/base/meson.build | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)
drivers/net/octeontx/base/meson.build +0 -0
index a06a2c8..035aeda 100644
@@ -10,7 +10,11 @@ sources = [
 depends = ['ethdev', 'mempool_octeontx']  static_objs = []

foreach
d: depends

drivers/net/octeontx/base/meson.build +1 -1
-	static_objs += [get_variable('static_rte_' + d)]
+	test_dep_obj = '@0@'.format(get_variable('static_rte_' + d, ''))
Quoted 9 lines

drivers/net/octeontx/base/meson.build sources = [ · line 18

Quoted 5 lines
drivers/net/octeontx/base/meson.build +4 -0
+	if test_dep_obj == ''
+		subdir_done()
+	endif
+	static_objs += get_variable('static_rte_' + d)
 endforeach

very minor nit - you can use "test_dep_obj" here rather than calling get_variable twice.

Quoted 1 line

test_dep_obj is being formatted as string object, so can't be used as static

obj..

Apologies, you are quite right, I missed that.

One final suggestion - the "is_variable" function is probably want you want rather than using get_variable with a fallback. It should save the use of a temporary variable completely.

/Bruce

#10 lore raw

PATCH v3 1/1 net/octeontx: fix meson build for disabled octeontx drivers

In reply to [email protected]

From: Amit Gupta <[email protected]>

Add a condition to check if octeontx drivers are disabled. octeontx drivers are built only if dependent drivers i.e. ethdev, mempool and common/octeontx are enabled.

Bugzilla ID: 387

Fixes 7f615033d64f ("drivers/net: build Cavium NIC PMDs with meson")
---
 drivers/net/octeontx/base/meson.build | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
drivers/net/octeontx/base/meson.build +4 -1
index a06a2c8..e1060fc 100644
@@ -10,7 +10,10 @@ sources = [
 depends = ['ethdev', 'mempool_octeontx']
 static_objs = []
 foreach d: depends
-	static_objs += [get_variable('static_rte_' + d)]
+	if not is_variable('shared_rte_' + d)
+		subdir_done()
+	endif
+	static_objs += get_variable('static_rte_' + d)
 endforeach
 
 c_args = cflags
Signature · 1 line
1.8.3.1
Reviewed-by on v3 1/1
#11 lore raw

Re: [dpdk-dev] [PATCH v3 1/1] net/octeontx: fix meson build for disabled octeontx drivers

Quoted 11 lines · On Wed, Mar 04, 2020 at 11:17:04AM +0530, [email protected] wrote:

From: Amit Gupta <[email protected]>

Add a condition to check if octeontx drivers are disabled. octeontx drivers are built only if dependent drivers i.e. ethdev, mempool and common/octeontx are enabled.

Bugzilla ID: 387

Fixes 7f615033d64f ("drivers/net: build Cavium NIC PMDs with meson")
Applied
#12 lore raw

Re: [dpdk-dev] [PATCH v3 1/1] net/octeontx: fix meson build for disabled octeontx drivers

Quoted 8 lines · Bruce Richardson
Quoted 6 lines · On Wed, Mar 04, 2020 at 11:17:04AM +0530, [email protected] wrote:

From: Amit Gupta <[email protected]>

Add a condition to check if octeontx drivers are disabled. octeontx drivers are built only if dependent drivers i.e. ethdev, mempool and common/octeontx are enabled.

Quoted 7 lines
Quoted 5 lines

Bugzilla ID: 387

Fixes 7f615033d64f ("drivers/net: build Cavium NIC PMDs with meson")

Applied to dpdk-next-net-mrvl/master. Thanks

Acked-by on v3 1/1
#13 lore raw

Re: [dpdk-dev] [PATCH v3 1/1] net/octeontx: fix meson build for disabled octeontx drivers

In reply to [email protected]
Quoted 11 lines · On Wed, Mar 04, 2020 at 11:17:04AM +0530, [email protected] wrote:

From: Amit Gupta <[email protected]>

Add a condition to check if octeontx drivers are disabled. octeontx drivers are built only if dependent drivers i.e. ethdev, mempool and common/octeontx are enabled.

Bugzilla ID: 387

Fixes 7f615033d64f ("drivers/net: build Cavium NIC PMDs with meson")
Quoted 23 lines
---
 drivers/net/octeontx/base/meson.build | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)
drivers/net/octeontx/base/meson.build +4 -1
index a06a2c8..e1060fc 100644
@@ -10,7 +10,10 @@ sources = [
 depends = ['ethdev', 'mempool_octeontx']
 static_objs = []
 foreach d: depends
-	static_objs += [get_variable('static_rte_' + d)]
+	if not is_variable('shared_rte_' + d)
+		subdir_done()
+	endif
+	static_objs += get_variable('static_rte_' + d)
 endforeach
 
 c_args = cflags
Signature · 1 line
1.8.3.1