ibm_db 5.4.1-x86-mingw32 → 5.6.1-x86-mingw32
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGES +15 -0
- data/README +4 -2
- data/ext/Makefile +15 -13
- data/ext/extconf.rb +12 -3
- data/ext/ibm_db.c +16 -31
- data/ext/ibm_db.o +0 -0
- data/ext/ibm_db.so +0 -0
- data/ext/mkmf.log +8 -8
- data/ext/ruby_ibm_db_cli.c +1 -1
- data/ext/ruby_ibm_db_cli.h +8 -0
- data/ext/ruby_ibm_db_cli.o +0 -0
- data/lib/IBM_DB.rb +1 -1
- data/lib/active_record/connection_adapters/ibm_db_adapter.rb +2453 -1877
- data/lib/mswin32/ibm_db.rb +5 -1
- data/lib/mswin32/rb3x/i386/ruby33/ibm_db.so +0 -0
- data/test/config.yml +68 -12
- metadata +36 -11
- data/lib/mswin32/rb3x/i386/ruby31/ibm_db.so +0 -0
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 28366bb9dd3a5df9457b1a8914988d44da1fe8ec39bf8c891cccdbcd8e5c6cb3
|
4
|
+
data.tar.gz: a2c763025f4f9ee1c41aebab4d1a4c8de4a1d7662912f3eaffacefac765c4367
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0a90a4c4a36ec06240d814d6261aca73a88a9a0d656401b327166000ee36abbb1997ec5abe5881ac66f3918743ab78416a19b2c4bea7f39ca724be9d5335dfa3
|
7
|
+
data.tar.gz: e609fa20639e805b1d7f692bb6d83e9e0ed9b06697436792f59ee62bb892d926c3a7e5739237c97b18f4340401d3d5e6398ba60da063be04341f72eda317a112
|
data/CHANGES
CHANGED
@@ -1,5 +1,20 @@
|
|
1
1
|
Change Log
|
2
2
|
==============
|
3
|
+
2025/06/09 (IBM_DB adapter 5.6.1, driver 3.2.0)
|
4
|
+
- Rails < 7.2 is not campatible with Adapter 5.6.0 Onwards.
|
5
|
+
|
6
|
+
2025/06/03 (IBM_DB adapter 5.6.0, driver 3.2.0)
|
7
|
+
- Support for ruby 3.3 and rails 7.2.2.1
|
8
|
+
|
9
|
+
2024/12/13 (IBM_DB adapter 5.5.1, driver 3.1.1)
|
10
|
+
- Support for MAC ARM64
|
11
|
+
|
12
|
+
2024/07/10 (IBM_DB adapter 5.5.0, driver 3.1.0)
|
13
|
+
- Support for ruby 3.2 and rails 7.1.3.2
|
14
|
+
|
15
|
+
2023/10/11 (IBM_DB adapter 5.4.2, driver 3.1.0)
|
16
|
+
- config.yml to have Environment variables to specify credentials.
|
17
|
+
|
3
18
|
2023/03/29 (IBM_DB adapter 5.4.1, driver 3.1.0)
|
4
19
|
- Download clidriver issue fixed and replaced http links with https.
|
5
20
|
|
data/README
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
=====================================================================
|
2
|
-
README for the IBM_DB Adapter >= 5.
|
3
|
-
For ActiveRecord Version >=
|
2
|
+
README for the IBM_DB Adapter >= 5.5.0 and Driver >= 3.1.0
|
3
|
+
For ActiveRecord Version >= 7.1.x (and Rails >= 7.1.x)
|
4
4
|
=====================================================================
|
5
5
|
|
6
6
|
Supported Operating Systems
|
@@ -10,6 +10,7 @@ Supported Operating Systems
|
|
10
10
|
- IBM AIX 32/64 bit
|
11
11
|
- HP-UX 32/64 bit
|
12
12
|
- Sun Solaris 32/64 bit
|
13
|
+
- MAC M1 ARM 64 bit
|
13
14
|
|
14
15
|
|
15
16
|
Supported Databases
|
@@ -133,6 +134,7 @@ Testing the IBM_DB Adapter
|
|
133
134
|
2) Edit the Rakefile to include ibm_db in list of adapters
|
134
135
|
%w( mysql mysql2 postgresql sqlite3 sqlite3_mem firebird db2 oracle sybase openbase ibm_db frontbase jdbcmysql jdbcpostgresql jdbcsqlite3 jdbcderby jdbch2 jdbchsqldb )
|
135
136
|
3) Configure the connection information in test/config.yml for ibm_db
|
137
|
+
Set Environment Variables DB2_USER1, DB2_PASSWD1, DB2_DATABASE1, DB2_HOST1, DB2_PORT1 etc... accordingly.
|
136
138
|
4) run the test suite - rake test_ibm_db
|
137
139
|
|
138
140
|
Running IBM_DB driver test suite
|
data/ext/Makefile
CHANGED
@@ -13,12 +13,12 @@ NULLCMD = :
|
|
13
13
|
#### Start of system configuration section. ####
|
14
14
|
|
15
15
|
srcdir = .
|
16
|
-
topdir = /C/
|
16
|
+
topdir = /C/Ruby33/include/ruby-3.3.0
|
17
17
|
hdrdir = $(topdir)
|
18
|
-
arch_hdrdir = /C/
|
18
|
+
arch_hdrdir = /C/Ruby33/include/ruby-3.3.0/i386-mingw32
|
19
19
|
PATH_SEPARATOR = :
|
20
20
|
VPATH = $(srcdir):$(arch_hdrdir)/ruby:$(hdrdir)/ruby
|
21
|
-
prefix = $(DESTDIR)/C/
|
21
|
+
prefix = $(DESTDIR)/C/Ruby33
|
22
22
|
rubysitearchprefix = $(rubylibprefix)/$(sitearch)
|
23
23
|
rubyarchprefix = $(rubylibprefix)/$(arch)
|
24
24
|
rubylibprefix = $(libdir)/$(RUBY_BASE_NAME)
|
@@ -82,25 +82,25 @@ cflags = $(optflags) $(debugflags) $(warnflags)
|
|
82
82
|
cxxflags =
|
83
83
|
optflags = -O3 -fno-omit-frame-pointer -fno-fast-math
|
84
84
|
debugflags = -ggdb3
|
85
|
-
warnflags = -Wall -Wextra -Wdeprecated-declarations -Wduplicated-cond -Wimplicit-function-declaration -Wimplicit-int -
|
85
|
+
warnflags = -Wall -Wextra -Wdeprecated-declarations -Wdiv-by-zero -Wduplicated-cond -Wimplicit-function-declaration -Wimplicit-int -Wpointer-arith -Wwrite-strings -Wold-style-definition -Wimplicit-fallthrough=0 -Wmissing-noreturn -Wno-cast-function-type -Wno-constant-logical-operand -Wno-long-long -Wno-missing-field-initializers -Wno-overlength-strings -Wno-packed-bitfield-compat -Wno-parentheses-equality -Wno-self-assign -Wno-tautological-compare -Wno-unused-parameter -Wno-unused-value -Wsuggest-attribute=format -Wsuggest-attribute=noreturn -Wunused-variable -Wmisleading-indentation -Wundef
|
86
86
|
cppflags =
|
87
87
|
CCDLFLAGS =
|
88
88
|
CFLAGS = $(CCDLFLAGS) -O3 -fno-fast-math -fstack-protector-strong $(ARCH_FLAG)
|
89
89
|
INCFLAGS = -I. -I$(arch_hdrdir) -I$(hdrdir)/ruby/backward -I$(hdrdir) -I$(srcdir)
|
90
90
|
DEFS = -D_FILE_OFFSET_BITS=64
|
91
|
-
CPPFLAGS = -DRUBY_EXTCONF_H=\"$(RUBY_EXTCONF_H)\" -IC:/Users/pnarayanappa/ruby-ibmdb/IBM_DB_Adapter/ibm_db/ext/../lib/clidriver/include
|
92
|
-
CXXFLAGS = $(CCDLFLAGS) -march=pentium4 -mtune=generic -O2 -pipe $(ARCH_FLAG)
|
91
|
+
CPPFLAGS = -DRUBY_EXTCONF_H=\"$(RUBY_EXTCONF_H)\" -IC:/Users/pnarayanappa/ruby-ibmdb/IBM_DB_Adapter/ibm_db/ext/../lib/clidriver/include -DFD_SETSIZE=2048 -D_WIN32_WINNT=0x0600 -D__MINGW_USE_VC2005_COMPAT $(DEFS) $(cppflags)
|
92
|
+
CXXFLAGS = $(CCDLFLAGS) -march=pentium4 -mtune=generic -O2 -pipe -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector-strong -Wp,-D__USE_MINGW_ANSI_STDIO=1 $(ARCH_FLAG)
|
93
93
|
ldflags = -L. -pipe -s -fstack-protector-strong -Wl,--no-as-needed
|
94
94
|
dldflags = -pipe -s -fstack-protector-strong -Wl,--enable-auto-image-base,--enable-auto-import $(DEFFILE)
|
95
95
|
ARCH_FLAG =
|
96
96
|
DLDFLAGS = $(ldflags) $(dldflags) $(ARCH_FLAG)
|
97
97
|
LDSHARED = $(CC) -shared
|
98
98
|
LDSHAREDXX = $(CXX) -shared
|
99
|
-
AR =
|
99
|
+
AR = gcc-ar
|
100
100
|
EXEEXT = .exe
|
101
101
|
|
102
102
|
RUBY_INSTALL_NAME = $(RUBY_BASE_NAME)
|
103
|
-
RUBY_SO_NAME = msvcrt-
|
103
|
+
RUBY_SO_NAME = msvcrt-ruby330
|
104
104
|
RUBYW_INSTALL_NAME = $(RUBYW_BASE_NAME)
|
105
105
|
RUBY_VERSION_NAME = $(RUBY_BASE_NAME)-$(ruby_version)
|
106
106
|
RUBYW_BASE_NAME = rubyw
|
@@ -108,9 +108,10 @@ RUBY_BASE_NAME = ruby
|
|
108
108
|
|
109
109
|
arch = i386-mingw32
|
110
110
|
sitearch = i386-msvcrt
|
111
|
-
ruby_version = 3.
|
111
|
+
ruby_version = 3.3.0
|
112
112
|
ruby = $(bindir)/$(RUBY_BASE_NAME)
|
113
113
|
RUBY = $(ruby)
|
114
|
+
BUILTRUBY = $(bindir)/$(RUBY_BASE_NAME).exe
|
114
115
|
ruby_headers = $(hdrdir)/ruby.h $(hdrdir)/ruby/backward.h $(hdrdir)/ruby/ruby.h $(hdrdir)/ruby/defines.h $(hdrdir)/ruby/missing.h $(hdrdir)/ruby/intern.h $(hdrdir)/ruby/st.h $(hdrdir)/ruby/subst.h $(arch_hdrdir)/ruby/config.h $(RUBY_EXTCONF_H)
|
115
116
|
|
116
117
|
RM = rm -f
|
@@ -161,7 +162,8 @@ ARCHHDRDIR = $(sitearchhdrdir)$(target_prefix)
|
|
161
162
|
TARGET_SO_DIR =
|
162
163
|
TARGET_SO = $(TARGET_SO_DIR)$(DLLIB)
|
163
164
|
CLEANLIBS = $(TARGET_SO) false
|
164
|
-
CLEANOBJS = *.
|
165
|
+
CLEANOBJS = $(OBJS) *.bak
|
166
|
+
TARGET_SO_DIR_TIMESTAMP = $(TIMESTAMP_DIR)/.sitearchdir.time
|
165
167
|
|
166
168
|
all: $(DLLIB)
|
167
169
|
static: $(STATIC_LIB)
|
@@ -182,12 +184,12 @@ distclean-static::
|
|
182
184
|
distclean: clean distclean-so distclean-static distclean-rb-default distclean-rb
|
183
185
|
-$(Q)$(RM) Makefile $(RUBY_EXTCONF_H) conftest.* mkmf.log
|
184
186
|
-$(Q)$(RM) core ruby$(EXEEXT) *~ $(DISTCLEANFILES)
|
185
|
-
-$(Q)$(RMDIRS) $(DISTCLEANDIRS) 2>
|
187
|
+
-$(Q)$(RMDIRS) $(DISTCLEANDIRS) 2> NUL || true
|
186
188
|
|
187
189
|
realclean: distclean
|
188
190
|
install: install-so install-rb
|
189
191
|
|
190
|
-
install-so: $(DLLIB) $(
|
192
|
+
install-so: $(DLLIB) $(TARGET_SO_DIR_TIMESTAMP)
|
191
193
|
$(INSTALL_PROG) $(DLLIB) $(RUBYARCHDIR)
|
192
194
|
clean-static::
|
193
195
|
-$(Q)$(RM) $(STATIC_LIB)
|
@@ -199,7 +201,7 @@ do-install-rb:
|
|
199
201
|
do-install-rb-default:
|
200
202
|
pre-install-rb-default:
|
201
203
|
@$(NULLCMD)
|
202
|
-
$(
|
204
|
+
$(TARGET_SO_DIR_TIMESTAMP):
|
203
205
|
$(Q) $(MAKEDIRS) $(@D) $(RUBYARCHDIR)
|
204
206
|
$(Q) $(TOUCH) $@
|
205
207
|
|
data/ext/extconf.rb
CHANGED
@@ -10,7 +10,7 @@ require 'down'
|
|
10
10
|
# +----------------------------------------------------------------------+
|
11
11
|
# | Licensed Materials - Property of IBM |
|
12
12
|
# | |
|
13
|
-
# | (C) Copyright IBM Corporation 2006 -
|
13
|
+
# | (C) Copyright IBM Corporation 2006 - 2024 |
|
14
14
|
# +----------------------------------------------------------------------+
|
15
15
|
|
16
16
|
TAR_LONGLINK = '././@LongLink'
|
@@ -90,8 +90,11 @@ elsif (RUBY_PLATFORM =~ /solaris/i)
|
|
90
90
|
DOWNLOADLINK = "https://public.dhe.ibm.com/ibmdl/export/pub/software/data/db2/drivers/odbc_cli/sunamd32_odbc_cli.tar.gz"
|
91
91
|
end
|
92
92
|
elsif (RUBY_PLATFORM =~ /darwin/i)
|
93
|
-
if(
|
94
|
-
puts "Detected platform - MacOS
|
93
|
+
if (RUBY_PLATFORM =~ /arm64/i)
|
94
|
+
puts "Detected platform - MacOS darwin arm64"
|
95
|
+
DOWNLOADLINK = "https://public.dhe.ibm.com/ibmdl/export/pub/software/data/db2/drivers/odbc_cli/macarm64_odbc_cli.tar.gz"
|
96
|
+
elsif(RUBY_PLATFORM =~ /x86_64/i || is64Bit)
|
97
|
+
puts "Detected platform - MacOS darwin x86_64"
|
95
98
|
DOWNLOADLINK = "https://public.dhe.ibm.com/ibmdl/export/pub/software/data/db2/drivers/odbc_cli/macos64_odbc_cli.tar.gz"
|
96
99
|
else
|
97
100
|
puts "Mac OS 32 bit not supported. Please use an x64 architecture."
|
@@ -151,11 +154,17 @@ def untarCLIPackage(archive,destination)
|
|
151
154
|
FileUtils.mkdir_p file, :mode => entry.header.mode, :verbose => false
|
152
155
|
elsif entry.file?
|
153
156
|
FileUtils.rm_rf file if File.directory? file
|
157
|
+
if (RUBY_PLATFORM =~ /darwin/i) && (RUBY_PLATFORM =~ /arm64/i) && File.exist?(file)
|
158
|
+
FileUtils.chmod 755, file, :verbose => false
|
159
|
+
end
|
154
160
|
File.open file, "wb" do |f|
|
155
161
|
f.print entry.read
|
156
162
|
end
|
157
163
|
FileUtils.chmod entry.header.mode, file, :verbose => false
|
158
164
|
elsif entry.header.typeflag == '2' #Symlink!
|
165
|
+
if (RUBY_PLATFORM =~ /darwin/i) && (RUBY_PLATFORM =~ /arm64/i) && File.exist?(file)
|
166
|
+
File.delete file if File.file? file
|
167
|
+
end
|
159
168
|
File.symlink entry.header.linkname, file
|
160
169
|
end
|
161
170
|
end
|
data/ext/ibm_db.c
CHANGED
@@ -2,7 +2,7 @@
|
|
2
2
|
+----------------------------------------------------------------------+
|
3
3
|
| Licensed Materials - Property of IBM |
|
4
4
|
| |
|
5
|
-
| (C) Copyright IBM Corporation 2006 -
|
5
|
+
| (C) Copyright IBM Corporation 2006 - 2025 |
|
6
6
|
+----------------------------------------------------------------------+
|
7
7
|
| Authors: Sushant Koduru, Lynh Nguyen, Kanchana Padmanabhan, |
|
8
8
|
| Dan Scott, Helmut Tessarek, Sam Ruby, Kellen Bombardier, |
|
@@ -12,7 +12,7 @@
|
|
12
12
|
+----------------------------------------------------------------------+
|
13
13
|
*/
|
14
14
|
|
15
|
-
#define MODULE_RELEASE "3.
|
15
|
+
#define MODULE_RELEASE "3.2.0"
|
16
16
|
|
17
17
|
#ifdef HAVE_CONFIG_H
|
18
18
|
#include "config.h"
|
@@ -686,8 +686,7 @@ static void _ruby_ibm_db_mark_stmt_struct(stmt_handle *handle)
|
|
686
686
|
static inline
|
687
687
|
VALUE ibm_Ruby_Thread_Call(rb_blocking_function_t *func, void *data1, rb_unblock_function_t *ubf, void *data2)
|
688
688
|
{
|
689
|
-
|
690
|
-
return (VALUE)rb_thread_call_without_gvl(f, data1, ubf, data2);
|
689
|
+
return func(data1);
|
691
690
|
}
|
692
691
|
|
693
692
|
|
@@ -9579,36 +9578,22 @@ static VALUE _ruby_ibm_db_bind_fetch_helper(ibm_db_fetch_helper_args *data)
|
|
9579
9578
|
return Qnil;
|
9580
9579
|
}
|
9581
9580
|
|
9582
|
-
|
9583
|
-
|
9584
|
-
|
9585
|
-
strcat(tmpStr, row_data->str_val);
|
9586
|
-
strcat(tmpStr, "\')");
|
9581
|
+
strcpy(tmpStr, "BigDecimal(\'");
|
9582
|
+
strcat(tmpStr, row_data->str_val);
|
9583
|
+
strcat(tmpStr, "\')");
|
9587
9584
|
|
9588
|
-
|
9589
|
-
|
9590
|
-
}
|
9591
|
-
if ( op == FETCH_INDEX ) {
|
9592
|
-
rb_ary_store(return_value, i, rb_eval_string(tmpStr) );
|
9593
|
-
} else if ( op == FETCH_BOTH ) {
|
9594
|
-
rb_hash_aset( return_value, INT2NUM(i), rb_eval_string( tmpStr ) );
|
9595
|
-
}
|
9596
|
-
|
9597
|
-
ruby_xfree(tmpStr);
|
9598
|
-
tmpStr = NULL;
|
9585
|
+
if ( op & FETCH_ASSOC ) {
|
9586
|
+
rb_hash_aset(return_value, colName, rb_eval_string(tmpStr));
|
9599
9587
|
}
|
9600
|
-
|
9601
|
-
|
9602
|
-
|
9603
|
-
|
9604
|
-
}
|
9605
|
-
if ( op == FETCH_INDEX ) {
|
9606
|
-
rb_ary_store(return_value, i, LONG2NUM(atol((char *)row_data->str_val)));
|
9607
|
-
} else if ( op == FETCH_BOTH ) {
|
9608
|
-
rb_hash_aset(return_value, INT2NUM(i), LONG2NUM(atol((char *)row_data->str_val)));
|
9609
|
-
}
|
9588
|
+
if ( op == FETCH_INDEX ) {
|
9589
|
+
rb_ary_store(return_value, i, rb_eval_string(tmpStr) );
|
9590
|
+
} else if ( op == FETCH_BOTH ) {
|
9591
|
+
rb_hash_aset( return_value, INT2NUM(i), rb_eval_string( tmpStr ) );
|
9610
9592
|
}
|
9611
9593
|
|
9594
|
+
ruby_xfree(tmpStr);
|
9595
|
+
tmpStr = NULL;
|
9596
|
+
|
9612
9597
|
break;
|
9613
9598
|
case SQL_SMALLINT:
|
9614
9599
|
if ( op & FETCH_ASSOC ) {
|
@@ -11238,7 +11223,7 @@ VALUE ibm_db_server_info(int argc, VALUE *argv, VALUE self)
|
|
11238
11223
|
rb_scan_args(argc, argv, "1", &connection);
|
11239
11224
|
|
11240
11225
|
|
11241
|
-
if(NIL_P(
|
11226
|
+
if(NIL_P(connection))
|
11242
11227
|
{
|
11243
11228
|
}
|
11244
11229
|
if(&connection == NULL)
|
data/ext/ibm_db.o
CHANGED
Binary file
|
data/ext/ibm_db.so
CHANGED
Binary file
|
data/ext/mkmf.log
CHANGED
@@ -14,7 +14,7 @@ unicode_support_version.h is:
|
|
14
14
|
|
15
15
|
have_library: checking for SQLConnect() in -ldb2cli... -------------------- yes
|
16
16
|
|
17
|
-
PATH=".;C:/
|
17
|
+
PATH=".;C:/Ruby33/lib;C:\Ruby33\bin;C:\Ruby33\msys32\mingw32\bin;C:\Ruby33\msys32\usr\bin;C:\Users\pnarayanappa\Python\Python311\;C:\Users\pnarayanappa\Python\Python311\Scripts\;C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\ibm\gsk8\lib64;C:\Program Files (x86)\ibm\gsk8\lib;C:\Program Files\Java\jre1.8.0_231\bin;C:\Program Files\Microsoft SQL Server\130\Tools\Binn\;C:\Program Files\PuTTY\;C:\Program Files\OpenSSH-Win64;C:\Program Files\Microsoft SQL Server\110\Tools\Binn\;C:\Program Files\Microsoft SQL Server\120\Tools\Binn\;C:\Users\pnarayanappa\AppData\Roaming\Python\Python37\Scripts\;C:\Program Files\dotnet\;C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\170\Tools\Binn\;C:\Program Files (x86)\Microsoft SDKs\TypeScript\1.0\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;C:\Program Files\Git\cmd;C:\Ruby33\bin;C:\mingw-w64\i686-8.1.0-posix-dwarf-rt_v6-rev0\mingw32\bin;C:\Users\pnarayanappa\AppData\Local\Programs\Microsoft VS Code\bin;C:\Users\pnarayanappa\.dotnet\tools;C:\Users\pnarayanappa\AppData\Local\Microsoft\WindowsApps" "gcc -o conftest.exe -IC:/Ruby33/include/ruby-3.3.0/i386-mingw32 -IC:/Ruby33/include/ruby-3.3.0/ruby/backward -IC:/Ruby33/include/ruby-3.3.0 -I. -IC:/Users/pnarayanappa/ruby-ibmdb/IBM_DB_Adapter/ibm_db/ext/../lib/clidriver/include -DFD_SETSIZE=2048 -D_WIN32_WINNT=0x0600 -D__MINGW_USE_VC2005_COMPAT -D_FILE_OFFSET_BITS=64 -O3 -fno-fast-math -fstack-protector-strong conftest.c -L. -LC:/Ruby33/lib -LC:/Users/pnarayanappa/ruby-ibmdb/IBM_DB_Adapter/ibm_db/ext/../lib/clidriver/lib -L. -pipe -s -fstack-protector-strong -Wl,--no-as-needed -lmsvcrt-ruby330 -lshell32 -lws2_32 -liphlpapi -limagehlp -lshlwapi -lbcrypt "
|
18
18
|
checked program was:
|
19
19
|
/* begin */
|
20
20
|
1: #include "ruby.h"
|
@@ -27,12 +27,12 @@ checked program was:
|
|
27
27
|
8: }
|
28
28
|
/* end */
|
29
29
|
|
30
|
-
PATH=".;C:/
|
30
|
+
PATH=".;C:/Ruby33/lib;C:\Ruby33\bin;C:\Ruby33\msys32\mingw32\bin;C:\Ruby33\msys32\usr\bin;C:\Users\pnarayanappa\Python\Python311\;C:\Users\pnarayanappa\Python\Python311\Scripts\;C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\ibm\gsk8\lib64;C:\Program Files (x86)\ibm\gsk8\lib;C:\Program Files\Java\jre1.8.0_231\bin;C:\Program Files\Microsoft SQL Server\130\Tools\Binn\;C:\Program Files\PuTTY\;C:\Program Files\OpenSSH-Win64;C:\Program Files\Microsoft SQL Server\110\Tools\Binn\;C:\Program Files\Microsoft SQL Server\120\Tools\Binn\;C:\Users\pnarayanappa\AppData\Roaming\Python\Python37\Scripts\;C:\Program Files\dotnet\;C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\170\Tools\Binn\;C:\Program Files (x86)\Microsoft SDKs\TypeScript\1.0\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;C:\Program Files\Git\cmd;C:\Ruby33\bin;C:\mingw-w64\i686-8.1.0-posix-dwarf-rt_v6-rev0\mingw32\bin;C:\Users\pnarayanappa\AppData\Local\Programs\Microsoft VS Code\bin;C:\Users\pnarayanappa\.dotnet\tools;C:\Users\pnarayanappa\AppData\Local\Microsoft\WindowsApps" "gcc -o conftest.exe -IC:/Ruby33/include/ruby-3.3.0/i386-mingw32 -IC:/Ruby33/include/ruby-3.3.0/ruby/backward -IC:/Ruby33/include/ruby-3.3.0 -I. -IC:/Users/pnarayanappa/ruby-ibmdb/IBM_DB_Adapter/ibm_db/ext/../lib/clidriver/include -DFD_SETSIZE=2048 -D_WIN32_WINNT=0x0600 -D__MINGW_USE_VC2005_COMPAT -D_FILE_OFFSET_BITS=64 -O3 -fno-fast-math -fstack-protector-strong conftest.c -L. -LC:/Ruby33/lib -LC:/Users/pnarayanappa/ruby-ibmdb/IBM_DB_Adapter/ibm_db/ext/../lib/clidriver/lib -L. -pipe -s -fstack-protector-strong -Wl,--no-as-needed -lmsvcrt-ruby330 -ldb2cli -lshell32 -lws2_32 -liphlpapi -limagehlp -lshlwapi -lbcrypt "
|
31
31
|
conftest.c: In function 't':
|
32
32
|
conftest.c:17:57: error: 'SQLConnect' undeclared (first use in this function); did you mean 'WSAConnect'?
|
33
|
-
int t(void) { void ((*volatile p)()); p = (void ((*)()))SQLConnect; return !p; }
|
34
|
-
^~~~~~~~~~
|
35
|
-
WSAConnect
|
33
|
+
17 | int t(void) { void ((*volatile p)()); p = (void ((*)()))SQLConnect; return !p; }
|
34
|
+
| ^~~~~~~~~~
|
35
|
+
| WSAConnect
|
36
36
|
conftest.c:17:57: note: each undeclared identifier is reported only once for each function it appears in
|
37
37
|
checked program was:
|
38
38
|
/* begin */
|
@@ -55,7 +55,7 @@ checked program was:
|
|
55
55
|
17: int t(void) { void ((*volatile p)()); p = (void ((*)()))SQLConnect; return !p; }
|
56
56
|
/* end */
|
57
57
|
|
58
|
-
PATH=".;C:/
|
58
|
+
PATH=".;C:/Ruby33/lib;C:\Ruby33\bin;C:\Ruby33\msys32\mingw32\bin;C:\Ruby33\msys32\usr\bin;C:\Users\pnarayanappa\Python\Python311\;C:\Users\pnarayanappa\Python\Python311\Scripts\;C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\ibm\gsk8\lib64;C:\Program Files (x86)\ibm\gsk8\lib;C:\Program Files\Java\jre1.8.0_231\bin;C:\Program Files\Microsoft SQL Server\130\Tools\Binn\;C:\Program Files\PuTTY\;C:\Program Files\OpenSSH-Win64;C:\Program Files\Microsoft SQL Server\110\Tools\Binn\;C:\Program Files\Microsoft SQL Server\120\Tools\Binn\;C:\Users\pnarayanappa\AppData\Roaming\Python\Python37\Scripts\;C:\Program Files\dotnet\;C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\170\Tools\Binn\;C:\Program Files (x86)\Microsoft SDKs\TypeScript\1.0\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;C:\Program Files\Git\cmd;C:\Ruby33\bin;C:\mingw-w64\i686-8.1.0-posix-dwarf-rt_v6-rev0\mingw32\bin;C:\Users\pnarayanappa\AppData\Local\Programs\Microsoft VS Code\bin;C:\Users\pnarayanappa\.dotnet\tools;C:\Users\pnarayanappa\AppData\Local\Microsoft\WindowsApps" "gcc -o conftest.exe -IC:/Ruby33/include/ruby-3.3.0/i386-mingw32 -IC:/Ruby33/include/ruby-3.3.0/ruby/backward -IC:/Ruby33/include/ruby-3.3.0 -I. -IC:/Users/pnarayanappa/ruby-ibmdb/IBM_DB_Adapter/ibm_db/ext/../lib/clidriver/include -DFD_SETSIZE=2048 -D_WIN32_WINNT=0x0600 -D__MINGW_USE_VC2005_COMPAT -D_FILE_OFFSET_BITS=64 -O3 -fno-fast-math -fstack-protector-strong conftest.c -L. -LC:/Ruby33/lib -LC:/Users/pnarayanappa/ruby-ibmdb/IBM_DB_Adapter/ibm_db/ext/../lib/clidriver/lib -L. -pipe -s -fstack-protector-strong -Wl,--no-as-needed -lmsvcrt-ruby330 -ldb2cli -lshell32 -lws2_32 -liphlpapi -limagehlp -lshlwapi -lbcrypt "
|
59
59
|
checked program was:
|
60
60
|
/* begin */
|
61
61
|
1: #include "ruby.h"
|
@@ -82,7 +82,7 @@ checked program was:
|
|
82
82
|
|
83
83
|
have_header: checking for gil_release_version.h... -------------------- yes
|
84
84
|
|
85
|
-
PATH=".;C:/
|
85
|
+
PATH=".;C:/Ruby33/lib;C:\Ruby33\bin;C:\Ruby33\msys32\mingw32\bin;C:\Ruby33\msys32\usr\bin;C:\Users\pnarayanappa\Python\Python311\;C:\Users\pnarayanappa\Python\Python311\Scripts\;C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\ibm\gsk8\lib64;C:\Program Files (x86)\ibm\gsk8\lib;C:\Program Files\Java\jre1.8.0_231\bin;C:\Program Files\Microsoft SQL Server\130\Tools\Binn\;C:\Program Files\PuTTY\;C:\Program Files\OpenSSH-Win64;C:\Program Files\Microsoft SQL Server\110\Tools\Binn\;C:\Program Files\Microsoft SQL Server\120\Tools\Binn\;C:\Users\pnarayanappa\AppData\Roaming\Python\Python37\Scripts\;C:\Program Files\dotnet\;C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\170\Tools\Binn\;C:\Program Files (x86)\Microsoft SDKs\TypeScript\1.0\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;C:\Program Files\Git\cmd;C:\Ruby33\bin;C:\mingw-w64\i686-8.1.0-posix-dwarf-rt_v6-rev0\mingw32\bin;C:\Users\pnarayanappa\AppData\Local\Programs\Microsoft VS Code\bin;C:\Users\pnarayanappa\.dotnet\tools;C:\Users\pnarayanappa\AppData\Local\Microsoft\WindowsApps" "gcc -IC:/Ruby33/include/ruby-3.3.0/i386-mingw32 -IC:/Ruby33/include/ruby-3.3.0/ruby/backward -IC:/Ruby33/include/ruby-3.3.0 -I. -IC:/Users/pnarayanappa/ruby-ibmdb/IBM_DB_Adapter/ibm_db/ext/../lib/clidriver/include -DFD_SETSIZE=2048 -D_WIN32_WINNT=0x0600 -D__MINGW_USE_VC2005_COMPAT -D_FILE_OFFSET_BITS=64 -O3 -fno-fast-math -fstack-protector-strong -c conftest.c"
|
86
86
|
checked program was:
|
87
87
|
/* begin */
|
88
88
|
1: #include "ruby.h"
|
@@ -96,7 +96,7 @@ checked program was:
|
|
96
96
|
|
97
97
|
have_header: checking for unicode_support_version.h... -------------------- yes
|
98
98
|
|
99
|
-
PATH=".;C:/
|
99
|
+
PATH=".;C:/Ruby33/lib;C:\Ruby33\bin;C:\Ruby33\msys32\mingw32\bin;C:\Ruby33\msys32\usr\bin;C:\Users\pnarayanappa\Python\Python311\;C:\Users\pnarayanappa\Python\Python311\Scripts\;C:\Program Files (x86)\Common Files\Oracle\Java\javapath;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\ibm\gsk8\lib64;C:\Program Files (x86)\ibm\gsk8\lib;C:\Program Files\Java\jre1.8.0_231\bin;C:\Program Files\Microsoft SQL Server\130\Tools\Binn\;C:\Program Files\PuTTY\;C:\Program Files\OpenSSH-Win64;C:\Program Files\Microsoft SQL Server\110\Tools\Binn\;C:\Program Files\Microsoft SQL Server\120\Tools\Binn\;C:\Users\pnarayanappa\AppData\Roaming\Python\Python37\Scripts\;C:\Program Files\dotnet\;C:\Program Files\Microsoft SQL Server\Client SDK\ODBC\170\Tools\Binn\;C:\Program Files (x86)\Microsoft SDKs\TypeScript\1.0\;C:\WINDOWS\system32;C:\WINDOWS;C:\WINDOWS\System32\Wbem;C:\WINDOWS\System32\WindowsPowerShell\v1.0\;C:\WINDOWS\System32\OpenSSH\;C:\Program Files\Git\cmd;C:\Ruby33\bin;C:\mingw-w64\i686-8.1.0-posix-dwarf-rt_v6-rev0\mingw32\bin;C:\Users\pnarayanappa\AppData\Local\Programs\Microsoft VS Code\bin;C:\Users\pnarayanappa\.dotnet\tools;C:\Users\pnarayanappa\AppData\Local\Microsoft\WindowsApps" "gcc -IC:/Ruby33/include/ruby-3.3.0/i386-mingw32 -IC:/Ruby33/include/ruby-3.3.0/ruby/backward -IC:/Ruby33/include/ruby-3.3.0 -I. -IC:/Users/pnarayanappa/ruby-ibmdb/IBM_DB_Adapter/ibm_db/ext/../lib/clidriver/include -DFD_SETSIZE=2048 -D_WIN32_WINNT=0x0600 -D__MINGW_USE_VC2005_COMPAT -D_FILE_OFFSET_BITS=64 -O3 -fno-fast-math -fstack-protector-strong -c conftest.c"
|
100
100
|
checked program was:
|
101
101
|
/* begin */
|
102
102
|
1: #include "ruby.h"
|
data/ext/ruby_ibm_db_cli.c
CHANGED
@@ -208,7 +208,7 @@ int _ruby_ibm_db_SQLForeignKeys_helper(metadata_args *data) {
|
|
208
208
|
|
209
209
|
data->stmt_res->is_executing = 1;
|
210
210
|
|
211
|
-
if(!NIL_P(data->table_type))
|
211
|
+
if(data->table_type != NULL && !NIL_P(*data->table_type))
|
212
212
|
{
|
213
213
|
#ifndef UNICODE_SUPPORT_VERSION_H
|
214
214
|
rc = SQLForeignKeys( (SQLHSTMT) data->stmt_res->hstmt, data->qualifier, data->qualifier_len,
|
data/ext/ruby_ibm_db_cli.h
CHANGED
@@ -11,6 +11,14 @@
|
|
11
11
|
#ifndef RUBY_IBM_DB_CLI_H
|
12
12
|
#define RUBY_IBM_DB_CLI_H
|
13
13
|
|
14
|
+
#ifdef _WIN32
|
15
|
+
#ifndef _MSC_VER
|
16
|
+
#define __out_ecount_opt(x)
|
17
|
+
#define __in_ecount_opt(x)
|
18
|
+
#define __out_bcount_opt(x)
|
19
|
+
#endif
|
20
|
+
#endif
|
21
|
+
|
14
22
|
#ifdef _WIN32
|
15
23
|
#include <windows.h>
|
16
24
|
#else
|
data/ext/ruby_ibm_db_cli.o
CHANGED
Binary file
|
data/lib/IBM_DB.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
if(RUBY_PLATFORM =~ /darwin/i)
|
2
2
|
cliPackagePath = File.dirname(__FILE__) + '/clidriver'
|
3
|
-
if(Dir.
|
3
|
+
if(Dir.exist?(cliPackagePath))
|
4
4
|
currentPath = "#{File.expand_path(File.dirname(File.dirname(__FILE__)))}"
|
5
5
|
|
6
6
|
cmd = "chmod 755 #{currentPath}/lib/ibm_db.bundle "
|