• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: Need to do some logic in a component pkg which is specific to the integrated distribution pkg
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Need to do some logic in a component pkg which is specific to the integrated distribution pkg


  • Subject: Re: Need to do some logic in a component pkg which is specific to the integrated distribution pkg
  • From: Sravana Kumar <email@hidden>
  • Date: Wed, 24 Mar 2010 10:15:48 +0530

Hi Bill,


I regret for the delayed response.


I completely agree that there is no need to have same type of installer as Windows has. I am also a Mac fanatic and I like its simplicity and easiness.


But end user need to have the capability to remove what he have installed on to his machine, lets say he didn't like some app which he tried some time back. Why will that app leave the traces of it on the machine, eg. AppSupport, kext etc. Means need the ability of uninstalling, to clean the machine when end user don't want. 



Here in my case, I am developing a shared technology component(service) which can be used by multiple products. When my component gets installed I need to maintain database (refcount) of who are all installed/using this shared component. Such that when we are trying to uninstall we will query the database and act accordingly. If database operations is typical then we can maintain refcount files.



Here in the example you quoted, MyComponent is being used by two products ( p1, p2 ) and these two products are repackaged in to bigger installer package, say GroupPkg. In my case when user tries to install GroupPkg then along with MyComponent, p1 and p2 I need to create two references for both the products p1 and p2. In this case GroupPkg should give handle to MyComponent twice to create references.


As of now I asked the product teams to maintain these reference files, unless I find a good solution.


Thanks,

-Sra1.


On Thu, Mar 18, 2010 at 3:50 AM, Bill Coderre <email@hidden> wrote:
On Mar 17, 2010, at 3:38 AM, Sravana Kumar wrote:
Here in component pkg i need to identify in which distribution package it is running and do some logic some thing like creating a file based on the distribution package. This logic should be inside my component package's preinstall and postinstall. 

Can this be done ?

It can be done, but it is probably not a good idea, because schools and businesses repackage installer packages into bigger metapackages all the time.

When they do, your install package won't get the right stuff passed to it, so your installer won't work "the same" -- and you'll get support calls. (Read what people write online about some companies' installers, and you can get an idea of how they might react to yours.)

On Mac, the mindset is to view the installer as a simple copying of files out of an archive into place, with an enhancement so, e.g., application programs are not downgraded to an older version. (Installer.app uses the Mac programming concept of "bundle versions" to prevent downgrading.)

This is very much the opposite of the Windows installer mindset, where any installer must also be an uninstaller, unload and reload drivers, "phone home" with registration, automatically spool a copy of the manual to the printer, etc, etc, etc. 

It is also very common for a senior company official to say "The Mac installer MUST BE THE SAME AS the Windows installer." Often I'm asked why our installer does not shut down all other programs, completely take over the screen, etc. etc.

Well, Mac is a very different ecosystem, emphasizing simplicity. (Some would say over-emphasizing.) The code being installed is definitely different between Mac and Windows, the code DOING the installation is definitely different between Mac and Windows, why shouldn't the installer LOOK different?

There are two common situations which cause companies to ship complex installers:
1) They are doing work the program should do itself (eg. fixing preference files).  Since your program has to deal with this situation anyway (because users drag-copy apps), why not have it just do the work?

2) They are installing different things on different systems. A common example is to install a Spotlight indexer on 10.5 and later systems. In this case, the preferred solution is to create multiple installation packages and use a distribution metapackage to choose which packages to install.

(I am sure people will suggest other cases, and perhaps common solutions.)

Yes, there are extenuating circumstances, always. But please try to keep installers as simple as possible.

The Point (finally!): WHY do you need to do this? Can you possibly avoid it? If you can explain, maybe we can suggest a different approach.

(It also helps the Installer core team figure out what features are needed.)

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Installer-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

References: 
 >Need to do some logic in a component pkg which is specific to the integrated distribution pkg (From: Sravana Kumar <email@hidden>)
 >Re: Need to do some logic in a component pkg which is specific to the integrated distribution pkg (From: Bill Coderre <email@hidden>)

  • Prev by Date: Re: Can Installer.app download things?
  • Next by Date: RE: package maker
  • Previous by thread: Re: Need to do some logic in a component pkg which is specific to the integrated distribution pkg
  • Next by thread: Building distribution package on the commandline
  • Index(es):
    • Date
    • Thread