Skip to content

Commit 28caf61

Browse files
aporialiaofacebook-github-bot
authored andcommitted
Allow undefined libraries to fix CMake errors
Summary: This should get rid of the `libtorch_cpu.so: undefined reference to `logf@GLIBC_2.27'` etc.. we see in our cpp unit tests on Github CI See: https://fb.workplace.com/groups/1405155842844877/permalink/23944202491846891/ Note there is another error of undefined reference - but it's related to our library not installing google benchmark rather than something inside of torch.so file like the ones mentioned in post. Differential Revision: D71862824
1 parent fb1f2c4 commit 28caf61

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

.github/workflows/cpp_unittest_ci_cpu.yml

+2-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
# This workflow will install Python dependencies, run tests and lint with a variety of Python versions
22
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions
33

4-
name: CPU Unit Test C++ CI
4+
name: C++ CPU Unit Test CI
55

66
on:
77
push:
@@ -58,6 +58,7 @@ jobs:
5858
conda run -n build_binary cmake \
5959
-DBUILD_TEST=ON \
6060
-DBUILD_REDIS_IO=ON \
61+
-DCMAKE_EXE_LINKER_FLAGS=-Wl,--allow-shlib-undefined \
6162
-DCMAKE_PREFIX_PATH=/opt/conda/envs/build_binary/lib/python${{ matrix.python-version }}/site-packages/torch/share/cmake ..
6263
conda run -n build_binary make -j
6364
conda run -n build_binary ctest -V .

0 commit comments

Comments
 (0)