Build OpenSSL 1.1.1w from source on Debian 11 (x86_64),

To build OpenSSL 1.1.1w from source on Debian 11 (x86_64), follow these steps:

1. Install Dependencies

Before compiling OpenSSL, ensure you have the necessary build tools and dependencies installed:

sh 复制代码
sudo apt update
sudo apt install -y build-essential checkinstall perl zlib1g-dev

2. Download and Extract OpenSSL Source

sh 复制代码
wget https://github.com/openssl/openssl/releases/download/OpenSSL_1_1_1w/openssl-1.1.1w.tar.gz
tar -xvzf openssl-1.1.1w.tar.gz
cd openssl-1.1.1w

3. Configure OpenSSL

Configure OpenSSL with a suitable prefix (e.g., /usr/local/ssl) and enable optimizations:

sh 复制代码
./config --prefix=/usr/local/ssl --openssldir=/usr/local/ssl shared zlib

If you need static libraries instead, remove shared.

4. Compile and Install

sh 复制代码
make -j$(nproc)  # Compiles using all available CPU cores
sudo make install

5. Update Library Paths

Ensure your system uses the newly compiled OpenSSL instead of the default Debian version.

5.1 Add OpenSSL to Library Path
sh 复制代码
echo "/usr/local/ssl/lib" | sudo tee -a /etc/ld.so.conf.d/openssl-1.1.1w.conf
sudo ldconfig
5.2 Update System Paths

Modify your environment variables to prioritize the new OpenSSL:

sh 复制代码
echo 'export PATH="/usr/local/ssl/bin:$PATH"' | sudo tee -a /etc/profile.d/openssl.sh
source /etc/profile.d/openssl.sh

6. Verify Installation

Check if the new OpenSSL version is in use:

sh 复制代码
openssl version -a

You should see OpenSSL 1.1.1w and the correct installation path.

相关推荐
爱莉希雅&&&3 分钟前
shell脚本之条件判断,循环控制,exit详解
linux·运维·服务器·ssh
Sylvan Ding1 小时前
远程主机状态监控-GPU服务器状态监控-深度学习服务器状态监控
运维·服务器·深度学习·监控·远程·gpu状态
北漂老男孩2 小时前
在 Linux 上安装 MATLAB:完整指南与疑难解决方案
linux·运维·matlab
Why not try?!2 小时前
Centos7 中 Docker运行配置Apache
运维·docker·容器
杰克逊的日记2 小时前
Flink运维要点
大数据·运维·flink
hnlucky3 小时前
如何彻底清空docker里面不使用的容器?
运维·docker·容器
像风一样的男人@3 小时前
Linux --systemctl损坏
linux·运维·服务器
南方以南_3 小时前
【云实验】搭建个人网盘实验
linux·运维·服务器
humors2213 小时前
Windows运维工具批处理版
运维·windows·计算机·电脑·笔记本·维护·台式机
xbd_zc4 小时前
【Linux Nano Vim快捷键大全】
linux·运维·vim