Changeset 46fd4a
- Timestamp:
- 10/05/08 13:41:32 (4 years ago)
- Branches:
- master
- Children:
- c346b2
- Parents:
- 11df21
- git-author:
- Tomash Brechko <tomash.brechko@…> (09/29/08 10:31:01)
- git-committer:
- Tomash Brechko <tomash.brechko@…> (10/05/08 13:41:32)
- Files:
-
- 2 added
- 7 edited
-
Changes (modified) (1 diff)
-
MANIFEST (modified) (1 diff)
-
README (modified) (1 diff)
-
lib/Cache/Memcached/Fast.pm (modified) (1 diff)
-
src/Makefile.PL (modified) (2 diffs)
-
src/client.c (modified) (8 diffs)
-
src/connect.c (modified) (1 diff)
-
src/socket_win32.c (added)
-
src/socket_win32.h (added)
Legend:
- Unmodified
- Added
- Removed
-
Changes
r6fee7e r46fd4a 2 2 3 3 0.13 ??? 4 - ??? 4 - introduce Win32 support (based on the patch by Yasuhiro 5 Matsumoto---arigatou!). 5 6 6 7 Changes since 0.12: 7 8 8 ??? 9 Add support for Win32. I personally don't have the system nor 10 compiler, so I can't even test the build. Win32 port is 11 expected to be supported by community. 9 12 10 13 -
MANIFEST
r11df21 r46fd4a 36 36 src/socket_posix.c 37 37 src/socket_posix.h 38 src/socket_win32.c 39 src/socket_win32.h -
README
r6fee7e r46fd4a 19 19 API and may be used by itself). 20 20 21 The module should compile and work on any Unix-derived system. 22 According to CPAN testers it doesn't compile on Windows, patches are 23 welcome.21 The module should compile and work on any Unix-derived system. Win32 22 support is based on the patch by Yasuhiro Matsumoto---thanks!, and is 23 (expected to be) supported by community. 24 24 25 25 Despite the low version number (which mainly reflects release history) -
lib/Cache/Memcached/Fast.pm
r6fee7e r46fd4a 1382 1382 Thanks to S<Peter J. Holzer> for enlightening on UTF-8 support. 1383 1383 1384 Thanks to S<Yasuhiro Matsumoto> for initial Win32 patch. 1385 1384 1386 1385 1387 =head1 WARRANTY -
src/Makefile.PL
r182fc0 r46fd4a 3 3 use warnings; 4 4 use ExtUtils::MakeMaker; 5 6 7 my @c = ('parse_keyword.c', 'compute_crc32.c', <*.c>); 8 my $exclude; 9 if ($^O eq 'MSWin32') { 10 $exclude = 'socket_posix.c'; 11 } else { 12 $exclude = 'socket_win32.c'; 13 } 14 15 my @object = grep { $_ ne $exclude } @c; 16 map { s/\.c$/\$(OBJ_EXT)/ } @object; 17 5 18 6 19 # See lib/ExtUtils/MakeMaker.pm for details of how to influence … … 13 26 DEFINE => '', # e.g., '-DHAVE_SOMETHING' 14 27 INC => '-I.', # e.g., '-I. -I/usr/include/other' 15 OBJECT => 'parse_keyword$(OBJ_EXT) compute_crc32$(OBJ_EXT) 16 $(O_FILES)', 28 OBJECT => "@object", 17 29 clean => { FILES => 'compute_crc32.c compute_crc32.h' 18 30 . ' parse_keyword.c parse_keyword.h' }, -
src/client.c
r11df21 r46fd4a 30 30 #include <string.h> 31 31 #include <stdio.h> 32 #ifndef WIN32 32 33 #include <sys/uio.h> 33 34 #include <signal.h> … … 36 37 #include <netinet/tcp.h> 37 38 #include "socket_posix.h" 39 #else /* WIN32 */ 40 #include "socket_win32.h" 41 #endif /* WIN32 */ 38 42 39 43 … … 337 341 client_init() 338 342 { 343 #ifdef WIN32 344 if (win32_socket_library_acquire() != 0) 345 return NULL; 346 #endif /* WIN32 */ 347 339 348 struct client *c = malloc(sizeof(struct client)); 340 349 if (! c) … … 391 400 free(c->prefix); 392 401 free(c); 402 403 #ifdef WIN32 404 win32_socket_library_release(); 405 #endif /* WIN32 */ 393 406 } 394 407 … … 1371 1384 int first_iter = 1; 1372 1385 1373 #if ndef MSG_NOSIGNAL1386 #if ! defined(MSG_NOSIGNAL) && ! defined(WIN32) 1374 1387 struct sigaction orig, ignore; 1375 1388 int res; … … 1381 1394 if (res == -1) 1382 1395 return MEMCACHED_FAILURE; 1383 #endif /* ! MSG_NOSIGNAL*/1396 #endif /* ! defined(MSG_NOSIGNAL) && ! defined(WIN32) */ 1384 1397 1385 1398 while (1) … … 1508 1521 } 1509 1522 1510 #if ndef MSG_NOSIGNAL1523 #if ! defined(MSG_NOSIGNAL) && ! defined(WIN32) 1511 1524 /* 1512 1525 Ignore return value of sigaction(), there's nothing we can do in … … 1514 1527 */ 1515 1528 sigaction(SIGPIPE, &orig, NULL); 1516 #endif /* ! MSG_NOSIGNAL*/1529 #endif /* ! defined(MSG_NOSIGNAL) && ! defined(WIN32) */ 1517 1530 1518 1531 return MEMCACHED_SUCCESS; -
src/connect.c
r11df21 r46fd4a 24 24 #include "connect.h" 25 25 #include <string.h> 26 #ifndef WIN32 26 27 #include <netdb.h> 27 28 #include "socket_posix.h" 29 #else /* WIN32 */ 30 #include "socket_win32.h" 31 #endif /* WIN32 */ 28 32 29 33
Note: See TracChangeset
for help on using the changeset viewer.
