[SOLVED] Re: Building 3.4p1 on HP-UX 11.00, gcc, zlib 1.1.4, OpenSSL0.9.6d

Darren Tucker dtucker at zip.com.au
Wed Jul 17 21:30:09 EST 2002


"C. Bensend" wrote:
> ps:  Could this be categorized as an obscure bug in the configure
> process?  Shouldn't configure have bombed on -static being used
> when static libraries weren't availible, instead of complaining
> about something else (zlib)?  Not being argumentative or complaining
> or anything, it just would have been a lot quicker to track this
> down if I had seen a "configure: libxnet.a not found" or something
> similar.

I'm not very familiar with autoconf but how about the attached patch
(tested on HP-UX 11.00)?

$ LDFLAGS=-static ./configure
[snip]
checking for t_error in -lxnet... no
configure: error: *** -lxnet needed on HP-UX - check config.log ***

$ ./configure
[snip]
         Libraries:   -lz -lnsl -lxnet  -lsec -lcrypto  

-- 
Darren Tucker (dtucker at zip.com.au)
GPG Fingerprint D9A3 86E9 7EEE AF4B B2D4  37C9 C982 80C7 8FF4 FA69
    Good judgement comes with experience. Unfortunately, the experience
usually comes from bad judgement.
-------------- next part --------------
Index: configure.ac
===================================================================
RCS file: /cvs/openssh/configure.ac,v
retrieving revision 1.79
diff -u -r1.79 configure.ac
--- configure.ac	14 Jul 2002 20:36:50 -0000	1.79
+++ configure.ac	17 Jul 2002 11:19:53 -0000
@@ -113,7 +113,8 @@
 	AC_DEFINE(DISABLE_SHADOW)
 	AC_DEFINE(DISABLE_UTMP)
 	AC_DEFINE(SPT_TYPE,SPT_PSTAT)
-	LIBS="$LIBS -lxnet -lsec -lsecpw"
+	LIBS="$LIBS -lsec -lsecpw"
+	AC_CHECK_LIB(xnet, t_error, ,AC_MSG_ERROR([*** -lxnet needed on HP-UX - check config.log ***]))
 	disable_ptmx_check=yes
 	;;
 *-*-hpux10*)
@@ -128,7 +129,8 @@
 	AC_DEFINE(DISABLE_SHADOW)
 	AC_DEFINE(DISABLE_UTMP)
 	AC_DEFINE(SPT_TYPE,SPT_PSTAT)
-	LIBS="$LIBS -lxnet -lsec"
+	LIBS="$LIBS -lsec"
+	AC_CHECK_LIB(xnet, t_error, ,AC_MSG_ERROR([*** -lxnet needed on HP-UX - check config.log ***]))
 	;;
 *-*-hpux11*)
 	CPPFLAGS="$CPPFLAGS -D_HPUX_SOURCE -D_XOPEN_SOURCE -D_XOPEN_SOURCE_EXTENDED=1"
@@ -140,7 +142,8 @@
 	AC_DEFINE(DISABLE_SHADOW)
 	AC_DEFINE(DISABLE_UTMP)
 	AC_DEFINE(SPT_TYPE,SPT_PSTAT)
-	LIBS="$LIBS -lxnet -lsec"
+	LIBS="$LIBS -lsec"
+	AC_CHECK_LIB(xnet, t_error, ,AC_MSG_ERROR([*** -lxnet needed on HP-UX - check config.log ***]))
 	;;
 *-*-irix5*)
 	CPPFLAGS="$CPPFLAGS -I/usr/local/include"


More information about the openssh-unix-dev mailing list