Fwd: [Bug 4137] New: ipkg: pre/post control files not removed ( remove_obsolete_maintainer_scripts)
Marcin Juszkiewicz
openembedded at haerwu.biz
Thu Apr 3 10:26:49 CEST 2008
Would be nice to check does it happen in opkg too.
---------- Przekazana wiadomość ----------
Subject: [Bug 4137] New: ipkg: pre/post control files not removed (
remove_obsolete_maintainer_scripts)
Date: Sunday 30 of March 2008
From: bugzilla-daemon at treke.net
To: openembedded-issues at lists.openembedded.org
http://bugs.openembedded.net/show_bug.cgi?id=4137
Summary: ipkg: pre/post control files not removed
(remove_obsolete_maintainer_scripts)
Product: Openembedded
Version: Angstrom unstable
Platform: Other
OS/Version: Linux
Status: NEW
Severity: normal
Priority: P2
Component: Distributions
AssignedTo: openembedded-issues at lists.openembedded.org
ReportedBy: pieterg at gmx.com
When a package is replaced by a newer version, the old version has a
postinst
task, which is no longer there in the new version, the postinst script is
not
removed after the update.
So this postinst script will be executed after each consecutive update of
the
package (this might actually break the functionality of the new package,
depending on the contents of the control files)
This occurs with all 0.99 versions of ipkg, up to 0.99-163-r8
I believe this code is supposed to deal with removal of control files, in
ipkg_install.c:
[code]
static int remove_obsolete_maintainer_scripts(ipkg_conf_t *conf, pkg_t
*pkg,
pkg_t *old_pkg)
{
int i;
int err = 0;
char *globpattern;
glob_t globbuf;
if (0) {
if (!pkg->dest) {
ipkg_message(conf, IPKG_ERROR, "%s: no dest for
package %s\n",
__FUNCTION__, pkg->name
return -1;
}
sprintf_alloc(&globpattern, "%s/%s.*", pkg->dest->info_dir,
pkg->name);
err = glob(globpattern, 0, NULL, &globbuf);
free(globpattern);
if (err) {
return err;
}
/* XXXX this should perhaps only remove the ones that are not
overwritten in new package.
for (i = 0; i < globbuf.gl_pathc; i++) {
ipkg_message(conf, IPKG_DEBUG, "Removing control file %s
from
old_pkg %s\n",
globbuf.gl_pathv[i], old_pkg->name);
if (!conf->noaction)
unlink(globbuf.gl_pathv[i]);
}
globfree(&globbuf);
}
return err;
}
[/code]
I suppose this code had some undesired sideeffects, and has been if 0'ed
ever
since.
--
Configure bugmail: http://bugs.openembedded.net/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
_______________________________________________
Openembedded-issues mailing list
Openembedded-issues at lists.openembedded.org
http://lists.linuxtogo.org/cgi-bin/mailman/listinfo/openembedded-issues
-------------------------------------------------------
--
JID: hrw-jabber.org
OpenEmbedded developer/consultant
Problemy z matematyką? Zadzwoń! 0-800-[(10x)(13i)^2]-[sin(xy)/2.362x]
More information about the opkg-devel
mailing list