On Wed, Dec 2, 2009 at 12:56 PM, Marius Vollmer
<marius.voll...@nokia.com> wrote:
> ext Anderson Lizardo <anderson.liza...@openbossa.org> writes:
>
>> If you have plans to begin enabling auto-optification by default,
>> please inform us here on the list so we can begin adding the
>> debian/optify file to avoid optifying packages that were manually
>> optified  by other means (e.g. python packages).
>
> If a package already contains a /opt directory, no further optification
> is done by the maemo-optify tools in any case.  Is that enough to
> protect you?

No, because the optification was done by creating a "pymaemo-optify"
package which bind mounts the relevant Python directories from
/usr/... to /opt/pymaemo. These mounts are done during device boot by
/etc/init.d/pymaemo-optify (they are not mounted inside scratchbox, of
course).

This means that there is no change required for python packages to
become optified, they just need to depend on python.

> We can put additional checks into maemo-optify to disable optification.
> I don't know enough about Python packages to suggest a good one, but
> maybe just looking for /usr/lib/py* in a package and stopping to do
> anything would work.

Actually the list of directories handled by pymaemo-optify is variable
(but not expected to change). They are defined in
/etc/default/pymaemo-optify and currently is:

/usr/lib/python2.5
/usr/share/pyshared
/usr/lib/pyshared
/usr/share/python-support
/usr/lib/python-support

One idea might be to check whether this file exists and ignore any
packages which install files to the directories listed on the
"BIND_MOUNTS" directory (note that this file is a snippet of shell
script read by /etc/init.d/pymaemo-optify).

Or you can hard code this list somewhere, and you will get at least
most Python packages ignored. As with every heuristics, we can't get
100% of cases, and others will need to have to be manually opted-out.

My two cents,
--
Anderson Lizardo
OpenBossa Labs - INdT
Manaus - Brazil
_______________________________________________
maemo-developers mailing list
maemo-developers@maemo.org
https://lists.maemo.org/mailman/listinfo/maemo-developers

Reply via email to