Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 7 Jun 2017 10:54:23 +0200
From:      Willem Jan Withagen <wjw@digiware.nl>
To:        blubee blubeeme <gurenchan@gmail.com>, Jov <amutu@amutu.com>
Cc:        FreeBSD current <freebsd-current@freebsd.org>
Subject:   Re: [sed] command failure? Porting a project to FreeBSD
Message-ID:  <c84aeadd-70e5-32bf-8449-e174e3285590@digiware.nl>
In-Reply-To: <CALM2mE=Xa6R2q5%2BxPn7D5ttrcn0KBYnBOSYiE-1bnaZZb3j4fA@mail.gmail.com>
References:  <CALM2mEkC3fS5AXY6pvk1xzmxrhK-PE4_eVBBAL0jqqFNKPjDKw@mail.gmail.com> <CADyrUxOH2hCv60TxwycJsNJ9yikkz3pYQYPiozdkw7i=j%2BSPRw@mail.gmail.com> <CALM2mE=Xa6R2q5%2BxPn7D5ttrcn0KBYnBOSYiE-1bnaZZb3j4fA@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On 07/06/2017 09:40, blubee blubeeme wrote:
> Ahhh, that was it. Doing a find and ask to replace all instances of sed
> with gsed passed that part.
> 
> By the way, is knowledge like this written down somewhere centralized or is
> it just floating in the ether?

>From my experience of porting Ceph....
(And I agree with HPS, that if it looks a like, it does not have to be
the same.)

Most of these thing you have to find out on your own. But that is also
the fun of porting: issue arise from the strangest of corners.
Regular expression are among the most notorious, some of the Linux tools
also use Perl REs. Something the basic FreeeBSD will not do, since it
requires pulling Perl into base.

So for most of the tools, there is also a GNU equivalent, so that is
usually the first thing to look at.

Even more tricky are the tools you can install, but hat the same name as
their base counterpart. Like getopt, where the packaged one understands
a completely different set of options.
Not sure if you will be running into bash, but that ends up in
/usr/local/bin, whilest just about every script expects /bin/sh to be bash.

Even things like /usr/bin/env do not work the same way, and or have the
same parameters. So even there it does not always help.

--WjW




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?c84aeadd-70e5-32bf-8449-e174e3285590>