DPDK patches and discussions
 help / color / mirror / Atom feed
From: Thinh Tran <thinhtr@linux.vnet.ibm.com>
To: Ali Alnubani <alialnu@nvidia.com>,
	"NBU-Contact-Thomas Monjalon (EXTERNAL)" <thomas@monjalon.net>
Cc: "dev@dpdk.org" <dev@dpdk.org>,
	David Christensen <drc@linux.vnet.ibm.com>
Subject: Re: [PATCH] config: set pkgconfig for ppc64le
Date: Mon, 18 Jul 2022 15:16:43 -0500	[thread overview]
Message-ID: <108d23bd-30f2-b1e9-6e0c-7d9f77d04049@linux.vnet.ibm.com> (raw)
In-Reply-To: <DM4PR12MB5167DD9D1B5B71741166070EDA889@DM4PR12MB5167.namprd12.prod.outlook.com>



On 7/14/2022 1:58 AM, Ali Alnubani wrote:
>> -----Original Message-----
>> From: Thinh Tran <thinhtr@linux.vnet.ibm.com>
>> Sent: Wednesday, July 13, 2022 10:50 PM
>> To: Ali Alnubani <alialnu@nvidia.com>; NBU-Contact-Thomas Monjalon
>> (EXTERNAL) <thomas@monjalon.net>
>> Cc: dev@dpdk.org; David Christensen <drc@linux.vnet.ibm.com>
>> Subject: Re: [PATCH] config: set pkgconfig for ppc64le
>>
>> Hi,
>>
>> On 7/13/2022 2:39 AM, Ali Alnubani wrote:
>>>> -----Original Message-----
>>>> From: Thomas Monjalon <thomas@monjalon.net>
>>>> Sent: Monday, July 11, 2022 11:11 PM
>>>> To: Ali Alnubani <alialnu@nvidia.com>
>>>> Cc: dev@dpdk.org; David Christensen <drc@linux.vnet.ibm.com>
>>>> Subject: Re: [PATCH] config: set pkgconfig for ppc64le
>>>>
>>>> + PPC maintainer
>>>>
>>>> 07/07/2022 13:41, Ali Alnubani:
>>>>> Meson fails to detect the dependencies that are included
>>>>> in PKG_CONFIG_PATH and built for ppc64le if binaries.pkgconfig
>>>>> is not set in the ppc64le cross-file for Ubuntu.
>>>>>
>>>>> This fixes the issue by setting binaries.pkgconfig to the
>>>>> binary provided by the package 'pkg-config-powerpc64le-linux-gnu'.
>>>>>
>>>>> Signed-off-by: Ali Alnubani <alialnu@nvidia.com>
>>>>> ---
>>>>>    config/ppc/ppc64le-power8-linux-gcc-ubuntu | 1 +
>>>>
>>>> Why not adding the same for ppc64le-power8-linux-gcc?
>>>>
>>>>> +pkgconfig = 'powerpc64le-linux-gnu-pkg-config'
>>>
>>> I didn't find any operating systems that distribute the powerpc64le cross-
>> compiler with the binary names found in config/ppc/ppc64le-power8-linux-
>> gcc.
>>> Both Ubuntu and Fedora use the -gnu suffix. Fedora doesn't seem to have
>> a pkg-config binary for powerpc64le though.
>>
>> I am able to cross-compile dpdk on Ubuntu with the default config file
>> My system info:
>> # uname -rvm
>>    5.4.0-113-generic #127-Ubuntu SMP Wed May 18 14:30:56 UTC 2022 x86_64
>>
>> # apt list gcc-10-powerpc64le-linux-gnu | grep installed
>> gcc-10-powerpc64le-linux-gnu/focal-updates,focal-security,now
>> 10.3.0-1ubuntu1~20.04cross1 amd64 [installed]
>> # which powerpc64le-linux-gnu-gcc
>> /usr/bin/powerpc64le-linux-gnu-gcc
>> # ls -l /usr/bin/powerpc64le-linux-gnu-gcc
>> lrwxrwxrwx 1 root root 37 Jul 13 11:56
>> /usr/bin/powerpc64le-linux-gnu-gcc -> /usr/bin/powerpc64le-linux-gnu-gcc-
>> 10
>>
>> # apt list pkg-config | grep installed
>> pkg-config/focal,now 0.29.1-0ubuntu4 amd64 [installed]
>>
>> # meson cross-build_p8 --cross-file
>> config/ppc/ppc64le-power8-linux-gcc-ubuntu
>> The Meson build system
>> Version: 0.56.2
>> Source dir: /root/dpdk
>> Build dir: /root/dpdk/cross-build_p8
>> Build type: cross build
>> Program cat found: YES (/bin/cat)
>> Project name: DPDK
>> Project version: 22.07.0-rc4
>> C compiler for the host machine: powerpc64le-linux-gnu-gcc (gcc 10.3.0
>> "powerpc64le-linux-gnu-gcc (Ubuntu 10.3.0-1ubuntu1~20.04) 10.3.0")
>> C linker for the host machine: powerpc64le-linux-gnu-gcc ld.bfd 2.34
>> C compiler for the build machine: cc (gcc 9.4.0 "cc (Ubuntu
>> 9.4.0-1ubuntu1~20.04.1) 9.4.0")
>> C linker for the build machine: cc ld.bfd 2.34
>> Build machine cpu family: x86_64
>> Build machine cpu: x86_64
>> Host machine cpu family: x86_64
>> Host machine cpu: x86_64
>> Target machine cpu family: ppc64
>> Target machine cpu: power8
>> Program pkg-config found: YES (/usr/bin/pkg-config)
>> Program check-symbols.sh found: YES (/root/dpdk/buildtools/check-
>> symbols.sh)
>> Program options-ibverbs-static.sh found: YES
>> (/root/dpdk/buildtools/options-ibverbs-static.sh)
>> Program objdump found: YES (/usr/bin/objdump)
>> Program python3 found: YES (/usr/bin/python3)
>> Program cat found: YES (/bin/cat)
>> Program ../buildtools/symlink-drivers-solibs.sh found: YES (/bin/sh
>> /root/dpdk/config/../buildtools/symlink-drivers-solibs.sh)
>> Checking for size of "void *" : 8
>> Checking for size of "void *" : 8
>> ......
>> Build targets in project: 851
>>
>> Found ninja-1.10.0 at /usr/bin/ninja
>> # ninja -C cross-build_p8
>> ninja: Entering directory `cross-build_p8'
>> [2933/2933] Linking target app/test/dpdk-test
>>
>> similar to it, I'm able to build for power9
>>
> 
> Hi Thinh,
> 
> I'm also able to cross-build for ppc64 on Ubuntu, but without setting binaries.pkgconfig, meson will skip some build targets, even if PKG_CONFIG_PATH points to their dependencies.
> Have you tried on Fedora?
Hi Ali,
Sorry for the delay.
Cross-build failed - missing the stdio.h same as yours on Fedora 30 and 35.
checking gcc-powerpc64-linux-gnu.x86_64 and 
gcc-powerpc64le-linux-gnu.x86_64 packages, both do not ship stdio.h and 
other header files: pthread.h, inttypes.h, etc...

We are investing this issue.
Regards,
Thinh Tran

  reply	other threads:[~2022-07-18 20:16 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-07 11:41 Ali Alnubani
2022-07-11 20:10 ` Thomas Monjalon
2022-07-13  7:39   ` Ali Alnubani
2022-07-13  9:12     ` Thomas Monjalon
2022-07-13 10:14       ` Ali Alnubani
2022-07-13 10:51         ` Ali Alnubani
2022-07-13 19:49     ` Thinh Tran
2022-07-14  6:58       ` Ali Alnubani
2022-07-18 20:16         ` Thinh Tran [this message]
2022-07-19 23:02           ` David Christensen
2022-08-29 10:30             ` Thomas Monjalon
2022-08-30 17:39               ` David Christensen
2022-08-30 18:36                 ` Ali Alnubani
2022-10-26 16:21                   ` Ali Alnubani
2022-08-30 17:36 ` David Christensen

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=108d23bd-30f2-b1e9-6e0c-7d9f77d04049@linux.vnet.ibm.com \
    --to=thinhtr@linux.vnet.ibm.com \
    --cc=alialnu@nvidia.com \
    --cc=dev@dpdk.org \
    --cc=drc@linux.vnet.ibm.com \
    --cc=thomas@monjalon.net \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).