On 2 May 2011 12:20, Tomasz Czapiewski <[email protected]> wrote: > On Mon, 2 May 2011, Chris Rees wrote: > >> On 2 May 2011 07:00, Tomasz Czapiewski <[email protected]> wrote: >>> >>> This make some problems with my scripts portability. >>> None of BusyBox 'sed' applet parameters, like '-r' help to solve it. >> >> That's because it's a GNUism; BSD sed doesn't accept this either. >> >> GNU sed is not 'real sed', there is no 'real sed'. >> >> What are you trying to do? >> > > Sorry about naming.
You're not the only one ;) > I've get used to GNU tools and I'm comparing commands to GNU alternatives as > I'm making and testing scripts on Linux. > I've worked around the current code so it's not a problem for this script > for now but I wanted to avoid simmilar problems in future. > The script makes changes to xml files for binary app which uses carriage > return in XML like on Windows. You could always try using awk; it's more powerful and more likely to support things. Sed is usually a can of worms portability-wise; see some previous commits to the BusyBox build scripts. Maybe you should have a look at [1]. > So the target of BusyBox tools is to aim BSD compatibility, no GNU? It's more about POSIX than BSD; the target of BusyBox tools is to remain small for embedded systems; including every bloated option that GNU does would defeat that object. > Regards, > Tomasz Czapiewski > [1] http://linux.dsplabs.com.au/rmnl-remove-new-line-characters-tr-awk-perl-sed-c-cpp-bash-python-xargs-ghc-ghci-haskell-sam-ssam-p65/ _______________________________________________ busybox mailing list [email protected] http://lists.busybox.net/mailman/listinfo/busybox
