[haiku-development] Re: find it icon problem, but ...

Ingo Weinhold <bonefish@xxxxxxxxxxxxxxx> wrote:
> 
> On 2007-06-11 at 00:08:53 [+0200], Jonas Sundström <jonas@xxxxxxxxxxx
> > 
> wrote:
> > Ingo Weinhold <bonefish@xxxxxxxxxxxxxxx> wrote:
> > > On 2007-06-10 at 11:56:03 [+0200], Raynald Lesieur
> > > <raynald.lesieur@xxxxxxxxxxxxx> wrote:
> > > > after a lot of research, I concluded that I can put a copy of 
> > > > the
> > > > program ?mimeset? in the directory ? /home/bin ", which solved 
> > > > the
> > > > problem of icons. but I do not manage to find it why? if 
> > > > somebody
> > > > has
> > > > an idea!
> > > 
> > > We could try to have a closer look at how e.g. Terminal is built.
> > > Please
> > > remove the generated Terminal executable and rebuild it:
> > > 
> > >     rm generated/objects/haiku/x86/release/apps/terminal/Terminal
> > >     jam -q Terminal
> > > 
> > > Please check whether there are any warning or error messages. 
> > > Also do
> > > a
> > > listattr on the Terminal executable to see whether its icon is 
> > > there.
> > 
> > I don't know if this is related, but a while back I tried looking 
> > at
> > the
> > Jam rules to see why the following error gets reported, but I 
> > didn't
> > find
> > anything that looked wrong.
> > 
> > "
> > C++ ../../../../generated/objects/haiku/x86/release/add-ons/tracker
> > /
> > filetype/FileType.o
> > ResComp1 ../../../../generated/objects/haiku/x86/common/add-ons/
> > tracker
> > /filetype/FileType.rsrc
> > Link ../../../../generated/objects/haiku/x86/release/add-ons/
> > tracker/
> > filetype/FileType-F
> > XRes1 ../../../../generated/objects/haiku/x86/release/add-ons/
> > tracker/
> > filetype/FileType-F
> > Chmod1 ../../../../generated/objects/haiku/x86/release/add-ons/
> > tracker/
> > filetype/FileType-F
> > SetType1 ../../../../generated/objects/haiku/x86/release/add-ons/
> > tracker/filetype/FileType-F
> > MimeSet1 ../../../../generated/objects/haiku/x86/release/add-ons/
> > tracker/filetype/FileType-F
> > mimeset: "../../../../generated/objects/haiku/x86/release/add-ons/
> > tracker/filetype/FileType-F": No such file or directory
> > SetVersion1 ../../../../generated/objects/haiku/x86/release/add-ons
> > /
> > tracker/filetype/FileType-F
> > "
> > 
> > The line:  mimeset:  ... : No such file or directory
> 
> That does indeed look interesting. Can you reproduce it? If you can, 
> it 
> would be nice, if you would track it down. I don't expect it to be a 
> problem in the jam part of the build system. I think, the cause will 
> be 
> found in src/build/libbe/storage/mime/UpdateMimeInfoThread.cpp in 
> UpdateMimeInfoThread::DoMimeUpdate(), which is used by our mimeset. 
> There 
> are a few "early outs" in the function, particularly in the second 
> (shared 
> object related) part. I don't see anything obvious, but some problem 
> there 
> would explain the error message as well as the missing vector icon.
> 
> CU, Ingo

Commit r21484 by korli to /haiku/trunk/src/bin/mimeset.cpp:
"actually exit with an error when it happens"
kind of ground my builds to a halt, as the snag in mimesetting
FileType-F was -quite- reproducible. :)

It seems UpdateMimeInfoThread::DoMimeUpdate() fails in the
section below "// supported types". Roughly this sequence:

BAppFileInfo appFileInfoRead;
BAppFileInfo appFileInfoWrite;
// we read from resources and write to attributes
appFileInfoRead.SetInfoLocation(B_USE_RESOURCES);
appFileInfoWrite.SetInfoLocation(B_USE_ATTRIBUTES);
 ... 
BMessage supportedTypes;
err = appFileInfoRead.GetSupportedTypes(&supportedTypes);
err = appFileInfoWrite.SetSupportedTypes(&supportedTypes);

I believe the last call fails on FileType-F, for some reason.

AppFileInfo.cpp's _Read/_Write/_RemoveData do not seem
to use the fWhere member.

/Jonas.


Other related posts: