pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/databases/sqsh allow linking against the native Sybase...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/28f3b7445c67
branches:  trunk
changeset: 471522:28f3b7445c67
user:      grant <grant%pkgsrc.org@localhost>
date:      Mon Mar 29 01:50:39 2004 +0000

description:
allow linking against the native Sybase Open Client by defining
USE_SYBASE_OPENCLIENT and setting SYBASE to the root of the Sybase
Open Client installation.

diffstat:

 databases/sqsh/Makefile         |  27 ++++++++++++++++++++++-----
 databases/sqsh/distinfo         |   4 ++--
 databases/sqsh/patches/patch-aa |  19 +++++--------------
 3 files changed, 29 insertions(+), 21 deletions(-)

diffs (97 lines):

diff -r 4102b386b97f -r 28f3b7445c67 databases/sqsh/Makefile
--- a/databases/sqsh/Makefile   Mon Mar 29 01:40:23 2004 +0000
+++ b/databases/sqsh/Makefile   Mon Mar 29 01:50:39 2004 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: Makefile,v 1.18 2004/01/20 12:12:49 agc Exp $
+# $NetBSD: Makefile,v 1.19 2004/03/29 01:50:39 grant Exp $
 
 DISTNAME=      sqsh-1.7-src
 PKGNAME=       sqsh-1.7
@@ -17,11 +17,25 @@
 USE_BUILDLINK2=                yes
 GNU_CONFIGURE=         yes
 CONFIGURE_ARGS+=       --with-readline
-CONFIGURE_ENV+=                SYBASE="${BUILDLINK_PREFIX.freetds}/${SYBASE}"
 
-SYBASE=                        freetds
-LDFLAGS+=              -Wl,${RPATH_FLAG}${BUILDLINK_PREFIX.freetds}/${SYBASE}/lib
+# support for the native Sybase Open Client
+BUILD_DEFS+=           USE_SYBASE_OPENCLIENT
+BUILD_DEFS+=           SYBASE
+.if defined(USE_SYBASE_OPENCLIENT) && empty(USE_SYBASE_OPENCLIENT:M[Nn][Oo])
+.  if defined(SYBASE) && exists(${SYBASE}/lib/libct.so)
+BUILDLINK_PASSTHRU_DIRS=${SYBASE}
+_SYBASE=               ${SYBASE}
+.  else
+PKG_FAIL_REASON+=      "You must define SYBASE to the base directory of Open Client."
+.  endif
+.else
+_SYBASE=               ${BUILDLINK_PREFIX.freetds}/freetds
+MAKE_FLAGS+=           SYBASE_LIBS=-lct
+.endif
 
+LDFLAGS+=              -Wl,${RPATH_FLAG}${_SYBASE}/lib
+
+CONFIGURE_ENV+=                SYBASE="${_SYBASE}"
 CONFIGURE_ENV+=                INCDIRS="${BUILDLINK_PREFIX.readline}/include"
 CONFIGURE_ENV+=                LIBDIRS="${BUILDLINK_PREFIX.readline}/lib"
 
@@ -29,6 +43,9 @@
        ${INSTALL_PROGRAM} ${WRKSRC}/sqsh ${PREFIX}/bin
        ${INSTALL_MAN} ${WRKSRC}/doc/sqsh.1 ${PREFIX}/man/man1/sqsh.1
 
-.include "../../databases/freetds/buildlink2.mk"
+.if !defined(USE_SYBASE_OPENCLIENT)
+.  include "../../databases/freetds/buildlink2.mk"
+.endif
+
 .include "../../devel/readline/buildlink2.mk"
 .include "../../mk/bsd.pkg.mk"
diff -r 4102b386b97f -r 28f3b7445c67 databases/sqsh/distinfo
--- a/databases/sqsh/distinfo   Mon Mar 29 01:40:23 2004 +0000
+++ b/databases/sqsh/distinfo   Mon Mar 29 01:50:39 2004 +0000
@@ -1,8 +1,8 @@
-$NetBSD: distinfo,v 1.4 2001/06/09 15:01:58 wiz Exp $
+$NetBSD: distinfo,v 1.5 2004/03/29 01:50:39 grant Exp $
 
 SHA1 (sqsh-1.7-src.tar.gz) = 8526cced3350024ef262a0a572d2822c6059159c
 Size (sqsh-1.7-src.tar.gz) = 296618 bytes
-SHA1 (patch-aa) = 45f41fa23ee44d49a132c2cd0ff884219c70192f
+SHA1 (patch-aa) = e9f0669a15db33327364ba5bef818222954bb0da
 SHA1 (patch-ab) = b46405fbe1b97dcd8d019cd5f89922552e12b175
 SHA1 (patch-ac) = d86ad97113bc8521764ed5b6898ab524a0079285
 SHA1 (patch-ad) = 435a1abadf38e63bf97c9c872e6664fee1729368
diff -r 4102b386b97f -r 28f3b7445c67 databases/sqsh/patches/patch-aa
--- a/databases/sqsh/patches/patch-aa   Mon Mar 29 01:40:23 2004 +0000
+++ b/databases/sqsh/patches/patch-aa   Mon Mar 29 01:50:39 2004 +0000
@@ -1,17 +1,8 @@
-$NetBSD: patch-aa,v 1.3 2001/06/09 15:01:58 wiz Exp $
+$NetBSD: patch-aa,v 1.4 2004/03/29 01:50:39 grant Exp $
 
---- configure.orig     Tue Jan  5 21:33:39 1999
-+++ configure  Tue May 22 00:50:38 2001
-@@ -1095,7 +1095,7 @@
-       # The basic client libraries that are always needed
-       # on all platforms.
-       #
--      SYBASE_LIBS="-lblk -lcs -lct -lcomn -ltcl -lintl"
-+      SYBASE_LIBS="-lct"
- 
-       MAJOR_VERSION=`echo $SYBASE_VERSION | cut -d '.' -f 1`
- 
-@@ -1146,6 +1146,8 @@
+--- configure.orig     1999-01-06 13:33:39.000000000 +1100
++++ configure
+@@ -1146,6 +1146,8 @@ echo "configure:1127: checking Open Clie
                        SYBASE_OS="-lm -ldl -ldgc";;
                aix*)
                        SYBASE_OS="-lm";;
@@ -20,7 +11,7 @@
                *)
                        SYBASE_OS="-lm -ldl";;
        esac
-@@ -1301,7 +1303,7 @@
+@@ -1301,7 +1303,7 @@ else
                        CPPFLAGS="${CPPFLAGS} -L${READLINE_LIBDIR}"
                fi
  



Home | Main Index | Thread Index | Old Index