Skip to contentSkip to conversation

cereal: add cereal a header-only c++11 serialization library

PATCH In review Khem Raj 2 participants 3 messages Feb 3, 2021 – Feb 4, 2021

lore
Share & tools
lore

Khem Raj

author
#0 lore raw

PATCH v2 1/1 cereal: add cereal a header-only c++11 serialization library

From: Adam Miartus <[email protected]>

---
v2: Fix packaging errors

 .../packagegroups/packagegroup-meta-oe.bb     |  2 +-
 ...cense-files-for-components-of-cereal.patch | 99 +++++++++++++++++++
 meta-oe/recipes-devtools/cereal/cereal_1.0.bb | 36 +++++++
 3 files changed, 136 insertions(+), 1 deletion(-)
 create mode 100644 meta-oe/recipes-devtools/cereal/cereal/0001-add-license-files-for-components-of-cereal.patch
 create mode 100644 meta-oe/recipes-devtools/cereal/cereal_1.0.bb
meta-oe/recipes-core/packagegroups/packagegroup-meta-oe.bb +1 -1
index 94830e2970..ba85596995 100644
@@ -961,7 +961,7 @@ RDEPENDS_packagegroup-meta-oe-fortran-packages = "\
 # nlohmann-json exprtk liblightmodbus p8platform gnome-doc-utils-stub
 # glm ttf-mplus xbitmaps ceres-solver cli11 fftw gnulib libeigen ade
 # spdlog span-lite uthash websocketpp catch2 properties-cpp cpp-netlib
-
+# cereal
 # rsyslog conflicts with syslog-ng so its not included here
 
 EXCLUDE_FROM_WORLD = "1"
meta-oe/recipes-devtools/cereal/cereal/0001-add-license-files-for-components-of-cereal.patch new file +99 -0

99 lines not on this page · raw message

meta-oe/recipes-devtools/cereal/cereal_1.0.bb new file +36 -0
new file mode 100644
index 0000000000..dd3dc189dc
@@ -0,0 +1,36 @@
+SUMMARY = "cereal is a header-only C++11 serialization library"
+HOMEPAGE = "https://uscilab.github.io/cereal"
+LICENSE = "BSD & MIT & BSL-1.0"
+LIC_FILES_CHKSUM = "\
+    file://LICENSE;md5=e612690af2f575dfd02e2e91443cea23 \
+    file://include/cereal/external/rapidxml/license.txt;md5=d63ab70ba21ca0544b03284958324301 \
+    file://include/cereal/external/LICENSE;md5=b07578c9df99c0b8b45eb041efd4a645 \
+    file://include/cereal/external/rapidjson/LICENSE;md5=e7abb663111d4ac17cf00323698aff08 \
+    file://include/cereal/external/rapidjson/msinttypes/LICENSE;md5=dffce65b98c773976de2e338bd130f46 \
+"
+
+inherit cmake pkgconfig
+
+RDEPENDS_${PN}-dev = ""
+
+SRC_URI = " \
+    git://github.com/USCiLab/cereal.git;protocol=https \
+    file://0001-add-license-files-for-components-of-cereal.patch \
+"
+
+SRCREV = "48fda3f0a6b58f9a9278ec15c15e7b7c3dceeceb"
+
+EXTRA_OECMAKE += "\
+    -DCEREAL_INSTALL=TRUE \
+    -DJUST_INSTALL_CEREAL=TRUE \
+"
+
+S = "${WORKDIR}/git"
+
+PROVIDES += "${PN}-dev"
+
+FILES_${PN}-dev = " \
+    ${includedir} \
+    ${libdir} \
+"
+
Signature · 1 line
2.30.0
#1 lore raw

We already have meta-oe/recipes-support/libcereal/libcereal_1.3.0.bb!

I recommend ./meta-oe/recipes-devtools/cereal/cereal_1.0.bb is removed again, and any relevant changes added to libcereal instead.

//Peter

Quoted 225 lines

-----Original Message-----
From: [email protected] <openembedded- [email protected]> On Behalf Of Khem Raj
Sent: den 3 februari 2021 03:01
To: [email protected]
Cc: Adam Miartus <[email protected]>; Khem Raj <[email protected]>
Subject: [oe] [meta-oe][PATCH V2] cereal: add cereal a header-only c++11 serialization library

From: Adam Miartus <[email protected]>

---
v2: Fix packaging errors

 .../packagegroups/packagegroup-meta-oe.bb     |  2 +-
 ...cense-files-for-components-of-cereal.patch | 99 +++++++++++++++++++
 meta-oe/recipes-devtools/cereal/cereal_1.0.bb | 36 +++++++
 3 files changed, 136 insertions(+), 1 deletion(-)
 create mode 100644 meta-oe/recipes-devtools/cereal/cereal/0001-add-
license-files-for-components-of-cereal.patch
 create mode 100644 meta-oe/recipes-devtools/cereal/cereal_1.0.bb
meta-oe/recipes-core/packagegroups/packagegroup-meta-oe.bb +1 -1
index 94830e2970..ba85596995 100644
@@ -961,7 +961,7 @@ RDEPENDS_packagegroup-meta-oe-fortran-packages = "\
 # nlohmann-json exprtk liblightmodbus p8platform gnome-doc-utils-stub
 # glm ttf-mplus xbitmaps ceres-solver cli11 fftw gnulib libeigen ade
 # spdlog span-lite uthash websocketpp catch2 properties-cpp cpp-netlib
-
+# cereal
 # rsyslog conflicts with syslog-ng so its not included here
 
 EXCLUDE_FROM_WORLD = "1"
(quoted diff) +0 -0

files-for-components-of-cereal.patch b/meta-oe/recipes- devtools/cereal/cereal/0001-add-license-files-for-components-of- cereal.patch
new file mode 100644
index 0000000000..0000ab9197

meta-oe/recipes-devtools/cereal/cereal/0001-add-license-files-for- new file +0 -0

components-of-cereal.patch

meta-oe/recipes-devtools/cereal/cereal/0001-add-license-files-for- new file +16 -0
@@ -0,0 +1,99 @@
+From 481b2aa46b3f54d9bee059d9da68263edece2bb3 Mon Sep 17 00:00:00 2001
+From: Adam Miartus <[email protected]>
+Date: Mon, 1 Feb 2021 16:15:01 +0100
+Subject: [PATCH] add license files for components of cereal
+
+Signed-off-by: Adam Miartus <[email protected]>
+---
+ include/cereal/external/LICENSE               | 21 ++++++++++++++
+ include/cereal/external/rapidjson/LICENSE     | 13 +++++++++
+ .../external/rapidjson/msinttypes/LICENSE     | 29 +++++++++++++++++++
+ 3 files changed, 63 insertions(+)
+ create mode 100644 include/cereal/external/LICENSE
+ create mode 100644 include/cereal/external/rapidjson/LICENSE
+ create mode 100644 include/cereal/external/rapidjson/msinttypes/LICENSE
+
+diff --git a/include/cereal/external/LICENSE

b/include/cereal/external/LICENSE

meta-oe/recipes-devtools/cereal/cereal/0001-add-license-files-for- new file +16 -0
+new file mode 100644
+index 00000000..66300b68
+--- /dev/null
++++ b/include/cereal/external/LICENSE
+@@ -0,0 +1,21 @@
++Copyright (C) 2004-2008 René Nyffenegger
++
++This source code is provided 'as-is', without any express or implied
++warranty. In no event will the author be held liable for any damages
++arising from the use of this software.
++
++Permission is granted to anyone to use this software for any purpose,
++including commercial applications, and to alter it and redistribute it
++freely, subject to the following restrictions:
++
++1. The origin of this source code must not be misrepresented; you must

not
++ claim that you wrote the original source code. If you use this source code
++ in a product, an acknowledgment in the product documentation would be ++ appreciated but is not required.
++
++2. Altered source versions must be plainly marked as such, and must not be
++ misrepresented as being the original source code.
++
++3. This notice may not be removed or altered from any source distribution.
++
++René Nyffenegger [email protected]
+diff --git a/include/cereal/external/rapidjson/LICENSE b/include/cereal/external/rapidjson/LICENSE

meta-oe/recipes-devtools/cereal/cereal/0001-add-license-files-for- new file +6 -0
+new file mode 100644
+index 00000000..4546f15a
+--- /dev/null
++++ b/include/cereal/external/rapidjson/LICENSE
+@@ -0,0 +1,13 @@
++Tencent is pleased to support the open source community by making

RapidJSON available.
++
++Copyright (C) 2015 THL A29 Limited, a Tencent company, and Milo Yip. All rights reserved.
++
++Licensed under the MIT License (the "License"); you may not use this file except
++in compliance with the License. You may obtain a copy of the License at ++
++http://opensource.org/licenses/MIT
++
++Unless required by applicable law or agreed to in writing, software distributed
++under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
++CONDITIONS OF ANY KIND, either express or implied. See the License for the
++specific language governing permissions and limitations under the License.
+diff --git a/include/cereal/external/rapidjson/msinttypes/LICENSE b/include/cereal/external/rapidjson/msinttypes/LICENSE

meta-oe/recipes-devtools/cereal/cereal/0001-add-license-files-for- new file +12 -0
+new file mode 100644
+index 00000000..e3d96f8f
+--- /dev/null
++++ b/include/cereal/external/rapidjson/msinttypes/LICENSE
+@@ -0,0 +1,29 @@
++ISO C9x  compliant stdint.h for Microsoft Visual Studio
++Based on ISO/IEC 9899:TC2 Committee draft (May 6, 2005) WG14/N1124
++
++ Copyright (c) 2006-2013 Alexander Chemeris
++
++Redistribution and use in source and binary forms, with or without
++modification, are permitted provided that the following conditions are

met:
++
++ 1. Redistributions of source code must retain the above copyright notice,
++ this list of conditions and the following disclaimer.
++
++ 2. Redistributions in binary form must reproduce the above copyright
++ notice, this list of conditions and the following disclaimer in
the
++ documentation and/or other materials provided with the
distribution.
++
++ 3. Neither the name of the product nor the names of its contributors may
++ be used to endorse or promote products derived from this software
++ without specific prior written permission.
++
++THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
++WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF ++MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
++EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, ++SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
++PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
++OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
++WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR ++OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ++ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+--
+2.29.2

meta-oe/recipes-devtools/cereal/cereal/0001-add-license-files-for- new file +1 -0
+
meta- renamed from meta-oe/recipes-devtools/cereal/cereal_1.0.bb +0 -0

oe/recipes-devtools/cereal/cereal_1.0.bb
new file mode 100644
index 0000000000..dd3dc189dc

meta-oe/recipes-devtools/cereal/cereal_1.0.bb new file +6 -0
@@ -0,0 +1,36 @@
+SUMMARY = "cereal is a header-only C++11 serialization library"
+HOMEPAGE = "https://uscilab.github.io/cereal"
+LICENSE = "BSD & MIT & BSL-1.0"
+LIC_FILES_CHKSUM = "\
+    file://LICENSE;md5=e612690af2f575dfd02e2e91443cea23 \
+

file://include/cereal/external/rapidxml/license.txt;md5=d63ab70ba21ca0544 b03284958324301 \
+ file://include/cereal/external/LICENSE;md5=b07578c9df99c0b8b45eb041efd4a6 45 \
+ file://include/cereal/external/rapidjson/LICENSE;md5=e7abb663111d4ac17cf0 0323698aff08 \
+ file://include/cereal/external/rapidjson/msinttypes/LICENSE;md5=dffce65b9 8c773976de2e338bd130f46 \
+"

meta-oe/recipes-devtools/cereal/cereal_1.0.bb new file +26 -1
+
+inherit cmake pkgconfig
+
+RDEPENDS_${PN}-dev = ""
+
+SRC_URI = " \
+    git://github.com/USCiLab/cereal.git;protocol=https \
+    file://0001-add-license-files-for-components-of-cereal.patch \
+"
+
+SRCREV = "48fda3f0a6b58f9a9278ec15c15e7b7c3dceeceb"
+
+EXTRA_OECMAKE += "\
+    -DCEREAL_INSTALL=TRUE \
+    -DJUST_INSTALL_CEREAL=TRUE \
+"
+
+S = "${WORKDIR}/git"
+
+PROVIDES += "${PN}-dev"
+
+FILES_${PN}-dev = " \
+    ${includedir} \
+    ${libdir} \
+"
+
--

2.30.0

author
#2 lore raw

Thanks Peter, I did not realize that they could be merged but relooking it seems to be a better option
I have asked the developer to look into it

Quoted 234 lines · Peter Kjellerstedt

We already have meta-oe/recipes-support/libcereal/libcereal_1.3.0.bb!

I recommend ./meta-oe/recipes-devtools/cereal/cereal_1.0.bb is removed again, and any relevant changes added to libcereal instead.

//Peter

Quoted 225 lines

-----Original Message-----
From: [email protected] <openembedded- [email protected]> On Behalf Of Khem Raj
Sent: den 3 februari 2021 03:01
To: [email protected]
Cc: Adam Miartus <[email protected]>; Khem Raj <[email protected]>
Subject: [oe] [meta-oe][PATCH V2] cereal: add cereal a header-only c++11 serialization library

From: Adam Miartus <[email protected]>

---
v2: Fix packaging errors

 .../packagegroups/packagegroup-meta-oe.bb     |  2 +-
 ...cense-files-for-components-of-cereal.patch | 99 +++++++++++++++++++
 meta-oe/recipes-devtools/cereal/cereal_1.0.bb | 36 +++++++
 3 files changed, 136 insertions(+), 1 deletion(-)
 create mode 100644 meta-oe/recipes-devtools/cereal/cereal/0001-add-
license-files-for-components-of-cereal.patch
 create mode 100644 meta-oe/recipes-devtools/cereal/cereal_1.0.bb
meta-oe/recipes-core/packagegroups/packagegroup-meta-oe.bb +1 -1
index 94830e2970..ba85596995 100644
@@ -961,7 +961,7 @@ RDEPENDS_packagegroup-meta-oe-fortran-packages = "\
 # nlohmann-json exprtk liblightmodbus p8platform gnome-doc-utils-stub
 # glm ttf-mplus xbitmaps ceres-solver cli11 fftw gnulib libeigen ade
 # spdlog span-lite uthash websocketpp catch2 properties-cpp cpp-netlib
-
+# cereal
 # rsyslog conflicts with syslog-ng so its not included here
 
 EXCLUDE_FROM_WORLD = "1"
(quoted diff) +0 -0

files-for-components-of-cereal.patch b/meta-oe/recipes- devtools/cereal/cereal/0001-add-license-files-for-components-of- cereal.patch
new file mode 100644
index 0000000000..0000ab9197

meta-oe/recipes-devtools/cereal/cereal/0001-add-license-files-for- new file +0 -0

components-of-cereal.patch

meta-oe/recipes-devtools/cereal/cereal/0001-add-license-files-for- new file +16 -0
@@ -0,0 +1,99 @@
+From 481b2aa46b3f54d9bee059d9da68263edece2bb3 Mon Sep 17 00:00:00 2001
+From: Adam Miartus <[email protected]>
+Date: Mon, 1 Feb 2021 16:15:01 +0100
+Subject: [PATCH] add license files for components of cereal
+
+Signed-off-by: Adam Miartus <[email protected]>
+---
+ include/cereal/external/LICENSE               | 21 ++++++++++++++
+ include/cereal/external/rapidjson/LICENSE     | 13 +++++++++
+ .../external/rapidjson/msinttypes/LICENSE     | 29 +++++++++++++++++++
+ 3 files changed, 63 insertions(+)
+ create mode 100644 include/cereal/external/LICENSE
+ create mode 100644 include/cereal/external/rapidjson/LICENSE
+ create mode 100644 include/cereal/external/rapidjson/msinttypes/LICENSE
+
+diff --git a/include/cereal/external/LICENSE

b/include/cereal/external/LICENSE

meta-oe/recipes-devtools/cereal/cereal/0001-add-license-files-for- new file +16 -0
+new file mode 100644
+index 00000000..66300b68
+--- /dev/null
++++ b/include/cereal/external/LICENSE
+@@ -0,0 +1,21 @@
++Copyright (C) 2004-2008 René Nyffenegger
++
++This source code is provided 'as-is', without any express or implied
++warranty. In no event will the author be held liable for any damages
++arising from the use of this software.
++
++Permission is granted to anyone to use this software for any purpose,
++including commercial applications, and to alter it and redistribute it
++freely, subject to the following restrictions:
++
++1. The origin of this source code must not be misrepresented; you must

not
++ claim that you wrote the original source code. If you use this source code
++ in a product, an acknowledgment in the product documentation would be ++ appreciated but is not required.
++
++2. Altered source versions must be plainly marked as such, and must not be
++ misrepresented as being the original source code.
++
++3. This notice may not be removed or altered from any source distribution.
++
++René Nyffenegger [email protected]
+diff --git a/include/cereal/external/rapidjson/LICENSE b/include/cereal/external/rapidjson/LICENSE

meta-oe/recipes-devtools/cereal/cereal/0001-add-license-files-for- new file +6 -0
+new file mode 100644
+index 00000000..4546f15a
+--- /dev/null
++++ b/include/cereal/external/rapidjson/LICENSE
+@@ -0,0 +1,13 @@
++Tencent is pleased to support the open source community by making

RapidJSON available.
++
++Copyright (C) 2015 THL A29 Limited, a Tencent company, and Milo Yip. All rights reserved.
++
++Licensed under the MIT License (the "License"); you may not use this file except
++in compliance with the License. You may obtain a copy of the License at ++
++http://opensource.org/licenses/MIT
++
++Unless required by applicable law or agreed to in writing, software distributed
++under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
++CONDITIONS OF ANY KIND, either express or implied. See the License for the
++specific language governing permissions and limitations under the License.
+diff --git a/include/cereal/external/rapidjson/msinttypes/LICENSE b/include/cereal/external/rapidjson/msinttypes/LICENSE

meta-oe/recipes-devtools/cereal/cereal/0001-add-license-files-for- new file +12 -0
+new file mode 100644
+index 00000000..e3d96f8f
+--- /dev/null
++++ b/include/cereal/external/rapidjson/msinttypes/LICENSE
+@@ -0,0 +1,29 @@
++ISO C9x  compliant stdint.h for Microsoft Visual Studio
++Based on ISO/IEC 9899:TC2 Committee draft (May 6, 2005) WG14/N1124
++
++ Copyright (c) 2006-2013 Alexander Chemeris
++
++Redistribution and use in source and binary forms, with or without
++modification, are permitted provided that the following conditions are

met:
++
++ 1. Redistributions of source code must retain the above copyright notice,
++ this list of conditions and the following disclaimer.
++
++ 2. Redistributions in binary form must reproduce the above copyright
++ notice, this list of conditions and the following disclaimer in
the
++ documentation and/or other materials provided with the
distribution.
++
++ 3. Neither the name of the product nor the names of its contributors may
++ be used to endorse or promote products derived from this software
++ without specific prior written permission.
++
++THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
++WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF ++MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
++EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, ++SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
++PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
++OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
++WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR ++OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ++ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+--
+2.29.2

meta-oe/recipes-devtools/cereal/cereal/0001-add-license-files-for- new file +1 -0
+
meta- renamed from meta-oe/recipes-devtools/cereal/cereal_1.0.bb +0 -0

oe/recipes-devtools/cereal/cereal_1.0.bb
new file mode 100644
index 0000000000..dd3dc189dc

meta-oe/recipes-devtools/cereal/cereal_1.0.bb new file +6 -0
@@ -0,0 +1,36 @@
+SUMMARY = "cereal is a header-only C++11 serialization library"
+HOMEPAGE = "https://uscilab.github.io/cereal"
+LICENSE = "BSD & MIT & BSL-1.0"
+LIC_FILES_CHKSUM = "\
+    file://LICENSE;md5=e612690af2f575dfd02e2e91443cea23 \
+

file://include/cereal/external/rapidxml/license.txt;md5=d63ab70ba21ca0544 b03284958324301 \
+ file://include/cereal/external/LICENSE;md5=b07578c9df99c0b8b45eb041efd4a6 45 \
+ file://include/cereal/external/rapidjson/LICENSE;md5=e7abb663111d4ac17cf0 0323698aff08 \
+ file://include/cereal/external/rapidjson/msinttypes/LICENSE;md5=dffce65b9 8c773976de2e338bd130f46 \
+"

meta-oe/recipes-devtools/cereal/cereal_1.0.bb new file +26 -1
+
+inherit cmake pkgconfig
+
+RDEPENDS_${PN}-dev = ""
+
+SRC_URI = " \
+    git://github.com/USCiLab/cereal.git;protocol=https \
+    file://0001-add-license-files-for-components-of-cereal.patch \
+"
+
+SRCREV = "48fda3f0a6b58f9a9278ec15c15e7b7c3dceeceb"
+
+EXTRA_OECMAKE += "\
+    -DCEREAL_INSTALL=TRUE \
+    -DJUST_INSTALL_CEREAL=TRUE \
+"
+
+S = "${WORKDIR}/git"
+
+PROVIDES += "${PN}-dev"
+
+FILES_${PN}-dev = " \
+    ${includedir} \
+    ${libdir} \
+"
+
--

2.30.0