Commit graph

325 commits

Author SHA1 Message Date
usa
e668a019a7 * win32/Makefile.sub (config.status): include winsock2.h instead of
winsock.h when --with-winsock2 is specified.
  fixed: [ruby-dev:29296]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10749 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-08-19 05:17:43 +00:00
nobu
c41890583f * win32/win32.h: removed an excess macro. fixed: [ruby-dev:29258]
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10728 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-08-16 02:08:34 +00:00
nobu
05bc15b0ec * win32/win32.c (init_stdhandle): assign standard file handles.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10655 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-08-01 08:44:44 +00:00
usa
eec1f2882e * win32/win32.c (exit_handler): new function; release winsock and
environment work area.

* win32/win32.c (NTInitialize): setup exit_handler.

* win32/win32.c (StartSockets): use exit_handler.
  exit handler.

* win32/win32.c (rb_w32_getenv): use GetEnvironmentStrings() instead
  of GetEnvironmentVariable(), because the latter cannot distinguish
  wheather a null environment variable exists or not.
  fixed: [ruby-talk:205123]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10651 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-07-31 08:09:01 +00:00
usa
45b085a0b2 * win32/win32.c (open_ifs_socket): should not use plain malloc.
* win32/win32.c (rb_w32_opendir): should not use plain realloc.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10562 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-07-18 14:13:07 +00:00
eban
76f1a4f010 * win32/win32.h: define isascii on MinGW for msvcrt compatibility.
* configure.in: set ac_cv_header_sys_time_h=no on MinGW
  for msvcrt compatibility.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10409 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-06-27 07:21:31 +00:00
usa
c52019ffe7 * win32/win32.[ch] (rb_w32_send, rb_w32_sendto): constified.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10393 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-06-26 00:57:31 +00:00
usa
1c2b8571ee * win32/win32.h (write): not need to define on bcc.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10252 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-06-11 01:01:48 +00:00
usa
98f09b9618 * win32/win32.[ch] (rb_w32_read, rb_w32_write): new functions.
use recv() and send() when fd is socket. fixed: [ruby-dev:28694]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10233 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-06-08 05:20:00 +00:00
usa
1ea51f02ec * win32/win32.c (errmap): add some winsock errors.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10227 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-06-07 05:53:46 +00:00
usa
67fa40f429 * win32/configure.bat: add help message.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10225 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-06-07 02:44:55 +00:00
usa
ae229456fb * configure.in: add new configure option `--with-winsock2' for mingw.
* win32/Makefile.sub (config.h): define USE_WINSOCK2 in config.h
  instead of in CPPFLAGS.

* ext/socket/extconf.rb: determine whether to use winsock2 or not
  by using with_config.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10224 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-06-07 02:40:22 +00:00
usa
4e19b0e00f * win32/{configure.bat, setup.mak, Makefile.sub, win32.h}: add
support new configure option `--with-winsock2'.

* win32/win32.c (StartSockets): ditto.

* ext/socket/extconf.rb: ditto.

* win32/win32.c (open_ifs_socket): new function.

* win32/win32.c (StartSockets, rb_w32_socket): use open_ifs_socket()
  instead of socket().
  ifs socket support is backported from trunk.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10223 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-06-07 01:51:47 +00:00
nobu
ae6dedc7f0 * win32/win32.c (rb_w32_cmdvector): backslashes inside single-quotes
no longer has special meanings.  fixed: [ruby-list:42311]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10202 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-06-01 10:13:41 +00:00
usa
02821cc038 * win32/win32.c (rb_w32_getcwd): runtime's getcwd() will not success
if the length of the cwd is longer than MAX_PATH.
  fixed [ruby-list:42335]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10201 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-06-01 07:18:12 +00:00
usa
ee39e2578a * win32/win32.c (rb_w32_getcwd): set errno if not set.
fixed [ruby-list:42346]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10199 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-06-01 02:34:30 +00:00
nobu
65937b5eb9 * ruby.h, lib/mkmf.rb (create_header): clear command line options for
macros moved to extconf.h.

* ext/extmk.rb (extract_makefile, extmk): made RUBY_EXTCONF_H and
  EXTSTATIC permanent.

* ext/{dbm,digest/*,socket,zlib}/extconf.rb: used $defs and $INCFLAGS.

* {bcc32,win32,wince}/Makefile.sub (COMPILE_C, COMPILE_CXX): added
  $(INCFLAGS).


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10193 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-05-25 23:44:08 +00:00
nobu
aa9da28961 * mkconfig.rb: merge multiple entries to an entry with multiple lines.
* lib/mkmf.rb: allow a series of commands to link.

* win32/Makefile.sub: embed manifests.

* win32/setup.mak: suffix OS name by runtime version.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10189 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-05-24 16:52:00 +00:00
ocean
8bd7f1ecc5 * win32/win32.c (filetime_to_unixtime): should set tm_isdst to -1.
stat() didn't treat daylight saving time property on WinNT.
  [ruby-talk:182100]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@10011 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-03-02 04:01:31 +00:00
usa
d23d055d47 * time.c (time_new_internal): add prototype to tell the compiler
arugments types.

* win32/win32.c (NtInitialize): need to set a handler for VC++8.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9995 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-02-24 02:22:33 +00:00
usa
9c0aa2d017 * configure.in (mingw): have link.
* win32/Makefile.sub (config.h): ditto.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9975 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-02-20 17:20:55 +00:00
usa
4b7ecb15d1 * time.c (search_time_t): support non 32bit time_t environments.
* win32/Makefile.sub (config.h): VC++8 has ``long long'' type.

* win32/Makefile.sub (config.h): VC++8's time_t is 64bit value.

* win32/win32.c (rb_w32_utime): drop read-only attribute before
  changing file time.

  all changes are backported from CVS HEAD.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9929 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-02-14 05:03:16 +00:00
usa
49a2b019f6 * win32/win32.c (LK_ERR): ERROR_NOT_LOCKED is not an error.
In such situation, flock() should return 0.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9884 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-02-04 12:21:55 +00:00
usa
c81b214021 * win32/setup.mak (MAKE): workaround for nmake 8.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9840 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-01-17 02:33:29 +00:00
usa
1c102070bb * win32/{Makefile.sub,setup.mak}: invoke .bat via shell. workaround
for nmake 8.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9838 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-01-17 02:11:32 +00:00
ocean
c16cbe386a * win32/Makefile.sub (OPTFLAGS): I have experienced trouble on y- flag,
(VisualC++6) so use -O2b2xg- if  $(MSC_VER) < 1400. [ruby-core:7040]

* lib/webrick/httpservlet/filehandler.rb: fixed typo. (Kero van Gelder)
  [ruby-core:7075]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9809 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-01-09 05:27:43 +00:00
usa
b12d498a0a * win32/win32.c (ioinfo): revert previous commit. sorry.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9800 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-01-06 02:27:33 +00:00
usa
4f092ec3d0 * win32/win32.c (ioinfo): VC++8 support, forgotten to commit.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9795 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-01-05 10:05:08 +00:00
ocean
73a71e19c8 * win32/win32.c (rb_w32_seekdir): should not segfault even if passed
the location which rb_w32_telldir didn't return. [ruby-core:7035]

* test/ruby/test_dir.rb: added.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9787 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2006-01-01 08:12:39 +00:00
nobu
2ffedb5f29 * win32/Makefile.sub: VC++8 support.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9772 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-12-30 09:23:15 +00:00
usa
34664e81af * file.c (eaccess): workaround for VC++8 runtime.
* win32/win32.c (ioinfo): VC++8 support.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9767 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-12-29 19:55:58 +00:00
ocean
67ea4d0242 * win32/win32.c (rb_w32_strerror): remove all CR and LF. (avoid broken
error message on bccwin32 + winsock)


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9625 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-11-28 04:24:26 +00:00
nobu
fff3548e04 * file.c (test_identical): test if two files are identical.
* file.c (rb_f_test): support DOSISH systems where st_ino is not
  reliable.  fixed: [ruby-core:06672]

* win32.h, win32.c (rb_w32_osid): check the running platform.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9590 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-11-22 16:26:39 +00:00
ocean
4dc782978d * win32/win32.c (winnt_stat): set mapped errno instead of ENOENT.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9588 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-11-22 09:42:09 +00:00
ocean
bb935564fd * win32/win32.c (rb_w32_stat): Dir.chdir('//server/shared');
p Dir.glob('*') should work on WinNT. (implemented our own
  stat(2) on WinNT) [ruby-list:41552] [ruby-dev:27711]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9584 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-11-22 04:21:01 +00:00
ocean
5729217ccc * win32/setup.mk: findstr doesn't exist on win9x.
fixed: [ruby-dev:27756] (written by nobu)


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9575 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-11-21 07:12:57 +00:00
ocean
d63a0bb871 * win32/win32.h (S_IFIFO): r,w = IO.pipe; r.stat.pipe? now
returns true on VisualC++6.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9557 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-11-18 03:22:26 +00:00
nobu
17f022491a * configure.in (RUBY_EXTERN): macro to export symbols in shared
library.  [ruby-core:05528]

* defines.h, {bcc32,win32,wince}/Makefile.sub (RUBY_EXTERN): moved to
  configuration pass.

* ext/extmk.rb (extmake): RUBY_EXTERN for static linked extensions.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9466 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-10-25 17:00:03 +00:00
usa
45e155dbe5 * win32/win32.c (ioctl): should set errno.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9390 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-10-14 13:09:11 +00:00
ocean
b8bc87839d * win32/win32.h (rb_w32_stat): added prototype.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9168 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-09-15 14:06:48 +00:00
nobu
14e256f4b1 * dir.c (ruby_glob): glob function not using ruby exception system.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9158 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-09-14 13:41:02 +00:00
usa
4326e98025 * win32/Makefile.sub (OPTFLAGS): default global optimization to
disabled for all VC++ versions.  fixed: [ruby-dev:26897]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9060 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-08-31 05:43:51 +00:00
ocean
78604644e2 * bcc32/Makefile.sub (COMMON_HEADERS): reverted 1.42.2.24.
I misunderstood, bccwin32 on ruby_1_8 uses winsock2 originally.
  [ruby-dev:26806]

* win32/win32.h: include winsock2.h instead of winsock.h. (bcc32)


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@9004 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-08-18 03:50:47 +00:00
ocean
4d11a486ae * win32/win32.c: just uniformed method style.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@8924 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-08-05 04:19:22 +00:00
nobu
e869ff20a3 * common.mk, Makefile.in, {bcc32,win32,wince}/Makefile.sub: integrated
macro definitions.

* bcc32/Makefile.sub: LIBRUBY_SO should use DLDOBJS, not EXTOBJS.

* {win32,wince}/Makefile.sub: separate config.h for compiler versions.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@8902 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-08-03 15:27:13 +00:00
nobu
983c7c74ee * {bcc32,win32,wince}/Makefile.sub: moved CPPFLAGS only for ruby
source to XCFLAGS.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@8834 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-07-25 12:31:21 +00:00
ocean
0661db665e * win32/win32.c (rb_w32_strerror): should return correct message
for ENAMETOOLONG and ENOTEMPTY. (bcc32) [ruby-dev:26533]

* win32/win32.c (rb_w32_strerror): stripped CR LF on the tail.
  (bcc32) [ruby-dev:26533]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@8761 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-07-14 09:33:52 +00:00
ocean
d20bc9f4d2 * win32/win32.c (rb_w32_mkdir): should set EEXIST (not EACCES)
if file or directory already exists. (bcc32)

* win32/win32.c (rb_w32_rmdir): should set ENOTDIR (not EINVAL)
  if it is not directory. (bcc32, win32)

* win32/win32.c (rb_w32_rmdir, rb_w32_unlink): restore
  FILE_ATTRIBUTE_READONLY flag on function failure.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@8756 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-07-13 10:40:06 +00:00
matz
32d0d609e9 * missing/erf.c: need to include some headers for some platforms.
* win32/win32.h (copysign, scalb): define for compatibility with
  other platforms. [ruby-dev:26430]

* missing/crypt.c: modified to make it compilable on platforms
  other than BSD.  [ruby-dev:26430]

* missing/erf.c: ditto.  code from <exp.c> merged.


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@8692 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-07-01 07:23:40 +00:00
usa
8f8d7c1113 * ext/dbm/dbm.c (fdbm_closed): new method DBM#closed?
* ext/gdbm/gdbm.c (fgdbm_closed): new method GDBM#closed?

* ext/sdbm/init.c (fsdbm_closed): new method SDBM#closed?

* test/dbm/test_dbm.rb, test/gdbm/test_gdbm.rb, test/sdbm/test_sdbm.rb
  (teardown): close all db objects before deleting data files.

* win32/win32.{ch} (unlink): hook runtime function to change
  file attribute before unlinking.
  fixed: [ruby-dev:26360]


git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/branches/ruby_1_8@8648 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
2005-06-20 07:53:22 +00:00