On 11/10/2014 18:55, Beeblebrox wrote: > I'm getting several errors during "pkg upgrade" on pkg 1.3.8 > > At fist I thought this was a port error, because "pkg upgrade" actually > breaks on this: > "Installing linux-c6-hicolor-icon-theme-0.5: 0% > pkg: archive_read_extract(): Can't replace existing directory with > non-directory" > > But then I noticed many octave-related ports had given install errors: > "load-octave-pkg: octave is installing ad-1.0.6.tar.gz. > 'dispatch' undefined near line 2 column 1 > error: called from '/usr/local/share/octave/packages/ad-1.0.6/PKG_ADD' in > file /usr/local/share/octave/packages/ad-1.0.6/PKG_ADD near line 2, column 1 > error: called from: > error: /usr/local/share/octave/3.8.1/m/pkg/private/install.m at line 241, > column 5 > error: /usr/local/share/octave/3.8.1/m/pkg/pkg.m at line 394, column 9 > load-octave-pkg: octave is installing ltfat-2.0.1.tar.gz. > panic: Bus error -- stopping myself... > > Are these errors related? Is this a pkgng error, or problem with the > individual ports?
This is always a tricky thing for a packaging system to handle -- an existing directory being replaced by a file. pkg(8) won't remove a directory unless it is empty, so it can't create the identically named file. In effect the package is conflicting with an earlier version of itself. Actually, I don't know if the directory in question is empty or not: that would be a good thing to find out. Also if it isn't empty, are the contents owned by other packages awaiting upgrade and would your pkg upgrade run ultimately have removed them? pkg(8) crashing with a buss error is definitely a bug in pkg. However, the whole question of how to replace a directory with a file is mostly a problem with the port: yes, it should be possible to do such things, but it is always going to be fragile and sensible software developers will avoid doing such things. Cheers, Matthew -- Dr Matthew J Seaman MA, D.Phil. PGP: http://www.infracaninophile.co.uk/pgpkey
signature.asc
Description: OpenPGP digital signature