HipToday
Members-
Posts
32 -
Joined
-
Last visited
Never -
Donations
0.00 GBP
HipToday's Achievements
Advanced Member (3/3)
0
Reputation
-
From what I've seen and read these steps: are unnecessary and will break things (though the threads discussing that had different issues than what you're describing).
-
Except then you end up with over 100MB of stuff in your source code that you don't need.
-
I've tried both NetSky's 5.7.6 patch and ApoC's 5.7.5 patch for FreeBSD on OpenBSD 4.7-beta and neither compiled. I didn't have the time to dig into it very far, but I do know that with NetSky's patch I was having similar issues to the ones reported by ApoC (missing .inl files).
-
@Snake_Plissken: It looks like maybe the patch didn't apply cleanly. @Samuell.Sk: There's no indication at all that OpenSSL was even looked for in that log, I'd expect to at least see an attempt and a failure with the OpenSSL check. Also make sure the patch is applying cleanly for you. @ALL: When testing this stuff it is best to start with a clean clone of the repository and do everything from scratch, the idea being to eliminate as many variables as possible. I've tested this stuff on Ubuntu Desktop 9.10, Ubunter Server 8.04.3, Debian 5.03, and OpenBSD-current (all i386, 32-bit) and the only time I've been able to reproduce the compile errors is when I remove the libssl-dev package. I'm having a hell of a time figuring out what is different on the systems people are having issues on. This is frustrating for me too, my whole goal with this was to get MaNGOS compiling on more systems. I appreciate all of your feedback .
-
I was looking at this more over the weekend and came up with something similar. But why did you change OPENSSL_INCLUDES to OPENSSL_CPPFLAGS? I was going to change it to OPENSSL_CFLAGS as that is what it looked like was being set previously. My alternate patch also changes the pkg-config commands a little bit, and adds an error message if the OpenSSL check fails (which should have been there all along, but I was hurrying to try to fix people's issues). diff --git a/configure.ac b/configure.ac index 57cf30e..cdc3ce1 100644 --- a/configure.ac +++ b/configure.ac @@ -97,7 +97,7 @@ AC_CHECK_LIB( pthread, pthread_create, [], ]) AC_CHECK_LIB( z, compress, [ZLIB=-lz],[AC_MSG_ERROR([Missing zlib])] ) AC_CHECK_LIB( compat, ftime, [COMPATLIB=-lcompat] ) -AX_CHECK_OPENSSL() +AX_CHECK_OPENSSL([], [AC_MSG_ERROR([Missing OpenSSL])]) AC_ARG_WITH(postgresql, [ --with-postgresql Use PostgreSQL as a backend (default: no)], diff --git a/m4/ax_check_openssl.m4 b/m4/ax_check_openssl.m4 index 7f5c319..3b5ed9c 100644 --- a/m4/ax_check_openssl.m4 +++ b/m4/ax_check_openssl.m4 @@ -31,6 +31,9 @@ # permitted in any medium without royalty provided the copyright notice # and this notice are preserved. This file is offered as-is, without any # warranty. +# +# MaNGOS local changes: OPENSSL_INCLUDES replaced by OPENSSL_CFLAGS for +# better compatibility with the way PKG_CONFIG previously worked. AU_ALIAS([CHECK_SSL], [AX_CHECK_OPENSSL]) AC_DEFUN([AX_CHECK_OPENSSL], [ @@ -53,8 +56,8 @@ AC_DEFUN([AX_CHECK_OPENSSL], [ if test x"$PKG_CONFIG" != x""; then OPENSSL_LDFLAGS=`$PKG_CONFIG openssl --libs-only-L 2>/dev/null` if test $? = 0; then - OPENSSL_LIBS=`$PKG_CONFIG openssl --libs-only-l 2>/dev/null` - OPENSSL_INCLUDES=`$PKG_CONFIG openssl --cflags-only-I 2>/dev/null` + OPENSSL_LIBS=`$PKG_CONFIG openssl --libs 2>/dev/null` + OPENSSL_CFLAGS=`$PKG_CONFIG openssl --cflags 2>/dev/null` found=true fi fi @@ -71,11 +74,11 @@ AC_DEFUN([AX_CHECK_OPENSSL], [ # an 'openssl' subdirectory if ! $found; then - OPENSSL_INCLUDES= + OPENSSL_CFLAGS= for ssldir in $ssldirs; do AC_MSG_CHECKING([for openssl/ssl.h in $ssldir]) if test -f "$ssldir/include/openssl/ssl.h"; then - OPENSSL_INCLUDES="-I$ssldir/include" + OPENSSL_CFLAGS="-I$ssldir/include" OPENSSL_LDFLAGS="-L $ssldir/lib" OPENSSL_LIBS="-lssl -lcrypto" found=true @@ -95,14 +98,14 @@ AC_DEFUN([AX_CHECK_OPENSSL], [ AC_MSG_CHECKING([whether compiling and linking against OpenSSL works]) echo "Trying link with OPENSSL_LDFLAGS=$OPENSSL_LDFLAGS;" \\ - "OPENSSL_LIBS=$OPENSSL_LIBS; OPENSSL_INCLUDES=$OPENSSL_INCLUDES" >&AS_MESSAGE_LOG_FD + "OPENSSL_LIBS=$OPENSSL_LIBS; OPENSSL_CFLAGS=$OPENSSL_CFLAGS" >&AS_MESSAGE_LOG_FD save_LIBS="$LIBS" save_LDFLAGS="$LDFLAGS" save_CPPFLAGS="$CPPFLAGS" LDFLAGS="$LDFLAGS $OPENSSL_LDFLAGS" LIBS="$OPENSSL_LIBS $LIBS" - CPPFLAGS="$OPENSSL_INCLUDES $CPPFLAGS" + CPPFLAGS="$OPENSSL_CFLAGS $CPPFLAGS" AC_LINK_IFELSE( AC_LANG_PROGRAM([#include <openssl/ssl.h>], [sSL_new(NULL)]), [ @@ -116,7 +119,7 @@ AC_DEFUN([AX_CHECK_OPENSSL], [ LDFLAGS="$save_LDFLAGS" LIBS="$save_LIBS" - AC_SUBST([OPENSSL_INCLUDES]) + AC_SUBST([OPENSSL_CFLAGS]) AC_SUBST([OPENSSL_LIBS]) AC_SUBST([OPENSSL_LDFLAGS]) ]) I'm testing this as I post this on Ubuntu Server 8.04.3, but since I didn't have problems before, it won't really mean much unless some other folks out there test it.
-
Alright, with my fix posted above applied to 9225, I'm able to compile fine on Ubuntu 9.10 Desktop and OpenBSD-current (both i386). So now I don't know if my original patch to configure.ac should be reverted or if my fix, submitted afterwords, should just be committed. Have other people tried the fix I posted on freshly checked out code? alein?
-
It seems the AX_CHECK_OPENSSL() macro already tries to use pkg-config to find OpenSSL before searching in some standard default locations, so nesting it in the PKG_CHECK_MODULES() macro was redundant. That caused some weird nesting issues in the configure script that I didn't see since pkg-config doesn't find OpenSSL on OpenBSD. Hopefully this new patch will fix these issues in environments where pkg-config and OpenSSL work as expected. Thanks for the commit anyway!
Contact Us
To contact us
click here
You can also email us at [email protected]
Privacy Policy | Terms & Conditions
You can also email us at [email protected]
Privacy Policy | Terms & Conditions
Copyright © getMaNGOS. All rights Reserved.
This website is in no way associated with or endorsed by Blizzard Entertainment®
This website is in no way associated with or endorsed by Blizzard Entertainment®