pkgsrc-Changes-HG archive

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

[pkgsrc/trunk]: pkgsrc/databases/p5-DBD-ODBC Importing package for p5 module ...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/a0a70518c139
branches:  trunk
changeset: 393096:a0a70518c139
user:      sno <sno%pkgsrc.org@localhost>
date:      Sun May 17 13:29:15 2009 +0000

description:
Importing package for p5 module DBD::ODBC 1.21.

DBD::ODBC is an ODBC Driver for DBI.

diffstat:

 databases/p5-DBD-ODBC/DESCR            |   1 +
 databases/p5-DBD-ODBC/Makefile         |  24 +++++++++++
 databases/p5-DBD-ODBC/distinfo         |   6 ++
 databases/p5-DBD-ODBC/options.mk       |  22 ++++++++++
 databases/p5-DBD-ODBC/patches/patch-aa |  72 ++++++++++++++++++++++++++++++++++
 5 files changed, 125 insertions(+), 0 deletions(-)

diffs (145 lines):

diff -r 425ea0c2e865 -r a0a70518c139 databases/p5-DBD-ODBC/DESCR
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/databases/p5-DBD-ODBC/DESCR       Sun May 17 13:29:15 2009 +0000
@@ -0,0 +1,1 @@
+DBD::ODBC is an ODBC Driver for DBI.
diff -r 425ea0c2e865 -r a0a70518c139 databases/p5-DBD-ODBC/Makefile
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/databases/p5-DBD-ODBC/Makefile    Sun May 17 13:29:15 2009 +0000
@@ -0,0 +1,24 @@
+# $NetBSD: Makefile,v 1.1.1.1 2009/05/17 13:29:15 sno Exp $
+#
+
+DISTNAME=      DBD-ODBC-1.21
+PKGNAME=       p5-${DISTNAME}
+CATEGORIES=    databases perl5
+MASTER_SITES=  ${MASTER_SITE_PERL_CPAN:=DBD/}
+
+MAINTAINER=    pkgsrc-users%NetBSD.org@localhost
+HOMEPAGE=      http://search.cpan.org/dist/DBD-ODBC/
+COMMENT=       Perl DBI/DBD driver for ODBC
+LICENSE=       gnu-gpl-v2 # OR artistic
+
+.include "options.mk"
+
+PKG_DESTDIR_SUPPORT=   user-destdir
+
+PKG_INSTALLATION_TYPES=        overwrite pkgviews
+
+PERL5_PACKLIST=        auto/DBD/ODBC/.packlist
+
+.include "../../databases/p5-DBI/buildlink3.mk"
+.include "../../lang/perl5/module.mk"
+.include "../../mk/bsd.pkg.mk"
diff -r 425ea0c2e865 -r a0a70518c139 databases/p5-DBD-ODBC/distinfo
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/databases/p5-DBD-ODBC/distinfo    Sun May 17 13:29:15 2009 +0000
@@ -0,0 +1,6 @@
+$NetBSD: distinfo,v 1.1.1.1 2009/05/17 13:29:15 sno Exp $
+
+SHA1 (DBD-ODBC-1.21.tar.gz) = 7984e031ce3614b523920deebac03b80aa473a71
+RMD160 (DBD-ODBC-1.21.tar.gz) = 738d1d57676658a75ceb4676567547dc5292f25e
+Size (DBD-ODBC-1.21.tar.gz) = 174208 bytes
+SHA1 (patch-aa) = e731a710838e86f05c4f3b223f768968ba1d9489
diff -r 425ea0c2e865 -r a0a70518c139 databases/p5-DBD-ODBC/options.mk
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/databases/p5-DBD-ODBC/options.mk  Sun May 17 13:29:15 2009 +0000
@@ -0,0 +1,22 @@
+# $NetBSD: options.mk,v 1.1.1.1 2009/05/17 13:29:15 sno Exp $
+
+PKG_OPTIONS_VAR=               PKG_OPTIONS.p5-DBD-ODBC
+PKG_OPTIONS_OPTIONAL_GROUPS+=  odbc
+PKG_OPTIONS_GROUP.odbc=                iodbc unixodbc
+PKG_SUGGESTED_OPTIONS=         unixodbc
+
+.include "../../mk/bsd.options.mk"
+
+###
+### Whether to build with iODBC to enable ODBC access to TDS servers.
+###
+.if !empty(PKG_OPTIONS:Miodbc)
+.  include "../../databases/iodbc/buildlink3.mk"
+.endif
+
+###
+### Whether to build with unixODBC to enable ODBC access to TDS servers.
+###
+.if !empty(PKG_OPTIONS:Munixodbc)
+.  include "../../databases/unixodbc/buildlink3.mk"
+.endif
diff -r 425ea0c2e865 -r a0a70518c139 databases/p5-DBD-ODBC/patches/patch-aa
--- /dev/null   Thu Jan 01 00:00:00 1970 +0000
+++ b/databases/p5-DBD-ODBC/patches/patch-aa    Sun May 17 13:29:15 2009 +0000
@@ -0,0 +1,72 @@
+$NetBSD: patch-aa,v 1.1.1.1 2009/05/17 13:29:15 sno Exp $
+
+# Fix issues detecting iODBC
+
+--- Makefile.PL.orig   2009-05-16 08:36:54.000000000 +0000
++++ Makefile.PL        2009-05-16 08:49:56.000000000 +0000
+@@ -154,7 +154,6 @@
+ 
+ EOT
+     }
+-    prompt("Press return to continue...");
+ }
+ print "Overriding ODBC Directory with command line option: $opt_o\n"
+     if $opt_o ;
+@@ -242,6 +241,7 @@
+             # exist until 2.2.11 and it was broken wrt --cflags in 2.2.11/2.2.12
+             # i.e. --cflags did not include -I/xxx/yyy
+             my $odbc_config_v = `odbc_config --version 2>&1`;
++            my $iodbc_config_v = `iodbc-config --version 2>&1`;
+             print "Looking for odbc_config\n";
+             if ($odbc_config_v && ($odbc_config_v =~ /^(\d\.)+/)) {
+                 print "  Found odbc_config versions $odbc_config_v\n";
+@@ -257,6 +257,20 @@
+                     print "  but cannot find header files in that path so ignoring\n";
+                     $odbchome = '';
+                 }
++            } elsif ($iodbc_config_v && ($iodbc_config_v =~ /^(\d\.)+/)) {
++                print "  Found iodbc-config versions $iodbc_config_v\n";
++                $odbchome = `iodbc-config --prefix 2>&1`;
++                print "  iodbc-config reports --prefix=$odbchome\n";
++                chomp $odbchome;
++                if ((-e $odbchome) && (-e "$odbchome/include") &&
++                        (-f "$odbchome/include/sql.h") &&
++                            (-f "$odbchome/include/sqlext.h") &&
++                                (-f "$odbchome/include/sqltypes.h")) {
++                    print "  Set ODBCHOME to $odbchome from iodbc-config\n";
++                } else {
++                    print "  but cannot find header files in that path so ignoring\n";
++                    $odbchome = '';
++                }
+             } else {
+                 print "  odbc_config not found - ok, there are other things I can do\n";
+             }
+@@ -272,6 +286,11 @@
+                                  -f '/usr/local/include/sqltypes.h') {
+                     print "  Found sql header files in /use/local/include\n";
+                     $odbchome = '/usr/local';
++                } elsif (-f '/usr/pkg/include/sql.h' &&
++                             -f '/usr/pkg/include/sqlext.h' &&
++                                 -f '/usr/pkg/include/sqltypes.h') {
++                    print "  Found sql header files in /use/pkg/include\n";
++                    $odbchome = '/usr/pkg';
+                 } elsif (-d '/usr/local/easysoft/unixODBC') {
+                     print "  Found sql header files in /use/local/easysoft/include\n";
+                     $odbchome = '/usr/local/easysoft/unixODBC';
+@@ -346,13 +365,13 @@
+     # fix to avoid foo..ext on many systems.
+     $arext =~ s/^\.//;
+ 
+-    $myodbc = 'unixodbc'
+-              if !$myodbc && glob "$odbchome/lib/libodbc.*";
+-
+     $myodbc = 'iodbc'
+               if !$myodbc && ((glob "$odbchome/*iodbc*") ||
+                                     (glob "$odbchome/lib/*iodbc*"));
+ 
++    $myodbc = 'unixodbc'
++              if !$myodbc && glob "$odbchome/lib/libodbc.*";
++
+     $myodbc = 'empress'
+               if !$myodbc && glob "$odbchome/lib/libempodbc.*";
+ 



Home | Main Index | Thread Index | Old Index