1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81
|
Author: Alastair McKinstry <mckinstry@debian.org>
Description: Add gadap.pc pkg-config file to gadap
Last-Updated: 2011-10-25
Forwwarded: no
Index: gadap-2.0/configure.ac
===================================================================
--- gadap-2.0.orig/configure.ac 2011-10-24 16:50:06.000000000 +0100
+++ gadap-2.0/configure.ac 2011-10-25 11:34:15.000000000 +0100
@@ -38,6 +38,7 @@
AC_CONFIG_FILES([Makefile
src/Makefile
test/Makefile
+ gadap.pc
])
AC_CONFIG_FILES([gadap-config], [chmod 755 gadap-config])
AC_OUTPUT
Index: gadap-2.0/gadap.pc.in
===================================================================
--- /dev/null 1970-01-01 00:00:00.000000000 +0000
+++ gadap-2.0/gadap.pc.in 2011-10-25 11:54:31.000000000 +0100
@@ -0,0 +1,13 @@
+prefix=@prefix@
+exec_prefix=${prefix}
+libdir=@libdir@
+includedir=${prefix}/include
+ccompiler=gcc
+cppcompiler=g++
+
+Name: @PACKAGE_NAME@
+Description:
+Version: @PACKAGE_VERSION@
+Libs: -L${libdir} -lgadap
+Libs.private: -lpthread
+Requires: libdapclient libdapserver
Index: gadap-2.0/gadap-config.in
===================================================================
--- gadap-2.0.orig/gadap-config.in 2011-10-25 12:37:21.000000000 +0100
+++ gadap-2.0/gadap-config.in 2011-10-25 12:37:37.000000000 +0100
@@ -2,11 +2,7 @@
#
# Borrowed the idea for this script (and some code) from nc-dap which in
# turn took it from libcurl.
-#
-prefix=@prefix@
-exec_prefix=${prefix}
-libdir=${exec_prefix}/lib
-includedir=${prefix}/include
+# This version now derives out of the pkg-config file (preferred)
usage()
{
@@ -46,23 +42,23 @@
;;
--cc)
- echo "@CC@"
+ pkg-config --variable=cc gadap
;;
--cxx)
- echo "@CXX@"
+ pkg-config --variable=cxx gadap
;;
--cflags)
- echo "-I${includedir}/@PACKAGE_NAME@"
+ pkg-config --cflags gadap
;;
--libs)
- echo "-L${libdir} -lgadap @LIBS@"
+ pkg-config --libs gadap
;;
--prefix)
- echo "${prefix}"
+ pkg-config --variable=prefix gadap
;;
--version)
|