Register FAQ/Rules Forum Spy Search Today's Posts Mark Forums Read

Welcome to the Mac Forums forums. Please read the FAQ if you have questions. Register to participate.

 
Go Back   Mac Forums > Apple Software > Mac OS X Forums > Mac OS X
TouchArcade.com - iPhone Game Reviews and News

Reply
 
Thread Tools Search this Thread Display Modes
Old Nov 9, 2009, 12:05 PM   #1
sarath
macrumors newbie
 
Join Date: Aug 2009
How to list all the installed packages in a MAC OS

Hi,

I am testing a software which verifies for a package installation in the client(MAC client here) before proceeding with its job.The client software is to be configured first with the package it has to look for at the client.
For this I want to check all the installed packages in a MAC OS.This applies to both Leopard and Snow leopard.

I see there is a /Library/Receipts folder which contains a list of packages .But pkgutil when used gives a different list.Why is it so?Why does the list not match with the receipt folder contents?Is there any other way to get a wholesome list of all packages that are installed?

Moreover what's with Snow Leopard? I do not see the receipts folder anymore.How can I list the installed packages in Snow Leopard?

I greatly appreciate your help
sarath is offline   Reply With Quote
Old Nov 9, 2009, 02:51 PM   #2
calderone
macrumors 6502a
 
Join Date: Aug 2009
Snow Leopard
Things installed via package should visible here:

/Library/Receipts/InstallHistory.plist

You can open this with QuickView or TextEdit. But the Property List Editor that comes with XCode is the preferred method. XCode is of course free at developer.apple.com There is definitely a Receipts folder in Snow Leopard at /Library/Receipts. I am not sure why you don't see one. Hopefully you just overlooked it.

This is actually very important as it is a change from Leopard. If you had some software in Leopard and upgraded to Snow Leopard, and then try to upgrade that software. The installer may not be able to see that you have an old version due to this change. I know of at least one Developer who has had to address this with their clients.

Another location is /var/db/receipts

Leopard
In Leopard, /Library/Receipts

Another location is /var/db/receipts

Both
A much easier way is this command:

Code:
pkgutil --pkgs
This will give all packages. Running this through less will give you more readable output.

Code:
pkgutil --pkgs | less
You can also see the files that were installed, for example:

Code:
pkgutil --pkgs com.apple.pkg.DVDPlayer | less
As always, you can find out what else you can do with pkgutil by running:
Code:
man pkgutil

Last edited by calderone : Nov 9, 2009 at 03:07 PM.
calderone is offline   Reply With Quote

Reply

Mac Forums > Apple Software > Mac OS X Forums > Mac OS X

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Forum Jump


All times are GMT -5. The time now is 05:31 PM.

Mac News | Mac Rumors | iPhone Game Reviews | iPhone Apps

Powered by vBulletin® Version 3.6.10
Copyright ©2000 - 2010, Jelsoft Enterprises Ltd.
Copyright 2002-2010, MacRumors.com, LLC