I want to build a certain OpenSSH version with a specific OpenSSL version from sources, but I get the following error:
mkdir /tmp/ssh
cp openssh-6.7p1.tar.gz /tmp/ssh
cp openssl-1.0.1l.tar.gz /tmp/ssh
cd /tmp/ssh
tar zxvf openssl-1.0.1l.tar.gz
cd openssl-1.0.1l
./config --prefix=/tmp/ssh
make
make install
cd ..
tar zxvf openssh-6.7p1.tar.gz
cd openssh-6.7p1
./configure --with-ssl-dir=/tmp/ssh --prefix=/tmp/ssh
...
checking openssl/opensslv.h usability... no
checking openssl/opensslv.h presence... no
checking for openssl/opensslv.h... no
configure: error: *** OpenSSL headers missing - please install first or check config.log ***
Is there a bug in openSSH's configure script or do I have to change any command?
Here's a way without sending flags to ./configure
You need to install OpenSSL first. Get the latest tarball here.
./config
make
make test
make install
Then install libssl-dev
apt-get install libssl-dev
Then you can retry installing OpenSSH:
cd openssh-[version]
./configure
make
make install
ftp://ftp.ca.openbsd.org/pub/OpenBSD/OpenSSH/portable/INSTALL says:
LibreSSL/OpenSSL should be compiled as a position-independent library (i.e. with -fPIC) otherwise OpenSSH will not be able to link with it. If you must use a non-position-independent libcrypto, then you may need to configure OpenSSH --without-pie.
The following commands do not result in the "OpenSSL headers missing" error anymore:
tar zxvf openssl-1.0.1l.tar.gz
cd openssl-1.0.1l
./config --prefix=/tmp/ssh
make
make install
cd ..
tar zxvf openssh-6.7p1.tar.gz
cd openssh-6.7p1
./configure --with-ssl-dir=/tmp/ssh --prefix=/tmp/ssh --without-pie
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With