I try to install OpenSSH
./configure
checking for openssl/opensslv.h... no
configure: error: *** OpenSSL headers missing
any idea?
I try to install OpenSSH
./configure
checking for openssl/opensslv.h... no
configure: error: *** OpenSSL headers missing
any idea?
I would install the openssh server package if you have a choice apt-get install openssh-server
. However if you want to compile from source install openssl first.
Either from source or from the package: apt-get install libssl-dev openssl
To install dependencies needed to build a given package, you can use apt-get's build-dep option, e.g., apt-get build-dep openssh
or apt-get build-dep openssh-server
if you are trying to build the server.
tl;dr download, unpack, configure, build, install
Using version 9.0p1
as an example:
wget https://cdn.openbsd.org/pub/OpenBSD/OpenSSH/portable/openssh-9.0p1.tar.gz
tar -xvf openssh-9.0p1.tar.gz
cd openssh-9.0p1
./configure
make
make install
Make sure to download the Portable Release source code (unless running OpenBSD OS).
Optionally, verify the download before the tar
command:
wget https://cdn.openbsd.org/pub/OpenBSD/OpenSSH/RELEASE_KEY.asc
gpg --import RELEASE_KEY.asc
wget https://cdn.openbsd.org/pub/OpenBSD/OpenSSH/portable/openssh-9.0p1.tar.gz.asc
gpg --verbose --verify openssh-9.0p1.tar.gz.asc
If there is a missing header or library during the ./configure
command, you can view the dependencies for the built-in OpenSSH using apt
apt show openssh-server
The packages listed under Depends:
will most likely be adequate for building the downloaded OpenSSH .tar
.
Install the needed dependencies for building using apt install
.
A few extra packages I installed on my Debian 10 system:
apt install \
libssl-dev \
gcc g++ gdb cpp \
make cmake \
libtool \
libc6 \
autoconf automake pkg-config \
build-essential \
gettext
I wrote a full step-by-step write-up for installing the latest OpenSSH.
It's likely you are missing the development headers for openssl. Try installing "openssl-devel".