maemo.org - Talk

maemo.org - Talk (https://talk.maemo.org/index.php)
-   Nokia N900 (https://talk.maemo.org/forumdisplay.php?f=44)
-   -   [FREE-mantle] Running Maemo5 on N900 without closed source graphics driver (https://talk.maemo.org/showthread.php?t=83442)

AapoRantalainen 2012-04-04 09:10

[FREE-mantle] Running Maemo5 on N900 without closed source graphics driver
 
This thread belongs context of FREE-mantle http://wiki.maemo.org/FREE-mantle
So in this thread do not ask 'why'. Ask (/answer) 'how/who/when' instead.

I made first testing how to run Mamo5 on N900 without closed source gles1 or gles2 (uninstalled both!).

I got it working. Desktop is very slow, but as you get some application running, it is normal speed (expect every dialogs are slow). Going to dashboard is slow. Slow means 5 seconds for any action.

Even there are packages to download and guide to use them: This is not really meant to be used, it is just first test.

Beware messing with hildon-desktop can trigger watchdog to reboot your phone (and can cause reboot loop).


Step 0
I tested this with starting flashing this
RX-51_2009SE_20.2010.36-2_PR_COMBINED_MR0_ARM.bin

#upgrade to the PR.1.3.1
#not necessarily, but just showing my setup with every detail
apt-get update
apt-get upgrade

#I installed these:
apt-get install openssh-server wget

#Step 1
#Download xserver-xomap package and install it
wget http://cc.oulu.fi/~rantalai/maemo/fr...+0m5_armel.deb
dpkg -i xserver-xomap_1.6.99.1-0osso20090208.108\+0m5_armel.deb


#Step 2
#Install software GL
#it installs also libosmesa6
apt-get install libgl1-mesa-swx11


#Step 3
#Download and install libclutter, which is compiled against GL, not GLES
wget http://cc.oulu.fi/~rantalai/maemo/fr...+0m5_armel.deb
dpkg -i libclutter-0.8-0_0.8.2-0maemo66\+0m5_armel.deb

#IMPORTANT!
#create symlink
#This is for hildon-desktop (it is looking clutter in old name)
#Alternative way is to rebuilt hildon-desktop (clutter-glx installed)
ln -s libclutter-glx-0.8.so.0.800.2 /usr/lib/libclutter-eglx-0.8.so.0

#Step 4
#Remove gles2
#It will remove these: libgles2-sgx-img libqt4-declarative libqt4-gui libqt4-maemo5 libqt4-multimedia libqt4-opengl libqt4-phonon libqt4-svg libqt4-webkit libqtm-bearer libqtm-contacts libqtm-messaging libqtm-multimedia libqtm-sensors libqtm-serviceframework libqtm-systeminfo libqtm-versit mp-fremantle-generic-pr qtm-maemo-metapackage

apt-get remove libgles2-sgx-img

#Step 5
reboot

-----

For developer:

#Step 1
#Rebuild xserver-xomap
apt-get source xserver-xomap
debian/control:
Package: xserver-xomap (it is metapackage)
Remove dependencies: opengles-sgx-img-common, libgles2-sgx-img
dpkg-buildpackage

#Step 2
#Rebuild libclutter
#You really need version clutter_0.8.2-0maemo66+0m5, if it downloads clutter-1.0, use http://maemo.org/packages/view/libclutter-0.8-0/

apt-get source libclutter-0.8-0
change debian/rules --with-flavour=glx

#Fix issue of matchbox
clutter/glx/clutter-glx-texture-pixmap.c:722
+ClutterActor * clutter_eglx_texture_pixmap_new (void)
+{
+ return clutter_glx_texture_pixmap_new();
+}

debian/control
drop gles on dependency
dpkg-buildpackage

#Step3
#Testing new hildon-desktop on phone
flasher-3.5 --set-rd-flags=no-lifeguard-reset

#If you have no-lifeguard-reset you can kill hildon-desktop
as root
Code:

killall hildon-desktop ; /etc/osso-af-init/launch-wrapper.sh stop hildon-desktop /usr/bin/hildon-desktop
killall hildon-desktop ; /etc/osso-af-init/launch-wrapper.sh stop hildon-desktop /usr/bin/hildon-desktop
killall hildon-desktop ; /etc/osso-af-init/launch-wrapper.sh stop hildon-desktop /usr/bin/hildon-desktop
killall hildon-desktop ; /etc/osso-af-init/launch-wrapper.sh stop hildon-desktop /usr/bin/hildon-desktop
killall hildon-desktop ; /etc/osso-af-init/launch-wrapper.sh stop hildon-desktop /usr/bin/hildon-desktop

#And then start own version
(as user)
Code:

maemo-invoker ~/hildon-desktop.launch
-------
Next we need hildon-desktop which is not using gl/gles (means clutter).
Possible way to continue:
a) fork hildon-desktop
https://gitorious.org/community-ssu/hildon-desktop It is now part of CSSU and it is still developed, so forking would not be very wise.

b) fork clutter-0.8 and add option to not use gl/gles at all
This would be hard, because clutter is actually 'only' wrapper for openGL(ES).

c) create libfakeclutter
(clutter might be good starting point)
Library which is using some supported GUI-toolkit (QT/gtk/FLTK/X) but has function names clutter_actor_set_width and so on (only these needed what hildon-desktop is using).

freemangordon 2012-04-04 09:23

Re: [FREE-mantle] Running Maemo5 on N900 without closed source graphics driver
 
Wow, great, but why should we get rid of gles acceleration? no matter what toolkit we are using, it will always be slower that HW accelerated graphics. Or not? Actually it seems that on n900 Qt raster engine is faster than gles engine. At least for UI tasks. Might be wrong though.

Isn't it better to use newer GLES binaries from TI? Or the RE drivers you were talking about on a different thread?

AapoRantalainen 2012-04-04 09:41

Re: [FREE-mantle] Running Maemo5 on N900 without closed source graphics driver
 
Quote:

Originally Posted by freemangordon (Post 1187847)
no matter what toolkit we are using, it will always be slower that HW accelerated graphics. Or not?

If drawing is not intensive, it doesn't matter is it hw or sw. I think games are drawing intensive, but desktop should not be. Now there are some cool blur effects and so on, but maybe they are not necessary.

Truly speaking, it is also possible that GPU is using less power (battery) than CPU when calculating graphics.

Quote:

Originally Posted by freemangordon (Post 1187847)
Or the RE drivers you were talking about on a different thread?

This software-GL -thing might be only minor step for helping to make RE-drivers (only one application at a time using acceleration). Or is it possible that there will not be open source drivers (near future or ever).

imo 2012-04-04 09:51

Re: [FREE-mantle] Running Maemo5 on N900 without closed source graphics driver
 
something highly alarmingly awesome...great job .

anthonie 2012-04-04 10:00

Re: [FREE-mantle] Running Maemo5 on N900 without closed source graphics driver
 
I was just reading the wiki page on it, linked it to a friend on Skype with the words; "Ah, pro'lly an enthousiast that'll disappear any moment" and here you are to prove me wrong!

I have a second n900 at hand, that can be used to test so I'll follow this project closely.

Thanks.

Hurrian 2012-04-04 10:43

Re: [FREE-mantle] Running Maemo5 on N900 without closed source graphics driver
 
It's good to see that people are starting to unbind Fremantle from the closed Nokia bits.

Once that's done, perhaps we can start upgrading system components, and once that's done, the open SGX driver would probably be finished ;)

szopin 2012-04-04 21:29

Re: [FREE-mantle] Running Maemo5 on N900 without closed source graphics driver
 
Just one quick question: is nemo using proprietary blobs? It works quite impressively fast. If they somehow skipped closed-source HW acceleration I see no reason why any action on hildon-desktop would take 5 seconds per action on soft.
Impressive work Aapo, pls keep it up.

freemangordon 2012-04-04 21:40

Re: [FREE-mantle] Running Maemo5 on N900 without closed source graphics driver
 
Quote:

Originally Posted by szopin (Post 1188139)
Just one quick question: is nemo using proprietary blobs? It works quite impressively fast. If they somehow skipped closed-source HW acceleration I see no reason why any action on hildon-desktop would take 5 seconds per action on soft.
Impressive work Aapo, pls keep it up.

AFAIK they use newer version of the same driver(1.4 vs 1.3), probably same or similar version as in Harmattan, didn't check it though.


All times are GMT. The time now is 22:42.

vBulletin® Version 3.8.8