Symbiatch - maailma on rikki

N810 järkevämmäksi / More Sense to N810

21.01.2008 18.18 - mobiili 

Olen tässä yrittänyt saada N810:aa vähän fiksummaksi, eli enemmän "standardinmukaiseksi" Linuxiksi ja turhia paketteja pois. Tämä onkin vähän vaikeampi homma kun systeemin paketit on tehty tyhmästi. Esimerkiksi busybox on niin vaadittu vähän liikaa ja kaikki mahdolliset lokalisoinnit ja muut roskat on pakotettuja. Ei oikein minulle mieluista.

Busyboxin poistaminen onnistui jopa puukottamalla. Mutta ei se helppoa ollut. Tilalle täytyy asentaa bash, coreutils, procps, netbase jne. Mutta tämä pelkästään ei riitä koska busybox poistetaan ensin jolloin kaikki peruskomennot katoavat. Eli pitää ensin purkaa coreutils ja muut sopivaan paikkaan ja laittaa polut kuntoon (dpkg -x paketti /polku).

coreutils, grep, textutils jne vaativatkin sitten libsepollia ja libselinuxia ja vaikka mitä. Ja näitä ei tietenkään löydy repositorysta. Vaan ne pitää hakea Debianin pakettivalikoimasta. Grr.

Lopulta kun sain nuo paketit sisään (kolmannella yrittämällä, kaksi ensimmäistä kertaa päättyi siihen että laite ei enää toimi ja piti flashata uudelleen) alkoi homma toimia vähän paremmin. Niin ja se syy miksi nuo halusin? Koska haluan että sed, find jne toimivat kuten normaalisti, ei siten kuin busyboxin tekijät ovat päättäneet ne toteuttaa.

Seuraava homma olikin tutkia miksi systeemi vie hitosti muistitilaa. Yllättäen firmwaressa tulee kaikki mahdolliset lokalisoinnit ja näitähän ei voi poistaa paketinhallinnasta koska vaatimukset ovat typerät. Softa X vaatii X-l10n-mr0:n joka vaatii kaikki lokalisoinnit. Urghs. No, ei muuta kuin rm -r /usr/share/locale/[a-df-z]* kehiin ja tuli tulaa 15 megaa lisää.

Sitten vilkaistaankin pre-installed-* -paketit. Hienoa, kymmeniä megoja tungettu taustakuviin, videoon ja pariin biisiin. Eikun pois.

Sitten poistetaankin gizmon ja skypen installeripaketit. Ärsyttää kun pitää tunkea moisia sisään ja estää niiden poisto ilman että menet red pill -moodiin (tai rootiksi komentoriviltä). Kai siellä on raha sopivasti liikkunut tai jotain.

Sitten tarvitaan psql että voin tonkia kantoja vehkeellä. Yllättäen taas melkein kaikki paketit löytyvät, mutta postgresql-common puuttuu. Onneksi Debianin paketti meni heittämällä sisään ja sitten toimi.

Tahtoo mountata SMB-jakoja. Ei, ei löydy vakiona paketteja (ja tiedostonhallinta ei toimi järkevästi). Eikun kääntämään itse todella ärsyttävän hankalalla scratchboxilla jotain että saa aikaiseksi.

Eli kauhealla tappelemalla sai N810:sta jotenkuten järkevämmän. Eikä ole vielä tappelu ohi. Paljon tavaraa uupuu mitä tuonne tarvitsisin. Mutta ehkä sitä pitää itse sitten kääntää koko Debianin repository että saa mitä haluaa.

I've been trying to get the N810 to be a bit smarter, meaning more "standard" Linux and remove unnecessary packaged. This isn't as easy as you'd think since the packages have been done in a stupid way. For example, busybox is too much needed and all possible localizations and other crap are forced. Not the way I'd like it.

Removing busybox required some hacking. But it wasn't easy. You have to install bash, coreutils, procps, netbase etc. And this isn't enough since busybox is removed first and after that there are no basic commands available. So first you need to extract coreutils and others somewhere and set paths correctly (dpkg -x packet /path).

coreutils, grep, textutils etc require libsepol and libselinux. And these aren't in the normal repository. You have to get them from Debian's repository. Grr.

Finally I got those packages installed (third try, the two others ended with the device nonfunctional and a re-flash was needed) everything worked better. Oh, and why did I want to do this? Because I want sed, find etc to work as they work everywhere, not like the busybox people have decided to make them work.

Next thing was to determine why the system takes a lot of memory. Surprise, the firmware contains all imaginable localizations and they can't be removed cleanly with the package manager since the requirements are idiotic. Application X requires X-l10n-mr0 which requires all localizations. Grrg! Oh well, rm -r /usr/share/locale/[a-df-z]* to the rescue and 15 more megs of space available.

Then to check the pre-installed-* packages. Great. Tens of megs of background pics, a video and some tunes. Removed.

Then to remove the installer packages for gizmo and skype. Annoying that that kind of stuff is installed and you can't remove them unless you're in red pill mode or as root in command line. Money changing hands nicely or something?

Then I needed psql so that I can check my databases with the device. Surprise, almost all packages are available, but postgresql-common is missing. Fortunately Debian's version installed without problems.

So, I want to mount SMB shares. No, by default you can't (and the file manager doesn't work as it should). So, off to build my own packages in the horribly complicated scratchbox.

After all this fighting I got the N810 to be a bit more sensible. But it's not over yet, lots of stuff missing. But maybe I should just compile the whole Debian repository to get what I want.

Kommentoi

Kommentit

Jutut.fi  |  Omat jutut  |  Muiden jutut  |  Kategoriat  |  kirjaudu