apt-cache search finds this stuff in a pkg list located at:
/var/lib/apt/lists/

There are other package resources in /var/ at various spots:
/var/lib/dpkg/
/var/lib/dpkg/info
/var/cache/apt/archives/

At one point I found myself looking at dpkg source, only to find
a lot of C++ code that was incomprehensible to my pea sized brain.

Then I came to my senses and used strace to just see what these tools
do.  For example:
strace apt-cache search snort 2>&1 | less
strace dpkg -l 2>&1 | less
strace -f dpkg -l 2>&1 | less

Thanks Mike for the note on apt-file, I wasn't aware of that one.
Just tried it, and you do a apt-file update, which grabs this
Contents-<arch>.gz file and can search on it.  It's a big cross
reference of file-locations and pkg names.

I'm interested in collecting my .deb collection,
for reuse on other machines.  Whenever you do an apt-get install pkgname,
the .deb file gets saved in /var/cache/apt/archive.
So say at home I get an install that I like.  I could burn a CDROM
with .deb files, take it to another machine, and install these.

I've done some of this using dpkg-scanpackages.  Then add
a line to etc/apt/sources.list like:
deb file:///mydeb binary/

The biggest problem I ran into was that I want to use this private
collection, and also the normal debian collections, favouring the
private collection.  So I still want this in my sources.list:
deb ftp://ftp.cs.unm.edu/mirrors/debian/ unstable main non-free contrib

You can use something called apt-pinning to mix and match
multiple standard collections(/etc/apt/preferences):

Package: *
Pin: release a=stable
PinPriority: 700

Package: *
Pin: release a=unstable
PinPriority: 300

The PinPriority tells apt-get install which one to use by default.
Then if you want to install something from unstable:
apt-get install pkgname/unstable

After some googling, looks like my problem might be solved by making
a "Release" file to go with my .deb collection and "Packages.gz" file.

Well, thats enough chatter from me.




_______________________________________________
TCLUG Mailing List - Minneapolis/St. Paul, Minnesota
http://www.mn-linux.org tclug-list at mn-linux.org
https://mailman.real-time.com/mailman/listinfo/tclug-list