From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from mails.dpdk.org (mails.dpdk.org [217.70.189.124]) by inbox.dpdk.org (Postfix) with ESMTP id 21E48A09E4; Fri, 29 Jan 2021 16:39:42 +0100 (CET) Received: from [217.70.189.124] (localhost [127.0.0.1]) by mails.dpdk.org (Postfix) with ESMTP id 786ED4067B; Fri, 29 Jan 2021 16:39:41 +0100 (CET) Received: from mga09.intel.com (mga09.intel.com [134.134.136.24]) by mails.dpdk.org (Postfix) with ESMTP id DCC8040395 for ; Fri, 29 Jan 2021 16:39:39 +0100 (CET) IronPort-SDR: W/acP0BRdYzyMI6ycRlXLgX9yJ4goqSte5OBh27qN+5WRWYxSj8qwFHK4bD64Si2mtuJWi8Ycj aNonMFE7TM1A== X-IronPort-AV: E=McAfee;i="6000,8403,9878"; a="180579658" X-IronPort-AV: E=Sophos;i="5.79,385,1602572400"; d="scan'208";a="180579658" Received: from orsmga008.jf.intel.com ([10.7.209.65]) by orsmga102.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 29 Jan 2021 07:39:37 -0800 IronPort-SDR: R9I3lXRLiqf0S9TDIAUDcRN5lpmbifGA/i+5uYvpjpmBQmXuTYopmeTug5a3+JsZKVqtiQqdZU 05aWzq8A+/DA== X-IronPort-AV: E=Sophos;i="5.79,385,1602572400"; d="scan'208";a="389342411" Received: from bricha3-mobl.ger.corp.intel.com ([10.252.20.59]) by orsmga008-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-SHA; 29 Jan 2021 07:39:35 -0800 Date: Fri, 29 Jan 2021 15:39:32 +0000 From: Bruce Richardson To: Juraj =?utf-8?Q?Linke=C5=A1?= Cc: "thomas@monjalon.net" , "Ruifeng.Wang@arm.com" , "jerinjacobk@gmail.com" , "hemant.agrawal@nxp.com" , "ferruh.yigit@intel.com" , "aboyer@pensando.io" , "dev@dpdk.org" Message-ID: <20210129153932.GJ929@bricha3-MOBL.ger.corp.intel.com> References: <1611916159-32158-1-git-send-email-juraj.linkes@pantheon.tech> <20210129114340.GE929@bricha3-MOBL.ger.corp.intel.com> <20210129135116.GG929@bricha3-MOBL.ger.corp.intel.com> <20210129144225.GH929@bricha3-MOBL.ger.corp.intel.com> <20210129150105.GI929@bricha3-MOBL.ger.corp.intel.com> <6d59b6aaa6ae4697ae7200254be55065@pantheon.tech> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline Content-Transfer-Encoding: 8bit In-Reply-To: <6d59b6aaa6ae4697ae7200254be55065@pantheon.tech> Subject: Re: [dpdk-dev] [RFC PATCH v1] build: kni gcc cross-compilation support X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: DPDK patches and discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: dev-bounces@dpdk.org Sender: "dev" On Fri, Jan 29, 2021 at 03:17:02PM +0000, Juraj Linkeš wrote: > > > > -----Original Message----- > > From: Bruce Richardson > > Sent: Friday, January 29, 2021 4:01 PM > > To: Juraj Linkeš > > Cc: thomas@monjalon.net; Ruifeng.Wang@arm.com; jerinjacobk@gmail.com; > > hemant.agrawal@nxp.com; ferruh.yigit@intel.com; aboyer@pensando.io; > > dev@dpdk.org > > Subject: Re: [RFC PATCH v1] build: kni gcc cross-compilation support > > > > On Fri, Jan 29, 2021 at 02:47:57PM +0000, Juraj Linkeš wrote: > > > > > > > > > > -----Original Message----- > > > > From: Bruce Richardson > > > > Sent: Friday, January 29, 2021 3:42 PM > > > > To: Juraj Linkeš > > > > Cc: thomas@monjalon.net; Ruifeng.Wang@arm.com; > > > > jerinjacobk@gmail.com; hemant.agrawal@nxp.com; > > > > ferruh.yigit@intel.com; aboyer@pensando.io; dev@dpdk.org > > > > Subject: Re: [RFC PATCH v1] build: kni gcc cross-compilation support > > > > > > > > > > > > Can we find some way of getting it working for both cases. > > > > > > For native builds we want: > > > > > > > > > > > > * build kernel-dir = /lib/modules//build > > > > > > * install dir = /lib/modules//extra/dpdk > > > > > > > > > > > > What are the expected equivalent paths for cross building? > > > > > > > > > > > > > > > > The ubuntu1804 packages are installing aarch64 cross files to > > > > > /usr/aarch64- > > > > linux-gnu, so we could install it to /usr/aarch64-linux- > > > > gnu/lib/modules//extra/dpdk, or > > > > /usr//lib/modules//extra/dpdk in general. I think > > > > we can get from 'make kernelversion', so that would work, > > > > although I'm not sure this is the right place. > > > > > > > > > So what do you specify as the "kernel_dir" for the cross compile? > > > > > > > > > > The place where I cloned (and cross-compiled) linux sources: $HOME/linux. > > > > > So I think the key problem is that for cross-compilation you need two completely > > independent paths, while for native builds the two can be linked. Is that correct? > > Assuming that we want to install cross modules, then yes, although it's incomplete. There's also the scenario when a user would use different kernel_dir than the default for native builds. I don't know why anyone would do that, but it is a theoretical possibility :-) In the cross-compile install case, is the prefix /usr/aarch64-linux-gnu/ coming from a DESTDIR environment variable? If it is, then we could just use the kernel_dir option for the build path, and always install to /lib/modules//... allowing any cross-compiler relocation to take care of the rest.