You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@brpc.apache.org by "Gangbiao (via GitHub)" <gi...@apache.org> on 2023/10/12 08:10:34 UTC
[I] 应用程序使用brpc静态库(libbrpc.a)之后安装失败(依赖libc.so.6(GLIBC_PRIVATE)(64bit) ,使用brpc动态库没这个问题) (brpc)
Gangbiao opened a new issue, #2410:
URL: https://github.com/apache/brpc/issues/2410
**Describe the bug (描述bug)**
应用程序使用brpc静态库(libbrpc.a)之后安装失败,报错如下:


**To Reproduce (复现方法)**
使用librpc.a静态库有该报错,使用动态库正常。
**Expected behavior (期望行为)**
使用librpc.a静态库可以正常安装。
**Versions (各种版本)**
OS: 4.19.90-2107.6.0.0192.8.oe1.bclinux.x86_64
Compiler: gcc version 7.3.0 (GCC)
brpc: brpc-cmss_1.0.4.g361b9c1-1.oe1.bclinux.x86_64
protobuf: protobuf-3.14.0-1.oe1.x86_64
**Additional context/screenshots (更多上下文/截图)**
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org
Re: [I] 应用程序使用brpc静态库(libbrpc.a)之后安装失败(依赖libc.so.6(GLIBC_PRIVATE)(64bit) ,使用brpc动态库没这个问题) (brpc)
Posted by "zyearn (via GitHub)" <gi...@apache.org>.
zyearn closed issue #2410: 应用程序使用brpc静态库(libbrpc.a)之后安装失败(依赖libc.so.6(GLIBC_PRIVATE)(64bit) ,使用brpc动态库没这个问题)
URL: https://github.com/apache/brpc/issues/2410
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org
Re: [I] 应用程序使用brpc静态库(libbrpc.a)之后安装失败(依赖libc.so.6(GLIBC_PRIVATE)(64bit) ,使用brpc动态库没这个问题) (brpc)
Posted by "joke-lee (via GitHub)" <gi...@apache.org>.
joke-lee commented on issue #2410:
URL: https://github.com/apache/brpc/issues/2410#issuecomment-2208233520
this spec work
```
%define debug_package %{nil}
%define _unpackaged_files_terminate_build 0
Name: braft
Version: 1.1.2
Release: 1%{?dist}
Summary: accesser
License: Apache-2.0
Group: Development/Languages/Other
URL: http://gitlab.cmss.com/eos/accesser/accesser-src.git
Source0: braft-1.1.2.tar.gz
Provides: libbraft.so()(64bit)
# https://access.redhat.com/solutions/519993
%global _filter_GLIBC_PRIVATE 1
%global __filter_GLIBC_PRIVATE 1
%if 0%{?fedora} >= 15 || 0%{?rhel} >= 8
%global use_devtoolset 0
%else
%global use_devtoolset 1
%endif
%if 0%{?use_devtoolset}
BuildRequires: devtoolset-8-gcc-c++
%define __strip /opt/rh/devtoolset-8/root/usr/bin/strip
%endif
BuildRequires: cmake
BuildRequires: gcc
BuildRequires: gcc-c++
BuildRequires: gflags-devel >= 2.1
BuildRequires: protobuf-devel >= 2.4
BuildRequires: leveldb-devel
BuildRequires: openssl-devel
%description
%package -n libbraft
Summary: libbraft
%description -n libbraft
%prep
%setup -q
%build
%if 0%{?use_devtoolset}
. /opt/rh/devtoolset-8/enable
%endif
cd /yly/braft-1.1.2/build
make -C ./ DESTDIR=%{buildroot} install
%post -n libbraft
echo "/usr/local/lib" > /etc/ld.so.conf.d/usr_local_accesser.conf
echo "/usr/local/lib64" >> /etc/ld.so.conf.d/usr_local_accesser.conf
/sbin/ldconfig &> /dev/null
%postun -n libbraft
%define __spec_install_pre %{nil}
%files -n libbraft
/usr/local/include/braft/builtin_service.pb.h
/usr/local/include/braft/cli.pb.h
/usr/local/include/braft/enum.pb.h
/usr/local/include/braft/errno.pb.h
/usr/local/include/braft/file_service.pb.h
/usr/local/include/braft/local_file_meta.pb.h
/usr/local/include/braft/local_storage.pb.h
/usr/local/include/braft/raft.pb.h
/usr/local/include/braft/ballot.h
/usr/local/include/braft/ballot_box.h
/usr/local/include/braft/builtin_service_impl.h
/usr/local/include/braft/cli.h
/usr/local/include/braft/cli_service.h
/usr/local/include/braft/closure_helper.h
/usr/local/include/braft/closure_queue.h
/usr/local/include/braft/configuration.h
/usr/local/include/braft/configuration_manager.h
/usr/local/include/braft/file_reader.h
/usr/local/include/braft/file_service.h
/usr/local/include/braft/file_system_adaptor.h
/usr/local/include/braft/fsm_caller.h
/usr/local/include/braft/fsync.h
/usr/local/include/braft/lease.h
/usr/local/include/braft/log.h
/usr/local/include/braft/log_entry.h
/usr/local/include/braft/log_manager.h
/usr/local/include/braft/macros.h
/usr/local/include/braft/memory_log.h
/usr/local/include/braft/node.h
/usr/local/include/braft/node_manager.h
/usr/local/include/braft/protobuf_file.h
/usr/local/include/braft/raft.h
/usr/local/include/braft/raft_meta.h
/usr/local/include/braft/raft_service.h
/usr/local/include/braft/remote_file_copier.h
/usr/local/include/braft/repeated_timer_task.h
/usr/local/include/braft/replicator.h
/usr/local/include/braft/route_table.h
/usr/local/include/braft/snapshot.h
/usr/local/include/braft/snapshot_executor.h
/usr/local/include/braft/snapshot_throttle.h
/usr/local/include/braft/storage.h
/usr/local/include/braft/util.h
/usr/local/lib/libbraft.a
/usr/local/lib/libbraft.so
```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org
Re: [I] 应用程序使用brpc静态库(libbrpc.a)之后安装失败(依赖libc.so.6(GLIBC_PRIVATE)(64bit) ,使用brpc动态库没这个问题) (brpc)
Posted by "wasphin (via GitHub)" <gi...@apache.org>.
wasphin commented on issue #2410:
URL: https://github.com/apache/brpc/issues/2410#issuecomment-1759378868
参考项目下 spec 文件,过滤掉 glibc private 依赖
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org
Re: [I] 应用程序使用brpc静态库(libbrpc.a)之后安装失败(依赖libc.so.6(GLIBC_PRIVATE)(64bit) ,使用brpc动态库没这个问题) (brpc)
Posted by "Gangbiao (via GitHub)" <gi...@apache.org>.
Gangbiao commented on issue #2410:
URL: https://github.com/apache/brpc/issues/2410#issuecomment-1760620153
好的,非常感谢。
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@brpc.apache.org
For additional commands, e-mail: dev-help@brpc.apache.org