nabla-c0d3/nassl

QA Notice: Package triggers severe warnings

Closed this issue · 5 comments

The GCC has an internal checks which could determine code mistakes on the early stage. It can be enabled using -Wall flag. Currently, there are several problems detected:

x86_64-pc-linux-gnu-gcc -march=native -O2 -pipe -fPIC -Ibin/openssl-modern/include -Inassl/_nassl -I/usr/include/python3.6m -c nassl/_nassl/python_utils.c -o /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python3_6/temp.linux-x86_64-3.6/nassl/_nassl/python_utils.o -Wall
x86_64-pc-linux-gnu-gcc -shared -Wl,-O1 -Wl,--as-needed -Wl,--defsym=__gentoo_check_ldflags__=0 -march=native -O2 -pipe /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python3_6/temp.linux-x86_64-3.6/nassl/_nassl/nassl.o /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python3_6/temp.linux-x86_64-3.6/nassl/_nassl/nassl_SSL_CTX.o /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python3_6/temp.linux-x86_64-3.6/nassl/_nassl/nassl_SSL.o /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python3_6/temp.linux-x86_64-3.6/nassl/_nassl/nassl_X509.o /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python3_6/temp.linux-x86_64-3.6/nassl/_nassl/nassl_errors.o /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python3_6/temp.linux-x86_64-3.6/nassl/_nassl/nassl_BIO.o /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python3_6/temp.linux-x86_64-3.6/nassl/_nassl/nassl_X509_EXTENSION.o /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python3_6/temp.linux-x86_64-3.6/nassl/_nassl/nassl_X509_NAME_ENTRY.o /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python3_6/temp.linux-x86_64-3.6/nassl/_nassl/nassl_SSL_SESSION.o /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python3_6/temp.linux-x86_64-3.6/nassl/_nassl/openssl_utils.o /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python3_6/temp.linux-x86_64-3.6/nassl/_nassl/nassl_OCSP_RESPONSE.o /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python3_6/temp.linux-x86_64-3.6/nassl/_nassl/python_utils.o bin/openssl-modern/linux64/libssl.a bin/openssl-modern/linux64/libcrypto.a bin/zlib/linux64/libz.a -L/usr/lib64 -lpython3.6m -o /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python3_6/lib/nassl/_nassl.cpython-36m-x86_64-linux-gnu.so -Wl,-z,noexecstack
>>> Source compiled.
>>> Test phase [not enabled]: dev-python/nassl-1.1.3-r1

>>> Install nassl-1.1.3-r1 into /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/ category dev-python
 * python2_7: running distutils-r1_run_phase distutils-r1_python_install
python2.7 setup.py install --root=/var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python2.7
running install
running build
running build_py
running build_ext
running install_lib
creating /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python2.7
creating /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python2.7/usr
creating /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python2.7/usr/lib64
creating /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python2.7/usr/lib64/python2.7
creating /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python2.7/usr/lib64/python2.7/site-packages
creating /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python2.7/usr/lib64/python2.7/site-packages/nassl
copying /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python2_7/lib/nassl/_nassl.so -> /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python2.7/usr/lib64/python2.7/site-packages/nassl
copying /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python2_7/lib/nassl/_nassl_legacy.so -> /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python2.7/usr/lib64/python2.7/site-packages/nassl
copying /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python2_7/lib/nassl/ocsp_response.py -> /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python2.7/usr/lib64/python2.7/site-packages/nassl
copying /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python2_7/lib/nassl/legacy_ssl_client.py -> /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python2.7/usr/lib64/python2.7/site-packages/nassl
copying /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python2_7/lib/nassl/ssl_client.py -> /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python2.7/usr/lib64/python2.7/site-packages/nassl
copying /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python2_7/lib/nassl/__init__.py -> /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python2.7/usr/lib64/python2.7/site-packages/nassl
byte-compiling /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python2.7/usr/lib64/python2.7/site-packages/nassl/ocsp_response.py to ocsp_response.pyc
byte-compiling /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python2.7/usr/lib64/python2.7/site-packages/nassl/legacy_ssl_client.py to legacy_ssl_client.pyc
byte-compiling /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python2.7/usr/lib64/python2.7/site-packages/nassl/ssl_client.py to ssl_client.pyc
byte-compiling /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python2.7/usr/lib64/python2.7/site-packages/nassl/__init__.py to __init__.pyc
writing byte-compilation script '/var/tmp/portage/dev-python/nassl-1.1.3-r1/temp/tmpnD4NA3.py'
/usr/bin/python2.7 -OO /var/tmp/portage/dev-python/nassl-1.1.3-r1/temp/tmpnD4NA3.py
removing /var/tmp/portage/dev-python/nassl-1.1.3-r1/temp/tmpnD4NA3.py
running install_egg_info
running egg_info
writing requirements to nassl.egg-info/requires.txt
writing nassl.egg-info/PKG-INFO
writing top-level names to nassl.egg-info/top_level.txt
writing dependency_links to nassl.egg-info/dependency_links.txt
reading manifest file 'nassl.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'nassl.egg-info/SOURCES.txt'
Copying nassl.egg-info to /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python2.7/usr/lib64/python2.7/site-packages/nassl-1.1.3-py2.7.egg-info
running install_scripts
 * python3_6: running distutils-r1_run_phase distutils-r1_python_install
python3.6 setup.py install --root=/var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python3.6
running install
running build
running build_py
running build_ext
running install_lib
creating /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python3.6
creating /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python3.6/usr
creating /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python3.6/usr/lib64
creating /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python3.6/usr/lib64/python3.6
creating /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python3.6/usr/lib64/python3.6/site-packages
creating /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python3.6/usr/lib64/python3.6/site-packages/nassl
copying /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python3_6/lib/nassl/_nassl.cpython-36m-x86_64-linux-gnu.so -> /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python3.6/usr/lib64/python3.6/site-packages/nassl
copying /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python3_6/lib/nassl/_nassl_legacy.cpython-36m-x86_64-linux-gnu.so -> /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python3.6/usr/lib64/python3.6/site-packages/nassl
copying /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python3_6/lib/nassl/ocsp_response.py -> /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python3.6/usr/lib64/python3.6/site-packages/nassl
copying /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python3_6/lib/nassl/legacy_ssl_client.py -> /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python3.6/usr/lib64/python3.6/site-packages/nassl
copying /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python3_6/lib/nassl/ssl_client.py -> /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python3.6/usr/lib64/python3.6/site-packages/nassl
copying /var/tmp/portage/dev-python/nassl-1.1.3-r1/work/nassl-1.1.3-python3_6/lib/nassl/__init__.py -> /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python3.6/usr/lib64/python3.6/site-packages/nassl
byte-compiling /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python3.6/usr/lib64/python3.6/site-packages/nassl/ocsp_response.py to ocsp_response.cpython-36.pyc
byte-compiling /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python3.6/usr/lib64/python3.6/site-packages/nassl/legacy_ssl_client.py to legacy_ssl_client.cpython-36.pyc
byte-compiling /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python3.6/usr/lib64/python3.6/site-packages/nassl/ssl_client.py to ssl_client.cpython-36.pyc
byte-compiling /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python3.6/usr/lib64/python3.6/site-packages/nassl/__init__.py to __init__.cpython-36.pyc
writing byte-compilation script '/var/tmp/portage/dev-python/nassl-1.1.3-r1/temp/tmp4pry6si5.py'
/usr/bin/python3.6 /var/tmp/portage/dev-python/nassl-1.1.3-r1/temp/tmp4pry6si5.py
removing /var/tmp/portage/dev-python/nassl-1.1.3-r1/temp/tmp4pry6si5.py
writing byte-compilation script '/var/tmp/portage/dev-python/nassl-1.1.3-r1/temp/tmpst37l7on.py'
/usr/bin/python3.6 /var/tmp/portage/dev-python/nassl-1.1.3-r1/temp/tmpst37l7on.py
removing /var/tmp/portage/dev-python/nassl-1.1.3-r1/temp/tmpst37l7on.py
running install_egg_info
running egg_info
writing nassl.egg-info/PKG-INFO
writing dependency_links to nassl.egg-info/dependency_links.txt
writing requirements to nassl.egg-info/requires.txt
writing top-level names to nassl.egg-info/top_level.txt
reading manifest file 'nassl.egg-info/SOURCES.txt'
reading manifest template 'MANIFEST.in'
writing manifest file 'nassl.egg-info/SOURCES.txt'
Copying nassl.egg-info to /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/_python3.6/usr/lib64/python3.6/site-packages/nassl-1.1.3-py3.6.egg-info
running install_scripts
 * python3_6: running distutils-r1_run_phase distutils-r1_python_install_all
>>> Completed installing nassl-1.1.3-r1 into /var/tmp/portage/dev-python/nassl-1.1.3-r1/image/

 * Final size of build directory: 227748 KiB (222.4 MiB)
 * Final size of installed tree:   14604 KiB ( 14.2 MiB)


 * QA Notice: Package triggers severe warnings which indicate that it
 *            may exhibit random runtime failures.
 * nassl/_nassl/nassl_SSL_CTX.c:383:5: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
 * nassl/_nassl/nassl_SSL.c:297:9: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
 * nassl/_nassl/nassl_SSL.c:301:9: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
 * nassl/_nassl/nassl_SSL.c:1050:5: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
 * nassl/_nassl/nassl_X509.c:387:5: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
 * nassl/_nassl/nassl_BIO.c:200:5: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
 * nassl/_nassl/nassl_X509_EXTENSION.c:77:9: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
 * nassl/_nassl/nassl_X509_EXTENSION.c:81:9: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
 * nassl/_nassl/nassl_X509_EXTENSION.c:154:5: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
 * nassl/_nassl/nassl_X509_NAME_ENTRY.c:164:5: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
 * nassl/_nassl/nassl_SSL_SESSION.c:137:5: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
 * nassl/_nassl/nassl_OCSP_RESPONSE.c:205:5: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
 * nassl/_nassl/nassl_SSL_CTX.c:383:5: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
 * nassl/_nassl/nassl_SSL.c:297:9: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
 * nassl/_nassl/nassl_SSL.c:301:9: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
 * nassl/_nassl/nassl_SSL.c:1050:5: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
 * nassl/_nassl/nassl_X509.c:387:5: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
 * nassl/_nassl/nassl_BIO.c:200:5: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
 * nassl/_nassl/nassl_X509_EXTENSION.c:77:9: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
 * nassl/_nassl/nassl_X509_EXTENSION.c:81:9: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
 * nassl/_nassl/nassl_X509_EXTENSION.c:154:5: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
 * nassl/_nassl/nassl_X509_NAME_ENTRY.c:164:5: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
 * nassl/_nassl/nassl_SSL_SESSION.c:137:5: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]
 * nassl/_nassl/nassl_OCSP_RESPONSE.c:205:5: warning: dereferencing type-punned pointer will break strict-aliasing rules [-Wstrict-aliasing]

 * Please do not file a Gentoo bug and instead report the above QA
 * issues directly to the upstream developers of this software.
 * Homepage: https://github.com/nabla-c0d3/nassl

It is possible to disable these warnings with "--no-string-aliasing" flag but it just hides the problem.
I suggest to have a look at the root cause and fix it.

gcc-7.3.0
nassl-1.1.3

Thanks for the report!

It looks like this is an issue with Python 2 (Specifically the Py_INCREF & similar macros): boostorg/python#179 .

I will drop support for Python 2 in the next version version so this should no longer be an issue anyway.

wow, this is complicated. I tried to compile without python2.7 and confirm it compiles without warnings.
Thank you for this hint!

the issue is fixed, thank you.