* Re: Contents of non-rootfs partitions
From: Patrick Ohly @ 2016-11-24 7:38 UTC (permalink / raw)
To: Ulrich Ölmann, Eduard Bartosh; +Cc: openembedded-core
In-Reply-To: <20161124061543.e2xpgh7zjir3oynk@pengutronix.de>
On Thu, 2016-11-24 at 07:15 +0100, Ulrich Ölmann wrote:
> On Wed, Nov 23, 2016 at 04:56:56PM +0100, Patrick Ohly wrote:
> > Excluding only the directory content but not the actual directory is
> > indeed a good point. I'm a bit undecided. When excluding only the
> > directory content, there's no way of building a rootfs without that
> > mount point, if that's desired. OTOH, when excluding also the directory,
> > the data would have to be staged under a different path in the rootfs
> > and the mount point would have to be a separate, empty directory.
> >
> > I'm leaning towards excluding the directory content and keeping the
> > directory.
>
> what about having both possibilities by leaning against the syntax that rsync
> uses to specify if a whole source directory or only it's contents shall be
> synced to some destination site (see [1])?
I like that idea.
--
Best Regards, Patrick Ohly
The content of this message is my personal opinion only and although
I am an employee of Intel, the statements I make here in no way
represent Intel's position on the issue, nor am I authorized to speak
on behalf of Intel on this matter.
^ permalink raw reply
* [PATCH v5 6/6] wic: selftest: add tests for --fixed-size partition flags
From: Maciej Borzecki @ 2016-11-24 7:08 UTC (permalink / raw)
To: openembedded-core; +Cc: Paul Eggleton, Maciej Borzecki
In-Reply-To: <cover.1479971185.git.maciej.borzecki@rndity.com>
wic has a new flag for setting a fixed parition size --fixed-size. Add
tests that verify if partition is indeed sized properly and that errors
are signaled when there is not enough space to fit partition data.
Signed-off-by: Maciej Borzecki <maciej.borzecki@rndity.com>
---
meta/lib/oeqa/selftest/wic.py | 61 +++++++++++++++++++++++++++++++++++++++++++
1 file changed, 61 insertions(+)
diff --git a/meta/lib/oeqa/selftest/wic.py b/meta/lib/oeqa/selftest/wic.py
index 84ba08675b2995812a858e78b3678b2ab325b15b..4cba61060cbd081b2288c970877d863ef42d9b7f 100644
--- a/meta/lib/oeqa/selftest/wic.py
+++ b/meta/lib/oeqa/selftest/wic.py
@@ -29,6 +29,7 @@ import unittest
from glob import glob
from shutil import rmtree
from functools import wraps
+from tempfile import NamedTemporaryFile
from oeqa.selftest.base import oeSelfTest
from oeqa.utils.commands import runCmd, bitbake, get_bb_var, runqemu
@@ -59,6 +60,8 @@ class Wic(oeSelfTest):
def setUpLocal(self):
"""This code is executed before each test method."""
+ self.native_sysroot = get_bb_var('STAGING_DIR_NATIVE', 'core-image-minimal')
+
arch = get_bb_var('HOST_ARCH', 'core-image-minimal')
is_x86 = arch in ['i586', 'i686', 'x86_64']
if is_x86:
@@ -343,3 +346,61 @@ class Wic(oeSelfTest):
self.assertEqual(0, runCmd("wic create %s -e core-image-minimal" \
% image).status)
self.assertEqual(1, len(glob(self.resultdir + "%s-*direct" % image)))
+
+ def _make_fixed_size_wks(self, size):
+ """
+ Create a wks of an image with a single partition. Size of the partition is set
+ using --fixed-size flag. Returns a tuple: (path to wks file, wks image name)
+ """
+ with NamedTemporaryFile("w", suffix=".wks", delete=False) as tf:
+ wkspath = tf.name
+ tf.write("part " \
+ "--source rootfs --ondisk hda --align 4 --fixed-size %d "
+ "--fstype=ext4\n" % size)
+ wksname = os.path.splitext(os.path.basename(wkspath))[0]
+
+ return wkspath, wksname
+
+ def test_fixed_size(self):
+ """
+ Test creation of a simple image with partition size controlled through
+ --fixed-size flag
+ """
+ wkspath, wksname = self._make_fixed_size_wks(200)
+
+ self.assertEqual(0, runCmd("wic create %s -e core-image-minimal" \
+ % wkspath).status)
+ os.remove(wkspath)
+ wicout = glob(self.resultdir + "%s-*direct" % wksname)
+ self.assertEqual(1, len(wicout))
+
+ wicimg = wicout[0]
+
+ # verify partition size with wic
+ res = runCmd("parted -m %s unit mib p 2>/dev/null" % wicimg,
+ ignore_status=True,
+ native_sysroot=self.native_sysroot)
+ self.assertEqual(0, res.status)
+
+ # parse parted output which looks like this:
+ # BYT;\n
+ # /var/tmp/wic/build/tmpfwvjjkf_-201611101222-hda.direct:200MiB:file:512:512:msdos::;\n
+ # 1:0.00MiB:200MiB:200MiB:ext4::;\n
+ partlns = res.output.splitlines()[2:]
+
+ self.assertEqual(1, len(partlns))
+ self.assertEqual("1:0.00MiB:200MiB:200MiB:ext4::;", partlns[0])
+
+ def test_fixed_size_error(self):
+ """
+ Test creation of a simple image with partition size controlled through
+ --fixed-size flag. The size of partition is intentionally set to 1MiB
+ in order to trigger an error in wic.
+ """
+ wkspath, wksname = self._make_fixed_size_wks(1)
+
+ self.assertEqual(1, runCmd("wic create %s -e core-image-minimal" \
+ % wkspath, ignore_status=True).status)
+ os.remove(wkspath)
+ wicout = glob(self.resultdir + "%s-*direct" % wksname)
+ self.assertEqual(0, len(wicout))
--
2.5.0
^ permalink raw reply related
* [PATCH v5 5/6] wic: selftest: do not assume bzImage kernel image
From: Maciej Borzecki @ 2016-11-24 7:08 UTC (permalink / raw)
To: openembedded-core; +Cc: Paul Eggleton, Maciej Borzecki
In-Reply-To: <cover.1479971185.git.maciej.borzecki@rndity.com>
Instead of assuming that bzImage is available, query bitbake enviroment
for KERNEL_IMAGETYPE.
Signed-off-by: Maciej Borzecki <maciej.borzecki@rndity.com>
---
meta/lib/oeqa/selftest/wic.py | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/meta/lib/oeqa/selftest/wic.py b/meta/lib/oeqa/selftest/wic.py
index 2db14445956bc5adcf1e755844bbdb69edcb468f..84ba08675b2995812a858e78b3678b2ab325b15b 100644
--- a/meta/lib/oeqa/selftest/wic.py
+++ b/meta/lib/oeqa/selftest/wic.py
@@ -338,7 +338,8 @@ class Wic(oeSelfTest):
def test_sdimage_bootpart(self):
"""Test creation of sdimage-bootpart image"""
image = "sdimage-bootpart"
- self.write_config('IMAGE_BOOT_FILES = "bzImage"\n')
+ kimgtype = get_bb_var('KERNEL_IMAGETYPE', 'core-image-minimal')
+ self.write_config('IMAGE_BOOT_FILES = "%s"\n' % kimgtype)
self.assertEqual(0, runCmd("wic create %s -e core-image-minimal" \
% image).status)
self.assertEqual(1, len(glob(self.resultdir + "%s-*direct" % image)))
--
2.5.0
^ permalink raw reply related
* [PATCH v5 4/6] wic: selftest: avoid COMPATIBLE_HOST issues
From: Maciej Borzecki @ 2016-11-24 7:08 UTC (permalink / raw)
To: openembedded-core; +Cc: Paul Eggleton, Maciej Borzecki
In-Reply-To: <cover.1479971185.git.maciej.borzecki@rndity.com>
wic tests will unconditionally attempt to build syslinux and add
configuration options that may not be compatible with current machine.
Resolve this by consulting HOST_ARCH (which defaults to TARGET_ARCH) and build
recipes, add configuration options or skip tests conditionally.
A convenience decorator onlyForArch() can be used to skip test cases for
specific architectures.
Signed-off-by: Maciej Borzecki <maciej.borzecki@rndity.com>
---
meta/lib/oeqa/selftest/wic.py | 51 +++++++++++++++++++++++++++++++++++++++----
1 file changed, 47 insertions(+), 4 deletions(-)
diff --git a/meta/lib/oeqa/selftest/wic.py b/meta/lib/oeqa/selftest/wic.py
index faac11e21643e4c32a83b649b6ae986fead498f1..2db14445956bc5adcf1e755844bbdb69edcb468f 100644
--- a/meta/lib/oeqa/selftest/wic.py
+++ b/meta/lib/oeqa/selftest/wic.py
@@ -24,15 +24,33 @@
"""Test cases for wic."""
import os
+import unittest
from glob import glob
from shutil import rmtree
+from functools import wraps
from oeqa.selftest.base import oeSelfTest
from oeqa.utils.commands import runCmd, bitbake, get_bb_var, runqemu
from oeqa.utils.decorators import testcase
+class onlyForArch(object):
+
+ def __init__(self, *args):
+ self.archs = args
+
+ def __call__(self,f):
+ @wraps(f)
+ def wrapped_f(*args, **kwargs):
+ arch = get_bb_var('HOST_ARCH', 'core-image-minimal')
+ if self.archs and arch not in self.archs :
+ raise unittest.SkipTest("Testcase arch dependency not met: %s" % arch)
+ return f(*args, **kwargs)
+ wrapped_f.__name__ = f.__name__
+ return wrapped_f
+
+
class Wic(oeSelfTest):
"""Wic test class."""
@@ -41,15 +59,22 @@ class Wic(oeSelfTest):
def setUpLocal(self):
"""This code is executed before each test method."""
- self.write_config('IMAGE_FSTYPES += " hddimg"\n'
- 'MACHINE_FEATURES_append = " efi"\n')
+ arch = get_bb_var('HOST_ARCH', 'core-image-minimal')
+ is_x86 = arch in ['i586', 'i686', 'x86_64']
+ if is_x86:
+ self.write_config('IMAGE_FSTYPES += " hddimg"\n' \
+ 'MACHINE_FEATURES_append = " efi"\n')
# Do this here instead of in setUpClass as the base setUp does some
# clean up which can result in the native tools built earlier in
# setUpClass being unavailable.
if not Wic.image_is_ready:
- bitbake('syslinux syslinux-native parted-native gptfdisk-native '
- 'dosfstools-native mtools-native bmap-tools-native')
+ tools = 'parted-native gptfdisk-native ' \
+ 'dosfstools-native mtools-native bmap-tools-native'
+ if is_x86:
+ tools += ' syslinux syslinux-native'
+ bitbake(tools)
+
bitbake('core-image-minimal')
Wic.image_is_ready = True
@@ -71,6 +96,7 @@ class Wic(oeSelfTest):
self.assertEqual(0, runCmd('wic list --help').status)
@testcase(1211)
+ @onlyForArch('i586', 'i686', 'x86_64')
def test_build_image_name(self):
"""Test wic create directdisk --image-name core-image-minimal"""
self.assertEqual(0, runCmd("wic create directdisk "
@@ -78,6 +104,7 @@ class Wic(oeSelfTest):
self.assertEqual(1, len(glob(self.resultdir + "directdisk-*.direct")))
@testcase(1212)
+ @onlyForArch('i586', 'i686', 'x86_64')
def test_build_artifacts(self):
"""Test wic create directdisk providing all artifacts."""
bbvars = dict((var.lower(), get_bb_var(var, 'core-image-minimal')) \
@@ -92,6 +119,7 @@ class Wic(oeSelfTest):
self.assertEqual(1, len(glob(self.resultdir + "directdisk-*.direct")))
@testcase(1157)
+ @onlyForArch('i586', 'i686', 'x86_64')
def test_gpt_image(self):
"""Test creation of core-image-minimal with gpt table and UUID boot"""
self.assertEqual(0, runCmd("wic create directdisk-gpt "
@@ -125,6 +153,7 @@ class Wic(oeSelfTest):
self.assertEqual(0, runCmd('wic help kickstart').status)
@testcase(1264)
+ @onlyForArch('i586', 'i686', 'x86_64')
def test_compress_gzip(self):
"""Test compressing an image with gzip"""
self.assertEqual(0, runCmd("wic create directdisk "
@@ -134,6 +163,7 @@ class Wic(oeSelfTest):
"directdisk-*.direct.gz")))
@testcase(1265)
+ @onlyForArch('i586', 'i686', 'x86_64')
def test_compress_bzip2(self):
"""Test compressing an image with bzip2"""
self.assertEqual(0, runCmd("wic create directdisk "
@@ -143,6 +173,7 @@ class Wic(oeSelfTest):
"directdisk-*.direct.bz2")))
@testcase(1266)
+ @onlyForArch('i586', 'i686', 'x86_64')
def test_compress_xz(self):
"""Test compressing an image with xz"""
self.assertEqual(0, runCmd("wic create directdisk "
@@ -152,6 +183,7 @@ class Wic(oeSelfTest):
"directdisk-*.direct.xz")))
@testcase(1267)
+ @onlyForArch('i586', 'i686', 'x86_64')
def test_wrong_compressor(self):
"""Test how wic breaks if wrong compressor is provided"""
self.assertEqual(2, runCmd("wic create directdisk "
@@ -159,6 +191,7 @@ class Wic(oeSelfTest):
"-c wrong", ignore_status=True).status)
@testcase(1268)
+ @onlyForArch('i586', 'i686', 'x86_64')
def test_rootfs_indirect_recipes(self):
"""Test usage of rootfs plugin with rootfs recipes"""
wks = "directdisk-multi-rootfs"
@@ -170,6 +203,7 @@ class Wic(oeSelfTest):
self.assertEqual(1, len(glob(self.resultdir + "%s*.direct" % wks)))
@testcase(1269)
+ @onlyForArch('i586', 'i686', 'x86_64')
def test_rootfs_artifacts(self):
"""Test usage of rootfs plugin with rootfs paths"""
bbvars = dict((var.lower(), get_bb_var(var, 'core-image-minimal')) \
@@ -188,6 +222,7 @@ class Wic(oeSelfTest):
"%(wks)s-*.direct" % bbvars)))
@testcase(1346)
+ @onlyForArch('i586', 'i686', 'x86_64')
def test_iso_image(self):
"""Test creation of hybrid iso image with legacy and EFI boot"""
self.assertEqual(0, runCmd("wic create mkhybridiso "
@@ -220,6 +255,7 @@ class Wic(oeSelfTest):
self.assertTrue(content[var])
@testcase(1351)
+ @onlyForArch('i586', 'i686', 'x86_64')
def test_wic_image_type(self):
"""Test building wic images by bitbake"""
self.assertEqual(0, bitbake('wic-image-minimal').status)
@@ -235,6 +271,7 @@ class Wic(oeSelfTest):
self.assertTrue(os.path.isfile(os.path.realpath(path)))
@testcase(1348)
+ @onlyForArch('i586', 'i686', 'x86_64')
def test_qemux86_directdisk(self):
"""Test creation of qemux-86-directdisk image"""
image = "qemux86-directdisk"
@@ -243,6 +280,7 @@ class Wic(oeSelfTest):
self.assertEqual(1, len(glob(self.resultdir + "%s-*direct" % image)))
@testcase(1349)
+ @onlyForArch('i586', 'i686', 'x86_64')
def test_mkgummidisk(self):
"""Test creation of mkgummidisk image"""
image = "mkgummidisk"
@@ -251,6 +289,7 @@ class Wic(oeSelfTest):
self.assertEqual(1, len(glob(self.resultdir + "%s-*direct" % image)))
@testcase(1350)
+ @onlyForArch('i586', 'i686', 'x86_64')
def test_mkefidisk(self):
"""Test creation of mkefidisk image"""
image = "mkefidisk"
@@ -259,6 +298,7 @@ class Wic(oeSelfTest):
self.assertEqual(1, len(glob(self.resultdir + "%s-*direct" % image)))
@testcase(1385)
+ @onlyForArch('i586', 'i686', 'x86_64')
def test_directdisk_bootloader_config(self):
"""Test creation of directdisk-bootloader-config image"""
image = "directdisk-bootloader-config"
@@ -267,6 +307,7 @@ class Wic(oeSelfTest):
self.assertEqual(1, len(glob(self.resultdir + "%s-*direct" % image)))
@testcase(1422)
+ @onlyForArch('i586', 'i686', 'x86_64')
def test_qemu(self):
"""Test wic-image-minimal under qemu"""
self.assertEqual(0, bitbake('wic-image-minimal').status)
@@ -277,6 +318,7 @@ class Wic(oeSelfTest):
self.assertEqual(1, status, 'Failed to run command "%s": %s' % (command, output))
self.assertEqual(output, '/dev/root /\r\n/dev/vda3 /mnt')
+ @onlyForArch('i586', 'i686', 'x86_64')
def test_bmap(self):
"""Test generation of .bmap file"""
image = "directdisk"
@@ -285,6 +327,7 @@ class Wic(oeSelfTest):
self.assertEqual(1, len(glob(self.resultdir + "%s-*direct" % image)))
self.assertEqual(1, len(glob(self.resultdir + "%s-*direct.bmap" % image)))
+ @onlyForArch('i586', 'i686', 'x86_64')
def test_systemd_bootdisk(self):
"""Test creation of systemd-bootdisk image"""
image = "systemd-bootdisk"
--
2.5.0
^ permalink raw reply related
* [PATCH v5 3/6] wic: add --fixed-size wks option
From: Maciej Borzecki @ 2016-11-24 7:08 UTC (permalink / raw)
To: openembedded-core; +Cc: Paul Eggleton, Maciej Borzecki
In-Reply-To: <cover.1479971185.git.maciej.borzecki@rndity.com>
Added new option --fixed-size to wks. The option can be used to indicate
the exact size of a partition. The option cannot be added together with
--size, in which case an error will be raised. Other options that
influence automatic partition size (--extra-space, --overhead-factor),
if specifiec along with --fixed-size, will raise an error.
If it partition data is larger than the amount of space specified with
--fixed-size option wic will raise an error.
Signed-off-by: Maciej Borzecki <maciej.borzecki@rndity.com>
---
scripts/lib/wic/help.py | 14 ++++--
scripts/lib/wic/imager/direct.py | 2 +-
scripts/lib/wic/ksparser.py | 41 ++++++++++++++--
scripts/lib/wic/partition.py | 88 +++++++++++++++++++++-------------
scripts/lib/wic/utils/partitionedfs.py | 2 +-
5 files changed, 105 insertions(+), 42 deletions(-)
diff --git a/scripts/lib/wic/help.py b/scripts/lib/wic/help.py
index e5347ec4b7c900c68fc64351a5293e75de0672b3..daa11bf489c135627ddfe4cef968e48f8e3ad1d8 100644
--- a/scripts/lib/wic/help.py
+++ b/scripts/lib/wic/help.py
@@ -646,6 +646,12 @@ DESCRIPTION
not specified, the size is in MB.
You do not need this option if you use --source.
+ --fixed-size: Exact partition size. Value format is the same
+ as for --size option. This option cannot be
+ specified along with --size. If partition data
+ is larger than --fixed-size and error will be
+ raised when assembling disk image.
+
--source: This option is a wic-specific option that names the
source of the data that will populate the
partition. The most common value for this option
@@ -719,13 +725,15 @@ DESCRIPTION
space after the space filled by the content
of the partition. The final size can go
beyond the size specified by --size.
- By default, 10MB.
+ By default, 10MB. This option cannot be used
+ with --fixed-size option.
--overhead-factor: This option is specific to wic. The
size of the partition is multiplied by
this factor. It has to be greater than or
- equal to 1.
- The default value is 1.3.
+ equal to 1. The default value is 1.3.
+ This option cannot be used with --fixed-size
+ option.
--part-type: This option is specific to wic. It specifies partition
type GUID for GPT partitions.
diff --git a/scripts/lib/wic/imager/direct.py b/scripts/lib/wic/imager/direct.py
index 2bedef08d6450096c786def6f75a9ee53fcd4b3b..11ec15e33f65885618c7adc83e55c6a39fedbe99 100644
--- a/scripts/lib/wic/imager/direct.py
+++ b/scripts/lib/wic/imager/direct.py
@@ -290,7 +290,7 @@ class DirectImageCreator(BaseImageCreator):
self.bootimg_dir, self.kernel_dir, self.native_sysroot)
- self.__image.add_partition(int(part.size),
+ self.__image.add_partition(part.disk_size,
part.disk,
part.mountpoint,
part.source_file,
diff --git a/scripts/lib/wic/ksparser.py b/scripts/lib/wic/ksparser.py
index 0894e2b199a299fbbed272f2e1c95e9d692e3ab1..62c490274aa92bf82aac304d9323250e3b728d0c 100644
--- a/scripts/lib/wic/ksparser.py
+++ b/scripts/lib/wic/ksparser.py
@@ -113,6 +113,9 @@ def systemidtype(arg):
class KickStart():
""""Kickstart parser implementation."""
+ DEFAULT_EXTRA_SPACE = 10*1024
+ DEFAULT_OVERHEAD_FACTOR = 1.3
+
def __init__(self, confpath):
self.partitions = []
@@ -127,16 +130,24 @@ class KickStart():
part.add_argument('mountpoint', nargs='?')
part.add_argument('--active', action='store_true')
part.add_argument('--align', type=int)
- part.add_argument("--extra-space", type=sizetype, default=10*1024)
+ part.add_argument("--extra-space", type=sizetype)
part.add_argument('--fsoptions', dest='fsopts')
part.add_argument('--fstype')
part.add_argument('--label')
part.add_argument('--no-table', action='store_true')
part.add_argument('--ondisk', '--ondrive', dest='disk')
- part.add_argument("--overhead-factor", type=overheadtype, default=1.3)
+ part.add_argument("--overhead-factor", type=overheadtype)
part.add_argument('--part-type')
part.add_argument('--rootfs-dir')
- part.add_argument('--size', type=sizetype, default=0)
+
+ # --size and --fixed-size cannot be specified together; options
+ # ----extra-space and --overhead-factor should also raise a parser
+ # --error, but since nesting mutually exclusive groups does not work,
+ # ----extra-space/--overhead-factor are handled later
+ sizeexcl = part.add_mutually_exclusive_group()
+ sizeexcl.add_argument('--size', type=sizetype, default=0)
+ sizeexcl.add_argument('--fixed-size', type=sizetype, default=0)
+
part.add_argument('--source')
part.add_argument('--sourceparams')
part.add_argument('--system-id', type=systemidtype)
@@ -170,11 +181,33 @@ class KickStart():
lineno += 1
if line and line[0] != '#':
try:
- parsed = parser.parse_args(shlex.split(line))
+ line_args = shlex.split(line)
+ parsed = parser.parse_args(line_args)
except ArgumentError as err:
raise KickStartError('%s:%d: %s' % \
(confpath, lineno, err))
if line.startswith('part'):
+ # using ArgumentParser one cannot easily tell if option
+ # was passed as argument, if said option has a default
+ # value; --overhead-factor/--extra-space cannot be used
+ # with --fixed-size, so at least detect when these were
+ # passed with non-0 values ...
+ if parsed.fixed_size:
+ if parsed.overhead_factor or parsed.extra_space:
+ err = "%s:%d: arguments --overhead-factor and --extra-space not "\
+ "allowed with argument --fixed-size" \
+ % (confpath, lineno)
+ raise KickStartError(err)
+ else:
+ # ... and provide defaults if not using
+ # --fixed-size iff given option was not used
+ # (again, one cannot tell if option was passed but
+ # with value equal to 0)
+ if '--overhead-factor' not in line_args:
+ parsed.overhead_factor = self.DEFAULT_OVERHEAD_FACTOR
+ if '--extra-space' not in line_args:
+ parsed.extra_space = self.DEFAULT_EXTRA_SPACE
+
self.partnum += 1
self.partitions.append(Partition(parsed, self.partnum))
elif line.startswith('include'):
diff --git a/scripts/lib/wic/partition.py b/scripts/lib/wic/partition.py
index ac4c836bdb53300d3a4e4c09926b7b1514b8faf2..8cf966ebc6d07490c44cefc93acbe5868be30ac7 100644
--- a/scripts/lib/wic/partition.py
+++ b/scripts/lib/wic/partition.py
@@ -54,6 +54,7 @@ class Partition():
self.part_type = args.part_type
self.rootfs_dir = args.rootfs_dir
self.size = args.size
+ self.fixed_size = args.fixed_size
self.source = args.source
self.sourceparams = args.sourceparams
self.system_id = args.system_id
@@ -87,6 +88,41 @@ class Partition():
else:
return 0
+ def get_rootfs_size(self, actual_rootfs_size=0):
+ """
+ Calculate the required size of rootfs taking into consideration
+ --size/--fixed-size flags as well as overhead and extra space, as
+ specified in kickstart file. Raises an error if the
+ `actual_rootfs_size` is larger than fixed-size rootfs.
+
+ """
+ if self.fixed_size:
+ rootfs_size = self.fixed_size
+ if actual_rootfs_size > rootfs_size:
+ msger.error("Actual rootfs size (%d kB) is larger than allowed size %d kB" \
+ %(actual_rootfs_size, rootfs_size))
+ else:
+ extra_blocks = self.get_extra_block_count(actual_rootfs_size)
+ if extra_blocks < self.extra_space:
+ extra_blocks = self.extra_space
+
+ rootfs_size = actual_rootfs_size + extra_blocks
+ rootfs_size *= self.overhead_factor
+
+ msger.debug("Added %d extra blocks to %s to get to %d total blocks" % \
+ (extra_blocks, self.mountpoint, rootfs_size))
+
+ return rootfs_size
+
+ @property
+ def disk_size(self):
+ """
+ Obtain on-disk size of partition taking into consideration
+ --size/--fixed-size options.
+
+ """
+ return self.fixed_size if self.fixed_size else self.size
+
def prepare(self, creator, cr_workdir, oe_builddir, rootfs_dir,
bootimg_dir, kernel_dir, native_sysroot):
"""
@@ -97,9 +133,9 @@ class Partition():
self.sourceparams_dict = parse_sourceparams(self.sourceparams)
if not self.source:
- if not self.size:
- msger.error("The %s partition has a size of zero. Please "
- "specify a non-zero --size for that partition." % \
+ if not self.size and not self.fixed_size:
+ msger.error("The %s partition has a size of zero. Please "
+ "specify a non-zero --size/--fixed-size for that partition." % \
self.mountpoint)
if self.fstype and self.fstype == "swap":
self.prepare_swap_partition(cr_workdir, oe_builddir,
@@ -146,6 +182,7 @@ class Partition():
oe_builddir,
bootimg_dir, kernel_dir, rootfs_dir,
native_sysroot)
+
# further processing required Partition.size to be an integer, make
# sure that it is one
if type(self.size) is not int:
@@ -153,6 +190,12 @@ class Partition():
"This a bug in source plugin %s and needs to be fixed." \
% (self.mountpoint, self.source))
+ if self.fixed_size and self.size > self.fixed_size:
+ msger.error("File system image of partition %s is larger (%d kB) than its"\
+ "allowed size %d kB" % (self.mountpoint,
+ self.size, self.fixed_size))
+
+
def prepare_rootfs_from_fs_image(self, cr_workdir, oe_builddir,
rootfs_dir):
"""
@@ -217,15 +260,7 @@ class Partition():
out = exec_cmd(du_cmd)
actual_rootfs_size = int(out.split()[0])
- extra_blocks = self.get_extra_block_count(actual_rootfs_size)
- if extra_blocks < self.extra_space:
- extra_blocks = self.extra_space
-
- rootfs_size = actual_rootfs_size + extra_blocks
- rootfs_size *= self.overhead_factor
-
- msger.debug("Added %d extra blocks to %s to get to %d total blocks" % \
- (extra_blocks, self.mountpoint, rootfs_size))
+ rootfs_size = self.get_rootfs_size(actual_rootfs_size)
with open(rootfs, 'w') as sparse:
os.ftruncate(sparse.fileno(), rootfs_size * 1024)
@@ -251,15 +286,7 @@ class Partition():
out = exec_cmd(du_cmd)
actual_rootfs_size = int(out.split()[0])
- extra_blocks = self.get_extra_block_count(actual_rootfs_size)
- if extra_blocks < self.extra_space:
- extra_blocks = self.extra_space
-
- rootfs_size = actual_rootfs_size + extra_blocks
- rootfs_size *= self.overhead_factor
-
- msger.debug("Added %d extra blocks to %s to get to %d total blocks" % \
- (extra_blocks, self.mountpoint, rootfs_size))
+ rootfs_size = self.get_rootfs_size(actual_rootfs_size)
with open(rootfs, 'w') as sparse:
os.ftruncate(sparse.fileno(), rootfs_size * 1024)
@@ -281,20 +308,13 @@ class Partition():
out = exec_cmd(du_cmd)
blocks = int(out.split()[0])
- extra_blocks = self.get_extra_block_count(blocks)
- if extra_blocks < self.extra_space:
- extra_blocks = self.extra_space
-
- blocks += extra_blocks
-
- msger.debug("Added %d extra blocks to %s to get to %d total blocks" % \
- (extra_blocks, self.mountpoint, blocks))
+ rootfs_size = self.get_rootfs_size(blocks)
label_str = "-n boot"
if self.label:
label_str = "-n %s" % self.label
- dosfs_cmd = "mkdosfs %s -S 512 -C %s %d" % (label_str, rootfs, blocks)
+ dosfs_cmd = "mkdosfs %s -S 512 -C %s %d" % (label_str, rootfs, rootfs_size)
exec_native_cmd(dosfs_cmd, native_sysroot)
mcopy_cmd = "mcopy -i %s -s %s/* ::/" % (rootfs, rootfs_dir)
@@ -317,8 +337,9 @@ class Partition():
"""
Prepare an empty ext2/3/4 partition.
"""
+ size = self.disk_size
with open(rootfs, 'w') as sparse:
- os.ftruncate(sparse.fileno(), self.size * 1024)
+ os.ftruncate(sparse.fileno(), size * 1024)
extra_imagecmd = "-i 8192"
@@ -335,8 +356,9 @@ class Partition():
"""
Prepare an empty btrfs partition.
"""
+ size = self.disk_size
with open(rootfs, 'w') as sparse:
- os.ftruncate(sparse.fileno(), self.size * 1024)
+ os.ftruncate(sparse.fileno(), size * 1024)
label_str = ""
if self.label:
@@ -351,7 +373,7 @@ class Partition():
"""
Prepare an empty vfat partition.
"""
- blocks = self.size
+ blocks = self.disk_size
label_str = "-n boot"
if self.label:
diff --git a/scripts/lib/wic/utils/partitionedfs.py b/scripts/lib/wic/utils/partitionedfs.py
index 9e76487844eebfffc7227d053a65dc9fdab3678b..cfa5f5ce09b764c1c2a9b7a3f7bf7d677a6811c4 100644
--- a/scripts/lib/wic/utils/partitionedfs.py
+++ b/scripts/lib/wic/utils/partitionedfs.py
@@ -209,7 +209,7 @@ class Image():
msger.debug("Assigned %s to %s%d, sectors range %d-%d size %d "
"sectors (%d bytes)." \
% (part['mountpoint'], part['disk_name'], part['num'],
- part['start'], part['start'] + part['size'] - 1,
+ part['start'], disk['offset'] - 1,
part['size'], part['size'] * self.sector_size))
# Once all the partitions have been layed out, we can calculate the
--
2.5.0
^ permalink raw reply related
* [PATCH v5 2/6] oeqa/utils/commands.py: allow use of binaries from native sysroot
From: Maciej Borzecki @ 2016-11-24 7:08 UTC (permalink / raw)
To: openembedded-core; +Cc: Paul Eggleton, Maciej Borzecki
In-Reply-To: <cover.1479971185.git.maciej.borzecki@rndity.com>
Tests may need to run a native tool that is not available on the host
filesystem, but can be built using one of the *-native recipes. In such case,
the tool will be available in native sysroot, and running in from that location
will require adjustments to PATH.
runCmd() can now take a path to native sysroot as one of its arguments and
setup PATH accordingly.
Signed-off-by: Maciej Borzecki <maciej.borzecki@rndity.com>
---
meta/lib/oeqa/utils/commands.py | 9 ++++++++-
1 file changed, 8 insertions(+), 1 deletion(-)
diff --git a/meta/lib/oeqa/utils/commands.py b/meta/lib/oeqa/utils/commands.py
index 5cd0f7477baa5bb45f2b2b5b93fb1ff0efd02923..657c9dba34ea9d42aa416f3b889f4b04129e8da9 100644
--- a/meta/lib/oeqa/utils/commands.py
+++ b/meta/lib/oeqa/utils/commands.py
@@ -97,9 +97,16 @@ class Result(object):
pass
-def runCmd(command, ignore_status=False, timeout=None, assert_error=True, **options):
+def runCmd(command, ignore_status=False, timeout=None, assert_error=True, native_sysroot=None, **options):
result = Result()
+ if native_sysroot:
+ extra_paths = "%s/sbin:%s/usr/sbin:%s/usr/bin" % \
+ (native_sysroot, native_sysroot, native_sysroot)
+ nenv = dict(options.get('env', os.environ))
+ nenv['PATH'] = extra_paths + ':' + nenv.get('PATH', '')
+ options['env'] = nenv
+
cmd = Command(command, timeout=timeout, **options)
cmd.run()
--
2.5.0
^ permalink raw reply related
* [PATCH v5 1/6] oe-selftest: enforce en_US.UTF-8 locale
From: Maciej Borzecki @ 2016-11-24 7:08 UTC (permalink / raw)
To: openembedded-core; +Cc: Paul Eggleton, Maciej Borzecki
In-Reply-To: <cover.1479971185.git.maciej.borzecki@rndity.com>
Replicate bitbake and eforce en_US.UTF-8 locale so that ouptut of locale-aware
tools remains stable.
Signed-off-by: Maciej Birzecki <maciej.borzecki@rndity.com>
Signed-off-by: Maciej Borzecki <maciej.borzecki@rndity.com>
---
scripts/oe-selftest | 3 +++
1 file changed, 3 insertions(+)
diff --git a/scripts/oe-selftest b/scripts/oe-selftest
index c3215ea6592e128d17da550d778272985f5bd1a6..deaa4324cc888ea261687f90f83e8759c4436a15 100755
--- a/scripts/oe-selftest
+++ b/scripts/oe-selftest
@@ -468,6 +468,9 @@ def main():
sys.path.extend(layer_libdirs)
imp.reload(oeqa.selftest)
+ # act like bitbake and enforce en_US.UTF-8 locale
+ os.environ["LC_ALL"] = "en_US.UTF-8"
+
if args.run_tests_by and len(args.run_tests_by) >= 2:
valid_options = ['name', 'class', 'module', 'id', 'tag']
if args.run_tests_by[0] not in valid_options:
--
2.5.0
^ permalink raw reply related
* [PATCH v5 0/6] wic: bugfixes & --fixed-size support, tests, oe-selftest: minor fixes
From: Maciej Borzecki @ 2016-11-24 7:08 UTC (permalink / raw)
To: openembedded-core; +Cc: Paul Eggleton, Maciej Borzecki
v5 of a patch series previously posted here [1].
Changes since v4:
* dropped `wic: selftest: do not repeat core-image-minimal` & rebased
dependant patches
* minor formatting fix in `wic: selftest: add tests for --fixed-size
partition flags`
[1]. http://lists.openembedded.org/pipermail/openembedded-core/2016-November/129103.html
Maciej Borzecki (6):
oe-selftest: enforce en_US.UTF-8 locale
oeqa/utils/commands.py: allow use of binaries from native sysroot
wic: add --fixed-size wks option
wic: selftest: avoid COMPATIBLE_HOST issues
wic: selftest: do not assume bzImage kernel image
wic: selftest: add tests for --fixed-size partition flags
meta/lib/oeqa/selftest/wic.py | 123 +++++++++++++++++++++++++++++++--
meta/lib/oeqa/utils/commands.py | 9 ++-
scripts/lib/wic/help.py | 14 +++-
scripts/lib/wic/imager/direct.py | 2 +-
scripts/lib/wic/ksparser.py | 41 +++++++++--
scripts/lib/wic/partition.py | 88 ++++++++++++++---------
scripts/lib/wic/utils/partitionedfs.py | 2 +-
scripts/oe-selftest | 3 +
8 files changed, 234 insertions(+), 48 deletions(-)
--
2.5.0
^ permalink raw reply
* Re: Contents of non-rootfs partitions
From: Ulrich Ölmann @ 2016-11-24 6:15 UTC (permalink / raw)
To: openembedded-core
In-Reply-To: <1479916616.31880.48.camel@intel.com>
Hi,
On Wed, Nov 23, 2016 at 04:56:56PM +0100, Patrick Ohly wrote:
> On Wed, 2016-11-23 at 15:22 +0200, Ed Bartosh wrote:
> > On Wed, Nov 23, 2016 at 02:08:28PM +0100, Kristian Amlie wrote:
> > > On 23/11/16 13:08, Ed Bartosh wrote:
> > > > On Tue, Nov 22, 2016 at 12:54:52PM +0100, Kristian Amlie wrote:
> > > > [...]
> > > > This can be done by extending existing rootfs plugin. It should be able
> > > > to do 2 things:
> > > >
> > > > - populate content of one rootfs directory to the partition. We can
> > > > extend syntax of --rootfs-dir parameter to specify optional directory path to use
> > > >
> > > > - exclude rootfs directories when populating partitions. I'd propose to
> > > > introduce --exclude-dirs wks parser option to handle this.
> > > >
> > > > Example of wks file with proposed new options:
> > > > part / --source rootfs --rootfs-dir=core-image-minimal --ondisk sda --fstype=ext4 --label root --align 1024 --exclude-dirs data --exclude-dirs home
> > > > part /data --source rootfs --rootfs-dir=core-image-minimal:/home --ondisk sda --fstype=ext4 --label data --align 1024
> > > > part /home --source rootfs --rootfs-dir=core-image-minimal:/data --ondisk sda --fstype=ext4 --label data --align 1024
> > > >
> > > > Does this make sense?
> > >
> > > Looks good. The only thing I would question is that, in the interest of
> > > reducing redundancy, maybe we should omit --exclude-dirs and have wic
> > > figure this out by combining all the entries, since "--exclude-dirs
> > > <dir>" and the corresponding "part <dir>" will almost always come in
> > > pairs. Possibly we could mark the "/" partition with one single
> > > --no-overlapping-dirs to force wic to make this consideration. Or do you
> > > think that's too magical?
> > >
> > Tt's quite implicit from my point of view. However, if people like it we
> > can implement it this way.
>
> I prefer the explicit --exclude-dirs. It's less surprising and perhaps
> there are usages for having the same content in different partitions
> (redundancy, factory reset, etc.).
>
> Excluding only the directory content but not the actual directory is
> indeed a good point. I'm a bit undecided. When excluding only the
> directory content, there's no way of building a rootfs without that
> mount point, if that's desired. OTOH, when excluding also the directory,
> the data would have to be staged under a different path in the rootfs
> and the mount point would have to be a separate, empty directory.
>
> I'm leaning towards excluding the directory content and keeping the
> directory.
what about having both possibilities by leaning against the syntax that rsync
uses to specify if a whole source directory or only it's contents shall be
synced to some destination site (see [1])?
In analogy to this to exclude only the contents of the directory named 'data'
you would use
--exclude-dirs data/
but to additionally exclude the dir itself as well it would read
--exclude-dirs data
Best regards
Ulrich
[1] http://man.cx/rsync(1)#heading6
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
^ permalink raw reply
* Re: [PATCH 2/2] base-passwd: set root's default password to 'root'
From: Robert Yang @ 2016-11-24 3:38 UTC (permalink / raw)
To: Paul Eggleton; +Cc: openembedded-core
In-Reply-To: <1525289.rQK3S6YPkZ@peggleto-mobl.ger.corp.intel.com>
On 11/24/2016 11:18 AM, Paul Eggleton wrote:
> On Thu, 24 Nov 2016 10:01:59 Robert Yang wrote:
>> On 11/23/2016 07:16 PM, Patrick Ohly wrote:
>>> On Tue, 2016-11-22 at 23:49 -0800, Robert Yang wrote:
>>>> [YOCTO #10710]
>>>>
>>>> Otherwise, we can't login as root when debug-tweaks is not in
>>>> IMAGE_FEATURES, and there is no other users to login by default, so
>>>> there is no way to login.
>>>
>>> Wait a second, are you really suggesting that OE-core should have a
>>> default root password in its default configuration?
>>>
>>> That's very bad practice and I'm against doing it this way. Having a
>>> default password is one of the common vulnerabilities in actual devices
>>> on the market today. OE-core should make it hard to make that mistake,
>>> not actively introduce it.
>>>
>>> So if you think that having a root password set (instead of empty), then
>>> at least make it an opt-in behavior that explicitly has to be selected.
>>> Make it an image feature so that images with and without default
>>> password can be build in the same build configuration. Changing
>>> base-passwd doesn't achieve that.
>>>
>>> Even then I'm still wondering what the benefit of a well-known password
>>> compared to no password is. Both are equally insecure, so someone who
>>> wants to allow logins might as well go with "empty password".
>>
>> The problem is that when debug-tweaks or empty-root-password is not in
>> IMAGE_FEATURE, there is no way to login by default, which will surprise
>> the user. How about:
>>
>> 1) Let user can set root passwd via a variable when building.
>>
>> Or/And
>>
>> 2) Warn the user at build time when the image is unable to login.
>
> There are problems with both of these:
>
> 1) I'm concerned that by making it trivially easy this will encourage users to
> set a root password and forget they have done so. This may lead to yet more
> products going out with default root passwords, and that is not a good thing.
>
> 2) Having no root password in this scenario is not necessarily a mistake, it
> may be intentional. If nobody ever needs to log into your device via a
> terminal, then why would you need a root password set at all? In that scenario
> you wouldn't want to be implying "this could be wrong, you should set a root
> password".
Hi Paul,
Currently, debug-tweaks is in EXTRA_IMAGE_FEATURES by default for poky, and
there is no passwd, so that user can login easily without a passwd, I think
that current status is more unsafe ? And when user realizes this, he
wants to add a passwd, but sorry, there is no easy way.
The anaconda installer's (used by Redhat) kickstart file can easily sets
a passwd, you can even set an un-encrypted password, are there many complains
about that ? When people can get your device (hardware), it's hard to prevent
people login you device.
// Robert
>
> If we need more documentation around this so that people understand how this
> aspect works (and I don't doubt that we do, people do ask about it) then by
> all means we should improved the documentation.
>
> Cheers,
> Paul
>
^ permalink raw reply
* Re: [PATCH 2/2] base-passwd: set root's default password to 'root'
From: Paul Eggleton @ 2016-11-24 3:18 UTC (permalink / raw)
To: Robert Yang; +Cc: openembedded-core
In-Reply-To: <adc8effe-1856-560a-a7fb-0d92138e1990@windriver.com>
On Thu, 24 Nov 2016 10:01:59 Robert Yang wrote:
> On 11/23/2016 07:16 PM, Patrick Ohly wrote:
> > On Tue, 2016-11-22 at 23:49 -0800, Robert Yang wrote:
> >> [YOCTO #10710]
> >>
> >> Otherwise, we can't login as root when debug-tweaks is not in
> >> IMAGE_FEATURES, and there is no other users to login by default, so
> >> there is no way to login.
> >
> > Wait a second, are you really suggesting that OE-core should have a
> > default root password in its default configuration?
> >
> > That's very bad practice and I'm against doing it this way. Having a
> > default password is one of the common vulnerabilities in actual devices
> > on the market today. OE-core should make it hard to make that mistake,
> > not actively introduce it.
> >
> > So if you think that having a root password set (instead of empty), then
> > at least make it an opt-in behavior that explicitly has to be selected.
> > Make it an image feature so that images with and without default
> > password can be build in the same build configuration. Changing
> > base-passwd doesn't achieve that.
> >
> > Even then I'm still wondering what the benefit of a well-known password
> > compared to no password is. Both are equally insecure, so someone who
> > wants to allow logins might as well go with "empty password".
>
> The problem is that when debug-tweaks or empty-root-password is not in
> IMAGE_FEATURE, there is no way to login by default, which will surprise
> the user. How about:
>
> 1) Let user can set root passwd via a variable when building.
>
> Or/And
>
> 2) Warn the user at build time when the image is unable to login.
There are problems with both of these:
1) I'm concerned that by making it trivially easy this will encourage users to
set a root password and forget they have done so. This may lead to yet more
products going out with default root passwords, and that is not a good thing.
2) Having no root password in this scenario is not necessarily a mistake, it
may be intentional. If nobody ever needs to log into your device via a
terminal, then why would you need a root password set at all? In that scenario
you wouldn't want to be implying "this could be wrong, you should set a root
password".
If we need more documentation around this so that people understand how this
aspect works (and I don't doubt that we do, people do ask about it) then by
all means we should improved the documentation.
Cheers,
Paul
--
Paul Eggleton
Intel Open Source Technology Centre
^ permalink raw reply
* Re: [PATCH] meta/conf/layer.conf: Add recommended download layer
From: Mark Hatle @ 2016-11-24 3:00 UTC (permalink / raw)
To: Christopher Larson; +Cc: Patches and discussions about the oe-core layer
In-Reply-To: <CABcZANkiNi_+p3p67YLJr_pcxQLrTWzoFfVDNgrFneUHPvyeBg@mail.gmail.com>
On 11/23/16 7:16 PM, Christopher Larson wrote:
> On Wed, Nov 23, 2016 at 12:42 PM, Mark Hatle <mark.hatle@windriver.com
> <mailto:mark.hatle@windriver.com>> wrote:
>
> On 11/23/16 12:56 PM, Martin Jansa wrote:
> > On Wed, Nov 23, 2016 at 12:38:42PM -0600, Mark Hatle wrote:
> >> On 11/23/16 12:10 PM, Martin Jansa wrote:
> >>> On Wed, Nov 23, 2016 at 11:42:09AM -0600, Mark Hatle wrote:
> >>>> This is a Wind River specific patch and not generally applicable.
> >>>
> >>> Then why is it sent to oe-core ML?
> >>
> >> As noted in the cover letter, I'm required to by Yocto Project compliance
> >> requirements.
> >>
> >> As indicated LAST time I got scolded, I was told to indicate this in the patch
> >> summary email -- which I did.
> >
> > Sorry I've noticed the cover letter only after the response.
> >
> > So it's only because of this requirement from Yocto Project compliance?
>
> yes.
>
> > "Have all patches applied to BitBake and OpenEmbedded-Core (if present)
> > been submitted to the open source community?"
> >
> > Shouldn't the wording be change to something like "all applicable
> > patches" or "all generally useful patches"?
> >
> > It seems strange to send project specific patches together with cover
> > saying that they aren't generally applicable and shouldn't be merged,
> > just because of this requirement.
>
> It was done this way to prevent people from cheating and claiming something was
> (effectively) not useful/applicable/etc when it some special secret sauce.
>
> Even these patches while not generally applicable could give someone else the
> idea to duplicate (or improve) on our approach at providing layer specific
> download layers.
>
>
> More of an implementation question, but presumably you could have your setup
> scripts add the LAYERRECOMMENDS to bblayers.conf, rather than having it in your
> oe-core fork/branch, as an alternative.
The recommends need to be indexed by the layer index program. The layer index
program processes one layer at a time, and there is no way to inject things.
I can manually add dependencies, however the next time I create a branch -- I
have to do this again... and again... and again.... For our product we need to
have the layer.conf setup properly so that the layer index will index the
dependencies (including the recommended layers.)
--Mark
> --
> Christopher Larson
> clarson at kergoth dot com
> Founder - BitBake, OpenEmbedded, OpenZaurus
> Maintainer - Tslib
> Senior Software Engineer, Mentor Graphics
^ permalink raw reply
* [PATCH 1/1] archiver.bbclass: fix can't create diff tarball
From: Dengke Du @ 2016-11-24 2:40 UTC (permalink / raw)
To: openembedded-core
In-Reply-To: <cover.1479955151.git.dengke.du@windriver.com>
When enable:
ARCHIVER_MODE[src] = "configured"
ARCHIVER_MODE[diff] = "1"
There is no "diff" tarball created, just "configured" tarball created, in log
file: log.do_unpack_and_patch, it said that directory doesn't exist.
This is because when enable "diff" and "configured", system use create_diff_gz and
do_ar_configured function respectively.
In do_ar_configured function, it use create_tarball function, and the create_tarball
use the function:
bb.utils.mkdirhier(ar_outdir)
So when creating "configured" tarball, there was no "directory doesn't exist" problem
and it was created successfully.
In create_diff_gz function, it didn't create the directory "ar_outdir", so it can't create
"diff" tarball, and throw the problem that directory doesn't exit.
So we should add the
bb.utils.mkdirhier(ar_outdir)
to function create_diff_gz in archiver.bbclass.
Signed-off-by: Dengke Du <dengke.du@windriver.com>
---
meta/classes/archiver.bbclass | 1 +
1 file changed, 1 insertion(+)
diff --git a/meta/classes/archiver.bbclass b/meta/classes/archiver.bbclass
index 9239983..abe6f2b 100644
--- a/meta/classes/archiver.bbclass
+++ b/meta/classes/archiver.bbclass
@@ -290,6 +290,7 @@ def create_diff_gz(d, src_orig, src, ar_outdir):
dirname = os.path.dirname(src)
basename = os.path.basename(src)
os.chdir(dirname)
+ bb.utils.mkdirhier(ar_outdir)
out_file = os.path.join(ar_outdir, '%s-diff.gz' % d.getVar('PF', True))
diff_cmd = 'diff -Naur %s.orig %s.patched | gzip -c > %s' % (basename, basename, out_file)
subprocess.call(diff_cmd, shell=True)
--
2.7.4
^ permalink raw reply related
* [PATCH 0/1] archiver.bbclass: fix can't create diff tarball
From: Dengke Du @ 2016-11-24 2:40 UTC (permalink / raw)
To: openembedded-core
The following changes since commit 12a0ee049e453b6d0d2ce2f3fa981d1b6e02bd78:
dev-manual: Added note about RPM not dealing with post-install (2016-11-23 11:10:35 +0000)
are available in the git repository at:
git://git.openembedded.org/openembedded-core-contrib dengke/fix-can-not-create-diff-tarball
http://cgit.openembedded.org/cgit.cgi/openembedded-core-contrib/log/?h=dengke/fix-can-not-create-diff-tarball
Dengke Du (1):
archiver.bbclass: fix can't create diff tarball
meta/classes/archiver.bbclass | 1 +
1 file changed, 1 insertion(+)
--
2.7.4
^ permalink raw reply
* Re: [PATCH 2/2] base-passwd: set root's default password to 'root'
From: Robert Yang @ 2016-11-24 2:01 UTC (permalink / raw)
To: Patrick Ohly; +Cc: openembedded-core
In-Reply-To: <1479899811.31880.37.camel@intel.com>
On 11/23/2016 07:16 PM, Patrick Ohly wrote:
> On Tue, 2016-11-22 at 23:49 -0800, Robert Yang wrote:
>> [YOCTO #10710]
>>
>> Otherwise, we can't login as root when debug-tweaks is not in
>> IMAGE_FEATURES, and there is no other users to login by default, so
>> there is no way to login.
>
> Wait a second, are you really suggesting that OE-core should have a
> default root password in its default configuration?
>
> That's very bad practice and I'm against doing it this way. Having a
> default password is one of the common vulnerabilities in actual devices
> on the market today. OE-core should make it hard to make that mistake,
> not actively introduce it.
>
> So if you think that having a root password set (instead of empty), then
> at least make it an opt-in behavior that explicitly has to be selected.
> Make it an image feature so that images with and without default
> password can be build in the same build configuration. Changing
> base-passwd doesn't achieve that.
>
> Even then I'm still wondering what the benefit of a well-known password
> compared to no password is. Both are equally insecure, so someone who
> wants to allow logins might as well go with "empty password".
The problem is that when debug-tweaks or empty-root-password is not in
IMAGE_FEATURE, there is no way to login by default, which will surprise
the user. How about:
1) Let user can set root passwd via a variable when building.
Or/And
2) Warn the user at build time when the image is unable to login.
// Robert
>
^ permalink raw reply
* [PATCH] webkitgtk: update to 2.14.2
From: Carlos Alberto Lopez Perez @ 2016-11-24 1:43 UTC (permalink / raw)
To: openembedded-core
Signed-off-by: Carlos Alberto Lopez Perez <clopez@igalia.com>
---
meta/recipes-sato/webkit/{webkitgtk_2.14.1.bb => webkitgtk_2.14.2.bb} | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
rename meta/recipes-sato/webkit/{webkitgtk_2.14.1.bb => webkitgtk_2.14.2.bb} (97%)
diff --git a/meta/recipes-sato/webkit/webkitgtk_2.14.1.bb b/meta/recipes-sato/webkit/webkitgtk_2.14.2.bb
similarity index 97%
rename from meta/recipes-sato/webkit/webkitgtk_2.14.1.bb
rename to meta/recipes-sato/webkit/webkitgtk_2.14.2.bb
index 1f2166c..373df17 100644
--- a/meta/recipes-sato/webkit/webkitgtk_2.14.1.bb
+++ b/meta/recipes-sato/webkit/webkitgtk_2.14.2.bb
@@ -20,8 +20,8 @@ SRC_URI = "http://www.webkitgtk.org/releases/${BPN}-${PV}.tar.xz \
file://0001-Tweak-gtkdoc-settings-so-that-gtkdoc-generation-work.patch \
"
-SRC_URI[md5sum] = "8d6c60dc41604d3bbd43165a674c07e5"
-SRC_URI[sha256sum] = "2e2d76c328de65bed6e0e4f096b2720a366654b27fc1af0830ece90bc4b7ceb5"
+SRC_URI[md5sum] = "2fe3cadbc546d93ca68a13756c2be015"
+SRC_URI[sha256sum] = "2edbcbd5105046aea55af9671c4de8deedb5b0e3567c618034d440a760675556"
inherit cmake pkgconfig gobject-introspection perlnative distro_features_check upstream-version-is-even gtk-doc
--
2.1.4
^ permalink raw reply related
* Re: [PATCH] meta/conf/layer.conf: Add recommended download layer
From: Christopher Larson @ 2016-11-24 1:16 UTC (permalink / raw)
To: Mark Hatle; +Cc: Patches and discussions about the oe-core layer
In-Reply-To: <f2e7d5d6-7094-10b6-16bc-9398c8bb828e@windriver.com>
[-- Attachment #1: Type: text/plain, Size: 2002 bytes --]
On Wed, Nov 23, 2016 at 12:42 PM, Mark Hatle <mark.hatle@windriver.com>
wrote:
> On 11/23/16 12:56 PM, Martin Jansa wrote:
> > On Wed, Nov 23, 2016 at 12:38:42PM -0600, Mark Hatle wrote:
> >> On 11/23/16 12:10 PM, Martin Jansa wrote:
> >>> On Wed, Nov 23, 2016 at 11:42:09AM -0600, Mark Hatle wrote:
> >>>> This is a Wind River specific patch and not generally applicable.
> >>>
> >>> Then why is it sent to oe-core ML?
> >>
> >> As noted in the cover letter, I'm required to by Yocto Project
> compliance
> >> requirements.
> >>
> >> As indicated LAST time I got scolded, I was told to indicate this in
> the patch
> >> summary email -- which I did.
> >
> > Sorry I've noticed the cover letter only after the response.
> >
> > So it's only because of this requirement from Yocto Project compliance?
>
> yes.
>
> > "Have all patches applied to BitBake and OpenEmbedded-Core (if present)
> > been submitted to the open source community?"
> >
> > Shouldn't the wording be change to something like "all applicable
> > patches" or "all generally useful patches"?
> >
> > It seems strange to send project specific patches together with cover
> > saying that they aren't generally applicable and shouldn't be merged,
> > just because of this requirement.
>
> It was done this way to prevent people from cheating and claiming
> something was
> (effectively) not useful/applicable/etc when it some special secret sauce.
>
> Even these patches while not generally applicable could give someone else
> the
> idea to duplicate (or improve) on our approach at providing layer specific
> download layers.
>
More of an implementation question, but presumably you could have your
setup scripts add the LAYERRECOMMENDS to bblayers.conf, rather than having
it in your oe-core fork/branch, as an alternative.
--
Christopher Larson
clarson at kergoth dot com
Founder - BitBake, OpenEmbedded, OpenZaurus
Maintainer - Tslib
Senior Software Engineer, Mentor Graphics
[-- Attachment #2: Type: text/html, Size: 2670 bytes --]
^ permalink raw reply
* [PATCH] classes: Fix alternatives and rc.d ordering
From: David Vincent @ 2016-11-23 23:54 UTC (permalink / raw)
To: openembedded-core
When using an alternative as an initscript, the ordering between
update-rc.d and update-alternatives tasks during prerm and postinst
tasks must always be the following in order to work:
* prerm:
- stop daemon
- remove alternative
* postinst:
- add alternative
- start daemon
This patchset adds comments to the scripts generated by both classes and
organize the generated sections based on those comments.
[YOCTO #10433]
Signed-off-by: David Vincent <freesilicon@gmail.com>
---
meta/classes/update-alternatives.bbclass | 27 +++++++++++++++++++++------
meta/classes/update-rc.d.bbclass | 20 ++++++++++++++++++--
2 files changed, 39 insertions(+), 8 deletions(-)
diff --git a/meta/classes/update-alternatives.bbclass
b/meta/classes/update-alternatives.bbclass
index 1fdd681..e84a6cd 100644
--- a/meta/classes/update-alternatives.bbclass
+++ b/meta/classes/update-alternatives.bbclass
@@ -195,8 +195,8 @@ python populate_packages_updatealternatives () {
pkgdest = d.getVar('PKGD', True)
for pkg in (d.getVar('PACKAGES', True) or "").split():
# Create post install/removal scripts
- alt_setup_links = ""
- alt_remove_links = ""
+ alt_setup_links = "# Begin section update-alternatives\n"
+ alt_remove_links = "# Begin section update-alternatives\n"
for alt_name in (d.getVar('ALTERNATIVE_%s' % pkg, True) or "").split():
alt_link = d.getVarFlag('ALTERNATIVE_LINK_NAME',
alt_name, True)
alt_target = d.getVarFlag('ALTERNATIVE_TARGET_%s' %
pkg, alt_name, True) or d.getVarFlag('ALTERNATIVE_TARGET', alt_name,
True)
@@ -219,8 +219,11 @@ python populate_packages_updatealternatives () {
# Default to generate shell script.. eventually we may
want to change this...
alt_target = os.path.normpath(alt_target)
- alt_setup_links += '\tupdate-alternatives --install %s
%s %s %s\n' % (alt_link, alt_name, alt_target, alt_priority)
- alt_remove_links += '\tupdate-alternatives --remove %s
%s\n' % (alt_name, alt_target)
+ alt_setup_links += 'update-alternatives --install %s %s
%s %s\n' % (alt_link, alt_name, alt_target, alt_priority)
+ alt_remove_links += 'update-alternatives --remove %s
%s\n' % (alt_name, alt_target)
+
+ alt_setup_links += "# End section update-alternatives\n"
+ alt_remove_links += "# End section update-alternatives\n"
if alt_setup_links:
# RDEPENDS setup
@@ -232,12 +235,24 @@ python populate_packages_updatealternatives () {
bb.note('adding update-alternatives calls to
postinst/prerm for %s' % pkg)
bb.note('%s' % alt_setup_links)
postinst = d.getVar('pkg_postinst_%s' % pkg, True) or '#!/bin/sh\n'
- postinst += alt_setup_links
+ postinst = postinst.splitlines(True)
+ try:
+ index = postinst.index('# Begin section update-rc.d\n')
+ postinst.insert(index, alt_setup_links)
+ except ValueError:
+ postinst.append(alt_setup_links)
+ postinst = ''.join(postinst)
d.setVar('pkg_postinst_%s' % pkg, postinst)
bb.note('%s' % alt_remove_links)
prerm = d.getVar('pkg_prerm_%s' % pkg, True) or '#!/bin/sh\n'
- prerm += alt_remove_links
+ prerm = prerm.splitlines(True)
+ try:
+ index = prerm.index('# End section update-rc.d\n')
+ prerm.insert(index + 1, alt_remove_links)
+ except ValueError:
+ prerm.append(alt_remove_links)
+ prerm = ''.join(prerm)
d.setVar('pkg_prerm_%s' % pkg, prerm)
}
diff --git a/meta/classes/update-rc.d.bbclass b/meta/classes/update-rc.d.bbclass
index 321924b..18df2dc 100644
--- a/meta/classes/update-rc.d.bbclass
+++ b/meta/classes/update-rc.d.bbclass
@@ -26,6 +26,7 @@ fi
}
updatercd_postinst() {
+# Begin section update-rc.d
if type update-rc.d >/dev/null 2>/dev/null; then
if [ -n "$D" ]; then
OPT="-r $D"
@@ -34,12 +35,15 @@ if type update-rc.d >/dev/null 2>/dev/null; then
fi
update-rc.d $OPT ${INITSCRIPT_NAME} ${INITSCRIPT_PARAMS}
fi
+# End section update-rc.d
}
updatercd_prerm() {
+# Begin section update-rc.d
if [ -z "$D" -a -x "${INIT_D_DIR}/${INITSCRIPT_NAME}" ]; then
${INIT_D_DIR}/${INITSCRIPT_NAME} stop || :
fi
+# End section update-rc.d
}
updatercd_postrm() {
@@ -102,13 +106,25 @@ python populate_packages_updatercd () {
postinst = d.getVar('pkg_postinst_%s' % pkg, True)
if not postinst:
postinst = '#!/bin/sh\n'
- postinst += localdata.getVar('updatercd_postinst', True)
+ postinst = postinst.splitlines(True)
+ try:
+ index = postinst.index('# End section update-alternatives\n')
+ postinst.insert(index + 1,
localdata.getVar('updatercd_postinst', True))
+ except ValueError:
+ postinst.append(localdata.getVar('updatercd_postinst', True))
+ postinst = ''.join(postinst)
d.setVar('pkg_postinst_%s' % pkg, postinst)
prerm = d.getVar('pkg_prerm_%s' % pkg, True)
if not prerm:
prerm = '#!/bin/sh\n'
- prerm += localdata.getVar('updatercd_prerm', True)
+ prerm = prerm.splitlines(True)
+ try:
+ index = prerm.index('# Begin section update-alternatives\n')
+ prerm.insert(index, localdata.getVar('updatercd_prerm', True))
+ except ValueError:
+ prerm.append(localdata.getVar('updatercd_prerm', True))
+ prerm = ''.join(prerm)
d.setVar('pkg_prerm_%s' % pkg, prerm)
postrm = d.getVar('pkg_postrm_%s' % pkg, True)
--
2.10.2
^ permalink raw reply related
* [PATCH v2] systemd-boot: Remove old gummiboot recipe, class and wks file
From: Alejandro Hernandez @ 2016-11-23 23:09 UTC (permalink / raw)
To: openembedded-core
Since the gummiboot project is no longer being maintained
and we are using systemd-boot as a replacement instead,
we can now clean up all remaining gummiboot files.
[YOCTO #10332]
Signed-off-by: Alejandro Hernandez <alejandro.hernandez@linux.intel.com>
---
meta/classes/gummiboot.bbclass | 121 ---------------------
...-C-syntax-errors-for-function-declaration.patch | 74 -------------
.../gummiboot/gummiboot/fix-objcopy.patch | 45 --------
meta/recipes-bsp/gummiboot/gummiboot_git.bb | 39 -------
scripts/lib/wic/canned-wks/mkgummidisk.wks | 11 --
5 files changed, 290 deletions(-)
delete mode 100644 meta/classes/gummiboot.bbclass
delete mode 100644 meta/recipes-bsp/gummiboot/gummiboot/0001-console-Fix-C-syntax-errors-for-function-declaration.patch
delete mode 100644 meta/recipes-bsp/gummiboot/gummiboot/fix-objcopy.patch
delete mode 100644 meta/recipes-bsp/gummiboot/gummiboot_git.bb
delete mode 100644 scripts/lib/wic/canned-wks/mkgummidisk.wks
diff --git a/meta/classes/gummiboot.bbclass b/meta/classes/gummiboot.bbclass
deleted file mode 100644
index 4f2dea6..0000000
--- a/meta/classes/gummiboot.bbclass
+++ /dev/null
@@ -1,121 +0,0 @@
-# Copyright (C) 2014 Intel Corporation
-#
-# Released under the MIT license (see COPYING.MIT)
-
-# gummiboot.bbclass - equivalent of grub-efi.bbclass
-# Set EFI_PROVIDER = "gummiboot" to use gummiboot on your live images instead of grub-efi
-# (images built by image-live.bbclass or image-vm.bbclass)
-
-do_bootimg[depends] += "${MLPREFIX}gummiboot:do_deploy"
-do_bootdirectdisk[depends] += "${MLPREFIX}gummiboot:do_deploy"
-
-EFIDIR = "/EFI/BOOT"
-
-GUMMIBOOT_CFG ?= "${S}/loader.conf"
-GUMMIBOOT_ENTRIES ?= ""
-GUMMIBOOT_TIMEOUT ?= "10"
-
-# Need UUID utility code.
-inherit fs-uuid
-
-efi_populate() {
- DEST=$1
-
- EFI_IMAGE="gummibootia32.efi"
- DEST_EFI_IMAGE="bootia32.efi"
- if [ "${TARGET_ARCH}" = "x86_64" ]; then
- EFI_IMAGE="gummibootx64.efi"
- DEST_EFI_IMAGE="bootx64.efi"
- fi
-
- install -d ${DEST}${EFIDIR}
- # gummiboot requires these paths for configuration files
- # they are not customizable so no point in new vars
- install -d ${DEST}/loader
- install -d ${DEST}/loader/entries
- install -m 0644 ${DEPLOY_DIR_IMAGE}/${EFI_IMAGE} ${DEST}${EFIDIR}/${DEST_EFI_IMAGE}
- EFIPATH=$(echo "${EFIDIR}" | sed 's/\//\\/g')
- printf 'fs0:%s\%s\n' "$EFIPATH" "$DEST_EFI_IMAGE" >${DEST}/startup.nsh
- install -m 0644 ${GUMMIBOOT_CFG} ${DEST}/loader/loader.conf
- for i in ${GUMMIBOOT_ENTRIES}; do
- install -m 0644 ${i} ${DEST}/loader/entries
- done
-}
-
-efi_iso_populate() {
- iso_dir=$1
- efi_populate $iso_dir
- mkdir -p ${EFIIMGDIR}/${EFIDIR}
- cp $iso_dir/${EFIDIR}/* ${EFIIMGDIR}${EFIDIR}
- cp $iso_dir/vmlinuz ${EFIIMGDIR}
- EFIPATH=$(echo "${EFIDIR}" | sed 's/\//\\/g')
- echo "fs0:${EFIPATH}\\${DEST_EFI_IMAGE}" > ${EFIIMGDIR}/startup.nsh
- if [ -f "$iso_dir/initrd" ] ; then
- cp $iso_dir/initrd ${EFIIMGDIR}
- fi
-}
-
-efi_hddimg_populate() {
- efi_populate $1
-}
-
-python build_efi_cfg() {
- s = d.getVar("S", True)
- labels = d.getVar('LABELS', True)
- if not labels:
- bb.debug(1, "LABELS not defined, nothing to do")
- return
-
- if labels == []:
- bb.debug(1, "No labels, nothing to do")
- return
-
- cfile = d.getVar('GUMMIBOOT_CFG', True)
- try:
- cfgfile = open(cfile, 'w')
- except OSError:
- bb.fatal('Unable to open %s' % cfile)
-
- cfgfile.write('# Automatically created by OE\n')
- cfgfile.write('default %s\n' % (labels.split()[0]))
- timeout = d.getVar('GUMMIBOOT_TIMEOUT', True)
- if timeout:
- cfgfile.write('timeout %s\n' % timeout)
- else:
- cfgfile.write('timeout 10\n')
- cfgfile.close()
-
- for label in labels.split():
- localdata = d.createCopy()
-
- overrides = localdata.getVar('OVERRIDES', True)
- if not overrides:
- bb.fatal('OVERRIDES not defined')
-
- entryfile = "%s/%s.conf" % (s, label)
- d.appendVar("GUMMIBOOT_ENTRIES", " " + entryfile)
- try:
- entrycfg = open(entryfile, "w")
- except OSError:
- bb.fatal('Unable to open %s' % entryfile)
- localdata.setVar('OVERRIDES', label + ':' + overrides)
- bb.data.update_data(localdata)
-
- entrycfg.write('title %s\n' % label)
- entrycfg.write('linux /vmlinuz\n')
-
- append = localdata.getVar('APPEND', True)
- initrd = localdata.getVar('INITRD', True)
-
- if initrd:
- entrycfg.write('initrd /initrd\n')
- lb = label
- if label == "install":
- lb = "install-efi"
- entrycfg.write('options LABEL=%s ' % lb)
- if append:
- append = replace_rootfs_uuid(d, append)
- entrycfg.write('%s' % append)
- entrycfg.write('\n')
- entrycfg.close()
-}
diff --git a/meta/recipes-bsp/gummiboot/gummiboot/0001-console-Fix-C-syntax-errors-for-function-declaration.patch b/meta/recipes-bsp/gummiboot/gummiboot/0001-console-Fix-C-syntax-errors-for-function-declaration.patch
deleted file mode 100644
index fa50bc4..0000000
--- a/meta/recipes-bsp/gummiboot/gummiboot/0001-console-Fix-C-syntax-errors-for-function-declaration.patch
+++ /dev/null
@@ -1,74 +0,0 @@
-From 55957faf1272c8f5f304909faeebf647a78e3701 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 9 Sep 2015 07:19:45 +0000
-Subject: [PATCH] console: Fix C syntax errors for function declaration
-
-To address this, the semicolons after the function parameters should be
-replaced by commas, and the last one should be omitted
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
-Upstream-Status: Pending
-
- src/efi/console.c | 26 +++++++++++++-------------
- 1 file changed, 13 insertions(+), 13 deletions(-)
-
-diff --git a/src/efi/console.c b/src/efi/console.c
-index 6206c80..66aa88f 100644
---- a/src/efi/console.c
-+++ b/src/efi/console.c
-@@ -27,8 +27,8 @@
- struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL;
-
- typedef EFI_STATUS (EFIAPI *EFI_INPUT_RESET_EX)(
-- struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This;
-- BOOLEAN ExtendedVerification;
-+ struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
-+ BOOLEAN ExtendedVerification
- );
-
- typedef UINT8 EFI_KEY_TOGGLE_STATE;
-@@ -44,29 +44,29 @@ typedef struct {
- } EFI_KEY_DATA;
-
- typedef EFI_STATUS (EFIAPI *EFI_INPUT_READ_KEY_EX)(
-- struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This;
-- EFI_KEY_DATA *KeyData;
-+ struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
-+ EFI_KEY_DATA *KeyData
- );
-
- typedef EFI_STATUS (EFIAPI *EFI_SET_STATE)(
-- struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This;
-- EFI_KEY_TOGGLE_STATE *KeyToggleState;
-+ struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
-+ EFI_KEY_TOGGLE_STATE *KeyToggleState
- );
-
- typedef EFI_STATUS (EFIAPI *EFI_KEY_NOTIFY_FUNCTION)(
-- EFI_KEY_DATA *KeyData;
-+ EFI_KEY_DATA *KeyData
- );
-
- typedef EFI_STATUS (EFIAPI *EFI_REGISTER_KEYSTROKE_NOTIFY)(
-- struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This;
-- EFI_KEY_DATA KeyData;
-- EFI_KEY_NOTIFY_FUNCTION KeyNotificationFunction;
-- VOID **NotifyHandle;
-+ struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
-+ EFI_KEY_DATA KeyData,
-+ EFI_KEY_NOTIFY_FUNCTION KeyNotificationFunction,
-+ VOID **NotifyHandle
- );
-
- typedef EFI_STATUS (EFIAPI *EFI_UNREGISTER_KEYSTROKE_NOTIFY)(
-- struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This;
-- VOID *NotificationHandle;
-+ struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
-+ VOID *NotificationHandle
- );
-
- typedef struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL {
---
-2.5.1
-
diff --git a/meta/recipes-bsp/gummiboot/gummiboot/fix-objcopy.patch b/meta/recipes-bsp/gummiboot/gummiboot/fix-objcopy.patch
deleted file mode 100644
index 49f5593..0000000
--- a/meta/recipes-bsp/gummiboot/gummiboot/fix-objcopy.patch
+++ /dev/null
@@ -1,45 +0,0 @@
-From 0f7f9e3bb1d0e1b93f3ad8a1d5d7bdd3fbf27494 Mon Sep 17 00:00:00 2001
-From: Robert Yang <liezhi.yang@windriver.com>
-Date: Thu, 27 Mar 2014 07:20:33 +0000
-Subject: [PATCH] Makefile.am: use objcopy from the env
-
-It uses the "objcopy" directly, which is not suitable for cross compile.
-
-Upstream-Status: Pending
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
----
- Makefile.am | 4 +++-
- 1 file changed, 3 insertions(+), 1 deletion(-)
-
-Index: git/Makefile.am
-===================================================================
---- git.orig/Makefile.am
-+++ git/Makefile.am
-@@ -19,6 +19,8 @@
- ACLOCAL_AMFLAGS = -I m4 ${ACLOCAL_FLAGS}
- AM_MAKEFLAGS = --no-print-directory
-
-+OBJCOPY ?= objcopy
-+
- gummibootlibdir = $(prefix)/lib/gummiboot
-
- AM_CPPFLAGS = -include config.h
-@@ -148,7 +150,7 @@ $(gummiboot_solib): $(gummiboot_objects)
- .DELETE_ON_ERROR: $(gummboot_solib)
-
- $(gummiboot): $(gummiboot_solib)
-- $(AM_V_GEN) objcopy -j .text -j .sdata -j .data -j .dynamic \
-+ $(AM_V_GEN) $(OBJCOPY) -j .text -j .sdata -j .data -j .dynamic \
- -j .dynsym -j .rel -j .rela -j .reloc \
- --target=efi-app-$(ARCH) $< $@
-
-@@ -183,7 +185,7 @@ $(stub_solib): $(stub_objects)
- .DELETE_ON_ERROR: $(gummboot_solib)
-
- $(stub): $(stub_solib)
-- $(AM_V_GEN) objcopy -j .text -j .sdata -j .data -j .dynamic \
-+ $(AM_V_GEN) $(OBJCOPY) -j .text -j .sdata -j .data -j .dynamic \
- -j .dynsym -j .rel -j .rela -j .reloc \
- --target=efi-app-$(ARCH) $< $@
-
diff --git a/meta/recipes-bsp/gummiboot/gummiboot_git.bb b/meta/recipes-bsp/gummiboot/gummiboot_git.bb
deleted file mode 100644
index c684b83..0000000
--- a/meta/recipes-bsp/gummiboot/gummiboot_git.bb
+++ /dev/null
@@ -1,39 +0,0 @@
-SUMMARY = "Gummiboot is a simple UEFI boot manager which executes configured EFI images."
-HOMEPAGE = "http://freedesktop.org/wiki/Software/gummiboot"
-
-LICENSE = "LGPLv2.1"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=4fbd65380cdd255951079008b364516c"
-
-DEPENDS = "gnu-efi util-linux"
-
-inherit autotools pkgconfig manpages
-inherit deploy
-
-PV = "48+git${SRCPV}"
-SRCREV = "2bcd919c681c952eb867ef1bdb458f1bc49c2d55"
-SRC_URI = "git://anongit.freedesktop.org/gummiboot \
- file://fix-objcopy.patch \
- file://0001-console-Fix-C-syntax-errors-for-function-declaration.patch \
- "
-
-PACKAGECONFIG[manpages] = "--enable-manpages, --disable-manpages, libxslt-native xmlto-native"
-
-# Note: Add COMPATIBLE_HOST here is only because it depends on gnu-efi
-# which has set the COMPATIBLE_HOST, the gummiboot itself may work on
-# more hosts.
-COMPATIBLE_HOST = "(x86_64.*|i.86.*)-linux"
-
-S = "${WORKDIR}/git"
-
-EXTRA_OECONF = "--with-efi-includedir=${STAGING_INCDIR} \
- --with-efi-ldsdir=${STAGING_LIBDIR} \
- --with-efi-libdir=${STAGING_LIBDIR}"
-
-EXTRA_OEMAKE += "gummibootlibdir=${libdir}/gummiboot"
-
-TUNE_CCARGS_remove = "-mfpmath=sse"
-
-do_deploy () {
- install ${B}/gummiboot*.efi ${DEPLOYDIR}
-}
-addtask deploy before do_build after do_compile
diff --git a/scripts/lib/wic/canned-wks/mkgummidisk.wks b/scripts/lib/wic/canned-wks/mkgummidisk.wks
deleted file mode 100644
index f3ae090..0000000
--- a/scripts/lib/wic/canned-wks/mkgummidisk.wks
+++ /dev/null
@@ -1,11 +0,0 @@
-# short-description: Create an EFI disk image
-# long-description: Creates a partitioned EFI disk image that the user
-# can directly dd to boot media.
-
-part /boot --source bootimg-efi --sourceparams="loader=gummiboot" --ondisk sda --label msdos --active --align 1024
-
-part / --source rootfs --ondisk sda --fstype=ext4 --label platform --align 1024
-
-part swap --ondisk sda --size 44 --label swap1 --fstype=swap
-
-bootloader --ptable gpt --timeout=5 --append="rootwait rootfstype=ext4 console=ttyS0,115200 console=tty0"
--
2.10.1
^ permalink raw reply related
* [PATCH 2/2] Remove old gummiboot recipe, class and wks file
From: Alejandro Hernandez @ 2016-11-23 23:08 UTC (permalink / raw)
To: openembedded-core
In-Reply-To: <cover.1479942307.git.alejandro.hernandez@linux.intel.com>
Since the gummiboot project is no longer being maintained
and we are using systemd-boot as a replacement instead,
we can now clean up all remaining gummiboot files.
[YOCTO #10332]
Signed-off-by: Alejandro Hernandez <alejandro.hernandez@linux.intel.com>
---
meta/classes/gummiboot.bbclass | 121 ---------------------
...-C-syntax-errors-for-function-declaration.patch | 74 -------------
.../gummiboot/gummiboot/fix-objcopy.patch | 45 --------
meta/recipes-bsp/gummiboot/gummiboot_git.bb | 39 -------
scripts/lib/wic/canned-wks/mkgummidisk.wks | 11 --
5 files changed, 290 deletions(-)
delete mode 100644 meta/classes/gummiboot.bbclass
delete mode 100644 meta/recipes-bsp/gummiboot/gummiboot/0001-console-Fix-C-syntax-errors-for-function-declaration.patch
delete mode 100644 meta/recipes-bsp/gummiboot/gummiboot/fix-objcopy.patch
delete mode 100644 meta/recipes-bsp/gummiboot/gummiboot_git.bb
delete mode 100644 scripts/lib/wic/canned-wks/mkgummidisk.wks
diff --git a/meta/classes/gummiboot.bbclass b/meta/classes/gummiboot.bbclass
deleted file mode 100644
index 4f2dea6..0000000
--- a/meta/classes/gummiboot.bbclass
+++ /dev/null
@@ -1,121 +0,0 @@
-# Copyright (C) 2014 Intel Corporation
-#
-# Released under the MIT license (see COPYING.MIT)
-
-# gummiboot.bbclass - equivalent of grub-efi.bbclass
-# Set EFI_PROVIDER = "gummiboot" to use gummiboot on your live images instead of grub-efi
-# (images built by image-live.bbclass or image-vm.bbclass)
-
-do_bootimg[depends] += "${MLPREFIX}gummiboot:do_deploy"
-do_bootdirectdisk[depends] += "${MLPREFIX}gummiboot:do_deploy"
-
-EFIDIR = "/EFI/BOOT"
-
-GUMMIBOOT_CFG ?= "${S}/loader.conf"
-GUMMIBOOT_ENTRIES ?= ""
-GUMMIBOOT_TIMEOUT ?= "10"
-
-# Need UUID utility code.
-inherit fs-uuid
-
-efi_populate() {
- DEST=$1
-
- EFI_IMAGE="gummibootia32.efi"
- DEST_EFI_IMAGE="bootia32.efi"
- if [ "${TARGET_ARCH}" = "x86_64" ]; then
- EFI_IMAGE="gummibootx64.efi"
- DEST_EFI_IMAGE="bootx64.efi"
- fi
-
- install -d ${DEST}${EFIDIR}
- # gummiboot requires these paths for configuration files
- # they are not customizable so no point in new vars
- install -d ${DEST}/loader
- install -d ${DEST}/loader/entries
- install -m 0644 ${DEPLOY_DIR_IMAGE}/${EFI_IMAGE} ${DEST}${EFIDIR}/${DEST_EFI_IMAGE}
- EFIPATH=$(echo "${EFIDIR}" | sed 's/\//\\/g')
- printf 'fs0:%s\%s\n' "$EFIPATH" "$DEST_EFI_IMAGE" >${DEST}/startup.nsh
- install -m 0644 ${GUMMIBOOT_CFG} ${DEST}/loader/loader.conf
- for i in ${GUMMIBOOT_ENTRIES}; do
- install -m 0644 ${i} ${DEST}/loader/entries
- done
-}
-
-efi_iso_populate() {
- iso_dir=$1
- efi_populate $iso_dir
- mkdir -p ${EFIIMGDIR}/${EFIDIR}
- cp $iso_dir/${EFIDIR}/* ${EFIIMGDIR}${EFIDIR}
- cp $iso_dir/vmlinuz ${EFIIMGDIR}
- EFIPATH=$(echo "${EFIDIR}" | sed 's/\//\\/g')
- echo "fs0:${EFIPATH}\\${DEST_EFI_IMAGE}" > ${EFIIMGDIR}/startup.nsh
- if [ -f "$iso_dir/initrd" ] ; then
- cp $iso_dir/initrd ${EFIIMGDIR}
- fi
-}
-
-efi_hddimg_populate() {
- efi_populate $1
-}
-
-python build_efi_cfg() {
- s = d.getVar("S", True)
- labels = d.getVar('LABELS', True)
- if not labels:
- bb.debug(1, "LABELS not defined, nothing to do")
- return
-
- if labels == []:
- bb.debug(1, "No labels, nothing to do")
- return
-
- cfile = d.getVar('GUMMIBOOT_CFG', True)
- try:
- cfgfile = open(cfile, 'w')
- except OSError:
- bb.fatal('Unable to open %s' % cfile)
-
- cfgfile.write('# Automatically created by OE\n')
- cfgfile.write('default %s\n' % (labels.split()[0]))
- timeout = d.getVar('GUMMIBOOT_TIMEOUT', True)
- if timeout:
- cfgfile.write('timeout %s\n' % timeout)
- else:
- cfgfile.write('timeout 10\n')
- cfgfile.close()
-
- for label in labels.split():
- localdata = d.createCopy()
-
- overrides = localdata.getVar('OVERRIDES', True)
- if not overrides:
- bb.fatal('OVERRIDES not defined')
-
- entryfile = "%s/%s.conf" % (s, label)
- d.appendVar("GUMMIBOOT_ENTRIES", " " + entryfile)
- try:
- entrycfg = open(entryfile, "w")
- except OSError:
- bb.fatal('Unable to open %s' % entryfile)
- localdata.setVar('OVERRIDES', label + ':' + overrides)
- bb.data.update_data(localdata)
-
- entrycfg.write('title %s\n' % label)
- entrycfg.write('linux /vmlinuz\n')
-
- append = localdata.getVar('APPEND', True)
- initrd = localdata.getVar('INITRD', True)
-
- if initrd:
- entrycfg.write('initrd /initrd\n')
- lb = label
- if label == "install":
- lb = "install-efi"
- entrycfg.write('options LABEL=%s ' % lb)
- if append:
- append = replace_rootfs_uuid(d, append)
- entrycfg.write('%s' % append)
- entrycfg.write('\n')
- entrycfg.close()
-}
diff --git a/meta/recipes-bsp/gummiboot/gummiboot/0001-console-Fix-C-syntax-errors-for-function-declaration.patch b/meta/recipes-bsp/gummiboot/gummiboot/0001-console-Fix-C-syntax-errors-for-function-declaration.patch
deleted file mode 100644
index fa50bc4..0000000
--- a/meta/recipes-bsp/gummiboot/gummiboot/0001-console-Fix-C-syntax-errors-for-function-declaration.patch
+++ /dev/null
@@ -1,74 +0,0 @@
-From 55957faf1272c8f5f304909faeebf647a78e3701 Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Wed, 9 Sep 2015 07:19:45 +0000
-Subject: [PATCH] console: Fix C syntax errors for function declaration
-
-To address this, the semicolons after the function parameters should be
-replaced by commas, and the last one should be omitted
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
-Upstream-Status: Pending
-
- src/efi/console.c | 26 +++++++++++++-------------
- 1 file changed, 13 insertions(+), 13 deletions(-)
-
-diff --git a/src/efi/console.c b/src/efi/console.c
-index 6206c80..66aa88f 100644
---- a/src/efi/console.c
-+++ b/src/efi/console.c
-@@ -27,8 +27,8 @@
- struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL;
-
- typedef EFI_STATUS (EFIAPI *EFI_INPUT_RESET_EX)(
-- struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This;
-- BOOLEAN ExtendedVerification;
-+ struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
-+ BOOLEAN ExtendedVerification
- );
-
- typedef UINT8 EFI_KEY_TOGGLE_STATE;
-@@ -44,29 +44,29 @@ typedef struct {
- } EFI_KEY_DATA;
-
- typedef EFI_STATUS (EFIAPI *EFI_INPUT_READ_KEY_EX)(
-- struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This;
-- EFI_KEY_DATA *KeyData;
-+ struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
-+ EFI_KEY_DATA *KeyData
- );
-
- typedef EFI_STATUS (EFIAPI *EFI_SET_STATE)(
-- struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This;
-- EFI_KEY_TOGGLE_STATE *KeyToggleState;
-+ struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
-+ EFI_KEY_TOGGLE_STATE *KeyToggleState
- );
-
- typedef EFI_STATUS (EFIAPI *EFI_KEY_NOTIFY_FUNCTION)(
-- EFI_KEY_DATA *KeyData;
-+ EFI_KEY_DATA *KeyData
- );
-
- typedef EFI_STATUS (EFIAPI *EFI_REGISTER_KEYSTROKE_NOTIFY)(
-- struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This;
-- EFI_KEY_DATA KeyData;
-- EFI_KEY_NOTIFY_FUNCTION KeyNotificationFunction;
-- VOID **NotifyHandle;
-+ struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
-+ EFI_KEY_DATA KeyData,
-+ EFI_KEY_NOTIFY_FUNCTION KeyNotificationFunction,
-+ VOID **NotifyHandle
- );
-
- typedef EFI_STATUS (EFIAPI *EFI_UNREGISTER_KEYSTROKE_NOTIFY)(
-- struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This;
-- VOID *NotificationHandle;
-+ struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
-+ VOID *NotificationHandle
- );
-
- typedef struct _EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL {
---
-2.5.1
-
diff --git a/meta/recipes-bsp/gummiboot/gummiboot/fix-objcopy.patch b/meta/recipes-bsp/gummiboot/gummiboot/fix-objcopy.patch
deleted file mode 100644
index 49f5593..0000000
--- a/meta/recipes-bsp/gummiboot/gummiboot/fix-objcopy.patch
+++ /dev/null
@@ -1,45 +0,0 @@
-From 0f7f9e3bb1d0e1b93f3ad8a1d5d7bdd3fbf27494 Mon Sep 17 00:00:00 2001
-From: Robert Yang <liezhi.yang@windriver.com>
-Date: Thu, 27 Mar 2014 07:20:33 +0000
-Subject: [PATCH] Makefile.am: use objcopy from the env
-
-It uses the "objcopy" directly, which is not suitable for cross compile.
-
-Upstream-Status: Pending
-
-Signed-off-by: Robert Yang <liezhi.yang@windriver.com>
----
- Makefile.am | 4 +++-
- 1 file changed, 3 insertions(+), 1 deletion(-)
-
-Index: git/Makefile.am
-===================================================================
---- git.orig/Makefile.am
-+++ git/Makefile.am
-@@ -19,6 +19,8 @@
- ACLOCAL_AMFLAGS = -I m4 ${ACLOCAL_FLAGS}
- AM_MAKEFLAGS = --no-print-directory
-
-+OBJCOPY ?= objcopy
-+
- gummibootlibdir = $(prefix)/lib/gummiboot
-
- AM_CPPFLAGS = -include config.h
-@@ -148,7 +150,7 @@ $(gummiboot_solib): $(gummiboot_objects)
- .DELETE_ON_ERROR: $(gummboot_solib)
-
- $(gummiboot): $(gummiboot_solib)
-- $(AM_V_GEN) objcopy -j .text -j .sdata -j .data -j .dynamic \
-+ $(AM_V_GEN) $(OBJCOPY) -j .text -j .sdata -j .data -j .dynamic \
- -j .dynsym -j .rel -j .rela -j .reloc \
- --target=efi-app-$(ARCH) $< $@
-
-@@ -183,7 +185,7 @@ $(stub_solib): $(stub_objects)
- .DELETE_ON_ERROR: $(gummboot_solib)
-
- $(stub): $(stub_solib)
-- $(AM_V_GEN) objcopy -j .text -j .sdata -j .data -j .dynamic \
-+ $(AM_V_GEN) $(OBJCOPY) -j .text -j .sdata -j .data -j .dynamic \
- -j .dynsym -j .rel -j .rela -j .reloc \
- --target=efi-app-$(ARCH) $< $@
-
diff --git a/meta/recipes-bsp/gummiboot/gummiboot_git.bb b/meta/recipes-bsp/gummiboot/gummiboot_git.bb
deleted file mode 100644
index c684b83..0000000
--- a/meta/recipes-bsp/gummiboot/gummiboot_git.bb
+++ /dev/null
@@ -1,39 +0,0 @@
-SUMMARY = "Gummiboot is a simple UEFI boot manager which executes configured EFI images."
-HOMEPAGE = "http://freedesktop.org/wiki/Software/gummiboot"
-
-LICENSE = "LGPLv2.1"
-LIC_FILES_CHKSUM = "file://LICENSE;md5=4fbd65380cdd255951079008b364516c"
-
-DEPENDS = "gnu-efi util-linux"
-
-inherit autotools pkgconfig manpages
-inherit deploy
-
-PV = "48+git${SRCPV}"
-SRCREV = "2bcd919c681c952eb867ef1bdb458f1bc49c2d55"
-SRC_URI = "git://anongit.freedesktop.org/gummiboot \
- file://fix-objcopy.patch \
- file://0001-console-Fix-C-syntax-errors-for-function-declaration.patch \
- "
-
-PACKAGECONFIG[manpages] = "--enable-manpages, --disable-manpages, libxslt-native xmlto-native"
-
-# Note: Add COMPATIBLE_HOST here is only because it depends on gnu-efi
-# which has set the COMPATIBLE_HOST, the gummiboot itself may work on
-# more hosts.
-COMPATIBLE_HOST = "(x86_64.*|i.86.*)-linux"
-
-S = "${WORKDIR}/git"
-
-EXTRA_OECONF = "--with-efi-includedir=${STAGING_INCDIR} \
- --with-efi-ldsdir=${STAGING_LIBDIR} \
- --with-efi-libdir=${STAGING_LIBDIR}"
-
-EXTRA_OEMAKE += "gummibootlibdir=${libdir}/gummiboot"
-
-TUNE_CCARGS_remove = "-mfpmath=sse"
-
-do_deploy () {
- install ${B}/gummiboot*.efi ${DEPLOYDIR}
-}
-addtask deploy before do_build after do_compile
diff --git a/scripts/lib/wic/canned-wks/mkgummidisk.wks b/scripts/lib/wic/canned-wks/mkgummidisk.wks
deleted file mode 100644
index f3ae090..0000000
--- a/scripts/lib/wic/canned-wks/mkgummidisk.wks
+++ /dev/null
@@ -1,11 +0,0 @@
-# short-description: Create an EFI disk image
-# long-description: Creates a partitioned EFI disk image that the user
-# can directly dd to boot media.
-
-part /boot --source bootimg-efi --sourceparams="loader=gummiboot" --ondisk sda --label msdos --active --align 1024
-
-part / --source rootfs --ondisk sda --fstype=ext4 --label platform --align 1024
-
-part swap --ondisk sda --size 44 --label swap1 --fstype=swap
-
-bootloader --ptable gpt --timeout=5 --append="rootwait rootfstype=ext4 console=ttyS0,115200 console=tty0"
--
2.10.1
^ permalink raw reply related
* [PATCH 1/2] systemd-boot: Completely replaces gummiboot with systemd-boot
From: Alejandro Hernandez @ 2016-11-23 23:08 UTC (permalink / raw)
To: openembedded-core
In-Reply-To: <cover.1479942307.git.alejandro.hernandez@linux.intel.com>
After systemd-boot was introduced, its been tested for a while with no major
issues being found until now, this patch completely replaces all gummiboot
instances with systemd-boot ones, taking the next step into cleaning
up systemd-boot/gummiboot.
[YOCTO #10332]
Signed-off-by: Alejandro Hernandez <alejandro.hernandez@linux.intel.com>
---
meta/classes/fs-uuid.bbclass | 2 +-
meta/classes/systemd-boot.bbclass | 4 +---
meta/conf/distro/include/distro_alias.inc | 2 +-
meta/lib/oeqa/controllers/masterimage.py | 4 ++--
meta/lib/oeqa/selftest/wic.py | 6 ++---
meta/recipes-bsp/systemd-boot/systemd-boot.bb | 2 +-
.../initrdscripts/files/init-install-efi-testfs.sh | 12 +++++-----
.../initrdscripts/files/init-install-efi.sh | 12 +++++-----
scripts/contrib/mkefidisk.sh | 26 +++++++++++-----------
scripts/lib/wic/plugins/source/bootimg-efi.py | 22 +++++++++---------
10 files changed, 44 insertions(+), 48 deletions(-)
diff --git a/meta/classes/fs-uuid.bbclass b/meta/classes/fs-uuid.bbclass
index bd2613c..1d5d0c3 100644
--- a/meta/classes/fs-uuid.bbclass
+++ b/meta/classes/fs-uuid.bbclass
@@ -13,7 +13,7 @@ def get_rootfs_uuid(d):
bb.fatal('Could not determine filesystem UUID of %s' % rootfs)
# Replace the special <<uuid-of-rootfs>> inside a string (like the
-# root= APPEND string in a syslinux.cfg or gummiboot entry) with the
+# root= APPEND string in a syslinux.cfg or systemd-boot entry) with the
# actual UUID of the rootfs. Does nothing if the special string
# is not used.
def replace_rootfs_uuid(d, string):
diff --git a/meta/classes/systemd-boot.bbclass b/meta/classes/systemd-boot.bbclass
index 05244c7..3398218 100644
--- a/meta/classes/systemd-boot.bbclass
+++ b/meta/classes/systemd-boot.bbclass
@@ -4,9 +4,7 @@
# systemd-boot.bbclass - The "systemd-boot" is essentially the gummiboot merged into systemd.
# The original standalone gummiboot project is dead without any more
-# maintenance. As a start point, we replace all gummitboot occurrences
-# with systemd-boot in gummiboot.bbclass to have a base version of this
-# systemd-boot.bbclass.
+# maintenance.
#
# Set EFI_PROVIDER = "systemd-boot" to use systemd-boot on your live images instead of grub-efi
# (images built by image-live.bbclass or image-vm.bbclass)
diff --git a/meta/conf/distro/include/distro_alias.inc b/meta/conf/distro/include/distro_alias.inc
index 10efb09..9c82854 100644
--- a/meta/conf/distro/include/distro_alias.inc
+++ b/meta/conf/distro/include/distro_alias.inc
@@ -135,7 +135,7 @@ DISTRO_PN_ALIAS_pn-gtk-doc = "Fedora=gtk-doc Ubuntu=gtk-doc"
DISTRO_PN_ALIAS_pn-gtk-engines = "Fedora=gtk2-engines OpenSuSE=gtk2-engines Ubuntu=gtk2-engines Mandriva=gtk-engines2 Debian=gtk2-engines"
DISTRO_PN_ALIAS_pn-gtk-sato-engine = "OpenedHand"
DISTRO_PN_ALIAS_pn-gtk-icon-utils-native = "OSPDT"
-DISTRO_PN_ALIAS_pn-gummiboot = "Debian=gummiboot Fedora=gummiboot"
+DISTRO_PN_ALIAS_pn-systemd-boot = "Ubuntu=systemd-boot Fedora=systemd-boot"
DISTRO_PN_ALIAS_pn-hello-mod = "OE-Core"
DISTRO_PN_ALIAS_pn-hostap-conf = "OE-Core"
DISTRO_PN_ALIAS_pn-hwlatdetect = "OSPDT"
diff --git a/meta/lib/oeqa/controllers/masterimage.py b/meta/lib/oeqa/controllers/masterimage.py
index 9ce3bf8..7fcbb6d 100644
--- a/meta/lib/oeqa/controllers/masterimage.py
+++ b/meta/lib/oeqa/controllers/masterimage.py
@@ -159,10 +159,10 @@ class MasterImageHardwareTarget(oeqa.targetcontrol.BaseTarget, metaclass=ABCMeta
self.power_cycle(self.connection)
-class GummibootTarget(MasterImageHardwareTarget):
+class SystemdbootTarget(MasterImageHardwareTarget):
def __init__(self, d):
- super(GummibootTarget, self).__init__(d)
+ super(SystemdbootTarget, self).__init__(d)
# this the value we need to set in the LoaderEntryOneShot EFI variable
# so the system boots the 'test' bootloader label and not the default
# The first four bytes are EFI bits, and the rest is an utf-16le string
diff --git a/meta/lib/oeqa/selftest/wic.py b/meta/lib/oeqa/selftest/wic.py
index faac11e..61081cc 100644
--- a/meta/lib/oeqa/selftest/wic.py
+++ b/meta/lib/oeqa/selftest/wic.py
@@ -243,9 +243,9 @@ class Wic(oeSelfTest):
self.assertEqual(1, len(glob(self.resultdir + "%s-*direct" % image)))
@testcase(1349)
- def test_mkgummidisk(self):
- """Test creation of mkgummidisk image"""
- image = "mkgummidisk"
+ def test_systemd-bootdisk(self):
+ """Test creation of systemd-bootdisk image"""
+ image = "systemd-bootdisk"
self.assertEqual(0, runCmd("wic create %s -e core-image-minimal" \
% image).status)
self.assertEqual(1, len(glob(self.resultdir + "%s-*direct" % image)))
diff --git a/meta/recipes-bsp/systemd-boot/systemd-boot.bb b/meta/recipes-bsp/systemd-boot/systemd-boot.bb
index 7036664..602052c 100644
--- a/meta/recipes-bsp/systemd-boot/systemd-boot.bb
+++ b/meta/recipes-bsp/systemd-boot/systemd-boot.bb
@@ -15,7 +15,7 @@ EXTRA_OECONF = " --enable-gnuefi \
--disable-manpages \
"
-# Imported from gummiboot recipe
+# Imported from the old gummiboot recipe
TUNE_CCARGS_remove = "-mfpmath=sse"
COMPATIBLE_HOST = "(x86_64.*|i.86.*)-linux"
diff --git a/meta/recipes-core/initrdscripts/files/init-install-efi-testfs.sh b/meta/recipes-core/initrdscripts/files/init-install-efi-testfs.sh
index b562109..9c4b263 100644
--- a/meta/recipes-core/initrdscripts/files/init-install-efi-testfs.sh
+++ b/meta/recipes-core/initrdscripts/files/init-install-efi-testfs.sh
@@ -171,19 +171,19 @@ if [ -f /run/media/$1/EFI/BOOT/grub.cfg ]; then
fi
if [ -d /run/media/$1/loader ]; then
- GUMMIBOOT_CFGS="/ssd/loader/entries/*.conf"
- # copy config files for gummiboot
+ SYSTEMDBOOT_CFGS="/ssd/loader/entries/*.conf"
+ # copy config files for systemd-boot
cp -dr /run/media/$1/loader /ssd
# delete the install entry
rm -f /ssd/loader/entries/install.conf
# delete the initrd lines
- sed -i "/initrd /d" $GUMMIBOOT_CFGS
+ sed -i "/initrd /d" $SYSTEMDBOOT_CFGS
# delete any LABEL= strings
- sed -i "s/ LABEL=[^ ]*/ /" $GUMMIBOOT_CFGS
+ sed -i "s/ LABEL=[^ ]*/ /" $SYSTEMDBOOT_CFGS
# delete any root= strings
- sed -i "s/ root=[^ ]*/ /" $GUMMIBOOT_CFGS
+ sed -i "s/ root=[^ ]*/ /" $SYSTEMDBOOT_CFGS
# add the root= and other standard boot options
- sed -i "s@options *@options root=$rootfs rw $rootwait quiet @" $GUMMIBOOT_CFGS
+ sed -i "s@options *@options root=$rootfs rw $rootwait quiet @" $SYSTEMDBOOT_CFGS
# Add the test label
echo -ne "title test\nlinux /test-kernel\noptions root=$testfs rw $rootwait quiet\n" > /ssd/loader/entries/test.conf
fi
diff --git a/meta/recipes-core/initrdscripts/files/init-install-efi.sh b/meta/recipes-core/initrdscripts/files/init-install-efi.sh
index ffb709c..5ad3a60 100644
--- a/meta/recipes-core/initrdscripts/files/init-install-efi.sh
+++ b/meta/recipes-core/initrdscripts/files/init-install-efi.sh
@@ -245,19 +245,19 @@ fi
if [ -d /run/media/$1/loader ]; then
rootuuid=$(blkid -o value -s PARTUUID ${rootfs})
- GUMMIBOOT_CFGS="/boot/loader/entries/*.conf"
- # copy config files for gummiboot
+ SYSTEMDBOOT_CFGS="/boot/loader/entries/*.conf"
+ # copy config files for systemd-boot
cp -dr /run/media/$1/loader /boot
# delete the install entry
rm -f /boot/loader/entries/install.conf
# delete the initrd lines
- sed -i "/initrd /d" $GUMMIBOOT_CFGS
+ sed -i "/initrd /d" $SYSTEMDBOOT_CFGS
# delete any LABEL= strings
- sed -i "s/ LABEL=[^ ]*/ /" $GUMMIBOOT_CFGS
+ sed -i "s/ LABEL=[^ ]*/ /" $SYSTEMDBOOT_CFGS
# delete any root= strings
- sed -i "s/ root=[^ ]*/ /" $GUMMIBOOT_CFGS
+ sed -i "s/ root=[^ ]*/ /" $SYSTEMDBOOT_CFGS
# add the root= and other standard boot options
- sed -i "s@options *@options root=PARTUUID=$rootuuid rw $rootwait quiet @" $GUMMIBOOT_CFGS
+ sed -i "s@options *@options root=PARTUUID=$rootuuid rw $rootwait quiet @" $SYSTEMDBOOT_CFGS
fi
umount /tgt_root
diff --git a/scripts/contrib/mkefidisk.sh b/scripts/contrib/mkefidisk.sh
index a175895..800733f 100755
--- a/scripts/contrib/mkefidisk.sh
+++ b/scripts/contrib/mkefidisk.sh
@@ -384,7 +384,7 @@ EFIDIR="$BOOTFS_MNT/EFI/BOOT"
cp $HDDIMG_MNT/vmlinuz $BOOTFS_MNT >$OUT 2>&1 || error "Failed to copy vmlinuz"
# Copy the efi loader and configs (booti*.efi and grub.cfg if it exists)
cp -r $HDDIMG_MNT/EFI $BOOTFS_MNT >$OUT 2>&1 || error "Failed to copy EFI dir"
-# Silently ignore a missing gummiboot loader dir (we might just be a GRUB image)
+# Silently ignore a missing systemd-boot loader dir (we might just be a GRUB image)
cp -r $HDDIMG_MNT/loader $BOOTFS_MNT >$OUT 2>&1
# Update the boot loaders configurations for an installed image
@@ -410,25 +410,25 @@ if [ -e "$GRUB_CFG" ]; then
sed -i "s@vmlinuz @vmlinuz root=$TARGET_ROOTFS ro rootwait console=ttyS0 console=tty0 @" $GRUB_CFG
fi
-# Look for a gummiboot installation
-GUMMI_ENTRIES="$BOOTFS_MNT/loader/entries"
-GUMMI_CFG="$GUMMI_ENTRIES/boot.conf"
-if [ -d "$GUMMI_ENTRIES" ]; then
- info "Configuring Gummiboot"
+# Look for a systemd-boot installation
+SYSTEMD_BOOT_ENTRIES="$BOOTFS_MNT/loader/entries"
+SYSTEMD_BOOT_CFG="$SYSTEMD_BOOT_ENTRIES/boot.conf"
+if [ -d "$SYSTEMD_BOOT_ENTRIES" ]; then
+ info "Configuring SystemD-boot"
# remove the install target if it exists
- rm $GUMMI_ENTRIES/install.conf >$OUT 2>&1
+ rm $SYSTEMD_BOOT_ENTRIES/install.conf >$OUT 2>&1
- if [ ! -e "$GUMMI_CFG" ]; then
- echo "ERROR: $GUMMI_CFG not found"
+ if [ ! -e "$SYSTEMD_BOOT_CFG" ]; then
+ echo "ERROR: $SYSTEMD_BOOT_CFG not found"
fi
- sed -i "/initrd /d" $GUMMI_CFG
- sed -i "s@ root=[^ ]*@ @" $GUMMI_CFG
- sed -i "s@options *LABEL=boot @options LABEL=Boot root=$TARGET_ROOTFS ro rootwait console=ttyS0 console=tty0 @" $GUMMI_CFG
+ sed -i "/initrd /d" $SYSTEMD_BOOT_CFG
+ sed -i "s@ root=[^ ]*@ @" $SYSTEMD_BOOT_CFG
+ sed -i "s@options *LABEL=boot @options LABEL=Boot root=$TARGET_ROOTFS ro rootwait console=ttyS0 console=tty0 @" $SYSTEMD_BOOT_CFG
fi
# Ensure we have at least one EFI bootloader configured
-if [ ! -e $GRUB_CFG ] && [ ! -e $GUMMI_CFG ]; then
+if [ ! -e $GRUB_CFG ] && [ ! -e $SYSTEMD_BOOT_CFG ]; then
die "No EFI bootloader configuration found"
fi
diff --git a/scripts/lib/wic/plugins/source/bootimg-efi.py b/scripts/lib/wic/plugins/source/bootimg-efi.py
index 4adb80b..305e910 100644
--- a/scripts/lib/wic/plugins/source/bootimg-efi.py
+++ b/scripts/lib/wic/plugins/source/bootimg-efi.py
@@ -36,7 +36,7 @@ from wic.utils.oe.misc import exec_cmd, exec_native_cmd, get_bitbake_var, \
class BootimgEFIPlugin(SourcePlugin):
"""
Create EFI boot partition.
- This plugin supports GRUB 2 and gummiboot bootloaders.
+ This plugin supports GRUB 2 and systemd-boot bootloaders.
"""
name = 'bootimg-efi'
@@ -82,7 +82,7 @@ class BootimgEFIPlugin(SourcePlugin):
cfg.close()
@classmethod
- def do_configure_gummiboot(cls, hdddir, creator, cr_workdir):
+ def do_configure_systemdboot(cls, hdddir, creator, cr_workdir):
"""
Create loader-specific systemd-boot/gummiboot config
"""
@@ -98,7 +98,7 @@ class BootimgEFIPlugin(SourcePlugin):
loader_conf += "default boot\n"
loader_conf += "timeout %d\n" % bootloader.timeout
- msger.debug("Writing gummiboot config %s/hdd/boot/loader/loader.conf" \
+ msger.debug("Writing systemd-boot config %s/hdd/boot/loader/loader.conf" \
% cr_workdir)
cfg = open("%s/hdd/boot/loader/loader.conf" % cr_workdir, "w")
cfg.write(loader_conf)
@@ -109,16 +109,16 @@ class BootimgEFIPlugin(SourcePlugin):
if configfile:
custom_cfg = get_custom_config(configfile)
if custom_cfg:
- # Use a custom configuration for gummiboot
+ # Use a custom configuration for systemd-boot
boot_conf = custom_cfg
msger.debug("Using custom configuration file "
- "%s for gummiboots's boot.conf" % configfile)
+ "%s for systemd-boots's boot.conf" % configfile)
else:
msger.error("configfile is specified but failed to "
"get it from %s." % configfile)
if not custom_cfg:
- # Create gummiboot configuration using parameters from wks file
+ # Create systemd-boot configuration using parameters from wks file
kernel = "/bzImage"
boot_conf = ""
@@ -127,7 +127,7 @@ class BootimgEFIPlugin(SourcePlugin):
boot_conf += "options LABEL=Boot root=%s %s\n" % \
(creator.rootdev, bootloader.append)
- msger.debug("Writing gummiboot config %s/hdd/boot/loader/entries/boot.conf" \
+ msger.debug("Writing systemd-boot config %s/hdd/boot/loader/entries/boot.conf" \
% cr_workdir)
cfg = open("%s/hdd/boot/loader/entries/boot.conf" % cr_workdir, "w")
cfg.write(boot_conf)
@@ -149,9 +149,8 @@ class BootimgEFIPlugin(SourcePlugin):
try:
if source_params['loader'] == 'grub-efi':
cls.do_configure_grubefi(hdddir, creator, cr_workdir)
- elif source_params['loader'] == 'gummiboot' \
- or source_params['loader'] == 'systemd-boot':
- cls.do_configure_gummiboot(hdddir, creator, cr_workdir)
+ elif source_params['loader'] == 'systemd-boot':
+ cls.do_configure_systemdboot(hdddir, creator, cr_workdir)
else:
msger.error("unrecognized bootimg-efi loader: %s" % source_params['loader'])
except KeyError:
@@ -190,8 +189,7 @@ class BootimgEFIPlugin(SourcePlugin):
exec_cmd(cp_cmd, True)
shutil.move("%s/grub.cfg" % cr_workdir,
"%s/hdd/boot/EFI/BOOT/grub.cfg" % cr_workdir)
- elif source_params['loader'] == 'gummiboot' \
- or source_params['loader'] == 'systemd-boot':
+ elif source_params['loader'] == 'systemd-boot':
cp_cmd = "cp %s/EFI/BOOT/* %s/EFI/BOOT" % (bootimg_dir, hdddir)
exec_cmd(cp_cmd, True)
else:
--
2.10.1
^ permalink raw reply related
* [PATCHv2 1/1] nfs-utils: 1.3.3 -> 1.3.4
From: mariano.lopez @ 2016-11-23 20:41 UTC (permalink / raw)
To: openembedded-core
In-Reply-To: <cover.1479933579.git.mariano.lopez@linux.intel.com>
From: Mariano Lopez <mariano.lopez@linux.intel.com>
Signed-off-by: Mariano Lopez <mariano.lopez@linux.intel.com>
---
.../files/nfs-utils-debianize-start-statd.patch | 23 +++--
...tatd-fix-a-segfault-caused-by-improper-us.patch | 113 ---------------------
.../fix-protocol-minor-version-fall-back.patch | 55 ----------
.../{nfs-utils_1.3.3.bb => nfs-utils_1.3.4.bb} | 6 +-
4 files changed, 14 insertions(+), 183 deletions(-)
delete mode 100644 meta/recipes-connectivity/nfs-utils/nfs-utils/0001-nfs-utils-statd-fix-a-segfault-caused-by-improper-us.patch
delete mode 100644 meta/recipes-connectivity/nfs-utils/nfs-utils/fix-protocol-minor-version-fall-back.patch
rename meta/recipes-connectivity/nfs-utils/{nfs-utils_1.3.3.bb => nfs-utils_1.3.4.bb} (95%)
diff --git a/meta/recipes-connectivity/nfs-utils/files/nfs-utils-debianize-start-statd.patch b/meta/recipes-connectivity/nfs-utils/files/nfs-utils-debianize-start-statd.patch
index 8500229..ede0dce 100644
--- a/meta/recipes-connectivity/nfs-utils/files/nfs-utils-debianize-start-statd.patch
+++ b/meta/recipes-connectivity/nfs-utils/files/nfs-utils-debianize-start-statd.patch
@@ -9,17 +9,18 @@ Signed-off-by: Li Wang <li.wang@windriver.com>
Signed-off-by: Roy Li <rongqing.li@windriver.com>
Signed-off-by: Wenzong Fan <wenzong.fan@windriver.com>
---
- utils/statd/start-statd | 9 ++++++++-
- 1 file changed, 8 insertions(+), 1 deletion(-)
+ utils/statd/start-statd | 10 +++++++++-
+ 1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/utils/statd/start-statd b/utils/statd/start-statd
-index ec9383b..3969b8c 100755
+index 2fd6039..f591b34 100755
--- a/utils/statd/start-statd
+++ b/utils/statd/start-statd
-@@ -6,6 +6,13 @@
- # site.
- PATH="/sbin:/usr/sbin:/bin:/usr/bin"
-
+@@ -17,6 +17,14 @@ then
+ # statd already running - must have been slow to respond.
+ exit 0
+ fi
++
+# Read config
+DEFAULTFILE=/etc/default/nfs-common
+NEED_IDMAPD=
@@ -28,14 +29,14 @@ index ec9383b..3969b8c 100755
+fi
+
# First try systemd if it's installed.
- if systemctl --help >/dev/null 2>&1; then
+ if [ -d /run/systemd/system ]; then
# Quit only if the call worked.
-@@ -13,4 +20,4 @@ if systemctl --help >/dev/null 2>&1; then
- fi
+@@ -25,4 +33,4 @@ fi
+ cd /
# Fall back to launching it ourselves.
-exec rpc.statd --no-notify
+exec rpc.statd --no-notify $STATDOPTS
--
-1.9.1
+2.6.6
diff --git a/meta/recipes-connectivity/nfs-utils/nfs-utils/0001-nfs-utils-statd-fix-a-segfault-caused-by-improper-us.patch b/meta/recipes-connectivity/nfs-utils/nfs-utils/0001-nfs-utils-statd-fix-a-segfault-caused-by-improper-us.patch
deleted file mode 100644
index de0b045..0000000
--- a/meta/recipes-connectivity/nfs-utils/nfs-utils/0001-nfs-utils-statd-fix-a-segfault-caused-by-improper-us.patch
+++ /dev/null
@@ -1,113 +0,0 @@
-Upstream-Status: Pending
-
-Subject: nfs-utils/statd: fix a segfault caused by improper usage of RPC interface
-
-There is a hack which uses the bottom-level RPC improperly as below
-in the current statd implementation:
-insert a socket in the svc_fdset without a corresponding transport handle
-and passes the socket to the svc_getreqset subroutine, this usage causes
-a segfault of statd on a huge amount of sm-notifications.
-
-Fix the issue by separating the non-RPC-server sock from RPC dispatcher.
-
-Signed-off-by: Shan Hai <shan.hai@windriver.com>
-Signed-off-by: Chen Qi <Qi.Chen@windriver.com>
----
- utils/statd/rmtcall.c | 1 -
- utils/statd/statd.c | 5 +++--
- utils/statd/statd.h | 2 +-
- utils/statd/svc_run.c | 8 ++++++--
- 4 files changed, 10 insertions(+), 6 deletions(-)
-
-diff --git a/utils/statd/rmtcall.c b/utils/statd/rmtcall.c
-index fd576d9..cde091b 100644
---- a/utils/statd/rmtcall.c
-+++ b/utils/statd/rmtcall.c
-@@ -104,7 +104,6 @@ statd_get_socket(void)
- if (sockfd < 0)
- return -1;
-
-- FD_SET(sockfd, &SVC_FDSET);
- return sockfd;
- }
-
-diff --git a/utils/statd/statd.c b/utils/statd/statd.c
-index 51a016e..e21a259 100644
---- a/utils/statd/statd.c
-+++ b/utils/statd/statd.c
-@@ -247,6 +247,7 @@ int main (int argc, char **argv)
- int port = 0, out_port = 0;
- int nlm_udp = 0, nlm_tcp = 0;
- struct rlimit rlim;
-+ int notify_sockfd;
-
- int pipefds[2] = { -1, -1};
- char status;
-@@ -473,7 +474,7 @@ int main (int argc, char **argv)
- }
-
- /* Make sure we have a privilege port for calling into the kernel */
-- if (statd_get_socket() < 0)
-+ if ((notify_sockfd = statd_get_socket()) < 0)
- exit(1);
-
- /* If sm-notify didn't take all the state files, load
-@@ -528,7 +529,7 @@ int main (int argc, char **argv)
- * Handle incoming requests: SM_NOTIFY socket requests, as
- * well as callbacks from lockd.
- */
-- my_svc_run(); /* I rolled my own, Olaf made it better... */
-+ my_svc_run(notify_sockfd); /* I rolled my own, Olaf made it better... */
-
- /* Only get here when simulating a crash so we should probably
- * start sm-notify running again. As we have already dropped
-diff --git a/utils/statd/statd.h b/utils/statd/statd.h
-index a1d8035..231ac7e 100644
---- a/utils/statd/statd.h
-+++ b/utils/statd/statd.h
-@@ -28,7 +28,7 @@ extern _Bool statd_present_address(const struct sockaddr *sap, char *buf,
- __attribute__((__malloc__))
- extern char * statd_canonical_name(const char *hostname);
-
--extern void my_svc_run(void);
-+extern void my_svc_run(int);
- extern void notify_hosts(void);
- extern void shuffle_dirs(void);
- extern int statd_get_socket(void);
-diff --git a/utils/statd/svc_run.c b/utils/statd/svc_run.c
-index d98ecee..28c1ad6 100644
---- a/utils/statd/svc_run.c
-+++ b/utils/statd/svc_run.c
-@@ -78,7 +78,7 @@ my_svc_exit(void)
- * The heart of the server. A crib from libc for the most part...
- */
- void
--my_svc_run(void)
-+my_svc_run(int sockfd)
- {
- FD_SET_TYPE readfds;
- int selret;
-@@ -96,6 +96,8 @@ my_svc_run(void)
- }
-
- readfds = SVC_FDSET;
-+ /* Set notify sockfd for waiting for reply */
-+ FD_SET(sockfd, &readfds);
- if (notify) {
- struct timeval tv;
-
-@@ -125,8 +127,10 @@ my_svc_run(void)
-
- default:
- selret -= process_reply(&readfds);
-- if (selret)
-+ if (selret) {
-+ FD_CLR(sockfd, &readfds);
- svc_getreqset(&readfds);
-+ }
- }
- }
- }
---
-1.9.1
-
diff --git a/meta/recipes-connectivity/nfs-utils/nfs-utils/fix-protocol-minor-version-fall-back.patch b/meta/recipes-connectivity/nfs-utils/nfs-utils/fix-protocol-minor-version-fall-back.patch
deleted file mode 100644
index 683246c..0000000
--- a/meta/recipes-connectivity/nfs-utils/nfs-utils/fix-protocol-minor-version-fall-back.patch
+++ /dev/null
@@ -1,55 +0,0 @@
-From 78bb645a42c216b37b8d930c7c849a3fa89babf8 Mon Sep 17 00:00:00 2001
-From: Takashi Iwai <tiwai@suse.com>
-Date: Sat, 16 Jan 2016 12:02:30 -0500
-Subject: [PATCH] Fix protocol minor version fall-back
-
-mount.nfs currently expects mount(2) to fail with EPROTONOSUPPORT if
-the kernel doesn't understand the requested NFS version.
-
-Unfortunately if the requested minor is not known to the kernel
-it returns -EINVAL.
-In kernels since 3.11 this can happen in nfs4_alloc_client(), if
-compiled without NFS_V4_2.
-
-More generally it can happen in in nfs_validate_text_mount_data()
-when nfs_parse_mount_options() returns 0 because
-nfs_parse_version_string()
-didn't recognise the version.
-
-EPROTONOSUPPORT is only returned if NFSv4 support is completely compiled
-out.
-
-So nfs_autonegotiate needs to check for EINVAL as well as
-EPROTONOSUPPORT.
-
-URL: https://bugzilla.opensuse.org/show_bug.cgi?id=959211
-Reported-by: Takashi Iwai <tiwai@suse.com>
-Signed-off-by: NeilBrown <neilb@suse.com>
-Signed-off-by: Steve Dickson <steved@redhat.com>
-
-
-Upstream-Status: Backport
-http://git.linux-nfs.org/?p=steved/nfs-utils.git;a=patch;h=78bb645a42c216b37b8d930c7c849a3fa89babf8
-
-Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
----
- utils/mount/stropts.c | 3 +++
- 1 file changed, 3 insertions(+)
-
-diff --git a/utils/mount/stropts.c b/utils/mount/stropts.c
-index c8f5a6d..86829a9 100644
---- a/utils/mount/stropts.c
-+++ b/utils/mount/stropts.c
-@@ -841,6 +841,9 @@ check_result:
- case EPROTONOSUPPORT:
- /* A clear indication that the server or our
- * client does not support NFS version 4 and minor */
-+ case EINVAL:
-+ /* A less clear indication that our client
-+ * does not support NFSv4 minor version. */
- if (mi->version.v_mode == V_GENERAL &&
- mi->version.minor == 0)
- return result;
---
-2.7.4
-
diff --git a/meta/recipes-connectivity/nfs-utils/nfs-utils_1.3.3.bb b/meta/recipes-connectivity/nfs-utils/nfs-utils_1.3.4.bb
similarity index 95%
rename from meta/recipes-connectivity/nfs-utils/nfs-utils_1.3.3.bb
rename to meta/recipes-connectivity/nfs-utils/nfs-utils_1.3.4.bb
index a2bebe0..bf6c9fa 100644
--- a/meta/recipes-connectivity/nfs-utils/nfs-utils_1.3.3.bb
+++ b/meta/recipes-connectivity/nfs-utils/nfs-utils_1.3.4.bb
@@ -31,13 +31,11 @@ SRC_URI = "${KERNELORG_MIRROR}/linux/utils/nfs-utils/${PV}/nfs-utils-${PV}.tar.x
file://proc-fs-nfsd.mount \
file://nfs-utils-Do-not-pass-CFLAGS-to-gcc-while-building.patch \
file://nfs-utils-debianize-start-statd.patch \
- file://0001-nfs-utils-statd-fix-a-segfault-caused-by-improper-us.patch \
file://bugfix-adjust-statd-service-name.patch \
- file://fix-protocol-minor-version-fall-back.patch \
"
-SRC_URI[md5sum] = "cd6b568c2e9301cc3bfac09d87fbbc0b"
-SRC_URI[sha256sum] = "700d689c5622c87953c34102e5befafc4d3c811e676852238f0dd79c9c0c084d"
+SRC_URI[md5sum] = "54e4119043ec8507a2a0e054cf2889a4"
+SRC_URI[sha256sum] = "b42a5bc0a8d80d04650030ceb9a11f08f4acfbcb1ee297f657fb94e339c45975"
# Only kernel-module-nfsd is required here (but can be built-in) - the nfsd module will
# pull in the remainder of the dependencies.
--
2.7.3
^ permalink raw reply related
* Re: [PATCH] meta/conf/layer.conf: Add recommended download layer
From: Mark Hatle @ 2016-11-23 19:42 UTC (permalink / raw)
To: Martin Jansa; +Cc: openembedded-core
In-Reply-To: <20161123185617.GH3265@jama>
On 11/23/16 12:56 PM, Martin Jansa wrote:
> On Wed, Nov 23, 2016 at 12:38:42PM -0600, Mark Hatle wrote:
>> On 11/23/16 12:10 PM, Martin Jansa wrote:
>>> On Wed, Nov 23, 2016 at 11:42:09AM -0600, Mark Hatle wrote:
>>>> This is a Wind River specific patch and not generally applicable.
>>>
>>> Then why is it sent to oe-core ML?
>>
>> As noted in the cover letter, I'm required to by Yocto Project compliance
>> requirements.
>>
>> As indicated LAST time I got scolded, I was told to indicate this in the patch
>> summary email -- which I did.
>
> Sorry I've noticed the cover letter only after the response.
>
> So it's only because of this requirement from Yocto Project compliance?
yes.
> "Have all patches applied to BitBake and OpenEmbedded-Core (if present)
> been submitted to the open source community?"
>
> Shouldn't the wording be change to something like "all applicable
> patches" or "all generally useful patches"?
>
> It seems strange to send project specific patches together with cover
> saying that they aren't generally applicable and shouldn't be merged,
> just because of this requirement.
It was done this way to prevent people from cheating and claiming something was
(effectively) not useful/applicable/etc when it some special secret sauce.
Even these patches while not generally applicable could give someone else the
idea to duplicate (or improve) on our approach at providing layer specific
download layers.
--Mark
> Regards,
>
>>>> Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
>>>> ---
>>>> meta/conf/layer.conf | 2 ++
>>>> 1 file changed, 2 insertions(+)
>>>>
>>>> diff --git a/meta/conf/layer.conf b/meta/conf/layer.conf
>>>> index 24b4df0..a94e524 100644
>>>> --- a/meta/conf/layer.conf
>>>> +++ b/meta/conf/layer.conf
>>>> @@ -11,6 +11,8 @@ BBFILE_PRIORITY_core = "5"
>>>> # cause compatibility issues with other layers
>>>> LAYERVERSION_core = "9"
>>>>
>>>> +LAYERRECOMMENDS_core = "oe-core-dl-2-2"
>>>> +
>>>> BBLAYERS_LAYERINDEX_NAME_core = "openembedded-core"
>>>>
>>>> # Set a variable to get to the top of the metadata location
>>>> --
>>>> 2.9.3
>>>>
>>>> --
>>>> _______________________________________________
>>>> Openembedded-core mailing list
>>>> Openembedded-core@lists.openembedded.org
>>>> http://lists.openembedded.org/mailman/listinfo/openembedded-core
>>>
>>
>
^ permalink raw reply
* Re: [PATCH] meta/conf/layer.conf: Add recommended download layer
From: Martin Jansa @ 2016-11-23 18:56 UTC (permalink / raw)
To: Mark Hatle; +Cc: openembedded-core
In-Reply-To: <c06ab920-517b-b6b8-f2c8-e9ec8ae8714c@windriver.com>
[-- Attachment #1: Type: text/plain, Size: 2041 bytes --]
On Wed, Nov 23, 2016 at 12:38:42PM -0600, Mark Hatle wrote:
> On 11/23/16 12:10 PM, Martin Jansa wrote:
> > On Wed, Nov 23, 2016 at 11:42:09AM -0600, Mark Hatle wrote:
> >> This is a Wind River specific patch and not generally applicable.
> >
> > Then why is it sent to oe-core ML?
>
> As noted in the cover letter, I'm required to by Yocto Project compliance
> requirements.
>
> As indicated LAST time I got scolded, I was told to indicate this in the patch
> summary email -- which I did.
Sorry I've noticed the cover letter only after the response.
So it's only because of this requirement from Yocto Project compliance?
"Have all patches applied to BitBake and OpenEmbedded-Core (if present)
been submitted to the open source community?"
Shouldn't the wording be change to something like "all applicable
patches" or "all generally useful patches"?
It seems strange to send project specific patches together with cover
saying that they aren't generally applicable and shouldn't be merged,
just because of this requirement.
Regards,
> >> Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
> >> ---
> >> meta/conf/layer.conf | 2 ++
> >> 1 file changed, 2 insertions(+)
> >>
> >> diff --git a/meta/conf/layer.conf b/meta/conf/layer.conf
> >> index 24b4df0..a94e524 100644
> >> --- a/meta/conf/layer.conf
> >> +++ b/meta/conf/layer.conf
> >> @@ -11,6 +11,8 @@ BBFILE_PRIORITY_core = "5"
> >> # cause compatibility issues with other layers
> >> LAYERVERSION_core = "9"
> >>
> >> +LAYERRECOMMENDS_core = "oe-core-dl-2-2"
> >> +
> >> BBLAYERS_LAYERINDEX_NAME_core = "openembedded-core"
> >>
> >> # Set a variable to get to the top of the metadata location
> >> --
> >> 2.9.3
> >>
> >> --
> >> _______________________________________________
> >> Openembedded-core mailing list
> >> Openembedded-core@lists.openembedded.org
> >> http://lists.openembedded.org/mailman/listinfo/openembedded-core
> >
>
--
Martin 'JaMa' Jansa jabber: Martin.Jansa@gmail.com
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 201 bytes --]
^ permalink raw reply
* Re: [PATCH] meta/conf/layer.conf: Add recommended download layer
From: Mark Hatle @ 2016-11-23 18:38 UTC (permalink / raw)
To: Martin Jansa; +Cc: openembedded-core
In-Reply-To: <20161123181039.GF3265@jama>
On 11/23/16 12:10 PM, Martin Jansa wrote:
> On Wed, Nov 23, 2016 at 11:42:09AM -0600, Mark Hatle wrote:
>> This is a Wind River specific patch and not generally applicable.
>
> Then why is it sent to oe-core ML?
As noted in the cover letter, I'm required to by Yocto Project compliance
requirements.
As indicated LAST time I got scolded, I was told to indicate this in the patch
summary email -- which I did.
--Mark
>>
>> Signed-off-by: Mark Hatle <mark.hatle@windriver.com>
>> ---
>> meta/conf/layer.conf | 2 ++
>> 1 file changed, 2 insertions(+)
>>
>> diff --git a/meta/conf/layer.conf b/meta/conf/layer.conf
>> index 24b4df0..a94e524 100644
>> --- a/meta/conf/layer.conf
>> +++ b/meta/conf/layer.conf
>> @@ -11,6 +11,8 @@ BBFILE_PRIORITY_core = "5"
>> # cause compatibility issues with other layers
>> LAYERVERSION_core = "9"
>>
>> +LAYERRECOMMENDS_core = "oe-core-dl-2-2"
>> +
>> BBLAYERS_LAYERINDEX_NAME_core = "openembedded-core"
>>
>> # Set a variable to get to the top of the metadata location
>> --
>> 2.9.3
>>
>> --
>> _______________________________________________
>> Openembedded-core mailing list
>> Openembedded-core@lists.openembedded.org
>> http://lists.openembedded.org/mailman/listinfo/openembedded-core
>
^ permalink raw reply
page: next (older) | prev (newer) | latest
- recent:[subjects (threaded)|topics (new)|topics (active)]
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox