Thanks Jean-Noël and Michael for your answers.

I was looking at the current code of ptxdist (actually, I have the 2011.01.0 
code) and I saw that the code has changed a lot from the 1.* version.

I already found that the {pre,post}{inst,rm} scripts calls are actually well 
handled by adding some files in the rules directory.

For the conffile thing in the pkg control directory, I think the best is 
effectively to follow the same architecture than install_alternative 
(install_conf_alternative for the name?).

When an ipkg get installed or updated, the preinst script should be called 
differently.
Case of a fresh installation: preinst install version
Case of an upgrade: preinst upgrade oldversion

http://buffalo.nas-central.org/wiki/Construct_ipkg_packages_(for_developers)#Things_common_to_all_CONTROL_Scripts

The installation scripts could find the CONTROL directory and conffiles file.

In case the configuration file has changed, it will ask for the user to make a 
decision (as dpkg does): keep the old, take the new, show diff
With the -force-defaults option to ipkg, the old conf is kept without asking.

Regards,

Ben

-----Message d'origine-----
De : [email protected] [mailto:[email protected]] De 
la part de Michael Olbrich
Envoyé : mardi 1 mars 2011 12:50
À : [email protected]
Objet : Re: [ptxdist] Configuration files management

What's the exact handling of config files? What happen on update
(with/without modified config files)? How are modifications detected?

Regards,
Michael Olbrich

--
Pengutronix e.K.                           |                             |
Industrial Linux Solutions                 | http://www.pengutronix.de/  |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0    |
Amtsgericht Hildesheim, HRA 2686           | Fax:   +49-5121-206917-5555 |

--
ptxdist mailing list
[email protected]

-- 
ptxdist mailing list
[email protected]

Reply via email to