perl-dbi.patch 4.3 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130
  1. Index: DBD-SQLite-1.14/Makefile.PL
  2. --- DBD-SQLite-1.14/Makefile.PL.orig 2007-08-28 21:57:09 +0200
  3. +++ DBD-SQLite-1.14/Makefile.PL 2009-02-10 08:56:57 +0100
  4. @@ -10,34 +10,6 @@
  5. }
  6. use Config;
  7. use strict;
  8. -eval {
  9. - require DBD::SQLite;
  10. - if ($DBD::SQLite::VERSION < 1.0) {
  11. - print <<EOT;
  12. -
  13. -**** WARNING **** WARNING **** WARNING **** WARNING **** WARNING ****
  14. -
  15. -Your version of DBD::SQLite currently installed ($DBD::SQLite::VERSION) uses
  16. -the old sqlite database format. This version of DBD::SQLite will *NOT*
  17. -open these files, and installing this module may cause problems on your
  18. -system. If this is a live environment you should upgrade with caution.
  19. -
  20. -To upgrade a database, download and install both sqlite 2.x and 3.x from
  21. -http://www.sqlite.org/ and issue:
  22. -
  23. - sqlite OLD.DB .dump | sqlite3 NEW.DB
  24. -
  25. -DBD::SQLite will NOT automatically upgrade a database for you, and using
  26. -this version against an old SQLite database WILL lead to database
  27. -corruption.
  28. -
  29. -EOT
  30. - if (prompt("Continue?", "N") !~ /^y/i) {
  31. - print "Exiting\n";
  32. - exit -1;
  33. - }
  34. - }
  35. -};
  36. # 2005/6/19, by rjray@blackperl.com
  37. #
  38. @@ -111,18 +83,19 @@
  39. my $nlid = $DBI::VERSION > 1.42 ? '' : '-Dno_last_insert_id';
  40. -my $libs = '';
  41. -$libs .= "-L$sqlite_lib " if ($sqlite_lib);
  42. -$libs .= "-lsqlite3 " unless ($force_local);
  43. +my $inc = `@l_prefix@/bin/pkg-config sqlite3 --cflags-only-I`;
  44. +$inc =~ s/\r?\n$//s;
  45. +my $libs = `@l_prefix@/bin/pkg-config sqlite3 --libs`;
  46. +$libs =~ s/\r?\n$//s;
  47. WriteMakefile(
  48. 'NAME' => 'DBD::SQLite',
  49. 'VERSION_FROM' => 'lib/DBD/SQLite.pm', # finds $VERSION
  50. 'PREREQ_PM' => {DBI => 1.21}, # e.g., Module::Name => 1.1
  51. 'OBJECT' => ($force_local) ? '$(O_FILES)' : 'SQLite.o dbdimp.o',
  52. - 'INC' => '-I. -I$(DBI_INSTARCH_DIR)' .
  53. + 'INC' => $inc . ' -I. -I$(DBI_INSTARCH_DIR)' .
  54. (($sqlite_inc) ? " -I$sqlite_inc" : ''),
  55. - $libs ? ('LIBS' => $libs) : (),
  56. + 'LIBS' => [ $libs ],
  57. 'OPTIMIZE' => "-O2",
  58. 'DEFINE' => "-DSQLITE_CORE -DSQLITE_ENABLE_FTS2 -DNDEBUG=1 -DSQLITE_PTR_SZ=$Config{ptrsize}" .
  59. ( ($Config{d_usleep} ||
  60. Index: DBD-SQLite-1.14/dbdimp.h
  61. --- DBD-SQLite-1.14/dbdimp.h.orig 2007-08-23 02:45:08 +0200
  62. +++ DBD-SQLite-1.14/dbdimp.h 2009-02-10 08:56:57 +0100
  63. @@ -4,7 +4,7 @@
  64. #define _DBDIMP_H 1
  65. #include "SQLiteXS.h"
  66. -#include "sqliteInt.h"
  67. +#include "sqlite3.h"
  68. /* 30 second timeout by default */
  69. #define SQL_TIMEOUT 30000
  70. Index: DBD-Sybase-1.09/dbdimp.c
  71. --- DBD-Sybase-1.09/dbdimp.c.orig 2008-08-31 14:08:17 +0200
  72. +++ DBD-Sybase-1.09/dbdimp.c 2009-02-10 08:56:57 +0100
  73. @@ -774,22 +774,22 @@
  74. #if defined(CS_VERSION_150)
  75. if(cs_ver == CS_VERSION_150)
  76. - BLK_VERSION = BLK_VERSION_150;
  77. + BLK_VERSION = CS_VERSION_150;
  78. #endif
  79. #if defined(CS_VERSION_125)
  80. if(cs_ver == CS_VERSION_125)
  81. - BLK_VERSION = BLK_VERSION_125;
  82. + BLK_VERSION = CS_VERSION_125;
  83. #endif
  84. #if defined(CS_VERSION_120)
  85. if(cs_ver == CS_VERSION_120)
  86. - BLK_VERSION = BLK_VERSION_120;
  87. + BLK_VERSION = CS_VERSION_120;
  88. #endif
  89. #if defined(CS_VERSION_110)
  90. if(cs_ver == CS_VERSION_110)
  91. - BLK_VERSION = BLK_VERSION_110;
  92. + BLK_VERSION = CS_VERSION_110;
  93. #endif
  94. if (cs_ver == CS_VERSION_100)
  95. - BLK_VERSION = BLK_VERSION_100;
  96. + BLK_VERSION = CS_VERSION_100;
  97. #if USE_CSLIB_CB
  98. if (cs_config(context, CS_SET, CS_MESSAGE_CB,
  99. Index: DBD-cego/Makefile.PL
  100. --- DBD-cego/Makefile.PL.orig 2007-06-25 20:38:07 +0200
  101. +++ DBD-cego/Makefile.PL 2009-02-10 08:56:57 +0100
  102. @@ -43,7 +43,7 @@
  103. 'VERSION_FROM' => 'Cego.pm',
  104. 'PREREQ_PM' => {DBI => 1.03},
  105. 'OBJECT' => '$(O_FILES)',
  106. - 'INC' => '-I$(DBI_INSTARCH_DIR) -I' . $opt->{'prefix'} . '/include',
  107. + 'INC' => '-I$(DBI_INSTARCH_DIR) -I' . $opt->{'prefix'} . '/include/cego',
  108. 'MYEXTLIB' => $opt->{'prefix'} . "/lib/libCego.a "
  109. . $opt->{'prefix'} . "/lib/libXML.a "
  110. . $opt->{'prefix'} . "/lib/libBase.a",
  111. Index: DBD-mysql-4.010/dbdimp.h
  112. --- DBD-mysql-4.010/dbdimp.h.orig 2008-04-29 01:36:17 +0200
  113. +++ DBD-mysql-4.010/dbdimp.h 2009-02-10 08:56:57 +0100
  114. @@ -19,6 +19,7 @@
  115. * Header files we use
  116. */
  117. #include <DBIXS.h> /* installed by the DBI module */
  118. +#include <my_global.h>
  119. #include <mysql.h> /* Comes with MySQL-devel */
  120. #include <mysqld_error.h> /* Comes MySQL */