Commit Graph

14 Commits

Author SHA1 Message Date
Nitin A Kamble 1695345393 initramfs-live-install*: fix the "install" boot option
The install boot option was giving the following error when one tried to
install the live image on a  permanent storage of a BSP.

cat: write error Invalid argument
Installation image failed
sh: can't access tty: job control turned off

Further digging into the issue, found out that the install script was trying
to do this:
 cat /proc/mounts > /etc/mtab

And in the base-files recipe the /etc/mtab is made soft link to /proc/mounts.
So the cat command was failing to write on /etc/mtab. As the contents of
the /proc/mounts is already reflected in the /etc/mtab file due to the
symlink-ing, there is no need for this step to recreate /etc/mtab in the
install script. So just removing this unnecessary step, which solves the
install issue of the live images.

Fixes this bug:
[YOCTO #4229]

(From OE-Core rev: f8663eac872882e94d956b1b604304e92b865766)

Signed-off-by: Nitin A Kamble <nitin.a.kamble@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-04-16 12:06:40 +01:00
Darren Hart 4f4d82c62c install: Look for grub2 files on the initramfs, not rootfs
Fixes [YOCTO #3870] atom-pc - cannot boot image on netbook after install

The problem here is that grub2 is installed but a grub 1 menu.lst is
created at install time. At boot, grub2 doesn't find a grub.cfg file and
drops to the grub shell.

This happens because the installer is looking for 40_custom (a grub2
file) on the rootfs, but grub2 isn't installed on the rootfs. It exists
in the initramfs. Patching the installer to look on the initramfs
resolves the problem.

Note that the problem may have occurred if grub2 used to be installed on
the rootfs but was later removed. In any case, the installer is HORRIBLE
and really needs to be completely redesigned as part of the deployment
effort. For now, this should get the live image installer limping along
again.

Tested on a Toshiba NB-305.

(From OE-Core rev: 8756a19bd24045d41ad20abb581e7872d0fc9ee6)

Signed-off-by: Darren Hart <dvhart@linux.intel.com>
Cc: alexandru.c.georgescu@intel.com
Cc: sgw@linux.intel.com
Cc: ross.burton@intel.com
Cc: richard.purdie@intel.com
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2013-02-22 06:39:07 -08:00
Darren Hart 203231f1f8 initrdscripts: Update install.sh to work with mmc devices
Fixes [YOCTO #2385]

The installer only searches for hd[ab] sd[ab]. Some newer BSPs have mmcblk
devices that should be used as the install target. These devices also have a
partition prefix (mmcblk0p1 instead of mmcblk01). As they are detected
asynchronously, it is necessary to add the rootwait kernel parameter to avoid
a race condition trying to mount the root device.

As BSPs like the FRI2 and the sys940x have mmc devices and will have a 1.2
release, we should push this to 1.2.1. The changes are perfectly contained and
easily verified.

Test for an mmcblk device and add the p partition prefix if necessary. Add the
rootwait kernel parameter when an mmcblk device is detected.  Replace the series
of explicit umount commands with a single umount using a wildcard. This will
find all the partitions and will not try to unmount non-existant devices. Avoid
copy and paste errors by replacing /dev/${device}${pX} references with the
previously assigned rootfs, bootfs, and swap variables.

These changes have been tested on the FRI2 Sato image which installed to
/dev/mmcblk0 as well as the N450 Sato image which installed to /dev/sda. Both
were successful.

(From OE-Core rev: bf403680d72e360c7382f540ea25cfdcbe77b4e5)

Signed-off-by: Darren Hart <dvhart@linux.intel.com>
CC: Scott Garman <scott.a.garman@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2012-05-06 09:55:48 +01:00
Darren Hart e4fe5542a5 Set an explicit path for the initrd scripts
If we don't set PATH, then the shell will specify one for us.
Busybox adds the sbin dirs, but bash does not. I hit an
issue where bash (among other things) ended up in my initrd
and the boot scripts failed due to a bad default PATH. While
that is a separate issue, we should not be at the mercy of the
shell's default PATH. Update the initrdscripts to all specify:

PATH=/sbin:/bin:/usr/sbin:/usr/bin

(From OE-Core rev: 4617ae0f433876037c2c9a0dfdb5e373e7a5c77b)

Signed-off-by: Darren Hart <dvhart@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-09-16 13:30:26 +01:00
Tom Zanussi 0ecc7bbb46 initramfs-live-install: add PN to RDEPENDS
RDEPENDS is package-specific, so add ${PN} to it.

(From OE-Core rev: ac3373f5baefd5ac5fea7d7f68690bf0f0889be6)

Signed-off-by: Tom Zanussi <tom.zanussi@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-09-16 13:30:26 +01:00
Tom Zanussi bcd1bca880 initramfs-live-install: add support for grub2
grub2 needs a different set of install steps from grub 0.97.  This
adds them to init-install.sh and adds an install-time check that
determines which version is being used and which steps to use
depending on the version of grub selected.

(From OE-Core rev: c67d03eb3684acab89e5972609e397087727e74e)

Signed-off-by: Tom Zanussi <tom.zanussi@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-09-15 11:23:58 +01:00
Lianhao Lu dc3a8274c7 initramfs-live-install: Be consistent with grub.
[YOCTO #1428]
Because the underlying grub 0.97 the initramfs-live-install RDEPDNEDS on
only supports 32bit x86 target, set the COMPATIBLE_HOST accordingly.

(From OE-Core rev: d128b4f2746ee8525352ce982a9c2a5e422630f2)

Signed-off-by: Lianhao Lu <lianhao.lu@intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-09-07 22:54:14 +01:00
Richard Purdie 05b59a64a3 initrdscripts: Inhibit compiler/libc dependencies as this is just a configuration file 2011-06-13 22:38:06 +01:00
Tom Zanussi 10cf515710 initramfs-live-install: comment out allarch inherit to resolve no provider
initramfs-live-install is only compatible with i.86|x86_64 so
shouldn't inherit 'allarch'.  This comments it out.

More specifically, commit 52295fa3de
(Improve handling of 'all' architecture recipes and their interaction
with sstate) sets TARGET_ARCH which due to the COMPATIBLE_HOST setting
in the recipe causes it to be skipped and gives the following error
for any -live build:

NOTE: Resolving any missing task queue dependencies
NOTE: Runtime target 'initramfs-live-install' is unbuildable, removing...
Missing or unbuildable dependency chain was: ['initramfs-live-install']
ERROR: Required build target 'core-image-sato-live' has no buildable providers.
Missing or unbuildable dependency chain was: ['core-image-sato-live', 'core-ima\
ge-minimal-initramfs', 'initramfs-live-install']
ERROR: Nothing RPROVIDES 'initramfs-live-install'

(From OE-Core rev: e576e4aa91fc1608f706a341088f9a7b9a21cd2a)

Signed-off-by: Tom Zanussi <tom.zanussi@intel.com>

Commented out with explaination instead of remove

Signed-off-by: Saul Wold <sgw@linux.intel.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-06-09 15:48:27 +01:00
Richard Purdie 52295fa3de Improve handling of 'all' architecture recipes and their interaction with sstate
The existing PACKAGE_ARCH = "all" mechanism of sharing packages is problematic
with sstate since there are a variety of variables which have target specific
values and the sstate package therefore correctly changes signature depending
on the MACHINE setting.

This patch creates a new "allarch" class which sets:

PACKAGE_ARCH = "all"

(as per the existing convention)

INHIBIT_DEFAULT_DEPS = "1"

(since its not target specific and therefore can't depend on the cross
compiler or target libc)

TARGET_ARCH = "all"
TARGET_OS = "linux"
TARGET_CC_ARCH = "none"

(since these variables shouldn't change between the different packages and
target compiler flags shouldn't be getting used)

PACKAGE_EXTRA_ARCHS = ""

(since we shouldn't be depending on any architecture specific package architectures)

Not all PACKAGE_ARCH = "all" recipes can use this class since some run configure
checks on the compiler. This means they have target specific components and therefore
the "all" classification is incorrect.

(From OE-Core rev: 26e5e5feb695864b11e47e24017e254c28f14494)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-05-31 13:07:00 +01:00
Richard Purdie 4d609d5021 Replace POKYBASE with COREBASE
(From OE-Core rev: 607a7657715f6fcba467a4e55ba64f41f4e13a15)

Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
2011-04-21 00:29:29 +01:00
Darren Hart d9573b40b1 Correct DESCRIPTION typos in various recipes
An investigation into undocumented variables uncovered a few mispellings
of the variable DESCRIPTION.

Signed-off-by: Darren Hart <dvhart@linux.intel.com>
2010-12-10 22:01:42 -08:00
Mei Lei 7adf2aa0d3 initramfs-live-install:Add license checksum to bb file
Add COPYING.MIT file checksum to bb file

Signed-off-by: Mei Lei <lei.mei@intel.com>
2010-12-06 22:02:18 +00:00
Richard Purdie 29d6678fd5 Major layout change to the packages directory
Having one monolithic packages directory makes it hard to find things
and is generally overwhelming. This commit splits it into several
logical sections roughly based on function, recipes.txt gives more
information about the classifications used.

The opportunity is also used to switch from "packages" to "recipes"
as used in OpenEmbedded as the term "packages" can be confusing to
people and has many different meanings.

Not all recipes have been classified yet, this is just a first pass
at separating things out. Some packages are moved to meta-extras as
they're no longer actively used or maintained.

Signed-off-by: Richard Purdie <rpurdie@linux.intel.com>
2010-08-27 15:29:45 +01:00