DPDK patches and discussions
 help / color / mirror / Atom feed
From: Raphael Cohn <raphael.cohn@stormmq.com>
To: dev@dpdk.org
Subject: [dpdk-dev] Changes to DPDK 17.02 to cross compile for Linux on Mac OS X
Date: Tue, 14 Mar 2017 07:56:40 +0000	[thread overview]
Message-ID: <CACCP0Gq54-OWzJ2xvSCo+kNnNM+3Ao_nyLHYqsktXWG2DGkWXQ@mail.gmail.com> (raw)

Hi,

If anyone's interested, there are a few small changes needed to pmdinfogen
to get it to cross-compile using Homebrew on Mac OS X. These aren't really
patch worthy, as my changes will break it for other BSD-based systems.

Firstly
local libelfPrefix="$(brew --prefix libelf)"
                local extra="-I${libelfPrefix}/include/libelf
-I${libelfPrefix}/include -isystem${dpdkSrcDir}/buildtools/pmdinfogen"
                sed -i -e 's;-g;-g '"$extra"';g'
buildtools/pmdinfogen/Makefile
                sed -i -e 's;#include <sys/endian\.h>;#include
"endian.h";g' buildtools/pmdinfogen/pmdinfogen.h

Secondly, create a simple endian.h file inside buildtools/pmdinfogen. There
are a few ones floating around on the web.

Thirdly, create a stripped down elf.h inside buildtools/pmdinfogen. There
are a few public domain ones floating around on the web. I'm not sure about
the copyright status of these, so I've not linked to them.

I'm using these changes currently as part of a Rust crate wrapping DPDK,
called `dpdk-sys` (it has a mid-level Rust wrapper called `dpdk`). It
compiles but it's early days - see https://github.com/lemonrock/dpdk .

Raph

                 reply	other threads:[~2017-03-14  7:56 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=CACCP0Gq54-OWzJ2xvSCo+kNnNM+3Ao_nyLHYqsktXWG2DGkWXQ@mail.gmail.com \
    --to=raphael.cohn@stormmq.com \
    --cc=dev@dpdk.org \
    /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).