No Packages Eligible For Install Mac

  1. Nov 06, 2019 My end goal was to install macOS 10.13 High Sierra. I read online that one must upgrade to OS X 10.11 before upgrading to macOS 10.13 if one is starting from OS X 10.6. This upgrade route did not work for me no matter how many solutions I attempted.
  2. Mac Pro Mods PowerMac G3 B&W PowerMac G4 PowerMac G4 Cube PowerMac G5 Others Retail Cases Modders Tools. 'No packages were eligible for install'.
; Date: Sun Oct 16 2016

Tags: Mac OS X

A key step for upgrading the disk on a MacBook Pro is to install a new operating system on the new drive, and then use Migration Assistant to copy over the old data. Depending on how you went about the work, installing Mac OS X on the new system may give you a message: OS X could not be installed on your computer. No packages were eligible for install.

Mac High Sierra No Packages Were Eligible For Install. The problem was that the old Mac did not have its date set correctly. Hold Option (ALT) + Command + R at Mac startup to start internet recovery. Going into Utilities Terminal starts the recovery terminal. Run date mmddHHMMyy - this solves the problem (date must be in PST!). I am trying to install the Public Beta version of El Capitan and after about 10-15 mins of trying to install, a message pops up that says 'no packages were eligible for install' and the installation fails. Here's what I've tried so far: Restarting with command + r: - I do not have a Time Machine backup. Jul 05, 2021 Before you install a new macOS update, make sure that there is free space on the system. In this way, the system can download the update without any trouble and take the needed actions. To check Mac storage, go to the Apple menu from the top and click on 'About This Mac'. A dedicated window will open with details about the system.

This is what it looks like in the installer. Upon seeing this I went 'HUH?' because the installation was from a thumb drive I'd used many times to install Mac OS X (El Capitan) successfully.

The above image came from an attempt to install El Capitan. I just got the following message, macOS could not be installed on your computer, while trying to install macOS High Sierra.

In both cases there was the same cause. In the El Capitan case, as I say in the next paragraph, the hardware clock had reset to zero because it did not have a battery pack. In the High Sierra case, I had performed a hardware reset of the computer in an attempt to fix a bootup problem. I had found advice to disconnect the battery, the power supply, then hold down the power key for a few moments. In both cases the hardware clock had been reset to zero, and macOS refused to boot.

After some yahoogling (duckduckgoing) I came across a simple solution. This particular computer had been running with no battery, and therefore the hardware clock was reset to zero, and Mac OS X had a test against that condition.

We've discussed elsewhere the process to install Mac OS X onto a computer, and transfer information from an old drive. It's during that process when the above message appears. A couple steps prior is where you can take action to correct the problem.

At this step, click on Terminal ..

No packages eligible for install mac operating system

Then change the operating system date.

When running this particular Terminal session, you are ROOT meaning you can change anything on the computer. Normally we type 'date' at the command line just to find out the current day/month/year/time. But, the date command can be used to change the time registered in the system clock.

As I said above, for this particular computer the system clock had been reset to zero because the battery pack had been changed. In fact, the computer had run without a battery for many months because the old battery had gone bad.

As you see on the screen, the date had been January 1, 2001. I then changed the system date to the current time as of the writing of this posting.

To understand the second command, go to a terminal window and type 'man date'.

In the synopsis section you'll see this as an option for the 'date' command:

That's a little obtuse, but further down the manpage is this key:

No Packages Eligible For Install Mac

In other words, the date code for this purpose is month-day-hour-minutes-year .. hence, that's what I entered and it changed the system date to match.

Afterward I closed the Terminal window and was able to successfully install Mac OS X on the computer.

Please enable JavaScript to view the comments powered by Disqus.

OSX flat packages are single installer files with .pkg file extensions.

They appear to have originated with OSX 10.5. You can’t install these fileson OSX < 10.5.

The previous packaging formats were bundles rather than single files:

bundle
A structured directory hierarchy that stores files in a way thatfacilitates their retrieval (see glossary in the software delivery legacyguide)

See OSX legacy packaging redux for details.

As far as I know there is no Apple document describing the flat packageformat.

You may find these other pages useful as background:

  • A MacTech flat package article;
  • An introduction to the flat package format;
  • A guide on unpacking flat packages manually;
  • A comprehensive stackoverflow package building answer.

About the examples on this page¶

I wrote this page in reStructuredText (reST) for Sphinx, with some customSphinx extensions. The extensions pick up the code fragments in this page andrun them on my laptop as part of the build process for the web pages. Theyalso write out the example files listed on this page. The combination meansthat, at the time I last built the website, I confirmed that the code ran onmy laptop, and gave the output you see here.

Flat packages in general¶

Flat packages are xar archives (see the xar man page).

To see the contents of a flat package, the most convenient command ispkgutil--expand, as in:

This will unpack product archive (meta-packages) and their component packages,and allows you to futz with the directory contents in an_output_dir beforereconstituting the package with:

On OSX, tar will unpack xar archives, and will automatically detect thatthe archive is in xar format with tarxfmy.pkg, if you really want to dothe unpacking without pkgutil.

Different package types¶

Flat packages can be of type:

  • product archive – a meta-package format containing one or morecomponent packages with an XML file specifying the behavior of theinstaller, including system and volume requirement checks giving informativeerror messages. See the productbuild man page for more detail.
  • component package – an installer to install one component. Generallyincluded as part of a product archive but can be used as an installer inits own right. A component package installer cannot control the behavior ofthe installer, but can abort the install or raise a post-install errorvia preinstall and postinstall scripts.

Component installer¶

A component installer goes through these stages:

  1. Runs preinstall script if present. An exit code other than zero abortsthe installation.
  2. Writes payload to one or more locations on the target volume
  3. Runs postinstall script if present. An exit code other then zero givesan error message.

We start with some component packages that only have scripts and no payload,to show how they work.

Component installer scripts¶

Contents of scripts/preinstall
Contents of scripts/postinstall

The scripts need to be executable:

Each package needs a package identifier to identify it to the database ofinstalled packages on the target system.

You can list the recorded installed packages on target / with:

Build the package with a fake identifier:

Install the package:

Check the scripts ran by looking for output:

Exit code other than zero causes the installer to give an error message:

Contents of scripts/postinstall

Fixed if the script is not run:

There are some useful environment variables available to thepreinstall, postinstall scripts:

Contents of scripts/preinstall

Here are the new environment variables inserted by the installer:

These appear to be a superset of the environment variables listed for the oldbundle installers at install operations.

No payload, no receipt¶

These “scripts only” installers have no payload, and write no package receiptto the package database:

Payload¶

A flat-package component installer can install one or more bundles to givenoutput locations on the target filesystem.

There are two ways of specifying payload with target location:

  • Using a destination root, using --root flag to pkgbuild. Thisanalyzes a given directory root-path taking this directory to representthe root / directory of the target system. The installer will copy eachdirectory at root-path to the target system at the same relativefilesystem location.
  • By individual bundle component, using --component flag topkgbuild. Specify directories to copy, and give their output locationsseparately using the --install-location flag.

Destination root¶

Do the install:

This install did write a package receipt:

Explicit component(s)¶

We point to a bundle to install and (usually) specify the install location.

In this case the bundle must be a properly formed bundle of some sort.

I’ll make a debug symbols bundle by doing a tiny compilation with clang:

Build, install the package:

The installer has written the expected output files:

You can add more than one bundle to a single component installer.

Here I make another bundle with a different name:

When you add more than one component, you need to give a package identifier,because pkgbuild will not know which component to get an identifier from.

Product archive¶

Component packages give a very basic default install.

Product archives allow you to wrap one or more component installs with aninstall configuration that includes:

  • custom welcome, readme, license and conclusion screens;
  • custom system requirement and volume requirement checks with informativeerror messages using Javascript code;
  • ability to customize choices of component packages to install usingJavascript code.
No packages eligible for install mac

An XML file named Distribution specifies these options (see distributiondefinition file).

Building product archives with productarchive

productarchive has five modes of action:

Archive for “in-app” content¶

This appears to be something to do with the App Store. Use the --contentflag for this one.

Archive from destination root¶

Build an archive from a directory where the paths of the files relative to the--root directory give the output install location on the target volume(see Destination root).

Archive from component bundle(s) or package(s)¶

Build a product archive from one or more components by passing:

  • bundle path(s) with one or more uses of the --component flag (seeExplicit component(s)) and / or;
  • package paths(s) with one or more uses of the --package flag.

Build product archive with two component bundles:

Make bundles into component packages:

Build product archives from the component packages:

Build a Distribution file from component bundle(s) / packages(s)¶

This builds a template Distribution XML file by analyzing one or morecomponents in the form of bundles or .pkg files. Use the --synthesizeflag.

Analyze two component bundles to give a Distribution file:

Analyze two component packages to give a Distribution file:

Archive from Distribution file¶

Build a product archive from a pre-existing Distribution file, using the--distribution flag. The Distribution file refers to pre-existingcomponent .pkg files. If these are not in the current directory, you cangive paths to find .pkg files with the --package-path flag.

Customizing the Distribution file¶

See: distribution definition file and installer Javascript reference.

Adding system and volume checks¶

Contents of distro_check.xml

Serial key for photoshop cs4. Now make the volume check fail:

The volume check gets run on every candidate volume; each volume that passesthe check is eligible for the install.

Debugging Distribution Javascript with system.log

Getting the Javascript right can be tricky because it is running in a highlyspecific environment. system.log() can help.

Contents of distro_debug.xml

Use the -dumplog flag to the installer to see the log.

Adding custom script checks¶

You can add custom executable scripts or binaries to run via the Javascriptfunctions such as the volume check and the system check.

You first have to enable the allow-external-scripts option in theDistribution file XML:

This will cause the installer GUI to ask if you want to allow an externalscript to check if the software can be installed.

You can then call external programs via the Javascript system.run()function. The programs you call with system.run either need to be on thesystem PATH that the installer uses, or provided in the installer, usually viathe --scripts flag to productbuild. Here’s an example of a commandalready on the path:

Contents of distro_system_run.xml

How To Fix No Packages Were Eligible For Install

Check the script ran:

Here’s an example of a custom script:

Contents of distro_custom_run.xml

Make a directory to contain the test script:

Use test script to look for any interesting environment variables available tothe custom script:

Contents of archive_scripts/my_test_cmd.sh

The script must be executable:

Macos mojave no packages were eligible for install

Build the product archive with --scripts flag:

Check the environment variables available to the custom script. We alreadyhave /tmp/my_sudo_envs.log with the standard environment variablesavailable as root, so look for the difference:

There do not seem to be any environment variables to tell us where theinstaller .pkg file is. Here we can work out which volume the installeris installing to with the SUDO_COMMAND variable, but this will only workfor command line installs - the installer GUI does not set this variable.

Customizing the installer pages¶

See distribution definition file for details.

You can customize these pages:

  • Welcome (<welcome../> element)
  • Readme (<readme../>)
  • License (<license../>)
  • Conclusion (<conclusion../>)

To do this, you specify the filename containing the custom text, and theformat of the file. For example:

The file should be in the Resources/<language>.lproj directory of theinstaller .pkg, where <language> is a language like “English”,“French” or “Spanish”, or shorthand for these such as “en”, “fr”, “es”. Youcan provide a Resources directory with the --resources flag toproductbuild.

Contents of my_resources/English.lproj/welcome.html
Contents of distro_welcome.xml

We use the --resources flag to add the resources directory: I9100 efs tar md5 download manager.

No Packages Eligible For Install Mac Mini

The welcome won’t show up in the command line install, so you need to run thisinstaller via the GUI to see the new text.

El Capitan No Packages

I used an HTML file here, and that works as expected, for me at least. Thereare many installers that use .rtf files instead of HTML, but I heard arumor that productbuild does not deal with these correctly. If you want touse rich text format files with productbuild, you might have to do somepost-processing of your installer with – pkgutil--expandmy_archive.pkgout_dir; (futz); pkgutil--flattenout_dirmy_archive.pkg.