Skip to content

Commit b467fb3

Browse files
committed
Fix segfault in recent wheel builds
The 0.2.1 tag introduced ceres-solver + Eigen + GLOG into the compiled dependencies and into the wheel building scripts. The resulting wheels, when installed into a conda environment, triggered a segfault inside the conda-forge glog package. I am not sure the cause of this, since the glog library vendored in the so3g wheels should have its name modified to avoid such conflicts. This work changes the compilation inside the wheels to build and link static versions of glog and ceres-solver. I tested a locally-built (which cibuildwheel) wheel and verified that the segfault is now gone and that sotodlib master branch unit tests pass using this so3g wheel.
1 parent 17ffe9b commit b467fb3

2 files changed

Lines changed: 8 additions & 2 deletions

File tree

wheels/install_deps_linux.sh

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -215,6 +215,9 @@ tar xzf ${glog_pkg} \
215215
-DCMAKE_CXX_FLAGS="${CXXFLAGS}" \
216216
-DCMAKE_VERBOSE_MAKEFILE:BOOL=ON \
217217
-DCMAKE_INSTALL_PREFIX="${PREFIX}" \
218+
-DWITH_GFLAGS:BOOL=OFF \
219+
-DWITH_GTEST:BOOL=OFF \
220+
-DBUILD_SHARED_LIBS:BOOL=OFF \
218221
.. \
219222
&& make -j ${MAKEJ} install \
220223
&& popd >/dev/null 2>&1 \
@@ -249,7 +252,7 @@ tar xzf ${ceres_pkg} \
249252
-DCMAKE_INSTALL_PREFIX="${PREFIX}" \
250253
-DBUILD_EXAMPLES=OFF \
251254
-DBUILD_BENCHMARKS=OFF \
252-
-DBUILD_SHARED_LIBS=ON \
255+
-DBUILD_SHARED_LIBS=OFF \
253256
-DBUILD_TESTING=OFF \
254257
-DGFLAGS=OFF \
255258
-DSUITESPARSE=OFF \

wheels/install_deps_osx.sh

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -253,6 +253,9 @@ tar xzf ${glog_pkg} \
253253
-DCMAKE_CXX_FLAGS="${CXXFLAGS}" \
254254
-DCMAKE_VERBOSE_MAKEFILE:BOOL=ON \
255255
-DCMAKE_INSTALL_PREFIX="${PREFIX}" \
256+
-DWITH_GFLAGS:BOOL=OFF \
257+
-DWITH_GTEST:BOOL=OFF \
258+
-DBUILD_SHARED_LIBS:BOOL=OFF \
256259
.. \
257260
&& make -j ${MAKEJ} install \
258261
&& popd >/dev/null 2>&1 \
@@ -287,7 +290,7 @@ tar xzf ${ceres_pkg} \
287290
-DCMAKE_INSTALL_PREFIX="${PREFIX}" \
288291
-DBUILD_EXAMPLES=OFF \
289292
-DBUILD_BENCHMARKS=OFF \
290-
-DBUILD_SHARED_LIBS=ON \
293+
-DBUILD_SHARED_LIBS=OFF \
291294
-DBUILD_TESTING=OFF \
292295
-DGFLAGS=OFF \
293296
-DSUITESPARSE=OFF \

0 commit comments

Comments
 (0)