poky: subtree update:3b87508a9a..745e38ff0f

Jacob Kroon (2):
      bitbake: bitbake-user-manual: Correct description for _append/_prepend/_remove
      bitbake: bitbake-user-manual: key-expansion: Don't refer to overrides

Nathan Rossi (2):
      oeqa/selftest/context.py: For -t/-T use append argparse action
      chrpath.bbclass: Add break_hardlinks kwarg to allow breaking hardlinks

Trevor Gamblin (1):
      libevent: don't treat test stats line as pass/fail in ptest

Change-Id: I453a18f9177b070de9a2109a8b2b96694aa6e1c3
Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
diff --git a/poky/bitbake/doc/bitbake-user-manual/bitbake-user-manual-metadata.xml b/poky/bitbake/doc/bitbake-user-manual/bitbake-user-manual-metadata.xml
index 8862242..421364c 100644
--- a/poky/bitbake/doc/bitbake-user-manual/bitbake-user-manual-metadata.xml
+++ b/poky/bitbake/doc/bitbake-user-manual/bitbake-user-manual-metadata.xml
@@ -369,9 +369,8 @@
 
             <para>
                 These operators differ from the ":=", ".=", "=.", "+=", and "=+"
-                operators in that their effects are deferred
-                until after parsing completes rather than being immediately
-                applied.
+                operators in that their effects are applied at variable
+                expansion time rather than being immediately applied.
                 Here are some examples:
                 <literallayout class='monospaced'>
      B = "bval"
@@ -435,7 +434,7 @@
 
             <para>
                 Like "_append" and "_prepend", "_remove"
-                is deferred until after parsing completes.
+                is applied at variable expansion time.
             </para>
         </section>
 
@@ -800,17 +799,15 @@
             <title>Key Expansion</title>
 
             <para>
-                Key expansion happens when the BitBake datastore is finalized
-                just before BitBake expands overrides.
+                Key expansion happens when the BitBake datastore is finalized.
                 To better understand this, consider the following example:
                 <literallayout class='monospaced'>
      A${B} = "X"
      B = "2"
      A2 = "Y"
                 </literallayout>
-                In this case, after all the parsing is complete, and
-                before any overrides are handled, BitBake expands
-                <filename>${B}</filename> into "2".
+                In this case, after all the parsing is complete,
+                BitBake expands <filename>${B}</filename> into "2".
                 This expansion causes <filename>A2</filename>, which was
                 set to "Y" before the expansion, to become "X".
             </para>
diff --git a/poky/meta/classes/chrpath.bbclass b/poky/meta/classes/chrpath.bbclass
index ad3c397..2870c10 100644
--- a/poky/meta/classes/chrpath.bbclass
+++ b/poky/meta/classes/chrpath.bbclass
@@ -1,7 +1,7 @@
 CHRPATH_BIN ?= "chrpath"
 PREPROCESS_RELOCATE_DIRS ?= ""
 
-def process_file_linux(cmd, fpath, rootdir, baseprefix, tmpdir, d):
+def process_file_linux(cmd, fpath, rootdir, baseprefix, tmpdir, d, break_hardlinks = False):
     import subprocess as sub
 
     p = sub.Popen([cmd, '-l', fpath],stdout=sub.PIPE,stderr=sub.PIPE)
@@ -39,6 +39,9 @@
 
     # if we have modified some rpaths call chrpath to update the binary
     if modified:
+        if break_hardlinks:
+            bb.utils.break_hardlinks(fpath)
+
         args = ":".join(new_rpaths)
         #bb.note("Setting rpath for %s to %s" %(fpath, args))
         p = sub.Popen([cmd, '-r', args, fpath],stdout=sub.PIPE,stderr=sub.PIPE)
@@ -46,7 +49,7 @@
         if p.returncode != 0:
             bb.fatal("%s: chrpath command failed with exit code %d:\n%s%s" % (d.getVar('PN'), p.returncode, out, err))
 
-def process_file_darwin(cmd, fpath, rootdir, baseprefix, tmpdir, d):
+def process_file_darwin(cmd, fpath, rootdir, baseprefix, tmpdir, d, break_hardlinks = False):
     import subprocess as sub
 
     p = sub.Popen([d.expand("${HOST_PREFIX}otool"), '-L', fpath],stdout=sub.PIPE,stderr=sub.PIPE)
@@ -61,11 +64,14 @@
         if baseprefix not in rpath:
             continue
 
+        if break_hardlinks:
+            bb.utils.break_hardlinks(fpath)
+
         newpath = "@loader_path/" + os.path.relpath(rpath, os.path.dirname(fpath.replace(rootdir, "/")))
         p = sub.Popen([d.expand("${HOST_PREFIX}install_name_tool"), '-change', rpath, newpath, fpath],stdout=sub.PIPE,stderr=sub.PIPE)
         out, err = p.communicate()
 
-def process_dir (rootdir, directory, d):
+def process_dir(rootdir, directory, d, break_hardlinks = False):
     import stat
 
     rootdir = os.path.normpath(rootdir)
@@ -95,7 +101,7 @@
             continue
 
         if os.path.isdir(fpath):
-            process_dir(rootdir, fpath, d)
+            process_dir(rootdir, fpath, d, break_hardlinks = break_hardlinks)
         else:
             #bb.note("Testing %s for relocatability" % fpath)
 
@@ -108,8 +114,9 @@
             else:
                 # Temporarily make the file writeable so we can chrpath it
                 os.chmod(fpath, perms|stat.S_IRWXU)
-            process_file(cmd, fpath, rootdir, baseprefix, tmpdir, d)
-                
+
+            process_file(cmd, fpath, rootdir, baseprefix, tmpdir, d, break_hardlinks = break_hardlinks)
+
             if perms:
                 os.chmod(fpath, perms)
 
diff --git a/poky/meta/lib/oeqa/selftest/context.py b/poky/meta/lib/oeqa/selftest/context.py
index 3126ada..c4eb5d6 100644
--- a/poky/meta/lib/oeqa/selftest/context.py
+++ b/poky/meta/lib/oeqa/selftest/context.py
@@ -78,12 +78,12 @@
         parser.add_argument('--machine', required=False, choices=['random', 'all'],
                             help='Run tests on different machines (random/all).')
 
-        parser.add_argument('-t', '--select-tags', dest="select_tags",
-                nargs='*', default=None,
-                help='Filter all (unhidden) tests to any that match any of the specified tags.')
-        parser.add_argument('-T', '--exclude-tags', dest="exclude_tags",
-                nargs='*', default=None,
-                help='Exclude all (unhidden) tests that match any of the specified tags. (exclude applies before select)')
+        parser.add_argument('-t', '--select-tag', dest="select_tags",
+                action='append', default=None,
+                help='Filter all (unhidden) tests to any that match any of the specified tag(s).')
+        parser.add_argument('-T', '--exclude-tag', dest="exclude_tags",
+                action='append', default=None,
+                help='Exclude all (unhidden) tests that match any of the specified tag(s). (exclude applies before select)')
 
         parser.set_defaults(func=self.run)
 
diff --git a/poky/meta/recipes-support/libevent/libevent/run-ptest b/poky/meta/recipes-support/libevent/libevent/run-ptest
index 080806d..d3b5e79 100644
--- a/poky/meta/recipes-support/libevent/libevent/run-ptest
+++ b/poky/meta/recipes-support/libevent/libevent/run-ptest
@@ -10,10 +10,11 @@
 
 cd ${LIBEVENTLIB}/ptest 
 
-for test in ./test/*
-do
-    $test 2>&1| sed -e '/OK/ s/^/PASS: / ; /FAILED/ s/^/FAIL: / ; /SKIPPED/ s/^/SKIP: / ; /DISABLED/ s/^/SKIP: /' | cut -f1,2 -d ':' | tee -a ${LOG}
-done
+# Run only the libevent "regress" test. All other test scripts in the
+# libevent "test" folder are related to performance, e.g. read/write
+# rates, and/or do not provide a pass/fail output that can be recorded
+# in the ptest log.
+./test/regress 2>&1| sed -e '/TESTS/d' -e '/tests/d' -e '/OK/ s/^/PASS: / ; /FAILED/ s/^/FAIL: / ; /SKIPPED/ s/^/SKIP: / ; /DISABLED/ s/^/SKIP: /' | cut -f1,2 -d ':' | tee -a ${LOG}
 
 passed=`grep PASS ${LOG}|wc -l`
 failed=`grep FAIL ${LOG}|wc -l`