Home | Contact Us | FAQ | Search & Site Map | Link to Us
Sign In | Join | Other 45 Sites in Network
Home
Discussion Groups
General
GeneralPortable MacsHardwareNetworking
Applications
Mac ApplicationsEudoraFirefox / MozillaInternet ExplorerOutlook ExpressMS OfficeEntourageExcelPowerPointWordVirtual PCMedia PlayerOther MS Products
Programming
Mac ProgrammingCodeWarriorPerl
Country Specific
Australian Mac GroupUK Mac Group

Mac Forum / Programming / Mac Programming / October 2005



Tip: Looking for answers? Try searching our database.

Naive bundle/package question

Thread view: 
Enable EMail Alerts  Start New Thread
Thread rating: 
James Meiss - 21 Oct 2005 23:47 GMT
 
 I have an xCode project (aProject.xcodeproj, say) that somehow lost
its identity as a bundle (or is it a package?). So it appears to the
finder as an ordinary directory.

I would have thought that the "Bundle bit" was supposed to be set on
these project files, so that the finder would recognize them as bundles.
However /Developer/Tools/GetFileInfo says that the bundle bit is not set
on any of my projects (b instead of B)--including of course the errant
one.

So: what makes a bundle a bundle? And how do I get my bundle back?

I have searched the developer documentation, but can't figure out where
the answer might be.

Signature

Jim Meiss
<http://amath.colorado.edu/faculty/jdm>

Reinder Verlinde - 22 Oct 2005 00:43 GMT
>    
>   I have an xCode project (aProject.xcodeproj, say) that somehow lost
> its identity as a bundle (or is it a package?). So it appears to the
> finder as an ordinary directory.
> [...]
> So: what makes a bundle a bundle? And how do I get my bundle back?

See
<http://developer.apple.com/documentation/CoreFoundation/Conceptual/CFBun
dles/Concepts/BundleAnatomy.html#//apple_ref/doc/uid/20001119-BAJFIBAJ>

Reinder
Eric Albert - 22 Oct 2005 10:21 GMT
>    
>   I have an xCode project (aProject.xcodeproj, say) that somehow lost
[quoted text clipped - 3 lines]
> I would have thought that the "Bundle bit" was supposed to be set on
> these project files, so that the finder would recognize them as bundles.

Nope.  All that's required is for there to be a Launch Services binding
for the directory's extension.  If I do "mkdir foo.xcodeproj", the
resulting directory gets the right icon.

-Eric

Signature

Eric Albert         ejalbert@cs.stanford.edu
http://outofcheese.org/

James Meiss - 22 Oct 2005 18:07 GMT
> >    
> >   I have an xCode project (aProject.xcodeproj, say) that somehow lost
[quoted text clipped - 7 lines]
> for the directory's extension.  If I do "mkdir foo.xcodeproj", the
> resulting directory gets the right icon.

Ah. Thanks. I finally realized that I copied the project to my laptop,
but hadn't installed xCode 2.2 on that computer yet, so, the .xcodeproj
extension wasn't in the Launch Serviced database (just .xcode). I
suppose that by the type we are to xCode 3.x, we'll have 12 character
file extensions--won't that be fun!

So: what the heck is the bundle bit for (e.g.
/Developer/Tools/GetFileInfo) ?

Signature

James Meiss
<http://amath.colorado.edu/faculty/jdm>

Eric Albert - 23 Oct 2005 19:39 GMT
> > >   I have an xCode project (aProject.xcodeproj, say) that somehow lost
> > > its identity as a bundle (or is it a package?). So it appears to the
[quoted text clipped - 12 lines]
> suppose that by the type we are to xCode 3.x, we'll have 12 character
> file extensions--won't that be fun!

Hopefully just .xcodeproj -- the project file format is better designed
now so hopefully renaming it won't be necessary.

> So: what the heck is the bundle bit for (e.g.
> /Developer/Tools/GetFileInfo) ?

Not very much any more.  It's a holdover from Mac OS 9.

-Eric

Signature

Eric Albert         ejalbert@cs.stanford.edu
http://outofcheese.org/

James Meiss - 24 Oct 2005 17:26 GMT
> So: what the heck is the bundle bit for (e.g.
> /Developer/Tools/GetFileInfo) ?

Well, I guess (to answer my own question) we have from
<http://developer.apple.com/documentation/CoreFoundation/Conceptual/CFBun
dles/Concepts/BundlesAndFinder.html#//apple_ref/doc/uid/20002127-BAJIBGGC

The Finder identifies bundles by any of the following mechanisms:
  €    The bundle directory has one of the known bundle extensions: .app,
.bundle, .framework, .plugin, .kext, and so on.
  €    The directory has its bundle bit set.
  €    The directory has a known structure type indicating it is a modern
or versioned bundle.

So it appears that you can create a bundle by setting the bundle bit on
a directory, too.

Signature

Jim Meiss
<http://amath.colorado.edu/faculty/jdm>

 
Sign In
Join
My Latest Posts
My Monitored Threads
My Blog
My Photo Gallery
My Profile
My Homepage

Start New Thread
Enable EMail Alerts
Rate this Thread



©2009 Advenet LLC   Privacy Policy - Terms of Use
This website includes both content owned or controlled by Advenet as well as content owned or controlled by third parties.