mirror of
https://github.com/openembedded/meta-openembedded.git
synced 2026-11-14 03:57:15 +00:00
libplist: upgrade 2.7.0 -> 2.8.1
Drop 0001-test-fix-operator-error.patch and 0001-ostep-invalid-types.test-Fix-ostep-invalid-types-tes.patch, the tests were fixed upstream. Install the new date_val_test, xml_behavior_test and bplist_behavior_test programs for the ptests, and use rm -f in run-ptest so the script does not exit non-zero when the last test leaves no data behind. ptests pass on qemux86-64. AI-Generated: Uses Claude Code Signed-off-by: Khem Raj <khem.raj@oss.qualcomm.com>
This commit is contained in:
4 files changed
+5
-122
No files matched your search
-49
@@ -1,49 +0,0 @@
|
||||
From d87f49535f5e815e91e309472c47da2375cbb5f4 Mon Sep 17 00:00:00 2001
|
||||
From: Khem Raj <raj.khem@gmail.com>
|
||||
Date: Wed, 26 Nov 2025 18:18:04 -0800
|
||||
Subject: [PATCH] ostep-invalid-types.test: Fix ostep-invalid-types test to
|
||||
accept both success and error codes
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
The ostep-invalid-types.test expects plistutil to return exit code 2
|
||||
when converting binary plist data containing NSData objects to OpenStep
|
||||
format, since OpenStep format doesn't natively support binary data types.
|
||||
|
||||
However, plistutil's current behavior is to succeed (exit 0) and output
|
||||
the binary data as hex-encoded strings in OpenStep format, which is a
|
||||
valid fallback representation.
|
||||
|
||||
This patch updates the test to accept both behaviors:
|
||||
- Exit code 0: Success with hex-encoded binary data (current behavior)
|
||||
- Exit code 2: Explicit rejection of unsupported type (expected behavior)
|
||||
|
||||
Both outcomes are acceptable - either the tool can gracefully handle the
|
||||
conversion by encoding binary data as strings, or it can reject formats
|
||||
that don't support all input types. The test should not fail in either case.
|
||||
|
||||
Upstream never noticed because they wrote -neq instead of -ne, so the
|
||||
first check is effectively broken and doesn’t enforce the exit code.
|
||||
|
||||
Upstream-Status: Pending
|
||||
|
||||
Signed-off-by: Khem Raj <raj.khem@gmail.com>
|
||||
---
|
||||
test/ostep-invalid-types.test | 3 ++-
|
||||
1 file changed, 2 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/test/ostep-invalid-types.test b/test/ostep-invalid-types.test
|
||||
index 240505c..ebfc6b0 100755
|
||||
--- a/test/ostep-invalid-types.test
|
||||
+++ b/test/ostep-invalid-types.test
|
||||
@@ -14,7 +14,8 @@ export PLIST_OSTEP_DEBUG=1
|
||||
|
||||
echo "Converting (failure expected)"
|
||||
$top_builddir/tools/plistutil -f openstep -i $DATASRC/$TESTFILE0 -o /dev/null
|
||||
-if [ $? -ne 2 ]; then
|
||||
+rc=$?
|
||||
+if [ $rc -ne 0 ] && [ $rc -ne 2 ]; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
@@ -1,68 +0,0 @@
|
||||
From 18e5b22a71f85091127cc063db79c8df687c582c Mon Sep 17 00:00:00 2001
|
||||
From: Ankur Tyagi <ankur.tyagi85@gmail.com>
|
||||
Date: Thu, 20 Nov 2025 16:01:58 +1300
|
||||
Subject: [PATCH] test: fix operator error
|
||||
|
||||
Otherwise test fail with error [: -neq: binary operator expected
|
||||
|
||||
Upstream-Status: Submitted [https://github.com/libimobiledevice/libplist/pull/284]
|
||||
Signed-off-by: Ankur Tyagi <ankur.tyagi85@gmail.com>
|
||||
---
|
||||
test/json-invalid-types.test | 6 +++---
|
||||
test/ostep-invalid-types.test | 6 +++---
|
||||
2 files changed, 6 insertions(+), 6 deletions(-)
|
||||
|
||||
diff --git a/test/json-invalid-types.test b/test/json-invalid-types.test
|
||||
index c532316..a21fcd9 100755
|
||||
--- a/test/json-invalid-types.test
|
||||
+++ b/test/json-invalid-types.test
|
||||
@@ -14,19 +14,19 @@ export PLIST_JSON_DEBUG=1
|
||||
|
||||
echo "Converting (failure expected)"
|
||||
$top_builddir/tools/plistutil -f json -i $DATASRC/$TESTFILE0 -o /dev/null
|
||||
-if [ $? -neq 2 ]; then
|
||||
+if [ $? -ne 2 ]; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "Converting (failure expected)"
|
||||
$top_builddir/tools/plistutil -f json -i $DATASRC/$TESTFILE1 -o /dev/null
|
||||
-if [ $? -neq 2 ]; then
|
||||
+if [ $? -ne 2 ]; then
|
||||
exit 2
|
||||
fi
|
||||
|
||||
echo "Converting (failure expected)"
|
||||
$top_builddir/tools/plistutil -f json -i $DATASRC/$TESTFILE2 -o /dev/null
|
||||
-if [ $? -neq 2 ]; then
|
||||
+if [ $? -ne 2 ]; then
|
||||
exit 3
|
||||
fi
|
||||
|
||||
diff --git a/test/ostep-invalid-types.test b/test/ostep-invalid-types.test
|
||||
index 9222394..240505c 100755
|
||||
--- a/test/ostep-invalid-types.test
|
||||
+++ b/test/ostep-invalid-types.test
|
||||
@@ -14,19 +14,19 @@ export PLIST_OSTEP_DEBUG=1
|
||||
|
||||
echo "Converting (failure expected)"
|
||||
$top_builddir/tools/plistutil -f openstep -i $DATASRC/$TESTFILE0 -o /dev/null
|
||||
-if [ $? -neq 2 ]; then
|
||||
+if [ $? -ne 2 ]; then
|
||||
exit 1
|
||||
fi
|
||||
|
||||
echo "Converting (failure expected)"
|
||||
$top_builddir/tools/plistutil -f openstepn -i $DATASRC/$TESTFILE1 -o /dev/null
|
||||
-if [ $? -neq 2 ]; then
|
||||
+if [ $? -ne 2 ]; then
|
||||
exit 2
|
||||
fi
|
||||
|
||||
echo "Converting (failure expected)"
|
||||
$top_builddir/tools/plistutil -f openstep -i $DATASRC/$TESTFILE2 -o /dev/null
|
||||
-if [ $? -neq 2 ]; then
|
||||
+if [ $? -ne 2 ]; then
|
||||
exit 3
|
||||
fi
|
||||
|
||||
@@ -2,5 +2,5 @@
|
||||
|
||||
for t in `ls test/*.test`; do
|
||||
top_srcdir=$(pwd)/input top_builddir=$(pwd)/test ./$t && echo PASS: $t || echo FAIL: $t
|
||||
rm $(pwd)/test/test/data/* 2>/dev/null
|
||||
rm -f $(pwd)/test/test/data/*
|
||||
done
|
||||
+4
-4
@@ -8,11 +8,9 @@ DEPENDS = "libxml2 glib-2.0 swig python3"
|
||||
|
||||
inherit autotools pkgconfig python3native python3targetconfig ptest
|
||||
|
||||
SRCREV = "cf5897a71ea412ea2aeb1e2f6b5ea74d4fabfd8c"
|
||||
SRCREV = "678b1a34693b86ae1787fa470dcb7203ffd0ef3f"
|
||||
SRC_URI = "git://github.com/libimobiledevice/libplist;protocol=https;branch=master;tag=${PV} \
|
||||
file://run-ptest \
|
||||
file://0001-test-fix-operator-error.patch \
|
||||
file://0001-ostep-invalid-types.test-Fix-ostep-invalid-types-tes.patch \
|
||||
"
|
||||
|
||||
CVE_STATUS_GROUPS += "CVE_STATUS_LIBLIST"
|
||||
@@ -44,7 +42,9 @@ do_install_ptest(){
|
||||
install ${S}/test/data/* ${D}${PTEST_PATH}/input/test/data/
|
||||
install ${S}/test/*.test ${D}${PTEST_PATH}/test/
|
||||
install -m 0755 ${B}/test/.libs/plist* ${D}${PTEST_PATH}/test/test/.libs/
|
||||
install -m 0755 ${B}/test/.libs/integer_set_test ${D}${PTEST_PATH}/test/test/
|
||||
for t in integer_set_test date_val_test xml_behavior_test bplist_behavior_test; do
|
||||
install -m 0755 ${B}/test/.libs/$t ${D}${PTEST_PATH}/test/test/
|
||||
done
|
||||
for t in $(find ${B}/test -type f -name 'plist*' \! -name '*.o'); do
|
||||
install -m 0755 $t ${D}${PTEST_PATH}/test/test/
|
||||
done
|
||||
Reference in new issue
Block a user