evgeny-gridasov / openvpn-otp

OpenVPN OTP token support plugin
GNU General Public License v3.0
279 stars 74 forks source link

./configure fails on centos7 with 'OpenVPN headers missing' #8

Closed rene00 closed 8 years ago

rene00 commented 8 years ago

The openvpn RPM shipped with EPEL for CentOS7 places openvpn-plugin.h in /usr/include.

# ./configure --prefix=/usr
...
checking openvpn/openvpn-plugin.h usability... no
checking openvpn/openvpn-plugin.h presence... no
checking for openvpn/openvpn-plugin.h... no
configure: error: OpenVPN headers missing

Quick fix

# rpm -ql openvpn |grep openvpn-plugin.h
/usr/include/openvpn-plugin.h
# mkdir /usr/include/openvpn
# ln -sf /usr/include/openvpn-plugin.h /usr/include/openvpn/

Should something like this be mentioned within the README?

evgeny-gridasov commented 8 years ago

I've modified configure.ac to check for headers in /usr/include as well and added #ifdef sections accordingly. Please 0567fdd for details.

aioue commented 7 years ago

Same error. Lib does not exist on the system here.

edit: fixed by installing devel package as well as core (# yum install openvpn-devel)

# ./configure --prefix=/usr
...
checking openvpn/openvpn-plugin.h usability... no
checking openvpn/openvpn-plugin.h presence... no
checking for openvpn/openvpn-plugin.h... no
checking openvpn-plugin.h usability... no
checking openvpn-plugin.h presence... no
checking for openvpn-plugin.h... no
configure: error: OpenVPN headers missing

# rpm --query centos-release
centos-release-7-3.1611.el7.centos.x86_64

# uname -a
Linux ip-10-194-1-53 3.10.0-514.21.1.el7.x86_64 #1 SMP Thu May 25 17:04:51 UTC 2017 x86_64 x86_64 x86_64 GNU/Linux

# rpm --query epel-release
epel-release-7-9.noarch

# openvpn --version
OpenVPN 2.4.2 x86_64-redhat-linux-gnu [Fedora EPEL patched] [SSL (OpenSSL)] [LZO] [LZ4] [EPOLL] [PKCS11] [MH/PKTINFO] [AEAD] built on May 11 2017
library versions: OpenSSL 1.0.1e-fips 11 Feb 2013, LZO 2.06
Originally developed by James Yonan
Copyright (C) 2002-2017 OpenVPN Technologies, Inc. <sales@openvpn.net>
Compile time defines: enable_async_push=no enable_comp_stub=no enable_crypto=yes enable_crypto_ofb_cfb=yes enable_debug=yes enable_def_auth=yes enable_dependency_tracking=no enable_dlopen=unknown enable_dlopen_self=unknown enable_dlopen_self_static=unknown enable_fast_install=yes enable_fragment=yes enable_iproute2=yes enable_libtool_lock=yes enable_lz4=yes enable_lzo=yes enable_management=yes enable_multi=yes enable_multihome=yes enable_pam_dlopen=no enable_pedantic=no enable_pf=yes enable_pkcs11=yes enable_plugin_auth_pam=yes enable_plugin_down_root=yes enable_plugins=yes enable_port_share=yes enable_selinux=yes enable_server=yes enable_shared=yes enable_shared_with_static_runtimes=no enable_small=no enable_static=yes enable_strict=no enable_strict_options=no enable_systemd=yes enable_werror=no enable_win32_dll=yes enable_x509_alt_username=no with_crypto_library=openssl with_gnu_ld=yes with_mem_check=no with_sysroot=no

# locate openvpn-plugin
/usr/lib64/openvpn/plugins/openvpn-plugin-auth-pam.so
/usr/lib64/openvpn/plugins/openvpn-plugin-down-root.so