From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from dpdk.org (dpdk.org [92.243.14.124]) by inbox.dpdk.org (Postfix) with ESMTP id 5ABBBA04C0; Fri, 25 Sep 2020 16:08:51 +0200 (CEST) Received: from [92.243.14.124] (localhost [127.0.0.1]) by dpdk.org (Postfix) with ESMTP id BC3431E964; Fri, 25 Sep 2020 16:08:49 +0200 (CEST) Received: from mail-ot1-f66.google.com (mail-ot1-f66.google.com [209.85.210.66]) by dpdk.org (Postfix) with ESMTP id 59AC01E93C for ; Fri, 25 Sep 2020 16:08:48 +0200 (CEST) Received: by mail-ot1-f66.google.com with SMTP id n61so2370609ota.10 for ; Fri, 25 Sep 2020 07:08:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=KhFPcGz1DlRpj6sVVtnWlFrPcDVELgwNQzTTdRvfLQo=; b=Vrkta5loDTRiq/hhgd8zWzgMf4QCwsqYFAGeELIuS0m9qRZvYrkQFDh+ta7y59nRua gqUer573sTdnLavWxi1LC0MiRJRXMD3kV2TKoAF445InNCSJuEq3saZI26iZfjRFKlHf u8zrhKDd9aQACFowRzMS46AvbvuCyIRWR76GM= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=KhFPcGz1DlRpj6sVVtnWlFrPcDVELgwNQzTTdRvfLQo=; b=Wb/J0pGPWKXpokKgjDVY8PqvesCUBiss68jF5TkEM9yYJkvJmel9zF2K0or3XbltyU zQv50TixXgO4i/EhKIB0vRpruNRC57TRBo1fGXxKJKxaoDs9pSU/PNXDFp1+CvaJB7Hj QnJ3xPDj5b68eaqd2g9Z/EhUxu7BvB/prT8qEw50oXquzbyI610GKum1GtNKzlZ2IN+y RO0tnhpnToPsFtDMhgOMrR3jrkDcXz8C9t6nERUOgBPfMofh7ecWcIFIamoe8Gw68Tcl EXxTWX3cbw+N7DNEsiC9Qr73KHd+T0OlBBZ1EjKtJdnUlaWbGfjvmP9dXEio56eKg6dl Mwdw== X-Gm-Message-State: AOAM532M3DTaALSjOI6Zqw07I/oZ0sxgRmgr8HQC1L7qJSmh6+TYDWM1 isHm5wP44ab8/lmmKqE10qwiQkXc8J7o0bxoT9v9WRb8Fww= X-Google-Smtp-Source: ABdhPJyYFQqywtYwRmfmA8WqyCjsIDAEdCren/j/w8tsBCp0UKfGdcKN/qhO9dkKEXwP1UWF4oCnlSemNCcK6dtswzg= X-Received: by 2002:a9d:6a19:: with SMTP id g25mr406344otn.267.1601042926419; Fri, 25 Sep 2020 07:08:46 -0700 (PDT) MIME-Version: 1.0 References: <20200924163742.321600-1-lance.richardson@broadcom.com> <20200925091341.GB923@bricha3-MOBL.ger.corp.intel.com> <20200925134436.GB943@bricha3-MOBL.ger.corp.intel.com> In-Reply-To: <20200925134436.GB943@bricha3-MOBL.ger.corp.intel.com> From: Lance Richardson Date: Fri, 25 Sep 2020 10:08:35 -0400 Message-ID: To: Bruce Richardson Cc: dev@dpdk.org Content-Type: text/plain; charset="UTF-8" X-Content-Filtered-By: Mailman/MimeDel 2.1.15 Subject: Re: [dpdk-dev] [PATCH] build: support i686 target on x86 64-bit hosts X-BeenThere: dev@dpdk.org X-Mailman-Version: 2.1.15 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, Sep 25, 2020 at 9:44 AM Bruce Richardson wrote: > > On Fri, Sep 25, 2020 at 09:27:25AM -0400, Lance Richardson wrote: > > On Fri, Sep 25, 2020 at 5:13 AM Bruce Richardson > > wrote: > > > > > > On Thu, Sep 24, 2020 at 12:37:42PM -0400, Lance Richardson wrote: > > > > Add meson cross files for building i686 targets using gcc on x86_64 > > > > linux hosts. > > > > > > > > Uusage example: > > > > > > > > meson --cross-file config/x86/cross-i686-linux-gcc build-i686 > > > > ninja -C build-i686 > > > > > > > > Signed-off-by: Lance Richardson > > > > --- > > > > Red Hat distros use a different name for the 32-bit pkg-config > > > > command from most other distros, maybe there is a better way > > > > to handle this than using separate files. > > > > > > > > Others will probably have better naming suggestions for the files. > > > > > > > Just to note that rather than using cross-files, building i686 on x86_64 > > > should be possible by just setting environment variables. > > > > > > For example, on Ubuntu 20.04, this works for me: > > > > > > PKG_CONFIG_LIBDIR=/usr/lib/i386-linux-gnu/pkgconfig CFLAGS='-m32' LDFLAGS='-m32' meson --werror build-32bit > > > ninja -C build-32bit/ > > > > > > For Fedora or Redhat system the PKG_CONFIG_LIBDIR will be different (I > > > think just /usr/lib/pkgconfig), but the rest should work identically. > > > > > > /Bruce > > > > Thanks, that does work, although I'll have some trouble remembering it > > for future > > use (unlike using cross-files). Googling for "PKG_CONFIG_LIBDIR meson dpdk" > > did lead me to this discussion, which makes it sound like cross-files > > might still > > worthy of consideration: > > > > https://patches.dpdk.org/patch/69067/ > > > > Yes, absolutely the cross-file is worthy of consideration. The most awkward > part in both cases is getting the 32-bit pkg-config right. Agreed, having the distro-specific bits is not pretty. Would it be possible to set the pkgconfig binary name or PKG_CONFIG_LIBDIR in config/x86/meson.build? If so, maybe we could have a single cross-file and probe for the distro-specifics in meson.build.