Closed kloczek closed 7 months ago
Any update? 🤔
I just created ticket against libphonenumber https://issuetracker.google.com/issues/283987730
No, I'm waiting for you to provide the reproduction steps I asked for last week. I wasn't able to reproduce the issue you saw by guessing cmake flags.
Cmake settings:
%cmake \
-D CMAKE_PREFIX_PATH=%{_prefix} \
-D BUILD_SHARED_LIBS=ON \
-D protobuf_ABSL_PROVIDER=package \
-D protobuf_BUILD_TESTS=ON \
-D protobuf_USE_EXTERNAL_GTEST=ON \
-D utf8_range_ENABLE_INSTALL=OFF \
%{nil}
%cmake \
-D ABSL_BUILD_TESTING=ON \
-D ABSL_BUILD_TEST_HELPERS=ON \
-D ABSL_USE_EXTERNAL_GOOGLETEST=ON \
%{nil}
%cmake cpp \
-D BUILD_STATIC_LIB=OFF \
-D BUILD_TESTING=OM \
-D PROTOBUF_USE_DLLS=ON \
-D USE_BOOST=ON \
-D USE_ICU_REGEXP=ON \
-D USE_RE2=OFF \
%{nil}
%cmake \
-D BUILD_DOCS=ON \
-D BUILD_EXAMPLES=ON \
-D BUILD_opencv_java=ON \
-D BUILD_PROTOBUF=OFF \
-D CMAKE_SKIP_RPATH=ON \
-D ENABLE_PRECOMPILED_HEADERS=OFF \
-D ENABLE_PYLINT=ON \
-D INSTALL_C_EXAMPLES=ON \
-D INSTALL_PYTHON_EXAMPLES=ON \
-D OPENCV_CONFIG_INSTALL_PATH=%{_lib}/cmake/OpenCV \
-D OPENCV_EXTRA_MODULES_PATH=$(ls -1d opencv_contrib-*/modules) \
-D OPENCV_GENERATE_PKGCONFIG=ON \
-D OPENCV_JAR_INSTALL_PATH=%{_jnidir} \
-D OPENCV_PC_FILE_NAME=opencv.pc \
-D OPENCV_SKIP_PYTHON_LOADER=ON \
-D OPENCV_TEST_DATA_PATH=$PWD/%{name}_extra-%{version} \
-D OpenGL_GL_PREFERENCE=GLVND \
-D PNG_PNG_INCLUDE_DIR=%{_includedir} \
-D PROTOBUF_UPDATE_FILES=ON \
-D PYTHON2_EXECUTABLE=OFF \
-D PYTHON3_EXECUTABLE=%__python3 \
-D PYTHON3_PACKAGES_PATH=%{python3_sitearch} \
-D VULKAN_INCLUDE_DIRS=%{_includedir}/vulkan \
-D WITH_CAROTENE=OFF \
-D WITH_CLP=OFF \
-D WITH_FFMPEG=ON \
-D WITH_GDAL=ON \
-D WITH_GDCM=ON \
-D WITH_GSTREAMER=ON \
-D WITH_IPP=OFF \
-D WITH_ITT=OFF \
-D WITH_LAPACK=OFF \
-D WITH_LIBV4L=ON \
-D WITH_MFX=OFF \
-D WITH_OPENCL=ON \
-D WITH_OPENGL=ON \
-D WITH_OPENJPEG=OFF \
-D WITH_OPENMP=ON \
-D WITH_OPENNI=ON \
-D WITH_QT=ON \
-D WITH_TBB=ON \
-D WITH_UNICAP=ON \
-D WITH_VA=ON \
-D WITH_VTK=OFF \
-D WITH_VULKAN=ON \
-D WITH_XINE=OFF \
%{?with_opencl:-D OPENCL_INCLUDE_DIR=%{_includedir}/CL } \
-D WITH_CUDA=ON \
-D CUDA_TOOLKIT_ROOT_DIR=%{?_cuda_prefix} \
-D CUDA_VERBOSE_BUILD=ON \
-D CUDA_PROPAGATE_HOST_FLAGS=OFF \
%{nil}
%cmake \
-D ADD_GDB_INDEX=OFF \
-D BUILD_CONFIG=mysql_release \
-D CMAKE_C_FLAGS="$CFLAGS" \
-D CMAKE_C_LINK_FLAGS="$LDFLAGS" \
-D CMAKE_CXX_FLAGS="$CXXFLAGS" \
-D CMAKE_CXX_LINK_FLAGS="$LDFLAGS" \
-D CMAKE_EXE_LINKER_FLAGS="$LDFLAGS" \
-D CMAKE_SKIP_INSTALL_RPATH=ON \
-D DAEMON_NAME="%{daemon_name}" \
-D DAEMON_NO_PREFIX="%{daemon_no_prefix}" \
-D ENABLED_LOCAL_INFILE=ON \
-D ENABLED_PROFILING=OFF \
-D FEATURE_SET="community" \
-D INSTALL_DOCDIR="share/doc/%{_pkgdocdirname}" \
-D INSTALL_DOCREADMEDIR="share/doc/%{_pkgdocdirname}" \
-D INSTALL_INCLUDEDIR=include/mysql \
-D INSTALL_INFODIR=share/info \
-D INSTALL_LAYOUT=RPM \
-D INSTALL_LIBDIR="%{_lib}" \
-D INSTALL_LIBEXECDIR=libexec \
-D INSTALL_MANDIR=share/man \
-D INSTALL_MYSQLSHAREDIR=share/%{pkg_name} \
-D INSTALL_MYSQLTESTDIR=share/mysql-test \
-D INSTALL_PLUGINDIR="%{_lib}/mysql/plugin" \
-D INSTALL_SBINDIR=bin \
-D INSTALL_STATIC_LIBRARIES=OFF \
-D INSTALL_SUPPORTFILESDIR=share/%{pkg_name} \
-D LOGFILE_RPM="%{_localstatedir}/log/mysql/%{daemon_no_prefix}.log" \
-D MYSQL_DATADIR="%{_sharedstatedir}/mysql" \
-D MYSQL_UNIX_ADDR="/var/lib/mysql/mysql.sock" \
-D NICE_PROJECT_NAME="MySQL" \
-D PID_FILE_DIR="%{_rundir}/%{daemon_name}" \
-D REPRODUCIBLE_BUILD=OFF \
-D RPATH_LIBDIR="%{_libdir}" \
-D SYSCONF2DIR="%{_sysconfdir}/my.cnf.d" \
-D SYSCONFDIR="%{_sysconfdir}" \
-D SYSTEMD_PID_DIR="%{_rundir}/%{daemon_name}" \
-D SYSTEMD_SERVICE_NAME="%{daemon_name}" \
-D TMPDIR=/var/tmp \
-D MYSQLX_ADDITIONAL_TESTS_ENABLE=OFF \
-D WITH_AUTHENTICATION_FIDO=ON \
-D WITH_AUTHENTICATION_KERBEROS=ON \
-D WITH_AUTHENTICATION_LDAP=ON \
-D WITH_BOOST=boost \
-D WITH_FIDO=system \
-D WITH_HYPERGRAPH_OPTIMIZER=OFF \
-D WITH_INNODB_MEMCACHED=ON \
-D WITH_JSON_BINLOG_LIBRARY=OFF \
-D WITH_LIBWRAP=OFF \
-D WITH_MECAB=system \
-D WITH_MYSQLD_LDFLAGS="$LDFLAGS" \
-D WITH_NDBCLUSTER=OFF \
-D WITH_ROUTER=ON \
-D WITH_SYSTEMD=ON \
-D WITH_SYSTEM_LIBS=ON \
-D WITH_VALGRIND=OFF \
-D XPLUGIN_LOG_PROTOBUF=ON \
%{?with_debug:-D MYSQL_MAINTAINER_MODE=OFF} \
%{?with_debug:-D WITH_DEBUG=ON} \
-D WITH_NUMA=ON \
%{nil}
libphonenumber maintainers just mentioned that they are observing as well linking issue https://issuetracker.google.com/issues/283987730#comment6
Hi,
FYI, on the main branch, the linking errors about thread_cache_
(and only this error, as this issue seems to mix several unrelated issues) should now be gone (for all non Windows users).
Note: I am not involved at all in Protobuf development, I am just an external contributor who hit this issue and decided to submit a fix for it ;)
Cheers, Romain
Not sure what the status of this issue is, but here's some information that might be helpful. At Homebrew:
-DCMAKE_FIND_PACKAGE_PREFER_CONFIG=ON
and -Dprotobuf_MODULE_COMPATIBLE=ON
to cmake
.^2 I believe this confirms https://github.com/protocolbuffers/protobuf/issues/12746#issuecomment-1555303873.Linux centos also has error:
/usr/local/include/google/protobuf/thread_safe_arena.h:198: undefined reference to google::protobuf::internal::ThreadSafeArena::thread_cache_' /usr/local/include/google/protobuf/thread_safe_arena.h:198: undefined reference to
google::protobuf::internal::ThreadSafeArena::threadcache'
/usr/local/include/google/protobuf/thread_safe_arena.h:198: undefined reference to `google::protobuf::internal::ThreadSafeArena::threadcache'
if message has repeated int32 or int64, i will get errors above, why?
while if message has repeated other type such as message or bytes, it build success...
My solution is define threadcache in my own source code(.pb.cc), like this⬇️.
Why not using up to date probotuf where this very problem is fixed already, without any hack required ?
We triage inactive PRs and issues in order to make it easier to find active work. If this issue should remain active or becomes active again, please add a comment.
This issue is labeled inactive
because the last activity was over 90 days ago.
We triage inactive PRs and issues in order to make it easier to find active work. If this issue should remain active or becomes active again, please reopen it.
This issue was closed and archived because there has been no new activity in the 14 days since the inactive
label was added.
Looks like generated protobuf.pc has in Requires
utf8_range
.