lidavidm commented on a change in pull request #11006:
URL: https://github.com/apache/arrow/pull/11006#discussion_r697451454



##########
File path: dev/tasks/linux-packages/apache-arrow/debian/rules
##########
@@ -47,6 +47,8 @@ override_dh_auto_configure:
          -DCMAKE_BUILD_TYPE=$(BUILD_TYPE)                      \
          -DCMAKE_UNITY_BUILD=ON                                \
          -DPARQUET_REQUIRE_ENCRYPTION=ON                       \
+         -DProtobuf_SOURCE=BUNDLED                             \
+         -DgRPC_SOURCE=BUNDLED                                 \

Review comment:
       It seems something about the build causes Protobuf to not be linked 
against pthreads. Protoc then crashes instantly when it tries to use 
std::call_once. Despite the `-lpthread` below. Forcing it to load pthreads at 
runtime via LD_PRELOAD causes the later protoc invocation to succeed.
   
   ```
   [200/201] : && /usr/bin/c++ -g -O0 
-ffile-prefix-map=/build/apache-arrow-6.0.0~dev20210827=. -flto=auto 
-ffat-lto-objects -fstack-protector-strong -Wformat -Werror=format-security 
-fdiagnostics-color=always -O3 -DNDEBUG -O3 -DNDEBUG -fPIC  -g -O0 
-ffile-prefix-map=/build/apache-arrow-6.0.0~dev20210827=. -flto=auto 
-ffat-lto-objects -fstack-protector-strong -Wformat -Werror=format-security 
-fdiagnostics-color=always -O3 -DNDEBUG -O3 -DNDEBUG -fPIC 
-Wl,-Bsymbolic-functions -flto=auto -Wl,-z,relro   -rdynamic 
'CMakeFiles/protoc.dir/build/apache-arrow-6.0.0~dev20210827/cpp_build/protobuf_ep-prefix/src/protobuf_ep/src/google/protobuf/compiler/main.cc.o'
 -o protoc-3.17.3.0  -Wl,-rpath,::::::::::::::  libprotoc.a  libprotobuf.a  
-lpthread  /usr/lib/x86_64-linux-gnu/libz.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: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


Reply via email to