-
Notifications
You must be signed in to change notification settings - Fork 14
Open
Description
Bug:
While trying to build TCGStorage according to the readme (python setup.py opensea followed by python setup.py build), the linker finds multiple defintions for gnutls-namespaced classes and functions. It is also unable to find boost_python310 despite it being installed and on the path.
$ apt-file search gnutls/gnutlsxx.h
libgnutls28-dev: /usr/include/gnutls/gnutlsxx.h
$ apt-file search apt-file search boost/python
libboost1.74-dev: /usr/include/boost/python.hppFull log:
running build
running build_py
copying TCGstorageAPI/pysedSupport.py -> build/lib.linux-x86_64-cpython-310/TCGstorageAPI
copying TCGstorageAPI/__init__.py -> build/lib.linux-x86_64-cpython-310/TCGstorageAPI
copying TCGstorageAPI/tcgapi.py -> build/lib.linux-x86_64-cpython-310/TCGstorageAPI
copying TCGstorageAPI/tcgSupport.py -> build/lib.linux-x86_64-cpython-310/TCGstorageAPI
copying TCGstorageAPI/tcgapi_test.py -> build/lib.linux-x86_64-cpython-310/TCGstorageAPI
running egg_info
writing tcgstorageapi.egg-info/PKG-INFO
writing dependency_links to tcgstorageapi.egg-info/dependency_links.txt
writing requirements to tcgstorageapi.egg-info/requires.txt
writing top-level names to tcgstorageapi.egg-info/top_level.txt
reading manifest file 'tcgstorageapi.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
adding license file 'LICENSE.md'
writing manifest file 'tcgstorageapi.egg-info/SOURCES.txt'
running build_ext
building 'TCGstorageAPI.pysed' extension
clang++ -pthread -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -fPIC -Ipysed -Iopensea-transport/include -Iopensea-common/include -Iopensea-operations/include -Iopensea-transport/include/vendor -I/usr/local/include -I/home/mon/dev/TCGstorageAPI/.venv/include -I/home/mon/.local/share/uv/python/cpython-3.10.15-linux-x86_64-gnu/include/python3.10 -c pysed/TcgDrive.cpp -o build/temp.linux-x86_64-cpython-310/pysed/TcgDrive.o -O0 -g -DDISABLE_NVME_PASSTHROUGH
pysed/TcgDrive.cpp:447:15: warning: variable length arrays in C++ are a Clang extension [-Wvla-cxx-extension]
447 | char bytestr[maxbytes];
| ^~~~~~~~
pysed/TcgDrive.cpp:447:15: note: read of non-const variable 'maxbytes' is not allowed in a constant expression
pysed/TcgDrive.cpp:445:6: note: declared here
445 | int maxbytes = size * 5 + 1;
| ^
pysed/TcgDrive.cpp:449:20: warning: comparison of integers of different signs: 'int' and 'size_t' (aka 'unsigned long') [-Wsign-compare]
449 | for (int i = 0; i < size; i++) {
| ~ ^ ~~~~
2 warnings generated.
clang++ -pthread -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -fPIC -Ipysed -Iopensea-transport/include -Iopensea-common/include -Iopensea-operations/include -Iopensea-transport/include/vendor -I/usr/local/include -I/home/mon/dev/TCGstorageAPI/.venv/include -I/home/mon/.local/share/uv/python/cpython-3.10.15-linux-x86_64-gnu/include/python3.10 -c pysed/TcgScanner.cpp -o build/temp.linux-x86_64-cpython-310/pysed/TcgScanner.o -O0 -g -DDISABLE_NVME_PASSTHROUGH
pysed/TcgScanner.cpp:249:26: warning: unused variable 'len' [-Wunused-variable]
249 | Py_ssize_t len = PyBytes_Size(v);
| ^~~
1 warning generated.
clang++ -pthread -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -fPIC -Ipysed -Iopensea-transport/include -Iopensea-common/include -Iopensea-operations/include -Iopensea-transport/include/vendor -I/usr/local/include -I/home/mon/dev/TCGstorageAPI/.venv/include -I/home/mon/.local/share/uv/python/cpython-3.10.15-linux-x86_64-gnu/include/python3.10 -c pysed/Tls.cpp -o build/temp.linux-x86_64-cpython-310/pysed/Tls.o -O0 -g -DDISABLE_NVME_PASSTHROUGH
clang++ -pthread -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -fPIC -Ipysed -Iopensea-transport/include -Iopensea-common/include -Iopensea-operations/include -Iopensea-transport/include/vendor -I/usr/local/include -I/home/mon/dev/TCGstorageAPI/.venv/include -I/home/mon/.local/share/uv/python/cpython-3.10.15-linux-x86_64-gnu/include/python3.10 -c pysed/parser.tab.cpp -o build/temp.linux-x86_64-cpython-310/pysed/parser.tab.o -O0 -g -DDISABLE_NVME_PASSTHROUGH
pysed/parser.tab.cpp:571:33: warning: equality comparison result unused [-Wunused-comparison]
571 | { yylhs.value.as< list > () == list(); }
| ~~~~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~
pysed/parser.tab.cpp:571:33: note: use '=' to turn this equality comparison into an assignment
571 | { yylhs.value.as< list > () == list(); }
| ^~
| =
pysed/parser.tab.cpp:394:9: warning: variable 'yynerrs_' set but not used [-Wunused-but-set-variable]
394 | int yynerrs_ = 0;
| ^
pysed/parser.tab.cpp:705:7: warning: code will never be executed [-Wunreachable-code]
705 | goto yyerrorlab;
| ^~~~~~~~~~~~~~~
pysed/parser.tab.cpp:704:9: note: silence by adding parentheses to mark code as explicitly dead
704 | if (false)
| ^
| /* DISABLES CODE */ ( )
3 warnings generated.
clang++ -pthread -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -fPIC -Ipysed -Iopensea-transport/include -Iopensea-common/include -Iopensea-operations/include -Iopensea-transport/include/vendor -I/usr/local/include -I/home/mon/dev/TCGstorageAPI/.venv/include -I/home/mon/.local/share/uv/python/cpython-3.10.15-linux-x86_64-gnu/include/python3.10 -c pysed/pysed.cpp -o build/temp.linux-x86_64-cpython-310/pysed/pysed.o -O0 -g -DDISABLE_NVME_PASSTHROUGH
pysed/pysed.cpp:684:6: warning: address of array 'this->tlsCreds' will always evaluate to 'true' [-Wpointer-bool-conversion]
684 | if (tlsCreds) {
| ~~ ^~~~~~~~
pysed/pysed.cpp:754:2: warning: 'PyEval_InitThreads' is deprecated [-Wdeprecated-declarations]
754 | PyEval_InitThreads();
| ^
/home/mon/.local/share/uv/python/cpython-3.10.15-linux-x86_64-gnu/include/python3.10/ceval.h:122:1: note: 'PyEval_InitThreads' has been explicitly marked deprecated here
122 | Py_DEPRECATED(3.9) PyAPI_FUNC(void) PyEval_InitThreads(void);
| ^
/home/mon/.local/share/uv/python/cpython-3.10.15-linux-x86_64-gnu/include/python3.10/pyport.h:513:54: note: expanded from macro 'Py_DEPRECATED'
513 | #define Py_DEPRECATED(VERSION_UNUSED) __attribute__((__deprecated__))
| ^
2 warnings generated.
clang++ -pthread -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -fPIC -Ipysed -Iopensea-transport/include -Iopensea-common/include -Iopensea-operations/include -Iopensea-transport/include/vendor -I/usr/local/include -I/home/mon/dev/TCGstorageAPI/.venv/include -I/home/mon/.local/share/uv/python/cpython-3.10.15-linux-x86_64-gnu/include/python3.10 -c pysed/support.cpp -o build/temp.linux-x86_64-cpython-310/pysed/support.o -O0 -g -DDISABLE_NVME_PASSTHROUGH
clang++ -pthread -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -fPIC -Ipysed -Iopensea-transport/include -Iopensea-common/include -Iopensea-operations/include -Iopensea-transport/include/vendor -I/usr/local/include -I/home/mon/dev/TCGstorageAPI/.venv/include -I/home/mon/.local/share/uv/python/cpython-3.10.15-linux-x86_64-gnu/include/python3.10 -c pysed/transport.cpp -o build/temp.linux-x86_64-cpython-310/pysed/transport.o -O0 -g -DDISABLE_NVME_PASSTHROUGH
clang++ -pthread -Wno-unused-result -Wsign-compare -Wunreachable-code -DNDEBUG -g -fwrapv -O3 -Wall -fPIC -pthread -shared build/temp.linux-x86_64-cpython-310/pysed/TcgDrive.o build/temp.linux-x86_64-cpython-310/pysed/TcgScanner.o build/temp.linux-x86_64-cpython-310/pysed/Tls.o build/temp.linux-x86_64-cpython-310/pysed/parser.tab.o build/temp.linux-x86_64-cpython-310/pysed/pysed.o build/temp.linux-x86_64-cpython-310/pysed/support.o build/temp.linux-x86_64-cpython-310/pysed/transport.o opensea-transport/Make/gcc/lib/libopensea-transport.a opensea-common/Make/gcc/lib/libopensea-common.a opensea-operations/Make/gcc/lib/libopensea-operations.a -L/install/lib -lboost_python -lgnutls -lgnutlsxx -o build/lib.linux-x86_64-cpython-310/TCGstorageAPI/pysed.cpython-310-x86_64-linux-gnu.so
<snip:lots of linker errors regarding gnutls>
/usr/bin/ld: build/temp.linux-x86_64-cpython-310/pysed/pysed.o: in function `gnutls::psk_server_credentials::psk_server_credentials()':
/usr/include/gnutls/gnutlsxx.h:1111: multiple definition of `gnutls::psk_server_credentials::psk_server_credentials()'; build/temp.linux-x86_64-cpython-310/pysed/TcgDrive.o:/usr/include/gnutls/gnutlsxx.h:1111: first defined here
/usr/bin/ld: build/temp.linux-x86_64-cpython-310/pysed/pysed.o: in function `gnutls::psk_client_credentials::psk_client_credentials()':
/usr/include/gnutls/gnutlsxx.h:1144: multiple definition of `gnutls::psk_client_credentials::psk_client_credentials()'; build/temp.linux-x86_64-cpython-310/pysed/TcgDrive.o:/usr/include/gnutls/gnutlsxx.h:1144: first defined here
/usr/bin/ld: build/temp.linux-x86_64-cpython-310/pysed/pysed.o: in function `gnutls::credentials::credentials(gnutls_credentials_type_t)':
/usr/include/gnutls/gnutlsxx.h:1170: multiple definition of `gnutls::credentials::credentials(gnutls_credentials_type_t)'; build/temp.linux-x86_64-cpython-310/pysed/TcgDrive.o:/usr/include/gnutls/gnutlsxx.h:1170: first defined here
/usr/bin/ld: cannot find -lboost_python310: No such file or directory
/usr/bin/ld: cannot find -lgnutlsxx: No such file or directory
Desktop (please complete the following information):
- OS: Ubuntu 24.04
- Python version: Tested across Python 3.8, 3.10, 3.12
clang++version: 18.1.3g++version: 13.2.0
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels