# Build of Catalyst-v5.6.0-Base-Enable-Python fails

**URL:** https://discourse.paraview.org/t/build-of-catalyst-v5-6-0-base-enable-python-fails/1759
**Category:** In Situ Support
**Created:** [May 3, 2019, 6:22pm UTC](https://discourse.paraview.org/t/build-of-catalyst-v5-6-0-base-enable-python-fails/1759 "2019-05-03T18:22:29Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![tesari](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/t/e99b99/32.png) [@tesari](https://discourse.paraview.org/u/tesari)
#### Post date: [May 3, 2019, 6:22pm UTC](https://discourse.paraview.org/t/build-of-catalyst-v5-6-0-base-enable-python-fails/1759/1 "2019-05-03T18:22:29Z")

</div>

Hi,

I am building Catalyst on Linux x86\_64 with gcc 6.3.1. The build fails at the very end, while building pvserver, pvpython, pvbatch and pvdataserver. The error is ‘cannot find openpty’, see attachment. In case that it is relevant, I use a custom build of python-2.7.16, because the system python is 2.6.

Could you advise how to resolve this issue, please?  
Thanks,  
Ted

…  
Scanning dependencies of target vtkPVPythonCatalystPython  
[100%] Building CXX object CMakeFiles/vtkPVPythonCatalystPython.dir/vtkPVPythonCatalystPythonInit.cxx.o  
[100%] Linking CXX static library lib/libvtkPVPythonCatalystPython-pv5.6.a  
[100%] Built target vtkPVPythonCatalystPython  
/ascldap/users/tesari/local/python-2.7.16/lib/libpython2.7.a(posixmodule.o): In function `posix_tmpnam': /ascldap/users/tesari/projects/Python-2.7.16/./Modules/posixmodule.c:7648: warning: the use of`tmpnam\_r’ is dangerous, better use `mkstemp' /ascldap/users/tesari/local/python-2.7.16/lib/libpython2.7.a(posixmodule.o): In function`posix\_tempnam’:  
/ascldap/users/tesari/projects/Python-2.7.16/./Modules/posixmodule.c:7595: warning: the use of `tempnam' is dangerous, better use`mkstemp’  
/ascldap/users/tesari/local/python-2.7.16/lib/libpython2.7.a(posixmodule.o): In function `posix_forkpty': /ascldap/users/tesari/projects/Python-2.7.16/./Modules/posixmodule.c:4022: undefined reference to`forkpty’  
/ascldap/users/tesari/local/python-2.7.16/lib/libpython2.7.a(posixmodule.o): In function `posix_openpty': /ascldap/users/tesari/projects/Python-2.7.16/./Modules/posixmodule.c:3962: undefined reference to`openpty’  
collect2: error: ld returned 1 exit status  
CommandLineExecutables/CMakeFiles/pvdataserver.dir/build.make:155: recipe for target ‘bin/pvdataserver’ failed  
make[2]: \*\*\* [bin/pvdataserver] Error 1  
CMakeFiles/Makefile2:8092: recipe for target ‘CommandLineExecutables/CMakeFiles/pvdataserver.dir/all’ failed  
make[1]: \*\*\* [CommandLineExecutables/CMakeFiles/pvdataserver.dir/all] Error 2  
make[1]: \*\*\* Waiting for unfinished jobs…  
/ascldap/users/tesari/local/python-2.7.16/lib/libpython2.7.a(posixmodule.o): In function `posix_tmpnam': /ascldap/users/tesari/projects/Python-2.7.16/./Modules/posixmodule.c:7648: warning: the use of`tmpnam\_r’ is dangerous, better use `mkstemp' /ascldap/users/tesari/local/python-2.7.16/lib/libpython2.7.a(posixmodule.o): In function`posix\_tempnam’:  
/ascldap/users/tesari/projects/Python-2.7.16/./Modules/posixmodule.c:7595: warning: the use of `tempnam' is dangerous, better use`mkstemp’  
[100%] Built target pvtkpython  
/ascldap/users/tesari/local/python-2.7.16/lib/libpython2.7.a(posixmodule.o): In function `posix_tmpnam': /ascldap/users/tesari/projects/Python-2.7.16/./Modules/posixmodule.c:7648: warning: the use of`tmpnam\_r’ is dangerous, better use `mkstemp' /ascldap/users/tesari/local/python-2.7.16/lib/libpython2.7.a(posixmodule.o): In function`posix\_tempnam’:  
/ascldap/users/tesari/projects/Python-2.7.16/./Modules/posixmodule.c:7595: warning: the use of `tempnam' is dangerous, better use`mkstemp’  
[100%] Built target vtkpython  
/ascldap/users/tesari/local/python-2.7.16/lib/libpython2.7.a(posixmodule.o): In function `posix_tmpnam': /ascldap/users/tesari/projects/Python-2.7.16/./Modules/posixmodule.c:7648: warning: the use of`tmpnam\_r’ is dangerous, better use `mkstemp' /ascldap/users/tesari/local/python-2.7.16/lib/libpython2.7.a(posixmodule.o): In function`posix\_tempnam’:  
/ascldap/users/tesari/projects/Python-2.7.16/./Modules/posixmodule.c:7595: warning: the use of `tempnam' is dangerous, better use`mkstemp’  
/ascldap/users/tesari/local/python-2.7.16/lib/libpython2.7.a(posixmodule.o): In function `posix_forkpty': /ascldap/users/tesari/projects/Python-2.7.16/./Modules/posixmodule.c:4022: undefined reference to`forkpty’  
/ascldap/users/tesari/local/python-2.7.16/lib/libpython2.7.a(posixmodule.o): In function `posix_openpty': /ascldap/users/tesari/projects/Python-2.7.16/./Modules/posixmodule.c:3962: undefined reference to`openpty’  
collect2: error: ld returned 1 exit status  
CommandLineExecutables/CMakeFiles/pvserver.dir/build.make:155: recipe for target ‘bin/pvserver’ failed  
make[2]: \*\*\* [bin/pvserver] Error 1  
CMakeFiles/Makefile2:8399: recipe for target ‘CommandLineExecutables/CMakeFiles/pvserver.dir/all’ failed  
make[1]: \*\*\* [CommandLineExecutables/CMakeFiles/pvserver.dir/all] Error 2  
/ascldap/users/tesari/local/python-2.7.16/lib/libpython2.7.a(posixmodule.o): In function `posix_tmpnam': /ascldap/users/tesari/projects/Python-2.7.16/./Modules/posixmodule.c:7648: warning: the use of`tmpnam\_r’ is dangerous, better use `mkstemp' /ascldap/users/tesari/local/python-2.7.16/lib/libpython2.7.a(posixmodule.o): In function`posix\_tempnam’:  
/ascldap/users/tesari/projects/Python-2.7.16/./Modules/posixmodule.c:7595: warning: the use of `tempnam' is dangerous, better use`mkstemp’  
/ascldap/users/tesari/local/python-2.7.16/lib/libpython2.7.a(posixmodule.o): In function `posix_forkpty': /ascldap/users/tesari/projects/Python-2.7.16/./Modules/posixmodule.c:4022: undefined reference to`forkpty’  
/ascldap/users/tesari/local/python-2.7.16/lib/libpython2.7.a(posixmodule.o): In function `posix_openpty': /ascldap/users/tesari/projects/Python-2.7.16/./Modules/posixmodule.c:3962: undefined reference to`openpty’  
collect2: error: ld returned 1 exit status  
CommandLineExecutables/CMakeFiles/pvbatch.dir/build.make:155: recipe for target ‘bin/pvbatch’ failed  
make[2]: \*\*\* [bin/pvbatch] Error 1  
CMakeFiles/Makefile2:8539: recipe for target ‘CommandLineExecutables/CMakeFiles/pvbatch.dir/all’ failed  
make[1]: \*\*\* [CommandLineExecutables/CMakeFiles/pvbatch.dir/all] Error 2  
/ascldap/users/tesari/local/python-2.7.16/lib/libpython2.7.a(posixmodule.o): In function `posix_tmpnam': /ascldap/users/tesari/projects/Python-2.7.16/./Modules/posixmodule.c:7648: warning: the use of`tmpnam\_r’ is dangerous, better use `mkstemp' /ascldap/users/tesari/local/python-2.7.16/lib/libpython2.7.a(posixmodule.o): In function`posix\_tempnam’:  
/ascldap/users/tesari/projects/Python-2.7.16/./Modules/posixmodule.c:7595: warning: the use of `tempnam' is dangerous, better use`mkstemp’  
/ascldap/users/tesari/local/python-2.7.16/lib/libpython2.7.a(posixmodule.o): In function `posix_forkpty': /ascldap/users/tesari/projects/Python-2.7.16/./Modules/posixmodule.c:4022: undefined reference to`forkpty’  
/ascldap/users/tesari/local/python-2.7.16/lib/libpython2.7.a(posixmodule.o): In function `posix_openpty': /ascldap/users/tesari/projects/Python-2.7.16/./Modules/posixmodule.c:3962: undefined reference to`openpty’  
collect2: error: ld returned 1 exit status  
CommandLineExecutables/CMakeFiles/pvrenderserver.dir/build.make:155: recipe for target ‘bin/pvrenderserver’ failed  
make[2]: \*\*\* [bin/pvrenderserver] Error 1  
CMakeFiles/Makefile2:8297: recipe for target ‘CommandLineExecutables/CMakeFiles/pvrenderserver.dir/all’ failed  
make[1]: \*\*\* [CommandLineExecutables/CMakeFiles/pvrenderserver.dir/all] Error 2  
/ascldap/users/tesari/local/python-2.7.16/lib/libpython2.7.a(posixmodule.o): In function `posix_tmpnam': /ascldap/users/tesari/projects/Python-2.7.16/./Modules/posixmodule.c:7648: warning: the use of`tmpnam\_r’ is dangerous, better use `mkstemp' /ascldap/users/tesari/local/python-2.7.16/lib/libpython2.7.a(posixmodule.o): In function`posix\_tempnam’:  
/ascldap/users/tesari/projects/Python-2.7.16/./Modules/posixmodule.c:7595: warning: the use of `tempnam' is dangerous, better use`mkstemp’  
/ascldap/users/tesari/local/python-2.7.16/lib/libpython2.7.a(posixmodule.o): In function `posix_forkpty': /ascldap/users/tesari/projects/Python-2.7.16/./Modules/posixmodule.c:4022: undefined reference to`forkpty’  
/ascldap/users/tesari/local/python-2.7.16/lib/libpython2.7.a(posixmodule.o): In function `posix_openpty': /ascldap/users/tesari/projects/Python-2.7.16/./Modules/posixmodule.c:3962: undefined reference to`openpty’  
collect2: error: ld returned 1 exit status  
CommandLineExecutables/CMakeFiles/pvpython.dir/build.make:155: recipe for target ‘bin/pvpython’ failed  
make[2]: \*\*\* [bin/pvpython] Error 1  
CMakeFiles/Makefile2:8195: recipe for target ‘CommandLineExecutables/CMakeFiles/pvpython.dir/all’ failed  
make[1]: \*\*\* [CommandLineExecutables/CMakeFiles/pvpython.dir/all] Error 2  
Makefile:129: recipe for target ‘all’ failed  
make: \*\*\* [all] Error 2

---

<div class="post-metadata">

### Author: ![tesari](https://discourse.paraview.org/letter_avatar_proxy/v4/letter/t/e99b99/32.png) [@tesari](https://discourse.paraview.org/u/tesari)
#### Post date: [May 3, 2019, 7:04pm UTC](https://discourse.paraview.org/t/build-of-catalyst-v5-6-0-base-enable-python-fails/1759/2 "2019-05-03T19:04:59Z")

</div>

I figured it out. Linking with -lutil fixed the issue.  
Thanks,  
Ted
