maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Maemo 5 / Fremantle (https://talk.maemo.org/forumdisplay.php?f=40)
-   -   [Announce] Enhanced BusyBox package (https://talk.maemo.org/showthread.php?t=72801)

iDont 2011-05-05 14:39

[Announce] Enhanced BusyBox package
 
Busybox-power provides an enhanced shell replacement for Maemo. It is built using the latest upstream release, rather than the old source used by default in Maemo.

All patches that Nokia included in Maemo's original BusyBox are reviewed. Newer versions of Nokia's patches are pulled from Debian Sid, while original patches are ported to this latest BusyBox release when they were missing from upstream. Maemo's configuration file for BusyBox has also been checked and updated against the default config from the new BusyBox release.

The result is a drop-in enhanced replacement for Maemo's BusyBox without losing any patched in functionality :)

This thread covers busybox-power for Diablo and Fremantle (N800/N810/N900). If you're looking for the Harmattan version (N9/N950), please refer to this thread instead.

Functionality included
This package wouldn't be called busybox-power if it didn't have extra functionality. The BusyBox binary in the package has been compiled with support for way more features and utilities than the stock busybox. Besides extra features like swap priority support in swapon, colored ls output and getopts support, the following extra utilities are included in addition to those which are also in the stock BusyBox shell:

bunzip2 bzcat bzip2 cpio cttyhack dnsdomainname dumpkmap ed fbset fdflush hush ip ipaddr iplink iproute iprule mountpoint mt nc pipe_progress popmaildir pscan usleep blockdev bootchartd crond fdisk ifenslave ip iptunnel klogd loadkmap logread makedevs mdev nbd-client raidautorun setconsole sulogin sysctl syslogd vconfig adjtimex arping base64 beep brctl cal catv chpst chrt crontab cryptpw dc devmem diff dos2unix dumpleases eject envdir envuidgid ether-wake fdformat fgconsole flock freeramdisk ftpget ftpput hexdump ionice iostat ipcalc last length less linux32 linux64 loadfont lpd lpq lpr lzcat lzma lzop lzopcat makemime man microcom mkpasswd mpstat nmeter patch pmap readahead reformime resize rev rpm rpm2cpio rtcwake runsv runsvdir rx script scriptreplay setarch setfont setuidgid showkey smemcap softlimit strings sv svlogd tcpsvd telnet tftp timeout traceroute traceroute6 ttysize udhcpc udpsvd unix2dos unlzma unlzop unxz unzip uudecode uuencode vlock volname wall xz xzcat ar acpid add-shell addgroup adduser arp chat delgroup deluser dhcprelay dnsd fakeidentd ftpd hdparm httpd ifplugd inetd lspci ntpd rdate rdev readprofile remove-shell sendmail sha256sum sha512sum telnetd tftpd tunctl udhcpd watchdog zcip whois pstree pwdx groups users setserial nameif ubirsvol sha3sum


There is a screenshot a little bit further down this post which shows all utilities (functions) included in busybox-power.

Other highlights include: Ctrl-R reverse history search, proper shell history handling, Maemo-specific bug fixes and more.
Lastly, busybox-power pulls in over three years of upstream BusyBox work!

Where to download
You can find busybox-power in Maemo's extras(-devel/testing) repository for Fremantle and extras-devel for Diablo. It is listed in the category "utilities" as "Enhanced BusyBox shell". You can also install it via the terminal by executing
Code:

apt-get install busybox-power
A standalone compiled binary (for Fremantle) is available here, for those interested in this.

Warning
This package replaces an essential system binary during installation, namely /bin/busybox. BusyBox has an essential (or better: critical) role in Maemo. This warning will also be given during installation of busybox-power. We have to take this approach, since Nokia decided to create a metapackage, which depends on specific versions of most system packages, unfortunately.

This warning aside, there have been no critical issues so far. A lot of work has been put into busybox-power to minimize the chance of messing stuff up, e.g. by testing intensively, creating md5 hashes during installation, and implementing checks for as much variables as possible. Busybox-power has been installed >250000 times (source) without any confirmed incidents I'm aware of.

About this package
My original intention was to simply provide an updated BusyBox shell; the stock one in Maemo is getting rather old (about 3 years to be precise). After working on Nokia's patches and making sure the new configuration didn't break anything, it was ready to be released. After releasing it, there were requests for an enhanced build with extra features enabled, so I made a separate release for that build. I found myself to be using that build too instead of the package I started out with.

Then it struck me that there was no real reason to maintain both an 'only updated' version and an enhanced version, as the 'only updated' one also had enhancements (brought in by the updated upstream sources). Maintaining two different versions would only fragment shell use in Maemo and had no real purpose. Therefore I started to polish and package up the enhanced binary for a wider audience, and busybox-power was born :)

The name is chosen as a parody on kernel-power, which basically does the same thing for Maemo's kernel (providing extra features, bugfixes, etcetera).

Screenshots
http://s15.postimg.org/i60avigqz/Scr...818_124519.png

http://s16.postimg.org/q7ubqqzx1/Scr...818_124712.png

iDont 2011-05-05 14:40

Enhanced BusyBox binary
 
Development, bugtracking and news
Since 07-05-2011, busybox-power has its own Maemo garage page. This page contains various topics regarding the development of busybox-power. It also contains a proper bugtracker. Head over to it for everything related to development.

Busybox-power's garage page
The project's changelog can be found here

carlon 2011-05-05 15:13

Re: [Announce] Updated BusyBox packages
 
Just install and currently testing, looks good so far, good work

vi_ 2011-05-05 15:19

Re: [Announce] Updated BusyBox packages
 
This is great.

Does discussion about an enhanced busybox installer script go here or in the previous thread?

If so...

run as root:
Quote:

#!/bin/sh
#create dirs
mkdir /home/bb
cd /home/bb
#get binary
wget http://enhanced_binary
#double check permissions
chmod +x ./busybox
#copy to bin
cp /home/bb/busybox /bin
#create symlinks in temp dir
/bin/busybox --install -s /home/bb/
#here comes the pain
yes n | cp -P -r -i /home/bb/* /bin
#punch it chewie!
cd ~
#remove temp dir of crap
rm -r /home/bb/*
DO NOT RUN THIS SCRIPT! It is just an idea.

I think the cp is set to copy the symlinks and not the source however I am not sure...

iDont 2011-05-05 15:32

Re: [Announce] Updated BusyBox packages
 
Quote:

Originally Posted by vi_ (Post 1000663)
Does discussion about an enhanced busybox installer script go here or in the previous thread?

I think it would be best to PM any suggestions.
However, I think it won't be too much of a problem to create a script; it will just take a little while to be absolutely sure it won't mess anything up ;).

Mentalist Traceur 2011-05-05 19:07

Re: [Announce] Updated BusyBox packages
 
Seems to me that the much easier solution if you're just copying the symlinks out anyway is to just package them all in the same tar file, preserving the file paths, and then from the installer script, just install the .tar.gz to /tmp/* and then unpack to /. However, it's probably better to just have an if/then check for each one. If [file where the symlink would go] doesn't exist, then symlink to /bin/busybox.

That makes it less likely to override existing full binaries, and/or symlinks to a different binary. Bit more annoying to write the script, but hey, this is why copy+paste was invented.

- Edit -

Anyone using the enhanced busybox use Advanced Interface Switcher? I think the enhanced busybox, combined with the way the Advanced Interface Switcher runs it's unload scripts, makes the Advanced Interface Switcher unable to unload the wifi driver while connected to a network.

Unlike the DNS thing I'm not as sure at this point what is happening. I think I might have had the same effect with the original not-your busybox package offered in the previous thread. Sadly I don't fully understand how the Advanced Interface Switcher package does the running of it's shell scripts, it also barely effects anyone else I suspect - the stock Advanced Interface Switcher scripts first brings down the wlan0 interface, and is meant for the stock driver. Mine skips the interface bringing down step, and uses the injection capable drivers... I'll test more as I can.

- Edit 2 -

Ok, near as I can tell, it's some deeper adv. int. switcher issue - still linked to the inhanced busybox, but not only can root easily rmmod the driver when it's in use, but if tricked into unloading the driver, when it's already connected, on the load script (Adv. Int. Switch. seems to assume the wifi driver is unloaded when it's initially started upon a restart of hildon-status-menu when you're already connected, so you can run its load script through its UI even with wifi pn and connected.), the switcher will still unload the driver just fine.

So my hypothesis is that something didn't work in the interface switcher before, and then started to work with the enhanced busybox - this something being some odd is-wifi-connected check. I can't wrap my mind around how that would be effected by busybox though, as the interface switcher is written in python. Will look through the code as I have time.

For all the masses though: don't worry about using the .deb files in the first post. That one has very little difference from the stock in terms of configuration, and in my testing experience it runs just fine. It's just the enhanced one that seems to hit these odd corner case bugs.(I'm still not 100% sure it's the busybox's fault either yet. Just think that's likely.)

Mentalist Traceur 2011-05-06 04:21

Re: [Announce] Updated BusyBox packages
 
Bump out of sheer conviction that there's no good reason for this thread to sink.

- Edit -

I found an issue with both busyboxes in this thread, the updated and updated enhanced - different character support is lacking. Namely, I cannot get characters like €, ≠, ≤, ≥, pretty sure ∞, and the entire Russian alphabet, and quite a few other things that aren't the standard basic set of characters. Any and all of them just print question marks. I know this isn't my system because running the old busybox (I have them sitting in the /home / /opt partition for testing like this) sh works, as does using the same characters in every other program. It's just inside the new busybox shells that they break.

"Wait-a-minute", you (iDont) might say, "I made sure I used the same settings as Nokia did for character support" (my guess, I didn't actually check the config.maemo files) "- it shouldn't change." Alas, I have slightly inconvenient news - I mentioned this to a family member (who as a hobby does a bunch of Tomato router Linux firmware); turns out that as of a somewhat recent version of Busybox (1.17.something or the 1.18.somethings), the default config settings for UTF code support changed, so now you have to use different config options to get the same characters supported.

iDont 2011-05-06 08:58

Re: [Announce] Updated BusyBox packages
 
Thanks for digging into this issue! Really appreciated.
I'll look into the configuration files later today.

Update: Mentalist Traceur: You've nailed it in your posts :). I've fixed the issue in a test build. There are CONFIG_UNICODE_* entries in the BusyBox 1.18.4 configuration file, which aren't to be found in the old one. I'm now pinning down the exact configuration entry responsible and should have a final fix available later today.

On the installer: I have already a script ready which contains all functions from busybox defined on top by location (DEST_BIN="bunzip2 ..", DEST_SBIN="blkid .." ...) and some for-looping, which checks for existing symlinks/binaries before creating new symlinks. The final goal is to provide a single .deb which both provides the binary and does the symlinking.
I'm also working on an uninstaller which basically checks whether an utility is a symlink and if so, it checks whether the binary links to busybox. If not, it won't remove the symlink. This uninstaller works with the same list of functions defined as in the installer.
Still testing and extending; there mustn't be any corner cases of course!

x-lette 2011-05-06 09:26

Re: [Announce] Updated BusyBox packages
 
Great job! Will try updated version soon and really wonder at new behaviour.

Quote:

Originally Posted by iDont (Post 1000643)
Unfortunately, the packages can't be pushed into Maemo's repositories because of the mentioned metapackage, at least as far as I know. (Creative) workarounds are greatly appreciated!

Just an idea: why not generating a metapackage too?
First of all: use correct version number for updated busybox. Then your mentioned metapackage will break, therefore you'll need another metapackage providing the needed version and itself depending on your version. That should do the trick imho. I don't think there will be issues having several versions of busybox installed. They shouldn't conflict, but your package should have a slightly different name of course. Maybe you can even provide a different version string within the same package but I'm not sure. Debian archives are so powerful, I sometimes could swear they even make coffee :D

lolloo 2011-05-06 10:02

Re: [Announce] Updated BusyBox packages
 
Quote:

Originally Posted by Mentalist Traceur (Post 1001000)
Bump out of sheer conviction that there's no good reason for this thread to sink.

- program. It's just inside the new busybox shells that they break.

.

I love this guy!

iDont 2011-05-06 12:34

Re: [Announce] Updated BusyBox packages
 
Quote:

Originally Posted by Mentalist Traceur (Post 1001000)
I found an issue with both busyboxes in this thread, the updated and updated enhanced - different character support is lacking.

Fixed. I don't have any scripts that are using these special characters, so if you could verify that it's working for you too, that would be much appreciated :).

I've checked the character support by simply typing euro signs, copyright symbols, tabs, etcetera, which worked fine in the new build. I enabled just about all character support to be on the safe side (which only adds about ~5KiB anyway).

The source, the debs, the enhanced binary and the enhanced .conf file are updated on the server.

Quote:

Originally Posted by x-lette (Post 1001078)
Just an idea: why not generating a metapackage too?
First of all: use correct version number for updated busybox. Then your mentioned metapackage will break, therefore you'll need another metapackage providing the needed version and itself depending on your version. That should do the trick imho.

Unfortunately, the source of the metapackage, mp-fremantle-generic-pr, is not available. Also, I'm not sure if anyone is allowed to push a new version of it to Maemo's repositories (which will cause all Maemo users to be notified of an update I think?) or if anyone is even able to do that in the first place.
Replacing the metapackage with my own would be a solution, but I think that would break Nokia's SSU system.

The CSSU fixes this by replacing the metapackage with their own (source). That package gets rid of many specific version dependencies, so this whole thing wouldn't be a problem with the CSSU. However, not everybody has got the CSSU installed, so this is no option (or I have to make this updated BusyBox depend on the CSSU).

Quote:

Originally Posted by x-lette (Post 1001078)
I don't think there will be issues having several versions of busybox installed. They shouldn't conflict, but your package should have a slightly different name of course.

The problem with this is that only one BusyBox binary can be installed (as there is just one /bin/busybox). I either have to make my package available as an alternative shell (which invalidates the whole 'replacement' thing), or the packages would overwrite each other their binaries.

After thinking it over a lot, I think it would be best to make a package with its own name (busybox-power anyone?), which simply overwrites /bin/busybox. This way I won't have any restrictions with names, versions or dependencies and I would be able to push it into the repositories. Being able to receive updates automatically, rather than checking a thread, seems a lot more convenient for the users too. Also, official BusyBox upgrades by Nokia (if any) will overwrite my binary, so no problems there. The only downside with this approach is that overwriting other packages their binaries is a bad practise.

Quote:

Originally Posted by x-lette (Post 1001078)
Maybe you can even provide a different version string within the same package but I'm not sure. Debian archives are so powerful, I sometimes could swear they even make coffee :D

I agree :). It's a shame that Nokia made their metapackage explicitly depend on specific versions of Maemo's core packages, which kind of defeats the purpose of such a refined packaging system.

x-lette 2011-05-06 13:23

Re: [Announce] Updated BusyBox packages
 
Quote:

Originally Posted by iDont (Post 1001159)
Unfortunately, the source of the metapackage, mp-fremantle-generic-pr, is not available.

I'm not talkibng about replacing the mentioned metapackage, but creating a new one which offers the name (busybox) and the needed version string and simply depends on your package name (busybox-abcd) and probably a version string. So there would be three packages in the end:
  • the original metapackage which depends on old busybox
  • your metapackage which "provides" old busybox and
  • your updated busybox package
Quote:

.... However, not everybody has got the CSSU installed, so this is no option (or I have to make this updated BusyBox depend on the CSSU).
Please don't depend on CSSU! I'm one of the mentioned users who don't have it activated (yet). So it would be a pitty if such a great package would force me to do it now.

Quote:

The problem with this is that only one BusyBox binary can be installed (as there is just one /bin/busybox). I either have to make my package available as an alternative shell (which invalidates the whole 'replacement' thing), or the packages would overwrite each other their binaries.
You're right with that filename. but you could backup the old busybox and replace it with your new one. In case of uninstallation you could simply restore the old one again. It could be tricky to step in when original busybox should get updated but using a checksum of backed up binary and own binary and comparing it to actual binary in case of uninstallation should suffice.

Mentalist Traceur 2011-05-06 20:41

Re: [Announce] Updated BusyBox packages
 
Quote:

Originally Posted by lolloo (Post 1001088)
I love this guy!

Lol. I appreciate it.

Quote:

Originally Posted by iDont
I've checked the character support by simply typing euro signs, copyright symbols, tabs, etcetera, which worked fine in the new build. I enabled just about all character support to be on the safe side (which only adds about ~5KiB anyway).

Success! It accepted everything I threw at it:

∞, ≠, ≤, ≥, (entire russian/cyrillic alphabet) and: ∅æÆœŒ♂♀∫§¶¿¡μαπθψ№∠δß

Not like they actually see any use in scripts, to be fair - although I do sometimes use vi as a generic all-purpose text editor so it helps. For examples, I've used the proper 'micro' (μ) prefix for units in my conky configs which I edit through vi.

Your prompt tackling of issues makes me wish I could thank your original two posts more than once - one time for each new upload of fixed packages/binaries.

JohnLF 2011-05-06 22:30

Re: [Announce] Updated BusyBox packages
 
Quote:

Originally Posted by iDont (Post 1001159)
After thinking it over a lot, I think it would be best to make a package with its own name (busybox-power anyone?)

Enhanced busybox: -
busybox-power
busybox-enhanced
busybox2
busierbox ;)

Updated busybox: -
busybox-updated

(then maybe you should use busybox-updated-power etc)

mr_pingu 2011-05-08 10:37

Re: [Announce] Updated BusyBox packages
 
bug:

I changed my hostname to Mr Pingu (space included)
the old busybox used to display the whole name, after going to root via "root" (not sudo gainroot)

Code:

~ $ root


BusyBox v1.10.4 (Debian 1.10.4) built-in shell (ash)
Enter 'help' for a list of built-in commands.

 Mr Pingu:~#


This new busybox stops after Mr so it doesnt display the full hostname if a space is included in the hostname it stops after this space ;)

new:
Code:

~ $ root


BusyBox v1.18.4 (Debian 1.18.4power2) built-in shell (ash)
Enter 'help' for a list of built-in commands.

Mr:~#


note: I dont know if version match on the old , I just thought it was 1.10 so I changed to make the difference more clear

iDont 2011-05-08 13:39

Re: [Announce] Updated BusyBox packages
 
Quote:

Originally Posted by x-lette (Post 1001182)
Please don't depend on CSSU! I'm one of the mentioned users who don't have it activated (yet). So it would be a pitty if such a great package would force me to do it now.

Don't worry, this isn't my intention either.

Quote:

Originally Posted by JohnLF (Post 1001430)
Enhanced busybox: -
busybox-power
busybox-enhanced
busybox2
busierbox ;)

Updated busybox: -
busybox-updated

(then maybe you should use busybox-updated-power etc)

Thanks for the suggestions, appreciate it.
I've gone ahead with busybox-power, as that name represents the similarities in goal with kernel-power the most.

Quote:

Originally Posted by mr_pingu (Post 1002052)
bug:

I changed my hostname to Mr Pingu (space included)
the old busybox used to display the whole name
[..]
This new busybox stops after Mr so it doesnt display the full hostname if a space is included in the hostname it stops after this space ;)

Thanks for reporting, I'll look into it :)

On a side note, I want to recommend you to change the space to an underscore regardless of whether you experience a bug or not. Spaces are, at least as far as I know, pretty uncommon (and even discouraged to use) in hostnames.

iDont 2011-05-08 13:42

Re: [Announce] Enhanced BusyBox package
 
I've changed the direction for this project a little bit. I'll focus only on the enhanced package from now on. The first two posts of this thread have received a major overhaul. Please read "About this package" in the first post for some additional information.

Also, busybox-power can now be found in the repositories! A lot of work went into the install and uninstall script to make sure they behave well.
Mentalist Traceur & others: you don't have to worry about the package overwriting existing symlinks/applications. The package also keeps track of what symlinks it has installed, so it will never remove more symlinks than it has made ;)

To all who have installed an older version (both the 'only updated' and enhanced binary): I recommend to revert to Nokia's original BusyBox (by executing "apt-get install --reinstall busybox"), and to remove any manually made symlinks to /bin/busybox prior to installing busybox-power. These recommendations aren't strictly necessary, but they prevent possible double symlinks and invalidating the backup of the original BusyBox binary (as the 'original' binary isn't original then).

Radicalz38 2011-05-08 14:02

Re: [Announce] Updated BusyBox packages
 
Quote:

Originally Posted by mr_pingu (Post 1002052)
bug:

I changed my hostname to Mr Pingu (space included)
the old busybox used to display the whole name, after going to root via "root" (not sudo gainroot)

Code:

~ $ root


BusyBox v1.10.4 (Debian 1.10.4) built-in shell (ash)
Enter 'help' for a list of built-in commands.

 Mr Pingu:~#


This new busybox stops after Mr so it doesnt display the full hostname if a space is included in the hostname it stops after this space ;)

new:
Code:

~ $ root


BusyBox v1.18.4 (Debian 1.18.4power2) built-in shell (ash)
Enter 'help' for a list of built-in commands.

Mr:~#


note: I dont know if version match on the old , I just thought it was 1.10 so I changed to make the difference more clear

Hi! Please type in your hostname Mr\ Pingu instead
Somehow it's related with the added support for unicode format doing that would escape the whitespace :D

Mentalist Traceur 2011-05-09 01:49

Re: [Announce] Enhanced BusyBox package
 
Just installed. (N900 not in an environment currently where I can constantly get wifi, else I would've had this installed a while ago.)

Seems to have worked fine. I also tested this updating eSpeak AND installing this at once, so that's a little bit extra assurance that no unexpected glitches arise when doing more than one apt-get task at once. (Not that that was likely, but still.)

The commands I checked seem to have been symlinked fine, or not symlinked where appropriate. Is there any mechanism in place to make sure that if a user installs busybox-power, then installs, say, a binary for iostat or telnet (or something else that stock busybox lacked), and then uninstalls busybox-power, that the binary (or different symlink) won't get deleted by the uninstaller thinking it's deleting its own symlink?

mr_pingu 2011-05-09 05:23

Re: [Announce] Updated BusyBox packages
 
Quote:

Originally Posted by Radicalz38 (Post 1002121)
Hi! Please type in your hostname Mr\ Pingu instead
Somehow it's related with the added support for unicode format doing that would escape the whitespace :D

Doesnt work, it still stops after the "\"

Xagoln 2011-05-09 07:03

Re: [Announce] Enhanced BusyBox package
 
@mr_pingu, I thought spaces were not allowed in hostnames as per some RFC. Still, if it worked before...

And any feedback on performance/memory use of the new busybox? If busybox is used to run system startup scripts, a small change in either direction could be significant.

Radicalz38 2011-05-09 10:24

Re: [Announce] Updated BusyBox packages
 
Quote:

Originally Posted by mr_pingu (Post 1002505)
Doesnt work, it still stops after the "\"

0.o weird... I know I have done that before... Well yeah indeed hostnames shouldn't really support whitespace anyways... But having space is a great feature...

iDont 2011-05-09 11:00

Re: [Announce] Enhanced BusyBox package
 
Quote:

Originally Posted by Mentalist Traceur (Post 1002465)
The commands I checked seem to have been symlinked fine, or not symlinked where appropriate. Is there any mechanism in place to make sure that if a user installs busybox-power, then installs, say, a binary for iostat or telnet (or something else that stock busybox lacked), and then uninstalls busybox-power, that the binary (or different symlink) won't get deleted by the uninstaller thinking it's deleting its own symlink?

Yes, there actually is such a mechanism ;)

When deinstalling busybox-power, all symlinks created upon installation are checked if they still are symlinks, and if so, whether the symlink still points to /bin/busybox or not. Only if an utility passes both tests, it will get deleted upon deinstallation.

Quote:

Originally Posted by mr_pingu (Post 1002505)
Doesnt work, it still stops after the "\"

Still looking into it ;)

Quote:

Originally Posted by Xagoln (Post 1002551)
@mr_pingu, I thought spaces were not allowed in hostnames as per some RFC. Still, if it worked before...

And any feedback on performance/memory use of the new busybox? If busybox is used to run system startup scripts, a small change in either direction could be significant.

I actually thought the same, but the stock BusyBox does indeed seem to allow a hostname with a space in /etc/hostname.

Busybox-power replaces /bin/busybox with the latest upstream version (albeit with Nokia's patches and a slightly different configuration); all scripts are ran with the new binary. I don't have any numbers on performance, but I can imagine some difference as there is a ~3 years time span between Maemo's BusyBox and the latest upstream version. I don't expect too much of a difference though (either positive or negative). I'll see if I can time some operations when I get home.

Update: Some very simple checks (cat /proc/uptime > /root/uptime) in a late startup script didn't show any significant difference in performance: a 0.58% difference in uptime (all measured uptimes were in the 13.7-13.8s range, test was performed three times which both BusyBox versions). This is a very limited benchmark though; feel free to perform additional benchmarks.

iDont 2011-05-09 21:34

Re: [Announce] Enhanced BusyBox package
 
Quote:

Originally Posted by mr_pingu (Post 1002052)
bug:

I changed my hostname to Mr Pingu (space included)
the old busybox used to display the whole name
[..]
This new busybox stops after Mr so it doesnt display the full hostname if a space is included in the hostname it stops after this space ;)

This has been fixed in busybox-power 1.18.4power3.

I don't know whether it was a bug or a feature: the responsible 'code' was a simple flag (PARSE_GREEDY) passed to a function responsible for parsing files. After removing this flag, the complete hostname (including spaces) was read from files (including /etc/hostname) again.

laasonen 2011-05-09 22:21

Re: [Announce] Enhanced BusyBox package
 
Problems when there is ~ in attribute. Example:
Code:

dpkg -i fennec_6.0~a1_armel.deb
Run root while you are root and you get big help message.

Mentalist Traceur 2011-05-10 06:00

Re: [Announce] Enhanced BusyBox package
 
Quote:

Originally Posted by laasonen (Post 1003091)
Problems when there is ~ in attribute. Example:
Code:

dpkg -i fennec_6.0~a1_armel.deb
Run root while you are root and you get big help message.

Shouldn't there be a backslash before the tilde? Did you type it in manually or use auto-complete? Does the auto-complete not add a backslash before the tilde where it did with the original busybox?

iDont 2011-05-10 08:29

Re: [Announce] Enhanced BusyBox package
 
Quote:

Originally Posted by laasonen (Post 1003091)
Problems when there is ~ in attribute. Example:
Code:

dpkg -i fennec_6.0~a1_armel.deb
Run root while you are root and you get big help message.

Thanks for reporting.

However, this is not because of the ~ in the filename. You'll see the 'help' when you remove it from the filename too. This help appears because of some invalid options passed to a command ran upon both installation and deinstallation of Fennec.

A quick glance revealed the following:

Fennec uses the following command in their preinst and prerm files:
Code:

RUNNING=`ps ax | grep "fennec.*/fennec" | grep -v grep | wc -l`
The help description comes from the ps command. The old BusyBox accepted everything, even "ps dwbhfweyuwedih". The latest upstream BusyBox however does complain about invalid options. I'll have to check whether the options "ax" are supported in BusyBox. For now it seems that it simply doesn't support it, but I'll have to dig deeper into the source/web (I'm not at home right now).

Update: This seems to be a bug in Fennec's scripts. For more information, see https://bugzilla.mozilla.org/show_bug.cgi?id=656020. Let's hope it'll get fixed, as the bug is not exposed when using the default BusyBox.
I could always write a patch to make ps accept all options again if it won't get fixed. For now, I'll leave this untouched. Installation and removal of Fennec should work fine nonetheless.

anthonie 2011-05-10 08:57

Re: [Announce] Enhanced BusyBox package
 
Thanks man, this may take away the need for me to have bash3 installed! Awesome job!

Mentalist Traceur 2011-05-10 19:11

Re: [Announce] Enhanced BusyBox package
 
Does the stock busybox need to be a dependency for this package? Seems like the package itself doesn't need to be a necessity, as one can no doubt imagine a working N900 setup where stock busybox has been replaced or removed, but its' binaries have been preserved, or replacements have been moved in.

Now, yes it's unlikely, and really unreasonable for someone to do that, and frak if anyone knows why you'd even bother doing that but then wish to install busybox-power on top of it... *Shrug* But I've always been against adding dependencies that make sense "practically" but aren't actually technically necessary - is there anything that the stock busybox package provides that the busybox-power package needs to have?

iDont 2011-05-11 19:25

Re: [Announce] Enhanced BusyBox package
 
Quote:

Originally Posted by Mentalist Traceur (Post 1003608)
Does the stock busybox need to be a dependency for this package? Seems like the package itself doesn't need to be a necessity, as one can no doubt imagine a working N900 setup where stock busybox has been replaced or removed, but its' binaries have been preserved, or replacements have been moved in.

Now, yes it's unlikely, and really unreasonable for someone to do that, and frak if anyone knows why you'd even bother doing that but then wish to install busybox-power on top of it... *Shrug* But I've always been against adding dependencies that make sense "practically" but aren't actually technically necessary - is there anything that the stock busybox package provides that the busybox-power package needs to have?

Busybox-power's (un)installation script needs mkdir, ls, cp and rm, which are all provided by the package coreutils. Coreutils however is always provided by the BusyBox package on Maemo.
It would be technically correct to make busybox-power depend on coreutils instead of BusyBox. The only reason BusyBox itself is listed as a dependency is indeed because of practical reasons.

Your post made me think over busybox-power's dependencies. It seems that I've overlooked something very obvious: busybox-power contains BusyBox, so it should never ever have to depend on anything provided by BusyBox (if the (un)installation scripts are made to use the package its BusyBox instead of /bin/busybox). I'll release an update this weekend with the dependency removed ;)

spikelinux 2011-05-14 09:41

lspci
 
Exelente trabajo... finalmente una actualizacion de la BusyBox... instalado y testeado correctamente :) bueno el comando lspci me da el sig error:
lspci: /sys/bus/pci/devices: No such file or directory

Nuevamente Grax por el exelente trabajo

iDont 2011-05-14 09:54

Re: lspci
 
Quote:

Originally Posted by spikelinux (Post 1006013)
Exelente trabajo... finalmente una actualizacion de la BusyBox... instalado y testeado correctamente :) bueno el comando lspci me da el sig error:
lspci: /sys/bus/pci/devices: No such file or directory

Nuevamente Grax por el exelente trabajo

Thanks for your appreciation and report.

The N900 doesn't have a pci bus. Therefore /sys/bus/pci doesn't exist at all. Lspci will never return anything useful on the N900.
I could remove lspci from busybox-power, but I rather like to keep it for (utility) completeness' sake.

Cosmic 2011-05-14 18:28

Re: [Announce] Enhanced BusyBox package
 
Hi, guys!
Watching on emacs screen in the BusyBox and view ~1/7 of screen height is unwisely lost at the bottom:
https://lh6.googleusercontent.com/_Q...514-205137.png
Obviously what much more convenient would be to hide that bottom panel. For example after then Ctrl+L(arge) will been pushed.

Is I'm right or absolutely right :rolleyes:
But how I'm can implement this feature?!
Great thanks!

Mentalist Traceur 2011-05-14 20:51

Re: [Announce] Enhanced BusyBox package
 
What is contained within the bottom bar, and whether to bottom bar is shown at all, is controllable with Gconf settings. I don't remember which ones off the top of my head, but it shouldn't be hard to find if you search for, say, 'modifying xterm bottom bar' or whatever.

Mentalist Traceur 2011-05-15 22:39

Re: [Announce] Enhanced BusyBox package
 
I'm a bit busy at the moment (college coursework, plus breaking my N900's boot process by modifying /sbin/preinit, reflashing, and trying again to achieve the thing I'm working on that keeps resulting in this problem, so this might be taking up my time for a while), BUT:

When I'm done, I'll write up how to combine dbus-scripts and the modified hildon desktop (required - either by itself or the one from CSSU), to make it so that Shift+Ctrl+[key] or Fn+Ctrl+[Key] toggle the bar at the bottom of X-Term.

- Edit -

Well, I succeeded in doing what I was trying to do with /sbin/preinit; not only that, but what I got working depended on the busybox-power package, so it's on-topic now! (I needed to be able to use "read -n 1 -t 1", and stock busybox didn't support the -n flag on read.)

I'll post an example of how to implement keyboard-toggle-able X-Term bar tomorrow - or at least will try to get it posted tomorrow.

- Edit 2 -

In the meantime, users willing to risk modifying /sbin/preinit and/or interested in what I was so willing to get working that I was willing to spend a day breaking and reflashing by N900 may see:
http://talk.maemo.org/showthread.php...31#post1007131

Also, the post under mine is correct, that is the relevant gconf setting.

zoner 2011-05-16 02:23

Re: [Announce] Enhanced BusyBox package
 
Quote:

Originally Posted by Cosmic (Post 1006322)
Obviously what much more convenient would be to hide that bottom panel.

this may do what you want

JadeH 2011-05-16 11:18

Re: [Announce] Enhanced BusyBox package
 
Is there any way to install this without the symlinks? I use other stuff like procps and some others I forgot so I don't want busybox symlinks back

iDont 2011-05-16 13:11

Re: [Announce] Enhanced BusyBox package
 
Quote:

Originally Posted by JadeH (Post 1007330)
Is there any way to install this without the symlinks? I use other stuff like procps and some others I forgot so I don't want busybox symlinks back

Installing busybox-power will never overwrite any existing symlinks or binaries. It will only create new symlinks :)

If you still wish to install busybox-power without the symlinks: the first post contains a link to just the binary (direct link). You can safely replace /bin/busybox with the one in the tarball. Be extra careful not to mess up the binary its permissions (don't extract it to MyDocs or similar!). The binary in the tarball is the same as the one in the repositories.

Cosmic 2011-05-17 15:38

Re: [Announce] Enhanced BusyBox package
 
Quote:

Originally Posted by zoner (Post 1007071)
this may do what you want

Thanks, and that too :D
Seriosly if you'll try to determine some problem as complex there is only one way do it - just determine them complexly.
Near I'm put a winner sequence at whole:
Code:

sudo apt-get install xbindkeys wmctrl
Create a magic script in home directory:
https://lh6.googleusercontent.com/_Q...517-181823.png
Code:

#!/bin/sh                                                                                                                                                                         
                                                                                                                                                                                 
SETTING=`gconftool-2 --get \                                                                                                                                                     
        /apps/osso/xterm/toolbar`                                                                                                                                                 
                                                                                                                                                                                 
if [ $SETTING == "true" ]                                                                                                                                                         
        then NEWSETTING="false"                                                                                                                                                   
        else NEWSETTING="true"                                                                                                                                                   
fi                                                                                                                                                                               
                                                                                                                                                                                 
gconftool-2 --set --type bool \                                                                                                                                                   
        /apps/osso/xterm/toolbar \                                                                                                                                               
        $NEWSETTING

and make them executable by:
Code:

chmod a+x ./fscr
Configure xbindkeys to use that script:
https://lh3.googleusercontent.com/_Q...517-181812.png
Code:

"wmctrl -r :ACTIVE: -b toggle,fullscreen"                                                                                                                                         
control + KP_Enter                                                                                                                                                               
"/home/user/fscr"                                                                                                                                                                 
control + period

Vuala! Now you'll able to remove (restore):
  • bottom panel by Ctrl+.;
  • top panel by Ctrl+Enter
I hope this behaviaour is much more convenient then the default :rolleyes:
Exactly for Emacs ;)

Mentalist Traceur 2011-05-17 22:47

Re: [Announce] Enhanced BusyBox package
 
Good job @ Cosmic for solving his own issues. That's always applaudable. I'm guessing you won't be needing my way with dbus-scripts.

Meanwhile, I see busybox-power got a new update today. However, it does still list "busybox" as its dependency when you view it in the app manager. Was this intentional?

(Also, I'm going to be selfish and request loadkeys with the -b flag supported by added in - although, honestly, I'm making that a very tentative request, because I know if you keep adding stuff it'll just keep inflating the busybox binary, adding bloat that most people wouldn't want or need). I just cannot for the life of me find a precompiled armel binary of the loadkeys command that actually supports the -b flag.


All times are GMT. The time now is 05:33.

vBulletin® Version 3.8.8