2011/3/25 Robert Luberda <rob...@debian.org>:
> Agustin Martin writes:
>> dpkg seems to not wait for iportuguese configuration before running
>> dictionaries-common triggers. That is the same problem you found. And is in
>> that trigger where problem appears. Either I am missing something about
>> triggers or this is not at all the expected behavior. Will look again at
>> trigers document.
>
> It seems dictionaries-common.postinst activates the triggers during
> configure (the `Calling' lines generated by an ad-hoc
> /usr/local/bin/dpkg-trigger script)
..
> So at this stage dictionaries-common is in a `triggers-pending' state so
> dpkg calls `postinst triggered' to switch the state to `installed', so
> the package could satisfy ispell & ispell dictionaries dependencies:

Thanks for the debugging. As expected, the problem was a basic
misunderstanding at my side about how triggers work

>>> Maybe the compat file creation should be moved to preinst? Augustin,
>>> what do you think about it?
>>
>> If there is no other possibility I am afraid I should try that. That will
>> however make dpkg-reconfigure not rebuild the hash. May be puttng that
>> in both places may help, but that may trigger building twice unless I check
>> for reconfigure in postinst. But I do not understand why current
>> setup is being problematic.
>
> I've just came up with about other possible solutions:
> - create the empty hash file in preinst (if the file doesn't exist)
> - overwrite the compat file in debconf's config script (in addition to
> preinst, instead of postinst) - I can see ingerman does this
> - don't fail when link target doesn't and auto-hash is set for the
> dictionary.

The call from dictionaries-common postinst is only to deal with
possible changes in jed/emacs/squirrelmail handling of options, no
need to set symlinks there.

There is currently an unused --ignore-symlinks option to
update-default-*. That was initially designed for removal scripts and
there is now a better system, but the concept may be of help here,
although renamed and improved. I am thinking about calling
update-default-* from dictionaries-common.postinst with something like

update-default-ispell --dico-postinst

resulting in a real run, not enabling trigger and skipping symlinks
step. autobuildhash step could also be skipped, although it is
harmless. So, triggers are enabled only from dictionaries or ispell
(this last enables only ispell-autobuildhash).

Last week I was doing some changes in that script, so is probably time
to integrate everything. But I do not have changes here. Hope to have
everything put together on Monday.

Hope this is enough (Cross fingers).

>> By the way, I will soon upload a dictionaries-common package with a minor
>> change, enabling  -huge and -insane for initial default selection.
>
> Thanks a lot.

Noticed when trying to debug this problem, so thanks to all you that
contributed.

-- 
Agustin



-- 
To UNSUBSCRIBE, email to debian-bugs-rc-requ...@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmas...@lists.debian.org

Reply via email to