diff mbox series

mk: fix output directory name when compiling with custom kernel header dir

Message ID 20190718132912.28250-1-herakliusz.lipiec@intel.com (mailing list archive)
State Superseded, archived
Headers show
Series mk: fix output directory name when compiling with custom kernel header dir | expand

Checks

Context Check Description
ci/checkpatch success coding style OK
ci/Intel-compilation fail Compilation issues
ci/mellanox-Performance-Testing success Performance Testing PASS
ci/intel-Performance-Testing success Performance Testing PASS

Commit Message

Lipiec, Herakliusz July 18, 2019, 1:29 p.m. UTC
When building dpdk with differnt kernel headers by specifying
RTE_KERNELDIR igb_uio is compiled to directory with a name of the
version of kernel thats running on the system instead of the one that
dpdk is actually compiled against. Fixed by replacing hardcoded value
with value from RTE_KERNELDIR.

Cc: stable@intel.com
Cc: bruce.richardson@intel.com
Signed-off-by: Herakliusz Lipiec <herakliusz.lipiec@intel.com>
---
 mk/rte.sdkinstall.mk | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Thomas Monjalon July 18, 2019, 1:43 p.m. UTC | #1
18/07/2019 15:29, Herakliusz Lipiec:
> When building dpdk with differnt kernel headers by specifying
> RTE_KERNELDIR igb_uio is compiled to directory with a name of the
> version of kernel thats running on the system instead of the one that
> dpdk is actually compiled against. Fixed by replacing hardcoded value
> with value from RTE_KERNELDIR.
> 
> Cc: stable@intel.com
> Cc: bruce.richardson@intel.com
> Signed-off-by: Herakliusz Lipiec <herakliusz.lipiec@intel.com>
> ---
> --- a/mk/rte.sdkinstall.mk
> +++ b/mk/rte.sdkinstall.mk
>  ifeq ($(RTE_EXEC_ENV),linux)
> -kerneldir   ?= /lib/modules/$(shell uname -r)/extra/dpdk
> +kerneldir ?= $(subst /build,/extra/dpdk,$(RTE_KERNELDIR))
>  else
>  kerneldir   ?= /boot/modules
>  endif

You are changing the alignment :)

This change is only for the "make" system.
How does it work for meson?
Lipiec, Herakliusz July 18, 2019, 2:06 p.m. UTC | #2
> From: Thomas Monjalon [mailto:thomas@monjalon.net]
> Sent: Thursday, July 18, 2019 2:44 PM
> 18/07/2019 15:29, Herakliusz Lipiec:
> > When building dpdk with differnt kernel headers by specifying
> > RTE_KERNELDIR igb_uio is compiled to directory with a name of the
> > version of kernel thats running on the system instead of the one that
> > dpdk is actually compiled against. Fixed by replacing hardcoded value
> > with value from RTE_KERNELDIR.
> >
> > Cc: stable@intel.com
> > Cc: bruce.richardson@intel.com
> > Signed-off-by: Herakliusz Lipiec <herakliusz.lipiec@intel.com>
> > ---
> > --- a/mk/rte.sdkinstall.mk
> > +++ b/mk/rte.sdkinstall.mk
> >  ifeq ($(RTE_EXEC_ENV),linux)
> > -kerneldir   ?= /lib/modules/$(shell uname -r)/extra/dpdk
> > +kerneldir ?= $(subst /build,/extra/dpdk,$(RTE_KERNELDIR))
> >  else
> >  kerneldir   ?= /boot/modules
> >  endif
> 
> You are changing the alignment :)
> 
> This change is only for the "make" system.
> How does it work for meson?
> 
> 

The issue doesn't seem to be happening when using meson build system,
kernel modules are compiled into correct directory.
diff mbox series

Patch

diff --git a/mk/rte.sdkinstall.mk b/mk/rte.sdkinstall.mk
index 5c4215cd7..a602dd6cc 100644
--- a/mk/rte.sdkinstall.mk
+++ b/mk/rte.sdkinstall.mk
@@ -27,7 +27,7 @@  ifeq ($(RTE_EXEC_ENV),linuxapp)
 RTE_EXEC_ENV=linux
 endif
 ifeq ($(RTE_EXEC_ENV),linux)
-kerneldir   ?= /lib/modules/$(shell uname -r)/extra/dpdk
+kerneldir ?= $(subst /build,/extra/dpdk,$(RTE_KERNELDIR))
 else
 kerneldir   ?= /boot/modules
 endif