Installing Python3.12 With SSL Module
Below is the process to download, compile, and install a new version of Python3 within Debian Linux. This drove me crazy for a while trying to figure out how to include the SSL module.
Python3 Alternative install
## make source code folder:
$ mkdir -pv sourcecode/python3.12
$ cd sourcecode/python3.12
## Download the latest version that you want with wget:
$ wget https://www.python.org/ftp/python/3.12.0/Python-3.12.0.tgz
$ ./configure --with-openssl=/usr --enable-optimizations
$ make -j $(nproc)
$ sudo make altinstall
## Test the install and ensure it includes SSL module:
$ python3.12 -c "import ssl; print(ssl.OPENSSL_VERSION)"
## should output something like:
OpenSSL 1.1.1w 11 Sep 2023
