From ccad528f0371da2a3a2478664d8a8337133de3acff8e522f1f1054631e16a029 Mon Sep 17 00:00:00 2001 From: Dirk Mueller Date: Mon, 17 Feb 2025 13:42:23 +0000 Subject: [PATCH] - added patches fix https://github.com/jbeder/yaml-cpp/commit/7b469b4220f96fb3d036cf68cd7bd30bd39e61d2 + yaml-cpp-gcc15.patch OBS-URL: https://build.opensuse.org/package/show/devel:libraries:c_c++/yaml-cpp?expand=0&rev=41 --- .gitattributes | 23 +++++++ .gitignore | 1 + baselibs.conf | 1 + yaml-cpp-0.8.0.tar.gz | 3 + yaml-cpp-gcc15.patch | 39 +++++++++++ yaml-cpp.changes | 156 ++++++++++++++++++++++++++++++++++++++++++ yaml-cpp.spec | 94 +++++++++++++++++++++++++ 7 files changed, 317 insertions(+) create mode 100644 .gitattributes create mode 100644 .gitignore create mode 100644 baselibs.conf create mode 100644 yaml-cpp-0.8.0.tar.gz create mode 100644 yaml-cpp-gcc15.patch create mode 100644 yaml-cpp.changes create mode 100644 yaml-cpp.spec diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..9b03811 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,23 @@ +## Default LFS +*.7z filter=lfs diff=lfs merge=lfs -text +*.bsp filter=lfs diff=lfs merge=lfs -text +*.bz2 filter=lfs diff=lfs merge=lfs -text +*.gem filter=lfs diff=lfs merge=lfs -text +*.gz filter=lfs diff=lfs merge=lfs -text +*.jar filter=lfs diff=lfs merge=lfs -text +*.lz filter=lfs diff=lfs merge=lfs -text +*.lzma filter=lfs diff=lfs merge=lfs -text +*.obscpio filter=lfs diff=lfs merge=lfs -text +*.oxt filter=lfs diff=lfs merge=lfs -text +*.pdf filter=lfs diff=lfs merge=lfs -text +*.png filter=lfs diff=lfs merge=lfs -text +*.rpm filter=lfs diff=lfs merge=lfs -text +*.tbz filter=lfs diff=lfs merge=lfs -text +*.tbz2 filter=lfs diff=lfs merge=lfs -text +*.tgz filter=lfs diff=lfs merge=lfs -text +*.ttf filter=lfs diff=lfs merge=lfs -text +*.txz filter=lfs diff=lfs merge=lfs -text +*.whl filter=lfs diff=lfs merge=lfs -text +*.xz filter=lfs diff=lfs merge=lfs -text +*.zip filter=lfs diff=lfs merge=lfs -text +*.zst filter=lfs diff=lfs merge=lfs -text diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..57affb6 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +.osc diff --git a/baselibs.conf b/baselibs.conf new file mode 100644 index 0000000..d2567bf --- /dev/null +++ b/baselibs.conf @@ -0,0 +1 @@ +libyaml-cpp0_8 diff --git a/yaml-cpp-0.8.0.tar.gz b/yaml-cpp-0.8.0.tar.gz new file mode 100644 index 0000000..b377767 --- /dev/null +++ b/yaml-cpp-0.8.0.tar.gz @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:fbe74bbdcee21d656715688706da3c8becfd946d92cd44705cc6098bb23b3a16 +size 1017151 diff --git a/yaml-cpp-gcc15.patch b/yaml-cpp-gcc15.patch new file mode 100644 index 0000000..bca00ee --- /dev/null +++ b/yaml-cpp-gcc15.patch @@ -0,0 +1,39 @@ +From 7b469b4220f96fb3d036cf68cd7bd30bd39e61d2 Mon Sep 17 00:00:00 2001 +From: Christopher Fore +Date: Wed, 14 Aug 2024 21:02:32 -0400 +Subject: [PATCH] emitterutils: Explicitly include + +GCC 15 will no longer include it by default, resulting in build +failures in projects that do not explicitly include it. + +Error: +src/emitterutils.cpp:221:11: error: 'uint16_t' was not declared in this scope + 221 | std::pair EncodeUTF16SurrogatePair(int codePoint) { + | ^~~~~~~~ +src/emitterutils.cpp:13:1: note: 'uint16_t' is defined in header ''; +this is probably fixable by adding '#include ' + 12 | #include "yaml-cpp/null.h" + +++ |+#include + 13 | #include "yaml-cpp/ostream_wrapper.h" + +Tests pass. + +Closes: #1307 +See-also: https://gcc.gnu.org/pipermail/gcc-cvs/2024-August/407124.html +See-also: https://bugs.gentoo.org/937412 +Signed-off-by: Christopher Fore +--- + src/emitterutils.cpp | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/src/emitterutils.cpp b/src/emitterutils.cpp +index fc41011a5..f801b1d0c 100644 +--- a/src/emitterutils.cpp ++++ b/src/emitterutils.cpp +@@ -1,4 +1,5 @@ + #include ++#include + #include + #include + + diff --git a/yaml-cpp.changes b/yaml-cpp.changes new file mode 100644 index 0000000..0b3825a --- /dev/null +++ b/yaml-cpp.changes @@ -0,0 +1,156 @@ +------------------------------------------------------------------- +Thu Feb 13 09:45:14 UTC 2025 - pgajdos@suse.com + +- added patches + fix https://github.com/jbeder/yaml-cpp/commit/7b469b4220f96fb3d036cf68cd7bd30bd39e61d2 + + yaml-cpp-gcc15.patch + +------------------------------------------------------------------- +Mon Oct 28 08:09:19 UTC 2024 - Martin Hauke + +- Add baselibs.conf + +------------------------------------------------------------------- +Thu Aug 17 13:13:20 UTC 2023 - Antonio Teixeira + +- Update to 0.8.0: + * Significant CMake changes, especially to Windows builds + * Support for std::unordered_map, std::valarray, and std::string_view + * Updated gtest dependency + * Assorted bug fixes +- Drop 1077.patch, which is included in version 0.8.0 + +------------------------------------------------------------------- +Thu May 11 15:57:44 UTC 2023 - Frederic Crozat + +- Drop patches fix-cmake-export.patch untabify-cmakelists.patch + replacing them with pull-request 1077.patch which was + merged (bsc#1191137). + +------------------------------------------------------------------- +Tue Jan 4 17:56:42 UTC 2022 - Dirk Müller + +- add fix-cmake-export.patch untabify-cmakelists.patch (bsc#1191137) + +------------------------------------------------------------------- +Mon Aug 30 18:47:21 UTC 2021 - Hans-Peter Jansen + +- Adjust library dependency reference + +------------------------------------------------------------------- +Mon Aug 30 16:14:47 UTC 2021 - Stanislav Brabec + +- Update to 0.7.0: + * Bazel support + * CMake improvements + * Adopts many modern C++ syntaxes + * Bug fixes + * Obsoletes yaml-cpp-CVE-2017-5950.patch (fixed by DepthGuard) + +------------------------------------------------------------------- +Tue Dec 17 14:57:04 UTC 2019 - Michał Rostecki + +- Update to 0.6.3: + * bug fixes + * CMake updates, now requiring 3.1 +- Remove merged patch to fix PIE build: + * yaml-cpp-fix-pie.patch + +------------------------------------------------------------------- +Thu Aug 9 21:53:21 UTC 2018 - rpm@fthiessen.de + +- Update to 0.6.2: + * Fix incorrect version numbering + +------------------------------------------------------------------- +Wed Feb 14 16:01:53 UTC 2018 - pmonrealgonzalez@suse.com + +- Security fix: [bsc#1032144, CVE-2017-5950] + * Stack overflow in SingleDocParser::HandleNode() function + * Added patch yaml-cpp-CVE-2017-5950.patch + +------------------------------------------------------------------- +Fri Feb 2 16:56:09 UTC 2018 - tchvatal@suse.com + +- Update to 0.6.1: + * Just brownpaperbag over previous release + +------------------------------------------------------------------- +Wed Jan 31 11:19:44 UTC 2018 - pmonrealgonzalez@suse.com + +- Update to version 0.6.0 + * yaml-cpp no longer depends on Boost + * Requires C++11 + * Some bug fixes and performance improvements +- Dropped patch yaml-cpp-disable-bundled-gmock.patch since it can + be configured with the option YAML_CPP_BUILD_TESTS + +------------------------------------------------------------------- +Thu Feb 2 15:48:20 UTC 2017 - adam.majer@suse.de + +- use individual libboost-*-devel packages instead of boost-devel + +------------------------------------------------------------------- +Mon Jul 11 07:51:14 UTC 2016 - tchvatal@suse.com + +- Fix building with updated cmake and wrong -fPIE parsing: + * yaml-cpp-disable-bundled-gmock.patch + * yaml-cpp-fix-pie.patch + +------------------------------------------------------------------- +Fri Feb 12 21:14:16 UTC 2016 - mpluskal@suse.com + +- Update to 0.5.3 + * Bugfix release. + * This will be the last release that does not require C++11. +- Drop upstreamed fix-node-regression.patch +- Small spec file cleanups + +------------------------------------------------------------------- +Fri Nov 13 09:51:23 UTC 2015 - tchvatal@suse.com + +- Add patch to fix wrong node behaviour in 0.5.2 bnc#954749: + * fix-node-regression.patch + +------------------------------------------------------------------- +Sat Aug 1 18:08:00 UTC 2015 - rpm@fthiessen.de + +- Update version 0.5.2 + * Some bugfixes +- Updated spec file + * Using cmake macro + * Updated copyright. + +------------------------------------------------------------------- +Tue Jul 2 17:43:52 UTC 2013 - asterios.dramis@gmail.com + +- Added boost-devel in yaml-cpp-devel Requires: (some yaml-cpp headers require + boost headers). + +------------------------------------------------------------------- +Sat Jun 29 13:22:28 UTC 2013 - i@marguerite.su + +- update version 0.5.1 + * a bug fix release for the new API + +------------------------------------------------------------------- +Sun Jul 22 18:11:43 UTC 2012 - i@marguerite.su + +- fix sle builds. + +------------------------------------------------------------------- +Sun Jul 22 08:15:52 UTC 2012 - i@marguerite.su + +- update version 0.3.0 + * minor bug fixing release + +------------------------------------------------------------------- +Sat Jan 28 22:12:35 UTC 2012 - jengelh@medozas.de + +- Remove redundant tags/sections per specfile guideline suggestions +- Parallel building using %_smp_mflags + +------------------------------------------------------------------- +Mon Nov 14 15:58:30 UTC 2011 - tchvatal@suse.com + +- Initial commit of yaml-cpp. diff --git a/yaml-cpp.spec b/yaml-cpp.spec new file mode 100644 index 0000000..b5a589e --- /dev/null +++ b/yaml-cpp.spec @@ -0,0 +1,94 @@ +# +# spec file for package yaml-cpp +# +# Copyright (c) 2025 SUSE LLC +# +# All modifications and additions to the file contributed by third parties +# remain the property of their copyright owners, unless otherwise agreed +# upon. The license for this file, and modifications and additions to the +# file, is the same license as for the pristine package itself (unless the +# license for the pristine package is not an Open Source License, in which +# case the license is the MIT License). An "Open Source License" is a +# license that conforms to the Open Source Definition (Version 1.9) +# published by the Open Source Initiative. + +# Please submit bugfixes or comments via https://bugs.opensuse.org/ +# + + +%define library_name libyaml-cpp0_8 +Name: yaml-cpp +Version: 0.8.0 +Release: 0 +Summary: YAML parser and emitter in C++ +License: MIT +Group: Development/Libraries/C and C++ +URL: https://github.com/jbeder/yaml-cpp/ +Source: https://github.com/jbeder/yaml-cpp/archive/%{version}.tar.gz#/%{name}-%{version}.tar.gz +Source98: baselibs.conf +# https://github.com/jbeder/yaml-cpp/commit/7b469b4220f96fb3d036cf68cd7bd30bd39e61d2 +Patch0: yaml-cpp-gcc15.patch +BuildRequires: cmake +BuildRequires: pkgconfig +BuildRequires: sed +%if %{?suse_version} >= 1330 +BuildRequires: gcc +BuildRequires: gcc-c++ +%else +BuildRequires: gcc6 +BuildRequires: gcc6-c++ +%endif + +%description +A YAML parser and emitter in C++ matching the YAML 1.2 spec. + +%package -n %{library_name} +Summary: YAML parser and emitter in C++ +Group: Development/Libraries/C and C++ + +%description -n %{library_name} +A YAML parser and emitter in C++ matching the YAML 1.2 spec. + +%package devel +Summary: Development files for %{name} +Group: Development/Libraries/C and C++ +Requires: %{library_name} = %{version} + +%description devel +Development files for %{name} library. + +%prep +%autosetup -n %{name}-%{version} -p1 + +%build +export CC=gcc +export CXX=g++ +%if 0%{?suse_version} < 1330 +export CC=gcc-6 +export CXX=g++-6 +%endif +%cmake \ + -DYAML_BUILD_SHARED_LIBS:BOOL=ON \ + -DYAML_CPP_BUILD_TESTS:BOOL=OFF \ + -DCMAKE_C_COMPILER=$CC \ + -DCMAKE_CXX_COMPILER=$CXX + +make %{?_smp_mflags} + +%install +%cmake_install + +%post -n %{library_name} -p /sbin/ldconfig +%postun -n %{library_name} -p /sbin/ldconfig + +%files -n %{library_name} +%license LICENSE +%{_libdir}/libyaml-cpp.so.* + +%files devel +%{_libdir}/pkgconfig/yaml-cpp.pc +%{_libdir}/cmake/%{name}/ +%{_includedir}/yaml-cpp/ +%{_libdir}/libyaml-cpp.so + +%changelog