New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
_multiprocessing module builds incorrectly when POSIX semaphores are disabled #65903
Comments
When POSIX semaphores are disabled (e.g. by unmounting /dev/shm on a Linux system), then _multiprocessing module builds with undefined symbol _PyMp_sem_unlink: $ ./configure ...
...
checking whether POSIX semaphores are enabled... no
...
$ make
...
building '_multiprocessing' extension
creating build/temp.linux-x86_64-3.5/tmp/cpython/Modules/_multiprocessing
x86_64-pc-linux-gnu-gcc -pthread -fPIC -Wno-unused-result -Werror=declaration-after-statement -DNDEBUG -march=core2 -O2 -fno-ident -pipe -ggdb3 -Wall -Wpointer-sign -IModules/_multiprocessing -I./Include -I. -IInclude -I/usr/local/include -I/tmp/cpython/Include -I/tmp/cpython -c /tmp/cpython/Modules/_multiprocessing/multiprocessing.c -o build/temp.linux-x86_64-3.5/tmp/cpython/Modules/_multiprocessing/multiprocessing.o
x86_64-pc-linux-gnu-gcc -pthread -shared -Wl,-O1 -Wl,--as-needed -Wl,--gc-sections -Wl,--hash-style=gnu -Wl,--sort-common build/temp.linux-x86_64-3.5/tmp/cpython/Modules/_multiprocessing/multiprocessing.o -L. -L/usr/local/lib -lpython3.5m -o build/lib.linux-x86_64-3.5/_multiprocessing.cpython-35m.so
*** WARNING: renaming "_multiprocessing" since importing it failed: build/lib.linux-x86_64-3.5/_multiprocessing.cpython-35m.so: undefined symbol: _PyMp_sem_unlink
...
Following modules built successfully but were removed because they could not be imported:
_multiprocessing This problem was introduced in Python 3.4. This problem is absent in older versions of Python. --- Modules/_multiprocessing/multiprocessing.c
+++ Modules/_multiprocessing/multiprocessing.c
@@ -129,5 +129,7 @@
{"send", multiprocessing_send, METH_VARARGS, ""},
#endif
+#ifndef POSIX_SEMAPHORES_NOT_ENABLED
{"sem_unlink", _PyMp_sem_unlink, METH_VARARGS, ""},
+#endif
{NULL}
}; |
New changeset f618f6739200 by Richard Oudkerk in branch '3.4': New changeset a9637b29954d by Richard Oudkerk in branch 'default': |
New changeset 1a00be3d79bc by Ezio Melotti in branch '3.4': New changeset 723e0a7c4914 by Ezio Melotti in branch 'default': |
For reference and breadcrumbs, this also occurs when: checking for sem_open... yes This can occur on FreeBSD jails, among other things, when host & jail versions differ. Attaching full QA log from RedPorts on FreeBSD 8.4-RELEASE |
Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.
Show more details
GitHub fields:
bugs.python.org fields:
The text was updated successfully, but these errors were encountered: