From 7c13c7d0637ad0a0dfffcc26ce2eb276dde54399 Mon Sep 17 00:00:00 2001 From: liyancheng <412998149@qq.com> Date: Sat, 27 Aug 2022 10:30:04 +0800 Subject: [PATCH] [Bugfix] static link plg_grpc_proto --- 0001-static-link-plg_grpc_proto.patch | 14 ++++++++++++++ pin-server.spec | 10 +++++++++- 2 files changed, 23 insertions(+), 1 deletion(-) create mode 100644 0001-static-link-plg_grpc_proto.patch diff --git a/0001-static-link-plg_grpc_proto.patch b/0001-static-link-plg_grpc_proto.patch new file mode 100644 index 0000000..40ef355 --- /dev/null +++ b/0001-static-link-plg_grpc_proto.patch @@ -0,0 +1,14 @@ +diff --git a/CMakeLists.txt b/CMakeLists.txt +index e713c1b..ec07e26 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -28,7 +28,7 @@ add_custom_command( + include_directories("${CMAKE_CURRENT_BINARY_DIR}") + + # plg_grpc_proto +-add_library(plg_grpc_proto ++add_library(plg_grpc_proto STATIC + ${plg_grpc_srcs} + ${plg_grpc_hdrs} + ${plg_proto_srcs} + diff --git a/pin-server.spec b/pin-server.spec index 1945cb1..5b2cf18 100644 --- a/pin-server.spec +++ b/pin-server.spec @@ -1,10 +1,11 @@ Name: pin-server Version: 0.1.0 -Release: 1 +Release: 2 Summary: Pin (Plug-IN framework) server provides plugin APIs for compiler optimization developers to develop optimization pass. License: Apache 2.0 URL: https://gitee.com/openeuler/pin-server Source0: %{name}-%{version}.tar.gz +Patch0: 0001-static-link-plg_grpc_proto.patch BuildRequires: gcc gcc-c++ cmake make pkgconfig grpc grpc-plugins grpc-devel protobuf-devel jsoncpp-devel Requires: grpc protobuf @@ -25,6 +26,7 @@ A demo for pin-server %prep %setup -q +%patch0 -p1 mkdir -p _build cd _build %{cmake} .. -DCMAKE_INSTALL_PREFIX=%{_usr} -DCMAKE_INSTALL_LIBDIR=%{_libdir} @@ -46,6 +48,12 @@ cd _build %attr(0755,root,root) %{_libdir}/libuser.so %changelog +* Sat Aug 27 2022 liyancheng <412998149@qq.com> - 0.1.0-2 +- Type:Bugfix +- ID:NA +- SUG:NA +- DESC:Static link plg_grpc_proto + * Fri Aug 26 2022 liyancheng <412998149@qq.com> - 0.1.0-1 - Type:Init - ID:NA -- Gitee