[25612] in Source-Commits

home help back first fref pref prev next nref lref last post

/svn/athena r25125 - in trunk/debathena/debathena/aclocal: aclocal debian

daemon@ATHENA.MIT.EDU (Geoffrey Thomas)
Tue May 3 02:52:08 2011

Date: Tue, 3 May 2011 02:51:51 -0400
From: Geoffrey Thomas <geofft@MIT.EDU>
Message-Id: <201105030651.p436ppf3014684@drugstore.mit.edu>
To: source-commits@mit.edu
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit

Author: geofft
Date: 2011-05-03 02:51:51 -0400 (Tue, 03 May 2011)
New Revision: 25125

Modified:
   trunk/debathena/debathena/aclocal/aclocal/athena_com_err.m4
   trunk/debathena/debathena/aclocal/debian/changelog
Log:
In aclocal:
  * PKG_CHECK_MODULES doesn't split LDFLAGS and LIBS properly. Since we
    need to insert com_err's LDFLAGS before AFS's, but since -lcom_err
    needs to be after the object files, we need this split. So,
    reimplement what we need of it and just use PKG_CHECK_EXISTS.


Modified: trunk/debathena/debathena/aclocal/aclocal/athena_com_err.m4
===================================================================
--- trunk/debathena/debathena/aclocal/aclocal/athena_com_err.m4	2011-05-02 20:35:35 UTC (rev 25124)
+++ trunk/debathena/debathena/aclocal/aclocal/athena_com_err.m4	2011-05-03 06:51:51 UTC (rev 25125)
@@ -30,11 +30,12 @@
 	[com_err="$withval"], [com_err=yes])
 AS_IF([test "$com_err" != no],
 	[AS_IF([test "$com_err" != yes],
-		[COM_ERR_CFLAGS="-I$com_err/include"
-		COM_ERR_LDFLAGS="-L$com_err/lib"])
-	PKG_CHECK_MODULES([COM_ERR], [com_err])
-	CFLAGS="$COM_ERR_CFLAGS $CFLAGS"
-	LDFLAGS="$COM_ERR_LDFLAGS $LDFLAGS"
-	AC_SEARCH_LIBS(com_err, com_err, ,
-		       [AC_MSG_ERROR(com_err library not found)])],
+		[CFLAGS="$CFLAGS -I$com_err/include"
+		LDFLAGS="$LDFLAGS -L$com_err/lib"],
+		[PKG_CHECK_EXISTS([com_err],
+			[CFLAGS="$CFLAGS `$PKG_CONFIG --cflags com_err 2>/dev/null`"
+			LDFLAGS="$LDFLAGS `$PKG_CONFIG --libs-only-L --libs-only-other com_err 2>/dev/null`"
+			LIBS="$LIBS `$PKG_CONFIG --libs-only-l com_err 2>/dev/null`"],
+			[AC_SEARCH_LIBS(com_err, com_err, ,
+				       [AC_MSG_ERROR(com_err library not found)])])])],
 	[AC_MSG_ERROR(This package requires com_err.)])])

Modified: trunk/debathena/debathena/aclocal/debian/changelog
===================================================================
--- trunk/debathena/debathena/aclocal/debian/changelog	2011-05-02 20:35:35 UTC (rev 25124)
+++ trunk/debathena/debathena/aclocal/debian/changelog	2011-05-03 06:51:51 UTC (rev 25125)
@@ -1,3 +1,12 @@
+debathena-aclocal (1.1.2) unstable; urgency=low
+
+  * PKG_CHECK_MODULES doesn't split LDFLAGS and LIBS properly. Since we
+    need to insert com_err's LDFLAGS before AFS's, but since -lcom_err
+    needs to be after the object files, we need this split. So,
+    reimplement what we need of it and just use PKG_CHECK_EXISTS.
+
+ -- Geoffrey Thomas <geofft@mit.edu>  Tue, 03 May 2011 02:49:51 -0400
+
 debathena-aclocal (1.1.1) unstable; urgency=low
 
   * If we're going to use pkg-config's macros, having pkg-config


home help back first fref pref prev next nref lref last post