Message ID | 1453267824-2880-1-git-send-email-mhall@mhcomputing.net (mailing list archive) |
---|---|
State | Rejected, archived |
Delegated to: | Thomas Monjalon |
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 144BD8D36; Wed, 20 Jan 2016 06:30:33 +0100 (CET) Received: from mail.mhcomputing.net (master.mhcomputing.net [74.208.228.170]) by dpdk.org (Postfix) with ESMTP id 2387E5A9B for <dev@dpdk.org>; Wed, 20 Jan 2016 06:30:31 +0100 (CET) Received: from mvs-01.mhcomputing.net (99-34-229-174.lightspeed.sntcca.sbcglobal.net [99.34.229.174]) by mail.mhcomputing.net (Postfix) with ESMTPSA id 2DAE3FC; Wed, 20 Jan 2016 00:30:30 -0500 (EST) From: Matthew Hall <mhall@mhcomputing.net> To: dev@dpdk.org Date: Tue, 19 Jan 2016 21:30:24 -0800 Message-Id: <1453267824-2880-1-git-send-email-mhall@mhcomputing.net> X-Mailer: git-send-email 2.5.0 Subject: [dpdk-dev] [PATCH] rte.extvars.mk: allow overriding RTE_SDK_BIN from the environment 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
Matthew Hall
Jan. 20, 2016, 5:30 a.m. UTC
Currently pktgen-dpdk and many other external apps will fail to compile
if the build output directory name is not equal to the target name.
This causes problems if you used an alternative build output directory.
Signed-off-by: Matthew Hall <mhall@mhcomputing.net>
---
mk/internal/rte.extvars.mk | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
Comments
Hi Matthew, RTE_SDK_BIN is an internal variable and should not be overriden. 2016-01-19 21:30, Matthew Hall: > Currently pktgen-dpdk and many other external apps will fail to compile > if the build output directory name is not equal to the target name. > > This causes problems if you used an alternative build output directory. Have you installed DPDK somewhere? Example: make install O=mybuild DESTDIR=mylocalinstall Then you should build your app like this: make RTE_SDK=$(readlink -e ../dpdk/mylocalinstall/usr/local/share/dpdk)
On 1/20/16 7:27 AM, Thomas Monjalon wrote: > Hi Matthew, > > RTE_SDK_BIN is an internal variable and should not be overriden. > > Have you installed DPDK somewhere? Example: > make install O=mybuild DESTDIR=mylocalinstall > > Then you should build your app like this: > make RTE_SDK=$(readlink -e ../dpdk/mylocalinstall/usr/local/share/dpdk) Hello Thomas, Is the way the make install target really works documented somewhere? This target did not exist when I first used DPDK in 2011, and since then I saw various documentation on building DPDK in various places, but not that much explanation what make install actually does. I recall various list threads about changing its behavior as well. For example, if I look at this apparently most official document: http://dpdk.org/doc/guides/linux_gsg/build_dpdk.html It has build examples such as: make install T=x86_64-native-linuxapp-gcc But it does not discuss "O=" or "DESTDIR=" or any other additional options. From some experiments on my machine, it looks like maybe I could do this: make install "T=${RTE_TARGET}" "O=build" "DESTDIR=build" Is that a valid possibility, to keep it all in one easy directory? Thanks, Matthew.
2016-01-20 21:15, Matthew Hall: > On 1/20/16 7:27 AM, Thomas Monjalon wrote: > > Hi Matthew, > > > > RTE_SDK_BIN is an internal variable and should not be overriden. > > > > Have you installed DPDK somewhere? Example: > > make install O=mybuild DESTDIR=mylocalinstall > > > > Then you should build your app like this: > > make RTE_SDK=$(readlink -e ../dpdk/mylocalinstall/usr/local/share/dpdk) > > Hello Thomas, > > Is the way the make install target really works documented somewhere? It is poorly described here: http://dpdk.org/doc/guides/prog_guide/dev_kit_root_make_help.html#install-targets > This target did not exist when I first used DPDK in 2011, and since then > I saw various documentation on building DPDK in various places, but not > that much explanation what make install actually does. I recall various > list threads about changing its behavior as well. Historically, "make install" was a convenient default build (with T= option). The DESTDIR option was added to make a real install after building. The standard form (without T=) is now implemented to do a real install. > For example, if I look at this apparently most official document: > > http://dpdk.org/doc/guides/linux_gsg/build_dpdk.html > > It has build examples such as: > > make install T=x86_64-native-linuxapp-gcc This command finishes with this message: Installation cannot run with T defined and DESTDIR undefined Yes you are right, some docs are neither complete nor up-to-date. Volunteers are welcome. > But it does not discuss "O=" or "DESTDIR=" or any other additional > options. From some experiments on my machine, it looks like maybe I > could do this: > > make install "T=${RTE_TARGET}" "O=build" "DESTDIR=build" > > Is that a valid possibility, to keep it all in one easy directory? Yes you can install where you want. Note that this command (with T= and O=) will build in the directory $O/$T i.e. build/${RTE_TARGET} and install in build/ Please confirm that this patch is not needed. Thanks
diff --git a/mk/internal/rte.extvars.mk b/mk/internal/rte.extvars.mk index 040d39f..3d5ba1f 100644 --- a/mk/internal/rte.extvars.mk +++ b/mk/internal/rte.extvars.mk @@ -52,7 +52,7 @@ RTE_EXTMK ?= $(RTE_SRCDIR)/Makefile export RTE_EXTMK # RTE_SDK_BIN must point to .config, include/ and lib/. -RTE_SDK_BIN := $(RTE_SDK)/$(RTE_TARGET) +RTE_SDK_BIN ?= $(RTE_SDK)/$(RTE_TARGET) ifeq ($(wildcard $(RTE_SDK_BIN)/.config),) $(error Cannot find .config in $(RTE_SDK)) endif