Message ID | 1467905790-10597-4-git-send-email-thomas.monjalon@6wind.com (mailing list archive) |
---|---|
State | Superseded, archived |
Headers |
Return-Path: <dev-bounces@dpdk.org> X-Original-To: patchwork@dpdk.org Delivered-To: patchwork@dpdk.org Received: from [92.243.14.124] (localhost [IPv6:::1]) by dpdk.org (Postfix) with ESMTP id 3FD573237; Thu, 7 Jul 2016 17:36:39 +0200 (CEST) Received: from mail-wm0-f49.google.com (mail-wm0-f49.google.com [74.125.82.49]) by dpdk.org (Postfix) with ESMTP id 077452C17 for <dev@dpdk.org>; Thu, 7 Jul 2016 17:36:38 +0200 (CEST) Received: by mail-wm0-f49.google.com with SMTP id f126so215568172wma.1 for <dev@dpdk.org>; Thu, 07 Jul 2016 08:36:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=6wind-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=O2irlNG7ZDv4fnLzxxGH+oF6eWBX+eGV9UqMumP1z1U=; b=kWx9sd28+BeLC9GPHeUBiJ+o0abT4V0VcclTO/KhDIyo82p54Qp8diUr0BwS4gh2co ZSGlJ78RRXkwdluc3VEveVDc4DtcmU0r4W4mixhMoKdBnPY9KtepLJ18/hF4JyglscKM S+i5FPbnG36if1vbOM1kK/U8PYFGscJRxNypZpuJw7JclYUHyhrGwUV5FjXFpVsgmQQz zWj16caP9wisH57dVsKj5hDJLE56CPg+tzfwFHHFLfyB+b4R0y2tP56cLD/gcldLwTc3 UL022xEDfOtJzQ7oUBY0RtZ6vX+QDfrAg22RogV9aYPi01lPn0lN3JpO3di8SOsQQob0 S5Ww== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=O2irlNG7ZDv4fnLzxxGH+oF6eWBX+eGV9UqMumP1z1U=; b=VjQx1gboiCZYQf9mnqz0o6WGCAo4X1D/3joBE2tGLnRE9OprA8C1vp57eq+K9Jsr5s dJoPe+DC/dbNV6ZPLDARzjwAq7ezxii1zOoDe8L5wjWkXrLgEWMqIubRmWSlmNpCWKWx I68Haz8aO0SQxa+u/PtSgFrqYpbzALOBpxJZH6lzn3r8YdQb3Jbm8obV9RwTw3eiVcKW S+xrcDoEAQmSCPAXp/K45wsXImob8EvadO7T612QhkgSCr5KmZ+6nwny1Jeq+4THKN9z Mjvu2SRCI0nhvwTt5TRYfA8aKjf1hUqjsl242km21SVBsnMGy3IePjubuuoy4mOpVkfL UHgw== X-Gm-Message-State: ALyK8tLklYsqOtzCifBnFnQGvIz8/nRitOzFXy+YGafMBIB8JQQ3b51Az6IA75vg7tRZwkPE X-Received: by 10.28.184.16 with SMTP id i16mr3700908wmf.12.1467905797656; Thu, 07 Jul 2016 08:36:37 -0700 (PDT) Received: from XPS13.localdomain (184.203.134.77.rev.sfr.net. [77.134.203.184]) by smtp.gmail.com with ESMTPSA id p126sm559331wmp.13.2016.07.07.08.36.36 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 07 Jul 2016 08:36:36 -0700 (PDT) From: Thomas Monjalon <thomas.monjalon@6wind.com> To: Neil Horman <nhorman@tuxdriver.com> Cc: dev@dpdk.org Date: Thu, 7 Jul 2016 17:36:22 +0200 Message-Id: <1467905790-10597-4-git-send-email-thomas.monjalon@6wind.com> X-Mailer: git-send-email 2.7.0 In-Reply-To: <1467905790-10597-1-git-send-email-thomas.monjalon@6wind.com> References: <1467905790-10597-1-git-send-email-thomas.monjalon@6wind.com> Subject: [dpdk-dev] [PATCH 03/11] mk: fix build dependency of drivers on pmdinfogen X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: patches and discussions about DPDK <dev.dpdk.org> List-Unsubscribe: <http://dpdk.org/ml/options/dev>, <mailto:dev-request@dpdk.org?subject=unsubscribe> List-Archive: <http://dpdk.org/ml/archives/dev/> List-Post: <mailto:dev@dpdk.org> List-Help: <mailto:dev-request@dpdk.org?subject=help> List-Subscribe: <http://dpdk.org/ml/listinfo/dev>, <mailto:dev-request@dpdk.org?subject=subscribe> Errors-To: dev-bounces@dpdk.org Sender: "dev" <dev-bounces@dpdk.org> |
Commit Message
Thomas Monjalon
July 7, 2016, 3:36 p.m. UTC
When compiling the drivers, some code is generated with pmdinfogen.
A fresh parallel build can fail if a driver is compiled before pmdinfogen:
build/buildtools/dpdk-pmdinfogen: Permission denied
There was a dependency declared in drivers/Makefile but it cannot work
because this file is based on mk/rte.subdir.mk which do not handle
dependencies.
It is fixed by declaring the whole buildtools as (order only) prerequisite
of drivers.
Fixes: cb6696d22023 ("drivers: update registration macro usage")
Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com>
---
drivers/Makefile | 2 --
mk/rte.sdkbuild.mk | 1 +
2 files changed, 1 insertion(+), 2 deletions(-)
Comments
On Thu, Jul 07, 2016 at 05:36:22PM +0200, Thomas Monjalon wrote: > When compiling the drivers, some code is generated with pmdinfogen. > A fresh parallel build can fail if a driver is compiled before pmdinfogen: > build/buildtools/dpdk-pmdinfogen: Permission denied > > There was a dependency declared in drivers/Makefile but it cannot work > because this file is based on mk/rte.subdir.mk which do not handle > dependencies. > > It is fixed by declaring the whole buildtools as (order only) prerequisite > of drivers. > > Fixes: cb6696d22023 ("drivers: update registration macro usage") > > Signed-off-by: Thomas Monjalon <thomas.monjalon@6wind.com> > --- > drivers/Makefile | 2 -- > mk/rte.sdkbuild.mk | 1 + > 2 files changed, 1 insertion(+), 2 deletions(-) > > diff --git a/drivers/Makefile b/drivers/Makefile > index 75a3168..81c03a8 100644 > --- a/drivers/Makefile > +++ b/drivers/Makefile > @@ -34,6 +34,4 @@ include $(RTE_SDK)/mk/rte.vars.mk > DIRS-y += net > DIRS-$(CONFIG_RTE_LIBRTE_CRYPTODEV) += crypto > > -DEPDIRS-y += buildtools/pmdinfo > - > include $(RTE_SDK)/mk/rte.subdir.mk > diff --git a/mk/rte.sdkbuild.mk b/mk/rte.sdkbuild.mk > index fb68af2..354f006 100644 > --- a/mk/rte.sdkbuild.mk > +++ b/mk/rte.sdkbuild.mk > @@ -49,6 +49,7 @@ $(1): $(sort $(LOCAL_DEPDIRS-$(1))) > endef > > $(foreach d,$(ROOTDIRS-y),$(eval $(call depdirs_rule,$(d)))) > +drivers: | buildtools > I'm not sure i understand the reasoning here, DEPDIRS is meant to declare prerequisites to a directory (and its children) getting built, right? A parallel make should block any drivers getting built prior to pmdinfogen getting built. What am I missing? Neil > # > # build and clean targets > -- > 2.7.0 > >
2016-07-07 11:56, Neil Horman: > On Thu, Jul 07, 2016 at 05:36:22PM +0200, Thomas Monjalon wrote: > > When compiling the drivers, some code is generated with pmdinfogen. > > A fresh parallel build can fail if a driver is compiled before pmdinfogen: > > build/buildtools/dpdk-pmdinfogen: Permission denied > > > > There was a dependency declared in drivers/Makefile but it cannot work > > because this file is based on mk/rte.subdir.mk which do not handle > > dependencies. > > > > It is fixed by declaring the whole buildtools as (order only) prerequisite > > of drivers. [...] > > --- a/drivers/Makefile > > +++ b/drivers/Makefile > > @@ -34,6 +34,4 @@ include $(RTE_SDK)/mk/rte.vars.mk > > DIRS-y += net > > DIRS-$(CONFIG_RTE_LIBRTE_CRYPTODEV) += crypto > > > > -DEPDIRS-y += buildtools/pmdinfo > > - > > include $(RTE_SDK)/mk/rte.subdir.mk > > diff --git a/mk/rte.sdkbuild.mk b/mk/rte.sdkbuild.mk > > index fb68af2..354f006 100644 > > --- a/mk/rte.sdkbuild.mk > > +++ b/mk/rte.sdkbuild.mk > > @@ -49,6 +49,7 @@ $(1): $(sort $(LOCAL_DEPDIRS-$(1))) > > endef > > > > $(foreach d,$(ROOTDIRS-y),$(eval $(call depdirs_rule,$(d)))) > > +drivers: | buildtools > > > I'm not sure i understand the reasoning here, DEPDIRS is meant to declare > prerequisites to a directory (and its children) getting built, right? A > parallel make should block any drivers getting built prior to pmdinfogen getting > built. What am I missing? DEPDIRS-y is not parsed at all in the context of rte.subdir.mk. That's why this line was ignored by the build system.
On Thu, Jul 07, 2016 at 06:21:49PM +0200, Thomas Monjalon wrote: > 2016-07-07 11:56, Neil Horman: > > On Thu, Jul 07, 2016 at 05:36:22PM +0200, Thomas Monjalon wrote: > > > When compiling the drivers, some code is generated with pmdinfogen. > > > A fresh parallel build can fail if a driver is compiled before pmdinfogen: > > > build/buildtools/dpdk-pmdinfogen: Permission denied > > > > > > There was a dependency declared in drivers/Makefile but it cannot work > > > because this file is based on mk/rte.subdir.mk which do not handle > > > dependencies. > > > > > > It is fixed by declaring the whole buildtools as (order only) prerequisite > > > of drivers. > [...] > > > --- a/drivers/Makefile > > > +++ b/drivers/Makefile > > > @@ -34,6 +34,4 @@ include $(RTE_SDK)/mk/rte.vars.mk > > > DIRS-y += net > > > DIRS-$(CONFIG_RTE_LIBRTE_CRYPTODEV) += crypto > > > > > > -DEPDIRS-y += buildtools/pmdinfo > > > - > > > include $(RTE_SDK)/mk/rte.subdir.mk > > > diff --git a/mk/rte.sdkbuild.mk b/mk/rte.sdkbuild.mk > > > index fb68af2..354f006 100644 > > > --- a/mk/rte.sdkbuild.mk > > > +++ b/mk/rte.sdkbuild.mk > > > @@ -49,6 +49,7 @@ $(1): $(sort $(LOCAL_DEPDIRS-$(1))) > > > endef > > > > > > $(foreach d,$(ROOTDIRS-y),$(eval $(call depdirs_rule,$(d)))) > > > +drivers: | buildtools > > > > > I'm not sure i understand the reasoning here, DEPDIRS is meant to declare > > prerequisites to a directory (and its children) getting built, right? A > > parallel make should block any drivers getting built prior to pmdinfogen getting > > built. What am I missing? > > DEPDIRS-y is not parsed at all in the context of rte.subdir.mk. > That's why this line was ignored by the build system. > Ah, ok then (though it seems like that might be a useful variable to query, rather than dead reconing it inside the sdk build file Acked-by: Neil Horman <nhorman@tuxdriver.com>
diff --git a/drivers/Makefile b/drivers/Makefile index 75a3168..81c03a8 100644 --- a/drivers/Makefile +++ b/drivers/Makefile @@ -34,6 +34,4 @@ include $(RTE_SDK)/mk/rte.vars.mk DIRS-y += net DIRS-$(CONFIG_RTE_LIBRTE_CRYPTODEV) += crypto -DEPDIRS-y += buildtools/pmdinfo - include $(RTE_SDK)/mk/rte.subdir.mk diff --git a/mk/rte.sdkbuild.mk b/mk/rte.sdkbuild.mk index fb68af2..354f006 100644 --- a/mk/rte.sdkbuild.mk +++ b/mk/rte.sdkbuild.mk @@ -49,6 +49,7 @@ $(1): $(sort $(LOCAL_DEPDIRS-$(1))) endef $(foreach d,$(ROOTDIRS-y),$(eval $(call depdirs_rule,$(d)))) +drivers: | buildtools # # build and clean targets