How to use function lbb_main of the libbusybox.so to a C program
Tito
farmatito at tiscali.it
Sun May 17 17:44:16 UTC 2020
On 5/15/20 9:51 PM, Tiago Araujo da costa wrote:
> Good afternoon busybox team.
>
> Suppose the fruit.txt file has the following content
>
> $ cat fruit.txt
> watermelon
> melon
> Strawberry
> avocado
> lemon
> orange
> Apple
>
> If you run the following commands, the results generated will be:
>
> $ melon=`grep "melon" fruit.txt`
> $ echo "$melon"
> watermelon
> melon
Hi,
the result is:
echo $melon
watermelon melon
> $ echo "$melon" | sed 's /on/an/g;s/$/in/' | rev
echo "$melon" | sed 's /on/an/g;s/$/in/' | rev
sed: -e expression #1, char 18: unterminated `s' command
> ninalemretaw
> nianlem
>
> If possible, you could generating the C equivalent of the commands mentioned above,
> using the lbb_main function, of the libbusybox.so library?
>
This would be rather convoluted and impractical, better write a little
C program or a shell script.
Ciao,
Tito
More information about the busybox
mailing list