Bug 51090 - Cyrus-sasl can not be built with openssl from ports
Summary: Cyrus-sasl can not be built with openssl from ports
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Hajimu UMEMOTO
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2003-04-17 12:30 UTC by Oleg Sharoiko
Modified: 2003-04-24 17:39 UTC (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Oleg Sharoiko 2003-04-17 12:30:15 UTC
	Two bugs found:

	1. USE_OPENSSL (from bsd.port.mk) does not allow to build
	with openssl from ports. It always tries to build against
	openssl from base system and complains when system was built
	without openssl, although openssl is installed from ports

	2. cyrus-sasl 2.1.13 incorrectly handles openssl location when
	building saslauthd. It can not use openssl in /usr/local

Fix: 

The following patch will solve both of the problems.
	1. It switches from USE_OPENSSL to security/openssl/bsd.openssl.mk
	for purposes of openssl identification
	2. It passes paths to include and lib files of openssl as
	CPPFLAGS and LDFLAGS

--- Makefile	15 Apr 2003 17:03:27 -0000	1.68
+++ Makefile	17 Apr 2003 11:27:01 -0000
@@ -17,7 +17,6 @@
 COMMENT=	RFC 2222 SASL (Simple Authentication and Security Layer)
 
 USE_SUBMAKE=	yes
-USE_OPENSSL=	yes
 
 INSTALLS_SHLIB=	yes
 
@@ -97,7 +96,8 @@
 CONFIGURE_ENV+=	LOCALBASE=${LOCALBASE} \
 		OPENSSLINC=${OPENSSLINC} \
 		OPENSSLLIB=${OPENSSLLIB} \
-		LDFLAGS=${LDFLAGS}
+		LDFLAGS="${LDFLAGS}" \
+		CPPFLAGS="${CPPFLAGS}"
 
 CYRUS_USER?=	cyrus
 CYRUS_GROUP?=	cyrus
@@ -193,4 +193,14 @@
 post-clean:
 	@${RM} -f ${WRKDIRPREFIX}${.CURDIR}/Makefile.inc
 
-.include <bsd.port.mk>
+.include <bsd.port.pre.mk>
+.include "${PORTSDIR}/security/openssl/bsd.openssl.mk"
+#
+# Workaround the bug in cyrus-sasl (saslauthd) configure not being able to find
+# openssl from ports
+#
+.if !defined(WITH_OPENSSL_BASE)
+LDFLAGS+=	-L${OPENSSLLIB}
+CPPFLAGS+=	-I${OPENSSLINC}
+.endif
+.include <bsd.port.post.mk>
Comment 1 Hajimu UMEMOTO freebsd_committer freebsd_triage 2003-04-24 17:37:29 UTC
State Changed
From-To: open->closed

Thanks!  I've just commited it with some modification. 


Comment 2 Hajimu UMEMOTO freebsd_committer freebsd_triage 2003-04-24 17:37:29 UTC
Responsible Changed
From-To: freebsd-ports-bugs->ume

Thanks!  I've just commited it with some modification.