pkgsrc-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

pkg/55642: lang/python37 No module named '_posixsubprocess'



>Number:         55642
>Category:       pkg
>Synopsis:       lang/python37 No module named '_posixsubprocess'
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    pkg-manager
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Sat Sep 05 02:00:01 +0000 2020
>Originator:     David Shao
>Release:        pkgsrc current cvs
>Organization:
>Environment:
NetBSD xxxxxx.xxx 9.99.72 NetBSD 9.99.72 (GENERIC) #3: Thu Sep  3 01:40:27 PDT 2020  xxxxxx.xxx:/usr/obj/sys/arch/amd64/compile/GENERIC amd64
>Description:
NetBSD 9.99.72, X11_TYPE=native, pkgsrc current cvs, running a custom shell script that make replaces all prerequisites and then lang/python37, build fails with error message below.  This failure to build also has been observed on FreeBSD 12.1 release and on current DragonFly.

LD_LIBRARY_PATH=/usr/pkgsrc/lang/python37/work/Python-3.7.9 ./python -E -S -m sysconfig --generate-posix-vars ; if test $? -ne 0 ; then  echo "generate-posix-vars failed" ;  rm -f ./pybuilddir.txt ;  exit 1 ;  fi
gcc -pthread -c -fPIC -Wno-unused-result -Wsign-compare -DNDEBUG -O2 -g -D_FORTIFY_SOURCE=2 -I/usr/include -I/usr/pkg/include -O2 -g -D_FORTIFY_SOURCE=2 -I/usr/include -I/usr/pkg/include -O2 -g -D_FORTIFY_SOURCE=2 -I/usr/include -I/usr/pkg/include  -std=gnu99 -Wextra -Wno-unused-result -Wno-unused-parameter -Wno-missing-field-initializers -Wno-cast-function-type -Werror=implicit-function-declaration   -I. -I./Include -I/usr/include -I/usr/pkg/include -I/usr/include -I/usr/pkg/include -fPIC -DPy_BUILD_CORE -o Modules/_math.o Modules/_math.c
LD_LIBRARY_PATH=/usr/pkgsrc/lang/python37/work/Python-3.7.9 CC='gcc -pthread' LDSHARED='gcc -pthread -shared -L. -L/usr/lib -Wl,-R/usr/lib -L/usr/pkg/lib -Wl,-R/usr/pkg/lib -L/usr/X11R7/lib -Wl,-R/usr/X11R7/lib -L/usr/lib -Wl,-R/usr/lib -L/usr/pkg/lib -Wl,-R/usr/pkg/lib -L/usr/X11R7/lib -Wl,-R/usr/X11R7/lib  ' OPT='-DNDEBUG -O2 -g -D_FORTIFY_SOURCE=2 -I/usr/include -I/usr/pkg/include'  _TCLTK_INCLUDES='' _TCLTK_LIBS=''  ./python -E ./setup.py  build
Traceback (most recent call last):
  File "./setup.py", line 10, in <module>
    from distutils import log
  File "/usr/pkg/lib/python3.7/site-packages/_distutils_hack/__init__.py", line 83, in create_module
    return importlib.import_module('._distutils', 'setuptools')
  File "/usr/pkgsrc/lang/python37/work/Python-3.7.9/Lib/importlib/__init__.py", line 127, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "/usr/pkg/lib/python3.7/site-packages/setuptools/__init__.py", line 8, in <module>
    import _distutils_hack.override  # noqa: F401
  File "/usr/pkg/lib/python3.7/site-packages/_distutils_hack/override.py", line 1, in <module>
    __import__('_distutils_hack').do_override()
  File "/usr/pkg/lib/python3.7/site-packages/_distutils_hack/__init__.py", line 64, in do_override
    ensure_local_distutils()
  File "/usr/pkg/lib/python3.7/site-packages/_distutils_hack/__init__.py", line 51, in ensure_local_distutils
    core = importlib.import_module('distutils.core')
  File "/usr/pkgsrc/lang/python37/work/Python-3.7.9/Lib/importlib/__init__.py", line 127, in import_module
    return _bootstrap._gcd_import(name[level:], package, level)
  File "/usr/pkg/lib/python3.7/site-packages/setuptools/_distutils/core.py", line 16, in <module>
    from distutils.dist import Distribution
  File "/usr/pkg/lib/python3.7/site-packages/setuptools/_distutils/dist.py", line 19, in <module>
    from distutils.util import check_environ, strtobool, rfc822_escape
  File "/usr/pkg/lib/python3.7/site-packages/setuptools/_distutils/util.py", line 14, in <module>
    from distutils.spawn import spawn
  File "/usr/pkg/lib/python3.7/site-packages/setuptools/_distutils/spawn.py", line 11, in <module>
    import subprocess
  File "/usr/pkgsrc/lang/python37/work/Python-3.7.9/Lib/subprocess.py", line 152, in <module>
    import _posixsubprocess
ModuleNotFoundError: No module named '_posixsubprocess'


>How-To-Repeat:
From /etc/mk.conf

.ifdef BSD_PKG_MK   # begin pkgsrc settings

CURSES_DEFAULT=ncurses
READLINE_DEFAULT=readline

PREFER.libexecinfo=native

PYTHON_VERSION_DEFAULT=37

CFLAGS+= -g
INSTALL_UNSTRIPPED=yes
USE_DESTDIR=yes

...

.endif              # end pkgsrc settings

MKDEBUG=yes
MKDEBUGLIB=yes
MKKDEBUG=yes
>Fix:



Home | Main Index | Thread Index | Old Index