1 Star 0 Fork 13

SiHuaN/yaml-cpp

forked from src-openEuler/yaml-cpp 
加入 Gitee
与超过 1200万 开发者一起发现、参与优秀开源项目,私有仓库也完全免费 :)
免费加入
该仓库未声明开源许可证文件(LICENSE),使用请关注具体项目描述及其代码上游依赖。
克隆/下载
yaml-cpp.spec 2.10 KB
一键复制 编辑 原始数据 按行查看 历史
starlet_dx 提交于 2023-07-06 16:08 . Update to 0.7.0
Name: yaml-cpp
Version: 0.7.0
Release: 1
Summary: A YAML parser and emitter in C++.
License: MIT
URL: https://github.com/jbeder/yaml-cpp
Source0: https://github.com/jbeder/yaml-cpp/archive/%{name}-%{version}.tar.gz
Patch0001: yaml-cpp-cmake.patch
BuildRequires: cmake gcc gcc-c++
%description
yaml-cpp is a YAML parser and emitter in C++ matching the YAML 1.2 spec.
%package devel
Summary: Development files for yaml-cpp
Requires: yaml-cpp = %{version}-%{release} boost-devel pkgconfig
Provides: yaml-cpp-static = %{version}-%{release}
Obsoletes: yaml-cpp-static < %{version}-%{release}
%description devel
This package contains libraries and header files for developing applications that use yaml-cpp.
%prep
%autosetup -n %{name}-%{name}-%{version} -p1
%build
rm -rf build_*
mkdir build_dynamic_lib
mkdir build_static_lib
cd build_dynamic_lib
%cmake -DYAML_BUILD_SHARED_LIBS=ON -DYAML_CPP_BUILD_TESTS=OFF -DYAML_CPP_BUILD_TOOLS=OFF ../
%make_build
cd ../build_static_lib
%cmake -DYAML_BUILD_SHARED_LIBS=OFF -DYAML_CPP_BUILD_TESTS=OFF -DYAML_CPP_BUILD_TOOLS=OFF ../
%make_build
cd -
%install
cd build_dynamic_lib
%make_install
mv %{buildroot}%{_libdir}/cmake/yaml-cpp %{buildroot}%{_libdir}/cmake/yaml-cpp-dynamic
mv %{buildroot}%{_libdir}/pkgconfig/yaml-cpp.pc %{buildroot}%{_libdir}/pkgconfig/yaml-cpp-dynamic.pc
cd ../build_static_lib
%make_install
mv %{buildroot}%{_libdir}/cmake/yaml-cpp %{buildroot}%{_libdir}/cmake/yaml-cpp-static
mv %{buildroot}%{_libdir}/pkgconfig/yaml-cpp.pc %{buildroot}%{_libdir}/pkgconfig/yaml-cpp-static.pc
cd -
%post
/sbin/ldconfig
%postun
/sbin/ldconfig
%files
%license LICENSE
%doc README.md
%{_libdir}/*.so.*
%files devel
%{_libdir}/*.so
%{_libdir}/*.a
%{_includedir}/yaml-cpp/
%{_libdir}/cmake/
%{_libdir}/pkgconfig/
%changelog
* Thu Jul 06 2023 yaoxin <yao_xin001@hoperun.com> - 0.7.0-1
- Update to 0.7.0
- Abi change: libyaml-cpp.so.0.6.3 -> libyaml-cpp.so.0.7.0
* Mon Jan 6 2020 Senlin Xia<xiasenlin1@huawei.com> - 0.6.3-1
- Package init
马建仓 AI 助手
尝试更多
代码解读
代码找茬
代码优化
1
https://gitee.com/shikann/yaml-cpp.git
git@gitee.com:shikann/yaml-cpp.git
shikann
yaml-cpp
yaml-cpp
master

搜索帮助