[physfs] adding archive paths to search paths

Ryan C. Gordon icculus at clutteredmind.org
Fri Nov 29 03:26:48 EST 2002


> I have zip-files that contain subdirectories inside
> them. I was wondering how I can add those directories
> to my search path. If I have those directories lying
> around in the real file system, I can add them.
> However if they only exist in the archives, I can't
> seem to add them.

Search path entries are meant to be roots of directory trees...you can add
a zipfile as a root of the contained directories. That you can add
subdirectories in the physical filesystem that are children of each other
is a side effect, really.

Plus, if you were to add separate subdirs from a zipfile, the contents
would all interpolate into one tree anyhow, so you might as well create a
zip that has the structure you want in the first place...if you want all
the files in one view, just put them all in the zip's root dir.

Otherwise, they are accessed as "/my/dir/in/the/zip/filename.ext" once
they are in the search path.

> Also, I noticed that I have to explicitly add
> zip-files to my search path before I can see their
> contents. Is there a more automatic way of making them
> all available automatically?

Well, we have to know what files to add.  :)  Look at
PHYSFS_setSaneConfig()...if it doesn't fit your needs, it will at least
show you how to do it yourself.

> Finally, if anybody responds, can you please cc: me. I
> subscribed to this list about a month ago, but so far
> I have seen no posts. I'm wondering if something's
> broken. (And is there a mail-list archive I can look
> at?)

The list has been quiet. I have a few things brewing in preparation for a
1.0 release, and then (unless something comes up), PhysicsFS will be
stable and more or less complete.

(Crappy) mailing list archive:
    http://icculus.org/cgi-bin/ezmlm/ezmlm-cgi?4

--ryan.






More information about the physfs mailing list