Don't worry about the missing lib error - this will happen on a number of OS - (I get it on Linux here).
Personally I think that would do something like this - but I can't test it right now:
--- UUID.h 2003-08-27 20:38:35.000000000 +0100
+++ UUID.h.new 2005-08-09 21:57:39.000000000 +0100
@@ -1,10 +1,15 @@
#if !defined __UUID_H__
# define __UUID_H__
+#if defined __CYGWIN__ || __MINGW32__ || WIN32
+# define USE_WIN32
+#endif
#include <string.h>
#include <stdio.h>
#include <stdlib.h>
-#include <unistd.h>
+#ifndef WIN32
+# include <unistd.h>
+#endif
#include <time.h>
#include "md5.h"
--- UUID.xs 2003-08-27 20:38:35.000000000 +0100
+++ UUID.xs.new 2005-08-09 21:58:27.000000000 +0100
@@ -105,7 +105,7 @@
}
static void get_system_time(uuid_time_t *uuid_time) {
-#if defined __CYGWIN__ || __MINGW32__
+#if defined USE_WIN32
/* ULARGE_INTEGER time; */
LARGE_INTEGER time;
@@ -129,7 +129,7 @@
static void get_random_info(unsigned char seed[16]) {
MD5_CTX c;
-#if defined __CYGWIN__ || __MINGW32__
+#if defined USE_WIN32
typedef struct {
MEMORYSTATUS m;
SYSTEM_INFO s;
@@ -150,7 +150,7 @@
MD5Init(&c);
-#if defined __CYGWIN__ || __MINGW32__
+#if defined USE_WIN32
GlobalMemoryStatus(&r.m);
GetSystemInfo(&r.s);
GetSystemTimeAsFileTime(&r.t);
/J\
-
Are you posting in the right place? Check out Where do I post X? to know for sure.
-
Posts may use any of the Perl Monks Approved HTML tags. Currently these include the following:
<code> <a> <b> <big>
<blockquote> <br /> <dd>
<dl> <dt> <em> <font>
<h1> <h2> <h3> <h4>
<h5> <h6> <hr /> <i>
<li> <nbsp> <ol> <p>
<small> <strike> <strong>
<sub> <sup> <table>
<td> <th> <tr> <tt>
<u> <ul>
-
Snippets of code should be wrapped in
<code> tags not
<pre> tags. In fact, <pre>
tags should generally be avoided. If they must
be used, extreme care should be
taken to ensure that their contents do not
have long lines (<70 chars), in order to prevent
horizontal scrolling (and possible janitor
intervention).
-
Want more info? How to link
or How to display code and escape characters
are good places to start.
|