Bug 175692 - security/openvpn-auth-ldap configure error
Summary: security/openvpn-auth-ldap configure error
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: Matthias Andree
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-01-30 09:00 UTC by a.ulasov
Modified: 2014-01-02 00:20 UTC (History)
0 users

See Also:


Attachments
openvpn-auth-ldap.patch (2.41 KB, patch)
2013-12-21 21:21 UTC, nick.barkas
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description a.ulasov 2013-01-30 09:00:00 UTC
When you try to compile openvpn-auth-ldap, you get an error
....
configure: WARNING: Check library not found. Unit tests will not be built or run.
checking for openvpn-plugin.h... no
configure: error: Could not locate a working openvpn source tree.
See `config.log' for more details.
===>  Script "configure" failed unexpectedly.
Please report the problem to snb@FreeBSD.org [maintainer] and attach the
"/usr/ports/security/openvpn-auth-ldap/work/auth-ldap-2.0.3/config.log"
including the output of the failure of your make command. Also, it might be
a good idea to provide an overview of all packages installed on your system
(e.g. a /usr/sbin/pkg_info -Ea).
*** Error code 1
......

In the config.log you can see that the configure looking for openvpn-plugin.h file in /usr/ports/security/openvpn/work/openvpn-2.3.0, but realy this file located in /usr/local/include

...
configure:5511: checking for openvpn-plugin.h
configure:5544: cc -o conftest -O2 -pipe -DLDAP_DEPRECATED -fno-strict-aliasing -I/usr/ports/security/openvpn/work/openvpn-2.3.0  -export-dynamic conftest.c  >&5
conftest.c:15:34: error: openvpn-plugin.h: No such file or directory
...
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2013-01-30 09:00:09 UTC
Responsible Changed
From-To: freebsd-ports-bugs->snb

Over to maintainer (via the GNATS Auto Assign Tool)
Comment 2 nick.barkas 2013-12-21 21:21:27 UTC
I put together a patch to fix this some time ago (also makes the port build on 9.x and greater, and adds a patch to make unit tests buildable if the user has libcheck installed), but forgot to submit a follow-up here. Iâm unable to commit this myself unfortunately, and would greatly appreciate if a committer picked it up!
Comment 3 Matthias Andree freebsd_committer freebsd_triage 2014-01-01 23:56:55 UTC
Responsible Changed
From-To: snb->mandree

I'll take it, per Nick's mail and patch to ports@
Comment 4 dfilter service freebsd_committer freebsd_triage 2014-01-02 00:15:09 UTC
Author: mandree
Date: Thu Jan  2 00:15:02 2014
New Revision: 338409
URL: http://svnweb.freebsd.org/changeset/ports/338409

Log:
  Chase openvpn source layout changes,
  and chase base GCC changes (Objective-C no longer build in 9+, uses port),
  and make a few other changes, to fix the build. [1]
  
  While here:
  - support staging
  - strip installed .so file unless under WITH_DEBUG regime
  - convert NOPORTEXAMPLES to optionsNG, too
  
  PR:		ports/175692
  Submitted by:	snb@ (maintainer) [1]

Added:
  head/security/openvpn-auth-ldap/files/
  head/security/openvpn-auth-ldap/files/patch-tests-Makefile.in   (contents, props changed)
Modified:
  head/security/openvpn-auth-ldap/Makefile   (contents, props changed)

Modified: head/security/openvpn-auth-ldap/Makefile
==============================================================================
--- head/security/openvpn-auth-ldap/Makefile	Thu Jan  2 00:10:08 2014	(r338408)
+++ head/security/openvpn-auth-ldap/Makefile	Thu Jan  2 00:15:02 2014	(r338409)
@@ -3,7 +3,7 @@
 
 PORTNAME=	openvpn-auth-ldap
 PORTVERSION=	2.0.3
-PORTREVISION=	3
+PORTREVISION=	4
 CATEGORIES=	security
 MASTER_SITES=	${MASTER_SITE_GOOGLE_CODE}
 DISTNAME=	auth-ldap-${PORTVERSION}
@@ -18,31 +18,35 @@ GNU_CONFIGURE=	yes
 USE_OPENLDAP=	yes
 OPENVPN_WRKSRC=	`cd ${PORTSDIR}/security/openvpn; make -V WRKSRC`
 CONFIGURE_ARGS+=	--with-openldap=${LOCALBASE} \
-			--with-openvpn=${OPENVPN_WRKSRC}
+			--with-openvpn=${OPENVPN_WRKSRC}/include \
+			--with-objc-runtime=GNU
 
 PORTDOCS=	README
 PORTEXAMPLES=	auth-ldap.conf
 PLIST_FILES=	lib/openvpn-auth-ldap.so
 
-NO_STAGE=	yes
-.include <bsd.port.pre.mk>
+OPTIONS_DEFINE=	DOCS EXAMPLES
+.include <bsd.port.options.mk>
 
 .if (${OSVERSION} >= 900000 && ${OSVERSION} < 900012) || ${OSVERSION} < 800505
 BUILD_DEPENDS+=	${LOCALBASE}/bin/xz:${PORTSDIR}/archivers/xz
 .endif
 
 .if ${OSVERSION} >= 900000
-BROKEN=		does not configure on FreeBSD 9.X
+# Use gcc from ports because Objective C support no longer included in base
+USE_GCC=	yes
+CONFIGURE_ENV+=	OBJC="${CC}"
 .endif
 
 post-install:
-.if !defined(NOPORTDOCS)
-	${MKDIR} ${DOCSDIR}
-	${INSTALL_DATA} ${WRKSRC}/README ${DOCSDIR}
+	${STRIP_CMD} ${STAGEDIR}${PREFIX}/lib/openvpn-auth-ldap.so
+.if ${PORT_OPTIONS:MDOCS}
+	${MKDIR} ${STAGEDIR}${DOCSDIR}
+	${INSTALL_DATA} ${WRKSRC}/README ${STAGEDIR}${DOCSDIR}
 .endif
-.if !defined(NOPORTEXAMPLES)
-	${MKDIR} ${EXAMPLESDIR}
-	${INSTALL_DATA} ${WRKSRC}/auth-ldap.conf ${EXAMPLESDIR}
+.if ${PORT_OPTIONS:MEXAMPLES}
+	${MKDIR} ${STAGEDIR}${EXAMPLESDIR}
+	${INSTALL_DATA} ${WRKSRC}/auth-ldap.conf ${STAGEDIR}${EXAMPLESDIR}
 .endif
 
-.include <bsd.port.post.mk>
+.include <bsd.port.mk>

Added: head/security/openvpn-auth-ldap/files/patch-tests-Makefile.in
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/security/openvpn-auth-ldap/files/patch-tests-Makefile.in	Thu Jan  2 00:15:02 2014	(r338409)
@@ -0,0 +1,11 @@
+--- tests/Makefile.in.orig	2006-08-01 05:51:52.000000000 +0200
++++ tests/Makefile.in	2013-06-09 06:33:07.000000000 +0200
+@@ -26,7 +26,7 @@
+ CFLAGS+=	@CHECK_CFLAGS@ -DTEST_DATA=\"${srcdir}/data\"
+ OBJCFLAGS+=	@CHECK_CFLAGS@ -DTEST_DATA=\"${srcdir}/data\"
+ LIBS+=		-lauth-ldap-testing $(OBJC_LIBS) $(LDAP_LIBS) @CHECK_LIBS@
+-LDFLAGS+=	-L${top_builddir}src $(LIBS)
++LDFLAGS+=	-L${top_builddir}/src $(LIBS)
+ 
+ # Recompile the tests every time
+ all: tests
_______________________________________________
svn-ports-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-ports-all
To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"
Comment 5 Matthias Andree freebsd_committer freebsd_triage 2014-01-02 00:16:03 UTC
State Changed
From-To: open->closed

Committed, with minor changes. Thanks!