From 29c71ca4b7705d0282db2d6186cf3542073015d0 Mon Sep 17 00:00:00 2001 From: Funda Wang Date: Sun, 12 Oct 2025 19:18:59 +0800 Subject: [PATCH] fix build with ninja --- yaml-cpp.spec | 21 ++++++++++++++------- 1 file changed, 14 insertions(+), 7 deletions(-) diff --git a/yaml-cpp.spec b/yaml-cpp.spec index 515d565..b513646 100755 --- a/yaml-cpp.spec +++ b/yaml-cpp.spec @@ -1,6 +1,6 @@ Name: yaml-cpp Version: 0.8.0 -Release: 3 +Release: 4 Summary: A YAML parser and emitter in C++. License: MIT URL: https://github.com/jbeder/yaml-cpp @@ -29,26 +29,29 @@ This package contains libraries and header files for developing applications tha %autosetup -n %{name}-%{version} -p1 %build -%cmake -B build_static \ +%define _vpath_builddir build_static +%cmake \ -DCMAKE_BUILD_TYPE=Release \ -DYAML_CPP_BUILD_TOOLS:BOOL=OFF \ -DYAML_CPP_FORMAT_SOURCE:BOOL=OFF \ -DYAML_CPP_INSTALL:BOOL=ON \ -DYAML_BUILD_SHARED_LIBS:BOOL=OFF \ -DYAML_CPP_BUILD_TESTS:BOOL=OFF -%make_build -C build_static +%cmake_build -%cmake -B build_shared \ +%define _vpath_builddir build_shared +%cmake \ -DCMAKE_BUILD_TYPE=Release \ -DYAML_CPP_BUILD_TOOLS:BOOL=OFF \ -DYAML_CPP_FORMAT_SOURCE:BOOL=OFF \ -DYAML_CPP_INSTALL:BOOL=ON \ -DYAML_BUILD_SHARED_LIBS:BOOL=ON \ -DYAML_CPP_BUILD_TESTS:BOOL=OFF -%make_build -C build_shared +%cmake_build %install -%make_install -C build_static yaml-cpp +%define _vpath_builddir build_static +%cmake_install # Move files so they don't get trampled mv %{buildroot}%{_libdir}/cmake/%{name} \ @@ -56,7 +59,8 @@ mv %{buildroot}%{_libdir}/cmake/%{name} \ mv %{buildroot}%{_libdir}/pkgconfig/%{name}.pc \ %{buildroot}%{_libdir}/pkgconfig/%{name}-static.pc -%make_install -C build_shared +%define _vpath_builddir build_shared +%cmake_install %files %license LICENSE @@ -71,6 +75,9 @@ mv %{buildroot}%{_libdir}/pkgconfig/%{name}.pc \ %{_libdir}/pkgconfig/*.pc %changelog +* Sun Oct 12 2025 Funda Wang - 0.8.0-4 +- fix build with ninja + * Mon Jul 28 2025 liuzhilin - 0.8.0-3 - fix: parse files with '\r' symbols as line ending correctly - fix: missing token enum name -- Gitee