summaryrefslogtreecommitdiffstats
path: root/external/poky/meta/recipes-devtools/libcomps
diff options
context:
space:
mode:
Diffstat (limited to 'external/poky/meta/recipes-devtools/libcomps')
-rw-r--r--external/poky/meta/recipes-devtools/libcomps/libcomps/0001-Add-crc32.c-to-sources-list.patch50
-rw-r--r--external/poky/meta/recipes-devtools/libcomps/libcomps/0001-Do-not-set-PYTHON_INSTALL_DIR-by-running-python.patch41
-rw-r--r--external/poky/meta/recipes-devtools/libcomps/libcomps/0001-Make-__comps_objmrtree_all-static-inline.patch35
-rw-r--r--external/poky/meta/recipes-devtools/libcomps/libcomps/0002-Do-not-set-PYTHON_INSTALL_DIR-by-running-python.patch27
-rw-r--r--external/poky/meta/recipes-devtools/libcomps/libcomps/0002-Set-library-installation-path-correctly.patch27
-rw-r--r--external/poky/meta/recipes-devtools/libcomps/libcomps/CVE-2019-3817.patch97
-rw-r--r--external/poky/meta/recipes-devtools/libcomps/libcomps_0.1.15.bb (renamed from external/poky/meta/recipes-devtools/libcomps/libcomps_git.bb)9
7 files changed, 80 insertions, 206 deletions
diff --git a/external/poky/meta/recipes-devtools/libcomps/libcomps/0001-Add-crc32.c-to-sources-list.patch b/external/poky/meta/recipes-devtools/libcomps/libcomps/0001-Add-crc32.c-to-sources-list.patch
new file mode 100644
index 00000000..f4fb6d3b
--- /dev/null
+++ b/external/poky/meta/recipes-devtools/libcomps/libcomps/0001-Add-crc32.c-to-sources-list.patch
@@ -0,0 +1,50 @@
+From 72065bb2b5881dc224299f302379391aebdfca3d Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Wed, 21 Nov 2018 13:09:05 +0100
+Subject: [PATCH 1/2] Add crc32.c to sources list
+
+Otherwise, there is a missing symbol runtime error under musl C library.
+
+Upstream-Status: Pending
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ libcomps/src/python/src/CMakeLists.txt | 4 ++--
+ libcomps/src/python/src/crc32.c | 2 +-
+ 2 files changed, 3 insertions(+), 3 deletions(-)
+
+diff --git a/libcomps/src/python/src/CMakeLists.txt b/libcomps/src/python/src/CMakeLists.txt
+index adabb31..b9b96ab 100644
+--- a/libcomps/src/python/src/CMakeLists.txt
++++ b/libcomps/src/python/src/CMakeLists.txt
+@@ -9,13 +9,13 @@ set (pycomps_SRCDIR ${CMAKE_CURRENT_SOURCE_DIR})
+ set (pycomps_SRC pycomps.c pycomps_sequence.c
+ pycomps_envs.c pycomps_categories.c pycomps_groups.c
+ pycomps_gids.c pycomps_utils.c pycomps_dict.c pycomps_mdict.c
+- pycomps_hash.c pycomps_exc.c pycomps_lbw.c)
++ pycomps_hash.c pycomps_exc.c pycomps_lbw.c crc32.c)
+
+ set (pycomps_HEADERS pycomps_23macros.h pycomps_sequence.h
+ pycomps_envs.h pycomps_categories.h pycomps_groups.h
+ pycomps_gids.h pycomps_utils.h pycomps_dict.h pycomps_mdict.h
+ pycomps_hash.h pycomps_exc.h pycomps_lbw.h
+- pycomps_types.h)
++ pycomps_types.h crc32.h)
+
+ #set(TEST_FILES ../__init__.py __test.py test_merge_comps.py test_libcomps.py
+ # utest.py)
+diff --git a/libcomps/src/python/src/crc32.c b/libcomps/src/python/src/crc32.c
+index d8f5e34..f266067 100644
+--- a/libcomps/src/python/src/crc32.c
++++ b/libcomps/src/python/src/crc32.c
+@@ -41,7 +41,7 @@
+ */
+
+ #include <sys/param.h>
+-#include <sys/systm.h>
++#include <stdint.h>
+
+ static uint32_t crc32_tab[] = {
+ 0x00000000, 0x77073096, 0xee0e612c, 0x990951ba, 0x076dc419, 0x706af48f,
+--
+2.26.2
+
diff --git a/external/poky/meta/recipes-devtools/libcomps/libcomps/0001-Do-not-set-PYTHON_INSTALL_DIR-by-running-python.patch b/external/poky/meta/recipes-devtools/libcomps/libcomps/0001-Do-not-set-PYTHON_INSTALL_DIR-by-running-python.patch
deleted file mode 100644
index 26e8b06f..00000000
--- a/external/poky/meta/recipes-devtools/libcomps/libcomps/0001-Do-not-set-PYTHON_INSTALL_DIR-by-running-python.patch
+++ /dev/null
@@ -1,41 +0,0 @@
-From ff4aae4c8beaf17cb8e7a3431f6c541eccfae244 Mon Sep 17 00:00:00 2001
-From: Alexander Kanavin <alex.kanavin@gmail.com>
-Date: Fri, 30 Dec 2016 18:22:09 +0200
-Subject: [PATCH 1/2] Do not set PYTHON_INSTALL_DIR by running python.
-
-Upstream-Status: Inappropriate [oe-core specific]
-Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
----
- libcomps/src/python/src/python2/CMakeLists.txt | 2 +-
- libcomps/src/python/src/python3/CMakeLists.txt | 2 +-
- 2 files changed, 2 insertions(+), 2 deletions(-)
-
-diff --git a/libcomps/src/python/src/python2/CMakeLists.txt b/libcomps/src/python/src/python2/CMakeLists.txt
-index 3ad9e18..0e7dd4b 100644
---- a/libcomps/src/python/src/python2/CMakeLists.txt
-+++ b/libcomps/src/python/src/python2/CMakeLists.txt
-@@ -1,7 +1,7 @@
- find_package (PythonLibs 2.6)
- find_package (PythonInterp 2.6 REQUIRED)
-
--execute_process (COMMAND ${PYTHON_EXECUTABLE} -c "from sys import stdout; from distutils import sysconfig; stdout.write(sysconfig.get_python_lib(True))" OUTPUT_VARIABLE PYTHON_INSTALL_DIR)
-+#execute_process (COMMAND ${PYTHON_EXECUTABLE} -c "from sys import stdout; from distutils import sysconfig; stdout.write(sysconfig.get_python_lib(True))" OUTPUT_VARIABLE PYTHON_INSTALL_DIR)
-
- include_directories(${PYTHON_INCLUDE_PATH})
- include_directories(${LIBCOMPS_INCLUDE_PATH})
-diff --git a/libcomps/src/python/src/python3/CMakeLists.txt b/libcomps/src/python/src/python3/CMakeLists.txt
-index 7fafa9f..ed82d3d 100644
---- a/libcomps/src/python/src/python3/CMakeLists.txt
-+++ b/libcomps/src/python/src/python3/CMakeLists.txt
-@@ -2,7 +2,7 @@ find_package (PythonLibs 3.0)
- find_package (PythonInterp 3.0)
- #add_custom_target(py3-copy)
-
--execute_process (COMMAND ${PYTHON_EXECUTABLE} -c "from sys import stdout; from distutils import sysconfig; stdout.write(sysconfig.get_python_lib(True))" OUTPUT_VARIABLE PYTHON_INSTALL_DIR)
-+#execute_process (COMMAND ${PYTHON_EXECUTABLE} -c "from sys import stdout; from distutils import sysconfig; stdout.write(sysconfig.get_python_lib(True))" OUTPUT_VARIABLE PYTHON_INSTALL_DIR)
-
- include_directories(${PYTHON_INCLUDE_PATH})
- include_directories(${LIBCOMPS_INCLUDE_PATH})
---
-2.11.0
-
diff --git a/external/poky/meta/recipes-devtools/libcomps/libcomps/0001-Make-__comps_objmrtree_all-static-inline.patch b/external/poky/meta/recipes-devtools/libcomps/libcomps/0001-Make-__comps_objmrtree_all-static-inline.patch
deleted file mode 100644
index 88469fb3..00000000
--- a/external/poky/meta/recipes-devtools/libcomps/libcomps/0001-Make-__comps_objmrtree_all-static-inline.patch
+++ /dev/null
@@ -1,35 +0,0 @@
-From 91a324f8771818b81017fdf4daaad0c8c4b6987c Mon Sep 17 00:00:00 2001
-From: Khem Raj <raj.khem@gmail.com>
-Date: Mon, 20 Mar 2017 11:38:54 -0700
-Subject: [PATCH] Make __comps_objmrtree_all() static inline
-
-This helps compilers to scope the symbol correctly
-and apply the inlining optimizations, clang e.g.
-emits the functions and calls in code which is
-suboptimal, therefore give a little help to compiler
-this function is not used anywhere else to have
-a global scope.
-
-Upstream-Status: Pending
-
-Signed-off-by: Khem Raj <raj.khem@gmail.com>
----
- libcomps/src/comps_objmradix.c | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/libcomps/src/comps_objmradix.c b/libcomps/src/comps_objmradix.c
-index 9be6648..55f7793 100644
---- a/libcomps/src/comps_objmradix.c
-+++ b/libcomps/src/comps_objmradix.c
-@@ -604,7 +604,7 @@ inline void comps_objmrtree_pair_destroy_v(void * pair) {
- free(pair);
- }
-
--inline COMPS_HSList* __comps_objmrtree_all(COMPS_ObjMRTree * rt, char keyvalpair) {
-+static inline COMPS_HSList* __comps_objmrtree_all(COMPS_ObjMRTree * rt, char keyvalpair) {
- COMPS_HSList *to_process, *ret;
- COMPS_HSListItem *hsit, *oldit;
- size_t x;
---
-2.12.0
-
diff --git a/external/poky/meta/recipes-devtools/libcomps/libcomps/0002-Do-not-set-PYTHON_INSTALL_DIR-by-running-python.patch b/external/poky/meta/recipes-devtools/libcomps/libcomps/0002-Do-not-set-PYTHON_INSTALL_DIR-by-running-python.patch
new file mode 100644
index 00000000..3e910260
--- /dev/null
+++ b/external/poky/meta/recipes-devtools/libcomps/libcomps/0002-Do-not-set-PYTHON_INSTALL_DIR-by-running-python.patch
@@ -0,0 +1,27 @@
+From 32447a79e24f8e7e9e0150eb747f34116d63ef38 Mon Sep 17 00:00:00 2001
+From: Alexander Kanavin <alex.kanavin@gmail.com>
+Date: Fri, 30 Dec 2016 18:22:09 +0200
+Subject: [PATCH 2/2] Do not set PYTHON_INSTALL_DIR by running python.
+
+Upstream-Status: Inappropriate [oe-core specific]
+Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
+---
+ libcomps/src/python/src/CMakeLists.txt | 2 +-
+ 1 file changed, 1 insertion(+), 1 deletion(-)
+
+diff --git a/libcomps/src/python/src/CMakeLists.txt b/libcomps/src/python/src/CMakeLists.txt
+index b9b96ab..6d44567 100644
+--- a/libcomps/src/python/src/CMakeLists.txt
++++ b/libcomps/src/python/src/CMakeLists.txt
+@@ -115,7 +115,7 @@ IF (SKBUILD)
+ INSTALL(FILES libcomps/__init__.py DESTINATION libcomps/src/python/src/libcomps)
+ INSTALL(TARGETS pycomps LIBRARY DESTINATION libcomps/src/python/src/libcomps)
+ ELSE ()
+- EXECUTE_PROCESS(COMMAND ${PYTHON_EXECUTABLE} -c "from sys import stdout; from distutils import sysconfig; stdout.write(sysconfig.get_python_lib(True))" OUTPUT_VARIABLE PYTHON_INSTALL_DIR)
++ #EXECUTE_PROCESS(COMMAND ${PYTHON_EXECUTABLE} -c "from sys import stdout; from distutils import sysconfig; stdout.write(sysconfig.get_python_lib(True))" OUTPUT_VARIABLE PYTHON_INSTALL_DIR)
+
+ INSTALL(FILES ${pycomps_SRCDIR}/libcomps/__init__.py DESTINATION ${PYTHON_INSTALL_DIR}/libcomps)
+ #INSTALL(FILES ${pycomps_SRCDIR}/tests/__test.py DESTINATION
+--
+2.26.2
+
diff --git a/external/poky/meta/recipes-devtools/libcomps/libcomps/0002-Set-library-installation-path-correctly.patch b/external/poky/meta/recipes-devtools/libcomps/libcomps/0002-Set-library-installation-path-correctly.patch
deleted file mode 100644
index dc3d9763..00000000
--- a/external/poky/meta/recipes-devtools/libcomps/libcomps/0002-Set-library-installation-path-correctly.patch
+++ /dev/null
@@ -1,27 +0,0 @@
-From b1f61296e2f16c2b9a39c5501e4538628ff01ab4 Mon Sep 17 00:00:00 2001
-From: Alexander Kanavin <alex.kanavin@gmail.com>
-Date: Fri, 30 Dec 2016 18:26:00 +0200
-Subject: [PATCH 2/2] Set library installation path correctly
-
-Upstream-Status: Submitted [https://github.com/rpm-software-management/libcomps/pull/32]
-Signed-off-by: Alexander Kanavin <alex.kanavin@gmail.com>
----
- libcomps/src/CMakeLists.txt | 2 +-
- 1 file changed, 1 insertion(+), 1 deletion(-)
-
-diff --git a/libcomps/src/CMakeLists.txt b/libcomps/src/CMakeLists.txt
-index e553d77..e2eef9c 100644
---- a/libcomps/src/CMakeLists.txt
-+++ b/libcomps/src/CMakeLists.txt
-@@ -52,7 +52,7 @@ add_dependencies(libcomps src-copy)
- IF (CMAKE_SIZEOF_VOID_P MATCHES "8")
- SET (LIB_SUFFIX "64")
- ENDIF (CMAKE_SIZEOF_VOID_P MATCHES "8")
--set (LIB_INST_DIR ${CMAKE_INSTALL_PREFIX}/lib${LIB_SUFFIX})
-+set (LIB_INST_DIR ${CMAKE_INSTALL_LIBDIR})
-
-
- install (FILES ${libcomps_HEADERS} DESTINATION include/libcomps)
---
-2.11.0
-
diff --git a/external/poky/meta/recipes-devtools/libcomps/libcomps/CVE-2019-3817.patch b/external/poky/meta/recipes-devtools/libcomps/libcomps/CVE-2019-3817.patch
deleted file mode 100644
index b8cfb3c4..00000000
--- a/external/poky/meta/recipes-devtools/libcomps/libcomps/CVE-2019-3817.patch
+++ /dev/null
@@ -1,97 +0,0 @@
-From cea10cd1f2ef6bb4edaac0c1d46d47bf237c42b8 Mon Sep 17 00:00:00 2001
-From: Riccardo Schirone <rschiron@redhat.com>
-Date: Mon, 21 Jan 2019 18:11:42 +0100
-Subject: [PATCH] Fix UAF in comps_objmrtree_unite function
-
-The added field is not used at all in many places and it is probably the
-left-over of some copy-paste.
-
-Upstream-Status: Backport
-[https://github.com/rpm-software-management/libcomps/commit
-/e3a5d056633677959ad924a51758876d415e7046]
-
-CVE: CVE-2019-3817
-
-Signed-off-by: Kevin Weng <t-keweng@microsoft.com>
----
- libcomps/src/comps_mradix.c | 2 --
- libcomps/src/comps_objmradix.c | 2 --
- libcomps/src/comps_objradix.c | 2 --
- libcomps/src/comps_radix.c | 1 -
- 4 files changed, 7 deletions(-)
-
-diff --git a/libcomps/src/comps_mradix.c b/libcomps/src/comps_mradix.c
-index 338cb07..6ceb7c9 100644
---- a/libcomps/src/comps_mradix.c
-+++ b/libcomps/src/comps_mradix.c
-@@ -177,7 +177,6 @@ void comps_mrtree_unite(COMPS_MRTree *rt1, COMPS_MRTree *rt2) {
- struct Pair {
- COMPS_HSList * subnodes;
- char * key;
-- char added;
- } *pair, *parent_pair;
-
- pair = malloc(sizeof(struct Pair));
-@@ -195,7 +194,6 @@ void comps_mrtree_unite(COMPS_MRTree *rt1, COMPS_MRTree *rt2) {
- parent_pair = (struct Pair*) it->data;
- free(it);
-
-- pair->added = 0;
- for (it = tmp_subnodes->first; it != NULL; it=it->next) {
- pair = malloc(sizeof(struct Pair));
- pair->subnodes = ((COMPS_MRTreeData*)it->data)->subnodes;
-diff --git a/libcomps/src/comps_objmradix.c b/libcomps/src/comps_objmradix.c
-index 9be6648..8771c89 100644
---- a/libcomps/src/comps_objmradix.c
-+++ b/libcomps/src/comps_objmradix.c
-@@ -285,7 +285,6 @@ void comps_objmrtree_unite(COMPS_ObjMRTree *rt1, COMPS_ObjMRTree *rt2) {
- struct Pair {
- COMPS_HSList * subnodes;
- char * key;
-- char added;
- } *pair, *parent_pair;
-
- pair = malloc(sizeof(struct Pair));
-@@ -303,7 +302,6 @@ void comps_objmrtree_unite(COMPS_ObjMRTree *rt1, COMPS_ObjMRTree *rt2) {
- parent_pair = (struct Pair*) it->data;
- free(it);
-
-- pair->added = 0;
- for (it = tmp_subnodes->first; it != NULL; it=it->next) {
- pair = malloc(sizeof(struct Pair));
- pair->subnodes = ((COMPS_ObjMRTreeData*)it->data)->subnodes;
-diff --git a/libcomps/src/comps_objradix.c b/libcomps/src/comps_objradix.c
-index a790270..0ebaf22 100644
---- a/libcomps/src/comps_objradix.c
-+++ b/libcomps/src/comps_objradix.c
-@@ -692,7 +692,6 @@ void comps_objrtree_unite(COMPS_ObjRTree *rt1, COMPS_ObjRTree *rt2) {
- struct Pair {
- COMPS_HSList * subnodes;
- char * key;
-- char added;
- } *pair, *parent_pair;
-
- pair = malloc(sizeof(struct Pair));
-@@ -711,7 +710,6 @@ void comps_objrtree_unite(COMPS_ObjRTree *rt1, COMPS_ObjRTree *rt2) {
- //printf("key-part:%s\n", parent_pair->key);
- free(it);
-
-- //pair->added = 0;
- for (it = tmp_subnodes->first; it != NULL; it=it->next) {
- pair = malloc(sizeof(struct Pair));
- pair->subnodes = ((COMPS_ObjRTreeData*)it->data)->subnodes;
-diff --git a/libcomps/src/comps_radix.c b/libcomps/src/comps_radix.c
-index ada4fda..05dcaf2 100644
---- a/libcomps/src/comps_radix.c
-+++ b/libcomps/src/comps_radix.c
-@@ -529,7 +529,6 @@ void comps_rtree_unite(COMPS_RTree *rt1, COMPS_RTree *rt2) {
- struct Pair {
- COMPS_HSList * subnodes;
- char * key;
-- char added;
- } *pair, *parent_pair;
-
- pair = malloc(sizeof(struct Pair));
---
-2.22.0
-
diff --git a/external/poky/meta/recipes-devtools/libcomps/libcomps_git.bb b/external/poky/meta/recipes-devtools/libcomps/libcomps_0.1.15.bb
index b657f337..98c55dca 100644
--- a/external/poky/meta/recipes-devtools/libcomps/libcomps_git.bb
+++ b/external/poky/meta/recipes-devtools/libcomps/libcomps_0.1.15.bb
@@ -3,14 +3,11 @@ LICENSE = "GPLv2"
LIC_FILES_CHKSUM = "file://COPYING;md5=b234ee4d69f5fce4486a80fdaf4a4263"
SRC_URI = "git://github.com/rpm-software-management/libcomps.git \
- file://0001-Do-not-set-PYTHON_INSTALL_DIR-by-running-python.patch \
- file://0002-Set-library-installation-path-correctly.patch \
- file://0001-Make-__comps_objmrtree_all-static-inline.patch \
- file://CVE-2019-3817.patch \
+ file://0001-Add-crc32.c-to-sources-list.patch \
+ file://0002-Do-not-set-PYTHON_INSTALL_DIR-by-running-python.patch \
"
-PV = "0.1.8+git${SRCPV}"
-SRCREV = "01a4759894cccff64d2561614a58281adf5ce859"
+SRCREV = "b213f749405d84e989b25e183bcf28ce701696dd"
S = "${WORKDIR}/git"