From d03d6e606b40157d910ddf99ab018156abeb8ef0 Mon Sep 17 00:00:00 2001
From: "berkeviktor@aol.com" <berkeviktor@aol.com>
Date: Mon, 28 Feb 2011 18:59:32 +0100
Subject: add wdk changes to named branch

---
 plugins/checksum/checksum.c            |  351 ++++++
 plugins/checksum/makefile.mak          |   18 +
 plugins/ewc/COPYING                    |  502 +++++++++
 plugins/ewc/ewc.c                      |  231 ++++
 plugins/ewc/makefile.mak               |   18 +
 plugins/lua/lua.c                      | 1882 ++++++++++++++++++++++++++++++++
 plugins/lua/makefile.mak               |   20 +
 plugins/makefile.mak                   |   66 ++
 plugins/mpcinfo/functions.c            |  167 +++
 plugins/mpcinfo/makefile.mak           |   18 +
 plugins/mpcinfo/mp3Info.c              |  361 ++++++
 plugins/mpcinfo/mpcInfo.c              |  149 +++
 plugins/mpcinfo/oggInfo.c              |  122 +++
 plugins/mpcinfo/theme.c                |  136 +++
 plugins/perl/makefile-510.mak          |   30 +
 plugins/perl/makefile-512.mak          |   30 +
 plugins/perl/perl.c                    |   11 +-
 plugins/python/makefile.mak            |   25 +
 plugins/python/python.c                |    6 +-
 plugins/tcl/makefile.mak               |   22 +
 plugins/tcl/tclplugin.c                |    4 +-
 plugins/upd/makefile.mak               |   18 +
 plugins/upd/upd.c                      |  111 ++
 plugins/winamp/makefile.mak            |   18 +
 plugins/winamp/winamp.c                |  189 ++++
 plugins/xdcc/makefile.mak              |   18 +
 plugins/xdcc/xdcc.c                    |    2 +-
 plugins/xtray/bitmaps/sd.bmp           |  Bin 0 -> 32824 bytes
 plugins/xtray/callbacks.cpp            |  734 +++++++++++++
 plugins/xtray/callbacks.h              |   37 +
 plugins/xtray/icons/banned.ico         |  Bin 0 -> 1406 bytes
 plugins/xtray/icons/chan_msg.ico       |  Bin 0 -> 1406 bytes
 plugins/xtray/icons/disconnected.ico   |  Bin 0 -> 1406 bytes
 plugins/xtray/icons/highlight-1-3.ico  |  Bin 0 -> 1406 bytes
 plugins/xtray/icons/highlight.ico      |  Bin 0 -> 1406 bytes
 plugins/xtray/icons/kicked.ico         |  Bin 0 -> 1406 bytes
 plugins/xtray/icons/priv_msg-1-2-2.ico |  Bin 0 -> 1406 bytes
 plugins/xtray/icons/sd.ico             |  Bin 0 -> 24358 bytes
 plugins/xtray/icons/server_notice.ico  |  Bin 0 -> 1406 bytes
 plugins/xtray/icons/xchat.ico          |  Bin 0 -> 25670 bytes
 plugins/xtray/makefile.mak             |   37 +
 plugins/xtray/plugin.h                 |  335 ++++++
 plugins/xtray/resource.h               |   47 +
 plugins/xtray/resource.rc              |  309 ++++++
 plugins/xtray/sdAlerts.cpp             |  109 ++
 plugins/xtray/sdAlerts.h               |   26 +
 plugins/xtray/sdTray.cpp               |  207 ++++
 plugins/xtray/sdTray.h                 |   39 +
 plugins/xtray/utility.cpp              |  563 ++++++++++
 plugins/xtray/utility.h                |   52 +
 plugins/xtray/xchat.cpp                |  319 ++++++
 plugins/xtray/xchat.h                  |   32 +
 plugins/xtray/xtray.cpp                |  219 ++++
 plugins/xtray/xtray.h                  |   77 ++
 54 files changed, 7658 insertions(+), 9 deletions(-)
 create mode 100644 plugins/checksum/checksum.c
 create mode 100644 plugins/checksum/makefile.mak
 create mode 100644 plugins/ewc/COPYING
 create mode 100644 plugins/ewc/ewc.c
 create mode 100644 plugins/ewc/makefile.mak
 create mode 100644 plugins/lua/lua.c
 create mode 100644 plugins/lua/makefile.mak
 create mode 100644 plugins/makefile.mak
 create mode 100644 plugins/mpcinfo/functions.c
 create mode 100644 plugins/mpcinfo/makefile.mak
 create mode 100644 plugins/mpcinfo/mp3Info.c
 create mode 100644 plugins/mpcinfo/mpcInfo.c
 create mode 100644 plugins/mpcinfo/oggInfo.c
 create mode 100644 plugins/mpcinfo/theme.c
 create mode 100644 plugins/perl/makefile-510.mak
 create mode 100644 plugins/perl/makefile-512.mak
 create mode 100644 plugins/python/makefile.mak
 create mode 100644 plugins/tcl/makefile.mak
 create mode 100644 plugins/upd/makefile.mak
 create mode 100644 plugins/upd/upd.c
 create mode 100644 plugins/winamp/makefile.mak
 create mode 100644 plugins/winamp/winamp.c
 create mode 100644 plugins/xdcc/makefile.mak
 create mode 100644 plugins/xtray/bitmaps/sd.bmp
 create mode 100644 plugins/xtray/callbacks.cpp
 create mode 100644 plugins/xtray/callbacks.h
 create mode 100644 plugins/xtray/icons/banned.ico
 create mode 100644 plugins/xtray/icons/chan_msg.ico
 create mode 100644 plugins/xtray/icons/disconnected.ico
 create mode 100644 plugins/xtray/icons/highlight-1-3.ico
 create mode 100644 plugins/xtray/icons/highlight.ico
 create mode 100644 plugins/xtray/icons/kicked.ico
 create mode 100644 plugins/xtray/icons/priv_msg-1-2-2.ico
 create mode 100644 plugins/xtray/icons/sd.ico
 create mode 100644 plugins/xtray/icons/server_notice.ico
 create mode 100644 plugins/xtray/icons/xchat.ico
 create mode 100644 plugins/xtray/makefile.mak
 create mode 100644 plugins/xtray/plugin.h
 create mode 100644 plugins/xtray/resource.h
 create mode 100644 plugins/xtray/resource.rc
 create mode 100644 plugins/xtray/sdAlerts.cpp
 create mode 100644 plugins/xtray/sdAlerts.h
 create mode 100644 plugins/xtray/sdTray.cpp
 create mode 100644 plugins/xtray/sdTray.h
 create mode 100644 plugins/xtray/utility.cpp
 create mode 100644 plugins/xtray/utility.h
 create mode 100644 plugins/xtray/xchat.cpp
 create mode 100644 plugins/xtray/xchat.h
 create mode 100644 plugins/xtray/xtray.cpp
 create mode 100644 plugins/xtray/xtray.h

(limited to 'plugins')

diff --git a/plugins/checksum/checksum.c b/plugins/checksum/checksum.c
new file mode 100644
index 00000000..170daa5b
--- /dev/null
+++ b/plugins/checksum/checksum.c
@@ -0,0 +1,351 @@
+/* XChat-WDK
+ * Copyright (c) 2010-2011 Berke Viktor.
+ *
+ * Use of OpenSSL SHA256 interface: http://adamlamers.com/?p=5
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ * 3. The name of the author may not be used to endorse or promote products
+ *    derived from this software without specific prior written permission.
+ * 
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+ * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#include <stdio.h>
+#include <string.h>
+#include <malloc.h>
+#include <errno.h>
+#include <sys/types.h>
+#include <sys/stat.h>
+#include <openssl/sha.h>
+
+#include "xchat-plugin.h"
+
+#define BUFSIZE 32768
+#define DEFAULT_MAX_HASH_SIZE 268435456						/* default size is 256 MB */
+#define FILE_BUF_SIZE 512
+
+#ifndef snprintf
+#define snprintf _snprintf
+#endif
+#ifndef stat64
+#define stat64 _stat64
+#endif
+
+static xchat_plugin *ph;									/* plugin handle */
+static int config_fail;										/* variable for config availability */
+
+static void
+sha256_hash_string (unsigned char hash[SHA256_DIGEST_LENGTH], char outputBuffer[65])
+{
+	int i;
+	for (i = 0; i < SHA256_DIGEST_LENGTH; i++)
+	{
+		sprintf (outputBuffer + (i * 2), "%02x", hash[i]);
+	}
+	outputBuffer[64] = 0;
+}
+
+static void
+sha256 (char *string, char outputBuffer[65])
+{
+	int i;
+	unsigned char hash[SHA256_DIGEST_LENGTH];
+	SHA256_CTX sha256;
+
+	SHA256_Init (&sha256);
+	SHA256_Update (&sha256, string, strlen (string));
+	SHA256_Final (hash, &sha256);
+
+	for (i = 0; i < SHA256_DIGEST_LENGTH; i++)
+	{
+		sprintf (outputBuffer + (i * 2), "%02x", hash[i]);
+	}
+	outputBuffer[64] = 0;
+}
+
+static int
+sha256_file (char *path, char outputBuffer[65])
+{
+	int bytesRead;
+	unsigned char *buffer;
+	unsigned char hash[SHA256_DIGEST_LENGTH];
+	SHA256_CTX sha256;
+
+	FILE *file = fopen (path, "rb");
+	if (!file)
+	{
+		return -534;
+	}
+
+	SHA256_Init (&sha256);
+	buffer = malloc (BUFSIZE);
+	bytesRead = 0;
+
+	if (!buffer)
+	{
+		return ENOMEM;
+	}
+
+	while ((bytesRead = fread (buffer, 1, BUFSIZE, file)))
+	{
+		SHA256_Update (&sha256, buffer, bytesRead);
+	}
+
+	SHA256_Final (hash, &sha256);
+	sha256_hash_string (hash, outputBuffer);
+
+	fclose (file);
+	free (buffer);
+	return 0;
+}
+
+static void
+init ()
+{
+	/* check whether the config file exists, if it doesn't, try to create it */
+	FILE * file_in;
+	FILE * file_out;
+	char buffer[FILE_BUF_SIZE];
+
+	config_fail = 0;
+	snprintf (buffer, sizeof (buffer), "%s/checksum.conf", xchat_get_info (ph, "xchatdirfs"));
+
+	if ((file_in = fopen (buffer, "r")) == NULL)
+	{
+		if ((file_out = fopen (buffer, "w")) == NULL)
+		{
+			config_fail = 1;
+		} else
+		{
+			fprintf (file_out, "%llu\n", (unsigned long long) DEFAULT_MAX_HASH_SIZE);
+			fclose (file_out);
+		}
+	} else
+	{
+		fclose (file_in);
+	}
+
+	/* nasty easter egg: if FILE_BUF_SIZE is set to 1024 and you build for x86, you can do fclose ()
+	   at the end of init (), which is plain wrong as it will only work if fopen () != 0. */
+}
+
+static unsigned long long
+get_max_hash_size ()
+{
+	FILE * file_in;
+	char buffer[FILE_BUF_SIZE];
+	unsigned long long max_hash_size;
+
+	if (config_fail)
+	{
+		return (unsigned long long) DEFAULT_MAX_HASH_SIZE;
+	} else
+	{
+		snprintf (buffer, sizeof (buffer), "%s/checksum.conf", xchat_get_info (ph, "xchatdirfs"));
+		file_in = fopen (buffer, "r");
+		fscanf (file_in, "%llu", &max_hash_size);
+
+		fclose (file_in);
+		return max_hash_size;
+	}
+}
+
+static void
+print_size ()
+{
+	unsigned long long size;
+	char suffix[3];
+	
+	size = get_max_hash_size ();
+	
+	if (size >= 1073741824)
+	{
+		size /= 1073741824;
+		snprintf (suffix, sizeof (suffix), "GB");
+	} else if (size >= 1048576)
+	{
+		size /= 1048576;
+		snprintf (suffix, sizeof (suffix), "MB");
+	} else if (size >= 1024)
+	{
+		size /= 1024;
+		snprintf (suffix, sizeof (suffix), "kB");
+	} else
+	{
+		snprintf (suffix, sizeof (suffix), "B");
+	}
+	xchat_printf (ph, "File size limit for checksums: %llu %s\n", size, suffix);
+}
+
+static void
+increase_max_hash_size ()
+{
+	unsigned long long size;
+	FILE * file_out;
+	char buffer[FILE_BUF_SIZE];
+
+	if (config_fail)
+	{
+		xchat_printf (ph, "Config file is unavailable, falling back to the default value\n");
+		print_size ();
+	} else
+	{
+		size = get_max_hash_size ();
+		if (size <= ULLONG_MAX/2)
+		{
+			size *= 2;
+		}
+		
+		snprintf (buffer, sizeof (buffer), "%s/checksum.conf", xchat_get_info (ph, "xchatdirfs"));
+		file_out = fopen (buffer, "w");
+		fprintf (file_out, "%llu\n", size);
+		fclose (file_out);
+		print_size ();
+	}
+}
+
+static void
+decrease_max_hash_size ()
+{
+	unsigned long long size;
+	FILE * file_out;
+	char buffer[FILE_BUF_SIZE];
+
+	if (config_fail)
+	{
+		xchat_printf (ph, "Config file is unavailable, falling back to the default value\n");
+		print_size ();
+	} else
+	{
+		size = get_max_hash_size ();
+		if (size >= 2)
+		{
+			size /= 2;
+		}
+		
+		snprintf (buffer, sizeof (buffer), "%s/checksum.conf", xchat_get_info (ph, "xchatdirfs"));
+		file_out = fopen (buffer, "w");
+		fprintf (file_out, "%llu\n", size);
+		fclose (file_out);
+		print_size ();
+	}
+}
+
+static int
+dccrecv_cb (char *word[], void *userdata)
+{
+	int result;
+	struct stat64 buffer;									/* buffer for storing file info */
+	char sum[65];											/* buffer for checksum */
+
+	result = stat64 (word[2], &buffer);
+	if (result == 0)										/* stat returns 0 on success */
+	{
+		if (buffer.st_size <= get_max_hash_size ())
+		{
+			sha256_file (word[2], sum);						/* word[2] is the full filename */
+			/* try to print the checksum in the privmsg tab of the sender */
+			xchat_set_context (ph, xchat_find_context (ph, NULL, word[3]));
+			xchat_printf (ph, "SHA-256 checksum for %s (local):  %s\n", word[1], sum);
+		} else
+		{
+			xchat_set_context (ph, xchat_find_context (ph, NULL, word[3]));
+			xchat_printf (ph, "SHA-256 checksum for %s (local):  (size limit reached, no checksum calculated, you can increase it with /CHECKSUM INC)\n", word[1]);
+		}
+	} else
+	{
+		xchat_printf (ph, "File access error\n");
+	}
+
+	return XCHAT_EAT_NONE;
+}
+
+static int
+dccoffer_cb (char *word[], void *userdata)
+{
+	int result;
+	struct stat64 buffer;									/* buffer for storing file info */
+	char sum[65];											/* buffer for checksum */
+
+	result = stat64 (word[3], &buffer);
+	if (result == 0)										/* stat returns 0 on success */
+	{
+		if (buffer.st_size <= get_max_hash_size ())
+		{
+			sha256_file (word[3], sum);						/* word[3] is the full filename */
+			xchat_commandf (ph, "quote PRIVMSG %s :SHA-256 checksum for %s (remote): %s", word[2], word[1], sum);
+		} else
+		{
+			xchat_set_context (ph, xchat_find_context (ph, NULL, word[3]));
+			xchat_printf (ph, "quote PRIVMSG %s :SHA-256 checksum for %s (remote): (size limit reached, no checksum calculated)", word[2], word[1]);
+		}
+	} else
+	{
+		xchat_printf (ph, "File access error\n");
+	}
+
+	return XCHAT_EAT_NONE;
+}
+
+static void
+checksum (char *word[], void *userdata)
+{
+	if (!stricmp ("GET", word[2]))
+	{
+		print_size ();
+	} else if (!stricmp ("INC", word[2]))
+	{
+		increase_max_hash_size ();
+	} else if (!stricmp ("DEC", word[2]))
+	{
+		decrease_max_hash_size ();
+	} else
+	{
+		xchat_printf (ph, "Usage: /CHECKSUM GET|INC|DEC\n");
+		xchat_printf (ph, "  GET - print the maximum file size to be hashed\n");
+		xchat_printf (ph, "  INC - double the maximum file size to be hashed\n");
+		xchat_printf (ph, "  DEC - halve the maximum file size to be hashed\n");
+	}
+}
+
+int
+xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugin_desc, char **plugin_version, char *arg)
+{
+	ph = plugin_handle;
+
+	*plugin_name = "Checksum";
+	*plugin_desc = "Calculate checksum for DCC file transfers";
+	*plugin_version = "2.0";
+
+	init ();
+
+	xchat_hook_command (ph, "CHECKSUM", XCHAT_PRI_NORM, checksum, "Usage: /CHECKSUM GET|INC|DEC", 0);
+	xchat_hook_print (ph, "DCC RECV Complete", XCHAT_PRI_NORM, dccrecv_cb, NULL);
+	xchat_hook_print (ph, "DCC Offer", XCHAT_PRI_NORM, dccoffer_cb, NULL);
+
+	xchat_print (ph, "Checksum plugin loaded\n");
+	return 1;
+}
+
+int
+xchat_plugin_deinit (void)
+{
+	xchat_print (ph, "Checksum plugin unloaded\n");
+	return 1;
+}
diff --git a/plugins/checksum/makefile.mak b/plugins/checksum/makefile.mak
new file mode 100644
index 00000000..ec8e0455
--- /dev/null
+++ b/plugins/checksum/makefile.mak
@@ -0,0 +1,18 @@
+include "..\..\src\makeinc.mak"
+
+all: checksum.obj checksum.def
+	link $(LDFLAGS) $(LIBS) /dll /out:xcchecksum.dll /def:checksum.def checksum.obj 
+
+checksum.def:
+	echo EXPORTS > checksum.def
+	echo xchat_plugin_init >> checksum.def
+	echo xchat_plugin_deinit >> checksum.def
+
+checksum.obj: checksum.c makefile.mak
+	cl $(CFLAGS) /I.. checksum.c
+
+clean:
+	del *.obj
+	del *.dll
+	del *.exp
+	del *.lib
diff --git a/plugins/ewc/COPYING b/plugins/ewc/COPYING
new file mode 100644
index 00000000..4362b491
--- /dev/null
+++ b/plugins/ewc/COPYING
@@ -0,0 +1,502 @@
+                  GNU LESSER GENERAL PUBLIC LICENSE
+                       Version 2.1, February 1999
+
+ Copyright (C) 1991, 1999 Free Software Foundation, Inc.
+ 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
+ Everyone is permitted to copy and distribute verbatim copies
+ of this license document, but changing it is not allowed.
+
+[This is the first released version of the Lesser GPL.  It also counts
+ as the successor of the GNU Library Public License, version 2, hence
+ the version number 2.1.]
+
+                            Preamble
+
+  The licenses for most software are designed to take away your
+freedom to share and change it.  By contrast, the GNU General Public
+Licenses are intended to guarantee your freedom to share and change
+free software--to make sure the software is free for all its users.
+
+  This license, the Lesser General Public License, applies to some
+specially designated software packages--typically libraries--of the
+Free Software Foundation and other authors who decide to use it.  You
+can use it too, but we suggest you first think carefully about whether
+this license or the ordinary General Public License is the better
+strategy to use in any particular case, based on the explanations below.
+
+  When we speak of free software, we are referring to freedom of use,
+not price.  Our General Public Licenses are designed to make sure that
+you have the freedom to distribute copies of free software (and charge
+for this service if you wish); that you receive source code or can get
+it if you want it; that you can change the software and use pieces of
+it in new free programs; and that you are informed that you can do
+these things.
+
+  To protect your rights, we need to make restrictions that forbid
+distributors to deny you these rights or to ask you to surrender these
+rights.  These restrictions translate to certain responsibilities for
+you if you distribute copies of the library or if you modify it.
+
+  For example, if you distribute copies of the library, whether gratis
+or for a fee, you must give the recipients all the rights that we gave
+you.  You must make sure that they, too, receive or can get the source
+code.  If you link other code with the library, you must provide
+complete object files to the recipients, so that they can relink them
+with the library after making changes to the library and recompiling
+it.  And you must show them these terms so they know their rights.
+
+  We protect your rights with a two-step method: (1) we copyright the
+library, and (2) we offer you this license, which gives you legal
+permission to copy, distribute and/or modify the library.
+
+  To protect each distributor, we want to make it very clear that
+there is no warranty for the free library.  Also, if the library is
+modified by someone else and passed on, the recipients should know
+that what they have is not the original version, so that the original
+author's reputation will not be affected by problems that might be
+introduced by others.
+
+  Finally, software patents pose a constant threat to the existence of
+any free program.  We wish to make sure that a company cannot
+effectively restrict the users of a free program by obtaining a
+restrictive license from a patent holder.  Therefore, we insist that
+any patent license obtained for a version of the library must be
+consistent with the full freedom of use specified in this license.
+
+  Most GNU software, including some libraries, is covered by the
+ordinary GNU General Public License.  This license, the GNU Lesser
+General Public License, applies to certain designated libraries, and
+is quite different from the ordinary General Public License.  We use
+this license for certain libraries in order to permit linking those
+libraries into non-free programs.
+
+  When a program is linked with a library, whether statically or using
+a shared library, the combination of the two is legally speaking a
+combined work, a derivative of the original library.  The ordinary
+General Public License therefore permits such linking only if the
+entire combination fits its criteria of freedom.  The Lesser General
+Public License permits more lax criteria for linking other code with
+the library.
+
+  We call this license the "Lesser" General Public License because it
+does Less to protect the user's freedom than the ordinary General
+Public License.  It also provides other free software developers Less
+of an advantage over competing non-free programs.  These disadvantages
+are the reason we use the ordinary General Public License for many
+libraries.  However, the Lesser license provides advantages in certain
+special circumstances.
+
+  For example, on rare occasions, there may be a special need to
+encourage the widest possible use of a certain library, so that it becomes
+a de-facto standard.  To achieve this, non-free programs must be
+allowed to use the library.  A more frequent case is that a free
+library does the same job as widely used non-free libraries.  In this
+case, there is little to gain by limiting the free library to free
+software only, so we use the Lesser General Public License.
+
+  In other cases, permission to use a particular library in non-free
+programs enables a greater number of people to use a large body of
+free software.  For example, permission to use the GNU C Library in
+non-free programs enables many more people to use the whole GNU
+operating system, as well as its variant, the GNU/Linux operating
+system.
+
+  Although the Lesser General Public License is Less protective of the
+users' freedom, it does ensure that the user of a program that is
+linked with the Library has the freedom and the wherewithal to run
+that program using a modified version of the Library.
+
+  The precise terms and conditions for copying, distribution and
+modification follow.  Pay close attention to the difference between a
+"work based on the library" and a "work that uses the library".  The
+former contains code derived from the library, whereas the latter must
+be combined with the library in order to run.
+
+                  GNU LESSER GENERAL PUBLIC LICENSE
+   TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
+
+  0. This License Agreement applies to any software library or other
+program which contains a notice placed by the copyright holder or
+other authorized party saying it may be distributed under the terms of
+this Lesser General Public License (also called "this License").
+Each licensee is addressed as "you".
+
+  A "library" means a collection of software functions and/or data
+prepared so as to be conveniently linked with application programs
+(which use some of those functions and data) to form executables.
+
+  The "Library", below, refers to any such software library or work
+which has been distributed under these terms.  A "work based on the
+Library" means either the Library or any derivative work under
+copyright law: that is to say, a work containing the Library or a
+portion of it, either verbatim or with modifications and/or translated
+straightforwardly into another language.  (Hereinafter, translation is
+included without limitation in the term "modification".)
+
+  "Source code" for a work means the preferred form of the work for
+making modifications to it.  For a library, complete source code means
+all the source code for all modules it contains, plus any associated
+interface definition files, plus the scripts used to control compilation
+and installation of the library.
+
+  Activities other than copying, distribution and modification are not
+covered by this License; they are outside its scope.  The act of
+running a program using the Library is not restricted, and output from
+such a program is covered only if its contents constitute a work based
+on the Library (independent of the use of the Library in a tool for
+writing it).  Whether that is true depends on what the Library does
+and what the program that uses the Library does.
+
+  1. You may copy and distribute verbatim copies of the Library's
+complete source code as you receive it, in any medium, provided that
+you conspicuously and appropriately publish on each copy an
+appropriate copyright notice and disclaimer of warranty; keep intact
+all the notices that refer to this License and to the absence of any
+warranty; and distribute a copy of this License along with the
+Library.
+
+  You may charge a fee for the physical act of transferring a copy,
+and you may at your option offer warranty protection in exchange for a
+fee.
+
+  2. You may modify your copy or copies of the Library or any portion
+of it, thus forming a work based on the Library, and copy and
+distribute such modifications or work under the terms of Section 1
+above, provided that you also meet all of these conditions:
+
+    a) The modified work must itself be a software library.
+
+    b) You must cause the files modified to carry prominent notices
+    stating that you changed the files and the date of any change.
+
+    c) You must cause the whole of the work to be licensed at no
+    charge to all third parties under the terms of this License.
+
+    d) If a facility in the modified Library refers to a function or a
+    table of data to be supplied by an application program that uses
+    the facility, other than as an argument passed when the facility
+    is invoked, then you must make a good faith effort to ensure that,
+    in the event an application does not supply such function or
+    table, the facility still operates, and performs whatever part of
+    its purpose remains meaningful.
+
+    (For example, a function in a library to compute square roots has
+    a purpose that is entirely well-defined independent of the
+    application.  Therefore, Subsection 2d requires that any
+    application-supplied function or table used by this function must
+    be optional: if the application does not supply it, the square
+    root function must still compute square roots.)
+
+These requirements apply to the modified work as a whole.  If
+identifiable sections of that work are not derived from the Library,
+and can be reasonably considered independent and separate works in
+themselves, then this License, and its terms, do not apply to those
+sections when you distribute them as separate works.  But when you
+distribute the same sections as part of a whole which is a work based
+on the Library, the distribution of the whole must be on the terms of
+this License, whose permissions for other licensees extend to the
+entire whole, and thus to each and every part regardless of who wrote
+it.
+
+Thus, it is not the intent of this section to claim rights or contest
+your rights to work written entirely by you; rather, the intent is to
+exercise the right to control the distribution of derivative or
+collective works based on the Library.
+
+In addition, mere aggregation of another work not based on the Library
+with the Library (or with a work based on the Library) on a volume of
+a storage or distribution medium does not bring the other work under
+the scope of this License.
+
+  3. You may opt to apply the terms of the ordinary GNU General Public
+License instead of this License to a given copy of the Library.  To do
+this, you must alter all the notices that refer to this License, so
+that they refer to the ordinary GNU General Public License, version 2,
+instead of to this License.  (If a newer version than version 2 of the
+ordinary GNU General Public License has appeared, then you can specify
+that version instead if you wish.)  Do not make any other change in
+these notices.
+
+  Once this change is made in a given copy, it is irreversible for
+that copy, so the ordinary GNU General Public License applies to all
+subsequent copies and derivative works made from that copy.
+
+  This option is useful when you wish to copy part of the code of
+the Library into a program that is not a library.
+
+  4. You may copy and distribute the Library (or a portion or
+derivative of it, under Section 2) in object code or executable form
+under the terms of Sections 1 and 2 above provided that you accompany
+it with the complete corresponding machine-readable source code, which
+must be distributed under the terms of Sections 1 and 2 above on a
+medium customarily used for software interchange.
+
+  If distribution of object code is made by offering access to copy
+from a designated place, then offering equivalent access to copy the
+source code from the same place satisfies the requirement to
+distribute the source code, even though third parties are not
+compelled to copy the source along with the object code.
+
+  5. A program that contains no derivative of any portion of the
+Library, but is designed to work with the Library by being compiled or
+linked with it, is called a "work that uses the Library".  Such a
+work, in isolation, is not a derivative work of the Library, and
+therefore falls outside the scope of this License.
+
+  However, linking a "work that uses the Library" with the Library
+creates an executable that is a derivative of the Library (because it
+contains portions of the Library), rather than a "work that uses the
+library".  The executable is therefore covered by this License.
+Section 6 states terms for distribution of such executables.
+
+  When a "work that uses the Library" uses material from a header file
+that is part of the Library, the object code for the work may be a
+derivative work of the Library even though the source code is not.
+Whether this is true is especially significant if the work can be
+linked without the Library, or if the work is itself a library.  The
+threshold for this to be true is not precisely defined by law.
+
+  If such an object file uses only numerical parameters, data
+structure layouts and accessors, and small macros and small inline
+functions (ten lines or less in length), then the use of the object
+file is unrestricted, regardless of whether it is legally a derivative
+work.  (Executables containing this object code plus portions of the
+Library will still fall under Section 6.)
+
+  Otherwise, if the work is a derivative of the Library, you may
+distribute the object code for the work under the terms of Section 6.
+Any executables containing that work also fall under Section 6,
+whether or not they are linked directly with the Library itself.
+
+  6. As an exception to the Sections above, you may also combine or
+link a "work that uses the Library" with the Library to produce a
+work containing portions of the Library, and distribute that work
+under terms of your choice, provided that the terms permit
+modification of the work for the customer's own use and reverse
+engineering for debugging such modifications.
+
+  You must give prominent notice with each copy of the work that the
+Library is used in it and that the Library and its use are covered by
+this License.  You must supply a copy of this License.  If the work
+during execution displays copyright notices, you must include the
+copyright notice for the Library among them, as well as a reference
+directing the user to the copy of this License.  Also, you must do one
+of these things:
+
+    a) Accompany the work with the complete corresponding
+    machine-readable source code for the Library including whatever
+    changes were used in the work (which must be distributed under
+    Sections 1 and 2 above); and, if the work is an executable linked
+    with the Library, with the complete machine-readable "work that
+    uses the Library", as object code and/or source code, so that the
+    user can modify the Library and then relink to produce a modified
+    executable containing the modified Library.  (It is understood
+    that the user who changes the contents of definitions files in the
+    Library will not necessarily be able to recompile the application
+    to use the modified definitions.)
+
+    b) Use a suitable shared library mechanism for linking with the
+    Library.  A suitable mechanism is one that (1) uses at run time a
+    copy of the library already present on the user's computer system,
+    rather than copying library functions into the executable, and (2)
+    will operate properly with a modified version of the library, if
+    the user installs one, as long as the modified version is
+    interface-compatible with the version that the work was made with.
+
+    c) Accompany the work with a written offer, valid for at
+    least three years, to give the same user the materials
+    specified in Subsection 6a, above, for a charge no more
+    than the cost of performing this distribution.
+
+    d) If distribution of the work is made by offering access to copy
+    from a designated place, offer equivalent access to copy the above
+    specified materials from the same place.
+
+    e) Verify that the user has already received a copy of these
+    materials or that you have already sent this user a copy.
+
+  For an executable, the required form of the "work that uses the
+Library" must include any data and utility programs needed for
+reproducing the executable from it.  However, as a special exception,
+the materials to be distributed need not include anything that is
+normally distributed (in either source or binary form) with the major
+components (compiler, kernel, and so on) of the operating system on
+which the executable runs, unless that component itself accompanies
+the executable.
+
+  It may happen that this requirement contradicts the license
+restrictions of other proprietary libraries that do not normally
+accompany the operating system.  Such a contradiction means you cannot
+use both them and the Library together in an executable that you
+distribute.
+
+  7. You may place library facilities that are a work based on the
+Library side-by-side in a single library together with other library
+facilities not covered by this License, and distribute such a combined
+library, provided that the separate distribution of the work based on
+the Library and of the other library facilities is otherwise
+permitted, and provided that you do these two things:
+
+    a) Accompany the combined library with a copy of the same work
+    based on the Library, uncombined with any other library
+    facilities.  This must be distributed under the terms of the
+    Sections above.
+
+    b) Give prominent notice with the combined library of the fact
+    that part of it is a work based on the Library, and explaining
+    where to find the accompanying uncombined form of the same work.
+
+  8. You may not copy, modify, sublicense, link with, or distribute
+the Library except as expressly provided under this License.  Any
+attempt otherwise to copy, modify, sublicense, link with, or
+distribute the Library is void, and will automatically terminate your
+rights under this License.  However, parties who have received copies,
+or rights, from you under this License will not have their licenses
+terminated so long as such parties remain in full compliance.
+
+  9. You are not required to accept this License, since you have not
+signed it.  However, nothing else grants you permission to modify or
+distribute the Library or its derivative works.  These actions are
+prohibited by law if you do not accept this License.  Therefore, by
+modifying or distributing the Library (or any work based on the
+Library), you indicate your acceptance of this License to do so, and
+all its terms and conditions for copying, distributing or modifying
+the Library or works based on it.
+
+  10. Each time you redistribute the Library (or any work based on the
+Library), the recipient automatically receives a license from the
+original licensor to copy, distribute, link with or modify the Library
+subject to these terms and conditions.  You may not impose any further
+restrictions on the recipients' exercise of the rights granted herein.
+You are not responsible for enforcing compliance by third parties with
+this License.
+
+  11. If, as a consequence of a court judgment or allegation of patent
+infringement or for any other reason (not limited to patent issues),
+conditions are imposed on you (whether by court order, agreement or
+otherwise) that contradict the conditions of this License, they do not
+excuse you from the conditions of this License.  If you cannot
+distribute so as to satisfy simultaneously your obligations under this
+License and any other pertinent obligations, then as a consequence you
+may not distribute the Library at all.  For example, if a patent
+license would not permit royalty-free redistribution of the Library by
+all those who receive copies directly or indirectly through you, then
+the only way you could satisfy both it and this License would be to
+refrain entirely from distribution of the Library.
+
+If any portion of this section is held invalid or unenforceable under any
+particular circumstance, the balance of the section is intended to apply,
+and the section as a whole is intended to apply in other circumstances.
+
+It is not the purpose of this section to induce you to infringe any
+patents or other property right claims or to contest validity of any
+such claims; this section has the sole purpose of protecting the
+integrity of the free software distribution system which is
+implemented by public license practices.  Many people have made
+generous contributions to the wide range of software distributed
+through that system in reliance on consistent application of that
+system; it is up to the author/donor to decide if he or she is willing
+to distribute software through any other system and a licensee cannot
+impose that choice.
+
+This section is intended to make thoroughly clear what is believed to
+be a consequence of the rest of this License.
+
+  12. If the distribution and/or use of the Library is restricted in
+certain countries either by patents or by copyrighted interfaces, the
+original copyright holder who places the Library under this License may add
+an explicit geographical distribution limitation excluding those countries,
+so that distribution is permitted only in or among countries not thus
+excluded.  In such case, this License incorporates the limitation as if
+written in the body of this License.
+
+  13. The Free Software Foundation may publish revised and/or new
+versions of the Lesser General Public License from time to time.
+Such new versions will be similar in spirit to the present version,
+but may differ in detail to address new problems or concerns.
+
+Each version is given a distinguishing version number.  If the Library
+specifies a version number of this License which applies to it and
+"any later version", you have the option of following the terms and
+conditions either of that version or of any later version published by
+the Free Software Foundation.  If the Library does not specify a
+license version number, you may choose any version ever published by
+the Free Software Foundation.
+
+  14. If you wish to incorporate parts of the Library into other free
+programs whose distribution conditions are incompatible with these,
+write to the author to ask for permission.  For software which is
+copyrighted by the Free Software Foundation, write to the Free
+Software Foundation; we sometimes make exceptions for this.  Our
+decision will be guided by the two goals of preserving the free status
+of all derivatives of our free software and of promoting the sharing
+and reuse of software generally.
+
+                            NO WARRANTY
+
+  15. BECAUSE THE LIBRARY IS LICENSED FREE OF CHARGE, THERE IS NO
+WARRANTY FOR THE LIBRARY, TO THE EXTENT PERMITTED BY APPLICABLE LAW.
+EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR
+OTHER PARTIES PROVIDE THE LIBRARY "AS IS" WITHOUT WARRANTY OF ANY
+KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE
+IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
+PURPOSE.  THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE
+LIBRARY IS WITH YOU.  SHOULD THE LIBRARY PROVE DEFECTIVE, YOU ASSUME
+THE COST OF ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
+
+  16. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN
+WRITING WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY
+AND/OR REDISTRIBUTE THE LIBRARY AS PERMITTED ABOVE, BE LIABLE TO YOU
+FOR DAMAGES, INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR
+CONSEQUENTIAL DAMAGES ARISING OUT OF THE USE OR INABILITY TO USE THE
+LIBRARY (INCLUDING BUT NOT LIMITED TO LOSS OF DATA OR DATA BEING
+RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD PARTIES OR A
+FAILURE OF THE LIBRARY TO OPERATE WITH ANY OTHER SOFTWARE), EVEN IF
+SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF SUCH
+DAMAGES.
+
+                     END OF TERMS AND CONDITIONS
+
+           How to Apply These Terms to Your New Libraries
+
+  If you develop a new library, and you want it to be of the greatest
+possible use to the public, we recommend making it free software that
+everyone can redistribute and change.  You can do so by permitting
+redistribution under these terms (or, alternatively, under the terms of the
+ordinary General Public License).
+
+  To apply these terms, attach the following notices to the library.  It is
+safest to attach them to the start of each source file to most effectively
+convey the exclusion of warranty; and each file should have at least the
+"copyright" line and a pointer to where the full notice is found.
+
+    <one line to give the library's name and a brief idea of what it does.>
+    Copyright (C) <year>  <name of author>
+
+    This library is free software; you can redistribute it and/or
+    modify it under the terms of the GNU Lesser General Public
+    License as published by the Free Software Foundation; either
+    version 2.1 of the License, or (at your option) any later version.
+
+    This library is distributed in the hope that it will be useful,
+    but WITHOUT ANY WARRANTY; without even the implied warranty of
+    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+    Lesser General Public License for more details.
+
+    You should have received a copy of the GNU Lesser General Public
+    License along with this library; if not, write to the Free Software
+    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
+
+Also add information on how to contact you by electronic and paper mail.
+
+You should also get your employer (if you work as a programmer) or your
+school, if any, to sign a "copyright disclaimer" for the library, if
+necessary.  Here is a sample; alter the names:
+
+  Yoyodyne, Inc., hereby disclaims all copyright interest in the
+  library `Frob' (a library for tweaking knobs) written by James Random Hacker.
+
+  <signature of Ty Coon>, 1 April 1990
+  Ty Coon, President of Vice
+
+That's all there is to it!
diff --git a/plugins/ewc/ewc.c b/plugins/ewc/ewc.c
new file mode 100644
index 00000000..78e7e9ac
--- /dev/null
+++ b/plugins/ewc/ewc.c
@@ -0,0 +1,231 @@
+/*
+EasyWinampControl - A Winamp "What's playing" plugin for Xchat
+Copyright (C) Yann HAMON & contributors
+
+This library is free software; you can redistribute it and/or
+modify it under the terms of the GNU Lesser General Public
+License as published by the Free Software Foundation; either
+version 2.1 of the License, or (at your option) any later version.
+
+This library is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+Lesser General Public License for more details.
+
+You should have received a copy of the GNU Lesser General Public
+License along with this library; if not, write to the Free Software
+Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+*/
+
+#include "xchat-plugin.h"
+#include <windows.h>
+
+static xchat_plugin *ph;   /* plugin handle */
+static int enable = 1;
+
+// For example, circularstrstr("winamp", "pwi", 3) would return 5 (the index of p)
+int circularstrstr(char* a, char* b, int nb)
+{
+  int equal = 1;
+  int length;
+  int pos=-1;
+  int i, j;
+
+  length = strlen(a);
+
+  for (i=0; i<length && pos == -1; ++i) {
+    equal = 1;
+    for (j=0; j<nb;j++) {
+      if (a[(i+j)%length] != b[j])
+        equal = 0;
+    }
+    if (equal == 1)
+      pos = i;
+  }
+
+  return pos;
+}
+
+void GetCurrentSongsName(HWND hwndWinamp, char* title, int titlesize)
+{
+  int pos;
+  char *title2;
+  int i, j=0;
+  int length;
+  char *p;
+
+  GetWindowText(hwndWinamp, title, titlesize);
+  length = strlen(title);
+
+  if ((pos = circularstrstr(title, "- Winamp ***", 12)) != -1) {
+    // The option "scroll song title in taskbar" is on
+    title2 = (char*) malloc (titlesize*sizeof(char));
+
+    for (i=(pos+12)%length; i!=pos; i=(i+1)%length)
+      title2[j++] = title[i];
+
+    title2[j] = '\0';
+
+    p = title2;
+    while (p<title2+titlesize && *p != '.')
+      p++;
+    p+=2; // Delete the . and the following white space
+
+    strcpy(title, p);
+    free(title2);
+  }
+  else {
+    p = title;
+    while (p<title+titlesize && *p != '.')
+      p++;
+    p+=2; // Delete the . and the following white space
+    if (p<title+titlesize)
+      strncpy(title, p, titlesize-(p-title));
+
+    // Delete the trailing "- winamp"
+    p = title + titlesize - 1;
+    while (p>title && *p != '-') p--;
+    *p = '\0';
+  }
+}
+
+
+// Controlling winamp
+static int wcmd_cb(char *word[], char *word_eol[], void *userdata)
+{
+  // Everything's here : http://winamp.com/nsdn/winamp2x/dev/sdk/api.php
+  // The previous url seems dead, see http://forums.winamp.com/showthread.php?threadid=180297
+  HWND hwndWinamp = NULL;
+
+  if ((hwndWinamp = FindWindow("Winamp v1.x",NULL)) == NULL) {
+    xchat_print(ph, "Winamp's window not found - Is winamp really running?\n");
+  }
+  else {
+    if (strcmp(word[1], "") == 0)
+      xchat_print(ph, "Usage: wcmd [command]\n");
+    else if (strcmp(word[2], "next") == 0) {
+      xchat_print(ph, "Loading next song...\n");
+      SendMessage (hwndWinamp, WM_COMMAND, 40048, 0);
+    }
+    else if (strcmp(word[2], "prev") == 0) {
+      xchat_print(ph, "Loading previous song...\n");
+      SendMessage (hwndWinamp, WM_COMMAND, 40044, 0);
+    }
+    else if (strcmp(word[2], "play") == 0) {
+      xchat_print(ph, "Playin'...\n");
+      SendMessage (hwndWinamp, WM_COMMAND, 40045, 0);
+    }
+    else if (strcmp(word[2], "stop") == 0) {
+      xchat_print(ph, "Winamp stopped!...\n");
+      SendMessage (hwndWinamp, WM_COMMAND, 40047, 0);
+    }
+    else if (strcmp(word[2], "pause") == 0) {
+      SendMessage (hwndWinamp, WM_COMMAND, 40046, 0);
+    }
+  }
+
+  return XCHAT_EAT_ALL;
+}
+
+
+// Display current song
+static int wp_cb(char *word[], char *word_eol[], void *userdata)
+{
+  HWND hwndWinamp = NULL;
+  int bitrate, length, elapsed, minutes, seconds, eminutes, eseconds, samplerate, nbchannels;
+  char elapsedtime[7];
+  char totaltime[7];
+  char this_title[1024];
+
+  if ((hwndWinamp = FindWindow("Winamp v1.x",NULL)) == NULL)
+    xchat_print(ph, "Winamp's window not found - Is winamp really running?\n");
+  else {
+    //Winamp's running
+    // Seems buggy when winamp2's agent is running, and winamp not (or winamp3) -> crashes xchat.
+    SendMessage(hwndWinamp, WM_USER, (WPARAM)0, (LPARAM)125);
+
+    if ((samplerate = SendMessage(hwndWinamp, WM_USER, (WPARAM)0, (LPARAM)126)) == 0) {
+      xchat_print(ph, "Could not get current song's samplerate... !?\n");
+      return XCHAT_EAT_ALL;
+    }
+    if ((bitrate = SendMessage(hwndWinamp, WM_USER, (WPARAM)1, (LPARAM)126)) == 0) {
+      xchat_print(ph, "Could not get current song's bitrate... !?\n");
+      return XCHAT_EAT_ALL;
+    }
+    if ((nbchannels = SendMessage(hwndWinamp, WM_USER, (WPARAM)2, (LPARAM)126)) == 0) {
+      xchat_print(ph, "Could not get the number of channels... !?\n");
+      return XCHAT_EAT_ALL;
+    }
+    if ((length = SendMessage(hwndWinamp, WM_USER, (WPARAM)1, (LPARAM)105)) == 0) {
+      // Could be buggy when streaming audio or video, returned length is unexpected;
+      // How to detect is Winamp is streaming, and display ??:?? in that case?
+      xchat_print(ph, "Could not get current song's length... !?\n");
+      return XCHAT_EAT_ALL;
+    }
+    else {
+      minutes = length/60;
+      seconds = length%60;
+
+      if (seconds>9)
+        wsprintf(totaltime, "%d:%d", minutes, seconds);
+      else
+        wsprintf(totaltime, "%d:0%d", minutes, seconds);
+    }
+    if ((elapsed = SendMessage(hwndWinamp, WM_USER, (WPARAM)0, (LPARAM)105)) == 0) {
+      xchat_print(ph, "Could not get current song's elapsed time... !?\n");
+      return XCHAT_EAT_ALL;
+    }
+    else {
+      eminutes = (elapsed/1000)/60;   /* kinda stupid sounding, but e is for elapsed */
+      eseconds = (elapsed/1000)%60;
+
+      if (eseconds>9)
+        wsprintf(elapsedtime, "%d:%d", eminutes, eseconds);
+      else
+        wsprintf(elapsedtime, "%d:0%d", eminutes, eseconds);
+    }
+
+    if ((bitrate = SendMessage(hwndWinamp, WM_USER, (WPARAM)1, (LPARAM)126)) == 0) {
+      xchat_print(ph, "Could not get current song's bitrate... !?\n");
+      return XCHAT_EAT_ALL;
+    }
+
+    GetCurrentSongsName(hwndWinamp, this_title, 1024);
+
+    xchat_commandf(ph, "dispcurrsong %d %d %d %s %s %s", samplerate, bitrate, nbchannels, elapsedtime, totaltime, this_title);
+  }
+
+  return XCHAT_EAT_ALL;   /* eat this command so xchat and other plugins can't process it */
+}
+
+
+
+int xchat_plugin_init(xchat_plugin *plugin_handle,
+                      char **plugin_name,
+                      char **plugin_desc,
+                      char **plugin_version,
+                      char *arg)
+{
+  /* we need to save this for use with any xchat_* functions */
+  ph = plugin_handle;
+
+  *plugin_name = "EasyWinampControl";
+  *plugin_desc = "Some commands to remotely control winamp";
+  *plugin_version = "1.2";
+
+  xchat_hook_command(ph, "wp", XCHAT_PRI_NORM, wp_cb,
+                    "Usage: wp", 0);
+
+  xchat_hook_command(ph, "wcmd", XCHAT_PRI_NORM, wcmd_cb,
+                    "Usage: wcmd [play|pause|stop|prev|next]", 0);
+
+  xchat_print(ph, "EasyWinampControl plugin loaded\n");
+
+  return 1;       /* return 1 for success */
+}
+
+int xchat_plugin_deinit(void)
+{
+  xchat_print(ph, "EasyWinampControl plugin unloaded\n");
+  return 1;
+}
diff --git a/plugins/ewc/makefile.mak b/plugins/ewc/makefile.mak
new file mode 100644
index 00000000..9b9f21c1
--- /dev/null
+++ b/plugins/ewc/makefile.mak
@@ -0,0 +1,18 @@
+include "..\..\src\makeinc.mak"
+
+all: ewc.obj ewc.def
+	link $(LDFLAGS) $(LIBS) /dll /out:xcewc.dll /def:ewc.def ewc.obj
+
+ewc.def:
+	echo EXPORTS > ewc.def
+	echo xchat_plugin_init >> ewc.def
+	echo xchat_plugin_deinit >> ewc.def
+
+ewc.obj: ewc.c makefile.mak
+	cl $(CFLAGS) ewc.c
+
+clean:
+	del *.obj
+	del *.dll
+	del *.exp
+	del *.lib
diff --git a/plugins/lua/lua.c b/plugins/lua/lua.c
new file mode 100644
index 00000000..9574fd4d
--- /dev/null
+++ b/plugins/lua/lua.c
@@ -0,0 +1,1882 @@
+/* 
+ * X-Chat 2.0 LUA Plugin
+ *
+ * Copyright (c) 2007 Hanno Hecker
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; version 2 of the License.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
+ */
+/*
+ *	$Id: lua.c 91 2007-06-09 18:44:03Z vetinari $
+ *	$Revision: 91 $
+ *	$Date: 2007-06-09 20:44:03 +0200 (Szo, 09 jún. 2007) $
+ */
+/* 
+ * TODO:
+ *   * compile (was OK)/run on IRIX
+ *   ? localize error msgs? ... maybe later
+ *   ? make xchat.print() like print() which does an tostring() on 
+ *     everything it gets?
+ *   ? add /LUA -s <code>? ... add a new script from cmdline... this state
+ *        is not removed after the pcall(), but prints a name, which may
+ *        be used to unload this virtual script. ... no xchat_register(),
+ *        xchat_init() should be needed
+ *        ... don't disable xchat.hook_* for this
+ *   ? timer name per state/script and not per plugin?
+ */
+#define LXC_NAME "Lua"
+#define LXC_DESC "Lua scripting interface"
+#define LXC_VERSION "0.7 (r91)"
+
+#include <stdlib.h>
+#include <stdio.h>
+#include <string.h>
+#include <sys/types.h>
+#include <sys/stat.h>
+#include <fcntl.h>
+#include "../../src/common/dirent.h"
+#include <errno.h>
+#include <ctype.h>
+
+#ifdef _WIN32
+#include <direct.h>	/* for getcwd */
+#endif
+
+#if !( defined(_WIN32) || defined(LXC_XCHAT_GETTEXT) )
+#  include <libintl.h>
+#endif
+
+#ifndef PATH_MAX /* hurd */
+# define PATH_MAX 1024 
+#endif
+
+#include <lua.h>
+#include <lauxlib.h>
+#include <lualib.h>
+
+#define lua_pop(L,n)  lua_settop(L, -(n)-1)
+
+#include "xchat-plugin.h"
+
+static xchat_plugin *ph; /* plugin handle */
+
+#define LXC_STRIP_COLOR 1
+#define LXC_STRIP_ATTR  2
+#define LXC_STRIP_ALL   (LXC_STRIP_COLOR|LXC_STRIP_ATTR)
+
+/* registered hooks */
+struct lxc_hooks {
+	const char *name;
+	xchat_hook *hook;
+	struct lxc_hooks *next;
+};
+
+/* single linked list of all lua states^Wscripts ;-)  */
+struct lxc_States {
+	lua_State *state;          /* the lua state of the script  */
+	char file[PATH_MAX+1];     /* the file name of the script  */
+	struct lxc_hooks *hooks;   /* all hooks this script registered */
+	void *gui;				/* the gui entry in windows->plugins and scripts... */
+	struct lxc_States *next;
+};
+
+static struct lxc_States *lxc_states = NULL;
+
+/* user/script supplied data for a callback */
+struct lxc_userdata {
+	int idx;					/* table index */
+	int type;				/* lua type:                          */	
+	const char *string;  /* only strings, ...                  */
+	double num;          /* numbers and booleans are supported */
+	struct lxc_userdata *next;	
+};
+
+/* callback data */
+struct lxc_cbdata {
+	lua_State *state;
+	const char *func;
+	xchat_hook *hook; /* timer ... */
+	struct lxc_userdata *data;
+};
+
+static char lxc_event_name[1024] = "\0";
+
+static int lxc_run_hook(char *word[], char *word_eol[], void *data);
+static int lxc_run_print(char *word[], void *data);
+static int lxc_run_timer(void *data);
+
+static int lxc_hook_command(lua_State *L);
+static int lxc_hook_server(lua_State *L);
+static int lxc_hook_print(lua_State *L);
+static int lxc_event(lua_State *L);
+static int lxc_hook_timer(lua_State *L);
+static int lxc_unhook(lua_State *L);
+
+static int lxc_command(lua_State *L);
+static int lxc_print(lua_State *L);
+static int lxc_emit_print(lua_State *L);
+static int lxc_send_modes(lua_State *L);
+static int lxc_find_context(lua_State *L);
+static int lxc_get_context(lua_State *L);
+static int lxc_get_info(lua_State *L);
+static int lxc_get_prefs(lua_State *L);
+static int lxc_set_context(lua_State *L);
+static int lxc_nickcmp(lua_State *L);
+
+static int lxc_list_get(lua_State *L);
+static int lxc_list_fields(lua_State *L);
+static int lxc_gettext(lua_State *L);
+
+static int lxc_bits(lua_State *L);
+
+static luaL_reg lxc_functions[] = {
+	{"hook_command",		lxc_hook_command },
+/* TODO:
+	{"hook_fd",				lxc_hook_fd      },
+*/
+	{"hook_print",			lxc_hook_print   },
+	{"hook_server",		lxc_hook_server  },
+	{"hook_timer",			lxc_hook_timer  },
+	{"unhook",				lxc_unhook  },
+
+	{"event",				lxc_event   },
+
+	{"command",				lxc_command  	  },
+	{"print", 				lxc_print     	  },
+	{"emit_print",			lxc_emit_print },
+	{"send_modes",			lxc_send_modes },
+	{"find_context",		lxc_find_context },
+	{"get_context",		lxc_get_context },
+	{"get_info",			lxc_get_info },
+	{"get_prefs",			lxc_get_prefs },
+	{"set_context",		lxc_set_context },
+
+	{"nickcmp", 			lxc_nickcmp 	},
+
+	{"list_get",			lxc_list_get },
+ 	{"list_fields",		lxc_list_fields }, 
+
+   {"gettext",				lxc_gettext},
+/* helper function for bit flags */
+	{"bits",					lxc_bits },
+	{NULL, NULL}
+};
+
+static struct {
+	const char *name;
+	long value;
+} lxc_consts[] = {
+	{"EAT_NONE", 	XCHAT_EAT_NONE},
+	{"EAT_XCHAT", 	XCHAT_EAT_XCHAT},
+	{"EAT_PLUGIN",	XCHAT_EAT_PLUGIN},
+	{"EAT_ALL",		XCHAT_EAT_ALL},
+
+/* unused until hook_fd is done 
+	{"FD_READ",			XCHAT_FD_READ},
+	{"FD_WRITE",		XCHAT_FD_WRITE},
+	{"FD_EXCEPTION",	XCHAT_FD_EXCEPTION},
+	{"FD_NOTSOCKET",	XCHAT_FD_NOTSOCKET},
+   */
+
+	{"PRI_HIGHEST", 	XCHAT_PRI_HIGHEST},
+	{"PRI_HIGH", 		XCHAT_PRI_HIGH},
+	{"PRI_NORM", 		XCHAT_PRI_NORM},
+	{"PRI_LOW", 		XCHAT_PRI_LOW},
+	{"PRI_LOWEST", 	XCHAT_PRI_LOWEST},
+
+	/* for: clean = xchat.strip(dirty, xchat.STRIP_ALL) */
+	{"STRIP_COLOR",	LXC_STRIP_COLOR},
+	{"STRIP_ATTR",    LXC_STRIP_ATTR},
+	{"STRIP_ALL",     LXC_STRIP_ALL},
+
+   /* for xchat.commandf("GUI COLOR %d", xchat.TAB_HILIGHT) */
+	{"TAB_DEFAULT",  0},
+	{"TAB_NEWDATA",  1},
+	{"TAB_NEWMSG",   2},
+	{"TAB_HILIGHT",  3},
+
+	{NULL,				0}
+};
+
+
+#ifdef DEBUG
+static void stackDump (lua_State *L, const char *msg) {
+	int i, t;
+	int top = lua_gettop(L);
+
+	fprintf(stderr, "%s\n", msg);
+	for (i = 1; i <= top; i++) {  /* repeat for each level */
+	 t = lua_type(L, i);
+	 switch (t) {
+
+		case LUA_TSTRING:  /* strings */
+		  fprintf(stderr, "`%s'", lua_tostring(L, i));
+		  break;
+
+		case LUA_TBOOLEAN:  /* booleans */
+		  fprintf(stderr, lua_toboolean(L, i) ? "true" : "false");
+		  break;
+
+		case LUA_TNUMBER:  /* numbers */
+		  fprintf(stderr, "%g", lua_tonumber(L, i));
+		  break;
+
+		default:  /* other values */
+		  fprintf(stderr, "%s", lua_typename(L, t));
+		  break;
+
+	 }
+	 fprintf(stderr, "  ");  /* put a separator */
+  }
+  fprintf(stderr, "\n");  /* end the listing */
+}
+#endif /* DEBUG */
+
+static int lxc__newindex(lua_State *L)
+{
+	int i;
+	const char *name = lua_tostring(L, 2);
+
+	luaL_getmetatable(L, "xchat"); /* 4 */
+
+	lua_pushnil(L);                /* 5 */
+	while (lua_next(L, 4) != 0) {
+		if ((lua_type(L, -2) == LUA_TSTRING) 
+					&& strcmp("__index", lua_tostring(L, -2)) == 0)
+				break; /* now __index is 5, table 6 */	
+		lua_pop(L, 1);
+	}
+
+	lua_pushnil(L);
+	while (lua_next(L, 6) != 0) {
+		if ((lua_type(L, -2) == LUA_TSTRING)
+				&& strcmp(name, lua_tostring(L, -2)) == 0) {
+			for (i=0; lxc_consts[i].name; i++) {
+				if (strcmp(name, lxc_consts[i].name) == 0) {
+					luaL_error(L, 
+						"`xchat.%s' is a readonly constant", lua_tostring(L, 2));
+					return 0;
+				}
+			}
+		}
+		lua_pop(L, 1);
+	}
+
+	lua_pushvalue(L, 2);
+	lua_pushvalue(L, 3);
+	lua_rawset(L, 6);
+
+	lua_settop(L, 1);
+	return 0;
+}
+
+static int luaopen_xchat(lua_State *L)
+{
+	int i;
+/* 
+ * wrappers for xchat.printf() and xchat.commandf() 
+ * ... xchat.strip 
+ */
+#define LXC_WRAPPERS  "function xchat.printf(...)\n" \
+						 "    xchat.print(string.format(unpack(arg)))\n" \
+						 "end\n" \
+						 "function xchat.commandf(...)\n" \
+						 "    xchat.command(string.format(unpack(arg)))\n" \
+						 "end\n" \
+						 "function xchat.strip(str, flags)\n" \
+						 "    if flags == nil then\n" \
+						 "        flags = xchat.STRIP_ALL\n" \
+						 "    end\n" \
+						 "    local bits = xchat.bits(flags)\n" \
+						 "    if bits[1] then\n" \
+						 "        str = string.gsub(\n" \
+						 "            string.gsub(str, \"\\3%d%d?,%d%d?\", \"\"),\n" \
+						 "                \"\\3%d%d?\", \"\")\n" \
+						 "    end\n" \
+						 "    if bits[2] then\n" \
+						 "        -- bold, beep, reset, reverse, underline\n" \
+						 "        str = string.gsub(str,\n" \
+						 "            \"[\\2\\7\\15\\22\\31]\", \"\")\n" \
+						 "    end\n" \
+						 "    return str\n" \
+						 "end\n"
+
+#if defined(LUA_VERSION_NUM) && (LUA_VERSION_NUM >= 501)
+	luaL_register(L, "xchat", lxc_functions);
+	(void)luaL_dostring(L, LXC_WRAPPERS);
+#else
+	luaL_openlib(L, "xchat", lxc_functions, 0);
+	lua_dostring(L, LXC_WRAPPERS);
+#endif
+	
+	luaL_newmetatable(L, "xchat");
+
+	lua_pushliteral(L, "__index");
+	lua_newtable(L); 
+
+	lua_pushstring(L, "ARCH");
+#ifdef _WIN32
+	lua_pushstring(L, "Windows");
+#else
+	lua_pushstring(L, "Unix");
+#endif
+	lua_settable(L, -3); /* add to table __index */
+
+	for (i=0; lxc_consts[i].name; i++) {
+		lua_pushstring(L, lxc_consts[i].name);
+		lua_pushnumber(L, lxc_consts[i].value);
+		lua_settable(L, -3); /* add to table __index */
+	}
+	lua_settable(L, -3); /* add to metatable */
+
+	lua_pushliteral(L, "__newindex");   
+	lua_pushcfunction(L, lxc__newindex); 
+	lua_settable(L, -3);                
+/* 
+	lua_pushliteral(L, "__metatable");
+	lua_pushstring(L, "nothing to see here, move along");
+	lua_settable(L, -3);               
+*/
+	lua_setmetatable(L, -2);
+	lua_pop(L, 1);
+	return 1;
+}
+
+lua_State *lxc_new_state() 
+{
+#if defined(LUA_VERSION_NUM) && (LUA_VERSION_NUM >= 501)
+	lua_State *L = luaL_newstate();     /* opens Lua */
+	luaL_openlibs(L);
+#else
+	lua_State *L = lua_open();     /* opens Lua */
+	luaopen_base(L);    /* opens the basic library */
+	luaopen_table(L);   /* opens the table library */
+	luaopen_io(L);      /* opens the I/O library */
+	luaopen_string(L);  /* opens the string lib. */
+	luaopen_math(L);    /* opens the math lib. */
+#endif
+
+	luaopen_xchat(L);
+	return L;
+}
+
+static int
+lxc_load_file(const char *script)
+{
+	lua_State *L;
+	struct lxc_States *state;  /* pointer to lua states list */
+	struct lxc_States *st;  /* pointer to lua states list */
+
+	L = lxc_new_state();
+	state = malloc(sizeof(struct lxc_States));
+	if (state == NULL) {
+		xchat_printf(ph, "malloc() failed: %s\n", strerror(errno));
+		lua_close(L);
+		return 0;
+	}
+
+	state->state = L;
+	snprintf(state->file, PATH_MAX, script);
+	state->next  = NULL;
+	state->hooks = NULL;
+	state->gui   = NULL;
+
+	if (luaL_loadfile(L, script) || lua_pcall(L, 0, 0, 0)) {
+		xchat_printf(ph, "Lua plugin: error loading script %s", 	
+							lua_tostring(L, -1));
+		lua_close(L);
+		free(state);
+		return 0;
+	}
+
+	if (!lxc_states) 
+		lxc_states = state;
+	else {
+		st = lxc_states;
+		while (st->next)
+			st = st->next;
+		st->next = state;
+	}
+
+	return 1;
+}
+
+static void
+lxc_autoload_from_path(const char *path)
+{
+	DIR *dir;
+	struct dirent *ent;
+	char *file;
+	int len;
+	/* xchat_printf(ph, "loading from %s\n", path); */
+	dir = opendir(path);
+	if (dir) {
+		while ((ent = readdir(dir))) {
+			len = strlen(ent->d_name);
+			if (len > 4 && strcasecmp(".lua", ent->d_name + len - 4) == 0) {
+				file = malloc(len + strlen(path) + 2);
+				if (file == NULL) {
+					xchat_printf(ph, "lxc_autoload_from_path(): malloc failed: %s",
+						strerror(errno));
+					break;
+				}
+				sprintf(file, "%s/%s", path, ent->d_name);
+				(void)lxc_load_file((const char *)file);
+				free(file);
+			}
+		}
+		closedir(dir);
+	}
+}
+
+void lxc_unload_script(struct lxc_States *state)
+{
+	struct lxc_hooks *hooks, *h;
+	struct lxc_cbdata *cb;
+	struct lxc_userdata *ud, *u;
+	lua_State *L = state->state;
+
+	lua_pushstring(L, "xchat_unload");
+	lua_gettable(L, LUA_GLOBALSINDEX);
+	if (lua_type(L, -1) == LUA_TFUNCTION) {
+		if (lua_pcall(L, 0, 0, 0)) {
+			xchat_printf(ph, "Lua plugin: error while unloading script %s", 	
+								lua_tostring(L, -1));
+			lua_pop(L, 1);
+		}
+	}
+
+	if (state->gui)
+		xchat_plugingui_remove(ph, state->gui);
+	state->gui = NULL;
+
+	hooks = state->hooks;
+	while (hooks) {
+		h     = hooks;
+		hooks = hooks->next;
+
+		cb    = xchat_unhook(ph, h->hook);
+		if (cb) {
+			ud    = cb->data;
+			while (ud) {
+				u  = ud;
+				ud = ud->next;
+				free(u);
+			}
+			free(cb);
+		}
+
+		free(h);
+	}
+	lua_close(state->state);
+}
+
+
+static int lxc_cb_load(char *word[], char *word_eol[], void *userdata)
+{
+	int len;
+	struct lxc_States *state;
+	lua_State *L;
+	const char *name, *desc, *vers;
+	const char *xdir = "";
+	char  *buf;
+	char file[PATH_MAX+1];
+	struct stat *st;
+
+	if (word_eol[2][0] == 0)
+		return XCHAT_EAT_NONE;
+	
+	buf = malloc(PATH_MAX + 1);
+	if (!buf) {
+		xchat_printf(ph, "malloc() failed: %s\n", strerror(errno));
+		return XCHAT_EAT_NONE;
+	}
+
+	st = malloc(sizeof(struct stat));
+	if (!st) {
+		xchat_printf(ph, "malloc() failed: %s\n", strerror(errno));
+		free(buf);
+		return XCHAT_EAT_NONE;
+	}
+
+ 	len = strlen(word[2]);
+	if (len > 4 && strcasecmp (".lua", word[2] + len - 4) == 0) {
+#ifdef WIN32
+		if (strrchr(word[2], '\\') != NULL)
+#else
+		if (strrchr(word[2], '/') != NULL)
+#endif
+			strncpy(file, word[2], PATH_MAX);
+		else {
+			if (stat(word[2], st) == 0)
+				xdir = getcwd(buf, PATH_MAX);
+			else {
+				xdir = xchat_get_info(ph, "xchatdirfs");
+				if (!xdir) /* xchatdirfs is new for 2.0.9, will fail on older */
+					xdir = xchat_get_info (ph, "xchatdir");
+			}
+			snprintf(file, PATH_MAX, "%s/%s", xdir, word[2]);
+		}
+
+		if (lxc_load_file((const char *)file) == 0) {
+			free(st);
+			free(buf);
+			return XCHAT_EAT_ALL;
+		}
+
+		state = lxc_states;
+		while (state) {
+			if (state->next == NULL) {
+				L = state->state;
+
+				lua_pushstring(L, "xchat_register");
+				lua_gettable(L, LUA_GLOBALSINDEX);
+				if (lua_pcall(L, 0, 3, 0)) {
+					xchat_printf(ph, "Lua plugin: error registering script %s", 	
+								lua_tostring(L, -1));
+					lua_pop(L, 1);
+					free(st);
+					free(buf);
+					return XCHAT_EAT_ALL;
+				}
+
+				name = lua_tostring(L, -3);
+				desc = lua_tostring(L, -2);
+				vers = lua_tostring(L, -1);
+				lua_pop(L, 4); /* func + 3 ret value */
+				state->gui = xchat_plugingui_add(ph, state->file, 
+																 name, desc, vers, NULL
+															);
+
+				lua_pushstring(L, "xchat_init");
+				lua_gettable(L, LUA_GLOBALSINDEX);
+				if (lua_type(L, -1) != LUA_TFUNCTION) 
+					lua_pop(L, 1);
+				else {
+					if (lua_pcall(L, 0, 0, 0)) {
+						xchat_printf(ph, 
+									"Lua plugin: error calling xchat_init() %s", 	
+									lua_tostring(L, -1));
+						lua_pop(L, 1);
+					}
+				}
+				free(st);
+				free(buf);
+				return XCHAT_EAT_ALL;
+			}
+			state = state->next;
+		}
+	}
+	free(st);
+	free(buf);
+	return XCHAT_EAT_NONE;
+}
+
+static int lxc_cb_unload(char *word[], char *word_eol[], void *userdata)
+{
+	int len;
+	struct lxc_States *state;
+	struct lxc_States *prev = NULL;
+	char *file;
+
+	if (word_eol[2][0] == 0)
+		return XCHAT_EAT_NONE;
+
+	len = strlen(word[2]);
+	if (len > 4 && strcasecmp(".lua", word[2] + len - 4) == 0) {
+		state = lxc_states;
+		while (state) {
+			/* 
+			 * state->file is the full or relative path, always with a '/' inside,
+			 * even if loaded via '/LOAD script.lua'. So strrchr() will never
+			 * be NULL.
+			 * ... we just inspect the script name w/o path to see if it's the 
+			 * right one to unload
+			 */
+			file = strrchr(state->file, '/') + 1; 
+			if ((strcmp(state->file, word[2]) == 0) 
+					|| (strcasecmp(file, word[2]) == 0)) {
+				lxc_unload_script(state);
+				if (prev) 
+					prev->next = state->next;
+				else
+					lxc_states = state->next;
+				xchat_printf(ph, "Lua script %s unloaded", file);
+				free(state);
+				return XCHAT_EAT_ALL;
+			}
+			prev  = state;
+			state = state->next;
+		}
+	}
+	return XCHAT_EAT_NONE;
+}
+
+static int lxc_cb_lua(char *word[], char *word_eol[], void *userdata)
+{
+	lua_State *L = lxc_new_state();
+	if (word[2][0] == '\0') {
+		xchat_printf(ph, "LUA: Usage: /LUA LUA_CODE... execute LUA_CODE");
+		return XCHAT_EAT_ALL;
+	}
+	if (luaL_loadbuffer(L, word_eol[2], strlen(word_eol[2]), "/LUA")) {
+		xchat_printf(ph, "LUA: error loading line %s", lua_tostring(L, -1));
+		lua_pop(L, 1);
+	}
+
+#define LXC_HOOK_DISABLE "xchat.hook_command = nil\n" \
+								 "xchat.hook_server  = nil\n" \
+								 "xchat.hook_print   = nil\n" \
+								 "xchat.hook_timer   = nil\n"
+
+#if defined(LUA_VERSION_NUM) && (LUA_VERSION_NUM >= 501)
+	(void)luaL_dostring(L, LXC_HOOK_DISABLE);
+#else
+	lua_dostring(L, LXC_HOOK_DISABLE);
+#endif
+
+	if (lua_pcall(L, 0, 0, 0)) {
+		xchat_printf(ph, "LUA: error executing line %s", lua_tostring(L, -1));
+		lua_pop(L, 1);
+	}
+
+	lua_close(L);
+	return XCHAT_EAT_ALL;
+}
+
+int xchat_plugin_init(xchat_plugin *plugin_handle,
+                      char **plugin_name,
+                      char **plugin_desc,
+                      char **plugin_version,
+                      char *arg)
+{
+	struct lxc_States	*state;	
+	lua_State *L;
+	const char *xdir;
+	const char *name, *desc, *vers;
+   /* we need to save this for use with any xchat_* functions */
+   ph = plugin_handle;
+
+   /* tell xchat our info */
+   *plugin_name = LXC_NAME;
+   *plugin_desc = LXC_DESC;
+   *plugin_version = LXC_VERSION;
+
+	xchat_hook_command(ph, "LOAD", XCHAT_PRI_NORM, lxc_cb_load, NULL, NULL);
+	xchat_hook_command(ph, "UNLOAD", XCHAT_PRI_NORM, lxc_cb_unload, NULL, NULL);
+	xchat_hook_command(ph, "LUA", XCHAT_PRI_NORM, lxc_cb_lua, "Usage: LUA <code>, executes <code> in a new lua state", NULL);
+
+	xdir = xchat_get_info(ph, "xchatdirfs");
+	if (!xdir) /* xchatdirfs is new for 2.0.9, will fail on older */
+		xdir = xchat_get_info (ph, "xchatdir");
+		
+	lxc_autoload_from_path(xdir);
+
+	if (!lxc_states) /* no scripts loaded */
+		return 1;
+	
+	state = lxc_states;
+	while (state) {
+		L = state->state;
+		lua_pushstring(L, "xchat_register");
+		lua_gettable(L, LUA_GLOBALSINDEX);
+		if (lua_pcall(L, 0, 3, 0)) {
+			xchat_printf(ph, "Lua plugin: error registering script %s", 	
+								lua_tostring(L, -1));
+			lua_pop(L, 1);
+			state = state->next;
+			continue;
+		}
+
+		name = lua_tostring(L, -3);
+		desc = lua_tostring(L, -2);
+		vers = lua_tostring(L, -1);
+		lua_pop(L, 4); /* func + 3 ret value */
+		state->gui = xchat_plugingui_add(ph, state->file, name, desc, vers, NULL);
+
+		lua_pushstring(L, "xchat_init");
+		lua_gettable(L, LUA_GLOBALSINDEX);
+		if (lua_type(L, -1) != LUA_TFUNCTION) 
+			lua_pop(L, 1);
+		else {
+			if (lua_pcall(L, 0, 0, 0)) {
+				xchat_printf(ph, "Lua plugin: error calling xchat_init() %s", 	
+								lua_tostring(L, -1));
+				lua_pop(L, 1);
+			}
+		}
+		state = state->next;
+	}
+	xchat_printf(ph, "Lua interface (v%s) loaded", LXC_VERSION);
+	return 1; 
+}
+
+int xchat_plugin_deinit(xchat_plugin *plug_handle) 
+{
+	struct lxc_States *state, *st;
+
+	state = lxc_states;
+	while (state) {
+		lxc_unload_script(state);
+		xchat_printf(ph, "Lua script %s unloaded", state->file);
+		st    = state;
+		state = state->next;
+		free(st);
+	}
+	xchat_printf(plug_handle, "Lua plugin v%s removed", LXC_VERSION);
+	return 1;
+}
+
+/*
+ * lua:  func_name(word, word_eol, data)
+ * desc: your previously hooked callback function for hook_command() and
+ *       hook_server(), you must return one of the xchat.EAT_* constants
+ * ret:  none
+ * args: 
+ *       * word (table): the incoming line split into words (max 32)
+ *       * word_eol (table): 
+ *         for both see 
+ *          http://xchat.org/docs/plugin20.html#word
+ *       * data (table): the data table you passed to the hook_command() /
+ *         hook_server() as 5th arg
+ */
+static int lxc_run_hook(char *word[], char *word_eol[], void *data)
+{
+	struct lxc_cbdata *cb   = data;
+	lua_State *L            = cb->state;
+	struct lxc_userdata *ud = cb->data;
+	struct lxc_userdata *u;
+	int i;
+	lua_pushstring(L, cb->func);
+	lua_gettable(L, LUA_GLOBALSINDEX);
+
+	strcpy(lxc_event_name, word[0]);
+	lua_newtable(L);
+	for (i=1; i<=31 && word[i][0]; i++) {
+		lua_pushnumber(L, i);
+		lua_pushstring(L, word[i]);
+		lua_settable(L, -3);
+	}
+
+	lua_newtable(L);
+	for (i=1; i<=31 && word_eol[i][0]; i++) {
+		lua_pushnumber(L, i);
+		lua_pushstring(L, word_eol[i]);
+		lua_settable(L, -3);
+	}
+
+	lua_newtable(L);
+	u = ud;
+	while (u) {
+		lua_pushnumber(L, u->idx);
+		switch (u->type) {
+			case LUA_TSTRING:
+				lua_pushstring(L, u->string);
+				break;
+			case LUA_TNUMBER:
+				lua_pushnumber(L, u->num);
+				break;
+			case LUA_TBOOLEAN:
+				lua_pushboolean(L, (((int)u->num == 0) ? 0 : 1));
+				break;
+			default: /* LUA_TNIL or others */
+				lua_pushnil(L);
+				break;
+		}
+		lua_settable(L, -3);
+		u = u->next;
+	}
+
+	if (lua_pcall(L, 3, 1, 0)) {
+		xchat_printf(ph, "failed to call callback for '%s': %s", 
+				word[1], lua_tostring(L, -1)
+			);
+		lua_pop(L, 1);
+		return XCHAT_EAT_NONE;
+	}
+
+	if (lua_type(L, -1) != LUA_TNUMBER) {
+		xchat_printf(ph, "callback for '%s' did not return number...", word[1]);
+		return XCHAT_EAT_NONE;
+	}
+
+	i = (int)lua_tonumber(L, -1);
+	lua_pop(L, 1);
+	return i;
+}
+
+static int lxc_get_userdata(int pos, struct lxc_cbdata *cb)
+{
+	struct lxc_userdata *ud, *u;
+	lua_State *L = cb->state;
+	int i, t;
+
+	t = lua_type(L, pos);
+	if (t == LUA_TNIL)
+		return 1;
+	if (t != LUA_TTABLE)
+		return 0;
+
+	i = 1;
+	while (1) {
+		lua_pushnumber(L, i);
+		lua_gettable(L, -2);
+
+		t = lua_type(L, -1);
+		if (t == LUA_TNIL) {
+			lua_pop(L, 1);
+			break;
+		}
+
+		ud = malloc(sizeof(struct lxc_userdata));
+		if (!ud) {
+			xchat_printf(ph, "lxc_get_userdata(): failed to malloc: %s", 
+																strerror(errno));
+			if (cb->data != NULL) {
+				ud = cb->data;
+				while (ud) {
+					u  = ud;
+					ud = ud->next;
+					free(u);
+				}
+			}
+			/* free(cb); NO! */
+			lua_pushnil(L);
+			return 0;
+		}
+		ud->idx = i;
+		ud->next = NULL;
+		switch (t) {
+			case LUA_TSTRING:
+				ud->string = lua_tostring(L, -1);
+				ud->type   = LUA_TSTRING;
+				break;
+			case LUA_TNUMBER:
+				ud->num    = lua_tonumber(L, -1);
+				ud->type   = LUA_TNUMBER;
+				break;
+			case LUA_TBOOLEAN:
+				ud->num    = (double)lua_toboolean(L, -1);
+				ud->type   = LUA_TBOOLEAN;
+				break;
+			default:
+				ud->type   = LUA_TNIL;
+				break;
+		}
+		lua_pop(L, 1);
+
+		if (cb->data == NULL)
+			cb->data = ud;
+		else {
+			u = cb->data;
+			while (u->next)
+				u = u->next;
+			u->next = ud;
+		}
+		i++;
+	} /* END while (1) */
+	return 1;
+}
+
+/* 
+ * lua:  xchat.hook_command(name, func_name, prio, help_str, data)
+ * desc: Adds a new /command. This allows your program to handle commands 
+ *       entered at the input box. To capture text without a "/" at the start 
+ *       (non-commands), you may hook a special name of "". i.e 
+ *           xchat.hook_command( "", ...)
+ * 		Starting from version 2.6.8, commands hooked that begin with a 
+ * 		period ('.') will be hidden in /HELP and /HELP -l. 
+ * ret:  true... or false if something went wrong while registering hook
+ * args: 
+ *       * name (string): the name of the new command
+ *       * func_name (string): the lua function to be called when command is
+ *          entered
+ *       * prio (number): use one of the xchat.PRIO_*
+ *       * help_str (string): help for the new command... use nil for no help
+ *       * data (table): table with strings, numbers and booleans, which will
+ *         be passed to func_name as last argument.
+ */
+static int lxc_hook_command(lua_State *L)
+{
+	xchat_hook *hook;
+	const char *help, *command, *func;
+	double prio;
+	struct lxc_hooks *hooks, *h;
+	struct lxc_States *st;
+	struct lxc_cbdata *cb;
+
+
+	if (lua_gettop(L) < 5) /* expand to five args if necessary */
+		lua_settop(L, 5);
+
+	cb = malloc(sizeof(struct lxc_cbdata));
+	if (!cb) {
+		xchat_printf(ph, "lxc_hook_command(): failed to malloc: %s", 
+																	strerror(errno));
+		lua_pushboolean(L, 0);
+		return 1;
+	}
+
+	cb->state = L;
+	cb->data = NULL;
+
+	command 	= luaL_checkstring(L, 1);
+	func     = luaL_checkstring(L, 2);
+	cb->func = func;
+	cb->hook = NULL;
+
+	if (lua_type(L, 3) == LUA_TNIL)
+		prio = XCHAT_PRI_NORM;
+	else
+		prio = luaL_checknumber(L, 3);
+
+	if (lua_type(L, 4) == LUA_TSTRING) {
+		help = luaL_checkstring(L, 4);
+		if (strlen(help) == 0)
+			help = NULL;
+	}
+	else
+		help = NULL;
+	
+	if (lxc_get_userdata(5, cb) == 0) 
+		lua_pushboolean(L, 0);
+	else {
+		h = malloc(sizeof(struct lxc_hooks));
+		if (!h) {
+			xchat_printf(ph, "lxc_hook_command(): failed to malloc: %s", 
+																	strerror(errno));
+			lua_pushboolean(L, 0);
+			return 1;
+		}
+		hook    = xchat_hook_command(ph, command, prio, lxc_run_hook, help, cb);
+		h->hook = hook;
+		h->name = command;
+		h->next = NULL;
+		st      = lxc_states;
+		while (st) {
+			if (st->state == L) {
+				if (!st->hooks) 
+					st->hooks = h;
+				else {
+					hooks     = st->hooks;
+					while (hooks->next) 
+						hooks = hooks->next;
+					hooks->next = h;
+				}
+				break;
+			}
+			st = st->next;
+		}
+		lua_pushboolean(L, 1);
+	}
+	return 1;
+}
+
+/*
+ * lua:  func_name(word, data)
+ * desc: your previously hooked callback function for hook_print(), 
+ *       you must return one of the xchat.EAT_* constants
+ * ret:  none
+ * args: 
+ *       * word (table): the incoming line split into words (max 32)
+ *         (see http://xchat.org/docs/plugin20.html#word)
+ *       * data (table): the data table you passed to the hook_print() /
+ *         as 4th arg
+ */
+static int lxc_run_print(char *word[], void *data)
+{
+	struct lxc_cbdata *cb = data;
+	lua_State *L          = cb->state;
+	int i;
+
+	lua_pushstring(L, cb->func);
+	lua_gettable(L, LUA_GLOBALSINDEX);
+
+	strcpy(lxc_event_name, word[0]);
+	lua_newtable(L);
+	for (i=1; i<=31 && word[i][0]; i++) {
+		lua_pushnumber(L, i);
+		lua_pushstring(L, word[i]);
+		lua_settable(L, -3);
+	}
+
+	if (lua_pcall(L, 1, 1, 0)) {
+		xchat_printf(ph, "failed to call callback for '%s': %s", 
+			word[1], lua_tostring(L, -1));
+		lua_pop(L, 1);
+		return 0;
+	}
+
+	if (lua_type(L, -1) != LUA_TNUMBER) {
+		xchat_printf(ph, "callback for '%s' didn't return number...", word[1]);
+		return XCHAT_EAT_NONE;
+	}
+	i = (int)lua_tonumber(L, -1);
+	lua_pop(L, 1);
+	return i;
+}
+
+/* 
+ * lua:  xchat.hook_print(name, func_name, prio, data)
+ * desc: Registers a function to trap any print events. The event names may 
+ *       be any available in the "Advanced > Text Events" window. There are 
+ *       also some extra "special" events you may hook using this function,
+ *       see: http://xchat.org/docs/plugin20.html#xchat_hook_print
+ * ret:  true... or false if something went wrong while registering hook
+ * args: 
+ *       * name (string): the name of the new command
+ *       * prio (number): use one of the xchat.PRIO_*
+ *       * func_name (string): the lua function to be called when command is
+ *         entered
+ *       * data (table): table with strings, numbers and booleans, which will
+ *         be passed to func_name as last argument.
+ */
+static int lxc_hook_print(lua_State *L)
+{
+	xchat_hook *hook;
+	struct lxc_hooks *hooks, *h;
+	struct lxc_States *st;
+	struct lxc_cbdata *cb = malloc(sizeof(struct lxc_cbdata));
+	const char *name, *func;
+	double prio;
+
+	if (!cb) {
+		luaL_error(L, "lxc_hook_print(): failed to malloc: %s", strerror(errno));
+		return 0;
+	}
+
+	if (lua_gettop(L) < 4) /* expand to 4 args if necessary */
+		lua_settop(L, 4);
+
+	name = luaL_checkstring(L, 1);
+	func = luaL_checkstring(L, 2);
+	if (lua_type(L, 3) == LUA_TNIL)
+		prio = XCHAT_PRI_NORM;
+	else
+		prio = luaL_checknumber(L, 3);
+
+	cb->state = L;
+	cb->func  = func;
+	cb->data  = NULL;
+	cb->hook  = NULL;
+
+	if (lxc_get_userdata(4, cb) == 0) 
+		lua_pushboolean(L, 0);
+	else {
+		h = malloc(sizeof(struct lxc_hooks));
+		if (!h) {
+			xchat_printf(ph, "lxc_hook_print(): failed to malloc: %s", 
+																	strerror(errno));
+			lua_pushboolean(L, 0);
+			return 1;
+		}
+		hook 	  = xchat_hook_print(ph, name, prio, lxc_run_print, cb); 
+		h->hook = hook;
+		h->name = name;
+		h->next = NULL;
+		st      = lxc_states;
+		while (st) {
+			if (st->state == L) {
+				if (!st->hooks)
+					st->hooks = h;
+				else {
+					hooks     = st->hooks;
+					while (hooks->next) 
+						hooks = hooks->next;
+					hooks->next = h;
+				}
+				break;
+			}
+			st = st->next;
+		}
+		lua_pushboolean(L, 1);
+	}
+	return 1;
+}
+
+/*
+ * lua:  xchat.hook_server(name, func_name, prio, data)
+ * desc: Registers a function to be called when a certain server event 
+ *       occurs. You can use this to trap PRIVMSG, NOTICE, PART, a server 
+ *       numeric etc... If you want to hook every line that comes from the 
+ *       IRC server, you may use the special name of "RAW LINE".
+ * ret:  true... or false if something went wrong while registering
+ * args: 
+ *       * name (string): the event name / numeric (yes, also as a string)
+ *       * prio (number): one of the xchat.PRIO_* constants
+ *       * func_name (string): the function to be called, when the event
+ *           happens
+ *       * data (table)... see xchat.hook_command()
+ */
+static int lxc_hook_server(lua_State *L)
+{
+	xchat_hook *hook;
+	struct lxc_hooks *hooks, *h;
+	struct lxc_States *st;
+	const char *name, *func;
+	double prio;
+
+	struct lxc_cbdata *cb = malloc(sizeof(struct lxc_cbdata));
+	if (!cb) {
+		xchat_printf(ph, "lxc_hook_server(): failed to malloc: %s", 
+																	 strerror(errno));
+		lua_pushnil(L);
+		return 1;
+	}
+
+	if (lua_gettop(L) < 4) /* expand to 4 args if necessary */
+		lua_settop(L, 4);
+
+	name = luaL_checkstring(L, 1);
+	func = luaL_checkstring(L, 2);
+	if (lua_type(L, 3) == LUA_TNIL)
+		prio = XCHAT_PRI_NORM;
+	else
+		prio = luaL_checknumber(L, 3);
+
+	cb->state = L;
+	cb->func = func;
+	cb->data = NULL;
+	cb->hook = NULL;
+
+	if (lxc_get_userdata(4, cb) == 0) 
+		lua_pushboolean(L, 0);
+	else {
+		h = malloc(sizeof(struct lxc_hooks));
+		if (!h) {
+			xchat_printf(ph, "lxc_hook_server(): failed to malloc: %s", 
+																	strerror(errno));
+			lua_pushboolean(L, 0);
+			return 1;
+		}
+		hook    = xchat_hook_server(ph, name, prio, lxc_run_hook, cb); 
+		h->hook = hook;
+		h->name = name;
+		h->next = NULL;
+		st      = lxc_states;
+		while (st) {
+			if (st->state == L) {
+				if (!st->hooks)
+					st->hooks = h;
+				else {
+					hooks     = st->hooks;
+					while (hooks->next) 
+						hooks = hooks->next;
+					hooks->next = h;
+				}
+				break;
+			}
+			st = st->next;
+		}
+		lua_pushboolean(L, 1);
+	}
+	return 1;
+}
+
+/* 
+ * lua:  xchat.hook_timer(timeout, func_name, data)
+ * desc: Registers a function to be called every "timeout" milliseconds.
+ * ret:  true (or false on error while registering)
+ * args: 
+ *       * timeout (number): Timeout in milliseconds (1000 is 1 second). 
+ *       * func_name (string): Callback function. This will be called 
+ *           every "timeout" milliseconds. 
+ *       * data (table): see xchat.hook_command()
+ */
+
+static unsigned long long lxc_timer_count = 0;
+
+static int lxc_hook_timer(lua_State *L)
+{
+	xchat_hook *hook;
+	struct lxc_hooks *hooks, *h;
+	struct lxc_States *st;
+	double timeout;
+	const char *func;
+	char name[32];
+
+	struct lxc_cbdata *cb = malloc(sizeof(struct lxc_cbdata));
+	if (!cb) {
+		luaL_error(L, "lxc_hook_timer(): failed to malloc: %s", strerror(errno));
+		lua_pushnil(L);
+		return 1;
+	}
+
+	if (lua_gettop(L) < 3) /* expand to 3 args if necessary */
+		lua_settop(L, 3);
+
+	timeout = luaL_checknumber(L, 1);
+	func    = luaL_checkstring(L, 2);
+
+	cb->state = L;
+	cb->func  = func;
+	cb->data  = NULL;
+
+	if (lxc_get_userdata(3, cb) == 0) 
+		lua_pushnil(L);
+	else {
+		h = malloc(sizeof(struct lxc_hooks));
+		if (!h) {
+			luaL_error(L, "lxc_hook_timer(): failed to malloc: %s", 
+				strerror(errno));
+			return 0;
+		}
+		hook 	   = xchat_hook_timer(ph, timeout, lxc_run_timer, cb); 
+		cb->hook = hook;
+		h->hook  = hook;
+		h->next  = NULL;
+		snprintf(name, 31, "timer%llu", lxc_timer_count++);
+		h->name  = name;
+		lua_pushstring(L, name);
+
+		st       = lxc_states;
+		while (st) {
+			if (st->state == L) {
+				if (!st->hooks)
+					st->hooks = h;
+				else {
+					hooks     = st->hooks;
+					while (hooks->next)
+						hooks = hooks->next;
+					hooks->next = h;
+				}
+				break;
+			}
+			st = st->next;
+		}
+	}
+	return 1;
+}
+
+static void lxc_unhook_timer(lua_State *L, xchat_hook *hook)
+{
+	struct lxc_States *state;
+	struct lxc_hooks *hooks, *h, *prev_hook;
+	struct lxc_cbdata *cb;
+	struct lxc_userdata *ud, *u;
+
+	prev_hook = NULL;
+	state = lxc_states;
+	while (state) {
+		if (state->state == L) {
+			hooks = state->hooks;
+			while (hooks) {
+				if (hooks->hook == hook) {
+					h  = hooks;
+					if (prev_hook)
+						prev_hook->next = hooks->next;
+					else
+						state->hooks = hooks->next;
+
+					cb = xchat_unhook(ph, h->hook);
+					if (cb) {
+						 ud = cb->data;
+						 while (ud) {
+							 u  = ud;
+							 ud = ud->next;
+							 free(u);
+						 }
+						 free(cb);
+					}
+
+					free(h);
+					return;
+				}
+				prev_hook = hooks;
+				hooks = hooks->next;
+			}
+			break;
+		}
+		state = state->next;
+	}
+}
+
+/* 
+ * lua:  func_name(data)
+ * desc: the callback function for the registered timer hook, return
+ *       true to keep this timer going, false to stop it
+ * ret:  none
+ * args: 
+ *       * data (table): the table you gave the hook_timer() as last
+ *           argument
+ */
+ static int lxc_run_timer(void *data)
+{
+	int ret;
+	struct lxc_cbdata *cb = data;
+	xchat_hook *hook      = cb->hook;
+	lua_State *L          = cb->state;
+
+	lua_pushstring(L, cb->func);
+	lua_gettable(L, LUA_GLOBALSINDEX);
+
+	if (lua_pcall(L, 0, 1, 0)) {
+		xchat_printf(ph, "failed to call timer callback for '%s': %s", 
+			cb->func, lua_tostring(L, -1));
+		lua_pop(L, 1);
+		lxc_unhook_timer(L, hook);
+		return 0;
+	}
+
+	if (lua_type(L, -1) != LUA_TBOOLEAN) {
+		xchat_printf(ph, 
+			"timer callback for '%s' didn't return a boolean", cb->func);
+		lua_pop(L, 1);
+		lxc_unhook_timer(L, hook);
+		return 0;
+	}
+
+	ret = (lua_toboolean(L, -1) == 0) ? 0 : 1;
+	lua_pop(L, 1);
+
+	if (ret == 0)
+		lxc_unhook_timer(L, hook);
+
+	return ret;
+}
+
+/*
+ * lua:  xchat.unhook(name)
+ * desc: unhooks a previously hooked hook 
+ * ret:  true if the hook existed, else false..
+ * args: 
+ *       * name (string): name of a registered hook (e.g. with 
+ *         xchat.hook_command("whois", ... ) you would unhook "whois"
+ *         ... see timer warnings... there's currently just one "timer"
+ *         to unhook
+ */
+static int lxc_unhook(lua_State *L)
+{
+	struct lxc_States *state;
+	struct lxc_hooks *hooks, *h, *prev_hook;
+	struct lxc_cbdata *cb;
+	struct lxc_userdata *ud, *u;
+	int done = 0;
+	const char *name = luaL_checkstring(L, 1);
+
+	prev_hook = NULL;
+	state = lxc_states;
+	while (state) {
+		if (state->state == L) {
+			hooks = state->hooks;
+			while (hooks) {
+				if (strcasecmp(hooks->name, name) == 0) {
+					h  = hooks;
+					if (prev_hook)
+						prev_hook->next = hooks->next;
+					else
+						state->hooks = hooks->next;
+
+					cb = xchat_unhook(ph, h->hook);
+					if (cb) {
+						ud = cb->data;
+						while (ud) {
+							u  = ud;
+							ud = ud->next;
+							free(u);
+						}
+						free(cb);
+					}
+
+					free(h);
+					done = 1;
+					break;
+				}
+				prev_hook = hooks;
+				hooks = hooks->next;
+			}
+			break;
+		}
+		state = state->next;
+	}
+	lua_pushboolean(L, done);
+	return 1;
+}
+
+static int lxc_event(lua_State *L)
+{
+	lua_pushstring(L, lxc_event_name);
+	return 1;
+}
+
+/* 
+ * lua:  xchat.command(command) 
+ * desc: executes a command as if it were typed in xchat's input box. 
+ * ret:  none
+ * args: 
+ *       * command (string): command to execute, without the forward slash "/". 
+ */
+static int lxc_command(lua_State *L)
+{
+	const char *command = luaL_checkstring(L, 1);
+	xchat_command(ph, command);
+	return 0;
+}
+
+/* 
+ * lua:  xchat.print(text)
+ * desc: Prints some text to the current tab/window.
+ * ret:  none
+ * args: 
+ *       * text (string): the text to print
+ */
+static int lxc_print(lua_State *L)
+{
+	const char *txt = luaL_checkstring(L, 1);
+	// FIXME? const char *txt = lua_tostring(L, 1);
+	xchat_print(ph, txt);
+	return 0;
+}
+
+/*
+ * lua: xchat.emit_print(event, text, [text2, ...])
+ * desc: Generates a print event. This can be any event found in the 
+ *       Preferences > Advanced > Text Events window. The vararg parameter 
+ *       list MUST be no longer than four (4) parameters. 
+ *       Special care should be taken when calling this function inside a 
+ *       print callback (from xchat.hook_print()), as not to cause endless 
+ *       recursion. 
+ * ret:  true on success, false on error
+ * args: 
+ *       * event (string): the event name from the references > Advanced > 
+ *         Text Events window
+ *       * text (string)
+ *         text2 (string)
+ *         ... (string(s)):
+ *           parameters for the given event
+ */
+static int lxc_emit_print(lua_State *L)
+{
+
+	int n = lua_gettop(L);
+	const char *text[5];
+	const char *event;
+	int i = 2;
+
+	if (n > 6)
+		luaL_error(L, "too many arguments to xchat.emit_print()");
+
+	event = luaL_checkstring(L, 1);
+	while (i <= n) {
+		text[i-2] = luaL_checkstring(L, i);
+		i++;
+	}
+	switch (n-1) {
+		case 0:
+			i = xchat_emit_print(ph, event, NULL);
+			break;
+		case 1:
+			i = xchat_emit_print(ph, event, text[0], NULL);
+			break;
+		case 2:
+			i = xchat_emit_print(ph, event, text[0], text[1], NULL);
+			break;
+		case 3:
+			i = xchat_emit_print(ph, event, text[0], text[1], text[2], NULL);
+			break;
+		case 4:
+			i = xchat_emit_print(ph, event, text[0], text[1], text[2], text[3], NULL);
+			break;
+	}
+	lua_pushboolean(L, (i == 0) ? 0 : 1);
+	return 1;
+}
+
+/* 
+ * lua:  xchat.send_modes(targets, sign, mode [, modes_per_line])
+ * desc: Sends a number of channel mode changes to the current channel. 
+ *       For example, you can Op a whole group of people in one go. It may 
+ *       send multiple MODE lines if the request doesn't fit on one. Pass 0 
+ *       for modes_per_line to use the current server's maximum possible. 
+ *       This function should only be called while in a channel context. 
+ * ret:  none
+ * args: 
+ *       * targets (table): list of names
+ *       * sign (string): mode sign, i.e. "+" or "-", only the first char of
+ *            this is used (currently unchecked if it's really "+" or "-")
+ *       * mode (string): mode char, i.e. "o" for opping, only the first 
+ *            char of this is used (currently unchecked, what char)
+ *       * modes_per_line (number): [optional] number of modes per line
+ */
+static int lxc_send_modes(lua_State *L)
+{
+	int i = 1;
+	const char *name, *mode, *sign;
+	const char *targets[4096];
+	int num = 0; /* modes per line */
+
+	if (!lua_istable(L, 1)) {
+		luaL_error(L, 
+			"xchat.send_modes(): first argument is not a table: %s", 
+			lua_typename(L, lua_type(L, 1)));
+		return 0;
+	}
+
+	while (1) {
+		lua_pushnumber(L, i); /* push index on stack */
+		lua_gettable(L, 1);   /* and get the element @ index */
+		if (lua_isnil(L, -1)) { /* end of table */
+			lua_pop(L, 1);
+			break;
+		}
+
+		if (lua_type(L, -1) != LUA_TSTRING) { /* oops, something wrong */
+			luaL_error(L, 
+				"lua: xchat.send_modes(): table element #%d not a string: %s",
+				i, lua_typename(L, lua_type(L, -1)));
+			lua_pop(L, 1);
+			return 0;
+		}
+
+		name = lua_tostring(L, -1);
+		if (name == NULL) { /* this should not happen, but... */
+			lua_pop(L, 1);
+			break;
+		}
+
+		targets[i-1] = name;
+		lua_pop(L, 1); /* take index from stack */
+		++i;
+	}
+
+	sign = luaL_checkstring(L, 2);
+	if (sign[0] == '\0' || sign[1] != '\0') {
+		luaL_error(L, "argument #2 (mode sign) does not have length 1");
+		return 0;
+	}
+	if ((sign[0] != '+') && (sign[0] != '-')) {
+		luaL_error(L, "argument #2 (mode sign) is not '+' or '-'");
+		return 0;
+	}
+
+	mode = luaL_checkstring(L, 3);
+	if (mode[0] == '\0' || mode[1] != '\0') {
+		luaL_error(L, "argument #3 (mode char) does not have length 1");
+		return 0;
+	}
+	if (!isalpha((int)mode[0]) || !isascii((int)mode[0])) {
+		luaL_error(L, "argument #3 is not a valid mode character");
+		return 0;
+	}
+
+	if (lua_gettop(L) == 4)
+		num = luaL_checknumber(L, 4);
+	
+	xchat_send_modes(ph, targets, i-1, num, sign[0], mode[0]);
+	return 0;
+}
+
+/*
+ * lua:  xchat.find_context(srv, chan)
+ * desc: Finds a context based on a channel and servername. If servname is nil,
+ *       it finds any channel (or query) by the given name. If channel is nil, 
+ *       it finds the front-most tab/window of the given servname. If nil is 
+ *       given for both arguments, the currently focused tab/window will be 
+ *       returned.
+ *       Changed in 2.6.1. If servname is nil, it finds the channel (or query)
+ *       by the given name in the same server group as the current context. 
+ *       If that doesn't exists then find any by the given name. 
+ * ret:  context number (DON'T modify)
+ * args: 
+ *       * srv (string or nil): server name
+ *       * chan (string or nil): channel / query name
+ */
+static int lxc_find_context(lua_State *L)
+{
+	const char *srv, *chan;
+	long ctx;
+	xchat_context *ptr;
+
+	if (lua_type(L, 1) == LUA_TSTRING) {
+		srv = lua_tostring(L, 1);
+		if (srv[0] == '\0')
+			srv = NULL;
+	}
+	else
+		srv = NULL;
+	
+	if (lua_type(L, 2) == LUA_TSTRING) {
+		chan = lua_tostring(L, 2);
+		if (chan[0] == '\0')
+			chan = NULL;
+	}
+	else
+		chan = NULL;
+	
+	ptr = xchat_find_context(ph, srv, chan);
+	ctx = (long)ptr;
+#ifdef DEBUG
+	fprintf(stderr, "find_context(): %#lx\n", (long)ptr);
+#endif
+	lua_pushnumber(L, (double)ctx);
+	return 1;
+}
+
+/* 
+ * lua:  xchat.get_context()
+ * desc: Returns the current context for your plugin. You can use this later 
+ *       with xchat_set_context. 
+ * ret:  context number ... DON'T modifiy
+ * args: none
+ */
+static int lxc_get_context(lua_State *L)
+{
+	long ptr;
+	xchat_context *ctx = xchat_get_context(ph);
+	ptr = (long)ctx;
+#ifdef DEBUG
+	fprintf(stderr, "get_context(): %#lx\n", ptr);
+#endif
+	lua_pushnumber(L, (double)ptr);
+	return 1;
+}
+
+/* 
+ * lua:  xchat.get_info(id)
+ * desc: Returns information based on your current context.
+ * ret:  the requested string or nil on error
+ * args: 
+ *       * id (string): the wanted information
+ */
+static int lxc_get_info(lua_State *L)
+{
+	const char *id    = luaL_checkstring(L, 1);
+	const char *value = xchat_get_info(ph, id);
+	if (value == NULL)
+		lua_pushnil(L);
+	else
+		lua_pushstring(L, value);
+	return 1;
+}
+
+/*
+ * lua:  xchat.get_prefs(name)
+ * desc: Provides xchat's setting information (that which is available 
+ *       through the /set command). A few extra bits of information are 
+ *       available that don't appear in the /set list, currently they are:
+ *       * state_cursor: Current input-box cursor position (characters, 
+ *                       not bytes). Since 2.4.2.
+ *       *id:            Unique server id. Since 2.6.1.
+ * ret:  returns the string/number/boolean for the given config var
+ *       or nil on error
+ * args:
+ *       * name (string): the wanted setting's name
+ */
+static int lxc_get_prefs(lua_State *L)
+{
+	int i;
+	const char *str;
+	const char *name = luaL_checkstring(L, 1);
+	/* 
+	 * luckily we can store anything in a lua var... this makes the 
+	 * xchat lua api more user friendly ;-) 
+	 */
+	switch (xchat_get_prefs(ph, name, &str, &i)) { 
+		case 0: /* request failed */
+			lua_pushnil(L);
+			break;
+		case 1: 
+			lua_pushstring(L, str);
+			break;
+		case 2:
+			lua_pushnumber(L, (double)i);
+			break;
+		case 3:
+			lua_pushboolean(L, i);
+			break;
+		default: /* doesn't happen if xchat's C-API doesn't change ;-) */
+			lua_pushnil(L);
+			break;
+	}
+	return 1;
+}
+
+/*
+ * lua:  xchat.set_context(ctx)
+ * desc: Changes your current context to the one given. 
+ * ret:  true or false 
+ * args: 
+ *       * ctx (number): the context (e.g. from xchat.get_context())
+ */
+static int lxc_set_context(lua_State *L)
+{
+	double ctx = luaL_checknumber(L, 1);
+#ifdef DEBUG
+	fprintf(stderr, "set_context(): %#lx\n", (long)ctx);
+#endif
+	xchat_context *xc = (void *)(long)ctx;
+	lua_pushboolean(L, xchat_set_context(ph, xc));
+	return 1;
+}
+
+/*
+ * lua:  xchat.nickcmp(name1, name2)
+ * desc: Performs a nick name comparision, based on the current server 
+ *       connection. This might be a RFC1459 compliant string compare, or 
+ *       plain ascii (in the case of DALNet). Use this to compare channels 
+ *       and nicknames. The function works the same way as strcasecmp. 
+ * ret:  number ess than, equal to, or greater than zero if name1 is found, 
+ *       respectively, to be less than, to match, or be greater than name2. 
+ * args:
+ *       * name1 (string): nick or channel name
+ *       * name2 (string): nick or channel name
+ */
+static int lxc_nickcmp(lua_State *L)
+{
+	const char *n1 = luaL_checkstring(L, 1);
+	const char *n2 = luaL_checkstring(L, 2);
+	lua_pushnumber(L, (double)xchat_nickcmp(ph, n1, n2));
+	return 1;
+}
+
+/* 
+ * lua:  xchat.list_get(name)
+ * desc: http://xchat.org/docs/plugin20.html#lists :)
+ *       time_t values are stored as number => e.g.
+ *         os.date("%Y-%m-%d, %H:%M:%S", time_t_value)
+ *       pointers (channel -> context) as number... untested if this works
+ * ret:  table with tables with all keys=Name, value=(Type)... or nil on error
+ * args: 
+ *       * name (string): the wanted list
+ */
+static int lxc_list_get(lua_State *L)
+{
+	const char *name          = luaL_checkstring(L, 1); 
+	int i; /* item index */
+	int l; /* list index */
+	const char *str;
+	double      num;
+	time_t     date;
+	long        ptr;
+	const char *const *fields = xchat_list_fields(ph, name);
+	xchat_list *list          = xchat_list_get(ph, name);
+
+	if (!list) {
+		lua_pushnil(L);
+		return 1;
+	}
+	lua_newtable(L);
+	/* this is like the perl plugin does it ;-) */
+	l = 1;
+	while (xchat_list_next(ph, list)) {
+		i = 0;
+		lua_pushnumber(L, l);
+		lua_newtable(L);
+		while (fields[i] != NULL) {
+			switch (fields[i][0]) {
+				case 's':
+					str = xchat_list_str(ph, list, fields [i] + 1);
+					lua_pushstring(L, fields[i]+1);
+					if (str != NULL)
+						lua_pushstring(L, str);
+					else 
+						lua_pushnil(L);
+					lua_settable(L, -3);
+					break;
+				case 'p':
+					ptr = (long)xchat_list_str(ph, list, fields [i] + 1);
+					num = (double)ptr;
+					lua_pushstring(L, fields[i]+1);
+					lua_pushnumber(L, num);
+					lua_settable(L, -3);
+					break;
+				case 'i':
+					num = (double)xchat_list_int(ph, list, fields[i] + 1);
+					lua_pushstring(L, fields[i]+1);
+					lua_pushnumber(L, num);
+					lua_settable(L, -3);
+					break;
+				case 't':
+					date = xchat_list_time(ph, list, fields[i] + 1);
+					lua_pushstring(L, fields[i]+1);
+					lua_pushnumber(L, (double)date);
+					lua_settable(L, -3);
+					break;
+			}
+			i++;
+		}
+		lua_settable(L, -3);
+		l++;
+	}
+	xchat_list_free(ph, list);
+	return 1;
+}
+
+/*
+ * lua:  xchat.list_fields(name)
+ * desc: returns the possible keys for name as table
+ * ret:  table ;->
+ * args: 
+ *       * name (string): name of the wanted list ("channels", "dcc", 
+ *            "ignore", "notify", "users")
+ */
+static int lxc_list_fields(lua_State *L)
+{
+	const char *name = luaL_checkstring(L, 1);
+	const char *const *fields = xchat_list_fields(ph, name);
+	int i;
+
+	lua_newtable(L);
+	i = 0;
+	while (fields[i] != NULL) {
+		 lua_pushnumber(L, i);
+		 /* first char is the type ... */
+		 lua_pushstring(L, fields[i]+1);
+		 lua_settable(L, -3);
+	}
+	return 1;
+}
+
+/*
+ * lua:  xchat.gettext(str)
+ * desc: 
+ */
+static int lxc_gettext(lua_State *L)
+{
+#if defined(_WIN32) || defined(LXC_XCHAT_GETTEXT)
+	lua_pushstring(L, xchat_gettext(ph, luaL_checkstring(L, 1)));
+#else
+	const char *dom;
+	const char *msgid = luaL_checkstring(L, 1);
+	if (lua_type(L,2) == LUA_TSTRING)
+			dom = lua_tostring(L, 2);
+	else
+			dom = "xchat";
+	lua_pushstring(L, dgettext(dom, msgid));
+#endif
+	return 1;
+}
+
+/*
+ * lua:  xchat.bits(flags)
+ * desc: returns a table of booleans if the bit at index (err... index-1) is
+ *       set
+ * ret:  table of booleans
+ * args: 
+ *       * flags (number)
+  */
+static int lxc_bits(lua_State *L)
+{
+	int flags = luaL_checknumber(L, 1);
+	int i;
+	lua_pop(L, 1);
+	lua_newtable(L);
+	for (i=0; i<16; i++) { /* at time of writing, the highest index was 9 ... */
+		lua_pushnumber(L, i+1);
+		lua_pushboolean(L, ((1<<i) & flags) == 0 ? 0 : 1);
+		lua_settable(L, -3);
+	}
+	return 1;
+}
+/* 
+ * vim: ts=3 noexpandtab
+ */
diff --git a/plugins/lua/makefile.mak b/plugins/lua/makefile.mak
new file mode 100644
index 00000000..fbc94072
--- /dev/null
+++ b/plugins/lua/makefile.mak
@@ -0,0 +1,20 @@
+include "..\..\src\makeinc.mak"
+
+DIRENTLIB = ..\..\src\common\dirent.lib
+
+all: lua.obj lua.def
+	link $(LDFLAGS) $(LIBS) /dll /out:xclua.dll $(LUALIB).lib $(DIRENTLIB) /def:lua.def lua.obj 
+
+lua.def:
+	echo EXPORTS > lua.def
+	echo xchat_plugin_init >> lua.def
+	echo xchat_plugin_deinit >> lua.def
+
+lua.obj: lua.c makefile.mak
+	cl $(CFLAGS) /I.. /Dsnprintf=g_snprintf lua.c
+
+clean:
+	del *.obj
+	del *.dll
+	del *.exp
+	del *.lib
diff --git a/plugins/makefile.mak b/plugins/makefile.mak
new file mode 100644
index 00000000..d15c7f84
--- /dev/null
+++ b/plugins/makefile.mak
@@ -0,0 +1,66 @@
+all:
+	@cd checksum
+	@-$(MAKE) /nologo /s /f makefile.mak $@
+	@cd ..\lua
+	@-$(MAKE) /nologo /s /f makefile.mak $@
+	@cd ..\mpcinfo
+	@-$(MAKE) /nologo /s /f makefile.mak $@
+	@cd ..\python
+	@-$(MAKE) /nologo /s /f makefile.mak $@
+	@cd ..\tcl
+	@-$(MAKE) /nologo /s /f makefile.mak $@
+	@cd ..\upd
+	@-$(MAKE) /nologo /s /f makefile.mak $@
+#	@cd ..\xdcc
+#	@-$(MAKE) /nologo /s /f makefile.mak $@
+	@cd ..\xtray
+	@-$(MAKE) /nologo /s /f makefile.mak $@
+	@cd ..\winamp
+	@-$(MAKE) /nologo /s /f makefile.mak $@	
+
+clean:
+	@del checksum\*.def
+	@del checksum\*.dll
+	@del checksum\*.exp
+	@del checksum\*.lib
+	@del checksum\*.obj
+	@del lua\*.def
+	@del lua\*.dll
+	@del lua\*.exp
+	@del lua\*.lib
+	@del lua\*.obj
+	@del mpcinfo\*.def
+	@del mpcinfo\*.dll
+	@del mpcinfo\*.exp
+	@del mpcinfo\*.lib
+	@del mpcinfo\*.obj
+	@del python\*.def
+	@del python\*.dll
+	@del python\*.exp
+	@del python\*.lib
+	@del python\*.obj
+	@del tcl\*.def
+	@del tcl\*.dll
+	@del tcl\*.exp
+	@del tcl\*.lib
+	@del tcl\*.obj
+	@del upd\*.def
+	@del upd\*.dll
+	@del upd\*.exp
+	@del upd\*.lib
+	@del upd\*.obj
+#	@del xdcc\*.def
+#	@del xdcc\*.dll
+#	@del xdcc\*.exp
+#	@del xdcc\*.lib
+#	@del xdcc\*.obj
+	@del xtray\*.def
+	@del xtray\*.dll
+	@del xtray\*.exp
+	@del xtray\*.lib
+	@del xtray\*.obj
+	@del winamp\*.def
+	@del winamp\*.dll
+	@del winamp\*.exp
+	@del winamp\*.lib
+	@del winamp\*.obj	
diff --git a/plugins/mpcinfo/functions.c b/plugins/mpcinfo/functions.c
new file mode 100644
index 00000000..ed0632d4
--- /dev/null
+++ b/plugins/mpcinfo/functions.c
@@ -0,0 +1,167 @@
+/*
+ *  This program is free software; you can redistribute it and/or modify
+ *  it under the terms of the GNU General Public License as published by
+ *  the Free Software Foundation; either version 2 of the License, or
+ *  (at your option) any later version.
+ *
+ *  This program is distributed in the hope that it will be useful,
+ *  but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *  GNU General Public License for more details.
+ *
+ *  You should have received a copy of the GNU General Public License
+ *  along with this program; if not, write to the Free Software
+ *  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ */
+
+/*
+typedef int (*MYPROC)(HWND,HWND,char*,char*,BOOL,BOOL); 
+
+int dllProc(char *name, char *data){
+    HINSTANCE hinstLib; 
+    hinstLib = LoadLibrary("mpcinfo");
+    //MYPROC proc;
+    int res;
+    if (hinstLib != NULL){
+       //proc = ;
+       if ((MYPROC) GetProcAddress(hinstLib, name)!=NULL){
+          res=(MYPROC)(NULL,NULL,data,NULL,TRUE,TRUE);
+       }
+       else{fprintf(stderr,"can't get proc: %s\n",name);res=-2;}
+    }
+    else{fprintf(stderr,"can't access dll\n");return -1;}
+    FreeLibrary(hinstLib);
+    return res;
+}
+*/
+
+/*
+int dllProc(char *name, char *data)
+{
+	static HMODULE lib = NULL;
+	if (!lib)
+	{
+		lib = LoadLibraryA ("mpcinfo");
+		if (!lib)
+		{
+			return FALSE;
+		}
+		FreeLibrary (lib);
+	}
+
+	return TRUE;
+}
+*/
+
+char *split(char *text, char seperator){
+     //if (DEBUG==1) putlog("splitting");
+     int i;int pos=-1;
+     for (i=0;i<strlen(text);i++){
+         if (text[i]==seperator){pos=i;i=strlen(text)+1;}
+     }
+     if (pos==-1) return text;
+     text[pos]=0;
+     return &(text[pos+1]);
+}
+
+int endsWith(char *text, char *suffix){
+    char *tmp=strstr(text,suffix);
+    if (tmp==NULL) return 0;
+    if (strlen(tmp)==strlen(suffix)) return 1;
+    return 0;
+}
+
+int inStr(char *s1, int sl1, char *s2){
+    //if (DEBUG==1) putlog("checking instr");
+	int i;int j;
+	for(i=0;i<sl1-strlen(s2);i++){
+		for (j=0;j<strlen(s2);j++){
+			if (s1[i+j]!=s2[j]) j=strlen(s2)+2;
+		}
+		if (j==strlen(s2)) return i;
+	}
+	return -1;
+}
+
+static char *subString(char *text, int first, int length, int spcKill){
+//if (DEBUG==1) putlog("creating substring");
+	char *ret=(char*) calloc (length+1,sizeof(char)); //malloc(sizeof(char)*(length+1));
+	int i;
+	ret[length]=0;
+	for (i=0;i<length;i++){
+		ret[i]=text[i+first];
+		//if (ret[i]==0) ret[i]='0';
+	}
+	if (spcKill==1){
+	   for (i=length-1;i>=0;i--){
+           if (ret[i]==32) ret[i]=0;
+           else i=-1;
+       }
+    }
+    //if (DEBUG==1) putlog("substring created");
+	return ret;
+}
+
+static char *substring(char *text, int first, int length){return subString(text,first,length,0);}
+
+
+char *readLine(FILE *f){
+     //if (DEBUG==1) putlog("reading line from file");
+     char *buffer=(char*)calloc(1024,sizeof(char)); //malloc(sizeof(char)*1024);
+     int pos=0;
+     int cc=0;
+     while((cc!=EOF)&&(pos<1024)&&(cc!=10)){
+          cc=fgetc(f);
+          if ((cc!=10)&&(cc!=13)){
+             if (cc==EOF) buffer[pos]=0;
+             else buffer[pos]=(char)cc;pos++;
+          }
+     }
+     if (buffer[pos]==EOF) xchat_printf(ph,"EOF: %i\n",pos);
+     return buffer;
+}
+
+char *toUpper(char *text){
+     //if (DEBUG==1) putlog("converting text to upper case");
+     char *ret=(char*) calloc(strlen(text)+1,sizeof(char));
+     int i;
+     for (i=0;i<strlen(text);i++) ret[i]=toupper(text[i]);
+     ret[strlen(text)]=0;
+     //if (DEBUG==1) putlog("uc done");
+     return ret;
+}
+
+static char *str3cat(char *s1, char *s2, char *s3){
+       //if (DEBUG==1) putlog("cating 3 strings");
+       char *ret=(char*)calloc(strlen(s1)+strlen(s2)+strlen(s3)+1,sizeof(char));
+       strcpy(ret,s1);strcat(ret,s2);strcat(ret,s3);
+       ret[strlen(s1)+strlen(s2)+strlen(s3)]=0;
+       //if (DEBUG==1) putlog("strings cated");
+       return ret;
+}
+
+char *replace(char *text, char *from, char *to){
+     //if (DEBUG==1) putlog("replacing");
+     char *ret=(char*)calloc( strlen(text)+(strlen(to)-strlen(from)),sizeof(char));
+     char *left;
+     char *right;
+     int pos=inStr(text,strlen(text),from);
+     if (pos!=-1){
+           left=substring(text,0,pos);
+           right=substring(text,pos+strlen(from),strlen(text)-(pos+strlen(from)));          
+           ret=str3cat(left,to,right);
+           return replace(ret,from,to);
+     }
+     //if (DEBUG==1) putlog("replaced");
+     return text;
+}
+
+char *intReplaceF(char *text, char *from, int to, char *form){
+     //if (DEBUG==1) putlog("replaceF");
+     char *buffer=(char*) calloc(16,sizeof(char));
+     sprintf(buffer,form,to);
+     //if (DEBUG==1) putlog("replaceF done");
+     return replace(text,from,buffer);
+}
+
+char *intReplace(char *text, char *from, int to){return intReplaceF(text,from,to,"%i");}
diff --git a/plugins/mpcinfo/makefile.mak b/plugins/mpcinfo/makefile.mak
new file mode 100644
index 00000000..4a8a2763
--- /dev/null
+++ b/plugins/mpcinfo/makefile.mak
@@ -0,0 +1,18 @@
+include "..\..\src\makeinc.mak"
+
+all: mpcinfo.obj mpcinfo.def
+	link $(LDFLAGS) $(LIBS) /dll /out:xcmpcinfo.dll /def:mpcinfo.def mpcinfo.obj
+
+mpcinfo.def:
+	echo EXPORTS > mpcinfo.def
+	echo xchat_plugin_init >> mpcinfo.def
+	echo xchat_plugin_deinit >> mpcinfo.def
+
+mpcinfo.obj: mpcinfo.c makefile.mak
+	cl $(CFLAGS) $(GLIB) /I.. mpcinfo.c
+
+clean:
+	del *.obj
+	del *.dll
+	del *.exp
+	del *.lib
diff --git a/plugins/mpcinfo/mp3Info.c b/plugins/mpcinfo/mp3Info.c
new file mode 100644
index 00000000..f75ba9c4
--- /dev/null
+++ b/plugins/mpcinfo/mp3Info.c
@@ -0,0 +1,361 @@
+/*
+ *  This program is free software; you can redistribute it and/or modify
+ *  it under the terms of the GNU General Public License as published by
+ *  the Free Software Foundation; either version 2 of the License, or
+ *  (at your option) any later version.
+ *
+ *  This program is distributed in the hope that it will be useful,
+ *  but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *  GNU General Public License for more details.
+ *
+ *  You should have received a copy of the GNU General Public License
+ *  along with this program; if not, write to the Free Software
+ *  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ */
+
+//#include <stdio.h>
+#include <sys/stat.h>
+//#include "functions.c"
+
+struct tagInfo{
+	int mode;
+	int cbr;
+	int bitrate;
+	unsigned int freq;
+	char *artist;
+	char *title;
+	char *album;
+	char *comment;
+	char *genre;
+	//int genre;
+	//int track;
+};
+
+static int RATES[2][3][15]={
+				{//mpeg2
+                    {-1,8,16,24,32,64,80,56,64,128,160,112,128,256,320},//layer3 (V2)    
+					{-1,32,48,56,64,80,96,112,128,160,192,224,256,320,384},//layer2 (V2)
+					{-1,32,64,96,128,160,192,224,256,288,320,352,384,416,448},//layer1 (V2)
+                },
+                {//mpeg1
+					{-1,32,40,48,56,64,80,96,112,128,160,192,224,256,320},//layer3 (V1)
+					{-1,32,48,56,64,80,96,112,128,160,192,224,256,320,384},//layer2 (V1)
+                    {-1,32,64,96,128,160,192,224,256,288,320,352,384,416,448},//layer1 (V1)
+        }};
+static int FREQS[2][4]={{22050,24000,16000,-1},{44100,48000,32000,-1}};
+//static double FRATES[]={38.5,32.5,27.8,0.0};
+
+static char GENRES[][50]={"Blues","Classic Rock","Country","Dance","Disco","Funk","Grunge","Hip-Hop","Jazz","Metal",
+"New Age","Oldies","Other","Pop","R&B","Rap","Reggae","Rock","Techno","Industrial",
+"Alternative","Ska","Death Metal","Pranks","Soundtrack","Euro-Techno","Ambient","Trip-Hop","Vocal","Jazz+Funk",
+"Fusion","Trance","Classical","Instrumental","Acid","House","Game","Sound Clip","Gospel","Noise",
+"AlternRock","Bass","Soul","Punk","Space","Meditative","Instrumental Pop","Instrumental Rock","Ethnic","Gothic",
+"Darkwave","Techno-Industrial","Electronic","Pop-Folk","Eurodance","Dream","Southern Rock","Comedy","Cult","Gangsta",
+"Top 40","Christian Rap","Pop/Funk","Jungle","Native American","Cabaret","New Wave","Psychadelic","Rave","Showtunes",
+"Trailer","Lo-Fi","Tribal","Acid Punk","Acid Jazz","Polka","Retro","Musical","Rock & Roll","Hard Rock",
+
+//################## END OF OFFICIAL ID3 TAGS, WINAMP TAGS BELOW ########################################
+
+"Folk","Folk/Rock","National Folk","Swing","Fast Fusion","Bebob","Latin","Revival","Celtic","Bluegrass",
+"Avantgarde","Gothic Rock","Progressive Rock","Psychedelic Rock","Symphonic Rock","Slow Rock","Big Band","Chorus","Easy Listening","Acoustic",
+"Humour","Speech","Chanson","Opera","Chamber Music","Sonata","Symphony","Booty Bass","Primus","Porn Groove",
+"Satire","Slow Jam","Club","Tango","Samba","Folklore","Ballad","Poweer Ballad","Rhytmic Soul","Freestyle",
+"Duet","Punk Rock","Drum Solo","A Capela","Euro-House","Dance Hall",
+
+//################## FOUND AT http://en.wikipedia.org/wiki/ID3 ###########################################
+
+"Goa","Drum & Bass","Club-House","Hardcore",
+"Terror","Indie","BritPop","Negerpunk","Polsk Punk","Beat","Christian Gangsta Rap","Heavy Metal","Black Metal","Crossover",
+"Contemporary Christian","Christian Rock","Merengue","Salsa","Thrash Metal","Anime","JPop","Synthpop"
+
+};
+
+static char MODES [][13]={"Stereo","Joint-Stereo","Dual-Channel","Mono"};
+
+int iPow(int x, int y){return (int)(pow((double)x,(double) y));}
+
+int str2int(char *text){
+    //if (DEBUG==1) putlog("converting string to int");
+    int i;
+    int ret=0;
+    for (i=1;i<=strlen(text);i++){
+        if ((text[strlen(text)-i]>57)||(text[strlen(text)-i]<48)){
+           xchat_printf(ph,"invalid char in string: %i",text[strlen(text)-i]);
+           return 255;
+        }
+        ret+=((int)text[strlen(text)-i]-48)*iPow(10,i-1);
+    }
+    //xchat_printf(ph, "str2int(%s)=%i",text,ret);
+    //if (DEBUG==1) putlog("int converted");
+    return ret;
+}
+/*
+static int getSize(char *file){
+    //if (DEBUG==1) putlog("reading filesize");
+	struct stat info;
+	if (stat(file,&info)!=0) return -1;
+	return info.st_size;
+}*/
+/*
+int inStr(char *s1, int sl1, char *s2){
+    //if (DEBUG==1) putlog("checking instr");
+	int i;int j;
+	for(i=0;i<sl1-strlen(s2);i++){
+		for (j=0;j<strlen(s2);j++){
+			if (s1[i+j]!=s2[j]) j=strlen(s2)+2;
+		}
+		if (j==strlen(s2)) return i;
+	}
+	return -1;
+}
+
+static char *subString(char *text, int first, int length, int spcKill){
+//if (DEBUG==1) putlog("creating substring");
+	char *ret=(char*) calloc (length+1,sizeof(char)); //malloc(sizeof(char)*(length+1));
+	ret[length]=0;int i;
+	for (i=0;i<length;i++){
+		ret[i]=text[i+first];
+		//if (ret[i]==0) ret[i]='0';
+	}
+	if (spcKill==1){
+	   for (i=length-1;i>=0;i--){
+           if (ret[i]==32) ret[i]=0;
+           else i=-1;
+       }
+    }
+    //if (DEBUG==1) putlog("substring created");
+	return ret;
+}
+
+static char *substring(char *text, int first, int length){return subString(text,first,length,0);} //1
+*/
+
+static char *tagExtract(char *tag, int tagLen, char* info){
+//if (DEBUG==1) putlog("extracting tag");
+	int pos, len, i;
+	pos=inStr(tag,tagLen,info);
+//xchat_printf(ph,"pos=%i",pos);
+	if (pos==-1) return "";//NULL;
+	//printf("position of %s = %i\n",info,pos);
+	len=0;
+	//for (i=pos;i<pos+10;i++)printf("tag[%i]=%i \n",i,tag[i]);
+	for (i=0;i<4;i++) {
+		len+=tag[pos+strlen(info)+i]*iPow(255,3-i);
+	}
+	//printf("Tag-Length: %i\n",len);
+	if (strcmp("COMM",info)!=0) return substring(tag,pos+7+strlen(info),len-1);//11
+	return substring(tag,pos+7+strlen(info),len-1);//11
+	//char *ct=substring(tag,pos+7+strlen(info),len-1);//11
+	//return substring(ct,strlen(ct)+1,len-1-strlen(ct)); //<-- do not understand, what i did here :(
+	
+}
+
+struct tagInfo readID3V1(char *file){
+//if (DEBUG==1) putlog("reading ID3V1");
+	FILE *f;
+	struct tagInfo ret;
+	int res, i, c, val;
+	char *tag;
+	char *id;
+	char *tmp;
+	tag = (char*) malloc(sizeof(char)*129);
+	ret.artist=NULL;
+	f=fopen(file,"rb");
+	if (f==NULL){
+       xchat_print(ph,"file not found while trying to read id3v1");
+       //if (DEBUG==1) putlog("file not found while trying to read id3v1");
+       return ret;
+    }
+	//int offset=getSize(file)-128;
+	res=fseek(f,-128,SEEK_END);
+	if (res!=0) {printf("seek failed\n");fclose(f);return ret;}
+	//long int pos=ftell(f);
+	//printf("position= %li\n",pos);
+	for (i=0;i<128;i++) {
+		c=fgetc(f);
+		if (c==EOF) {xchat_printf(ph,"read ID3V1 failed\n");fclose(f);return ret;}
+		tag[i]=(char)c;
+	}
+	fclose(f);
+	//printf("tag readed: \n");
+	id=substring(tag,0,3);
+	//printf("header: %s\n",id);
+	if (strcmp(id,"TAG")!=0){xchat_printf(ph,"no id3 v1 found\n");return ret;}
+	ret.title=subString(tag,3,30,1);
+	ret.artist=subString(tag,33,30,1);
+	ret.album=subString(tag,63,30,1);
+	ret.comment=subString(tag,97,30,1);
+	tmp=substring(tag,127,1);
+	//ret.genre=substring(tag,127,1);
+	
+	val=(int)tmp[0];
+	if (val<0)val+=256;
+	//xchat_printf(ph, "tmp[0]=%i (%i)",val,tmp[0]);
+	if ((val<148)&&(val>=0)) 
+       ret.genre=GENRES[val];//#############changed
+	else {
+         ret.genre="unknown";
+         //xchat_printf(ph, "tmp[0]=%i (%i)",val,tmp[0]);
+    }
+	//xchat_printf(ph, "tmp: \"%s\" -> %i",tmp,tmp[0]);
+	//xchat_printf(ph,"genre \"%s\"",ret.genre);
+	//if (DEBUG==1) putlog("id3v1 extracted");
+	return ret;
+}
+
+char *extractID3Genre(char *tag){
+     //if (DEBUG==1) putlog("extracting id3 genre");
+     if (tag[strlen(tag)-1]==')'){
+        tag[strlen(tag)-1]=0;
+        tag=&tag[1];
+        return GENRES[str2int(tag)];
+        //return tag;
+     }
+     else{
+          int i;
+          //xchat_print(ph, "Using 2 criteria");
+          for (i=0;i<strlen(tag);i++){
+              if (tag[i]==')'){ tag=&tag[i]+1;return tag;}
+          //return tag;
+          }
+     }
+     return "[152] failed";
+}
+
+struct tagInfo readID3V2(char *file){
+//if (DEBUG==1) putlog("reading id3v2");
+	FILE *f;
+	int i, c, len;
+	char header[10];
+	char *tag;
+	struct tagInfo ret;
+
+	f = fopen(file,"rb");
+	//xchat_printf(ph,"file :%s",file);
+	if (f==NULL)
+	{
+       xchat_print(ph,"file not found whilt trying to read ID3V2");
+       //if (DEBUG==1)putlog("file not found while trying to read ID3V2");
+       return ret;
+    }
+
+	ret.artist=NULL;
+	for (i=0;i<10;i++){
+        c=fgetc(f);
+        if (c==EOF){
+           //putlog("found eof while reading id3v2");
+           return ret;
+        }
+        header[i]=(char)c;
+    }
+	if (strstr(header,"ID3")==header){
+		//xchat_printf(ph,"found id3v2\n");
+		len=0;
+		for (i=6;i<10;i++) len+=(int)header[i]*iPow(256,9-i);
+		
+		//char *tag=(char*)malloc(sizeof(char)*len);
+		tag=(char*) calloc(len,sizeof(char)); //malloc(sizeof(char)*len);
+		for (i=0;i<len;i++){c=fgetc(f);tag[i]=(char)c;}
+//xchat_printf(ph,"tag length: %i\n",len);
+//xchat_printf(ph,"tag: %s\n",tag);
+		fclose(f);
+		ret.comment=tagExtract(tag,len,"COMM");
+//xchat_printf(ph,"Comment: %s\n",ret.comment);
+		ret.genre=tagExtract(tag,len,"TCON");
+		//if (strcmp(ret.genre,"(127)")==0) ret.genre="unknown";
+//xchat_printf(ph, "ret.genre = %s",ret.genre);
+		if ((ret.genre!=NULL)&&(ret.genre[0]=='(')) ret.genre=extractID3Genre(ret.genre);
+//xchat_printf(ph,"genre: %s\n",ret.genre);
+		ret.title=tagExtract(tag,len,"TIT2");
+//xchat_printf(ph,"Title: %s\n",ret.title);
+		ret.album=tagExtract(tag,len,"TALB");
+//xchat_printf(ph,"Album: %s\n",ret.album);
+		ret.artist=tagExtract(tag,len,"TPE1");
+//xchat_printf(ph,"Artist: %s\n",ret.artist);
+	}
+	else{fclose(f);printf("no id3v2 tag found\n"); return ret;}
+	//printf("id2v2 done\n");
+	//if (DEBUG==1) putlog("id3v2 readed");
+	return ret;
+}
+
+struct tagInfo readHeader(char *file){
+//if (DEBUG==1) putlog("reading header");
+	FILE *f;
+	//int buffer[5120];
+	int versionB, layerB, bitrateB, freqB, modeB;
+	int header[4];
+	int count=0;
+	int cc=0;
+	struct tagInfo info;
+	info.artist=NULL;
+
+	f = fopen(file,"rb");
+	if (f==NULL)
+	{
+       xchat_print(ph,"file not found while trying to read mp3 header");
+       //if (DEBUG==1) putlog("file not found while trying to read mp3 header");
+       return info;
+    }
+	//struct tagInfo tagv2
+	
+	info=readID3V2(file);
+	//struct tagInfo tagv1;//=readID3V1(file);
+	//if 	(tagv2.artist!=NULL){info=tagv2;}
+	//else {
+	if (info.artist==NULL){
+		//printf("searching for id3v1\n");
+		//tagv1=readID3V1(file);
+		info=readID3V1(file); //#####################
+	}
+	/*
+	if (tagv1.artist!=NULL){
+		//printf("Artist: %s\nTitle: %s\nAlbum: %s\nComment: %s\nGenre: %s\n",tagv1.artist,tagv1.title,tagv1.album,tagv1.comment,tagv1.genre);
+		info=tagv1;
+	}
+	*/
+	while ((count<5120)&&(cc!=EOF)&&(cc!=255)) {cc=fgetc(f);count++;}
+	if ((cc==EOF)||(count==5119)) printf("no header found\n");
+	else {
+		//printf("located header at %i\n",count);
+		header[0]=255;
+		for (count=1;count<4;count++){
+			header[count]=fgetc(f);
+			//printf("header[%i]=%i\n",count,header[count]);
+		}
+		versionB=(header[1]&8)>>3;
+		layerB=(header[1]&6)>>1;
+		bitrateB=(header[2]&240)>>4; //4
+		freqB=(header[2]&12)>>2;//2
+		modeB=(header[3]&192)>>6;//6
+		//printf("Mpeg: %i\nLayer: %i\nBitrate: %i\nFreq: %i\nMode: %i\n",versionB, layerB, bitrateB, freqB, modeB);
+		//int Bitrate=RATES[versionB][layerB-1][bitrateB];
+		//int Freq=FREQS[versionB][freqB];
+		info.bitrate=RATES[versionB][layerB-1][bitrateB];
+		info.freq=FREQS[versionB][freqB];
+		info.mode=modeB;	
+	}
+	fclose(f);
+	//if (DEBUG==1) putlog("header readed");
+	return info;
+}
+/*
+static void printMp3Info(char *file){
+	//printf("\nScanning Mp3-File for Informations: %s\n",file);
+	//printf("size:\t%10d byte\n",getSize(file));
+	struct tagInfo info =readHeader(file);
+	printf("%s | %10d",file,getSize(file));
+	if  (info.bitrate>0){
+		//printf("Bitrate: %i\nFreq: %i\nMode: %s\n",info.bitrate,info.freq,MODES[info.mode]);
+		printf(" | %i kbps | %i kHz | %s",info.bitrate,info.freq,MODES[info.mode]);
+		//if (info.artist!=NULL) printf("\nArtist: %s\nTitle: %s\nAlbum: %s\nComment: %s\nGenre: %s\n",info.artist,info.title,info.album,info.comment,info.genre);
+		if (info.artist!=NULL) {
+			printf("| %s | %s | %s | %s | %s",info.artist,info.title,info.album,info.comment,info.genre);
+			//printf("| %s ",info.title);//,info.title,info.album,info.comment,info.genre
+		}
+	}
+	printf("\n");
+	
+}
+*/
diff --git a/plugins/mpcinfo/mpcInfo.c b/plugins/mpcinfo/mpcInfo.c
new file mode 100644
index 00000000..e467e516
--- /dev/null
+++ b/plugins/mpcinfo/mpcInfo.c
@@ -0,0 +1,149 @@
+/*
+ *  This program is free software; you can redistribute it and/or modify
+ *  it under the terms of the GNU General Public License as published by
+ *  the Free Software Foundation; either version 2 of the License, or
+ *  (at your option) any later version.
+ *
+ *  This program is distributed in the hope that it will be useful,
+ *  but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *  GNU General Public License for more details.
+ *
+ *  You should have received a copy of the GNU General Public License
+ *  along with this program; if not, write to the Free Software
+ *  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ */
+
+//static int DEBUG=0;
+static char *VERSION="0.0.6";
+
+#include <windows.h>
+#include <stdlib.h>
+#include <string.h>
+#include <stdio.h>
+#include <ctype.h>
+#include <math.h>
+#include "xchat-plugin.h"
+static xchat_plugin *ph;
+
+#include "functions.c"
+#include "mp3Info.c"
+#include "oggInfo.c"
+#include "theme.c"
+
+static int print_themes (char *word[], char *word_eol[], void *userdata){
+       printThemes();
+       return XCHAT_EAT_ALL;
+}
+
+static int mpc_themeReload(char *word[], char *word_eol[], void *userdata){
+   themeInit();
+   loadThemes();
+   return XCHAT_EAT_ALL;
+}
+
+static int mpc_tell(char *word[], char *word_eol[], void *userdata){
+       char *tTitle, *zero, *oggLine, *line;
+	   struct tagInfo info;
+	   HWND hwnd = FindWindow("MediaPlayerClassicW",NULL);
+       if (hwnd==0) {xchat_command(ph, randomLine(notRunTheme));return XCHAT_EAT_ALL;}
+       
+       tTitle=(char*)malloc(sizeof(char)*1024);
+       GetWindowText(hwnd, tTitle, 1024);
+       zero=strstr(tTitle," - Media Player Classic");
+       if (zero!=NULL) zero[0]=0;
+       else xchat_print(ph,"pattern not found");
+       
+       if ((tTitle[1]==':')&&(tTitle[2]=='\\')){
+          //xchat_print(ph,"seams to be full path");
+          if (endsWith(tTitle,".mp3")==1){
+             //xchat_print(ph,"seams to be a mp3 file");
+             info = readHeader(tTitle);
+             
+             if ((info.artist!=NULL)&&(strcmp(info.artist,"")!=0)){
+                char *mode=MODES[info.mode];
+                //xchat_printf(ph,"mode: %s\n",mode);
+                char *mp3Line=randomLine(mp3Theme);
+                mp3Line=replace(mp3Line,"%art",info.artist);
+                mp3Line=replace(mp3Line,"%tit",info.title);
+                mp3Line=replace(mp3Line,"%alb",info.album);
+                mp3Line=replace(mp3Line,"%com",info.comment);
+                mp3Line=replace(mp3Line,"%gen",info.genre);
+                //mp3Line=replace(mp3Line,"%time",pos);
+                //mp3Line=replace(mp3Line,"%length",len);
+                //mp3Line=replace(mp3Line,"%ver",waVers);
+                //mp3Line=intReplace(mp3Line,"%br",br);
+                //mp3Line=intReplace(mp3Line,"%frq",frq);
+                
+                mp3Line=intReplace(mp3Line,"%br",info.bitrate);
+                mp3Line=intReplace(mp3Line,"%frq",info.freq);
+                mp3Line=replace(mp3Line,"%mode",mode);
+                //mp3Line=replace(mp3Line,"%size",size);
+                //mp3Line=intReplace(mp3Line,"%perc",perc);
+                //mp3Line=replace(mp3Line,"%plTitle",title);
+                mp3Line=replace(mp3Line,"%file",tTitle);
+                xchat_command(ph, mp3Line);
+                return XCHAT_EAT_ALL;
+             }
+          }
+          if (endsWith(tTitle,".ogg")==1){
+             xchat_printf(ph,"Ogg detected\n");
+             info = getOggHeader(tTitle);
+             if (info.artist!=NULL){
+                char *cbr;
+                if (info.cbr==1) cbr="CBR"; else cbr="VBR";
+                oggLine=randomLine(oggTheme);
+                //if (cue==1) oggLine=cueLine;
+                //xchat_printf(ph,"ogg-line: %s\n",oggLine);
+                oggLine=replace(oggLine,"%art",info.artist);
+                oggLine=replace(oggLine,"%tit",info.title);
+                oggLine=replace(oggLine,"%alb",info.album);
+                oggLine=replace(oggLine,"%com",info.comment);
+                oggLine=replace(oggLine,"%gen",info.genre);
+                //oggLine=replace(oggLine,"%time",pos);
+                //oggLine=replace(oggLine,"%length",len);
+                //oggLine=replace(oggLine,"%ver",waVers);
+                oggLine=intReplace(oggLine,"%chan",info.mode);
+                oggLine=replace(oggLine,"%cbr",cbr);
+                oggLine=intReplace(oggLine,"%br",info.bitrate/1000);//br);
+                oggLine=intReplace(oggLine,"%frq",info.freq);
+                //oggLine=replace(oggLine,"%size",size);
+                //oggLine=intReplace(oggLine,"%perc",perc);
+                //oggLine=replace(oggLine,"%plTitle",title);
+                oggLine=replace(oggLine,"%file",tTitle);
+                xchat_command(ph, oggLine);
+                return XCHAT_EAT_ALL;
+             }
+          }
+       }
+       line=randomLine(titleTheme);
+       line=replace(line,"%title", tTitle);
+       xchat_command(ph,line); 
+       return XCHAT_EAT_ALL;
+}
+
+int xchat_plugin_init(xchat_plugin *plugin_handle, char **plugin_name, char **plugin_desc, char **plugin_version, char *arg){
+	ph = plugin_handle;
+	*plugin_name = "mpcInfo";
+	*plugin_desc = "Information-Script for Media Player Classic"; 
+	*plugin_version=VERSION;
+
+	xchat_hook_command(ph, "mpc", XCHAT_PRI_NORM, mpc_tell,"no help text", 0);
+	xchat_hook_command(ph, "mpc_themes", XCHAT_PRI_NORM, print_themes,"no help text", 0);
+	xchat_hook_command(ph, "mpc_reloadthemes", XCHAT_PRI_NORM, mpc_themeReload,"no help text", 0);
+	xchat_command (ph, "MENU -ietc\\music.png ADD \"Window/Display Current Song (MPC)\" \"MPC\"");
+
+	themeInit();
+	loadThemes();
+	xchat_printf(ph, "%s %s plugin loaded\n",*plugin_name, VERSION);
+
+	return 1;
+}
+
+int
+xchat_plugin_deinit (void)
+{
+	xchat_command (ph, "MENU DEL \"Window/Display Current Song (MPC)\"");
+	xchat_print (ph, "mpcInfo plugin unloaded\n");
+	return 1;
+}
diff --git a/plugins/mpcinfo/oggInfo.c b/plugins/mpcinfo/oggInfo.c
new file mode 100644
index 00000000..83c2beb5
--- /dev/null
+++ b/plugins/mpcinfo/oggInfo.c
@@ -0,0 +1,122 @@
+/*
+ *  This program is free software; you can redistribute it and/or modify
+ *  it under the terms of the GNU General Public License as published by
+ *  the Free Software Foundation; either version 2 of the License, or
+ *  (at your option) any later version.
+ *
+ *  This program is distributed in the hope that it will be useful,
+ *  but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *  GNU General Public License for more details.
+ *
+ *  You should have received a copy of the GNU General Public License
+ *  along with this program; if not, write to the Free Software
+ *  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ */
+
+static int getOggInt(char *buff, int beg, int bytes){
+//if (DEBUG==1) putlog("getOggInt");
+	int ret=0;
+	int i;
+	for (i=0;i<bytes;i++){
+		if (buff[i+beg]>=0) ret+=buff[i+beg]*iPow(256,i);else ret+=(256+buff[i+beg])*iPow(256,i);
+		//printf("[%i]=%i\n",i,buff[i+beg]);
+	}
+	return ret;
+}
+
+static char *upperStr(char *text){
+//if (DEBUG==1) putlog("converting text to uc");
+    //printf("upperStr(%s)\n",text);
+	int i;
+	char *ret=(char*) malloc(sizeof(char)*(strlen(text)+1));
+	ret[strlen(text)]=0;
+	for (i=0;i<strlen(text);i++) ret[i]=toupper(text[i]);
+	//printf("Result: %s\n",ret);
+	return ret;
+}
+
+struct tagInfo getOggHeader(char *file){
+//if (DEBUG==1) putlog("reading ogg header");
+	char header[4096];
+	int i, c;
+	int h1pos, h3pos, maxBr, nomBr, minBr, pos, count, tagLen;
+	char *sub;
+	char *name;
+	char *val;
+	char *HEADLOC1, *HEADLOC3, *HEADLOC5;
+	FILE *f;
+	struct tagInfo info;
+
+	info.artist=NULL;
+	f = fopen(file,"rb");
+	if (f==NULL){
+       xchat_print(ph,"file not found while trying to read ogg header");
+       //if (DEBUG==1) putlog("file not found while trying to read ogg header");
+       return info;
+    }
+
+	for (i=0;i<4095;i++) {c=fgetc(f);header[i]=(char)c;}
+	fclose(f);
+	HEADLOC1="_vorbis";
+	HEADLOC1[0]=1;
+	HEADLOC3="_vorbis";
+	HEADLOC3[0]=3;
+	HEADLOC5="_vorbis";
+	HEADLOC5[0]=5;
+	h1pos=inStr(header,4096,HEADLOC1);
+	h3pos=inStr(header,4096,HEADLOC3);
+	//int h5pos=inStr(header,4096,HEADLOC5); //not needed
+	
+	//printf("loc1: %i\n",h1pos);printf("loc3: %i\n",h3pos);printf("loc5: %i\n",h5pos);
+	maxBr=getOggInt(header,h1pos+7+9,4);
+	nomBr=getOggInt(header,h1pos+7+13,4);
+	minBr=getOggInt(header,h1pos+7+17,4);
+	info.freq=getOggInt(header,h1pos+7+5,4);
+	info.mode=header[h1pos+7+4];
+	info.bitrate=nomBr;
+	if (((maxBr==nomBr)&&(nomBr=minBr))||((minBr==0)&&(maxBr==0))||((minBr=-1)&&(maxBr=-1)) )info.cbr=1;else info.cbr=0;
+	printf("bitrates: %i|%i|%i\n",maxBr,nomBr,minBr);
+	printf("freq: %i\n",info.freq);
+	pos=h3pos+7;
+	pos+=getOggInt(header,pos,4)+4;
+	count=getOggInt(header,pos,4);
+	//printf("tags: %i\n",count);
+	pos+=4;
+
+	info.artist=NULL;info.title=NULL;info.album=NULL;info.comment=NULL;info.genre=NULL;
+	for (i=0;i<count;i++){
+		tagLen=getOggInt(header,pos,4);
+		//printf("taglength: %i\n",tagLen);
+		sub=substring(header,pos+4,tagLen);
+		name=upperStr(substring(sub,0,inStr(sub,tagLen,"=")));
+		val=substring(sub,inStr(sub,tagLen,"=")+1,tagLen-inStr(sub,tagLen,"=")-1);
+		//printf("Tag: %s\n",sub);
+		//printf("Name: %s\n",name);
+		//printf("value: %s\n",val);
+		if (strcmp(name,"ARTIST")==0) info.artist=val;
+		if (strcmp(name,"TITLE")==0) info.title=val;
+		if (strcmp(name,"ALBUM")==0) info.album=val;
+		if (strcmp(name,"GENRE")==0) info.genre=val;
+		if (strcmp(name,"COMMENT")==0) info.comment=val;
+		pos+=4+tagLen;
+	}
+	if (info.artist==NULL) info.artist="";
+	if (info.album==NULL) info.album ="";
+	if (info.title==NULL) info.title="";
+	if (info.genre==NULL) info.genre="";
+	if (info.comment==NULL) info.comment="";
+	
+	printf("Artist: %s\nTitle: %s\nAlbum: %s\n",info.artist,info.title, info.album);
+	printf("Genre: %s\nComment: %s\nMode: %i\nCBR: %i\n",info.genre,info.comment,info.mode,info.cbr);
+	//if (DEBUG==1) putlog("ogg header readed");
+	return info;
+}
+
+/*
+void printOggInfo(char *file){
+	printf("Scanning Ogg-File for Informations: %s\n",file);
+	printf("size:\t%10d byte\n",getSize(file));
+	struct tagInfo info = getOggHeader(file);
+}
+*/
diff --git a/plugins/mpcinfo/theme.c b/plugins/mpcinfo/theme.c
new file mode 100644
index 00000000..000c00b1
--- /dev/null
+++ b/plugins/mpcinfo/theme.c
@@ -0,0 +1,136 @@
+/*
+ *  This program is free software; you can redistribute it and/or modify
+ *  it under the terms of the GNU General Public License as published by
+ *  the Free Software Foundation; either version 2 of the License, or
+ *  (at your option) any later version.
+ *
+ *  This program is distributed in the hope that it will be useful,
+ *  but WITHOUT ANY WARRANTY; without even the implied warranty of
+ *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ *  GNU General Public License for more details.
+ *
+ *  You should have received a copy of the GNU General Public License
+ *  along with this program; if not, write to the Free Software
+ *  Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+ */
+
+#include <time.h>
+
+struct theme{
+       int size;
+       char **line;
+};
+
+static struct theme notRunTheme;
+static struct theme titleTheme;
+static struct theme mp3Theme;
+static struct theme oggTheme;
+
+
+void themeInit(){
+     //if (DEBUG==1) putlog("init theme");
+     /*mp3Theme.size=0;oggTheme.size=0;cueTheme.size=0;streamTheme.size=0;etcTheme.size=0;
+     stopTheme.size=0;pauseTheme.size=0;*/
+     
+     notRunTheme.size=0;titleTheme.size=0;
+     srand((unsigned int)time((time_t *)NULL));
+     //if (DEBUG==1) putlog("theme init done");
+}
+
+void printTheme(struct theme data){
+     int i;
+     for (i=0;i<data.size;i++) xchat_printf(ph,"line[%i]=%s\n",i,data.line[i]);
+}
+
+void printThemes(){
+     xchat_printf(ph,"\nNotRun-Theme:\n");printTheme(notRunTheme);
+     xchat_printf(ph,"\nMP3-Theme:\n");printTheme(mp3Theme);
+     xchat_printf(ph,"\nOGG-Theme:\n");printTheme(oggTheme);
+     xchat_printf(ph,"\nTitle-Theme:\n");printTheme(titleTheme);
+}
+
+void cbFix(char *line){
+     //if (DEBUG==1) putlog("cbfix");
+     int i, j;
+     for (i=0;i<strlen(line);i++){
+         if (line[i]=='%'){
+            if ((line[i+1]=='C')||(line[i+1]=='B')||(line[i+1]=='U')||(line[i+1]=='O')||(line[i+1]=='R')){
+               if(line[i+1]=='C') line[i]=3;
+               if(line[i+1]=='B') line[i]=2;
+               if(line[i+1]=='U') line[i]=37;
+               if(line[i+1]=='O') line[i]=17;
+               if(line[i+1]=='R') line[i]=26;
+
+               for (j=i+1;j<strlen(line)-1;j++) line[j]=line[j+1];
+               line[strlen(line)-1]=0;
+            }
+         }
+     }
+     //if (DEBUG==1) putlog("cbfix done");
+}
+
+struct theme themeAdd(struct theme data, char *info){
+       //if (DEBUG==1) putlog("adding theme");
+       struct theme ret;
+       char **newLine=(char **)calloc(data.size+1,sizeof(char*));
+       int i;
+       for (i=0;i<data.size;i++) newLine[i]=data.line[i];
+       cbFix(info);
+       newLine[data.size]=info;
+       ret.line=newLine;ret.size=data.size+1;
+       //if (DEBUG==1) putlog("theme added");
+       return ret;
+}
+
+void loadThemes(){
+    char *hDir, *hFile, *line, *val;
+	FILE *f;
+	xchat_print(ph,"loading themes\n");
+    hDir=(char*)calloc(1024,sizeof(char));
+    strcpy(hDir,xchat_get_info(ph,"xchatdirfs"));
+    hFile=str3cat(hDir,"\\","mpcInfo.theme.txt");
+    f = fopen(hFile,"r");
+    if(f==NULL)
+	{
+		xchat_print(ph,"no theme in homedir, checking global theme");
+		f=fopen("mpcInfo.theme.txt","r");
+    }
+	//xchat_printf(ph,"file_desc: %p\n",f);
+	if (f==NULL) xchat_print(ph, "no theme found, using hardcoded\n");
+	else {
+		if (f > 0)
+		{
+			line=" ";
+		} else
+		{
+			line="\0";
+		}
+
+		while (line[0]!=0)
+		{
+			line=readLine(f);
+			val=split(line,'=');
+			printf("line: %s\n",line);
+			printf("val: %s\n",val);
+			if (strcmp(toUpper(line),"OFF_LINE")==0) notRunTheme=themeAdd(notRunTheme,val);
+			if (strcmp(toUpper(line),"TITLE_LINE")==0) titleTheme=themeAdd(titleTheme,val);
+			if (strcmp(toUpper(line),"MP3_LINE")==0) mp3Theme=themeAdd(mp3Theme,val);
+			if (strcmp(toUpper(line),"OGG_LINE")==0) mp3Theme=themeAdd(oggTheme,val);
+		}
+		fclose(f);
+		xchat_print(ph, "theme loaded successfull\n");
+	}
+	if (notRunTheme.size==0) notRunTheme=themeAdd(notRunTheme,"say Media Player Classic not running");
+	if (titleTheme.size==0) titleTheme=themeAdd(titleTheme,"say Playing %title in Media Player Classic");
+	if (mp3Theme.size==0) mp3Theme=themeAdd(mp3Theme,"me listens to %art with %tit from %alb [%gen|%br kbps|%frq kHz|%mode] in Media Player Classic ");
+	if (oggTheme.size==0) oggTheme=themeAdd(oggTheme,"me listens to %art with %tit from %alb [%gen|%br kbps|%frq kHz|%chan channels] in Media Player Classic ");
+	//mp3Theme=themeAdd(mp3Theme,"me listens to %art with %tit from %alb [%time|%length|%perc%|%br kbps|%frq kHz|%mode] in Media Player Classic ");
+}
+
+int rnd(int max){
+    return rand()%max;
+}
+
+char *randomLine(struct theme data){
+     return data.line[rnd(data.size)];
+}
diff --git a/plugins/perl/makefile-510.mak b/plugins/perl/makefile-510.mak
new file mode 100644
index 00000000..60f6b2dc
--- /dev/null
+++ b/plugins/perl/makefile-510.mak
@@ -0,0 +1,30 @@
+include "..\..\src\makeinc.mak"
+
+DIRENTLIB = ..\..\src\common\dirent.lib
+TARGET = $(PERL510OUTPUT)
+
+all: $(TARGET)
+
+perl.def:
+	echo EXPORTS > perl.def
+	echo xchat_plugin_init >> perl.def
+	echo xchat_plugin_deinit >> perl.def
+	echo xchat_plugin_get_info >> perl.def
+
+perl.obj: perl.c
+	$(CC) $(CFLAGS) perl.c $(GLIB) /I$(PERL510PATH) /I.. /DPERL_DLL=\"$(PERL510LIB).dll\"
+
+perl.c: xchat.pm.h
+
+xchat.pm.h: lib/Xchat.pm lib/IRC.pm
+	perl.exe generate_header
+
+$(TARGET): perl.obj perl.def
+	$(LINK) /DLL /out:$(TARGET) perl.obj $(LDFLAGS) $(PERL510LIB).lib /libpath:$(PERL510PATH) /DELAYLOAD:$(PERL510LIB).dll $(DIRENTLIB) DELAYIMP.LIB user32.lib shell32.lib advapi32.lib /def:perl.def
+
+clean:
+	@del $(TARGET)
+	@del *.obj
+	@del perl.def
+	@del *.lib
+	@del *.exp
diff --git a/plugins/perl/makefile-512.mak b/plugins/perl/makefile-512.mak
new file mode 100644
index 00000000..e4887ff9
--- /dev/null
+++ b/plugins/perl/makefile-512.mak
@@ -0,0 +1,30 @@
+include "..\..\src\makeinc.mak"
+
+DIRENTLIB = ..\..\src\common\dirent.lib
+TARGET = $(PERL512OUTPUT)
+
+all: $(TARGET)
+
+perl.def:
+	echo EXPORTS > perl.def
+	echo xchat_plugin_init >> perl.def
+	echo xchat_plugin_deinit >> perl.def
+	echo xchat_plugin_get_info >> perl.def
+
+perl.obj: perl.c
+	$(CC) $(CFLAGS) perl.c $(GLIB) /I$(PERL512PATH) /I.. /DPERL_DLL=\"$(PERL512LIB).dll\"
+
+perl.c: xchat.pm.h
+
+xchat.pm.h: lib/Xchat.pm lib/IRC.pm
+	perl.exe generate_header
+
+$(TARGET): perl.obj perl.def
+	$(LINK) /DLL /out:$(TARGET) perl.obj $(LDFLAGS) $(PERL512LIB).lib /libpath:$(PERL512PATH) /DELAYLOAD:$(PERL512LIB).dll $(DIRENTLIB) DELAYIMP.LIB user32.lib shell32.lib advapi32.lib /def:perl.def
+
+clean:
+	@del $(TARGET)
+	@del *.obj
+	@del perl.def
+	@del *.lib
+	@del *.exp
diff --git a/plugins/perl/perl.c b/plugins/perl/perl.c
index a29ce65a..761566f9 100644
--- a/plugins/perl/perl.c
+++ b/plugins/perl/perl.c
@@ -22,12 +22,15 @@
 #include <sys/types.h>
 #include <sys/stat.h>
 #include <fcntl.h>
-#include <dirent.h>
 #ifdef ENABLE_NLS
 #include <locale.h>
 #endif
 #ifdef WIN32
 #include <windows.h>
+#define  _INC_DIRENT
+#include "../../src/common/dirent.h"
+#else
+#include <dirent.h>
 #endif
 
 #undef PACKAGE
@@ -1342,7 +1345,11 @@ perl_load_file (char *filename)
 			if (GetLastError () == ERROR_BAD_EXE_FORMAT)
 				/* http://forum.xchat.org/viewtopic.php?t=3277 */
 				thread_mbox ("Cannot use this " PERL_DLL "\n\n"
+#ifdef _WIN64
+								 "64-bit ActivePerl is required.");
+#else
 								 "32-bit ActivePerl is required.");
+#endif
 			else {
 				/* a lot of people install this old version */
 				lib = LoadLibraryA ("perl56.dll");
@@ -1357,7 +1364,7 @@ perl_load_file (char *filename)
 					thread_mbox ("Cannot open " PERL_DLL "\n\n"
 									 "You must have ActivePerl " PERL_REQUIRED_VERSION " installed in order to\n"
 									 "run perl scripts.\n\n"
-									 "http://www.activestate.com/ActivePerl/\n\n"
+									 "http://www.activestate.com/activeperl/downloads\n\n"
 									 "Make sure perl's bin directory is in your PATH.");
 				}
 			}
diff --git a/plugins/python/makefile.mak b/plugins/python/makefile.mak
new file mode 100644
index 00000000..8cbba3f5
--- /dev/null
+++ b/plugins/python/makefile.mak
@@ -0,0 +1,25 @@
+include "..\..\src\makeinc.mak"
+
+DIRENTLIB = ..\..\src\common\dirent.lib
+TARGET = $(PYTHONOUTPUT)
+
+all: $(TARGET)
+
+python.def:
+	echo EXPORTS > python.def
+	echo xchat_plugin_init >> python.def
+	echo xchat_plugin_deinit >> python.def
+	echo xchat_plugin_get_info >> python.def
+
+python.obj: python.c
+	$(CC) $(CFLAGS) /I.. /Dusleep=_sleep /DPATH_MAX=255 python.c $(GLIB) /I$(PYTHONPATH)\include /DPYTHON_DLL=\"$(PYTHONLIB).dll\"
+
+$(TARGET): python.obj python.def
+	$(LINK) /dll /out:$(TARGET) $(LDFLAGS) python.obj /libpath:$(PYTHONPATH)\libs $(PYTHONLIB).lib $(DIRENTLIB) $(LIBS) /def:python.def
+
+clean:
+	del $(TARGET)
+	del *.obj
+	del python.def
+	del *.lib
+	del *.exp
diff --git a/plugins/python/python.c b/plugins/python/python.c
index fd682082..55adf989 100644
--- a/plugins/python/python.c
+++ b/plugins/python/python.c
@@ -53,10 +53,10 @@
 
 #include <glib.h>
 #include <string.h>
-#include <unistd.h>
 #include <stdlib.h>
 #include <sys/types.h>
-#include <dirent.h>
+#include "../../src/common/dirent.h"
+#include "../../config.h"
 
 #include "xchat-plugin.h"
 #include "Python.h"
@@ -68,7 +68,7 @@
 
 #ifdef WIN32
 #undef WITH_THREAD /* Thread support locks up xchat on Win32. */
-#define VERSION "0.8/2.4"	/* Linked to python24.dll */
+#define VERSION "0.8/2.7"	/* Linked to python27.dll */
 #else
 #define VERSION "0.8"
 #endif
diff --git a/plugins/tcl/makefile.mak b/plugins/tcl/makefile.mak
new file mode 100644
index 00000000..c88f5c4f
--- /dev/null
+++ b/plugins/tcl/makefile.mak
@@ -0,0 +1,22 @@
+include "..\..\src\makeinc.mak"
+
+TARGET = $(TCLOUTPUT)
+
+all: $(TARGET)
+
+tcl.def:
+	echo EXPORTS > tcl.def
+	echo xchat_plugin_init >> tcl.def
+	echo xchat_plugin_deinit >> tcl.def
+	echo xchat_plugin_get_info >> tcl.def
+
+tclplugin.obj: tclplugin.c
+	$(CC) $(CFLAGS) /I.. tclplugin.c /I$(TCLPATH)\include /DTCL_DLL=\"$(TCLLIB).dll\"
+
+$(TARGET): tclplugin.obj tcl.def
+	$(LINK) /dll /out:$(TARGET) $(LDFLAGS) tclplugin.obj /libpath:$(TCLPATH)\lib $(TCLLIB).lib /delayload:$(TCLLIB).dll delayimp.lib /def:tcl.def
+
+clean:
+	del $(TARGET)
+	del *.obj
+	del tcl.def
diff --git a/plugins/tcl/tclplugin.c b/plugins/tcl/tclplugin.c
index 17dc7556..1f9b33e7 100644
--- a/plugins/tcl/tclplugin.c
+++ b/plugins/tcl/tclplugin.c
@@ -32,8 +32,6 @@ static char RCSID[] = "$Id: tclplugin.c,v 1.64 2010/03/10 04:24:16 mooooooo Exp
 #include <windows.h>
 #define bzero(mem, sz) memset((mem), 0, (sz))
 #define bcopy(src, dest, count) memmove((dest), (src), (count))
-#else
-#include <unistd.h>
 #endif
 
 #include "xchat-plugin.h"
@@ -2221,7 +2219,7 @@ int xchat_plugin_init(xchat_plugin * plugin_handle, char **plugin_name, char **p
 #ifdef WIN32
     lib = LoadLibraryA(TCL_DLL);
     if (!lib) {
-        xchat_print(ph, "You must have ActiveTCL installed in order to run Tcl scripts.\n" "http://aspn.activestate.com/ASPN/Tcl/\n" "Make sure Tcl's bin directory is in your PATH.\n\n");
+        xchat_print(ph, "You must have ActiveTCL 8.5 installed in order to run Tcl scripts.\n" "http://www.activestate.com/activetcl/downloads\n" "Make sure Tcl's bin directory is in your PATH.\n\n");
         return 0;
     }
     FreeLibrary(lib);
diff --git a/plugins/upd/makefile.mak b/plugins/upd/makefile.mak
new file mode 100644
index 00000000..34b54cb8
--- /dev/null
+++ b/plugins/upd/makefile.mak
@@ -0,0 +1,18 @@
+include "..\..\src\makeinc.mak"
+
+all: upd.obj upd.def
+	link $(LDFLAGS) $(LIBS) /dll /out:xcupd.dll /def:upd.def upd.obj
+
+upd.def:
+	echo EXPORTS > upd.def
+	echo xchat_plugin_init >> upd.def
+	echo xchat_plugin_deinit >> upd.def
+
+upd.obj: upd.c makefile.mak
+	cl $(CFLAGS) $(GLIB) /I.. upd.c
+
+clean:
+	del *.obj
+	del *.dll
+	del *.exp
+	del *.lib
diff --git a/plugins/upd/upd.c b/plugins/upd/upd.c
new file mode 100644
index 00000000..001cd9d2
--- /dev/null
+++ b/plugins/upd/upd.c
@@ -0,0 +1,111 @@
+/* XChat-WDK
+ * Copyright (c) 2010-2011 Berke Viktor.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ * 3. The name of the author may not be used to endorse or promote products
+ *    derived from this software without specific prior written permission.
+ * 
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+ * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#include <windows.h>
+#include <wininet.h>
+
+#include "xchat-plugin.h"
+
+static xchat_plugin *ph;   /* plugin handle */
+
+static char*
+check_version ()
+{
+	HINTERNET hINet, hFile;
+	hINet = InternetOpen ("Update Checker", INTERNET_OPEN_TYPE_PRECONFIG, NULL, NULL, 0);
+	
+	if (!hINet)
+	{
+		return "Unknown";
+	}
+
+	hFile = InternetOpenUrl (hINet, "http://xchat-wdk.googlecode.com/hg/version.txt", NULL, 0, 0, 0);
+	
+	if (hFile)
+	{
+		static char buffer[1024];
+		DWORD dwRead;
+		while (InternetReadFile (hFile, buffer, 1023, &dwRead))
+		{
+			if (dwRead == 0)
+			{
+				break;
+			}
+			buffer[dwRead] = 0;
+		}
+
+		InternetCloseHandle (hFile);
+		return buffer;
+	}
+	
+	InternetCloseHandle (hINet);
+	return "Unknown";
+}
+
+static void
+print_version ()
+{
+	char *version = check_version ();
+
+	if (strcmp (version, xchat_get_info (ph, "wdk_version")) == 0)
+	{
+		xchat_printf (ph, "You have the latest version of XChat-WDK installed!\n");
+	}
+	else if (strcmp (version, "Unknown") == 0)
+	{
+		xchat_printf (ph, "Unable to check for XChat-WDK updates!\n");
+	}
+	else
+	{
+		xchat_printf (ph, "An XChat-WDK update is available! You can download it from here:\nhttp://xchat-wdk.googlecode.com/files/XChat-WDK%%20%s.exe\n", version);
+	}
+}
+
+int
+xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugin_desc, char **plugin_version, char *arg)
+{
+	ph = plugin_handle;
+
+	*plugin_name = "Update Checker";
+	*plugin_desc = "Plugin for checking for XChat-WDK updates";
+	*plugin_version = "1.2";
+
+	xchat_hook_command (ph, "UPDCHK", XCHAT_PRI_NORM, print_version, 0, 0);
+	xchat_command (ph, "MENU -ietc\\download.png ADD \"Help/Check for Updates\" \"UPDCHK\"");
+
+	xchat_print (ph, "Update Checker plugin loaded\n");
+	print_version ();
+
+	return 1;       /* return 1 for success */
+}
+
+int
+xchat_plugin_deinit (void)
+{
+	xchat_command (ph, "MENU DEL \"Help/Check for updates\"");
+	xchat_print (ph, "Update Checker plugin unloaded\n");
+	return 1;
+}
diff --git a/plugins/winamp/makefile.mak b/plugins/winamp/makefile.mak
new file mode 100644
index 00000000..79adf87e
--- /dev/null
+++ b/plugins/winamp/makefile.mak
@@ -0,0 +1,18 @@
+include "..\..\src\makeinc.mak"
+
+all: winamp.obj winamp.def
+	link $(LDFLAGS) $(LIBS) /dll /out:xcwinamp.dll /def:winamp.def winamp.obj
+
+winamp.def:
+	echo EXPORTS > winamp.def
+	echo xchat_plugin_init >> winamp.def
+	echo xchat_plugin_deinit >> winamp.def
+
+winamp.obj: winamp.c makefile.mak
+	cl $(CFLAGS) /I.. winamp.c
+
+clean:
+	del *.obj
+	del *.dll
+	del *.exp
+	del *.lib
diff --git a/plugins/winamp/winamp.c b/plugins/winamp/winamp.c
new file mode 100644
index 00000000..7201a875
--- /dev/null
+++ b/plugins/winamp/winamp.c
@@ -0,0 +1,189 @@
+/********************* Winamp Plugin 0.3******************************
+ *
+ *   Distribution: GPL
+ *
+ *   Originally written by: Leo - leo.nard@free.fr
+ *   Modified by: SilvereX - SilvereX@karklas.mif.vu.lt
+ *   Modified again by: Derek Buitenhuis - daemon404@gmail.com
+ *   Modified yet again by: Berke Viktor - berkeviktor@aol.com
+ *********************************************************************/
+
+#include "windows.h"
+
+#include <stdio.h>
+#include <stdlib.h>
+#include <string.h>
+
+#include "xchat-plugin.h"
+
+#define PLAYING 1
+#define PAUSED 3
+
+static xchat_plugin *ph;   /* plugin handle */
+
+BOOL winamp_found = FALSE;
+
+int status = 0;
+
+/* Slightly modified from X-Chat's log_escape_strcpy */
+static char *
+song_strcpy (char *dest, char *src)
+{
+	while (*src)
+	{
+		*dest = *src;
+		dest++;
+		src++;
+
+		if (*src == '%')
+		{
+			dest[0] = '%';
+			dest++;
+		}
+	}
+
+	dest[0] = 0;
+	return dest - 1;
+}
+
+static int
+winamp(char *word[], char *word_eol[], void *userdata)
+{
+
+char current_play[2048], *p;
+char p_esc[2048];
+char cur_esc[2048];
+char truc[2048];
+HWND hwndWinamp = FindWindow("Winamp v1.x",NULL);
+
+    if (hwndWinamp)
+	{
+	    {
+	        if (!stricmp("PAUSE", word[2]))
+			{
+			   if (SendMessage(hwndWinamp,WM_USER, 0, 104))
+				{
+			   	   SendMessage(hwndWinamp, WM_COMMAND, 40046, 0);
+			
+			       if (SendMessage(hwndWinamp, WM_USER, 0, 104) == PLAYING)
+			   	       xchat_printf(ph, "Winamp: playing");
+			       else
+                       xchat_printf(ph, "Winamp: paused");
+				}
+            }
+			else
+		        if (!stricmp("STOP", word[2]))
+			    {
+			       SendMessage(hwndWinamp, WM_COMMAND, 40047, 0);
+			       xchat_printf(ph, "Winamp: stopped");
+			    }
+			else
+			    if (!stricmp("PLAY", word[2]))
+			    {
+			         SendMessage(hwndWinamp, WM_COMMAND, 40045, 0);
+			         xchat_printf(ph, "Winamp: playing");
+			    }
+        	else
+
+			    if (!stricmp("NEXT", word[2]))
+			    {
+			         SendMessage(hwndWinamp, WM_COMMAND, 40048, 0);
+			         xchat_printf(ph, "Winamp: next playlist entry");
+			    }
+			else
+
+                if (!stricmp("PREV", word[2]))
+			    {
+			         SendMessage(hwndWinamp, WM_COMMAND, 40044, 0);
+			         xchat_printf(ph, "Winamp: previous playlist entry");
+			    }
+		    else
+
+                if (!stricmp("START", word[2]))
+			    {
+			         SendMessage(hwndWinamp, WM_COMMAND, 40154, 0);
+			         xchat_printf(ph, "Winamp: playlist start");
+			    }
+
+		    else
+
+                if (!word_eol[2][0])
+			    {
+					GetWindowText(hwndWinamp, current_play, sizeof(current_play));
+
+					if (strchr(current_play, '-'))
+					{
+	
+					p = current_play + strlen(current_play) - 8;
+					while (p >= current_play)
+					{
+						if (!strnicmp(p, "- Winamp", 8)) break;
+							p--;
+					}
+
+					if (p >= current_play) p--;
+	
+					while (p >= current_play && *p == ' ') p--;
+						*++p=0;
+	
+	
+					p = strchr(current_play, '.') + 1;
+
+ 					song_strcpy(p_esc, p);
+ 					song_strcpy(cur_esc, current_play);
+	
+					if (p)
+					{
+						sprintf(truc, "me is now playing:%s", p_esc);
+					}
+					else
+					{
+						sprintf(truc, "me is now playing:%s", cur_esc);
+					}
+	
+	   				xchat_commandf(ph, truc);
+	
+				}
+				else xchat_print(ph, "Winamp: Nothing being played.");
+			}
+		    else
+                xchat_printf(ph, "Usage: /WINAMP [PAUSE|PLAY|STOP|NEXT|PREV|START]\n");
+         }
+
+	}
+	else
+	{
+       xchat_print(ph, "Winamp not found.\n");
+	}
+	return XCHAT_EAT_ALL;
+}
+
+int
+xchat_plugin_init(xchat_plugin *plugin_handle,
+                      char **plugin_name,
+                      char **plugin_desc,
+                      char **plugin_version,
+                      char *arg)
+{
+	/* we need to save this for use with any xchat_* functions */
+	ph = plugin_handle;
+
+	*plugin_name = "Winamp";
+	*plugin_desc = "Winamp plugin for XChat";
+	*plugin_version = "0.5";
+
+	xchat_hook_command (ph, "WINAMP", XCHAT_PRI_NORM, winamp, "Usage: /WINAMP [PAUSE|PLAY|STOP|NEXT|PREV|START] - control Winamp or show what's currently playing", 0);
+   	xchat_command (ph, "MENU -ietc\\music.png ADD \"Window/Display Current Song (Winamp)\" \"WINAMP\"");
+
+	xchat_print (ph, "Winamp plugin loaded\n");
+
+	return 1;       /* return 1 for success */
+}
+
+int
+xchat_plugin_deinit(void)
+{
+	xchat_command (ph, "MENU DEL \"Window/Display Current Song (Winamp)\"");
+	xchat_print (ph, "Winamp plugin unloaded\n");
+	return 1;
+}
diff --git a/plugins/xdcc/makefile.mak b/plugins/xdcc/makefile.mak
new file mode 100644
index 00000000..0a12347e
--- /dev/null
+++ b/plugins/xdcc/makefile.mak
@@ -0,0 +1,18 @@
+include "..\..\src\makeinc.mak"
+
+all: xdcc.obj xdcc.def
+	link $(LDFLAGS) $(LIBS) /dll /out:xcxdcc.dll /def:xdcc.def xdcc.obj
+
+xdcc.def:
+	echo EXPORTS > xdcc.def
+	echo xchat_plugin_init >> xdcc.def
+	echo xchat_plugin_deinit >> xdcc.def
+
+xdcc.obj: xdcc.c makefile.mak
+	cl $(CFLAGS) $(GLIB) /I.. xdcc.c
+
+clean:
+	del *.obj
+	del *.dll
+	del *.exp
+	del *.lib
diff --git a/plugins/xdcc/xdcc.c b/plugins/xdcc/xdcc.c
index 147a3c33..a8fda540 100644
--- a/plugins/xdcc/xdcc.c
+++ b/plugins/xdcc/xdcc.c
@@ -2,11 +2,11 @@
 
 #include <glib.h>
 #include <string.h>
-#include <unistd.h>
 #include <stdlib.h>
 #include <stdio.h>
 
 #include "xchat-plugin.h"
+#include "../../src/common/xchat.h"
 
 static xchat_plugin *ph;	/* plugin handle */
 
diff --git a/plugins/xtray/bitmaps/sd.bmp b/plugins/xtray/bitmaps/sd.bmp
new file mode 100644
index 00000000..9d6b7f95
Binary files /dev/null and b/plugins/xtray/bitmaps/sd.bmp differ
diff --git a/plugins/xtray/callbacks.cpp b/plugins/xtray/callbacks.cpp
new file mode 100644
index 00000000..636c114e
--- /dev/null
+++ b/plugins/xtray/callbacks.cpp
@@ -0,0 +1,734 @@
+/* X-Tray
+ * Copyright (C) 2005 Michael Hotaling <Mike.Hotaling@SinisterDevelopments.com>
+ *
+ * X-Tray is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ * 
+ * X-Tray is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with X-Tray; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+ */
+
+#define _WIN32_IE 0x0601
+
+#include <windows.h>
+#include <stdio.h>
+#include <commctrl.h>
+#include <tchar.h>
+#include "utility.h"
+#include "plugin.h"
+#include "xtray.h"
+#include "xchat.h"
+#include "callbacks.h"
+#include "resource.h"
+#include "sdTray.h"
+#include "sdAlerts.h"
+
+HWND	g_hPrefTabEvents;
+HWND	g_hPrefTabSettings;
+HWND	g_hPrefTabAlerts;
+HWND	g_hPrefTabAbout;
+bool	g_bCanQuit;
+int		g_iIsActive = 1;
+
+
+BOOL CALLBACK EnumWindowsProc(HWND hWnd, LPARAM lParam)
+{
+	TCHAR szTitle[10];
+	GetWindowText(hWnd, szTitle, 9);
+
+	if(_tcsstr(szTitle, _T("XChat [")))
+	{
+		g_hXchatWnd = hWnd;
+		return false;
+	}
+	
+	return true;
+}
+
+/***********************************************************************************************/
+/******* our xchat event call back, get the name and info for each event and save it ***********/
+/******* for our alerts later														***********/
+/***********************************************************************************************/
+int event_cb(char *word[], void *userdata)
+{
+	int iEvent = (int)userdata;
+
+	if(iEvent > 10 && iEvent != 21)
+		return XCHAT_EAT_NONE;
+
+	/***************************************************************************************/
+	/***** if the window is minimized or if we're allowed to show alerts when its not	 **/
+	/***** and if the option to show the specified alert is true and if we're even		**/
+	/***** allowed to show alerts at all then we show them (a bit confusing but it works) **/
+	/***************************************************************************************/
+	if(((g_iIsActive == 0) || !(g_dwPrefs & (1<<PREF_OSBWM))) && (g_dwPrefs & (1<<PREF_AMAE)) && (g_dwPrefs & (1<<iEvent)))
+	{	
+		/*********************************/
+		/*********** Our Buffers *********/
+		/*********************************/
+		char			szInfo[512];
+		char			szName[64];
+		DWORD			dwInfoFlags;
+		int iTime		= g_iTime*1000;
+		char *szTemp	= NULL;
+
+		if(g_dwPrefs & (1<<PREF_KAOI))
+		{
+			iTime = 0;
+		}
+
+		switch(iEvent)
+		{
+		case CHAN_HILIGHT:
+			_snprintf(szInfo, 512, "%s:\r\n%s", word[1], word[2]);
+			_snprintf(szName, 64, "Hilight");
+			dwInfoFlags = NIIF_INFO;
+			break;
+		case CHAN_MESSAGE:
+			_snprintf(szInfo, 512, "%s:\r\n%s", word[1], word[2]);
+			_snprintf(szName, 64, "Channel Message");
+			dwInfoFlags = NIIF_INFO;
+			break;
+		case CHAN_TOPIC_CHANGE:
+			_snprintf(szInfo, 512, "%s has changed the topic to %s", word[1], word[2]);
+			_snprintf(szName, 64, "Topic Change: %s", word[3]);
+			dwInfoFlags = NIIF_INFO;
+			break;
+		case CHAN_INVITE:
+			_snprintf(szInfo, 512, "%s has invited you into %s", word[1], word[2]);
+			_snprintf(szName, 64, "Invite");
+			dwInfoFlags = NIIF_INFO;
+			break;
+		case CHAN_KICKED:
+			_snprintf(szInfo, 512, "Kicked from %s by %s:\r\n%s", word[2], word[3], word[4]);
+			_snprintf(szName, 64, "Kick");
+			dwInfoFlags = NIIF_WARNING;
+			break;
+		case CHAN_BANNED:
+			_snprintf(szInfo, 512, "Cannot join #%s You are banned.", word[1]);
+			_snprintf(szName, 64, "Banned");
+			dwInfoFlags = NIIF_WARNING;
+			break;
+		case CTCP_GENERIC:
+			_snprintf(szInfo, 512, "%s:\r\nCTCP %s", word[2], word[1]);
+			_snprintf(szName, 64, "CTCP");
+			dwInfoFlags = NIIF_INFO;
+			break;
+		case PMSG_RECEIVE:
+			_snprintf(szInfo, 512, "%s:\r\n%s", word[1], word[2]);
+			_snprintf(szName, 64, "Private Message");
+			dwInfoFlags = NIIF_INFO;
+			break;
+		case SERV_DISCONNECT:
+			_snprintf(szInfo, 512, "Disconnected\r\nError: %s", word[1]);
+			_snprintf(szName, 64, "Disconnect");
+			dwInfoFlags = NIIF_ERROR;
+			break;
+		case SERV_KILLED:
+			_snprintf(szInfo, 512, "Killed(%s(%s))", word[1], word[2]);
+			_snprintf(szName, 64, "Server Admin has killed you");
+			dwInfoFlags = NIIF_ERROR;
+			break;
+		case SERV_NOTICE:
+			_snprintf(szInfo, 512, "Notice:\r\n%s: %s", word[1], word[2]);
+			_snprintf(szName, 64, "Notice");
+			dwInfoFlags = NIIF_INFO;
+			break;
+		case 11:
+			_snprintf(szInfo, 512, ":\r\n%s: %s", word[1], word[2]);
+			_snprintf(szName, 64, "Notice");
+			dwInfoFlags = NIIF_INFO;
+			break;
+		}
+
+		/**************************************************************************************/
+		/***** Use windows instead of balloons, and if its a window should we keep it open ****/
+		/***** indefinately?															   ****/
+		/**************************************************************************************/
+		szTemp = xchat_strip_color(szInfo);
+
+		if(g_dwPrefs & (1<<PREF_UWIOB))
+		{
+			sdSystemAlert((HINSTANCE)g_hInstance, IDD_ALERT, szTemp, szName, iTime);
+		}
+		else
+		{
+			ShowBalloon(g_hXchatWnd, 1, szTemp, szName, iTime, dwInfoFlags);
+		}
+
+		free(szTemp);
+	}
+
+	if(g_dwPrefs & (1<<PREF_BLINK))
+	{
+		BlinkIcon(g_hXchatWnd, 1, g_hIcons[0], g_hIcons[(iEvent+1)], 700, 5);
+		
+	}
+
+	/***********************************/
+	/***** pass the events to xchat ****/
+	/***********************************/
+	return XCHAT_EAT_NONE;
+}
+
+int command_cb(char *word[], char *word_eol[], void *userdata)
+{
+	char szInfo[512];
+	char *szTemp	= NULL;
+	int iTime		= g_iTime*1000;
+
+	_snprintf(szInfo, 512, word_eol[2]);
+	szTemp = xchat_strip_color(szInfo);
+
+	if(g_dwPrefs & (1<<PREF_KAOI))
+	{
+		iTime = 0;
+	}
+
+	if(((g_iIsActive == 0) || !(g_dwPrefs & (1<<PREF_OSBWM))) && (g_dwPrefs & (1<<PREF_AMAE)))
+	{
+		if(g_dwPrefs & (1<<PREF_UWIOB))
+		{
+			sdSystemAlert((HINSTANCE)g_hInstance, IDD_ALERT, szTemp, "Alert", iTime);
+		}
+		else
+		{
+			ShowBalloon(g_hXchatWnd, 1, szTemp, "Alert", iTime, NIIF_INFO);
+		}
+	}
+
+	free(szTemp);
+
+	return XCHAT_EAT_ALL;
+}
+
+LRESULT CALLBACK WindowProc(HWND hWnd, UINT msg, WPARAM wparam, LPARAM lparam)
+{
+	switch(msg)
+	{
+	case WM_CLOSE:
+		{
+			if((g_dwPrefs & (1<<PREF_MIOC)) && (g_bCanQuit == false))
+			{
+				/*******************************************/
+				/**** to autoaway or not to autoaway...  ***/
+				/*******************************************/
+				if(g_dwPrefs & (1<<PREF_AOM))
+				{
+					xchat_globally_away(g_szAway);
+				}
+
+				/**************************************************/
+				/**** Win32 API call to hide the window and	     **/
+				/**** save the fact that its minimized for later **/
+				/**************************************************/
+				g_iIsActive = 0;
+				ShowWindow(hWnd, SW_HIDE);
+
+				return 0;
+			}
+			else
+			{
+				if(g_hPrefDlg != NULL)
+				{
+					DestroyWindow(g_hPrefDlg);
+				}
+
+				StopBlink(hWnd, 1, g_hIcons[0]);
+				
+				if(sdAlertNum())
+				{
+					sdCloseAlerts();
+					HoldClose();
+					return 0;
+				}
+			}
+		}
+		break;
+	case WM_SIZE:
+		{
+			/******************************************/
+			/***** User wants to minimize xChat, ******/
+			/***** are we allowed to go to tray? ******/
+			/******************************************/
+			if((g_dwPrefs & (1<<PREF_TOT)) && (wparam == SIZE_MINIMIZED))
+			{
+				/*******************************************/
+				/**** to autoaway or not to autoaway...  ***/
+				/*******************************************/
+				if(g_dwPrefs & (1<<PREF_AOM))
+				{
+					xchat_globally_away(g_szAway);
+				}
+
+				/**************************************************/
+				/**** Win32 API call to hide the window and	     **/
+				/**** save the fact that its minimized for later **/
+				/**************************************************/
+				g_iIsActive = 0;
+				ShowWindow(hWnd, SW_HIDE);
+			}
+		}
+		break;
+	/**********************************/
+	/*** user clicked the tray icon ***/
+	/**********************************/
+	case WM_TRAYMSG:
+		{
+			switch(lparam)
+			{
+			case WM_LBUTTONDOWN:
+				{
+					if(!g_iIsActive)
+					{
+						/*********************************************************/
+						/*** 0: its hiden, restore it and show it, if autoaway ***/
+						/*** is on, set us as back							 ***/
+						/*********************************************************/
+						SendMessage(hWnd, WM_SYSCOMMAND, SC_RESTORE, 0);
+						SetForegroundWindow(hWnd);
+						g_iIsActive = 1;
+
+						if(g_dwPrefs & (1<<PREF_AOM))
+						{
+							xchat_globally_back();
+						}
+					}
+					else
+					{
+						SendMessage(hWnd, WM_SYSCOMMAND, SC_MINIMIZE, 0);
+					}
+				}
+				break;
+			case WM_RBUTTONDOWN:
+				{
+					/******************************************/
+					/*** user wants to see the menu find out **/
+					/*** where the mouse is and show it	  **/
+					/******************************************/
+					POINT pt;
+					int iRet;
+
+					GetCursorPos(&pt);
+					SetForegroundWindow(hWnd);
+
+					ModifyMenu(g_hTrayMenu, 2, (MF_POPUP | MF_BYPOSITION), (UINT)setServerMenu(), _T("Away"));
+
+					Sleep(175);
+
+					iRet = TrackPopupMenuEx(g_hTrayMenu, (TPM_RETURNCMD | TPM_LEFTALIGN), pt.x, pt.y, hWnd, NULL);
+
+					/***********************************/
+					/*** nRet is the users selection, **/
+					/*** process it				   **/
+					/***********************************/
+					sdTrayProc(hWnd, iRet);
+				}
+				break;
+			}
+		}
+		break;
+	default:
+		{
+			/*****************************************************/
+			/*** the taskbar has been restarted, re-add our icon */
+			/*****************************************************/
+			if(msg == RegisterWindowMessage(_T("TaskbarCreated")))
+			{
+				char szVersion[64];
+				_snprintf(szVersion, 64, "XChat-WDK [%s]", xchat_get_info(ph, "version"));
+				AddIcon(g_hXchatWnd, 1, g_hIcons[0], szVersion, (NIF_ICON | NIF_MESSAGE | NIF_TIP), WM_TRAYMSG);
+			}
+		}
+		break;
+	}
+
+	return CallWindowProc(g_hOldProc, hWnd, msg, wparam, lparam);
+}
+
+/****************************************************/
+/*** process messages from the tray menu ************/
+/****************************************************/
+LRESULT CALLBACK sdTrayProc(HWND hWnd, int msg)
+{
+	switch(msg)
+	{
+	case ACT_EXIT:
+		{
+			g_bCanQuit = true;
+			PostMessage(hWnd, WM_CLOSE, 0, 0);
+		}
+		break;
+	case ACT_RESTORE:
+		{
+			/***********************************************/
+			/** user wants us to restore the xchat window **/
+			/** and of autoaway is on, set as back		**/
+			/***********************************************/
+			SendMessage(g_hXchatWnd, WM_SYSCOMMAND, SC_RESTORE, 0);
+			SetForegroundWindow(hWnd);
+			
+			if((!g_iIsActive) && (g_dwPrefs & (1<<PREF_AOM)))
+			{
+				xchat_globally_back();
+				g_iIsActive = 1;
+			}
+		}
+		break;
+	case ACT_SETTINGS:
+		{
+			ShowWindow(g_hPrefDlg, SW_SHOW);
+		}
+		break;
+	case ACT_AWAY:
+		{
+			xchat_globally_away(g_szAway);
+		}
+		break;
+	case ACT_BACK:
+		{
+			xchat_globally_back();
+		}
+		break;
+	default:
+		{
+			if(msg > 0)
+			{
+				xchat_set_context(ph, xchat_find_server(msg-1));
+
+				if(!xchat_get_info(ph, "away"))
+				{
+					xchat_away(g_szAway);
+				}
+				else
+				{
+					xchat_back();
+				}
+			}
+		}
+		break;
+	}
+
+	return 1;
+}
+
+int CALLBACK PrefProc(HWND hWnd, UINT msg, WPARAM wparam, LPARAM lparam)
+{
+	switch(msg)
+	{
+	case WM_INITDIALOG:
+		{
+			TCITEM tci1;
+			TCITEM tci2;
+			TCITEM tci3;
+			TCITEM tci4;
+
+			tci1.mask		= TCIF_TEXT;
+			tci1.pszText	= _T("Settings");
+			tci1.cchTextMax	= strlen("Settings");
+			SendDlgItemMessage(hWnd, IDC_TAB_CONTROL, TCM_INSERTITEM, 0, (LPARAM)&tci1);
+
+			tci2.mask		= TCIF_TEXT;
+			tci2.pszText	= _T("Alerts");
+			tci2.cchTextMax	= strlen("Alerts");
+			SendDlgItemMessage(hWnd, IDC_TAB_CONTROL, TCM_INSERTITEM, 1, (LPARAM)&tci2);
+
+			tci3.mask		= TCIF_TEXT;
+			tci3.pszText	= _T("Events");
+			tci3.cchTextMax	= strlen("Events");
+			SendDlgItemMessage(hWnd, IDC_TAB_CONTROL, TCM_INSERTITEM, 2, (LPARAM)&tci3);
+
+			tci4.mask		= TCIF_TEXT;
+			tci4.pszText	= _T("About");
+			tci4.cchTextMax	= strlen("About");
+			SendDlgItemMessage(hWnd, IDC_TAB_CONTROL, TCM_INSERTITEM, 3, (LPARAM)&tci4);
+
+
+			/***********************************************************************************/
+			/***********************************************************************************/
+			/***********************************************************************************/
+
+			g_hPrefTabSettings	= CreateDialog((HINSTANCE)g_hInstance,
+									MAKEINTRESOURCE(IDD_SETTINGS),
+									hWnd,		
+									(DLGPROC)SettingsProc);
+			SetDialog(g_hPrefTabSettings,	IDD_SETTINGS);
+
+			g_hPrefTabAlerts	= CreateDialog((HINSTANCE)g_hInstance,
+									MAKEINTRESOURCE(IDD_ALERTS),
+									hWnd,
+									(DLGPROC)AlertsProc);
+			SetDialog(g_hPrefTabAlerts,		IDD_ALERTS);
+
+			g_hPrefTabEvents	= CreateDialog((HINSTANCE)g_hInstance,
+									MAKEINTRESOURCE(IDD_EVENTS),
+									hWnd,		
+									(DLGPROC)EventsProc);
+			SetDialog(g_hPrefTabEvents,		IDD_EVENTS);
+
+			g_hPrefTabAbout		= CreateDialog((HINSTANCE)g_hInstance,
+									MAKEINTRESOURCE(IDD_ABOUT),
+									hWnd,
+									(DLGPROC)AboutProc);
+		}
+		break;
+	case WM_SHOWWINDOW:
+		{
+			if(wparam)
+			{
+				SendDlgItemMessage(hWnd, IDC_TAB_CONTROL, TCM_SETCURSEL, 0, 0);
+				ShowWindow(g_hPrefTabSettings,	SW_SHOW);
+				ShowWindow(g_hPrefTabAlerts,	SW_HIDE);
+				ShowWindow(g_hPrefTabEvents,	SW_HIDE);
+				ShowWindow(g_hPrefTabAbout,		SW_HIDE);
+			}
+		}
+		break;
+	case WM_NOTIFY:
+		{
+			NMHDR *pData = (NMHDR *)lparam;
+
+			switch(pData->code)
+			{
+			case TCN_SELCHANGE:
+				{
+					switch(SendDlgItemMessage(hWnd, IDC_TAB_CONTROL, TCM_GETCURSEL, 0, 0))
+					{
+					case 0:
+						{
+							ShowWindow(g_hPrefTabSettings,	SW_SHOW);
+							ShowWindow(g_hPrefTabAlerts,	SW_HIDE);
+							ShowWindow(g_hPrefTabEvents,	SW_HIDE);
+							ShowWindow(g_hPrefTabAbout,		SW_HIDE);
+						}
+						break;
+					case 1:
+						{
+							ShowWindow(g_hPrefTabSettings,	SW_HIDE);
+							ShowWindow(g_hPrefTabAlerts,	SW_SHOW);
+							ShowWindow(g_hPrefTabEvents,	SW_HIDE);
+							ShowWindow(g_hPrefTabAbout,		SW_HIDE);
+						}
+						break;
+					case 2:
+						{
+							ShowWindow(g_hPrefTabSettings,	SW_HIDE);
+							ShowWindow(g_hPrefTabAlerts,	SW_HIDE);
+							ShowWindow(g_hPrefTabEvents,	SW_SHOW);
+							ShowWindow(g_hPrefTabAbout,		SW_HIDE);
+						}
+						break;
+					case 3:
+						{
+							ShowWindow(g_hPrefTabSettings,	SW_HIDE);
+							ShowWindow(g_hPrefTabAlerts,	SW_HIDE);
+							ShowWindow(g_hPrefTabEvents,	SW_HIDE);
+							ShowWindow(g_hPrefTabAbout,		SW_SHOW);
+						}
+						break;
+					}
+				}
+				break;
+			}
+		}
+		break;
+	case WM_CLOSE:
+		{
+			ShowWindow(g_hPrefTabEvents,	SW_HIDE);
+			ShowWindow(g_hPrefTabSettings,	SW_HIDE);
+			ShowWindow(g_hPrefTabAlerts,	SW_HIDE);
+			ShowWindow(g_hPrefTabAbout,		SW_HIDE);
+			ShowWindow(hWnd,				SW_HIDE);
+			return TRUE;
+		}
+		break;
+	case WM_COMMAND:
+		{
+			switch(wparam)
+			{
+			case IDC_PREF_OK:
+				{
+					CheckPrefs(g_hPrefTabEvents,	IDD_EVENTS);
+					CheckPrefs(g_hPrefTabSettings,	IDD_SETTINGS);
+					CheckPrefs(g_hPrefTabAlerts,	IDD_ALERTS);
+
+					SavePrefs(0);
+
+					ShowWindow(g_hPrefTabEvents,	SW_HIDE);
+					ShowWindow(g_hPrefTabSettings,	SW_HIDE);
+					ShowWindow(g_hPrefTabAlerts,	SW_HIDE);
+					ShowWindow(g_hPrefTabAbout,		SW_HIDE);
+					ShowWindow(hWnd,				SW_HIDE);
+					return TRUE;
+				}
+				break;
+			case IDC_PREF_CANCEL:
+				{
+					ShowWindow(g_hPrefTabEvents,	SW_HIDE);
+					ShowWindow(g_hPrefTabSettings,	SW_HIDE);
+					ShowWindow(g_hPrefTabAlerts,	SW_HIDE);
+					ShowWindow(g_hPrefTabAbout,		SW_HIDE);
+					ShowWindow(hWnd,				SW_HIDE);
+					return TRUE;
+				}
+				break;
+			case IDC_PREF_APPLY:
+				{
+					CheckPrefs(g_hPrefTabEvents,	IDD_EVENTS);
+					CheckPrefs(g_hPrefTabSettings,	IDD_SETTINGS);
+					CheckPrefs(g_hPrefTabAlerts,	IDD_ALERTS);
+
+					SavePrefs(0);
+					return FALSE;
+				}
+				break;
+			}
+		}
+		break;
+	case WM_DESTROY:
+		{
+			SendMessage(g_hPrefTabEvents,	WM_CLOSE, 0, 0);
+			SendMessage(g_hPrefTabSettings,	WM_CLOSE, 0, 0);
+			SendMessage(g_hPrefTabAbout,	WM_CLOSE, 0, 0);
+			SendMessage(g_hPrefTabAlerts,	WM_CLOSE, 0, 0);
+		}
+		break;
+	}
+
+	return FALSE;
+}
+
+/****************************************************/
+/****************************************************/
+/****************************************************/
+LRESULT CALLBACK AlertsProc(HWND hWnd, UINT msg, WPARAM wparam, LPARAM lparam)
+{
+	switch(msg)
+	{
+	case WM_CLOSE:
+		{
+			DestroyWindow(hWnd);
+			return TRUE;
+			break;
+		}
+		break;
+	case WM_COMMAND:
+		{
+			switch(LOWORD(wparam))
+			{
+			case PREF_AMAE:
+				{
+					SetToggle(hWnd, PREF_OSBWM,			PREF_AMAE, TRUE);
+					SetToggle(hWnd, PREF_UWIOB,			PREF_AMAE, TRUE);
+					SetToggle(hWnd, PREF_KAOI,			PREF_AMAE, TRUE);
+					
+					if(IsDlgButtonChecked(hWnd, PREF_AMAE))
+					{
+						SetToggle(hWnd, IDC_ALERT_HOTKEY,		PREF_UWIOB, TRUE);
+						SetToggle(hWnd, IDC_ALERT_HOTKEY_TEXT,	PREF_UWIOB, TRUE);
+						SetToggle(hWnd, IDC_ALERT_TIME,			PREF_KAOI, FALSE);
+						SetToggle(hWnd, IDC_ALERT_TIME_TEXT,	PREF_KAOI, FALSE);
+					}
+					else
+					{
+						SetToggle(hWnd, IDC_ALERT_HOTKEY,		PREF_AMAE, TRUE);
+						SetToggle(hWnd, IDC_ALERT_HOTKEY_TEXT,	PREF_AMAE, TRUE);
+						SetToggle(hWnd, IDC_ALERT_TIME,			PREF_AMAE, TRUE);
+						SetToggle(hWnd, IDC_ALERT_TIME_TEXT,	PREF_AMAE, TRUE);
+					}
+				}
+				break;
+			case PREF_UWIOB:
+				{
+					SetToggle(hWnd, IDC_ALERT_HOTKEY,		PREF_UWIOB, TRUE);
+					SetToggle(hWnd, IDC_ALERT_HOTKEY_TEXT,	PREF_UWIOB, TRUE);
+				}
+				break;
+			case PREF_KAOI:
+				{
+					SetToggle(hWnd, IDC_ALERT_TIME,			PREF_KAOI, FALSE);
+					SetToggle(hWnd, IDC_ALERT_TIME_TEXT,	PREF_KAOI, FALSE);
+				}
+				break;
+			}
+			break;
+		}
+	}
+
+	return FALSE;
+}
+
+/****************************************************/
+/****************************************************/
+/****************************************************/
+LRESULT CALLBACK AboutProc(HWND hWnd, UINT msg, WPARAM wparam, LPARAM lparam)
+{
+	if(msg == WM_CLOSE)
+	{
+		DestroyWindow(hWnd);
+		return true;
+	}
+
+	return FALSE;
+}
+
+/*****************************************************/
+/** Process the events for our event dialog **********/
+/*****************************************************/
+LRESULT CALLBACK EventsProc(HWND hWnd, UINT msg, WPARAM wparam, LPARAM lparam)
+{
+	if(msg == WM_CLOSE)
+	{
+		DestroyWindow(hWnd);
+		return true;
+	}
+
+	return FALSE;
+}
+
+/*****************************************************/
+/** Process the events for our settings dialog this **/
+/** is alot more complicated because options are	**/
+/** enabled/disabled based on the state of others   **/
+/*****************************************************/
+LRESULT CALLBACK SettingsProc(HWND hWnd, UINT msg, WPARAM wparam, LPARAM lparam)
+{
+	if(msg == WM_CLOSE)
+	{
+		DestroyWindow(hWnd);
+		return true;
+	}
+
+	return FALSE;
+}
+
+/*****************************************************/
+/** this is the hotkey message  processing function **/
+/** this window is always open and ready to be told **/
+/** if someone has hit the hotkey, if they did, we  **/
+/** need to close out all of the tray alerts, for   **/
+/** this I wrote sdCloseAlerts, more info there	 **/
+/*****************************************************/
+LRESULT CALLBACK HotKeyProc(HWND hWnd, UINT msg, WPARAM wparam, LPARAM lparam)
+{
+	if(msg == WM_CLOSE)
+	{
+		DestroyWindow(hWnd);
+		return true;
+	}
+	else if(msg == WM_HOTKEY)
+	{
+		sdCloseAlerts();
+	}
+
+	return FALSE;
+}
+
diff --git a/plugins/xtray/callbacks.h b/plugins/xtray/callbacks.h
new file mode 100644
index 00000000..99cbae74
--- /dev/null
+++ b/plugins/xtray/callbacks.h
@@ -0,0 +1,37 @@
+/* X-Tray
+ * Copyright (C) 2005 Michael Hotaling <Mike.Hotaling@SinisterDevelopments.com>
+ *
+ * X-Tray is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ * 
+ * X-Tray is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with X-Tray; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+ */
+
+#ifndef _H_CALLBACKS_H
+#define _H_CALLBACKS_H
+
+int					event_cb		(char *word[], void *userdata);
+int					command_cb		(char *word[], char *word_eol[], void *userdata);
+
+LRESULT CALLBACK	WindowProc		(HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam);
+BOOL	CALLBACK	EnumWindowsProc	(HWND hWnd, LPARAM lParam);
+LRESULT CALLBACK	sdTrayProc		(HWND hwnd, int msg);
+
+LRESULT CALLBACK	AlertProc		(HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam);
+LRESULT CALLBACK	HotKeyProc		(HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam);
+LRESULT CALLBACK	EventsProc		(HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam);
+LRESULT CALLBACK	AboutProc		(HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam);
+LRESULT CALLBACK	AlertsProc		(HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam);
+LRESULT CALLBACK	SettingsProc	(HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam);
+int		CALLBACK	PrefProc		(HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam);
+
+#endif
\ No newline at end of file
diff --git a/plugins/xtray/icons/banned.ico b/plugins/xtray/icons/banned.ico
new file mode 100644
index 00000000..fef8df8c
Binary files /dev/null and b/plugins/xtray/icons/banned.ico differ
diff --git a/plugins/xtray/icons/chan_msg.ico b/plugins/xtray/icons/chan_msg.ico
new file mode 100644
index 00000000..793d050e
Binary files /dev/null and b/plugins/xtray/icons/chan_msg.ico differ
diff --git a/plugins/xtray/icons/disconnected.ico b/plugins/xtray/icons/disconnected.ico
new file mode 100644
index 00000000..9063e7e3
Binary files /dev/null and b/plugins/xtray/icons/disconnected.ico differ
diff --git a/plugins/xtray/icons/highlight-1-3.ico b/plugins/xtray/icons/highlight-1-3.ico
new file mode 100644
index 00000000..a759145b
Binary files /dev/null and b/plugins/xtray/icons/highlight-1-3.ico differ
diff --git a/plugins/xtray/icons/highlight.ico b/plugins/xtray/icons/highlight.ico
new file mode 100644
index 00000000..625cca9a
Binary files /dev/null and b/plugins/xtray/icons/highlight.ico differ
diff --git a/plugins/xtray/icons/kicked.ico b/plugins/xtray/icons/kicked.ico
new file mode 100644
index 00000000..845a74e1
Binary files /dev/null and b/plugins/xtray/icons/kicked.ico differ
diff --git a/plugins/xtray/icons/priv_msg-1-2-2.ico b/plugins/xtray/icons/priv_msg-1-2-2.ico
new file mode 100644
index 00000000..7941ff77
Binary files /dev/null and b/plugins/xtray/icons/priv_msg-1-2-2.ico differ
diff --git a/plugins/xtray/icons/sd.ico b/plugins/xtray/icons/sd.ico
new file mode 100644
index 00000000..ca179621
Binary files /dev/null and b/plugins/xtray/icons/sd.ico differ
diff --git a/plugins/xtray/icons/server_notice.ico b/plugins/xtray/icons/server_notice.ico
new file mode 100644
index 00000000..ff765d87
Binary files /dev/null and b/plugins/xtray/icons/server_notice.ico differ
diff --git a/plugins/xtray/icons/xchat.ico b/plugins/xtray/icons/xchat.ico
new file mode 100644
index 00000000..73247fd0
Binary files /dev/null and b/plugins/xtray/icons/xchat.ico differ
diff --git a/plugins/xtray/makefile.mak b/plugins/xtray/makefile.mak
new file mode 100644
index 00000000..d1f8d295
--- /dev/null
+++ b/plugins/xtray/makefile.mak
@@ -0,0 +1,37 @@
+include "..\..\src\makeinc.mak"
+
+TARGET = xtray.dll
+
+TRAY_OBJECTS = \
+callbacks.obj \
+sdAlerts.obj \
+sdTray.obj \
+utility.obj \
+xchat.obj \
+xtray.obj
+
+CPPFLAGS = $(CPPFLAGS) /D_STL70_ /D_STATIC_CPPLIB /EHsc /DUNICODE /D_UNICODE
+
+all: $(TRAY_OBJECTS) $(TARGET)
+
+xtray.def:
+	echo EXPORTS > xtray.def
+	echo xchat_plugin_init >> xtray.def
+	echo xchat_plugin_deinit >> xtray.def
+
+.cpp.obj:
+	$(CC) $(CPPFLAGS) /c $<
+
+res:
+	rc /nologo resource.rc
+	
+$(TARGET): $(TRAY_OBJECTS) xtray.def res
+	$(LINK) /DLL /out:$(TARGET) $(LDFLAGS) $(TRAY_OBJECTS) ntstc_msvcrt.lib $(LIBS) /def:xtray.def resource.res
+
+clean:
+	del $(TARGET)
+	del *.obj
+	del xtray.def
+	del resource.res
+	del *.lib
+	del *.exp
diff --git a/plugins/xtray/plugin.h b/plugins/xtray/plugin.h
new file mode 100644
index 00000000..50b0de21
--- /dev/null
+++ b/plugins/xtray/plugin.h
@@ -0,0 +1,335 @@
+/* You can distribute this header with your plugins for easy compilation */
+#ifndef XCHAT_PLUGIN_H
+#define XCHAT_PLUGIN_H
+
+#include <time.h>
+
+#define XCHAT_IFACE_MAJOR	1
+#define XCHAT_IFACE_MINOR	9
+#define XCHAT_IFACE_MICRO	11
+#define XCHAT_IFACE_VERSION	((XCHAT_IFACE_MAJOR * 10000) + \
+				 (XCHAT_IFACE_MINOR * 100) + \
+				 (XCHAT_IFACE_MICRO))
+
+#define XCHAT_PRI_HIGHEST	127
+#define XCHAT_PRI_HIGH		64
+#define XCHAT_PRI_NORM		0
+#define XCHAT_PRI_LOW		(-64)
+#define XCHAT_PRI_LOWEST	(-128)
+
+#define XCHAT_FD_READ		1
+#define XCHAT_FD_WRITE		2
+#define XCHAT_FD_EXCEPTION	4
+#define XCHAT_FD_NOTSOCKET	8
+
+#define XCHAT_EAT_NONE		0	/* pass it on through! */
+#define XCHAT_EAT_XCHAT		1	/* don't let xchat see this event */
+#define XCHAT_EAT_PLUGIN	2	/* don't let other plugins see this event */
+#define XCHAT_EAT_ALL		(XCHAT_EAT_XCHAT|XCHAT_EAT_PLUGIN)	/* don't let anything see this event */
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+typedef struct _xchat_plugin xchat_plugin;
+typedef struct _xchat_list xchat_list;
+typedef struct _xchat_hook xchat_hook;
+#ifndef PLUGIN_C
+typedef struct _xchat_context xchat_context;
+#endif
+
+#ifndef PLUGIN_C
+struct _xchat_plugin
+{
+	/* these are only used on win32 */
+	xchat_hook *(*xchat_hook_command) (xchat_plugin *ph,
+		    const char *name,
+		    int pri,
+		    int (*callback) (char *word[], char *word_eol[], void *user_data),
+		    const char *help_text,
+		    void *userdata);
+	xchat_hook *(*xchat_hook_server) (xchat_plugin *ph,
+		   const char *name,
+		   int pri,
+		   int (*callback) (char *word[], char *word_eol[], void *user_data),
+		   void *userdata);
+	xchat_hook *(*xchat_hook_print) (xchat_plugin *ph,
+		  const char *name,
+		  int pri,
+		  int (*callback) (char *word[], void *user_data),
+		  void *userdata);
+	xchat_hook *(*xchat_hook_timer) (xchat_plugin *ph,
+		  int timeout,
+		  int (*callback) (void *user_data),
+		  void *userdata);
+	xchat_hook *(*xchat_hook_fd) (xchat_plugin *ph,
+		   int fd,
+		   int flags,
+		   int (*callback) (int fd, int flags, void *user_data),
+		   void *userdata);
+	void *(*xchat_unhook) (xchat_plugin *ph,
+	      xchat_hook *hook);
+	void (*xchat_print) (xchat_plugin *ph,
+	     const char *text);
+	void (*xchat_printf) (xchat_plugin *ph,
+	      const char *format, ...);
+	void (*xchat_command) (xchat_plugin *ph,
+	       const char *command);
+	void (*xchat_commandf) (xchat_plugin *ph,
+		const char *format, ...);
+	int (*xchat_nickcmp) (xchat_plugin *ph,
+	       const char *s1,
+	       const char *s2);
+	int (*xchat_set_context) (xchat_plugin *ph,
+		   xchat_context *ctx);
+	xchat_context *(*xchat_find_context) (xchat_plugin *ph,
+		    const char *servname,
+		    const char *channel);
+	xchat_context *(*xchat_get_context) (xchat_plugin *ph);
+	const char *(*xchat_get_info) (xchat_plugin *ph,
+		const char *id);
+	int (*xchat_get_prefs) (xchat_plugin *ph,
+		 const char *name,
+		 const char **string,
+		 int *integer);
+	xchat_list * (*xchat_list_get) (xchat_plugin *ph,
+		const char *name);
+	void (*xchat_list_free) (xchat_plugin *ph,
+		 xchat_list *xlist);
+	const char * const * (*xchat_list_fields) (xchat_plugin *ph,
+		   const char *name);
+	int (*xchat_list_next) (xchat_plugin *ph,
+		 xchat_list *xlist);
+	const char * (*xchat_list_str) (xchat_plugin *ph,
+		xchat_list *xlist,
+		const char *name);
+	int (*xchat_list_int) (xchat_plugin *ph,
+		xchat_list *xlist,
+		const char *name);
+	void * (*xchat_plugingui_add) (xchat_plugin *ph,
+		     const char *filename,
+		     const char *name,
+		     const char *desc,
+		     const char *version,
+		     char *reserved);
+	void (*xchat_plugingui_remove) (xchat_plugin *ph,
+			void *handle);
+	int (*xchat_emit_print) (xchat_plugin *ph,
+			const char *event_name, ...);
+	int (*xchat_read_fd) (xchat_plugin *ph,
+			void *src,
+			char *buf,
+			int *len);
+	time_t (*xchat_list_time) (xchat_plugin *ph,
+		xchat_list *xlist,
+		const char *name);
+	char *(*xchat_gettext) (xchat_plugin *ph,
+		const char *msgid);
+	void (*xchat_send_modes) (xchat_plugin *ph,
+		  const char **targets,
+		  int ntargets,
+		  int modes_per_line,
+		  char sign,
+		  char mode);
+	char *(*xchat_strip) (xchat_plugin *ph,
+	     const char *str,
+	     int len,
+	     int flags);
+	void (*xchat_free) (xchat_plugin *ph,
+	    void *ptr);
+};
+#endif
+
+
+
+xchat_hook *
+xchat_hook_command (xchat_plugin *ph,
+		    const char *name,
+		    int pri,
+		    int (*callback) (char *word[], char *word_eol[], void *user_data),
+		    const char *help_text,
+		    void *userdata);
+
+xchat_hook *
+xchat_hook_server (xchat_plugin *ph,
+		   const char *name,
+		   int pri,
+		   int (*callback) (char *word[], char *word_eol[], void *user_data),
+		   void *userdata);
+
+xchat_hook *
+xchat_hook_print (xchat_plugin *ph,
+		  const char *name,
+		  int pri,
+		  int (*callback) (char *word[], void *user_data),
+		  void *userdata);
+
+xchat_hook *
+xchat_hook_timer (xchat_plugin *ph,
+		  int timeout,
+		  int (*callback) (void *user_data),
+		  void *userdata);
+
+xchat_hook *
+xchat_hook_fd (xchat_plugin *ph,
+		int fd,
+		int flags,
+		int (*callback) (int fd, int flags, void *user_data),
+		void *userdata);
+
+void *
+xchat_unhook (xchat_plugin *ph,
+	      xchat_hook *hook);
+
+void
+xchat_print (xchat_plugin *ph,
+	     const char *text);
+
+void
+xchat_printf (xchat_plugin *ph,
+	      const char *format, ...);
+
+void
+xchat_command (xchat_plugin *ph,
+	       const char *command);
+
+void
+xchat_commandf (xchat_plugin *ph,
+		const char *format, ...);
+
+int
+xchat_nickcmp (xchat_plugin *ph,
+	       const char *s1,
+	       const char *s2);
+
+int
+xchat_set_context (xchat_plugin *ph,
+		   xchat_context *ctx);
+
+xchat_context *
+xchat_find_context (xchat_plugin *ph,
+		    const char *servname,
+		    const char *channel);
+
+xchat_context *
+xchat_get_context (xchat_plugin *ph);
+
+const char *
+xchat_get_info (xchat_plugin *ph,
+		const char *id);
+
+int
+xchat_get_prefs (xchat_plugin *ph,
+		 const char *name,
+		 const char **string,
+		 int *integer);
+
+xchat_list *
+xchat_list_get (xchat_plugin *ph,
+		const char *name);
+
+void
+xchat_list_free (xchat_plugin *ph,
+		 xchat_list *xlist);
+
+const char * const *
+xchat_list_fields (xchat_plugin *ph,
+		   const char *name);
+
+int
+xchat_list_next (xchat_plugin *ph,
+		 xchat_list *xlist);
+
+const char *
+xchat_list_str (xchat_plugin *ph,
+		xchat_list *xlist,
+		const char *name);
+
+int
+xchat_list_int (xchat_plugin *ph,
+		xchat_list *xlist,
+		const char *name);
+
+time_t
+xchat_list_time (xchat_plugin *ph,
+		 xchat_list *xlist,
+		 const char *name);
+
+void *
+xchat_plugingui_add (xchat_plugin *ph,
+		     const char *filename,
+		     const char *name,
+		     const char *desc,
+		     const char *version,
+		     char *reserved);
+
+void
+xchat_plugingui_remove (xchat_plugin *ph,
+			void *handle);
+
+int 
+xchat_emit_print (xchat_plugin *ph,
+		  const char *event_name, ...);
+
+char *
+xchat_gettext (xchat_plugin *ph,
+	       const char *msgid);
+
+void
+xchat_send_modes (xchat_plugin *ph,
+		  const char **targets,
+		  int ntargets,
+		  int modes_per_line,
+		  char sign,
+		  char mode);
+
+char *
+xchat_strip (xchat_plugin *ph,
+	     const char *str,
+	     int len,
+	     int flags);
+
+void
+xchat_free (xchat_plugin *ph,
+	    void *ptr);
+
+#if !defined(PLUGIN_C) && defined(WIN32)
+#ifndef XCHAT_PLUGIN_HANDLE
+#define XCHAT_PLUGIN_HANDLE (ph)
+#endif
+#define xchat_hook_command ((XCHAT_PLUGIN_HANDLE)->xchat_hook_command)
+#define xchat_hook_server ((XCHAT_PLUGIN_HANDLE)->xchat_hook_server)
+#define xchat_hook_print ((XCHAT_PLUGIN_HANDLE)->xchat_hook_print)
+#define xchat_hook_timer ((XCHAT_PLUGIN_HANDLE)->xchat_hook_timer)
+#define xchat_hook_fd ((XCHAT_PLUGIN_HANDLE)->xchat_hook_fd)
+#define xchat_unhook ((XCHAT_PLUGIN_HANDLE)->xchat_unhook)
+#define xchat_print ((XCHAT_PLUGIN_HANDLE)->xchat_print)
+#define xchat_printf ((XCHAT_PLUGIN_HANDLE)->xchat_printf)
+#define xchat_command ((XCHAT_PLUGIN_HANDLE)->xchat_command)
+#define xchat_commandf ((XCHAT_PLUGIN_HANDLE)->xchat_commandf)
+#define xchat_nickcmp ((XCHAT_PLUGIN_HANDLE)->xchat_nickcmp)
+#define xchat_set_context ((XCHAT_PLUGIN_HANDLE)->xchat_set_context)
+#define xchat_find_context ((XCHAT_PLUGIN_HANDLE)->xchat_find_context)
+#define xchat_get_context ((XCHAT_PLUGIN_HANDLE)->xchat_get_context)
+#define xchat_get_info ((XCHAT_PLUGIN_HANDLE)->xchat_get_info)
+#define xchat_get_prefs ((XCHAT_PLUGIN_HANDLE)->xchat_get_prefs)
+#define xchat_list_get ((XCHAT_PLUGIN_HANDLE)->xchat_list_get)
+#define xchat_list_free ((XCHAT_PLUGIN_HANDLE)->xchat_list_free)
+#define xchat_list_fields ((XCHAT_PLUGIN_HANDLE)->xchat_list_fields)
+#define xchat_list_str ((XCHAT_PLUGIN_HANDLE)->xchat_list_str)
+#define xchat_list_int ((XCHAT_PLUGIN_HANDLE)->xchat_list_int)
+#define xchat_list_time ((XCHAT_PLUGIN_HANDLE)->xchat_list_time)
+#define xchat_list_next ((XCHAT_PLUGIN_HANDLE)->xchat_list_next)
+#define xchat_plugingui_add ((XCHAT_PLUGIN_HANDLE)->xchat_plugingui_add)
+#define xchat_plugingui_remove ((XCHAT_PLUGIN_HANDLE)->xchat_plugingui_remove)
+#define xchat_emit_print ((XCHAT_PLUGIN_HANDLE)->xchat_emit_print)
+#define xchat_gettext ((XCHAT_PLUGIN_HANDLE)->xchat_gettext)
+#define xchat_send_modes ((XCHAT_PLUGIN_HANDLE)->xchat_send_modes)
+#define xchat_strip ((XCHAT_PLUGIN_HANDLE)->xchat_strip)
+#define xchat_free ((XCHAT_PLUGIN_HANDLE)->xchat_free)
+#endif
+
+#ifdef __cplusplus
+}
+#endif
+#endif
diff --git a/plugins/xtray/resource.h b/plugins/xtray/resource.h
new file mode 100644
index 00000000..b8008c2c
--- /dev/null
+++ b/plugins/xtray/resource.h
@@ -0,0 +1,47 @@
+//{{NO_DEPENDENCIES}}
+// Microsoft Visual C++ generated include file.
+// Used by resource.rc
+//
+#define IDD_ALERTS                      104
+#define IDD_EVENTS                      105
+#define IDD_SETTINGS                    106
+#define IDD_ALERT                       107
+#define IDD_PREF                        108
+#define IDD_ABOUT                       109
+#define IDR_TRAY_MENU                   110
+#define ICO_XCHAT                       111
+#define ICO_BANNED                      112
+#define ICO_CHANMSG                     113
+#define ICO_DISCONNECTED                114
+#define ICO_HIGHLIGHT                   115
+#define ICO_KICKED                      116
+#define ICO_PMSG                        117
+#define ICO_SNOTICE                     118
+#define IDB_SD_LOGO                     119
+#define IDC_PREF_OK                     1014
+#define IDC_PREF_CANCEL                 1015
+#define IDC_PREF_APPLY                  1016
+#define IDC_AWAY_MSG                    1017
+#define IDC_ALERT_TIME                  1018
+#define IDC_TAB_CONTROL                 1019
+#define IDC_ALERT_HOTKEY                1020
+#define IDC_ALERT_MSG                   1021
+#define IDC_ALERT_HOTKEY_TEXT           1022
+#define IDC_ALERT_TIME_TEXT             1023
+#define ACT_EXIT                        40001
+#define ACT_SETTINGS                    40002
+#define ACT_AWAY                        40003
+#define ACT_BACK                        40004
+#define ACT_RESTORE                     40005
+#define IDC_STATIC                      -1
+
+// Next default values for new objects
+// 
+#ifdef APSTUDIO_INVOKED
+#ifndef APSTUDIO_READONLY_SYMBOLS
+#define _APS_NEXT_RESOURCE_VALUE        120
+#define _APS_NEXT_COMMAND_VALUE         40006
+#define _APS_NEXT_CONTROL_VALUE         1024
+#define _APS_NEXT_SYMED_VALUE           101
+#endif
+#endif
diff --git a/plugins/xtray/resource.rc b/plugins/xtray/resource.rc
new file mode 100644
index 00000000..906cf591
--- /dev/null
+++ b/plugins/xtray/resource.rc
@@ -0,0 +1,309 @@
+// Microsoft Visual C++ generated resource script.
+//
+#include "resource.h"
+
+#define APSTUDIO_READONLY_SYMBOLS
+/////////////////////////////////////////////////////////////////////////////
+//
+// Generated from the TEXTINCLUDE 2 resource.
+//
+#define APSTUDIO_HIDDEN_SYMBOLS
+#include "windows.h"
+#undef APSTUDIO_HIDDEN_SYMBOLS
+
+/////////////////////////////////////////////////////////////////////////////
+#undef APSTUDIO_READONLY_SYMBOLS
+
+/////////////////////////////////////////////////////////////////////////////
+// English (U.S.) resources
+
+#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
+#ifdef _WIN32
+LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
+#pragma code_page(1252)
+#endif //_WIN32
+
+/////////////////////////////////////////////////////////////////////////////
+//
+// Dialog
+//
+
+IDD_EVENTS DIALOGEX 8, 20, 216, 143
+STYLE DS_SETFONT | DS_SETFOREGROUND | WS_CHILD
+FONT 8, "Tahoma", 0, 0, 0x0
+BEGIN
+    GROUPBOX        "XChat Events",IDC_STATIC,5,5,205,77
+    CONTROL         "Banned",4,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,16,18,49,10
+    CONTROL         "Kicked",5,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,16,32,49,10
+    CONTROL         "Killed",8,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,16,46,49,10
+    CONTROL         "Disconnect",10,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,16,60,49,10
+    CONTROL         "Private Message",7,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,70,18,69,10
+    CONTROL         "Channel Message",21,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,70,32,69,10
+    CONTROL         "Highlight",1,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,70,46,69,10
+    CONTROL         "CTCP",6,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,70,60,69,10
+    CONTROL         "Topic Change",3,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,145,18,55,10
+    CONTROL         "Server Notice",9,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,145,32,55,10
+    CONTROL         "Invite",2,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,145,46,55,10
+END
+
+IDD_SETTINGS DIALOGEX 8, 20, 216, 143
+STYLE DS_SETFONT | WS_CHILD
+FONT 8, "Tahoma", 0, 0, 0x0
+BEGIN
+    GROUPBOX        "Options",IDC_STATIC,5,5,205,135
+    CONTROL         "Auto away on minimize",11,"Button",BS_AUTOCHECKBOX | 
+                    WS_TABSTOP,16,60,100,10
+    CONTROL         "Minimize XChat to the system tray",12,"Button",
+                    BS_AUTOCHECKBOX | WS_TABSTOP,16,18,133,10
+    CONTROL         "Minimize to the tray instead of closing",17,"Button",
+                    BS_AUTOCHECKBOX | WS_TABSTOP,16,32,174,9
+    EDITTEXT        IDC_AWAY_MSG,33,86,169,50,ES_AUTOHSCROLL
+    LTEXT           "Away Msg:",IDC_STATIC,27,72,35,8
+    CONTROL         "Remove XChat from the taskbar (only show in tray)",
+                    20,"Button",BS_AUTOCHECKBOX | WS_TABSTOP,16,46,191,9
+END
+
+IDD_ALERT DIALOGEX 0, 0, 151, 28
+STYLE DS_LOCALEDIT | DS_SETFONT | DS_NOIDLEMSG | DS_CENTER | WS_CAPTION | 
+    WS_SYSMENU
+EXSTYLE WS_EX_NOPARENTNOTIFY | WS_EX_ACCEPTFILES | WS_EX_TOOLWINDOW
+CAPTION "Event Name"
+FONT 8, "Tahoma", 0, 0, 0x1
+BEGIN
+    LTEXT           "Event Text",IDC_ALERT_MSG,3,0,147,27
+END
+
+IDD_PREF DIALOGEX 0, 0, 233, 190
+STYLE DS_SETFONT | DS_MODALFRAME | DS_CENTER | WS_POPUP | WS_CAPTION | 
+    WS_SYSMENU
+CAPTION "X-Tray Preferences"
+FONT 8, "Tahoma", 0, 0, 0x0
+BEGIN
+    DEFPUSHBUTTON   "Ok",IDC_PREF_OK,57,173,50,14
+    PUSHBUTTON      "Cancel",IDC_PREF_CANCEL,115,173,50,14
+    PUSHBUTTON      "Apply",IDC_PREF_APPLY,175,173,50,14
+    CONTROL         "Tab1",IDC_TAB_CONTROL,"SysTabControl32",0x0,7,7,218,159
+END
+
+IDD_ABOUT DIALOGEX 8, 20, 216, 143
+STYLE DS_SETFONT | WS_CHILD
+FONT 8, "Tahoma", 0, 0, 0x0
+BEGIN
+    CONTROL         119,IDC_STATIC,"Static",SS_BITMAP | SS_SUNKEN | 
+                    WS_BORDER,3,6,88,81
+    CTEXT           "X-Tray\r\nBy: Michael Hotaling\r\n www.SinisterDevelopments.com",
+                    IDC_STATIC,95,33,118,30
+    LTEXT           "Folken\r\nBasket\r\nDonatzsky\r\nDaemon404",IDC_STATIC,
+                    15,103,64,33
+    GROUPBOX        "Special Thanks To:",IDC_STATIC,3,91,89,50
+    GROUPBOX        "Version Information:",IDC_STATIC,101,92,109,49
+    LTEXT           "1.2.4",IDC_STATIC,170,105,33,8,0,WS_EX_RIGHT
+    LTEXT           "Compiled In: ",IDC_STATIC,110,117,54,8
+    LTEXT           "2011",IDC_STATIC,170,117,33,8,0,WS_EX_RIGHT
+    LTEXT           "Version Number:",IDC_STATIC,110,105,54,8
+END
+
+IDD_ALERTS DIALOGEX 8, 20, 216, 143
+STYLE DS_SETFONT | WS_CHILD
+FONT 8, "Tahoma", 0, 0, 0x0
+BEGIN
+    GROUPBOX        "Alerts",IDC_STATIC,5,5,205,117
+    CONTROL         "Only show alerts while minimized",14,"Button",
+                    BS_AUTOCHECKBOX | WS_TABSTOP,27,46,117,10
+    CONTROL         "Use tray alerts to notify me about events",13,"Button",
+                    BS_AUTOCHECKBOX | WS_TABSTOP,16,32,152,10
+    CONTROL         "Use window instead of balloons",15,"Button",
+                    BS_AUTOCHECKBOX | WS_TABSTOP,27,60,141,11
+    EDITTEXT        IDC_ALERT_TIME,137,101,61,12,ES_AUTOHSCROLL | ES_NUMBER,
+                    WS_EX_RIGHT
+    LTEXT           "Show alert for x seconds:",IDC_ALERT_TIME_TEXT,40,103,
+                    83,9
+    CONTROL         "Alert Hotkey",IDC_ALERT_HOTKEY,"msctls_hotkey32",
+                    WS_BORDER | WS_TABSTOP,137,74,61,13
+    LTEXT           "Close all alerts hotkey:",IDC_ALERT_HOTKEY_TEXT,39,75,
+                    76,10
+    CONTROL         "Leave alerts open indefinately",16,"Button",
+                    BS_AUTOCHECKBOX | WS_TABSTOP,27,88,115,11
+    CONTROL         "Blink Icon to alert me about events",18,"Button",
+                    BS_AUTOCHECKBOX | WS_TABSTOP,16,18,127,10
+END
+
+
+/////////////////////////////////////////////////////////////////////////////
+//
+// DESIGNINFO
+//
+
+#ifdef APSTUDIO_INVOKED
+GUIDELINES DESIGNINFO 
+BEGIN
+    IDD_EVENTS, DIALOG
+    BEGIN
+        BOTTOMMARGIN, 56
+    END
+
+    IDD_SETTINGS, DIALOG
+    BEGIN
+        BOTTOMMARGIN, 66
+    END
+
+    IDD_ALERT, DIALOG
+    BEGIN
+        RIGHTMARGIN, 150
+        BOTTOMMARGIN, 26
+    END
+
+    IDD_PREF, DIALOG
+    BEGIN
+        LEFTMARGIN, 7
+        RIGHTMARGIN, 232
+        TOPMARGIN, 7
+        BOTTOMMARGIN, 176
+    END
+
+    IDD_ABOUT, DIALOG
+    BEGIN
+        LEFTMARGIN, 7
+        RIGHTMARGIN, 209
+        TOPMARGIN, 7
+        BOTTOMMARGIN, 136
+    END
+
+    IDD_ALERTS, DIALOG
+    BEGIN
+        LEFTMARGIN, 7
+        RIGHTMARGIN, 208
+        TOPMARGIN, 7
+        BOTTOMMARGIN, 136
+    END
+END
+#endif    // APSTUDIO_INVOKED
+
+
+#ifdef APSTUDIO_INVOKED
+/////////////////////////////////////////////////////////////////////////////
+//
+// TEXTINCLUDE
+//
+
+1 TEXTINCLUDE 
+BEGIN
+    "resource.h\0"
+END
+
+2 TEXTINCLUDE 
+BEGIN
+    "#define APSTUDIO_HIDDEN_SYMBOLS\r\n"
+    "#include ""windows.h""\r\n"
+    "#undef APSTUDIO_HIDDEN_SYMBOLS\r\n"
+    "\0"
+END
+
+3 TEXTINCLUDE 
+BEGIN
+    "xtray.h\0"
+END
+
+4 TEXTINCLUDE 
+BEGIN
+    "\r\n"
+    "\0"
+END
+
+#endif    // APSTUDIO_INVOKED
+
+
+/////////////////////////////////////////////////////////////////////////////
+//
+// Version
+//
+
+VS_VERSION_INFO VERSIONINFO
+ FILEVERSION 1,2,4,0
+ PRODUCTVERSION 1,2,4,0
+ FILEFLAGSMASK 0x3fL
+#ifdef _DEBUG
+ FILEFLAGS 0x1L
+#else
+ FILEFLAGS 0x0L
+#endif
+ FILEOS 0x40004L
+ FILETYPE 0x2L
+ FILESUBTYPE 0x0L
+BEGIN
+    BLOCK "StringFileInfo"
+    BEGIN
+        BLOCK "040904b0"
+        BEGIN
+            VALUE "CompanyName", "SinisterDevelopments"
+            VALUE "FileDescription", "X-Tray"
+            VALUE "FileVersion", "1, 2, 4, 0"
+            VALUE "InternalName", "X-Tray"
+            VALUE "LegalCopyright", "Copyright � 2005"
+            VALUE "OriginalFilename", "xtray.dll"
+            VALUE "ProductName", "X-Tray - XChat Win32 System Tray Plugin"
+            VALUE "ProductVersion", "1, 2, 4, 0"
+        END
+    END
+    BLOCK "VarFileInfo"
+    BEGIN
+        VALUE "Translation", 0x409, 1200
+    END
+END
+
+
+/////////////////////////////////////////////////////////////////////////////
+//
+// Menu
+//
+
+IDR_TRAY_MENU MENU 
+BEGIN
+    POPUP "TRAY"
+    BEGIN
+        MENUITEM "Restore",                     ACT_RESTORE
+        MENUITEM SEPARATOR
+        MENUITEM "Away",                        65535
+        MENUITEM "Settings",                    ACT_SETTINGS
+        MENUITEM SEPARATOR
+        MENUITEM "Exit",                        ACT_EXIT
+    END
+END
+
+
+/////////////////////////////////////////////////////////////////////////////
+//
+// Icon
+//
+
+// Icon with lowest ID value placed first to ensure application icon
+// remains consistent on all systems.
+ICO_XCHAT               ICON                    "icons\\xchat.ico"
+ICO_BANNED              ICON                    "icons\\banned.ico"
+ICO_CHANMSG             ICON                    "icons\\chan_msg.ico"
+ICO_HIGHLIGHT           ICON                    "icons\\highlight.ico"
+ICO_KICKED              ICON                    "icons\\kicked.ico"
+ICO_PMSG                ICON                    "icons\\priv_msg-1-2-2.ico"
+ICO_SNOTICE             ICON                    "icons\\server_notice.ico"
+ICO_DISCONNECTED        ICON                    "icons\\disconnected.ico"
+
+/////////////////////////////////////////////////////////////////////////////
+//
+// Bitmap
+//
+
+IDB_SD_LOGO             BITMAP                  "bitmaps\\sd.bmp"
+#endif    // English (U.S.) resources
+/////////////////////////////////////////////////////////////////////////////
+
+
+
+#ifndef APSTUDIO_INVOKED
+/////////////////////////////////////////////////////////////////////////////
+//
+// Generated from the TEXTINCLUDE 3 resource.
+//
+xtray.h
+/////////////////////////////////////////////////////////////////////////////
+#endif    // not APSTUDIO_INVOKED
+
diff --git a/plugins/xtray/sdAlerts.cpp b/plugins/xtray/sdAlerts.cpp
new file mode 100644
index 00000000..5e042806
--- /dev/null
+++ b/plugins/xtray/sdAlerts.cpp
@@ -0,0 +1,109 @@
+/* X-Tray
+ * Copyright (C) 2005 Michael Hotaling <Mike.Hotaling@SinisterDevelopments.com>
+ *
+ * X-Tray is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ * 
+ * X-Tray is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with X-Tray; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+ */
+
+#include <windows.h>
+#include <winuser.h>
+#include <stdio.h>
+#include "utility.h"
+#include "resource.h"
+#include "sdAlerts.h"
+
+int g_iAlerts = 0;
+
+void sdSystemAlert(HINSTANCE hModule, UINT uiDialog, char *szMsg, char *szName, unsigned int iTime)
+{
+	TCHAR wszMsg[256];
+	TCHAR wszName[64];
+
+	HWND hDialog;
+	RECT rcWorkArea, rcDlg;
+	int ixPos, iyPos;
+	int iNumPerCol;
+	
+	hDialog = CreateDialog(hModule, MAKEINTRESOURCE(uiDialog), NULL, (DLGPROC)sdAlertProc);
+
+	SystemParametersInfo(SPI_GETWORKAREA, 0, &rcWorkArea, 0);
+	GetWindowRect(hDialog, &rcDlg);
+
+	iNumPerCol = ((rcWorkArea.bottom - rcWorkArea.top) / (rcDlg.bottom - rcDlg.top));
+	ixPos = rcWorkArea.right - (rcDlg.right - rcDlg.left) + 1;
+	iyPos = rcWorkArea.bottom - (rcDlg.bottom - rcDlg.top);
+
+	if((g_iAlerts >= iNumPerCol) && (iNumPerCol > 0))
+	{
+		ixPos -= ((g_iAlerts / iNumPerCol) * (rcDlg.right - rcDlg.left));
+		iyPos -= ((g_iAlerts - (iNumPerCol * (g_iAlerts / iNumPerCol))) * (rcDlg.bottom - rcDlg.top));
+	}
+	else
+	{
+		iyPos -= (g_iAlerts * (rcDlg.bottom - rcDlg.top));
+	}
+	SetWindowPos(hDialog, HWND_TOPMOST, ixPos, iyPos, 0, 0, SWP_NOSIZE | SWP_NOACTIVATE);
+	
+	ConvertString(szName, wszName, 64);
+	ConvertString(szMsg, wszMsg, 256);
+
+	SetWindowText(hDialog, wszName);
+	SetDlgItemText(hDialog, IDC_ALERT_MSG, wszMsg);
+	ShowWindow(hDialog, SW_SHOWNA);
+
+	if(iTime > 0)
+	{
+		SetTimer(hDialog, 1, iTime, NULL);
+	}
+
+	g_iAlerts++;
+}
+
+void sdCloseAlerts()
+{
+	PostMessage(HWND_BROADCAST, RegisterWindowMessage(TEXT("xTray:CloseAllAlertWindows")), 0, 0);
+}
+
+LRESULT CALLBACK sdAlertProc(HWND hwnd, UINT msg, WPARAM wparam, LPARAM lparam)
+{
+	switch(msg)
+	{
+	case WM_CLOSE:
+		if(g_iAlerts > 0){ g_iAlerts--; }
+		DestroyWindow(hwnd);
+		return TRUE;
+		break;
+	case WM_TIMER:
+		if(g_iAlerts > 0){ g_iAlerts--; }
+		AnimateWindow(hwnd, 600, AW_SLIDE | AW_HIDE | AW_VER_POSITIVE);
+		DestroyWindow(hwnd);
+		return TRUE;
+		break;
+	default:
+		if(msg == RegisterWindowMessage(TEXT("xTray:CloseAllAlertWindows")))
+		{
+			if(g_iAlerts > 0){ g_iAlerts--; }
+			DestroyWindow(hwnd);
+			return TRUE;
+		}
+		break;
+	}
+
+	return FALSE;
+}
+
+int sdAlertNum()
+{
+	return g_iAlerts;
+}
\ No newline at end of file
diff --git a/plugins/xtray/sdAlerts.h b/plugins/xtray/sdAlerts.h
new file mode 100644
index 00000000..cd45a05b
--- /dev/null
+++ b/plugins/xtray/sdAlerts.h
@@ -0,0 +1,26 @@
+/* X-Tray
+ * Copyright (C) 2005 Michael Hotaling <Mike.Hotaling@SinisterDevelopments.com>
+ *
+ * X-Tray is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ * 
+ * X-Tray is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with X-Tray; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+ */
+
+#ifndef _H_SDALERTS_H
+#define _H_SDALERTS_H
+
+void				sdSystemAlert	(HINSTANCE, UINT, char *, char *, UINT);
+LRESULT CALLBACK	sdAlertProc		(HWND, UINT, WPARAM, LPARAM);
+int					sdAlertNum		();
+void				sdCloseAlerts	();
+#endif
\ No newline at end of file
diff --git a/plugins/xtray/sdTray.cpp b/plugins/xtray/sdTray.cpp
new file mode 100644
index 00000000..3a91a61b
--- /dev/null
+++ b/plugins/xtray/sdTray.cpp
@@ -0,0 +1,207 @@
+/* X-Tray
+ * Copyright (C) 2005 Michael Hotaling <Mike.Hotaling@SinisterDevelopments.com>
+ *
+ * X-Tray is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ * 
+ * X-Tray is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with X-Tray; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+ */
+#define _WIN32_IE 0x601
+#include <windows.h>
+#include <stdio.h>
+#include <tchar.h>
+#include "sdTray.h"
+#include "utility.h"
+
+HANDLE hThread;
+iBlink *tData	= NULL;
+
+int AddIcon(HWND hwnd, UINT id, HICON hicon, char *szTip, unsigned short flags, unsigned int cbMsg)
+{
+	NOTIFYICONDATA nidata;
+
+	nidata.cbSize			= NOTIFYICONDATA_V2_SIZE;
+	nidata.hIcon			= hicon;
+	nidata.hWnd				= hwnd;
+	nidata.uCallbackMessage = cbMsg;
+	nidata.uFlags			= flags;
+	nidata.uID				= id;
+
+	if(szTip != NULL)
+	{
+		TCHAR *szTemp = new TCHAR[64];
+
+		ConvertString(szTip, szTemp, 64);
+		_tcsncpy(nidata.szTip, szTemp, 64);
+
+		delete[] szTemp;
+	}
+
+	return Shell_NotifyIcon(NIM_ADD, &nidata);
+}
+
+int RemoveIcon(HWND hwnd, UINT id)
+{
+	if(hThread != NULL)
+	{
+		TerminateThread(hThread, 0);
+		hThread = NULL;
+
+		delete tData;
+	}
+
+	NOTIFYICONDATA nidata;
+
+	nidata.cbSize = NOTIFYICONDATA_V2_SIZE;
+	nidata.hWnd   = hwnd;
+	nidata.uID    = id;
+
+	return Shell_NotifyIcon(NIM_DELETE, &nidata);
+}
+
+int SetIcon(HWND hwnd, UINT id, HICON hicon)
+{
+	NOTIFYICONDATA nidata;
+
+	nidata.cbSize = NOTIFYICONDATA_V2_SIZE;
+	nidata.hWnd   = hwnd;
+	nidata.uID    = id;
+	nidata.hIcon  = hicon;
+	nidata.uFlags = NIF_ICON;
+
+	return Shell_NotifyIcon(NIM_MODIFY, &nidata);
+}
+
+int SetTooltip(HWND hwnd, UINT id, char *szTip)
+{
+	NOTIFYICONDATA nidata;
+
+	nidata.cbSize = NOTIFYICONDATA_V2_SIZE;
+	nidata.hWnd   = hwnd;
+	nidata.uID    = id;
+	nidata.uFlags = NIF_TIP;
+
+	if(szTip != NULL)
+	{
+		TCHAR *szTemp = new TCHAR[64];
+		ConvertString(szTip, szTemp, 64);
+		_tcsncpy(nidata.szTip, szTemp, 64);
+		delete[] szTemp;
+	}
+
+	return Shell_NotifyIcon(NIM_MODIFY, &nidata);
+}
+
+int ShowBalloon(HWND hwnd, UINT id, char *szInfo, char *szTitle, UINT time, UINT infoFlags)
+{
+	NOTIFYICONDATA nidata;
+
+	nidata.cbSize	= NOTIFYICONDATA_V2_SIZE;
+	nidata.hWnd		= hwnd;
+	nidata.uID		= id;
+	nidata.uFlags	= NIF_INFO;
+	nidata.dwInfoFlags = infoFlags;
+
+	if(time > 0)
+		nidata.uTimeout = time;
+	else
+		nidata.uTimeout = 500000;
+
+	if(szInfo != NULL)
+	{
+		TCHAR *szTemp = new TCHAR[255];
+
+		ConvertString(szInfo, szTemp, 251);
+		szTemp[250] = 0;
+		
+		if(strlen(szInfo) > 255)
+		{
+			_sntprintf(szTemp, 255, _T("%s..."), szTemp);
+		}
+		_tcsncpy(nidata.szInfo, szTemp, 255);
+
+		delete[] szTemp;
+	}
+	if(szTitle != NULL)
+	{
+		TCHAR *wszTitle = new TCHAR[64];
+		ConvertString(szTitle, wszTitle, 64);
+		_tcsncpy(nidata.szInfoTitle, wszTitle, 64);
+		delete[] wszTitle;
+	}
+
+	return Shell_NotifyIcon(NIM_MODIFY, &nidata);
+}
+
+
+DWORD WINAPI BlinkThread(LPVOID lpParam)
+{
+	NOTIFYICONDATA nidata;
+
+	nidata.cbSize = NOTIFYICONDATA_V2_SIZE;
+	nidata.hWnd   = tData->hwnd;
+	nidata.uID    = tData->id;
+	nidata.uFlags = NIF_ICON;
+
+	for(UINT i = 0; i < tData->num; i++)
+	{
+		nidata.hIcon = tData->hBlink;
+		Shell_NotifyIcon(NIM_MODIFY, &nidata);
+
+		Sleep(tData->time);
+
+		nidata.hIcon = tData->hBase;
+		Shell_NotifyIcon(NIM_MODIFY, &nidata);
+
+		Sleep(tData->time);
+	}
+
+	delete tData;
+	hThread = NULL;
+
+	return 0;
+}
+
+int BlinkIcon(HWND hwnd, UINT id, HICON hBase, HICON hBlink, UINT time, UINT num)
+{
+	if(hThread != NULL)
+	{
+		StopBlink(hwnd, id, hBase);
+	}
+
+	DWORD dwThreadID;
+	tData = new iBlink;
+
+	tData->hwnd		= hwnd;
+	tData->id		= id;
+	tData->hBase	= hBase;
+	tData->hBlink	= hBlink;
+	tData->time		= time;
+	tData->num		= num;
+
+	hThread = CreateThread(NULL, 0, BlinkThread, tData, 0, &dwThreadID);
+
+	return 0;
+}
+
+void StopBlink(HWND hwnd, UINT id, HICON hBase)
+{
+	if(hThread != NULL)
+	{
+		TerminateThread(hThread, 0);
+		hThread = NULL;
+
+		delete tData;
+	}
+
+	SetIcon(hwnd, id, hBase);
+}
\ No newline at end of file
diff --git a/plugins/xtray/sdTray.h b/plugins/xtray/sdTray.h
new file mode 100644
index 00000000..68469fe0
--- /dev/null
+++ b/plugins/xtray/sdTray.h
@@ -0,0 +1,39 @@
+/* X-Tray
+ * Copyright (C) 2005 Michael Hotaling <Mike.Hotaling@SinisterDevelopments.com>
+ *
+ * X-Tray is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ * 
+ * X-Tray is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with X-Tray; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+ */
+
+#ifndef _H_SDTRAY_H
+#define _H_SDTRAY_H
+
+int				AddIcon		(HWND, UINT, HICON, char *, unsigned short, UINT);
+int				ShowBalloon	(HWND, UINT, char *, char *, UINT, UINT);
+int				BlinkIcon	(HWND, UINT, HICON, HICON, UINT, UINT);
+int				SetTooltip	(HWND, UINT, char *);
+int				SetIcon		(HWND, UINT, HICON);
+void			StopBlink	(HWND, UINT, HICON);
+int				RemoveIcon	(HWND, UINT);
+
+typedef struct IBLINK
+{
+	HICON hBase;
+	HICON hBlink;
+	HWND hwnd;
+	UINT id;
+	UINT time;
+	UINT num;
+}iBlink;
+#endif
\ No newline at end of file
diff --git a/plugins/xtray/utility.cpp b/plugins/xtray/utility.cpp
new file mode 100644
index 00000000..60f3f2f0
--- /dev/null
+++ b/plugins/xtray/utility.cpp
@@ -0,0 +1,563 @@
+/* X-Tray
+ * Copyright (C) 2005 Michael Hotaling <Mike.Hotaling@SinisterDevelopments.com>
+ *
+ * X-Tray is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ * 
+ * X-Tray is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with X-Tray; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+ */
+
+#include <windows.h>
+#include <stdio.h>
+#include <commctrl.h>
+#include <tchar.h>
+#include "utility.h"
+#include "plugin.h"
+#include "xtray.h"
+#include "callbacks.h"
+#include "resource.h"
+
+TCHAR BACKUP_INI_FILE[] = _T(".\\plugins\\config\\xtray.conf");
+struct HOTKEY g_hHotKey;
+
+void SavePrefs(int iDlg)
+{
+	/**************************************************************************************************/
+	/********** allocate space for our string, and then set it to the currently logged on user ********/
+	/**************************************************************************************************/
+	DWORD dBuff = 257;
+	TCHAR szUser[257];
+
+	GetUserName(szUser, &dBuff);
+
+	/**************************************************************************************************/
+	/*********************** Test if the file exists, If it doesn't, Create It ************************/
+	/**************************************************************************************************/
+	TCHAR XTRAY_INI_FILE[1024];
+	
+#ifdef UNICODE
+	char temp[1024];
+    TCHAR TEMP_INI_FILE[1024];
+	
+	_snprintf(temp, 1024, "%s\\xtray.conf", xchat_get_info(ph, "xchatdir"));
+	ConvertString(temp, TEMP_INI_FILE, 1024);
+
+	// ok this one is really ugly
+	// it checks to see if the file exists in two locations
+	// X-Chat default config dir, if that fails it trys xchat\plugins\config
+	// if neither one exists it tries to create it in
+	// X-Chat default config dir, if that fails it trys xchat\plugins\config
+	// In either case it writes \xFF\xFE to the file ( on creation )
+	// so that we can save unicode away messages WritePrivateProfile doesn't 
+	// do this for us, though I think it really should
+
+	if(FileExists(TEMP_INI_FILE))
+	{
+		_tcscpy(XTRAY_INI_FILE, TEMP_INI_FILE);
+	}
+	else
+	{
+		if(FileExists(BACKUP_INI_FILE))
+		{
+			_tcscpy(XTRAY_INI_FILE, BACKUP_INI_FILE);
+		}
+		else
+		{
+			HANDLE xTemp;
+			DWORD dwBytesTemp;
+
+			if(xTemp = CreateFile(TEMP_INI_FILE, GENERIC_WRITE, FILE_SHARE_READ, NULL, CREATE_NEW, FILE_ATTRIBUTE_NORMAL, NULL))
+			{
+				if(GetLastError() != ERROR_ALREADY_EXISTS)
+				{
+					WriteFile(xTemp, _T("\xFF\xFE"), 4, &dwBytesTemp, NULL);
+				}
+				CloseHandle(xTemp);
+			}
+
+			if(FileExists(TEMP_INI_FILE))
+			{
+				_tcscpy(XTRAY_INI_FILE, TEMP_INI_FILE);
+			}
+			else
+			{
+				HANDLE xBackup;
+				DWORD dwBytesBackup;
+
+				if(xBackup = CreateFile(TEMP_INI_FILE, GENERIC_WRITE, FILE_SHARE_READ, NULL, CREATE_NEW, FILE_ATTRIBUTE_NORMAL, NULL))
+				{
+					if(GetLastError() != ERROR_ALREADY_EXISTS)
+					{
+						WriteFile(xBackup, _T("\xFF\xFE"), 4, &dwBytesBackup, NULL);
+					}
+
+					CloseHandle(xBackup);
+				}
+
+				if(FileExists(BACKUP_INI_FILE))
+				{
+					_tcscpy(XTRAY_INI_FILE, BACKUP_INI_FILE);
+				}
+			}
+		}
+	}
+
+#else
+	_tcscpy(XTRAY_INI_FILE, BACKUP_INI_FILE);
+#endif
+
+	WritePrivateProfileInt(szUser, _T("SETTINGS"),		g_dwPrefs,		XTRAY_INI_FILE);
+	WritePrivateProfileInt(szUser, _T("AOT"),			g_iTime,		XTRAY_INI_FILE);
+	WritePrivateProfileInt(szUser, _T("KEY"),			g_hHotKey.key,	XTRAY_INI_FILE);
+	WritePrivateProfileInt(szUser, _T("MOD"),			g_hHotKey.mod,	XTRAY_INI_FILE);
+	WritePrivateProfileString(szUser, _T("AWAY"),		g_szAway,		XTRAY_INI_FILE);
+}
+
+void LoadPrefs()
+{
+	/**************************************************************************************************/
+	/*********************** Our Settings Section *****************************************************/
+	/**************************************************************************************************/
+	DWORD dBuff = 257;
+	TCHAR szUser[257];
+
+	GetUserName(szUser, &dBuff);
+
+	/**************************************************************************************************/
+	/*********************** Test if the file exists, If it doesn't, Create It ************************/
+	/**************************************************************************************************/
+	TCHAR XTRAY_INI_FILE[1024];
+
+#ifdef UNICODE
+	char temp[1024];
+	TCHAR TEMP_INI_FILE[1024];
+
+	_snprintf(temp, 1024, "%s\\xtray.conf", xchat_get_info(ph, "xchatdir"));
+	ConvertString(temp, TEMP_INI_FILE, 1024);
+
+	if(FileExists(TEMP_INI_FILE))
+	{
+		_tcscpy(XTRAY_INI_FILE, TEMP_INI_FILE);
+	}
+	else
+	{
+		if(FileExists(BACKUP_INI_FILE))
+		{
+			_tcscpy(XTRAY_INI_FILE, BACKUP_INI_FILE);
+		}
+		else
+		{
+			HANDLE xTemp;
+			DWORD dwBytesTemp;
+
+			if(xTemp = CreateFile(TEMP_INI_FILE, GENERIC_WRITE, FILE_SHARE_READ, NULL, CREATE_NEW, FILE_ATTRIBUTE_NORMAL, NULL))
+			{
+				if(GetLastError() != ERROR_ALREADY_EXISTS)
+				{
+					WriteFile(xTemp, _T("\xFF\xFE"), 4, &dwBytesTemp, NULL);
+				}
+
+				CloseHandle(xTemp);
+			}
+
+			if(FileExists(TEMP_INI_FILE))
+			{
+				_tcscpy(XTRAY_INI_FILE, TEMP_INI_FILE);
+			}
+			else
+			{
+				HANDLE xBackup;
+				DWORD dwBytesBackup;
+
+				if(xBackup = CreateFile(TEMP_INI_FILE, GENERIC_WRITE, FILE_SHARE_READ, NULL, CREATE_NEW, FILE_ATTRIBUTE_NORMAL, NULL))
+				{
+					if(GetLastError() != ERROR_ALREADY_EXISTS)
+					{
+						WriteFile(xBackup, _T("\xFF\xFE"), 4, &dwBytesBackup, NULL);
+					}
+
+					CloseHandle(xBackup);
+				}
+
+				if(FileExists(BACKUP_INI_FILE))
+				{
+					_tcscpy(XTRAY_INI_FILE, BACKUP_INI_FILE);
+				}
+			}
+		}
+	}
+
+#else
+	_tcscpy(XTRAY_INI_FILE, BACKUP_INI_FILE);
+#endif
+
+	/**************************************************************************************************/
+	/*************************** Get the value for each of our preferances ****************************/
+	/**************************************************************************************************/
+	g_dwPrefs = GetPrivateProfileInt(szUser, _T("SETTINGS"),	0,  XTRAY_INI_FILE);
+
+	// backwards compatability
+	// also allows us to set defaults if its a new installation
+	// disable topic change, channel message and server notice by default
+	if(g_dwPrefs == 0)
+	{
+		g_dwPrefs	|= (GetPrivateProfileInt(szUser, _T("HILIGHT"),		1,  XTRAY_INI_FILE)<<1);
+		g_dwPrefs	|= (GetPrivateProfileInt(szUser, _T("INVITE"),		1,  XTRAY_INI_FILE)<<2);
+		/* g_dwPrefs	|= (GetPrivateProfileInt(szUser, _T("TOPIC"),		1,  XTRAY_INI_FILE)<<3); */
+		g_dwPrefs	|= (GetPrivateProfileInt(szUser, _T("BANNED"),		1,  XTRAY_INI_FILE)<<4);
+		g_dwPrefs	|= (GetPrivateProfileInt(szUser, _T("KICKED"),		1,  XTRAY_INI_FILE)<<5);
+		g_dwPrefs	|= (GetPrivateProfileInt(szUser, _T("CTCP"),		1,  XTRAY_INI_FILE)<<6);
+		g_dwPrefs	|= (GetPrivateProfileInt(szUser, _T("PMSG"),		1,  XTRAY_INI_FILE)<<7);
+		g_dwPrefs	|= (GetPrivateProfileInt(szUser, _T("KILLED"),		1,  XTRAY_INI_FILE)<<8);
+		/* g_dwPrefs	|= (GetPrivateProfileInt(szUser, _T("NOTICE"),		1,  XTRAY_INI_FILE)<<9); */
+		g_dwPrefs	|= (GetPrivateProfileInt(szUser, _T("DISCONNECT"),	1,  XTRAY_INI_FILE)<<10);
+
+		g_dwPrefs	|= (GetPrivateProfileInt(szUser, _T("AOM"),			0,  XTRAY_INI_FILE)<<11);
+		g_dwPrefs	|= (GetPrivateProfileInt(szUser, _T("TOT"),			1,  XTRAY_INI_FILE)<<12);
+		g_dwPrefs	|= (GetPrivateProfileInt(szUser, _T("AMAE"),		1,  XTRAY_INI_FILE)<<13);
+		g_dwPrefs	|= (GetPrivateProfileInt(szUser, _T("OSBWM"),		0,  XTRAY_INI_FILE)<<14);
+		g_dwPrefs	|= (GetPrivateProfileInt(szUser, _T("UWIOB"),		0,  XTRAY_INI_FILE)<<15);
+		g_dwPrefs	|= (GetPrivateProfileInt(szUser, _T("KAOI"),		0,  XTRAY_INI_FILE)<<16);
+		g_dwPrefs	|= (GetPrivateProfileInt(szUser, _T("MIOC"),		0,  XTRAY_INI_FILE)<<17);
+	}
+	
+	g_hHotKey.key	= GetPrivateProfileInt(szUser, _T("KEY"),	84, XTRAY_INI_FILE);
+	g_hHotKey.mod	= GetPrivateProfileInt(szUser, _T("MOD"),	(MOD_CONTROL | MOD_SHIFT),  XTRAY_INI_FILE);
+	g_iTime			= GetPrivateProfileInt(szUser, _T("AOT"),	5,  XTRAY_INI_FILE);
+
+	GetPrivateProfileString(szUser, _T("AWAY"), _T(""),	g_szAway, 1024, XTRAY_INI_FILE);
+	
+	/**************************************************************************************************/
+	/******************************** Register our hotkey with windows ********************************/
+	/**************************************************************************************************/
+	if(g_dwPrefs & (1<<PREF_UWIOB))
+	{
+		RegisterHotKey(g_hHotkeyWnd, 1, g_hHotKey.mod, g_hHotKey.key);
+	}
+}
+
+void CheckPrefs(HWND hwnd, int iDlg)
+{
+	/**************************************************************************************************/
+	/**************** save the preferances based on the checkmarks/options ****************************/
+	/**************************************************************************************************/
+	switch(iDlg)
+	{
+	case IDD_EVENTS:
+		{
+			SetOption(hwnd, CHAN_HILIGHT,		CHAN_HILIGHT);
+			SetOption(hwnd, CHAN_INVITE,		CHAN_INVITE);
+			SetOption(hwnd, CHAN_TOPIC_CHANGE,	CHAN_TOPIC_CHANGE);
+			SetOption(hwnd, CHAN_BANNED,		CHAN_BANNED);
+			SetOption(hwnd, CHAN_KICKED,		CHAN_KICKED);
+			SetOption(hwnd, CTCP_GENERIC,		CTCP_GENERIC);
+			SetOption(hwnd, PMSG_RECEIVE,		PMSG_RECEIVE);
+			SetOption(hwnd, SERV_KILLED,		SERV_KILLED);
+			SetOption(hwnd, SERV_NOTICE,		SERV_NOTICE);
+			SetOption(hwnd, SERV_DISCONNECT,	SERV_DISCONNECT);
+			SetOption(hwnd, CHAN_MESSAGE,		CHAN_MESSAGE);
+		}
+		break;
+	case IDD_ALERTS:
+		{
+			SetOption(hwnd, PREF_AMAE,	PREF_AMAE);
+			SetOption(hwnd, PREF_OSBWM,	PREF_OSBWM);
+			SetOption(hwnd, PREF_UWIOB,	PREF_UWIOB);
+			SetOption(hwnd, PREF_KAOI,	PREF_KAOI);
+			SetOption(hwnd, PREF_BLINK,	PREF_BLINK);
+
+			/**************************************************************************/
+			/**************************************************************************/
+			/**************************************************************************/
+			TCHAR tTime[512];
+
+			GetWindowText(GetDlgItem(hwnd, IDC_ALERT_TIME), tTime, 511);
+			
+			g_iTime = _tstoi(tTime);
+			
+			/**************************************************************************/
+			/**************** Get our Hotkey and save it                     **********/
+			/**************** then remove the old hotkey and add the new one **********/
+			/**************************************************************************/
+			DWORD hHotkey;
+			hHotkey = SendDlgItemMessage(hwnd, IDC_ALERT_HOTKEY, HKM_GETHOTKEY, 0, 0);
+			
+			g_hHotKey.key = LOBYTE(hHotkey);
+			g_hHotKey.mod = HIBYTE(hHotkey);
+			
+			if(IsDlgButtonChecked(hwnd, PREF_UWIOB) == BST_CHECKED)
+			{
+				UnregisterHotKey(g_hHotkeyWnd, 1);
+				RegisterHotKey(g_hHotkeyWnd, 1, g_hHotKey.mod, g_hHotKey.key);
+			}
+			else
+			{
+				UnregisterHotKey(g_hHotkeyWnd, 1);
+			}
+
+			/*************************************************************************/
+			/*********** Get and save the away msg and alert time ********************/
+			/*************************************************************************/
+		}
+		break;
+	case IDD_SETTINGS:
+		{
+			SetOption(hwnd, PREF_AOM, PREF_AOM);
+			SetOption(hwnd, PREF_TOT, PREF_TOT);
+			SetOption(hwnd, PREF_MIOC, PREF_MIOC);
+			SetOption(hwnd, PREF_DNSIT, PREF_DNSIT);
+
+			GetDlgItemText(hwnd, IDC_AWAY_MSG, g_szAway, 511);
+
+			if(g_dwPrefs & (1<<PREF_DNSIT))
+			{
+				DWORD dwStyle;
+				dwStyle = GetWindowLong(g_hXchatWnd, GWL_STYLE);
+				dwStyle |= (1<<WS_CHILD);
+				SetWindowLongPtr(g_hXchatWnd, GWL_STYLE, (LONG_PTR)dwStyle);
+				SetWindowLongPtr(g_hXchatWnd, GWL_HWNDPARENT, (LONG_PTR)g_hHotkeyWnd);
+			}
+			else
+			{
+				DWORD dwStyle;
+				dwStyle = GetWindowLong(g_hXchatWnd, GWL_STYLE);
+				dwStyle &= ~(1<<WS_CHILD);
+				SetWindowLongPtr(g_hXchatWnd, GWL_STYLE, (LONG_PTR)dwStyle);
+				SetWindowLongPtr(g_hXchatWnd, GWL_HWNDPARENT, NULL);
+			}
+		}
+		break;
+	} 
+}
+
+void SetDialog(HWND hwnd, int iDlg)
+{
+	switch(iDlg)
+	{
+	case IDD_EVENTS:
+		{
+			SetCheck(hwnd, CHAN_HILIGHT,		CHAN_HILIGHT);
+			SetCheck(hwnd, CHAN_INVITE,			CHAN_INVITE);
+			SetCheck(hwnd, CHAN_TOPIC_CHANGE,	CHAN_TOPIC_CHANGE);
+			SetCheck(hwnd, CHAN_BANNED,			CHAN_BANNED);
+			SetCheck(hwnd, CHAN_KICKED,			CHAN_KICKED);
+			SetCheck(hwnd, CTCP_GENERIC,		CTCP_GENERIC);
+			SetCheck(hwnd, PMSG_RECEIVE,		PMSG_RECEIVE);
+			SetCheck(hwnd, SERV_KILLED,			SERV_KILLED);
+			SetCheck(hwnd, SERV_NOTICE,			SERV_NOTICE);
+			SetCheck(hwnd, SERV_DISCONNECT,		SERV_DISCONNECT);
+			SetCheck(hwnd, CHAN_MESSAGE,		CHAN_MESSAGE);
+		}
+		break;
+	case IDD_SETTINGS:
+		{
+			SetCheck(hwnd, PREF_TOT,	PREF_TOT);
+			SetCheck(hwnd, PREF_MIOC,	PREF_MIOC);
+			SetCheck(hwnd, PREF_AOM,	PREF_AOM);
+			SetCheck(hwnd, PREF_DNSIT,	PREF_DNSIT);
+
+			SetDlgItemText(hwnd, IDC_AWAY_MSG, g_szAway);
+		}
+		break;
+	case IDD_ALERTS:
+		{
+			
+			SetCheck(hwnd, PREF_BLINK,	PREF_BLINK);
+			SetCheck(hwnd, PREF_OSBWM,	PREF_OSBWM);
+			SetCheck(hwnd, PREF_UWIOB,	PREF_UWIOB);
+			SetCheck(hwnd, PREF_KAOI,	PREF_KAOI);
+
+			/**********************************************************/
+			/**********************************************************/
+			/**********************************************************/
+			if(SetCheck(hwnd, PREF_AMAE, PREF_AMAE) == false)
+			{
+				SetToggle(hwnd, PREF_OSBWM,				PREF_AMAE, TRUE);
+				SetToggle(hwnd, PREF_UWIOB,				PREF_AMAE, TRUE);
+				SetToggle(hwnd, PREF_KAOI,				PREF_AMAE, TRUE);
+				SetToggle(hwnd, IDC_ALERT_TIME,			PREF_AMAE, TRUE);
+				SetToggle(hwnd, IDC_ALERT_TIME_TEXT,	PREF_AMAE, TRUE);
+				SetToggle(hwnd, IDC_ALERT_HOTKEY,		PREF_AMAE, TRUE);
+				SetToggle(hwnd, IDC_ALERT_HOTKEY_TEXT,	PREF_AMAE, TRUE);
+			}
+			else
+			{
+
+				SetToggle(hwnd, IDC_ALERT_HOTKEY,		PREF_UWIOB, TRUE);
+				SetToggle(hwnd, IDC_ALERT_HOTKEY_TEXT,	PREF_UWIOB, TRUE);
+				SetToggle(hwnd, IDC_ALERT_TIME,			PREF_KAOI, FALSE);
+				SetToggle(hwnd, IDC_ALERT_TIME_TEXT,	PREF_KAOI, FALSE);
+			}
+
+			/**********************************************************/
+			/**********************************************************/
+			/**********************************************************/
+			TCHAR tTime[255];
+			SendDlgItemMessage(hwnd, IDC_ALERT_TIME,	WM_SETTEXT, 0, (LPARAM)_itot(g_iTime, tTime, 10));
+			SendDlgItemMessage(hwnd, IDC_ALERT_HOTKEY,	HKM_SETHOTKEY, MAKEWORD(g_hHotKey.key, g_hHotKey.mod), 0);
+		}
+		break;
+	}
+}
+
+int SetCheck(HWND hDialog, unsigned int uiCheckBox, unsigned int uiPref)
+{
+	if((g_dwPrefs & (1<<uiPref)))
+	{
+		CheckDlgButton(hDialog, uiCheckBox, BST_CHECKED);
+		return 1;
+	}
+	else
+	{
+		CheckDlgButton(hDialog, uiCheckBox, BST_UNCHECKED);
+		return 0;
+	}
+
+	return 0;
+}
+
+int SetToggle(HWND hDialog, unsigned int uiCheckBox, unsigned int uiTestbox, bool offeqoff)
+{
+	/**************************************************************************************************/
+	/*********************** if(true) then if option is off turn toggle off ***************************/
+	/*********************** if(false) then if option is off turn toggle on ***************************/
+	/**************************************************************************************************/
+	if(offeqoff)
+	{
+		if(IsDlgButtonChecked(hDialog, uiTestbox) == BST_CHECKED)
+		{
+			EnableWindow(GetDlgItem(hDialog, uiCheckBox), TRUE);
+			return 1;
+		}
+		else
+		{
+			EnableWindow(GetDlgItem(hDialog, uiCheckBox), FALSE);
+			return 0;
+		}
+	}
+	else
+	{
+		if(IsDlgButtonChecked(hDialog, uiTestbox) == BST_CHECKED)
+		{
+			EnableWindow(GetDlgItem(hDialog, uiCheckBox), FALSE);
+			return 1;
+		}
+		else
+		{
+			EnableWindow(GetDlgItem(hDialog, uiCheckBox), TRUE);
+			return 0;
+		}
+	}
+
+	return 0;
+}
+
+int SetOption(HWND hDialog, unsigned int uiCheckBox, unsigned int uiPref)
+{
+	if(IsDlgButtonChecked(hDialog, uiCheckBox) == BST_CHECKED)
+	{
+		g_dwPrefs |= (1<<uiPref);
+	}
+	else
+	{
+		g_dwPrefs &= ~(1<<uiPref);
+	}
+
+	return (g_dwPrefs & (1<<uiPref));
+}
+
+int WritePrivateProfileIntA(char *szSection, char *szItem, int iData, char *szPath)
+{
+	char szData[33];
+	itoa(iData, szData, 10);
+	return WritePrivateProfileStringA(szSection, szItem, szData, szPath);
+}
+
+int WritePrivateProfileIntW(wchar_t *wszSection, wchar_t *wszItem, int iData, wchar_t *wszPath)
+{
+	wchar_t wszData[33];
+	_itow(iData, wszData, 10);
+	return WritePrivateProfileStringW(wszSection, wszItem, wszData, wszPath);
+}
+
+// For cleanup ( Closing windows and the such )
+void HoldClose()
+{
+	HANDLE hcThread;
+	DWORD dwThreadID;
+	hcThread = CreateThread(NULL, 0, HoldCloseThread, 0, 0, &dwThreadID);
+}
+
+DWORD WINAPI HoldCloseThread(LPVOID lpParam)
+{
+	Sleep(1000);
+	PostMessage(g_hXchatWnd, WM_CLOSE, 0, 0);
+	return 0;
+}
+
+bool FileExists(TCHAR *file)
+{
+	HANDLE hTemp = CreateFile(file, GENERIC_READ, FILE_SHARE_READ, NULL, OPEN_EXISTING, FILE_ATTRIBUTE_NORMAL, NULL);
+	int nRet = GetLastError();
+	CloseHandle(hTemp);
+
+	if(nRet == 0)
+	{
+		return true;
+	}
+	else
+	{
+		return false;
+	}
+
+	return false;
+}
+
+void ConvertString(const char *in, wchar_t *out, int size)
+{
+	MultiByteToWideChar(CP_UTF8, 0, in,  -1, out, size);
+}
+
+void ConvertString(const wchar_t *in, char *out, int size)
+{
+	WideCharToMultiByte(CP_UTF8, 0, in, (size - 1), out, size, NULL, NULL);
+}
+
+void ConvertString(const char *in, char *out, int size)
+{
+	strncpy(out, in, size);
+}
+
+void ErrorDebug(LPTSTR lpszFunction)
+{ 
+    TCHAR szBuf[80]; 
+    LPVOID lpMsgBuf;
+    DWORD dw = GetLastError(); 
+
+    FormatMessage(
+        FORMAT_MESSAGE_ALLOCATE_BUFFER | 
+        FORMAT_MESSAGE_FROM_SYSTEM,
+        NULL,
+        dw,
+        MAKELANGID(LANG_NEUTRAL, SUBLANG_DEFAULT),
+        (LPTSTR) &lpMsgBuf,
+        0, NULL );
+
+    _stprintf(szBuf, 
+        _T("%s failed with error %d: %s"), 
+        lpszFunction, dw, lpMsgBuf); 
+ 
+    MessageBox(NULL, szBuf, _T("Error"), MB_OK); 
+
+    LocalFree(lpMsgBuf);
+}
+
diff --git a/plugins/xtray/utility.h b/plugins/xtray/utility.h
new file mode 100644
index 00000000..ce3d541c
--- /dev/null
+++ b/plugins/xtray/utility.h
@@ -0,0 +1,52 @@
+/* X-Tray
+ * Copyright (C) 2005 Michael Hotaling <Mike.Hotaling@SinisterDevelopments.com>
+ *
+ * X-Tray is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ * 
+ * X-Tray is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with X-Tray; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+ */
+
+#ifndef _H_UTILITY_H
+#define _H_UTILITY_H
+
+int						SetOption		(HWND, unsigned int, unsigned int);
+int						SetCheck		(HWND, unsigned int, unsigned int);
+int						SetToggle		(HWND, unsigned int, unsigned int, bool);
+void					ErrorDebug		(LPTSTR lpszFunction);
+void					SetDialog		(HWND, int);
+void					CheckPrefs		(HWND, int);
+bool					FileExists		(TCHAR *);
+DWORD WINAPI			HoldCloseThread	(LPVOID);
+void					SavePrefs		(int);
+void					LoadPrefs		();
+void					HoldClose		();
+
+void ConvertString(const char *in,		wchar_t *out,	int size);
+void ConvertString(const wchar_t *in,	char *out,		int size);
+void ConvertString(const char *in,		char *out,		int size);
+
+int WritePrivateProfileIntA(char *, char *, int, char *);
+int WritePrivateProfileIntW(wchar_t *, wchar_t *, int, wchar_t *);
+
+#ifdef UNICODE
+#define WritePrivateProfileInt WritePrivateProfileIntW
+#else
+#define WritePrivateProfileInt WritePrivateProfileIntA
+#endif
+
+struct HOTKEY
+{
+	WORD key;
+	WORD mod;
+};
+#endif
\ No newline at end of file
diff --git a/plugins/xtray/xchat.cpp b/plugins/xtray/xchat.cpp
new file mode 100644
index 00000000..581970f1
--- /dev/null
+++ b/plugins/xtray/xchat.cpp
@@ -0,0 +1,319 @@
+/* X-Tray
+ * Copyright (C) 1998, 2005 Peter Zelezny, Michael Hotaling <Mike.Hotaling@SinisterDevelopments.com>
+ *
+ * X-Tray is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ * 
+ * X-Tray is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with X-Tray; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+ */
+
+#include <windows.h>
+#include <vector>
+#include <algorithm>
+#include <stdio.h>
+#include <tchar.h>
+#include "plugin.h"
+#include "xtray.h"
+#include "resource.h"
+#include "xchat.h"
+#include "utility.h"
+
+// from util.c of xchat source code ( slightly modified to fit X-Tray Syntax )
+char *xchat_strip_color (char *text)
+{
+	int nc	= 0;
+	int i	= 0;
+	int col	= 0;
+	int len	= strlen(text);
+	char *new_str = (char *)malloc(len + 2);
+
+	while (len > 0)
+	{
+		if ((col && isdigit(*text) && (nc < 2)) || (col && isdigit(*(text+1)) && (nc < 3) && (*text == ',')))
+		{
+			nc++;
+
+			if(*text == ',')
+			{
+				nc = 0;
+			}
+		}
+		else
+		{
+			col = 0;
+
+			switch (*text)
+			{
+			case '\003':			  /*ATTR_COLOR: */
+				{
+					col = 1;
+					nc = 0;
+				}
+				break;
+			case '\007':			  /*ATTR_BEEP: */
+			case '\017':			  /*ATTR_RESET: */
+			case '\026':			  /*ATTR_REVERSE: */
+			case '\002':			  /*ATTR_BOLD: */
+			case '\037':			  /*ATTR_UNDERLINE: */
+				break;
+			default:
+				{
+					new_str[i] = *text;
+					i++;
+				}
+				break;
+			}
+		}
+
+		text++;
+		len--;
+	}
+
+	new_str[i] = 0;
+
+	return new_str;
+}
+
+void check_special_chars (char *cmd)
+{
+	int occur	= 0;
+	int len		= strlen (cmd);
+	int i = 0, j = 0;
+	char *buf;
+
+	if (!len)
+		return;
+
+	buf = (char *)malloc (len + 1);
+
+	if (buf)
+	{
+		while (cmd[j])
+		{
+			switch (cmd[j])
+			{
+			case '%':
+				{
+					occur++;
+
+					switch (cmd[j + 1])
+					{
+					case 'R':
+						buf[i] = '\026';
+						break;
+					case 'U':
+						buf[i] = '\037';
+						break;
+					case 'B':
+						buf[i] = '\002';
+						break;
+					case 'C':
+						buf[i] = '\003';
+						break;
+					case 'O':
+						buf[i] = '\017';
+						break;
+					case '%':
+						buf[i] = '%';
+						break;
+					default:
+						buf[i] = '%';
+						j--;
+						break;
+					}
+
+					j++;
+				}
+				break;
+			default:
+				{
+					buf[i] = cmd[j];
+				}
+				break;
+			}
+
+			j++;
+			i++;
+		}
+
+		buf[i] = 0;
+
+		if (occur)
+			strcpy (cmd, buf);
+
+		free (buf);
+	}
+}
+
+void xchat_globally_away(TCHAR *tszAway)
+{
+	char szTemp[512];
+	char szAway[512];
+
+	ConvertString(tszAway, szAway, 512);
+	_snprintf(szTemp, 512, "ALLSERV AWAY %s\0", szAway);
+	check_special_chars(szTemp);
+	xchat_exec(szTemp);
+}
+
+void xchat_away(TCHAR *tszAway)
+{
+	char szTemp[512];
+	char szAway[512];
+
+	ConvertString(tszAway, szAway, 512);
+	_snprintf(szTemp, 512, szAway);
+	check_special_chars(szTemp);
+	xchat_commandf(ph, "AWAY %s\0", szTemp);
+}
+
+void xchat_globally_back()
+{
+	std::vector<int> xs;
+	std::vector<int>::iterator xsi;
+	xchat_list *xl = xchat_list_get(ph, "channels");
+
+	if(xl)
+	{
+		while(xchat_list_next(ph, xl))
+		{
+			xsi = std::find(xs.begin(), xs.end(), xchat_list_int(ph, xl, "id"));
+
+			if((xsi == xs.end()) &&
+				((strlen(xchat_list_str(ph, xl, "server")) > 0) || 
+				(strlen(xchat_list_str(ph, xl, "channel")) > 0)))
+			{
+				xs.push_back(xchat_list_int(ph, xl, "id"));
+				xchat_set_context(ph, (xchat_context *)xchat_list_str(ph, xl, "context"));
+				xchat_back();
+			}
+		}
+
+		xchat_list_free(ph, xl);
+	}
+}
+
+
+
+void xchat_back()
+{
+	if(xchat_get_info(ph, "away"))
+	{
+		xchat_command(ph, "BACK");
+	}
+}
+
+HMENU setServerMenu()
+{
+	HMENU sTemp = CreateMenu();
+	TCHAR wszServer[128];
+	TCHAR wszNick[128];
+	TCHAR wszMenuEntry[256];
+
+	std::vector<int> xs;
+	std::vector<int>::iterator xsi;
+	xchat_list *xl = xchat_list_get(ph, "channels");
+
+	AppendMenu(sTemp, MF_STRING, ACT_AWAY, _T("Set Globally Away"));
+	AppendMenu(sTemp, MF_STRING, ACT_BACK, _T("Set Globally Back"));
+	AppendMenu(sTemp, MF_SEPARATOR, 0, NULL);
+
+	if(xl)
+	{
+		while(xchat_list_next(ph, xl))
+		{
+			xsi = std::find(xs.begin(), xs.end(), xchat_list_int(ph, xl, "id"));
+
+			if( (xsi == xs.end()) &&
+				((strlen(xchat_list_str(ph, xl, "server")) > 0) || 
+				(strlen(xchat_list_str(ph, xl, "channel")) > 0)))
+			{
+				xchat_set_context(ph, (xchat_context *)xchat_list_str(ph, xl, "context"));
+				xs.push_back(xchat_list_int(ph, xl, "id"));
+
+				char *network	= _strdup(xchat_list_str(ph, xl, "network"));
+				char *server	= _strdup(xchat_list_str(ph, xl, "server"));
+				char *nick		= _strdup(xchat_get_info(ph, "nick"));
+
+				if(network != NULL)
+				{
+					ConvertString(network, wszServer, 128);
+				}
+				else
+				{
+					ConvertString(server, wszServer, 128);
+				}
+
+				if(server != NULL)
+				{
+					ConvertString(nick, wszNick, 128);
+					_sntprintf(wszMenuEntry, 256, _T("%s @ %s\0"), wszNick, wszServer);
+
+					if(!xchat_get_info(ph, "away"))
+					{
+						AppendMenu(sTemp, MF_STRING, (xchat_list_int(ph, xl, "id") + 1), wszMenuEntry);
+					}
+					else
+					{
+						AppendMenu(sTemp, (MF_CHECKED | MF_STRING), (xchat_list_int(ph, xl, "id") + 1), wszMenuEntry);							
+					}
+				}
+
+				free(network);
+				free(server);
+				free(nick);
+			}
+		}
+
+		xchat_list_free(ph, xl);
+	}
+
+	return sTemp;
+}
+
+struct _xchat_context *xchat_find_server(int find_id)
+{
+	xchat_context *xc;
+	xchat_list *xl = xchat_list_get(ph, "channels");
+	int id;
+
+	if(!xl)
+		return NULL;
+
+	while(xchat_list_next(ph, xl))
+	{
+		id = xchat_list_int(ph, xl, "id");
+		
+		if(id == -1)
+		{
+			return NULL;
+		}
+		else if(id == find_id)
+		{
+			xc = (xchat_context *)xchat_list_str(ph, xl, "context");
+			
+			xchat_list_free(ph, xl);
+
+			return xc;
+		}
+	}
+
+	xchat_list_free(ph, xl);
+
+	return NULL;
+}
+
+void xchat_exec(char *command)
+{
+	xchat_set_context(ph, xchat_find_context(ph, NULL, NULL));
+	xchat_command(ph, command);
+}
\ No newline at end of file
diff --git a/plugins/xtray/xchat.h b/plugins/xtray/xchat.h
new file mode 100644
index 00000000..76452aeb
--- /dev/null
+++ b/plugins/xtray/xchat.h
@@ -0,0 +1,32 @@
+/* X-Tray
+ * Copyright (C) 2005 Michael Hotaling <Mike.Hotaling@SinisterDevelopments.com>
+ *
+ * X-Tray is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ * 
+ * X-Tray is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with X-Tray; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+ */
+
+#ifndef _H_XCHAT_H
+#define _H_XCHAT_H
+
+void					xchat_exec			(char *);
+char					*xchat_strip_color	(char *);
+void					xchat_parse			(char *);
+struct _xchat_context	*xchat_find_server	(int);
+void					xchat_globally_away	(TCHAR *);
+void					xchat_away			(TCHAR *);
+void					xchat_globally_back	();
+void					xchat_back			();
+HMENU					setServerMenu		();
+
+#endif
\ No newline at end of file
diff --git a/plugins/xtray/xtray.cpp b/plugins/xtray/xtray.cpp
new file mode 100644
index 00000000..a7c8c8bd
--- /dev/null
+++ b/plugins/xtray/xtray.cpp
@@ -0,0 +1,219 @@
+/* X-Tray
+ * Copyright (C) 2005 Michael Hotaling <Mike.Hotaling@SinisterDevelopments.com>
+ *
+ * X-Tray is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ * 
+ * X-Tray is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with X-Tray; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+ */
+
+#define _WIN32_IE 0x0601
+
+#include <windows.h>
+#include <list>
+#include <string>
+#include <shobjidl.h>
+#include "resource.h"
+#include "callbacks.h"
+#include "plugin.h"
+#include "utility.h"
+#include "xtray.h"
+#include "sdTray.h"
+#include "sdAlerts.h"
+#include "plugin.h"
+
+/*****************************************************/
+/**** Don't want to pollute the namespace do we? *****/
+/*****************************************************/
+std::list<xchat_hook *> g_vHooks;
+
+/*****************************************************/
+/************ Global Identifiers *********************/
+/*****************************************************/
+WNDPROC g_hOldProc;
+xchat_plugin *ph;
+
+/*****************************************************/
+/***************** Resources *************************/
+/*****************************************************/
+HWND	g_hXchatWnd;
+HWND	g_hHotkeyWnd;
+HWND	g_hPrefDlg;
+HMENU	g_hTrayMenu;
+HICON	g_hIcons[11];
+HANDLE	g_hInstance;
+/*****************************************************/
+/***************** Preferences ***********************/
+/*****************************************************/
+unsigned int g_dwPrefs;
+TCHAR	g_szAway[512];
+int		g_iTime;
+
+
+BOOL WINAPI DllMain(HANDLE hModule, DWORD fdwReason, LPVOID lpVoid)
+{
+	if((fdwReason == DLL_PROCESS_ATTACH) || (fdwReason == DLL_THREAD_ATTACH))
+	{
+		g_hInstance = hModule;
+	}
+
+	return TRUE;
+}
+
+int xchat_plugin_init(xchat_plugin *plugin_handle, char **plugin_name, char **plugin_desc, char **plugin_version, char *arg)
+{
+	ph = plugin_handle;
+
+	*plugin_name	= "X-Tray";
+	*plugin_desc	= "Minimize XChat to the Windows system tray";
+	*plugin_version = "1.2.4";
+
+	/***************************************************************************************************************************/
+	/************************* Load our preferances from xTray.ini *************************************************************/
+	/***************************************************************************************************************************/
+	LoadPrefs();
+
+	/***************************************************************************************************************************/
+	/************************* Finds the xChat window and saves it for later use ***********************************************/
+	/***************************************************************************************************************************/
+	g_hXchatWnd = (HWND)xchat_get_info(ph, "win_ptr");
+
+	if(g_hXchatWnd == NULL)
+	{
+		EnumThreadWindows(GetCurrentThreadId(), EnumWindowsProc, 0);
+	}
+
+	g_hOldProc	= (WNDPROC)GetWindowLongPtr(g_hXchatWnd, GWLP_WNDPROC);
+	SetWindowLongPtr(g_hXchatWnd, GWLP_WNDPROC, (LONG_PTR)WindowProc);
+
+	/***************************************************************************************************************************/	
+	/************************* Grab the xChat Icon, Load our menu, create the window to receive the hotkey messages  ***********/
+	/************************* and register the windows message so we know if explorer crashes                       ***********/
+	/***************************************************************************************************************************/
+	g_hTrayMenu		= GetSubMenu(LoadMenu((HINSTANCE)g_hInstance, MAKEINTRESOURCE(IDR_TRAY_MENU)), 0);
+	g_hHotkeyWnd	= CreateDialog((HINSTANCE)g_hInstance, MAKEINTRESOURCE(IDD_ALERT), NULL,		(DLGPROC)HotKeyProc);
+	g_hPrefDlg		= CreateDialog((HINSTANCE)g_hInstance, MAKEINTRESOURCE(IDD_PREF),  g_hXchatWnd, (DLGPROC)PrefProc);
+
+	g_hIcons[0]	= (HICON)LoadImage((HINSTANCE)g_hInstance, MAKEINTRESOURCE(ICO_XCHAT),			IMAGE_ICON, 16, 16, LR_DEFAULTCOLOR);
+	g_hIcons[1]	= (HICON)LoadImage((HINSTANCE)g_hInstance, MAKEINTRESOURCE(ICO_CHANMSG),		IMAGE_ICON, 16, 16, LR_DEFAULTCOLOR);
+	g_hIcons[2]	= (HICON)LoadImage((HINSTANCE)g_hInstance, MAKEINTRESOURCE(ICO_HIGHLIGHT),		IMAGE_ICON, 16, 16, LR_DEFAULTCOLOR);
+	g_hIcons[5]	= (HICON)LoadImage((HINSTANCE)g_hInstance, MAKEINTRESOURCE(ICO_BANNED),			IMAGE_ICON, 16, 16, LR_DEFAULTCOLOR);
+	g_hIcons[6]	= (HICON)LoadImage((HINSTANCE)g_hInstance, MAKEINTRESOURCE(ICO_KICKED),			IMAGE_ICON, 16, 16, LR_DEFAULTCOLOR);
+	g_hIcons[8]	= (HICON)LoadImage((HINSTANCE)g_hInstance, MAKEINTRESOURCE(ICO_PMSG),			IMAGE_ICON, 16, 16, LR_DEFAULTCOLOR);
+	g_hIcons[10]= (HICON)LoadImage((HINSTANCE)g_hInstance, MAKEINTRESOURCE(ICO_SNOTICE),		IMAGE_ICON, 16, 16, LR_DEFAULTCOLOR);
+	g_hIcons[11]= (HICON)LoadImage((HINSTANCE)g_hInstance, MAKEINTRESOURCE(ICO_DISCONNECTED),	IMAGE_ICON, 16, 16, LR_DEFAULTCOLOR);
+
+	/***************************************************************************************************************************/
+	/************************* Add our icon to the tray ************************************************************************/
+	/***************************************************************************************************************************/
+	char szVersion[64];
+	_snprintf(szVersion, 64, "XChat-WDK [%s]", xchat_get_info(ph, "version"));
+	AddIcon(g_hXchatWnd, 1, g_hIcons[0], szVersion, (NIF_ICON | NIF_MESSAGE | NIF_TIP), WM_TRAYMSG);
+
+	/***************************************************************************************************************************/
+	/***************************************************************************************************************************/
+	/***************************************************************************************************************************/
+	if(g_dwPrefs & (1<<PREF_DNSIT))
+	{
+		DWORD dwStyle;
+		dwStyle = GetWindowLong(g_hXchatWnd, GWL_STYLE);
+		dwStyle |= (1<<WS_CHILD);
+		SetWindowLongPtr(g_hXchatWnd, GWL_STYLE, (LONG_PTR)dwStyle);
+		SetWindowLongPtr(g_hXchatWnd, GWL_HWNDPARENT, (LONG_PTR)g_hHotkeyWnd);
+	}
+
+	/***************************************************************************************************************************/
+	/************************* Set our hooks and save them for later so we can unhook them *************************************/
+	/***************************************************************************************************************************/
+	g_vHooks.push_back(xchat_hook_print(ph, "Channel Msg Hilight",			XCHAT_PRI_NORM, event_cb,	(void *)CHAN_HILIGHT));
+	g_vHooks.push_back(xchat_hook_print(ph, "Channel Message",				XCHAT_PRI_NORM, event_cb,	(void *)CHAN_MESSAGE));
+	g_vHooks.push_back(xchat_hook_print(ph, "Topic Change",					XCHAT_PRI_NORM, event_cb,	(void *)CHAN_TOPIC_CHANGE));
+	g_vHooks.push_back(xchat_hook_print(ph, "Channel Action Hilight",		XCHAT_PRI_NORM, event_cb,	(void *)CHAN_HILIGHT));
+	g_vHooks.push_back(xchat_hook_print(ph, "Channel INVITE",				XCHAT_PRI_NORM, event_cb,	(void *)CHAN_INVITE));
+	g_vHooks.push_back(xchat_hook_print(ph, "You Kicked",					XCHAT_PRI_NORM, event_cb,	(void *)CHAN_KICKED));
+	g_vHooks.push_back(xchat_hook_print(ph, "Banned",						XCHAT_PRI_NORM, event_cb,	(void *)CHAN_BANNED));
+	g_vHooks.push_back(xchat_hook_print(ph, "CTCP Generic",					XCHAT_PRI_NORM, event_cb,	(void *)CTCP_GENERIC));
+	g_vHooks.push_back(xchat_hook_print(ph, "Private Message",				XCHAT_PRI_NORM, event_cb,	(void *)PMSG_RECEIVE));
+	g_vHooks.push_back(xchat_hook_print(ph, "Private Message to Dialog",	XCHAT_PRI_NORM, event_cb,	(void *)PMSG_RECEIVE));
+	g_vHooks.push_back(xchat_hook_print(ph, "Disconnected",					XCHAT_PRI_NORM, event_cb,	(void *)SERV_DISCONNECT));
+	g_vHooks.push_back(xchat_hook_print(ph, "Killed",						XCHAT_PRI_NORM, event_cb,	(void *)SERV_KILLED));
+	g_vHooks.push_back(xchat_hook_print(ph, "Notice",						XCHAT_PRI_NORM, event_cb,	(void *)SERV_NOTICE));
+	g_vHooks.push_back(xchat_hook_command(ph, "tray_alert",					XCHAT_PRI_NORM, command_cb,	"Create an Alert", NULL));
+
+	return 1;
+}
+
+int xchat_plugin_deinit(xchat_plugin *plugin_handle)
+{
+	/******************************************/
+	/****** Remove the Icon from the tray *****/
+	/******************************************/
+	StopBlink(g_hXchatWnd, 1, g_hIcons[0]);
+	RemoveIcon(g_hXchatWnd, 1);
+	
+	/*******************************************/
+	/*******************************************/
+	/*******************************************/
+	if(g_dwPrefs & (1<<PREF_DNSIT))
+	{
+		DWORD dwStyle;
+		dwStyle = GetWindowLong(g_hXchatWnd, GWL_STYLE);
+		dwStyle &= ~(1<<WS_CHILD);
+		SetWindowLongPtr(g_hXchatWnd, GWL_STYLE, (LONG_PTR)dwStyle);
+		SetWindowLongPtr(g_hXchatWnd, GWL_HWNDPARENT, NULL);
+	}
+
+	/******************************************/
+	/****** Unload our resources **************/
+	/******************************************/
+	DestroyMenu(g_hTrayMenu);
+
+	for(int i = 0; i <= 11; i++)
+	{
+		DestroyIcon(g_hIcons[i]);
+	}
+
+	/******************************************/
+	/****** Remove our window hook ************/
+	/******************************************/
+	SetWindowLongPtr(g_hXchatWnd, GWLP_WNDPROC, (LONG_PTR)g_hOldProc);
+
+	/******************************************/
+	/****** Remove our hotkey, and destroy ****/
+	/****** the window that receives its   ****/
+	/****** messages                       ****/
+	/******************************************/
+	UnregisterHotKey(g_hHotkeyWnd, 1);
+	DestroyWindow(g_hHotkeyWnd);
+	DestroyWindow(g_hPrefDlg);
+
+	/******************************************/
+	/************* Clean up Isle 7 ************/
+	/******************************************/
+	if(sdAlertNum())
+	{
+		sdCloseAlerts();
+	}
+	/******************************************/
+	/****** remove our xchat_hook_*s **********/
+	/******************************************/
+	while(!g_vHooks.empty())
+	{
+		if(g_vHooks.back() != NULL)
+		{
+			xchat_unhook(ph, g_vHooks.back());
+		}
+		g_vHooks.pop_back();
+	}
+
+	return 1;
+}
diff --git a/plugins/xtray/xtray.h b/plugins/xtray/xtray.h
new file mode 100644
index 00000000..56323cf2
--- /dev/null
+++ b/plugins/xtray/xtray.h
@@ -0,0 +1,77 @@
+/* X-Tray
+ * Copyright (C) 2005 Michael Hotaling <Mike.Hotaling@SinisterDevelopments.com>
+ *
+ * X-Tray is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ * 
+ * X-Tray is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ * 
+ * You should have received a copy of the GNU General Public License
+ * along with X-Tray; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
+ */
+
+#ifndef _XTRAY_H
+#define _XTRAY_H
+
+/******************** Globals *************************/
+extern HWND				g_hXchatWnd;
+extern HWND				g_hHotkeyWnd;
+extern HWND				g_hPrefDlg;
+extern HMENU			g_hTrayMenu;
+extern HICON			g_hIcons[11];
+extern HANDLE			g_hInstance;
+extern unsigned int		g_dwPrefs;
+extern TCHAR			g_szAway[512];
+extern int				g_iTime;
+extern WNDPROC			g_hOldProc;
+extern struct _xchat_plugin *ph;
+/******************************************************/
+
+/******************** Messages ************************/
+#define WM_TRAYMSG WM_APP
+/******************************************************/
+
+/********************* Events *************************/
+#define CHAN_HILIGHT			1
+#define CHAN_INVITE				2
+#define CHAN_TOPIC_CHANGE		3
+#define CHAN_BANNED				4
+#define CHAN_KICKED				5
+
+#define CTCP_GENERIC			6
+#define PMSG_RECEIVE			7
+
+#define SERV_KILLED				8
+#define SERV_NOTICE				9
+#define SERV_DISCONNECT			10
+
+/* new events */
+#define CHAN_MESSAGE			21
+
+#define PREF_AOM				11 // away on minimize
+#define PREF_TOT				12 // Tray on Taskbar
+#define PREF_AMAE				13 // alert me about events
+#define PREF_OSBWM				14 // Only Show Balloon When Minimized
+#define PREF_UWIOB				15 // Use Window Instead of Balloon
+#define PREF_KAOI				16 // Keep alerts open indefinately
+#define PREF_MIOC				17 // Minimize instead of close
+#define PREF_BLINK				18 // blink icon
+#define PREF_CICO				19 // change icon - not implemented
+#define PREF_DNSIT				20 // Do not show in taskbar
+/******************************************************/
+#endif
+
+#ifdef _WIN64
+/* use replacement with the same value, and use SetWindowLongPtr instead
+   of SetWindowLong. more info:
+
+   http://msdn.microsoft.com/en-us/library/ms633591.aspx
+   http://msdn.microsoft.com/en-us/library/ms644898.aspx */
+#define GWL_HWNDPARENT GWLP_HWNDPARENT
+#endif
-- 
cgit 1.4.1


From 31297031119aa50cf4fb241be1aa7f917786e686 Mon Sep 17 00:00:00 2001
From: "berkeviktor@aol.com" <berkeviktor@aol.com>
Date: Sat, 16 Apr 2011 19:48:59 +0200
Subject: update the update checker plugin according to google code hosting
 changes, preserve the file in default branch for a while for compatibility
 reasons

---
 plugins/upd/upd.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

(limited to 'plugins')

diff --git a/plugins/upd/upd.c b/plugins/upd/upd.c
index 001cd9d2..a3a6acc4 100644
--- a/plugins/upd/upd.c
+++ b/plugins/upd/upd.c
@@ -42,7 +42,7 @@ check_version ()
 		return "Unknown";
 	}
 
-	hFile = InternetOpenUrl (hINet, "http://xchat-wdk.googlecode.com/hg/version.txt", NULL, 0, 0, 0);
+	hFile = InternetOpenUrl (hINet, "http://xchat-wdk.googlecode.com/hg/version.txt?r=wdk", NULL, 0, 0, 0);
 	
 	if (hFile)
 	{
@@ -91,7 +91,7 @@ xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugi
 
 	*plugin_name = "Update Checker";
 	*plugin_desc = "Plugin for checking for XChat-WDK updates";
-	*plugin_version = "1.2";
+	*plugin_version = "1.3";
 
 	xchat_hook_command (ph, "UPDCHK", XCHAT_PRI_NORM, print_version, 0, 0);
 	xchat_command (ph, "MENU -ietc\\download.png ADD \"Help/Check for Updates\" \"UPDCHK\"");
-- 
cgit 1.4.1


From 24ac838543bc99ea8d289925b4c5418107d5ae1f Mon Sep 17 00:00:00 2001
From: "berkeviktor@aol.com" <berkeviktor@aol.com>
Date: Mon, 30 May 2011 22:52:02 +0200
Subject: add support for Perl 5.14

---
 build/build-x64.bat           |  4 ++++
 build/build-x86.bat           |  4 ++++
 build/release-x64.bat         |  1 +
 build/release-x86.bat         |  1 +
 build/xchat-wdk.skel.iss      |  4 ++++
 plugins/perl/makefile-514.mak | 30 ++++++++++++++++++++++++++++++
 src/makeinc.skel.mak          |  4 ++++
 7 files changed, 48 insertions(+)
 create mode 100644 plugins/perl/makefile-514.mak

(limited to 'plugins')

diff --git a/build/build-x64.bat b/build/build-x64.bat
index 6f49dae2..5375809e 100644
--- a/build/build-x64.bat
+++ b/build/build-x64.bat
@@ -1,6 +1,7 @@
 @echo off
 set PERL_510=c:\mozilla-build\perl-5.10-x64
 set PERL_512=c:\mozilla-build\perl-5.12-x64
+set PERL_514=c:\mozilla-build\perl-5.14-x64
 cd ..
 set DEV_64=%cd%\dep-x64
 cd src
@@ -30,6 +31,9 @@ nmake /nologo /s /f makefile-510.mak
 set PATH=%OOPATH%;%PERL_512%\bin
 nmake /nologo /s /f makefile-512.mak clean
 nmake /nologo /s /f makefile-512.mak
+set PATH=%OOPATH%;%PERL_514%\bin
+nmake /nologo /s /f makefile-514.mak clean
+nmake /nologo /s /f makefile-514.mak
 cd ..\..\build
 set PATH=%OPATH%
 call release-x64.bat
diff --git a/build/build-x86.bat b/build/build-x86.bat
index 7776ee4d..b8ee8052 100644
--- a/build/build-x86.bat
+++ b/build/build-x86.bat
@@ -1,6 +1,7 @@
 @echo off
 set PERL_510=c:\mozilla-build\perl-5.10-x86
 set PERL_512=c:\mozilla-build\perl-5.12-x86
+set PERL_514=c:\mozilla-build\perl-5.14-x86
 echo [Setup] > xchat-wdk.iss
 echo WizardImageFile=%cd%\bitmaps\wizardimage.bmp >> xchat-wdk.iss
 echo WizardSmallImageFile=%cd%\bitmaps\wizardsmallimage.bmp >> xchat-wdk.iss
@@ -31,6 +32,9 @@ nmake /nologo /s /f makefile-510.mak
 set PATH=%OOPATH%;%PERL_512%\bin
 nmake /nologo /s /f makefile-512.mak clean
 nmake /nologo /s /f makefile-512.mak
+set PATH=%OOPATH%;%PERL_514%\bin
+nmake /nologo /s /f makefile-514.mak clean
+nmake /nologo /s /f makefile-514.mak
 cd ..\..\build
 call compile-po-files.bat
 set PATH=%OPATH%
diff --git a/build/release-x64.bat b/build/release-x64.bat
index ddb070b6..50ae1e64 100644
--- a/build/release-x64.bat
+++ b/build/release-x64.bat
@@ -36,6 +36,7 @@ copy ..\plugins\lua\xclua.dll %XCHAT_DEST%\plugins\xclua.dll.x64
 copy ..\plugins\mpcinfo\xcmpcinfo.dll %XCHAT_DEST%\plugins\xcmpcinfo.dll.x64
 copy ..\plugins\perl\xcperl-510.dll %XCHAT_DEST%\plugins\xcperl-510.dll.x64
 copy ..\plugins\perl\xcperl-512.dll %XCHAT_DEST%\plugins\xcperl-512.dll.x64
+copy ..\plugins\perl\xcperl-514.dll %XCHAT_DEST%\plugins\xcperl-514.dll.x64
 copy ..\plugins\python\xcpython.dll %XCHAT_DEST%\plugins\xcpython.dll.x64
 copy ..\plugins\tcl\xctcl.dll %XCHAT_DEST%\plugins\xctcl.dll.x64
 copy ..\plugins\upd\xcupd.dll %XCHAT_DEST%\plugins\xcupd.dll.x64
diff --git a/build/release-x86.bat b/build/release-x86.bat
index c33e981c..05ad7df5 100644
--- a/build/release-x86.bat
+++ b/build/release-x86.bat
@@ -48,6 +48,7 @@ copy ..\plugins\lua\xclua.dll %XCHAT_DEST%\plugins
 copy ..\plugins\mpcinfo\xcmpcinfo.dll %XCHAT_DEST%\plugins
 copy ..\plugins\perl\xcperl-510.dll %XCHAT_DEST%\plugins
 copy ..\plugins\perl\xcperl-512.dll %XCHAT_DEST%\plugins
+copy ..\plugins\perl\xcperl-514.dll %XCHAT_DEST%\plugins
 copy ..\plugins\python\xcpython.dll %XCHAT_DEST%\plugins
 copy ..\plugins\tcl\xctcl.dll %XCHAT_DEST%\plugins
 copy ..\plugins\upd\xcupd.dll %XCHAT_DEST%\plugins
diff --git a/build/xchat-wdk.skel.iss b/build/xchat-wdk.skel.iss
index 86b9904a..dccd58ff 100644
--- a/build/xchat-wdk.skel.iss
+++ b/build/xchat-wdk.skel.iss
@@ -57,6 +57,7 @@ Name: x64; Description: "x64"; GroupDescription: "XChat-WDK version:"; Flags: ex
 
 Name: perl510; Description: "5.10"; GroupDescription: "Perl version:"; Flags: exclusive unchecked; Components: langs\perl
 Name: perl512; Description: "5.12"; GroupDescription: "Perl version:"; Flags: exclusive; Components: langs\perl
+Name: perl514; Description: "5.14"; GroupDescription: "Perl version:"; Flags: exclusive; Components: langs\perl
 
 Name: portable; Description: "Yes"; GroupDescription: "Portable Install (no Registry entries, no Start Menu icons, no uninstaller):"; Flags: unchecked
 
@@ -228,6 +229,9 @@ Source: "plugins\xcperl-510.dll.x64"; DestDir: "{app}\plugins"; DestName: "xcper
 Source: "plugins\xcperl-512.dll"; DestDir: "{app}\plugins"; DestName: "xcperl.dll"; Components: langs\perl; Tasks: x86 and perl512
 Source: "plugins\xcperl-512.dll.x64"; DestDir: "{app}\plugins"; DestName: "xcperl.dll"; Components: langs\perl; Tasks: x64 and perl512
 
+Source: "plugins\xcperl-514.dll"; DestDir: "{app}\plugins"; DestName: "xcperl.dll"; Components: langs\perl; Tasks: x86 and perl514
+Source: "plugins\xcperl-514.dll.x64"; DestDir: "{app}\plugins"; DestName: "xcperl.dll"; Components: langs\perl; Tasks: x64 and perl514
+
 [Icons]
 Name: "{group}\XChat-WDK"; Filename: "{app}\xchat.exe"; Tasks: not portable
 Name: "{group}\XChat-Text"; Filename: "{app}\xchat-text.exe"; Components: xctext; Tasks: not portable
diff --git a/plugins/perl/makefile-514.mak b/plugins/perl/makefile-514.mak
new file mode 100644
index 00000000..94ee456f
--- /dev/null
+++ b/plugins/perl/makefile-514.mak
@@ -0,0 +1,30 @@
+include "..\..\src\makeinc.mak"
+
+DIRENTLIB = ..\..\src\common\dirent.lib
+TARGET = $(PERL514OUTPUT)
+
+all: $(TARGET)
+
+perl.def:
+	echo EXPORTS > perl.def
+	echo xchat_plugin_init >> perl.def
+	echo xchat_plugin_deinit >> perl.def
+	echo xchat_plugin_get_info >> perl.def
+
+perl.obj: perl.c
+	$(CC) $(CFLAGS) perl.c $(GLIB) /I$(PERL514PATH) /I.. /DPERL_DLL=\"$(PERL514LIB).dll\"
+
+perl.c: xchat.pm.h
+
+xchat.pm.h: lib/Xchat.pm lib/IRC.pm
+	perl.exe generate_header
+
+$(TARGET): perl.obj perl.def
+	$(LINK) /DLL /out:$(TARGET) perl.obj $(LDFLAGS) $(PERL514LIB).lib /libpath:$(PERL514PATH) /DELAYLOAD:$(PERL514LIB).dll $(DIRENTLIB) DELAYIMP.LIB user32.lib shell32.lib advapi32.lib /def:perl.def
+
+clean:
+	@del $(TARGET)
+	@del *.obj
+	@del perl.def
+	@del *.lib
+	@del *.exp
diff --git a/src/makeinc.skel.mak b/src/makeinc.skel.mak
index c9027992..f7bbeeb7 100644
--- a/src/makeinc.skel.mak
+++ b/src/makeinc.skel.mak
@@ -18,6 +18,8 @@ PERL510LIB = perl510
 PERL510OUTPUT = xcperl-510.dll
 PERL512LIB = perl512
 PERL512OUTPUT = xcperl-512.dll
+PERL514LIB = perl514
+PERL514OUTPUT = xcperl-514.dll
 
 PYTHONLIB = python27
 PYTHONOUTPUT = xcpython.dll
@@ -32,6 +34,7 @@ LDFLAGS = $(LDFLAGS) msvcrt_win2003.obj
 
 PERL510PATH = c:\mozilla-build\perl-5.10-x64\lib\CORE
 PERL512PATH = c:\mozilla-build\perl-5.12-x64\lib\CORE
+PERL514PATH = c:\mozilla-build\perl-5.14-x64\lib\CORE
 PYTHONPATH = c:\mozilla-build\python-2.7-x64
 TCLPATH = c:\mozilla-build\tcl-8.5-x64
 !else
@@ -39,6 +42,7 @@ LDFLAGS = $(LDFLAGS) msvcrt_winxp.obj
 
 PERL510PATH = c:\mozilla-build\perl-5.10-x86\lib\CORE
 PERL512PATH = c:\mozilla-build\perl-5.12-x86\lib\CORE
+PERL514PATH = c:\mozilla-build\perl-5.14-x86\lib\CORE
 PYTHONPATH = c:\mozilla-build\python-2.7-x86
 TCLPATH = c:\mozilla-build\tcl-8.5-x86
 !endif
-- 
cgit 1.4.1


From 70f870fc961e9594ac41707e944b5bf364164c43 Mon Sep 17 00:00:00 2001
From: "berkeviktor@aol.com" <berkeviktor@aol.com>
Date: Wed, 27 Jul 2011 04:51:28 +0200
Subject: remove perl 5.10, migrate 5.12 to strawberry

---
 build/build-x64.bat           |  6 +-----
 build/build-x86.bat           |  6 +-----
 build/release-x64.bat         |  1 -
 build/release-x86.bat         |  1 -
 build/xchat-wdk.skel.iss      |  4 ----
 plugins/perl/makefile-510.mak | 30 ------------------------------
 src/makeinc.skel.mak          |  8 ++------
 7 files changed, 4 insertions(+), 52 deletions(-)
 delete mode 100644 plugins/perl/makefile-510.mak

(limited to 'plugins')

diff --git a/build/build-x64.bat b/build/build-x64.bat
index 5375809e..29db6400 100644
--- a/build/build-x64.bat
+++ b/build/build-x64.bat
@@ -1,6 +1,5 @@
 @echo off
-set PERL_510=c:\mozilla-build\perl-5.10-x64
-set PERL_512=c:\mozilla-build\perl-5.12-x64
+set PERL_512=c:\mozilla-build\perl-5.12-x64\perl
 set PERL_514=c:\mozilla-build\perl-5.14-x64
 cd ..
 set DEV_64=%cd%\dep-x64
@@ -25,9 +24,6 @@ nmake /nologo /f makefile.mak clean
 nmake /nologo /f makefile.mak
 cd perl
 set OOPATH=%PATH%
-set PATH=%OOPATH%;%PERL_510%\bin
-nmake /nologo /s /f makefile-510.mak clean
-nmake /nologo /s /f makefile-510.mak
 set PATH=%OOPATH%;%PERL_512%\bin
 nmake /nologo /s /f makefile-512.mak clean
 nmake /nologo /s /f makefile-512.mak
diff --git a/build/build-x86.bat b/build/build-x86.bat
index b8ee8052..c2df1c25 100644
--- a/build/build-x86.bat
+++ b/build/build-x86.bat
@@ -1,6 +1,5 @@
 @echo off
-set PERL_510=c:\mozilla-build\perl-5.10-x86
-set PERL_512=c:\mozilla-build\perl-5.12-x86
+set PERL_512=c:\mozilla-build\perl-5.12-x86\perl
 set PERL_514=c:\mozilla-build\perl-5.14-x86
 echo [Setup] > xchat-wdk.iss
 echo WizardImageFile=%cd%\bitmaps\wizardimage.bmp >> xchat-wdk.iss
@@ -26,9 +25,6 @@ nmake /nologo /f makefile.mak clean
 nmake /nologo /f makefile.mak
 cd perl
 set OOPATH=%PATH%
-set PATH=%OOPATH%;%PERL_510%\bin
-nmake /nologo /s /f makefile-510.mak clean
-nmake /nologo /s /f makefile-510.mak
 set PATH=%OOPATH%;%PERL_512%\bin
 nmake /nologo /s /f makefile-512.mak clean
 nmake /nologo /s /f makefile-512.mak
diff --git a/build/release-x64.bat b/build/release-x64.bat
index 50ae1e64..e22043e9 100644
--- a/build/release-x64.bat
+++ b/build/release-x64.bat
@@ -34,7 +34,6 @@ copy %DEPS_ROOT%\lib\enchant\libenchant_myspell.dll %XCHAT_DEST%\lib\enchant\lib
 copy ..\plugins\checksum\xcchecksum.dll %XCHAT_DEST%\plugins\xcchecksum.dll.x64
 copy ..\plugins\lua\xclua.dll %XCHAT_DEST%\plugins\xclua.dll.x64
 copy ..\plugins\mpcinfo\xcmpcinfo.dll %XCHAT_DEST%\plugins\xcmpcinfo.dll.x64
-copy ..\plugins\perl\xcperl-510.dll %XCHAT_DEST%\plugins\xcperl-510.dll.x64
 copy ..\plugins\perl\xcperl-512.dll %XCHAT_DEST%\plugins\xcperl-512.dll.x64
 copy ..\plugins\perl\xcperl-514.dll %XCHAT_DEST%\plugins\xcperl-514.dll.x64
 copy ..\plugins\python\xcpython.dll %XCHAT_DEST%\plugins\xcpython.dll.x64
diff --git a/build/release-x86.bat b/build/release-x86.bat
index 05ad7df5..b61bdbea 100644
--- a/build/release-x86.bat
+++ b/build/release-x86.bat
@@ -46,7 +46,6 @@ xcopy /q /s /i %DEPS_ROOT%\lib\enchant\libenchant_myspell.dll %XCHAT_DEST%\lib\e
 xcopy /q /s /i ..\plugins\checksum\xcchecksum.dll %XCHAT_DEST%\plugins\
 copy ..\plugins\lua\xclua.dll %XCHAT_DEST%\plugins
 copy ..\plugins\mpcinfo\xcmpcinfo.dll %XCHAT_DEST%\plugins
-copy ..\plugins\perl\xcperl-510.dll %XCHAT_DEST%\plugins
 copy ..\plugins\perl\xcperl-512.dll %XCHAT_DEST%\plugins
 copy ..\plugins\perl\xcperl-514.dll %XCHAT_DEST%\plugins
 copy ..\plugins\python\xcpython.dll %XCHAT_DEST%\plugins
diff --git a/build/xchat-wdk.skel.iss b/build/xchat-wdk.skel.iss
index 31617542..f0c0c8ad 100644
--- a/build/xchat-wdk.skel.iss
+++ b/build/xchat-wdk.skel.iss
@@ -55,7 +55,6 @@ Name: "langs\tcl"; Description: "Tcl"; Types: full custom; Flags: disablenounins
 Name: x86; Description: "x86"; GroupDescription: "XChat-WDK version:"; Flags: exclusive unchecked
 Name: x64; Description: "x64"; GroupDescription: "XChat-WDK version:"; Flags: exclusive; Check: Is64BitInstallMode
 
-Name: perl510; Description: "5.10"; GroupDescription: "Perl version:"; Flags: exclusive unchecked; Components: langs\perl
 Name: perl512; Description: "5.12"; GroupDescription: "Perl version:"; Flags: exclusive; Components: langs\perl
 Name: perl514; Description: "5.14"; GroupDescription: "Perl version:"; Flags: exclusive unchecked; Components: langs\perl
 
@@ -223,9 +222,6 @@ Source: "plugins\xctcl.dll.x64"; DestDir: "{app}\plugins"; DestName: "xctcl.dll"
 
 
 
-Source: "plugins\xcperl-510.dll"; DestDir: "{app}\plugins"; DestName: "xcperl.dll"; Components: langs\perl; Tasks: x86 and perl510
-Source: "plugins\xcperl-510.dll.x64"; DestDir: "{app}\plugins"; DestName: "xcperl.dll"; Components: langs\perl; Tasks: x64 and perl510
-
 Source: "plugins\xcperl-512.dll"; DestDir: "{app}\plugins"; DestName: "xcperl.dll"; Components: langs\perl; Tasks: x86 and perl512
 Source: "plugins\xcperl-512.dll.x64"; DestDir: "{app}\plugins"; DestName: "xcperl.dll"; Components: langs\perl; Tasks: x64 and perl512
 
diff --git a/plugins/perl/makefile-510.mak b/plugins/perl/makefile-510.mak
deleted file mode 100644
index 60f6b2dc..00000000
--- a/plugins/perl/makefile-510.mak
+++ /dev/null
@@ -1,30 +0,0 @@
-include "..\..\src\makeinc.mak"
-
-DIRENTLIB = ..\..\src\common\dirent.lib
-TARGET = $(PERL510OUTPUT)
-
-all: $(TARGET)
-
-perl.def:
-	echo EXPORTS > perl.def
-	echo xchat_plugin_init >> perl.def
-	echo xchat_plugin_deinit >> perl.def
-	echo xchat_plugin_get_info >> perl.def
-
-perl.obj: perl.c
-	$(CC) $(CFLAGS) perl.c $(GLIB) /I$(PERL510PATH) /I.. /DPERL_DLL=\"$(PERL510LIB).dll\"
-
-perl.c: xchat.pm.h
-
-xchat.pm.h: lib/Xchat.pm lib/IRC.pm
-	perl.exe generate_header
-
-$(TARGET): perl.obj perl.def
-	$(LINK) /DLL /out:$(TARGET) perl.obj $(LDFLAGS) $(PERL510LIB).lib /libpath:$(PERL510PATH) /DELAYLOAD:$(PERL510LIB).dll $(DIRENTLIB) DELAYIMP.LIB user32.lib shell32.lib advapi32.lib /def:perl.def
-
-clean:
-	@del $(TARGET)
-	@del *.obj
-	@del perl.def
-	@del *.lib
-	@del *.exp
diff --git a/src/makeinc.skel.mak b/src/makeinc.skel.mak
index f7bbeeb7..5c6beb6f 100644
--- a/src/makeinc.skel.mak
+++ b/src/makeinc.skel.mak
@@ -14,8 +14,6 @@ LIBS = $(LIBS) /libpath:$(DEV)\lib gtk-win32-2.0.lib gdk-win32-2.0.lib atk-1.0.l
 LUALIB = lua51
 LUAOUTPUT = xclua.dll
 
-PERL510LIB = perl510
-PERL510OUTPUT = xcperl-510.dll
 PERL512LIB = perl512
 PERL512OUTPUT = xcperl-512.dll
 PERL514LIB = perl514
@@ -32,16 +30,14 @@ CFLAGS = $(CFLAGS) /favor:AMD64 /D_WIN64
 CPPFLAGS = $(CPPFLAGS) /favor:AMD64 /D_WIN64
 LDFLAGS = $(LDFLAGS) msvcrt_win2003.obj
 
-PERL510PATH = c:\mozilla-build\perl-5.10-x64\lib\CORE
-PERL512PATH = c:\mozilla-build\perl-5.12-x64\lib\CORE
+PERL512PATH = c:\mozilla-build\perl-5.12-x64\perl\lib\CORE
 PERL514PATH = c:\mozilla-build\perl-5.14-x64\lib\CORE
 PYTHONPATH = c:\mozilla-build\python-2.7-x64
 TCLPATH = c:\mozilla-build\tcl-8.5-x64
 !else
 LDFLAGS = $(LDFLAGS) msvcrt_winxp.obj
 
-PERL510PATH = c:\mozilla-build\perl-5.10-x86\lib\CORE
-PERL512PATH = c:\mozilla-build\perl-5.12-x86\lib\CORE
+PERL512PATH = c:\mozilla-build\perl-5.12-x86\perl\lib\CORE
 PERL514PATH = c:\mozilla-build\perl-5.14-x86\lib\CORE
 PYTHONPATH = c:\mozilla-build\python-2.7-x86
 TCLPATH = c:\mozilla-build\tcl-8.5-x86
-- 
cgit 1.4.1


From 11e835b518401ffb4edd4d0790d6e0e381762949 Mon Sep 17 00:00:00 2001
From: "berkeviktor@aol.com" <berkeviktor@aol.com>
Date: Wed, 27 Jul 2011 06:16:35 +0200
Subject: add support files for strawberry importlib generation

---
 plugins/perl/importlib/perl512-x64.def | 1420 ++++++++++++++++++++++++++++++++
 plugins/perl/importlib/perl512-x86.def | 1420 ++++++++++++++++++++++++++++++++
 plugins/perl/importlib/sbperl-x64.bat  |   10 +
 plugins/perl/importlib/sbperl-x86.bat  |   10 +
 4 files changed, 2860 insertions(+)
 create mode 100644 plugins/perl/importlib/perl512-x64.def
 create mode 100644 plugins/perl/importlib/perl512-x86.def
 create mode 100644 plugins/perl/importlib/sbperl-x64.bat
 create mode 100644 plugins/perl/importlib/sbperl-x86.bat

(limited to 'plugins')

diff --git a/plugins/perl/importlib/perl512-x64.def b/plugins/perl/importlib/perl512-x64.def
new file mode 100644
index 00000000..5cfcaa68
--- /dev/null
+++ b/plugins/perl/importlib/perl512-x64.def
@@ -0,0 +1,1420 @@
+LIBRARY perl512
+EXPORTS
+PL_bincompat_options
+PL_check
+PL_fold
+PL_fold_locale
+PL_freq
+PL_keyword_plugin
+PL_memory_wrap
+PL_no_aelem
+PL_no_dir_func
+PL_no_func
+PL_no_helem_sv
+PL_no_localize_ref
+PL_no_mem
+PL_no_modify
+PL_no_myglob
+PL_no_security
+PL_no_sock_func
+PL_no_symref
+PL_no_usym
+PL_no_wrongref
+PL_op_desc
+PL_op_name
+PL_opargs
+PL_perlio_mutex
+PL_ppaddr
+PL_reg_extflags_name
+PL_reg_name
+PL_regkind
+PL_sig_name
+PL_sig_num
+PL_simple
+PL_utf8skip
+PL_uuemap
+PL_varies
+PL_vtbl_amagic
+PL_vtbl_amagicelem
+PL_vtbl_arylen
+PL_vtbl_backref
+PL_vtbl_bm
+PL_vtbl_collxfrm
+PL_vtbl_dbline
+PL_vtbl_defelem
+PL_vtbl_env
+PL_vtbl_envelem
+PL_vtbl_fm
+PL_vtbl_isa
+PL_vtbl_isaelem
+PL_vtbl_mglob
+PL_vtbl_nkeys
+PL_vtbl_pack
+PL_vtbl_packelem
+PL_vtbl_pos
+PL_vtbl_regdata
+PL_vtbl_regdatum
+PL_vtbl_regexp
+PL_vtbl_sig
+PL_vtbl_sigelem
+PL_vtbl_substr
+PL_vtbl_sv
+PL_vtbl_taint
+PL_vtbl_utf8
+PL_vtbl_uvar
+PL_vtbl_vec
+PL_warn_nl
+PL_warn_nosemi
+PL_warn_reserved
+PL_warn_uninit
+PerlIOBase_binmode
+PerlIOBase_clearerr
+PerlIOBase_close
+PerlIOBase_dup
+PerlIOBase_eof
+PerlIOBase_error
+PerlIOBase_fileno
+PerlIOBase_noop_fail
+PerlIOBase_noop_ok
+PerlIOBase_popped
+PerlIOBase_pushed
+PerlIOBase_read
+PerlIOBase_setlinebuf
+PerlIOBase_unread
+PerlIOBuf_bufsiz
+PerlIOBuf_close
+PerlIOBuf_dup
+PerlIOBuf_fill
+PerlIOBuf_flush
+PerlIOBuf_get_base
+PerlIOBuf_get_cnt
+PerlIOBuf_get_ptr
+PerlIOBuf_open
+PerlIOBuf_popped
+PerlIOBuf_pushed
+PerlIOBuf_read
+PerlIOBuf_seek
+PerlIOBuf_set_ptrcnt
+PerlIOBuf_tell
+PerlIOBuf_unread
+PerlIOBuf_write
+PerlIO_allocate
+PerlIO_apply_layera
+PerlIO_apply_layers
+PerlIO_arg_fetch
+PerlIO_binmode
+PerlIO_canset_cnt
+PerlIO_debug
+PerlIO_define_layer
+PerlIO_exportFILE
+PerlIO_fast_gets
+PerlIO_fdopen
+PerlIO_findFILE
+PerlIO_find_layer
+PerlIO_getc
+PerlIO_getname
+PerlIO_getpos
+PerlIO_has_base
+PerlIO_has_cntptr
+PerlIO_importFILE
+PerlIO_init
+PerlIO_isutf8
+PerlIO_layer_fetch
+PerlIO_list_alloc
+PerlIO_list_free
+PerlIO_modestr
+PerlIO_open
+PerlIO_parse_layers
+PerlIO_pending
+PerlIO_perlio
+PerlIO_pop
+PerlIO_printf
+PerlIO_push
+PerlIO_putc
+PerlIO_puts
+PerlIO_releaseFILE
+PerlIO_reopen
+PerlIO_rewind
+PerlIO_setpos
+PerlIO_sprintf
+PerlIO_stdoutf
+PerlIO_sv_dup
+PerlIO_teardown
+PerlIO_tmpfile
+PerlIO_ungetc
+PerlIO_vprintf
+PerlIO_vsprintf
+Perl_GNo_ptr
+Perl_GYes_ptr
+Perl_Gcheck_ptr
+Perl_Gcsighandlerp_ptr
+Perl_Gcurinterp_ptr
+Perl_Gdo_undump_ptr
+Perl_Gdollarzero_mutex_ptr
+Perl_Gfold_locale_ptr
+Perl_Ghexdigit_ptr
+Perl_Ghints_mutex_ptr
+Perl_Ginterp_size_5_10_0_ptr
+Perl_Ginterp_size_ptr
+Perl_Gkeyword_plugin_ptr
+Perl_Gmy_ctx_mutex_ptr
+Perl_Gmy_cxt_index_ptr
+Perl_Gop_mutex_ptr
+Perl_Gop_seq_ptr
+Perl_Gop_sequence_ptr
+Perl_Gpatleave_ptr
+Perl_Gperlio_debug_fd_ptr
+Perl_Gperlio_fd_refcnt_ptr
+Perl_Gperlio_fd_refcnt_size_ptr
+Perl_Gperlio_mutex_ptr
+Perl_Gppaddr_ptr
+Perl_Grevision_ptr
+Perl_Grunops_dbg_ptr
+Perl_Grunops_std_ptr
+Perl_Gsh_path_ptr
+Perl_Gsig_trapped_ptr
+Perl_Gsigfpe_saved_ptr
+Perl_Gsubversion_ptr
+Perl_Gsv_placeholder_ptr
+Perl_Gthr_key_ptr
+Perl_Guse_safe_putenv_ptr
+Perl_Gv_AMupdate
+Perl_Gversion_ptr
+Perl_Gveto_cleanup_ptr
+Perl_IArgv_ptr
+Perl_ICmd_ptr
+Perl_IDBgv_ptr
+Perl_IDBline_ptr
+Perl_IDBsignal_ptr
+Perl_IDBsingle_ptr
+Perl_IDBsub_ptr
+Perl_IDBtrace_ptr
+Perl_IDir_ptr
+Perl_IEnv_ptr
+Perl_ILIO_ptr
+Perl_IMemParse_ptr
+Perl_IMemShared_ptr
+Perl_IMem_ptr
+Perl_IOpPtr_ptr
+Perl_IOpSlab_ptr
+Perl_IOpSpace_ptr
+Perl_IProc_ptr
+Perl_ISock_ptr
+Perl_IStdIO_ptr
+Perl_ISv_ptr
+Perl_IXpv_ptr
+Perl_Iamagic_generation_ptr
+Perl_Ian_ptr
+Perl_Iargvgv_ptr
+Perl_Iargvout_stack_ptr
+Perl_Iargvoutgv_ptr
+Perl_Ibasetime_ptr
+Perl_Ibeginav_ptr
+Perl_Ibeginav_save_ptr
+Perl_Ibody_arenas_ptr
+Perl_Ibody_roots_ptr
+Perl_Ibodytarget_ptr
+Perl_Ibreakable_sub_gen_ptr
+Perl_Icheckav_ptr
+Perl_Icheckav_save_ptr
+Perl_Ichopset_ptr
+Perl_Iclocktick_ptr
+Perl_Icollation_ix_ptr
+Perl_Icollation_name_ptr
+Perl_Icollation_standard_ptr
+Perl_Icollxfrm_base_ptr
+Perl_Icollxfrm_mult_ptr
+Perl_Icolors_ptr
+Perl_Icolorset_ptr
+Perl_Icompcv_ptr
+Perl_Icompiling_ptr
+Perl_Icomppad_name_fill_ptr
+Perl_Icomppad_name_floor_ptr
+Perl_Icomppad_name_ptr
+Perl_Icomppad_ptr
+Perl_Icop_seqmax_ptr
+Perl_Icurcop_ptr
+Perl_Icurcopdb_ptr
+Perl_Icurpad_ptr
+Perl_Icurpm_ptr
+Perl_Icurstack_ptr
+Perl_Icurstackinfo_ptr
+Perl_Icurstash_ptr
+Perl_Icurstname_ptr
+Perl_Icustom_op_descs_ptr
+Perl_Icustom_op_names_ptr
+Perl_Icv_has_eval_ptr
+Perl_Idbargs_ptr
+Perl_Idebstash_ptr
+Perl_Idebug_pad_ptr
+Perl_Idebug_ptr
+Perl_Idef_layerlist_ptr
+Perl_Idefgv_ptr
+Perl_Idefoutgv_ptr
+Perl_Idefstash_ptr
+Perl_Idelaymagic_ptr
+Perl_Idestroyhook_ptr
+Perl_Idiehook_ptr
+Perl_Idirty_ptr
+Perl_Idoextract_ptr
+Perl_Idoswitches_ptr
+Perl_Idowarn_ptr
+Perl_Idumpindent_ptr
+Perl_Ie_script_ptr
+Perl_Iefloatbuf_ptr
+Perl_Iefloatsize_ptr
+Perl_Iegid_ptr
+Perl_Iencoding_ptr
+Perl_Iendav_ptr
+Perl_Ienvgv_ptr
+Perl_Ierrgv_ptr
+Perl_Ierrors_ptr
+Perl_Ieuid_ptr
+Perl_Ieval_root_ptr
+Perl_Ieval_start_ptr
+Perl_Ievalseq_ptr
+Perl_Iexit_flags_ptr
+Perl_Iexitlist_ptr
+Perl_Iexitlistlen_ptr
+Perl_Ifdpid_ptr
+Perl_Ifilemode_ptr
+Perl_Ifirstgv_ptr
+Perl_Iforkprocess_ptr
+Perl_Iformfeed_ptr
+Perl_Iformtarget_ptr
+Perl_Igensym_ptr
+Perl_Igid_ptr
+Perl_Iglob_index_ptr
+Perl_Iglobalstash_ptr
+Perl_Ihash_seed_ptr
+Perl_Ihintgv_ptr
+Perl_Ihints_ptr
+Perl_Ihv_fetch_ent_mh_ptr
+Perl_Iin_clean_all_ptr
+Perl_Iin_clean_objs_ptr
+Perl_Iin_eval_ptr
+Perl_Iin_load_module_ptr
+Perl_Iincgv_ptr
+Perl_Iinitav_ptr
+Perl_Iinplace_ptr
+Perl_Iisarev_ptr
+Perl_Iknown_layers_ptr
+Perl_Ilast_in_gv_ptr
+Perl_Ilast_swash_hv_ptr
+Perl_Ilast_swash_key_ptr
+Perl_Ilast_swash_klen_ptr
+Perl_Ilast_swash_slen_ptr
+Perl_Ilast_swash_tmps_ptr
+Perl_Ilastfd_ptr
+Perl_Ilastscream_ptr
+Perl_Ilaststatval_ptr
+Perl_Ilaststype_ptr
+Perl_Ilocalizing_ptr
+Perl_Ilocalpatches_ptr
+Perl_Ilockhook_ptr
+Perl_Imain_cv_ptr
+Perl_Imain_root_ptr
+Perl_Imain_start_ptr
+Perl_Imainstack_ptr
+Perl_Imarkstack_max_ptr
+Perl_Imarkstack_ptr
+Perl_Imarkstack_ptr_ptr
+Perl_Imax_intro_pending_ptr
+Perl_Imaxo_ptr
+Perl_Imaxscream_ptr
+Perl_Imaxsysfd_ptr
+Perl_Imess_sv_ptr
+Perl_Imin_intro_pending_ptr
+Perl_Iminus_E_ptr
+Perl_Iminus_F_ptr
+Perl_Iminus_a_ptr
+Perl_Iminus_c_ptr
+Perl_Iminus_l_ptr
+Perl_Iminus_n_ptr
+Perl_Iminus_p_ptr
+Perl_Imodglobal_ptr
+Perl_Imy_cxt_list_ptr
+Perl_Imy_cxt_size_ptr
+Perl_Ina_ptr
+Perl_Inice_chunk_ptr
+Perl_Inice_chunk_size_ptr
+Perl_Inomemok_ptr
+Perl_Inumeric_local_ptr
+Perl_Inumeric_name_ptr
+Perl_Inumeric_radix_sv_ptr
+Perl_Inumeric_standard_ptr
+Perl_Iofsgv_ptr
+Perl_Ioldname_ptr
+Perl_Iop_mask_ptr
+Perl_Iop_ptr
+Perl_Iopfreehook_ptr
+Perl_Iorigalen_ptr
+Perl_Iorigargc_ptr
+Perl_Iorigargv_ptr
+Perl_Iorigenviron_ptr
+Perl_Iorigfilename_ptr
+Perl_Iors_sv_ptr
+Perl_Iosname_ptr
+Perl_Ipad_reset_pending_ptr
+Perl_Ipadix_floor_ptr
+Perl_Ipadix_ptr
+Perl_Iparser_ptr
+Perl_Ipatchlevel_ptr
+Perl_Ipeepp_ptr
+Perl_Iperl_destruct_level_ptr
+Perl_Iperldb_ptr
+Perl_Iperlio_ptr
+Perl_Ipreambleav_ptr
+Perl_Iprofiledata_ptr
+Perl_Ipsig_name_ptr
+Perl_Ipsig_pend_ptr
+Perl_Ipsig_ptr_ptr
+Perl_Iptr_table_ptr
+Perl_Ireentrant_retint_ptr
+Perl_Ireg_state_ptr
+Perl_Iregdummy_ptr
+Perl_Iregex_pad_ptr
+Perl_Iregex_padav_ptr
+Perl_Ireginterp_cnt_ptr
+Perl_Iregistered_mros_ptr
+Perl_Iregmatch_slab_ptr
+Perl_Iregmatch_state_ptr
+Perl_Irehash_seed_ptr
+Perl_Irehash_seed_set_ptr
+Perl_Ireplgv_ptr
+Perl_Irestartop_ptr
+Perl_Irs_ptr
+Perl_Irunops_ptr
+Perl_Isavebegin_ptr
+Perl_Isavestack_ix_ptr
+Perl_Isavestack_max_ptr
+Perl_Isavestack_ptr
+Perl_Isawampersand_ptr
+Perl_Iscopestack_ix_ptr
+Perl_Iscopestack_max_ptr
+Perl_Iscopestack_name_ptr
+Perl_Iscopestack_ptr
+Perl_Iscreamfirst_ptr
+Perl_Iscreamnext_ptr
+Perl_Isecondgv_ptr
+Perl_Isharehook_ptr
+Perl_Isig_pending_ptr
+Perl_Isighandlerp_ptr
+Perl_Isignals_ptr
+Perl_Isort_RealCmp_ptr
+Perl_Isortcop_ptr
+Perl_Isortstash_ptr
+Perl_Isplitstr_ptr
+Perl_Isrand_called_ptr
+Perl_Istack_base_ptr
+Perl_Istack_max_ptr
+Perl_Istack_sp_ptr
+Perl_Istart_env_ptr
+Perl_Istashcache_ptr
+Perl_Istatbuf_ptr
+Perl_Istatcache_ptr
+Perl_Istatgv_ptr
+Perl_Istatname_ptr
+Perl_Istatusvalue_posix_ptr
+Perl_Istatusvalue_ptr
+Perl_Istderrgv_ptr
+Perl_Istdingv_ptr
+Perl_Istrtab_ptr
+Perl_Isub_generation_ptr
+Perl_Isubline_ptr
+Perl_Isubname_ptr
+Perl_Isv_arenaroot_ptr
+Perl_Isv_count_ptr
+Perl_Isv_no_ptr
+Perl_Isv_objcount_ptr
+Perl_Isv_root_ptr
+Perl_Isv_undef_ptr
+Perl_Isv_yes_ptr
+Perl_Isys_intern_ptr
+Perl_Itaint_warn_ptr
+Perl_Itainted_ptr
+Perl_Itainting_ptr
+Perl_Ithreadhook_ptr
+Perl_Itmps_floor_ptr
+Perl_Itmps_ix_ptr
+Perl_Itmps_max_ptr
+Perl_Itmps_stack_ptr
+Perl_Itop_env_ptr
+Perl_Itoptarget_ptr
+Perl_Iuid_ptr
+Perl_Iunicode_ptr
+Perl_Iunitcheckav_ptr
+Perl_Iunitcheckav_save_ptr
+Perl_Iunlockhook_ptr
+Perl_Iunsafe_ptr
+Perl_Iutf8_X_LVT_ptr
+Perl_Iutf8_X_LV_LVT_V_ptr
+Perl_Iutf8_X_LV_ptr
+Perl_Iutf8_X_L_ptr
+Perl_Iutf8_X_T_ptr
+Perl_Iutf8_X_V_ptr
+Perl_Iutf8_X_begin_ptr
+Perl_Iutf8_X_extend_ptr
+Perl_Iutf8_X_non_hangul_ptr
+Perl_Iutf8_X_prepend_ptr
+Perl_Iutf8_alnum_ptr
+Perl_Iutf8_alpha_ptr
+Perl_Iutf8_ascii_ptr
+Perl_Iutf8_cntrl_ptr
+Perl_Iutf8_digit_ptr
+Perl_Iutf8_graph_ptr
+Perl_Iutf8_idcont_ptr
+Perl_Iutf8_idstart_ptr
+Perl_Iutf8_lower_ptr
+Perl_Iutf8_mark_ptr
+Perl_Iutf8_perl_space_ptr
+Perl_Iutf8_perl_word_ptr
+Perl_Iutf8_posix_digit_ptr
+Perl_Iutf8_print_ptr
+Perl_Iutf8_punct_ptr
+Perl_Iutf8_space_ptr
+Perl_Iutf8_tofold_ptr
+Perl_Iutf8_tolower_ptr
+Perl_Iutf8_totitle_ptr
+Perl_Iutf8_toupper_ptr
+Perl_Iutf8_upper_ptr
+Perl_Iutf8_xdigit_ptr
+Perl_Iutf8cache_ptr
+Perl_Iutf8locale_ptr
+Perl_Iwarnhook_ptr
+Perl_PerlIO_clearerr
+Perl_PerlIO_close
+Perl_PerlIO_context_layers
+Perl_PerlIO_eof
+Perl_PerlIO_error
+Perl_PerlIO_fileno
+Perl_PerlIO_fill
+Perl_PerlIO_flush
+Perl_PerlIO_get_base
+Perl_PerlIO_get_bufsiz
+Perl_PerlIO_get_cnt
+Perl_PerlIO_get_ptr
+Perl_PerlIO_read
+Perl_PerlIO_seek
+Perl_PerlIO_set_cnt
+Perl_PerlIO_set_ptrcnt
+Perl_PerlIO_setlinebuf
+Perl_PerlIO_stderr
+Perl_PerlIO_stdin
+Perl_PerlIO_stdout
+Perl_PerlIO_tell
+Perl_PerlIO_unread
+Perl_PerlIO_write
+Perl_Slab_Alloc
+Perl_Slab_Free
+Perl_amagic_call
+Perl_any_dup
+Perl_apply_attrs_string
+Perl_atfork_lock
+Perl_atfork_unlock
+Perl_av_arylen_p
+Perl_av_clear
+Perl_av_delete
+Perl_av_exists
+Perl_av_extend
+Perl_av_fetch
+Perl_av_fill
+Perl_av_iter_p
+Perl_av_len
+Perl_av_make
+Perl_av_pop
+Perl_av_push
+Perl_av_reify
+Perl_av_shift
+Perl_av_store
+Perl_av_undef
+Perl_av_unshift
+Perl_block_gimme
+Perl_bytes_from_utf8
+Perl_bytes_to_utf8
+Perl_call_argv
+Perl_call_atexit
+Perl_call_list
+Perl_call_method
+Perl_call_pv
+Perl_call_sv
+Perl_calloc
+Perl_cast_i32
+Perl_cast_iv
+Perl_cast_ulong
+Perl_cast_uv
+Perl_ck_warner
+Perl_ck_warner_d
+Perl_ckwarn
+Perl_ckwarn_d
+Perl_croak
+Perl_croak_nocontext
+Perl_croak_xs_usage
+Perl_csighandler
+Perl_custom_op_desc
+Perl_custom_op_name
+Perl_cv_const_sv
+Perl_cv_undef
+Perl_cx_dump
+Perl_cx_dup
+Perl_cxinc
+Perl_deb
+Perl_deb_nocontext
+Perl_delimcpy
+Perl_despatch_signals
+Perl_die
+Perl_die_nocontext
+Perl_dirp_dup
+Perl_do_aexec
+Perl_do_aspawn
+Perl_do_binmode
+Perl_do_close
+Perl_do_gv_dump
+Perl_do_gvgv_dump
+Perl_do_hv_dump
+Perl_do_join
+Perl_do_magic_dump
+Perl_do_op_dump
+Perl_do_open
+Perl_do_open9
+Perl_do_openn
+Perl_do_pmop_dump
+Perl_do_spawn
+Perl_do_spawn_nowait
+Perl_do_sprintf
+Perl_do_sv_dump
+Perl_doing_taint
+Perl_doref
+Perl_dounwind
+Perl_dowantarray
+Perl_dump_all
+Perl_dump_eval
+Perl_dump_form
+Perl_dump_indent
+Perl_dump_packsubs
+Perl_dump_sub
+Perl_dump_vindent
+Perl_emulate_cop_io
+Perl_eval_pv
+Perl_eval_sv
+Perl_fbm_compile
+Perl_fbm_instr
+Perl_fetch_cop_label
+Perl_filter_add
+Perl_filter_del
+Perl_filter_read
+Perl_find_runcv
+Perl_find_rundefsvoffset
+Perl_form
+Perl_form_nocontext
+Perl_fp_dup
+Perl_fprintf_nocontext
+Perl_free_tmps
+Perl_get_av
+Perl_get_context
+Perl_get_cv
+Perl_get_cvn_flags
+Perl_get_hv
+Perl_get_op_descs
+Perl_get_op_names
+Perl_get_ppaddr
+Perl_get_re_arg
+Perl_get_sv
+Perl_get_vtbl
+Perl_getcwd_sv
+Perl_gp_dup
+Perl_gp_free
+Perl_gp_ref
+Perl_grok_bin
+Perl_grok_hex
+Perl_grok_number
+Perl_grok_numeric_radix
+Perl_grok_oct
+Perl_gv_AVadd
+Perl_gv_HVadd
+Perl_gv_IOadd
+Perl_gv_SVadd
+Perl_gv_add_by_type
+Perl_gv_autoload4
+Perl_gv_check
+Perl_gv_const_sv
+Perl_gv_dump
+Perl_gv_efullname
+Perl_gv_efullname3
+Perl_gv_efullname4
+Perl_gv_fetchfile
+Perl_gv_fetchfile_flags
+Perl_gv_fetchmeth
+Perl_gv_fetchmeth_autoload
+Perl_gv_fetchmethod
+Perl_gv_fetchmethod_autoload
+Perl_gv_fetchmethod_flags
+Perl_gv_fetchpv
+Perl_gv_fetchpvn_flags
+Perl_gv_fetchsv
+Perl_gv_fullname
+Perl_gv_fullname3
+Perl_gv_fullname4
+Perl_gv_handler
+Perl_gv_init
+Perl_gv_name_set
+Perl_gv_stashpv
+Perl_gv_stashpvn
+Perl_gv_stashsv
+Perl_gv_try_downgrade
+Perl_he_dup
+Perl_hek_dup
+Perl_hv_clear
+Perl_hv_clear_placeholders
+Perl_hv_common
+Perl_hv_common_key_len
+Perl_hv_delayfree_ent
+Perl_hv_delete
+Perl_hv_delete_ent
+Perl_hv_eiter_p
+Perl_hv_eiter_set
+Perl_hv_exists
+Perl_hv_exists_ent
+Perl_hv_fetch
+Perl_hv_fetch_ent
+Perl_hv_free_ent
+Perl_hv_iterinit
+Perl_hv_iterkey
+Perl_hv_iterkeysv
+Perl_hv_iternext
+Perl_hv_iternext_flags
+Perl_hv_iternextsv
+Perl_hv_iterval
+Perl_hv_ksplit
+Perl_hv_magic
+Perl_hv_name_set
+Perl_hv_placeholders_get
+Perl_hv_placeholders_p
+Perl_hv_placeholders_set
+Perl_hv_riter_p
+Perl_hv_riter_set
+Perl_hv_scalar
+Perl_hv_store
+Perl_hv_store_ent
+Perl_hv_store_flags
+Perl_hv_undef
+Perl_ibcmp
+Perl_ibcmp_locale
+Perl_ibcmp_utf8
+Perl_init_i18nl10n
+Perl_init_i18nl14n
+Perl_init_os_extras
+Perl_init_stacks
+Perl_init_tm
+Perl_instr
+Perl_is_ascii_string
+Perl_is_lvalue_sub
+Perl_is_uni_alnum
+Perl_is_uni_alnum_lc
+Perl_is_uni_alpha
+Perl_is_uni_alpha_lc
+Perl_is_uni_ascii
+Perl_is_uni_ascii_lc
+Perl_is_uni_cntrl
+Perl_is_uni_cntrl_lc
+Perl_is_uni_digit
+Perl_is_uni_digit_lc
+Perl_is_uni_graph
+Perl_is_uni_graph_lc
+Perl_is_uni_idfirst
+Perl_is_uni_idfirst_lc
+Perl_is_uni_lower
+Perl_is_uni_lower_lc
+Perl_is_uni_print
+Perl_is_uni_print_lc
+Perl_is_uni_punct
+Perl_is_uni_punct_lc
+Perl_is_uni_space
+Perl_is_uni_space_lc
+Perl_is_uni_upper
+Perl_is_uni_upper_lc
+Perl_is_uni_xdigit
+Perl_is_uni_xdigit_lc
+Perl_is_utf8_X_L
+Perl_is_utf8_X_LV
+Perl_is_utf8_X_LVT
+Perl_is_utf8_X_LV_LVT_V
+Perl_is_utf8_X_T
+Perl_is_utf8_X_V
+Perl_is_utf8_X_begin
+Perl_is_utf8_X_extend
+Perl_is_utf8_X_non_hangul
+Perl_is_utf8_X_prepend
+Perl_is_utf8_alnum
+Perl_is_utf8_alpha
+Perl_is_utf8_ascii
+Perl_is_utf8_char
+Perl_is_utf8_cntrl
+Perl_is_utf8_digit
+Perl_is_utf8_graph
+Perl_is_utf8_idcont
+Perl_is_utf8_idfirst
+Perl_is_utf8_lower
+Perl_is_utf8_mark
+Perl_is_utf8_perl_space
+Perl_is_utf8_perl_word
+Perl_is_utf8_posix_digit
+Perl_is_utf8_print
+Perl_is_utf8_punct
+Perl_is_utf8_space
+Perl_is_utf8_string
+Perl_is_utf8_string_loc
+Perl_is_utf8_string_loclen
+Perl_is_utf8_upper
+Perl_is_utf8_xdigit
+Perl_leave_scope
+Perl_lex_bufutf8
+Perl_lex_discard_to
+Perl_lex_end
+Perl_lex_grow_linestr
+Perl_lex_next_chunk
+Perl_lex_peek_unichar
+Perl_lex_read_space
+Perl_lex_read_to
+Perl_lex_read_unichar
+Perl_lex_stuff_pvn
+Perl_lex_stuff_sv
+Perl_lex_unstuff
+Perl_load_module
+Perl_load_module_nocontext
+Perl_looks_like_number
+Perl_magic_dump
+Perl_malloc
+Perl_markstack_grow
+Perl_mess
+Perl_mess_nocontext
+Perl_mfree
+Perl_mg_clear
+Perl_mg_copy
+Perl_mg_dup
+Perl_mg_find
+Perl_mg_free
+Perl_mg_get
+Perl_mg_length
+Perl_mg_magical
+Perl_mg_set
+Perl_mg_size
+Perl_mini_mktime
+Perl_mod
+Perl_moreswitches
+Perl_mro_get_from_name
+Perl_mro_get_linear_isa
+Perl_mro_get_private_data
+Perl_mro_meta_init
+Perl_mro_method_changed_in
+Perl_mro_register
+Perl_mro_set_mro
+Perl_mro_set_private_data
+Perl_my_atof
+Perl_my_atof2
+Perl_my_cxt_init
+Perl_my_dirfd
+Perl_my_exit
+Perl_my_failure_exit
+Perl_my_fflush_all
+Perl_my_fork
+Perl_my_lstat
+Perl_my_popen_list
+Perl_my_setenv
+Perl_my_snprintf
+Perl_my_socketpair
+Perl_my_stat
+Perl_my_strftime
+Perl_my_strlcat
+Perl_my_strlcpy
+Perl_my_vsnprintf
+Perl_newANONATTRSUB
+Perl_newANONHASH
+Perl_newANONLIST
+Perl_newANONSUB
+Perl_newASSIGNOP
+Perl_newATTRSUB
+Perl_newAV
+Perl_newAVREF
+Perl_newBINOP
+Perl_newCONDOP
+Perl_newCONSTSUB
+Perl_newCVREF
+Perl_newFORM
+Perl_newFOROP
+Perl_newGIVENOP
+Perl_newGVOP
+Perl_newGVREF
+Perl_newGVgen
+Perl_newHV
+Perl_newHVREF
+Perl_newHVhv
+Perl_newIO
+Perl_newLISTOP
+Perl_newLOGOP
+Perl_newLOOPEX
+Perl_newLOOPOP
+Perl_newMYSUB
+Perl_newNULLLIST
+Perl_newOP
+Perl_newPADOP
+Perl_newPMOP
+Perl_newPROG
+Perl_newPVOP
+Perl_newRANGE
+Perl_newRV
+Perl_newRV_noinc
+Perl_newSLICEOP
+Perl_newSTATEOP
+Perl_newSUB
+Perl_newSV
+Perl_newSVOP
+Perl_newSVREF
+Perl_newSV_type
+Perl_newSVhek
+Perl_newSViv
+Perl_newSVnv
+Perl_newSVpv
+Perl_newSVpvf
+Perl_newSVpvf_nocontext
+Perl_newSVpvn
+Perl_newSVpvn_flags
+Perl_newSVpvn_share
+Perl_newSVrv
+Perl_newSVsv
+Perl_newSVuv
+Perl_newUNOP
+Perl_newWHENOP
+Perl_newWHILEOP
+Perl_newXS
+Perl_newXS_flags
+Perl_new_collate
+Perl_new_ctype
+Perl_new_numeric
+Perl_new_stackinfo
+Perl_new_version
+Perl_new_warnings_bitfield
+Perl_ninstr
+Perl_nothreadhook
+Perl_op_clear
+Perl_op_dump
+Perl_op_free
+Perl_op_null
+Perl_op_refcnt_lock
+Perl_op_refcnt_unlock
+Perl_pack_cat
+Perl_packlist
+Perl_pad_findmy
+Perl_pad_push
+Perl_parser_dup
+Perl_pmflag
+Perl_pmop_dump
+Perl_pop_scope
+Perl_pregcomp
+Perl_pregexec
+Perl_pregfree
+Perl_pregfree2
+Perl_prescan_version
+Perl_printf_nocontext
+Perl_ptr_table_clear
+Perl_ptr_table_fetch
+Perl_ptr_table_free
+Perl_ptr_table_new
+Perl_ptr_table_split
+Perl_ptr_table_store
+Perl_push_scope
+Perl_pv_display
+Perl_pv_escape
+Perl_pv_pretty
+Perl_pv_uni_display
+Perl_qerror
+Perl_re_compile
+Perl_re_dup_guts
+Perl_re_intuit_start
+Perl_re_intuit_string
+Perl_realloc
+Perl_reentrant_free
+Perl_reentrant_init
+Perl_reentrant_retry
+Perl_reentrant_size
+Perl_ref
+Perl_refcounted_he_chain_2hv
+Perl_refcounted_he_fetch
+Perl_refcounted_he_new
+Perl_reg_named_buff
+Perl_reg_named_buff_all
+Perl_reg_named_buff_exists
+Perl_reg_named_buff_fetch
+Perl_reg_named_buff_firstkey
+Perl_reg_named_buff_iter
+Perl_reg_named_buff_nextkey
+Perl_reg_named_buff_scalar
+Perl_reg_numbered_buff_fetch
+Perl_reg_numbered_buff_length
+Perl_reg_numbered_buff_store
+Perl_reg_qr_package
+Perl_reg_temp_copy
+Perl_regclass_swash
+Perl_regcurly
+Perl_regdump
+Perl_regdupe_internal
+Perl_regexec_flags
+Perl_regfree_internal
+Perl_reginitcolors
+Perl_regnext
+Perl_repeatcpy
+Perl_report_uninit
+Perl_require_pv
+Perl_rninstr
+Perl_rsignal
+Perl_rsignal_state
+Perl_runops_debug
+Perl_runops_standard
+Perl_rvpv_dup
+Perl_safesyscalloc
+Perl_safesysfree
+Perl_safesysmalloc
+Perl_safesysrealloc
+Perl_save_I16
+Perl_save_I32
+Perl_save_I8
+Perl_save_adelete
+Perl_save_aelem_flags
+Perl_save_alloc
+Perl_save_aptr
+Perl_save_ary
+Perl_save_bool
+Perl_save_clearsv
+Perl_save_delete
+Perl_save_destructor
+Perl_save_destructor_x
+Perl_save_freeop
+Perl_save_freepv
+Perl_save_freesv
+Perl_save_generic_pvref
+Perl_save_generic_svref
+Perl_save_gp
+Perl_save_hash
+Perl_save_hdelete
+Perl_save_helem_flags
+Perl_save_hptr
+Perl_save_int
+Perl_save_item
+Perl_save_iv
+Perl_save_list
+Perl_save_long
+Perl_save_mortalizesv
+Perl_save_nogv
+Perl_save_op
+Perl_save_padsv_and_mortalize
+Perl_save_pptr
+Perl_save_pushptr
+Perl_save_re_context
+Perl_save_scalar
+Perl_save_set_svflags
+Perl_save_shared_pvref
+Perl_save_sptr
+Perl_save_svref
+Perl_save_vptr
+Perl_savepv
+Perl_savepvn
+Perl_savesharedpv
+Perl_savesharedpvn
+Perl_savestack_grow
+Perl_savestack_grow_cnt
+Perl_savesvpv
+Perl_scan_bin
+Perl_scan_hex
+Perl_scan_num
+Perl_scan_oct
+Perl_scan_version
+Perl_scan_vstring
+Perl_screaminstr
+Perl_seed
+Perl_set_context
+Perl_set_numeric_local
+Perl_set_numeric_radix
+Perl_set_numeric_standard
+Perl_setdefout
+Perl_share_hek
+Perl_si_dup
+Perl_signbit
+Perl_sortsv
+Perl_sortsv_flags
+Perl_ss_dup
+Perl_stack_grow
+Perl_start_subparse
+Perl_stashpv_hvname_match
+Perl_str_to_version
+Perl_sv_2bool
+Perl_sv_2cv
+Perl_sv_2io
+Perl_sv_2iv
+Perl_sv_2iv_flags
+Perl_sv_2mortal
+Perl_sv_2nv
+Perl_sv_2pv
+Perl_sv_2pv_flags
+Perl_sv_2pv_nolen
+Perl_sv_2pvbyte
+Perl_sv_2pvbyte_nolen
+Perl_sv_2pvutf8
+Perl_sv_2pvutf8_nolen
+Perl_sv_2uv
+Perl_sv_2uv_flags
+Perl_sv_backoff
+Perl_sv_bless
+Perl_sv_cat_decode
+Perl_sv_catpv
+Perl_sv_catpv_mg
+Perl_sv_catpvf
+Perl_sv_catpvf_mg
+Perl_sv_catpvf_mg_nocontext
+Perl_sv_catpvf_nocontext
+Perl_sv_catpvn
+Perl_sv_catpvn_flags
+Perl_sv_catpvn_mg
+Perl_sv_catsv
+Perl_sv_catsv_flags
+Perl_sv_catsv_mg
+Perl_sv_chop
+Perl_sv_clear
+Perl_sv_cmp
+Perl_sv_cmp_locale
+Perl_sv_collxfrm
+Perl_sv_compile_2op
+Perl_sv_copypv
+Perl_sv_dec
+Perl_sv_derived_from
+Perl_sv_destroyable
+Perl_sv_does
+Perl_sv_dump
+Perl_sv_dup
+Perl_sv_eq
+Perl_sv_force_normal
+Perl_sv_force_normal_flags
+Perl_sv_free
+Perl_sv_free2
+Perl_sv_gets
+Perl_sv_grow
+Perl_sv_inc
+Perl_sv_insert
+Perl_sv_insert_flags
+Perl_sv_isa
+Perl_sv_isobject
+Perl_sv_iv
+Perl_sv_len
+Perl_sv_len_utf8
+Perl_sv_magic
+Perl_sv_magicext
+Perl_sv_mortalcopy
+Perl_sv_newmortal
+Perl_sv_newref
+Perl_sv_nolocking
+Perl_sv_nosharing
+Perl_sv_nounlocking
+Perl_sv_nv
+Perl_sv_peek
+Perl_sv_pos_b2u
+Perl_sv_pos_u2b
+Perl_sv_pos_u2b_flags
+Perl_sv_pv
+Perl_sv_pvbyte
+Perl_sv_pvbyten
+Perl_sv_pvbyten_force
+Perl_sv_pvn
+Perl_sv_pvn_force
+Perl_sv_pvn_force_flags
+Perl_sv_pvn_nomg
+Perl_sv_pvutf8
+Perl_sv_pvutf8n
+Perl_sv_pvutf8n_force
+Perl_sv_recode_to_utf8
+Perl_sv_reftype
+Perl_sv_replace
+Perl_sv_report_used
+Perl_sv_reset
+Perl_sv_rvweaken
+Perl_sv_setiv
+Perl_sv_setiv_mg
+Perl_sv_setnv
+Perl_sv_setnv_mg
+Perl_sv_setpv
+Perl_sv_setpv_mg
+Perl_sv_setpvf
+Perl_sv_setpvf_mg
+Perl_sv_setpvf_mg_nocontext
+Perl_sv_setpvf_nocontext
+Perl_sv_setpviv
+Perl_sv_setpviv_mg
+Perl_sv_setpvn
+Perl_sv_setpvn_mg
+Perl_sv_setref_iv
+Perl_sv_setref_nv
+Perl_sv_setref_pv
+Perl_sv_setref_pvn
+Perl_sv_setref_uv
+Perl_sv_setsv
+Perl_sv_setsv_flags
+Perl_sv_setsv_mg
+Perl_sv_setuv
+Perl_sv_setuv_mg
+Perl_sv_taint
+Perl_sv_tainted
+Perl_sv_true
+Perl_sv_uni_display
+Perl_sv_unmagic
+Perl_sv_unref
+Perl_sv_unref_flags
+Perl_sv_untaint
+Perl_sv_upgrade
+Perl_sv_usepvn
+Perl_sv_usepvn_flags
+Perl_sv_usepvn_mg
+Perl_sv_utf8_decode
+Perl_sv_utf8_downgrade
+Perl_sv_utf8_encode
+Perl_sv_utf8_upgrade
+Perl_sv_utf8_upgrade_flags_grow
+Perl_sv_uv
+Perl_sv_vcatpvf
+Perl_sv_vcatpvf_mg
+Perl_sv_vcatpvfn
+Perl_sv_vsetpvf
+Perl_sv_vsetpvf_mg
+Perl_sv_vsetpvfn
+Perl_swash_fetch
+Perl_swash_init
+Perl_sys_init
+Perl_sys_init3
+Perl_sys_intern_clear
+Perl_sys_intern_dup
+Perl_sys_intern_init
+Perl_sys_term
+Perl_taint_env
+Perl_taint_proper
+Perl_tmps_grow
+Perl_to_uni_fold
+Perl_to_uni_lower
+Perl_to_uni_lower_lc
+Perl_to_uni_title
+Perl_to_uni_title_lc
+Perl_to_uni_upper
+Perl_to_uni_upper_lc
+Perl_to_utf8_case
+Perl_to_utf8_fold
+Perl_to_utf8_lower
+Perl_to_utf8_title
+Perl_to_utf8_upper
+Perl_unpack_str
+Perl_unpackstring
+Perl_unsharepvn
+Perl_upg_version
+Perl_utf16_to_utf8
+Perl_utf16_to_utf8_reversed
+Perl_utf8_distance
+Perl_utf8_hop
+Perl_utf8_length
+Perl_utf8_to_bytes
+Perl_utf8_to_uvchr
+Perl_utf8_to_uvuni
+Perl_utf8n_to_uvchr
+Perl_utf8n_to_uvuni
+Perl_uvchr_to_utf8
+Perl_uvchr_to_utf8_flags
+Perl_uvuni_to_utf8
+Perl_uvuni_to_utf8_flags
+Perl_vcmp
+Perl_vcroak
+Perl_vdeb
+Perl_vform
+Perl_vivify_defelem
+Perl_vload_module
+Perl_vmess
+Perl_vnewSVpvf
+Perl_vnormal
+Perl_vnumify
+Perl_vstringify
+Perl_vverify
+Perl_vwarn
+Perl_vwarner
+Perl_warn
+Perl_warn_nocontext
+Perl_warner
+Perl_warner_nocontext
+Perl_whichsig
+Perl_win32_init
+Perl_win32_term
+Perl_yylex
+RunPerl
+boot_DynaLoader
+boot_Win32CORE
+init_Win32CORE
+perl_alloc
+perl_alloc_override
+perl_alloc_using
+perl_clone
+perl_clone_host
+perl_clone_using
+perl_construct
+perl_destruct
+perl_free
+perl_get_host_info
+perl_parse
+perl_run
+perlsio_binmode
+setgid
+setuid
+win32_abort
+win32_accept
+win32_access
+win32_alarm
+win32_ansipath
+win32_async_check
+win32_bind
+win32_calloc
+win32_chdir
+win32_chmod
+win32_chsize
+win32_clearenv
+win32_clearerr
+win32_close
+win32_closedir
+win32_closesocket
+win32_connect
+win32_crypt
+win32_dup
+win32_dup2
+win32_dynaload
+win32_endhostent
+win32_endnetent
+win32_endprotoent
+win32_endservent
+win32_environ
+win32_eof
+win32_errno
+win32_execv
+win32_execvp
+win32_fclose
+win32_fcloseall
+win32_fdopen
+win32_feof
+win32_ferror
+win32_fflush
+win32_fgetc
+win32_fgetpos
+win32_fgets
+win32_fileno
+win32_flock
+win32_flushall
+win32_fopen
+win32_fprintf
+win32_fputc
+win32_fputs
+win32_fread
+win32_free
+win32_free_childdir
+win32_free_childenv
+win32_freopen
+win32_fseek
+win32_fsetpos
+win32_fstat
+win32_ftell
+win32_fwrite
+win32_get_childdir
+win32_get_childenv
+win32_get_osfhandle
+win32_getc
+win32_getchar
+win32_getenv
+win32_gethostbyaddr
+win32_gethostbyname
+win32_gethostname
+win32_getnetbyaddr
+win32_getnetbyname
+win32_getnetent
+win32_getpeername
+win32_getpid
+win32_getprotobyname
+win32_getprotobynumber
+win32_getprotoent
+win32_gets
+win32_getservbyname
+win32_getservbyport
+win32_getservent
+win32_getsockname
+win32_getsockopt
+win32_gettimeofday
+win32_htonl
+win32_htons
+win32_inet_addr
+win32_inet_ntoa
+win32_ioctl
+win32_ioctlsocket
+win32_isatty
+win32_kill
+win32_link
+win32_listen
+win32_longpath
+win32_lseek
+win32_malloc
+win32_mkdir
+win32_ntohl
+win32_ntohs
+win32_open
+win32_open_osfhandle
+win32_opendir
+win32_os_id
+win32_pclose
+win32_perror
+win32_pipe
+win32_popen
+win32_printf
+win32_putc
+win32_putchar
+win32_putenv
+win32_puts
+win32_read
+win32_readdir
+win32_realloc
+win32_recv
+win32_recvfrom
+win32_rename
+win32_rewind
+win32_rewinddir
+win32_rmdir
+win32_seekdir
+win32_select
+win32_send
+win32_sendto
+win32_setbuf
+win32_sethostent
+win32_setmode
+win32_setnetent
+win32_setprotoent
+win32_setservent
+win32_setsockopt
+win32_setvbuf
+win32_shutdown
+win32_sleep
+win32_socket
+win32_spawnvp
+win32_stat
+win32_stderr
+win32_stdin
+win32_stdout
+win32_str_os_error
+win32_strerror
+win32_tell
+win32_telldir
+win32_times
+win32_tmpfile
+win32_uname
+win32_ungetc
+win32_unlink
+win32_utime
+win32_vfprintf
+win32_vprintf
+win32_wait
+win32_waitpid
+win32_write
diff --git a/plugins/perl/importlib/perl512-x86.def b/plugins/perl/importlib/perl512-x86.def
new file mode 100644
index 00000000..5cfcaa68
--- /dev/null
+++ b/plugins/perl/importlib/perl512-x86.def
@@ -0,0 +1,1420 @@
+LIBRARY perl512
+EXPORTS
+PL_bincompat_options
+PL_check
+PL_fold
+PL_fold_locale
+PL_freq
+PL_keyword_plugin
+PL_memory_wrap
+PL_no_aelem
+PL_no_dir_func
+PL_no_func
+PL_no_helem_sv
+PL_no_localize_ref
+PL_no_mem
+PL_no_modify
+PL_no_myglob
+PL_no_security
+PL_no_sock_func
+PL_no_symref
+PL_no_usym
+PL_no_wrongref
+PL_op_desc
+PL_op_name
+PL_opargs
+PL_perlio_mutex
+PL_ppaddr
+PL_reg_extflags_name
+PL_reg_name
+PL_regkind
+PL_sig_name
+PL_sig_num
+PL_simple
+PL_utf8skip
+PL_uuemap
+PL_varies
+PL_vtbl_amagic
+PL_vtbl_amagicelem
+PL_vtbl_arylen
+PL_vtbl_backref
+PL_vtbl_bm
+PL_vtbl_collxfrm
+PL_vtbl_dbline
+PL_vtbl_defelem
+PL_vtbl_env
+PL_vtbl_envelem
+PL_vtbl_fm
+PL_vtbl_isa
+PL_vtbl_isaelem
+PL_vtbl_mglob
+PL_vtbl_nkeys
+PL_vtbl_pack
+PL_vtbl_packelem
+PL_vtbl_pos
+PL_vtbl_regdata
+PL_vtbl_regdatum
+PL_vtbl_regexp
+PL_vtbl_sig
+PL_vtbl_sigelem
+PL_vtbl_substr
+PL_vtbl_sv
+PL_vtbl_taint
+PL_vtbl_utf8
+PL_vtbl_uvar
+PL_vtbl_vec
+PL_warn_nl
+PL_warn_nosemi
+PL_warn_reserved
+PL_warn_uninit
+PerlIOBase_binmode
+PerlIOBase_clearerr
+PerlIOBase_close
+PerlIOBase_dup
+PerlIOBase_eof
+PerlIOBase_error
+PerlIOBase_fileno
+PerlIOBase_noop_fail
+PerlIOBase_noop_ok
+PerlIOBase_popped
+PerlIOBase_pushed
+PerlIOBase_read
+PerlIOBase_setlinebuf
+PerlIOBase_unread
+PerlIOBuf_bufsiz
+PerlIOBuf_close
+PerlIOBuf_dup
+PerlIOBuf_fill
+PerlIOBuf_flush
+PerlIOBuf_get_base
+PerlIOBuf_get_cnt
+PerlIOBuf_get_ptr
+PerlIOBuf_open
+PerlIOBuf_popped
+PerlIOBuf_pushed
+PerlIOBuf_read
+PerlIOBuf_seek
+PerlIOBuf_set_ptrcnt
+PerlIOBuf_tell
+PerlIOBuf_unread
+PerlIOBuf_write
+PerlIO_allocate
+PerlIO_apply_layera
+PerlIO_apply_layers
+PerlIO_arg_fetch
+PerlIO_binmode
+PerlIO_canset_cnt
+PerlIO_debug
+PerlIO_define_layer
+PerlIO_exportFILE
+PerlIO_fast_gets
+PerlIO_fdopen
+PerlIO_findFILE
+PerlIO_find_layer
+PerlIO_getc
+PerlIO_getname
+PerlIO_getpos
+PerlIO_has_base
+PerlIO_has_cntptr
+PerlIO_importFILE
+PerlIO_init
+PerlIO_isutf8
+PerlIO_layer_fetch
+PerlIO_list_alloc
+PerlIO_list_free
+PerlIO_modestr
+PerlIO_open
+PerlIO_parse_layers
+PerlIO_pending
+PerlIO_perlio
+PerlIO_pop
+PerlIO_printf
+PerlIO_push
+PerlIO_putc
+PerlIO_puts
+PerlIO_releaseFILE
+PerlIO_reopen
+PerlIO_rewind
+PerlIO_setpos
+PerlIO_sprintf
+PerlIO_stdoutf
+PerlIO_sv_dup
+PerlIO_teardown
+PerlIO_tmpfile
+PerlIO_ungetc
+PerlIO_vprintf
+PerlIO_vsprintf
+Perl_GNo_ptr
+Perl_GYes_ptr
+Perl_Gcheck_ptr
+Perl_Gcsighandlerp_ptr
+Perl_Gcurinterp_ptr
+Perl_Gdo_undump_ptr
+Perl_Gdollarzero_mutex_ptr
+Perl_Gfold_locale_ptr
+Perl_Ghexdigit_ptr
+Perl_Ghints_mutex_ptr
+Perl_Ginterp_size_5_10_0_ptr
+Perl_Ginterp_size_ptr
+Perl_Gkeyword_plugin_ptr
+Perl_Gmy_ctx_mutex_ptr
+Perl_Gmy_cxt_index_ptr
+Perl_Gop_mutex_ptr
+Perl_Gop_seq_ptr
+Perl_Gop_sequence_ptr
+Perl_Gpatleave_ptr
+Perl_Gperlio_debug_fd_ptr
+Perl_Gperlio_fd_refcnt_ptr
+Perl_Gperlio_fd_refcnt_size_ptr
+Perl_Gperlio_mutex_ptr
+Perl_Gppaddr_ptr
+Perl_Grevision_ptr
+Perl_Grunops_dbg_ptr
+Perl_Grunops_std_ptr
+Perl_Gsh_path_ptr
+Perl_Gsig_trapped_ptr
+Perl_Gsigfpe_saved_ptr
+Perl_Gsubversion_ptr
+Perl_Gsv_placeholder_ptr
+Perl_Gthr_key_ptr
+Perl_Guse_safe_putenv_ptr
+Perl_Gv_AMupdate
+Perl_Gversion_ptr
+Perl_Gveto_cleanup_ptr
+Perl_IArgv_ptr
+Perl_ICmd_ptr
+Perl_IDBgv_ptr
+Perl_IDBline_ptr
+Perl_IDBsignal_ptr
+Perl_IDBsingle_ptr
+Perl_IDBsub_ptr
+Perl_IDBtrace_ptr
+Perl_IDir_ptr
+Perl_IEnv_ptr
+Perl_ILIO_ptr
+Perl_IMemParse_ptr
+Perl_IMemShared_ptr
+Perl_IMem_ptr
+Perl_IOpPtr_ptr
+Perl_IOpSlab_ptr
+Perl_IOpSpace_ptr
+Perl_IProc_ptr
+Perl_ISock_ptr
+Perl_IStdIO_ptr
+Perl_ISv_ptr
+Perl_IXpv_ptr
+Perl_Iamagic_generation_ptr
+Perl_Ian_ptr
+Perl_Iargvgv_ptr
+Perl_Iargvout_stack_ptr
+Perl_Iargvoutgv_ptr
+Perl_Ibasetime_ptr
+Perl_Ibeginav_ptr
+Perl_Ibeginav_save_ptr
+Perl_Ibody_arenas_ptr
+Perl_Ibody_roots_ptr
+Perl_Ibodytarget_ptr
+Perl_Ibreakable_sub_gen_ptr
+Perl_Icheckav_ptr
+Perl_Icheckav_save_ptr
+Perl_Ichopset_ptr
+Perl_Iclocktick_ptr
+Perl_Icollation_ix_ptr
+Perl_Icollation_name_ptr
+Perl_Icollation_standard_ptr
+Perl_Icollxfrm_base_ptr
+Perl_Icollxfrm_mult_ptr
+Perl_Icolors_ptr
+Perl_Icolorset_ptr
+Perl_Icompcv_ptr
+Perl_Icompiling_ptr
+Perl_Icomppad_name_fill_ptr
+Perl_Icomppad_name_floor_ptr
+Perl_Icomppad_name_ptr
+Perl_Icomppad_ptr
+Perl_Icop_seqmax_ptr
+Perl_Icurcop_ptr
+Perl_Icurcopdb_ptr
+Perl_Icurpad_ptr
+Perl_Icurpm_ptr
+Perl_Icurstack_ptr
+Perl_Icurstackinfo_ptr
+Perl_Icurstash_ptr
+Perl_Icurstname_ptr
+Perl_Icustom_op_descs_ptr
+Perl_Icustom_op_names_ptr
+Perl_Icv_has_eval_ptr
+Perl_Idbargs_ptr
+Perl_Idebstash_ptr
+Perl_Idebug_pad_ptr
+Perl_Idebug_ptr
+Perl_Idef_layerlist_ptr
+Perl_Idefgv_ptr
+Perl_Idefoutgv_ptr
+Perl_Idefstash_ptr
+Perl_Idelaymagic_ptr
+Perl_Idestroyhook_ptr
+Perl_Idiehook_ptr
+Perl_Idirty_ptr
+Perl_Idoextract_ptr
+Perl_Idoswitches_ptr
+Perl_Idowarn_ptr
+Perl_Idumpindent_ptr
+Perl_Ie_script_ptr
+Perl_Iefloatbuf_ptr
+Perl_Iefloatsize_ptr
+Perl_Iegid_ptr
+Perl_Iencoding_ptr
+Perl_Iendav_ptr
+Perl_Ienvgv_ptr
+Perl_Ierrgv_ptr
+Perl_Ierrors_ptr
+Perl_Ieuid_ptr
+Perl_Ieval_root_ptr
+Perl_Ieval_start_ptr
+Perl_Ievalseq_ptr
+Perl_Iexit_flags_ptr
+Perl_Iexitlist_ptr
+Perl_Iexitlistlen_ptr
+Perl_Ifdpid_ptr
+Perl_Ifilemode_ptr
+Perl_Ifirstgv_ptr
+Perl_Iforkprocess_ptr
+Perl_Iformfeed_ptr
+Perl_Iformtarget_ptr
+Perl_Igensym_ptr
+Perl_Igid_ptr
+Perl_Iglob_index_ptr
+Perl_Iglobalstash_ptr
+Perl_Ihash_seed_ptr
+Perl_Ihintgv_ptr
+Perl_Ihints_ptr
+Perl_Ihv_fetch_ent_mh_ptr
+Perl_Iin_clean_all_ptr
+Perl_Iin_clean_objs_ptr
+Perl_Iin_eval_ptr
+Perl_Iin_load_module_ptr
+Perl_Iincgv_ptr
+Perl_Iinitav_ptr
+Perl_Iinplace_ptr
+Perl_Iisarev_ptr
+Perl_Iknown_layers_ptr
+Perl_Ilast_in_gv_ptr
+Perl_Ilast_swash_hv_ptr
+Perl_Ilast_swash_key_ptr
+Perl_Ilast_swash_klen_ptr
+Perl_Ilast_swash_slen_ptr
+Perl_Ilast_swash_tmps_ptr
+Perl_Ilastfd_ptr
+Perl_Ilastscream_ptr
+Perl_Ilaststatval_ptr
+Perl_Ilaststype_ptr
+Perl_Ilocalizing_ptr
+Perl_Ilocalpatches_ptr
+Perl_Ilockhook_ptr
+Perl_Imain_cv_ptr
+Perl_Imain_root_ptr
+Perl_Imain_start_ptr
+Perl_Imainstack_ptr
+Perl_Imarkstack_max_ptr
+Perl_Imarkstack_ptr
+Perl_Imarkstack_ptr_ptr
+Perl_Imax_intro_pending_ptr
+Perl_Imaxo_ptr
+Perl_Imaxscream_ptr
+Perl_Imaxsysfd_ptr
+Perl_Imess_sv_ptr
+Perl_Imin_intro_pending_ptr
+Perl_Iminus_E_ptr
+Perl_Iminus_F_ptr
+Perl_Iminus_a_ptr
+Perl_Iminus_c_ptr
+Perl_Iminus_l_ptr
+Perl_Iminus_n_ptr
+Perl_Iminus_p_ptr
+Perl_Imodglobal_ptr
+Perl_Imy_cxt_list_ptr
+Perl_Imy_cxt_size_ptr
+Perl_Ina_ptr
+Perl_Inice_chunk_ptr
+Perl_Inice_chunk_size_ptr
+Perl_Inomemok_ptr
+Perl_Inumeric_local_ptr
+Perl_Inumeric_name_ptr
+Perl_Inumeric_radix_sv_ptr
+Perl_Inumeric_standard_ptr
+Perl_Iofsgv_ptr
+Perl_Ioldname_ptr
+Perl_Iop_mask_ptr
+Perl_Iop_ptr
+Perl_Iopfreehook_ptr
+Perl_Iorigalen_ptr
+Perl_Iorigargc_ptr
+Perl_Iorigargv_ptr
+Perl_Iorigenviron_ptr
+Perl_Iorigfilename_ptr
+Perl_Iors_sv_ptr
+Perl_Iosname_ptr
+Perl_Ipad_reset_pending_ptr
+Perl_Ipadix_floor_ptr
+Perl_Ipadix_ptr
+Perl_Iparser_ptr
+Perl_Ipatchlevel_ptr
+Perl_Ipeepp_ptr
+Perl_Iperl_destruct_level_ptr
+Perl_Iperldb_ptr
+Perl_Iperlio_ptr
+Perl_Ipreambleav_ptr
+Perl_Iprofiledata_ptr
+Perl_Ipsig_name_ptr
+Perl_Ipsig_pend_ptr
+Perl_Ipsig_ptr_ptr
+Perl_Iptr_table_ptr
+Perl_Ireentrant_retint_ptr
+Perl_Ireg_state_ptr
+Perl_Iregdummy_ptr
+Perl_Iregex_pad_ptr
+Perl_Iregex_padav_ptr
+Perl_Ireginterp_cnt_ptr
+Perl_Iregistered_mros_ptr
+Perl_Iregmatch_slab_ptr
+Perl_Iregmatch_state_ptr
+Perl_Irehash_seed_ptr
+Perl_Irehash_seed_set_ptr
+Perl_Ireplgv_ptr
+Perl_Irestartop_ptr
+Perl_Irs_ptr
+Perl_Irunops_ptr
+Perl_Isavebegin_ptr
+Perl_Isavestack_ix_ptr
+Perl_Isavestack_max_ptr
+Perl_Isavestack_ptr
+Perl_Isawampersand_ptr
+Perl_Iscopestack_ix_ptr
+Perl_Iscopestack_max_ptr
+Perl_Iscopestack_name_ptr
+Perl_Iscopestack_ptr
+Perl_Iscreamfirst_ptr
+Perl_Iscreamnext_ptr
+Perl_Isecondgv_ptr
+Perl_Isharehook_ptr
+Perl_Isig_pending_ptr
+Perl_Isighandlerp_ptr
+Perl_Isignals_ptr
+Perl_Isort_RealCmp_ptr
+Perl_Isortcop_ptr
+Perl_Isortstash_ptr
+Perl_Isplitstr_ptr
+Perl_Isrand_called_ptr
+Perl_Istack_base_ptr
+Perl_Istack_max_ptr
+Perl_Istack_sp_ptr
+Perl_Istart_env_ptr
+Perl_Istashcache_ptr
+Perl_Istatbuf_ptr
+Perl_Istatcache_ptr
+Perl_Istatgv_ptr
+Perl_Istatname_ptr
+Perl_Istatusvalue_posix_ptr
+Perl_Istatusvalue_ptr
+Perl_Istderrgv_ptr
+Perl_Istdingv_ptr
+Perl_Istrtab_ptr
+Perl_Isub_generation_ptr
+Perl_Isubline_ptr
+Perl_Isubname_ptr
+Perl_Isv_arenaroot_ptr
+Perl_Isv_count_ptr
+Perl_Isv_no_ptr
+Perl_Isv_objcount_ptr
+Perl_Isv_root_ptr
+Perl_Isv_undef_ptr
+Perl_Isv_yes_ptr
+Perl_Isys_intern_ptr
+Perl_Itaint_warn_ptr
+Perl_Itainted_ptr
+Perl_Itainting_ptr
+Perl_Ithreadhook_ptr
+Perl_Itmps_floor_ptr
+Perl_Itmps_ix_ptr
+Perl_Itmps_max_ptr
+Perl_Itmps_stack_ptr
+Perl_Itop_env_ptr
+Perl_Itoptarget_ptr
+Perl_Iuid_ptr
+Perl_Iunicode_ptr
+Perl_Iunitcheckav_ptr
+Perl_Iunitcheckav_save_ptr
+Perl_Iunlockhook_ptr
+Perl_Iunsafe_ptr
+Perl_Iutf8_X_LVT_ptr
+Perl_Iutf8_X_LV_LVT_V_ptr
+Perl_Iutf8_X_LV_ptr
+Perl_Iutf8_X_L_ptr
+Perl_Iutf8_X_T_ptr
+Perl_Iutf8_X_V_ptr
+Perl_Iutf8_X_begin_ptr
+Perl_Iutf8_X_extend_ptr
+Perl_Iutf8_X_non_hangul_ptr
+Perl_Iutf8_X_prepend_ptr
+Perl_Iutf8_alnum_ptr
+Perl_Iutf8_alpha_ptr
+Perl_Iutf8_ascii_ptr
+Perl_Iutf8_cntrl_ptr
+Perl_Iutf8_digit_ptr
+Perl_Iutf8_graph_ptr
+Perl_Iutf8_idcont_ptr
+Perl_Iutf8_idstart_ptr
+Perl_Iutf8_lower_ptr
+Perl_Iutf8_mark_ptr
+Perl_Iutf8_perl_space_ptr
+Perl_Iutf8_perl_word_ptr
+Perl_Iutf8_posix_digit_ptr
+Perl_Iutf8_print_ptr
+Perl_Iutf8_punct_ptr
+Perl_Iutf8_space_ptr
+Perl_Iutf8_tofold_ptr
+Perl_Iutf8_tolower_ptr
+Perl_Iutf8_totitle_ptr
+Perl_Iutf8_toupper_ptr
+Perl_Iutf8_upper_ptr
+Perl_Iutf8_xdigit_ptr
+Perl_Iutf8cache_ptr
+Perl_Iutf8locale_ptr
+Perl_Iwarnhook_ptr
+Perl_PerlIO_clearerr
+Perl_PerlIO_close
+Perl_PerlIO_context_layers
+Perl_PerlIO_eof
+Perl_PerlIO_error
+Perl_PerlIO_fileno
+Perl_PerlIO_fill
+Perl_PerlIO_flush
+Perl_PerlIO_get_base
+Perl_PerlIO_get_bufsiz
+Perl_PerlIO_get_cnt
+Perl_PerlIO_get_ptr
+Perl_PerlIO_read
+Perl_PerlIO_seek
+Perl_PerlIO_set_cnt
+Perl_PerlIO_set_ptrcnt
+Perl_PerlIO_setlinebuf
+Perl_PerlIO_stderr
+Perl_PerlIO_stdin
+Perl_PerlIO_stdout
+Perl_PerlIO_tell
+Perl_PerlIO_unread
+Perl_PerlIO_write
+Perl_Slab_Alloc
+Perl_Slab_Free
+Perl_amagic_call
+Perl_any_dup
+Perl_apply_attrs_string
+Perl_atfork_lock
+Perl_atfork_unlock
+Perl_av_arylen_p
+Perl_av_clear
+Perl_av_delete
+Perl_av_exists
+Perl_av_extend
+Perl_av_fetch
+Perl_av_fill
+Perl_av_iter_p
+Perl_av_len
+Perl_av_make
+Perl_av_pop
+Perl_av_push
+Perl_av_reify
+Perl_av_shift
+Perl_av_store
+Perl_av_undef
+Perl_av_unshift
+Perl_block_gimme
+Perl_bytes_from_utf8
+Perl_bytes_to_utf8
+Perl_call_argv
+Perl_call_atexit
+Perl_call_list
+Perl_call_method
+Perl_call_pv
+Perl_call_sv
+Perl_calloc
+Perl_cast_i32
+Perl_cast_iv
+Perl_cast_ulong
+Perl_cast_uv
+Perl_ck_warner
+Perl_ck_warner_d
+Perl_ckwarn
+Perl_ckwarn_d
+Perl_croak
+Perl_croak_nocontext
+Perl_croak_xs_usage
+Perl_csighandler
+Perl_custom_op_desc
+Perl_custom_op_name
+Perl_cv_const_sv
+Perl_cv_undef
+Perl_cx_dump
+Perl_cx_dup
+Perl_cxinc
+Perl_deb
+Perl_deb_nocontext
+Perl_delimcpy
+Perl_despatch_signals
+Perl_die
+Perl_die_nocontext
+Perl_dirp_dup
+Perl_do_aexec
+Perl_do_aspawn
+Perl_do_binmode
+Perl_do_close
+Perl_do_gv_dump
+Perl_do_gvgv_dump
+Perl_do_hv_dump
+Perl_do_join
+Perl_do_magic_dump
+Perl_do_op_dump
+Perl_do_open
+Perl_do_open9
+Perl_do_openn
+Perl_do_pmop_dump
+Perl_do_spawn
+Perl_do_spawn_nowait
+Perl_do_sprintf
+Perl_do_sv_dump
+Perl_doing_taint
+Perl_doref
+Perl_dounwind
+Perl_dowantarray
+Perl_dump_all
+Perl_dump_eval
+Perl_dump_form
+Perl_dump_indent
+Perl_dump_packsubs
+Perl_dump_sub
+Perl_dump_vindent
+Perl_emulate_cop_io
+Perl_eval_pv
+Perl_eval_sv
+Perl_fbm_compile
+Perl_fbm_instr
+Perl_fetch_cop_label
+Perl_filter_add
+Perl_filter_del
+Perl_filter_read
+Perl_find_runcv
+Perl_find_rundefsvoffset
+Perl_form
+Perl_form_nocontext
+Perl_fp_dup
+Perl_fprintf_nocontext
+Perl_free_tmps
+Perl_get_av
+Perl_get_context
+Perl_get_cv
+Perl_get_cvn_flags
+Perl_get_hv
+Perl_get_op_descs
+Perl_get_op_names
+Perl_get_ppaddr
+Perl_get_re_arg
+Perl_get_sv
+Perl_get_vtbl
+Perl_getcwd_sv
+Perl_gp_dup
+Perl_gp_free
+Perl_gp_ref
+Perl_grok_bin
+Perl_grok_hex
+Perl_grok_number
+Perl_grok_numeric_radix
+Perl_grok_oct
+Perl_gv_AVadd
+Perl_gv_HVadd
+Perl_gv_IOadd
+Perl_gv_SVadd
+Perl_gv_add_by_type
+Perl_gv_autoload4
+Perl_gv_check
+Perl_gv_const_sv
+Perl_gv_dump
+Perl_gv_efullname
+Perl_gv_efullname3
+Perl_gv_efullname4
+Perl_gv_fetchfile
+Perl_gv_fetchfile_flags
+Perl_gv_fetchmeth
+Perl_gv_fetchmeth_autoload
+Perl_gv_fetchmethod
+Perl_gv_fetchmethod_autoload
+Perl_gv_fetchmethod_flags
+Perl_gv_fetchpv
+Perl_gv_fetchpvn_flags
+Perl_gv_fetchsv
+Perl_gv_fullname
+Perl_gv_fullname3
+Perl_gv_fullname4
+Perl_gv_handler
+Perl_gv_init
+Perl_gv_name_set
+Perl_gv_stashpv
+Perl_gv_stashpvn
+Perl_gv_stashsv
+Perl_gv_try_downgrade
+Perl_he_dup
+Perl_hek_dup
+Perl_hv_clear
+Perl_hv_clear_placeholders
+Perl_hv_common
+Perl_hv_common_key_len
+Perl_hv_delayfree_ent
+Perl_hv_delete
+Perl_hv_delete_ent
+Perl_hv_eiter_p
+Perl_hv_eiter_set
+Perl_hv_exists
+Perl_hv_exists_ent
+Perl_hv_fetch
+Perl_hv_fetch_ent
+Perl_hv_free_ent
+Perl_hv_iterinit
+Perl_hv_iterkey
+Perl_hv_iterkeysv
+Perl_hv_iternext
+Perl_hv_iternext_flags
+Perl_hv_iternextsv
+Perl_hv_iterval
+Perl_hv_ksplit
+Perl_hv_magic
+Perl_hv_name_set
+Perl_hv_placeholders_get
+Perl_hv_placeholders_p
+Perl_hv_placeholders_set
+Perl_hv_riter_p
+Perl_hv_riter_set
+Perl_hv_scalar
+Perl_hv_store
+Perl_hv_store_ent
+Perl_hv_store_flags
+Perl_hv_undef
+Perl_ibcmp
+Perl_ibcmp_locale
+Perl_ibcmp_utf8
+Perl_init_i18nl10n
+Perl_init_i18nl14n
+Perl_init_os_extras
+Perl_init_stacks
+Perl_init_tm
+Perl_instr
+Perl_is_ascii_string
+Perl_is_lvalue_sub
+Perl_is_uni_alnum
+Perl_is_uni_alnum_lc
+Perl_is_uni_alpha
+Perl_is_uni_alpha_lc
+Perl_is_uni_ascii
+Perl_is_uni_ascii_lc
+Perl_is_uni_cntrl
+Perl_is_uni_cntrl_lc
+Perl_is_uni_digit
+Perl_is_uni_digit_lc
+Perl_is_uni_graph
+Perl_is_uni_graph_lc
+Perl_is_uni_idfirst
+Perl_is_uni_idfirst_lc
+Perl_is_uni_lower
+Perl_is_uni_lower_lc
+Perl_is_uni_print
+Perl_is_uni_print_lc
+Perl_is_uni_punct
+Perl_is_uni_punct_lc
+Perl_is_uni_space
+Perl_is_uni_space_lc
+Perl_is_uni_upper
+Perl_is_uni_upper_lc
+Perl_is_uni_xdigit
+Perl_is_uni_xdigit_lc
+Perl_is_utf8_X_L
+Perl_is_utf8_X_LV
+Perl_is_utf8_X_LVT
+Perl_is_utf8_X_LV_LVT_V
+Perl_is_utf8_X_T
+Perl_is_utf8_X_V
+Perl_is_utf8_X_begin
+Perl_is_utf8_X_extend
+Perl_is_utf8_X_non_hangul
+Perl_is_utf8_X_prepend
+Perl_is_utf8_alnum
+Perl_is_utf8_alpha
+Perl_is_utf8_ascii
+Perl_is_utf8_char
+Perl_is_utf8_cntrl
+Perl_is_utf8_digit
+Perl_is_utf8_graph
+Perl_is_utf8_idcont
+Perl_is_utf8_idfirst
+Perl_is_utf8_lower
+Perl_is_utf8_mark
+Perl_is_utf8_perl_space
+Perl_is_utf8_perl_word
+Perl_is_utf8_posix_digit
+Perl_is_utf8_print
+Perl_is_utf8_punct
+Perl_is_utf8_space
+Perl_is_utf8_string
+Perl_is_utf8_string_loc
+Perl_is_utf8_string_loclen
+Perl_is_utf8_upper
+Perl_is_utf8_xdigit
+Perl_leave_scope
+Perl_lex_bufutf8
+Perl_lex_discard_to
+Perl_lex_end
+Perl_lex_grow_linestr
+Perl_lex_next_chunk
+Perl_lex_peek_unichar
+Perl_lex_read_space
+Perl_lex_read_to
+Perl_lex_read_unichar
+Perl_lex_stuff_pvn
+Perl_lex_stuff_sv
+Perl_lex_unstuff
+Perl_load_module
+Perl_load_module_nocontext
+Perl_looks_like_number
+Perl_magic_dump
+Perl_malloc
+Perl_markstack_grow
+Perl_mess
+Perl_mess_nocontext
+Perl_mfree
+Perl_mg_clear
+Perl_mg_copy
+Perl_mg_dup
+Perl_mg_find
+Perl_mg_free
+Perl_mg_get
+Perl_mg_length
+Perl_mg_magical
+Perl_mg_set
+Perl_mg_size
+Perl_mini_mktime
+Perl_mod
+Perl_moreswitches
+Perl_mro_get_from_name
+Perl_mro_get_linear_isa
+Perl_mro_get_private_data
+Perl_mro_meta_init
+Perl_mro_method_changed_in
+Perl_mro_register
+Perl_mro_set_mro
+Perl_mro_set_private_data
+Perl_my_atof
+Perl_my_atof2
+Perl_my_cxt_init
+Perl_my_dirfd
+Perl_my_exit
+Perl_my_failure_exit
+Perl_my_fflush_all
+Perl_my_fork
+Perl_my_lstat
+Perl_my_popen_list
+Perl_my_setenv
+Perl_my_snprintf
+Perl_my_socketpair
+Perl_my_stat
+Perl_my_strftime
+Perl_my_strlcat
+Perl_my_strlcpy
+Perl_my_vsnprintf
+Perl_newANONATTRSUB
+Perl_newANONHASH
+Perl_newANONLIST
+Perl_newANONSUB
+Perl_newASSIGNOP
+Perl_newATTRSUB
+Perl_newAV
+Perl_newAVREF
+Perl_newBINOP
+Perl_newCONDOP
+Perl_newCONSTSUB
+Perl_newCVREF
+Perl_newFORM
+Perl_newFOROP
+Perl_newGIVENOP
+Perl_newGVOP
+Perl_newGVREF
+Perl_newGVgen
+Perl_newHV
+Perl_newHVREF
+Perl_newHVhv
+Perl_newIO
+Perl_newLISTOP
+Perl_newLOGOP
+Perl_newLOOPEX
+Perl_newLOOPOP
+Perl_newMYSUB
+Perl_newNULLLIST
+Perl_newOP
+Perl_newPADOP
+Perl_newPMOP
+Perl_newPROG
+Perl_newPVOP
+Perl_newRANGE
+Perl_newRV
+Perl_newRV_noinc
+Perl_newSLICEOP
+Perl_newSTATEOP
+Perl_newSUB
+Perl_newSV
+Perl_newSVOP
+Perl_newSVREF
+Perl_newSV_type
+Perl_newSVhek
+Perl_newSViv
+Perl_newSVnv
+Perl_newSVpv
+Perl_newSVpvf
+Perl_newSVpvf_nocontext
+Perl_newSVpvn
+Perl_newSVpvn_flags
+Perl_newSVpvn_share
+Perl_newSVrv
+Perl_newSVsv
+Perl_newSVuv
+Perl_newUNOP
+Perl_newWHENOP
+Perl_newWHILEOP
+Perl_newXS
+Perl_newXS_flags
+Perl_new_collate
+Perl_new_ctype
+Perl_new_numeric
+Perl_new_stackinfo
+Perl_new_version
+Perl_new_warnings_bitfield
+Perl_ninstr
+Perl_nothreadhook
+Perl_op_clear
+Perl_op_dump
+Perl_op_free
+Perl_op_null
+Perl_op_refcnt_lock
+Perl_op_refcnt_unlock
+Perl_pack_cat
+Perl_packlist
+Perl_pad_findmy
+Perl_pad_push
+Perl_parser_dup
+Perl_pmflag
+Perl_pmop_dump
+Perl_pop_scope
+Perl_pregcomp
+Perl_pregexec
+Perl_pregfree
+Perl_pregfree2
+Perl_prescan_version
+Perl_printf_nocontext
+Perl_ptr_table_clear
+Perl_ptr_table_fetch
+Perl_ptr_table_free
+Perl_ptr_table_new
+Perl_ptr_table_split
+Perl_ptr_table_store
+Perl_push_scope
+Perl_pv_display
+Perl_pv_escape
+Perl_pv_pretty
+Perl_pv_uni_display
+Perl_qerror
+Perl_re_compile
+Perl_re_dup_guts
+Perl_re_intuit_start
+Perl_re_intuit_string
+Perl_realloc
+Perl_reentrant_free
+Perl_reentrant_init
+Perl_reentrant_retry
+Perl_reentrant_size
+Perl_ref
+Perl_refcounted_he_chain_2hv
+Perl_refcounted_he_fetch
+Perl_refcounted_he_new
+Perl_reg_named_buff
+Perl_reg_named_buff_all
+Perl_reg_named_buff_exists
+Perl_reg_named_buff_fetch
+Perl_reg_named_buff_firstkey
+Perl_reg_named_buff_iter
+Perl_reg_named_buff_nextkey
+Perl_reg_named_buff_scalar
+Perl_reg_numbered_buff_fetch
+Perl_reg_numbered_buff_length
+Perl_reg_numbered_buff_store
+Perl_reg_qr_package
+Perl_reg_temp_copy
+Perl_regclass_swash
+Perl_regcurly
+Perl_regdump
+Perl_regdupe_internal
+Perl_regexec_flags
+Perl_regfree_internal
+Perl_reginitcolors
+Perl_regnext
+Perl_repeatcpy
+Perl_report_uninit
+Perl_require_pv
+Perl_rninstr
+Perl_rsignal
+Perl_rsignal_state
+Perl_runops_debug
+Perl_runops_standard
+Perl_rvpv_dup
+Perl_safesyscalloc
+Perl_safesysfree
+Perl_safesysmalloc
+Perl_safesysrealloc
+Perl_save_I16
+Perl_save_I32
+Perl_save_I8
+Perl_save_adelete
+Perl_save_aelem_flags
+Perl_save_alloc
+Perl_save_aptr
+Perl_save_ary
+Perl_save_bool
+Perl_save_clearsv
+Perl_save_delete
+Perl_save_destructor
+Perl_save_destructor_x
+Perl_save_freeop
+Perl_save_freepv
+Perl_save_freesv
+Perl_save_generic_pvref
+Perl_save_generic_svref
+Perl_save_gp
+Perl_save_hash
+Perl_save_hdelete
+Perl_save_helem_flags
+Perl_save_hptr
+Perl_save_int
+Perl_save_item
+Perl_save_iv
+Perl_save_list
+Perl_save_long
+Perl_save_mortalizesv
+Perl_save_nogv
+Perl_save_op
+Perl_save_padsv_and_mortalize
+Perl_save_pptr
+Perl_save_pushptr
+Perl_save_re_context
+Perl_save_scalar
+Perl_save_set_svflags
+Perl_save_shared_pvref
+Perl_save_sptr
+Perl_save_svref
+Perl_save_vptr
+Perl_savepv
+Perl_savepvn
+Perl_savesharedpv
+Perl_savesharedpvn
+Perl_savestack_grow
+Perl_savestack_grow_cnt
+Perl_savesvpv
+Perl_scan_bin
+Perl_scan_hex
+Perl_scan_num
+Perl_scan_oct
+Perl_scan_version
+Perl_scan_vstring
+Perl_screaminstr
+Perl_seed
+Perl_set_context
+Perl_set_numeric_local
+Perl_set_numeric_radix
+Perl_set_numeric_standard
+Perl_setdefout
+Perl_share_hek
+Perl_si_dup
+Perl_signbit
+Perl_sortsv
+Perl_sortsv_flags
+Perl_ss_dup
+Perl_stack_grow
+Perl_start_subparse
+Perl_stashpv_hvname_match
+Perl_str_to_version
+Perl_sv_2bool
+Perl_sv_2cv
+Perl_sv_2io
+Perl_sv_2iv
+Perl_sv_2iv_flags
+Perl_sv_2mortal
+Perl_sv_2nv
+Perl_sv_2pv
+Perl_sv_2pv_flags
+Perl_sv_2pv_nolen
+Perl_sv_2pvbyte
+Perl_sv_2pvbyte_nolen
+Perl_sv_2pvutf8
+Perl_sv_2pvutf8_nolen
+Perl_sv_2uv
+Perl_sv_2uv_flags
+Perl_sv_backoff
+Perl_sv_bless
+Perl_sv_cat_decode
+Perl_sv_catpv
+Perl_sv_catpv_mg
+Perl_sv_catpvf
+Perl_sv_catpvf_mg
+Perl_sv_catpvf_mg_nocontext
+Perl_sv_catpvf_nocontext
+Perl_sv_catpvn
+Perl_sv_catpvn_flags
+Perl_sv_catpvn_mg
+Perl_sv_catsv
+Perl_sv_catsv_flags
+Perl_sv_catsv_mg
+Perl_sv_chop
+Perl_sv_clear
+Perl_sv_cmp
+Perl_sv_cmp_locale
+Perl_sv_collxfrm
+Perl_sv_compile_2op
+Perl_sv_copypv
+Perl_sv_dec
+Perl_sv_derived_from
+Perl_sv_destroyable
+Perl_sv_does
+Perl_sv_dump
+Perl_sv_dup
+Perl_sv_eq
+Perl_sv_force_normal
+Perl_sv_force_normal_flags
+Perl_sv_free
+Perl_sv_free2
+Perl_sv_gets
+Perl_sv_grow
+Perl_sv_inc
+Perl_sv_insert
+Perl_sv_insert_flags
+Perl_sv_isa
+Perl_sv_isobject
+Perl_sv_iv
+Perl_sv_len
+Perl_sv_len_utf8
+Perl_sv_magic
+Perl_sv_magicext
+Perl_sv_mortalcopy
+Perl_sv_newmortal
+Perl_sv_newref
+Perl_sv_nolocking
+Perl_sv_nosharing
+Perl_sv_nounlocking
+Perl_sv_nv
+Perl_sv_peek
+Perl_sv_pos_b2u
+Perl_sv_pos_u2b
+Perl_sv_pos_u2b_flags
+Perl_sv_pv
+Perl_sv_pvbyte
+Perl_sv_pvbyten
+Perl_sv_pvbyten_force
+Perl_sv_pvn
+Perl_sv_pvn_force
+Perl_sv_pvn_force_flags
+Perl_sv_pvn_nomg
+Perl_sv_pvutf8
+Perl_sv_pvutf8n
+Perl_sv_pvutf8n_force
+Perl_sv_recode_to_utf8
+Perl_sv_reftype
+Perl_sv_replace
+Perl_sv_report_used
+Perl_sv_reset
+Perl_sv_rvweaken
+Perl_sv_setiv
+Perl_sv_setiv_mg
+Perl_sv_setnv
+Perl_sv_setnv_mg
+Perl_sv_setpv
+Perl_sv_setpv_mg
+Perl_sv_setpvf
+Perl_sv_setpvf_mg
+Perl_sv_setpvf_mg_nocontext
+Perl_sv_setpvf_nocontext
+Perl_sv_setpviv
+Perl_sv_setpviv_mg
+Perl_sv_setpvn
+Perl_sv_setpvn_mg
+Perl_sv_setref_iv
+Perl_sv_setref_nv
+Perl_sv_setref_pv
+Perl_sv_setref_pvn
+Perl_sv_setref_uv
+Perl_sv_setsv
+Perl_sv_setsv_flags
+Perl_sv_setsv_mg
+Perl_sv_setuv
+Perl_sv_setuv_mg
+Perl_sv_taint
+Perl_sv_tainted
+Perl_sv_true
+Perl_sv_uni_display
+Perl_sv_unmagic
+Perl_sv_unref
+Perl_sv_unref_flags
+Perl_sv_untaint
+Perl_sv_upgrade
+Perl_sv_usepvn
+Perl_sv_usepvn_flags
+Perl_sv_usepvn_mg
+Perl_sv_utf8_decode
+Perl_sv_utf8_downgrade
+Perl_sv_utf8_encode
+Perl_sv_utf8_upgrade
+Perl_sv_utf8_upgrade_flags_grow
+Perl_sv_uv
+Perl_sv_vcatpvf
+Perl_sv_vcatpvf_mg
+Perl_sv_vcatpvfn
+Perl_sv_vsetpvf
+Perl_sv_vsetpvf_mg
+Perl_sv_vsetpvfn
+Perl_swash_fetch
+Perl_swash_init
+Perl_sys_init
+Perl_sys_init3
+Perl_sys_intern_clear
+Perl_sys_intern_dup
+Perl_sys_intern_init
+Perl_sys_term
+Perl_taint_env
+Perl_taint_proper
+Perl_tmps_grow
+Perl_to_uni_fold
+Perl_to_uni_lower
+Perl_to_uni_lower_lc
+Perl_to_uni_title
+Perl_to_uni_title_lc
+Perl_to_uni_upper
+Perl_to_uni_upper_lc
+Perl_to_utf8_case
+Perl_to_utf8_fold
+Perl_to_utf8_lower
+Perl_to_utf8_title
+Perl_to_utf8_upper
+Perl_unpack_str
+Perl_unpackstring
+Perl_unsharepvn
+Perl_upg_version
+Perl_utf16_to_utf8
+Perl_utf16_to_utf8_reversed
+Perl_utf8_distance
+Perl_utf8_hop
+Perl_utf8_length
+Perl_utf8_to_bytes
+Perl_utf8_to_uvchr
+Perl_utf8_to_uvuni
+Perl_utf8n_to_uvchr
+Perl_utf8n_to_uvuni
+Perl_uvchr_to_utf8
+Perl_uvchr_to_utf8_flags
+Perl_uvuni_to_utf8
+Perl_uvuni_to_utf8_flags
+Perl_vcmp
+Perl_vcroak
+Perl_vdeb
+Perl_vform
+Perl_vivify_defelem
+Perl_vload_module
+Perl_vmess
+Perl_vnewSVpvf
+Perl_vnormal
+Perl_vnumify
+Perl_vstringify
+Perl_vverify
+Perl_vwarn
+Perl_vwarner
+Perl_warn
+Perl_warn_nocontext
+Perl_warner
+Perl_warner_nocontext
+Perl_whichsig
+Perl_win32_init
+Perl_win32_term
+Perl_yylex
+RunPerl
+boot_DynaLoader
+boot_Win32CORE
+init_Win32CORE
+perl_alloc
+perl_alloc_override
+perl_alloc_using
+perl_clone
+perl_clone_host
+perl_clone_using
+perl_construct
+perl_destruct
+perl_free
+perl_get_host_info
+perl_parse
+perl_run
+perlsio_binmode
+setgid
+setuid
+win32_abort
+win32_accept
+win32_access
+win32_alarm
+win32_ansipath
+win32_async_check
+win32_bind
+win32_calloc
+win32_chdir
+win32_chmod
+win32_chsize
+win32_clearenv
+win32_clearerr
+win32_close
+win32_closedir
+win32_closesocket
+win32_connect
+win32_crypt
+win32_dup
+win32_dup2
+win32_dynaload
+win32_endhostent
+win32_endnetent
+win32_endprotoent
+win32_endservent
+win32_environ
+win32_eof
+win32_errno
+win32_execv
+win32_execvp
+win32_fclose
+win32_fcloseall
+win32_fdopen
+win32_feof
+win32_ferror
+win32_fflush
+win32_fgetc
+win32_fgetpos
+win32_fgets
+win32_fileno
+win32_flock
+win32_flushall
+win32_fopen
+win32_fprintf
+win32_fputc
+win32_fputs
+win32_fread
+win32_free
+win32_free_childdir
+win32_free_childenv
+win32_freopen
+win32_fseek
+win32_fsetpos
+win32_fstat
+win32_ftell
+win32_fwrite
+win32_get_childdir
+win32_get_childenv
+win32_get_osfhandle
+win32_getc
+win32_getchar
+win32_getenv
+win32_gethostbyaddr
+win32_gethostbyname
+win32_gethostname
+win32_getnetbyaddr
+win32_getnetbyname
+win32_getnetent
+win32_getpeername
+win32_getpid
+win32_getprotobyname
+win32_getprotobynumber
+win32_getprotoent
+win32_gets
+win32_getservbyname
+win32_getservbyport
+win32_getservent
+win32_getsockname
+win32_getsockopt
+win32_gettimeofday
+win32_htonl
+win32_htons
+win32_inet_addr
+win32_inet_ntoa
+win32_ioctl
+win32_ioctlsocket
+win32_isatty
+win32_kill
+win32_link
+win32_listen
+win32_longpath
+win32_lseek
+win32_malloc
+win32_mkdir
+win32_ntohl
+win32_ntohs
+win32_open
+win32_open_osfhandle
+win32_opendir
+win32_os_id
+win32_pclose
+win32_perror
+win32_pipe
+win32_popen
+win32_printf
+win32_putc
+win32_putchar
+win32_putenv
+win32_puts
+win32_read
+win32_readdir
+win32_realloc
+win32_recv
+win32_recvfrom
+win32_rename
+win32_rewind
+win32_rewinddir
+win32_rmdir
+win32_seekdir
+win32_select
+win32_send
+win32_sendto
+win32_setbuf
+win32_sethostent
+win32_setmode
+win32_setnetent
+win32_setprotoent
+win32_setservent
+win32_setsockopt
+win32_setvbuf
+win32_shutdown
+win32_sleep
+win32_socket
+win32_spawnvp
+win32_stat
+win32_stderr
+win32_stdin
+win32_stdout
+win32_str_os_error
+win32_strerror
+win32_tell
+win32_telldir
+win32_times
+win32_tmpfile
+win32_uname
+win32_ungetc
+win32_unlink
+win32_utime
+win32_vfprintf
+win32_vprintf
+win32_wait
+win32_waitpid
+win32_write
diff --git a/plugins/perl/importlib/sbperl-x64.bat b/plugins/perl/importlib/sbperl-x64.bat
new file mode 100644
index 00000000..a27ab442
--- /dev/null
+++ b/plugins/perl/importlib/sbperl-x64.bat
@@ -0,0 +1,10 @@
+@echo off
+set PATH=c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin\amd64
+cd c:\mozilla-build\perl-5.12-x64\perl\lib\CORE
+echo.Overwrite existing def file?
+pause
+dumpbin /exports ..\..\bin\perl512.dll > perl512.def
+echo.Please adjust the resulting file manually, then hit return!
+pause
+lib /machine:x64 /def:perl512.def
+pause
diff --git a/plugins/perl/importlib/sbperl-x86.bat b/plugins/perl/importlib/sbperl-x86.bat
new file mode 100644
index 00000000..e0b1a3dd
--- /dev/null
+++ b/plugins/perl/importlib/sbperl-x86.bat
@@ -0,0 +1,10 @@
+@echo off
+set PATH=c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin;C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE
+cd c:\mozilla-build\perl-5.12-x86\perl\lib\CORE
+echo.Overwrite existing def file?
+pause
+dumpbin /exports ..\..\bin\perl512.dll > perl512.def
+echo.Please adjust the resulting file manually, then hit return!
+pause
+lib /machine:x86 /def:perl512.def
+pause
-- 
cgit 1.4.1


From ffa31af46bdab63cee64b5e760fc7a26be380c72 Mon Sep 17 00:00:00 2001
From: "berkeviktor@aol.com" <berkeviktor@aol.com>
Date: Wed, 27 Jul 2011 06:20:29 +0200
Subject: some capitalization

---
 plugins/perl/makefile-512.mak | 2 +-
 plugins/perl/makefile-514.mak | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

(limited to 'plugins')

diff --git a/plugins/perl/makefile-512.mak b/plugins/perl/makefile-512.mak
index e4887ff9..3388e84f 100644
--- a/plugins/perl/makefile-512.mak
+++ b/plugins/perl/makefile-512.mak
@@ -20,7 +20,7 @@ xchat.pm.h: lib/Xchat.pm lib/IRC.pm
 	perl.exe generate_header
 
 $(TARGET): perl.obj perl.def
-	$(LINK) /DLL /out:$(TARGET) perl.obj $(LDFLAGS) $(PERL512LIB).lib /libpath:$(PERL512PATH) /DELAYLOAD:$(PERL512LIB).dll $(DIRENTLIB) DELAYIMP.LIB user32.lib shell32.lib advapi32.lib /def:perl.def
+	$(LINK) /DLL /out:$(TARGET) perl.obj $(LDFLAGS) $(PERL512LIB).lib /libpath:$(PERL512PATH) /delayload:$(PERL512LIB).dll $(DIRENTLIB) DELAYIMP.LIB user32.lib shell32.lib advapi32.lib /def:perl.def
 
 clean:
 	@del $(TARGET)
diff --git a/plugins/perl/makefile-514.mak b/plugins/perl/makefile-514.mak
index 94ee456f..657bc7dd 100644
--- a/plugins/perl/makefile-514.mak
+++ b/plugins/perl/makefile-514.mak
@@ -20,7 +20,7 @@ xchat.pm.h: lib/Xchat.pm lib/IRC.pm
 	perl.exe generate_header
 
 $(TARGET): perl.obj perl.def
-	$(LINK) /DLL /out:$(TARGET) perl.obj $(LDFLAGS) $(PERL514LIB).lib /libpath:$(PERL514PATH) /DELAYLOAD:$(PERL514LIB).dll $(DIRENTLIB) DELAYIMP.LIB user32.lib shell32.lib advapi32.lib /def:perl.def
+	$(LINK) /DLL /out:$(TARGET) perl.obj $(LDFLAGS) $(PERL514LIB).lib /libpath:$(PERL514PATH) /delayload:$(PERL514LIB).dll $(DIRENTLIB) DELAYIMP.LIB user32.lib shell32.lib advapi32.lib /def:perl.def
 
 clean:
 	@del $(TARGET)
-- 
cgit 1.4.1


From f46ddeaecad23c3a9415f02215240f478ff58ee0 Mon Sep 17 00:00:00 2001
From: "berkeviktor@aol.com" <berkeviktor@aol.com>
Date: Wed, 27 Jul 2011 06:22:31 +0200
Subject: some more capitalization

---
 plugins/perl/makefile-512.mak | 2 +-
 plugins/perl/makefile-514.mak | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

(limited to 'plugins')

diff --git a/plugins/perl/makefile-512.mak b/plugins/perl/makefile-512.mak
index 3388e84f..15f78a23 100644
--- a/plugins/perl/makefile-512.mak
+++ b/plugins/perl/makefile-512.mak
@@ -20,7 +20,7 @@ xchat.pm.h: lib/Xchat.pm lib/IRC.pm
 	perl.exe generate_header
 
 $(TARGET): perl.obj perl.def
-	$(LINK) /DLL /out:$(TARGET) perl.obj $(LDFLAGS) $(PERL512LIB).lib /libpath:$(PERL512PATH) /delayload:$(PERL512LIB).dll $(DIRENTLIB) DELAYIMP.LIB user32.lib shell32.lib advapi32.lib /def:perl.def
+	$(LINK) /DLL /out:$(TARGET) perl.obj $(LDFLAGS) $(PERL512LIB).lib /libpath:$(PERL512PATH) /delayload:$(PERL512LIB).dll $(DIRENTLIB) delayimp.lib user32.lib shell32.lib advapi32.lib /def:perl.def
 
 clean:
 	@del $(TARGET)
diff --git a/plugins/perl/makefile-514.mak b/plugins/perl/makefile-514.mak
index 657bc7dd..8c689979 100644
--- a/plugins/perl/makefile-514.mak
+++ b/plugins/perl/makefile-514.mak
@@ -20,7 +20,7 @@ xchat.pm.h: lib/Xchat.pm lib/IRC.pm
 	perl.exe generate_header
 
 $(TARGET): perl.obj perl.def
-	$(LINK) /DLL /out:$(TARGET) perl.obj $(LDFLAGS) $(PERL514LIB).lib /libpath:$(PERL514PATH) /delayload:$(PERL514LIB).dll $(DIRENTLIB) DELAYIMP.LIB user32.lib shell32.lib advapi32.lib /def:perl.def
+	$(LINK) /DLL /out:$(TARGET) perl.obj $(LDFLAGS) $(PERL514LIB).lib /libpath:$(PERL514PATH) /delayload:$(PERL514LIB).dll $(DIRENTLIB) delayimp.lib user32.lib shell32.lib advapi32.lib /def:perl.def
 
 clean:
 	@del $(TARGET)
-- 
cgit 1.4.1


From 34144faca5e0bb09ccc4cee4e298cb80dff740dd Mon Sep 17 00:00:00 2001
From: "berkeviktor@aol.com" <berkeviktor@aol.com>
Date: Wed, 27 Jul 2011 08:06:02 +0200
Subject: fix xtray blinking on unselected events

---
 plugins/xtray/callbacks.cpp | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

(limited to 'plugins')

diff --git a/plugins/xtray/callbacks.cpp b/plugins/xtray/callbacks.cpp
index 636c114e..18547ab3 100644
--- a/plugins/xtray/callbacks.cpp
+++ b/plugins/xtray/callbacks.cpp
@@ -167,10 +167,9 @@ int event_cb(char *word[], void *userdata)
 		free(szTemp);
 	}
 
-	if(g_dwPrefs & (1<<PREF_BLINK))
+	if(g_dwPrefs & (1<<PREF_BLINK) && (g_dwPrefs & (1<<iEvent)))
 	{
 		BlinkIcon(g_hXchatWnd, 1, g_hIcons[0], g_hIcons[(iEvent+1)], 700, 5);
-		
 	}
 
 	/***********************************/
-- 
cgit 1.4.1


From 69ba67b2549b6c6a46abd19879b67e1545c9ae3b Mon Sep 17 00:00:00 2001
From: "berkeviktor@aol.com" <berkeviktor@aol.com>
Date: Wed, 27 Jul 2011 09:04:58 +0200
Subject: fix xtray keyboard shortcut handling

---
 plugins/xtray/utility.cpp | 47 +++++++++++++++++++++++++++++++++++++++++++++--
 plugins/xtray/utility.h   |  3 +++
 2 files changed, 48 insertions(+), 2 deletions(-)

(limited to 'plugins')

diff --git a/plugins/xtray/utility.cpp b/plugins/xtray/utility.cpp
index 60f3f2f0..4faed90b 100644
--- a/plugins/xtray/utility.cpp
+++ b/plugins/xtray/utility.cpp
@@ -29,6 +29,49 @@
 TCHAR BACKUP_INI_FILE[] = _T(".\\plugins\\config\\xtray.conf");
 struct HOTKEY g_hHotKey;
 
+/* we need to convert ALT and SHIFT modifiers
+// from <winuser.h>
+#define MOD_ALT         0x0001
+#define MOD_CONTROL     0x0002
+#define MOD_SHIFT       0x0004
+// from <commctrl.h>
+#define HOTKEYF_SHIFT           0x01
+#define HOTKEYF_CONTROL         0x02
+#define HOTKEYF_ALT             0x04
+*/
+
+WORD HotkeyfToMod(WORD modifiers)
+{
+	WORD newmods = 0;
+
+	if (modifiers & HOTKEYF_SHIFT)
+		newmods |= MOD_SHIFT;
+
+	if (modifiers & HOTKEYF_CONTROL)
+		newmods |= MOD_CONTROL;
+
+	if (modifiers & HOTKEYF_ALT)
+		newmods |= MOD_ALT;
+
+	return newmods;
+}
+
+WORD ModToHotkeyf(WORD modifiers)
+{
+	WORD newmods = 0;
+
+	if (modifiers & MOD_SHIFT)
+		newmods |= HOTKEYF_SHIFT;
+
+	if (modifiers & MOD_CONTROL)
+		newmods |= HOTKEYF_CONTROL;
+
+	if (modifiers & MOD_ALT)
+		newmods |= HOTKEYF_ALT;
+
+	return newmods;
+}
+
 void SavePrefs(int iDlg)
 {
 	/**************************************************************************************************/
@@ -292,7 +335,7 @@ void CheckPrefs(HWND hwnd, int iDlg)
 			hHotkey = SendDlgItemMessage(hwnd, IDC_ALERT_HOTKEY, HKM_GETHOTKEY, 0, 0);
 			
 			g_hHotKey.key = LOBYTE(hHotkey);
-			g_hHotKey.mod = HIBYTE(hHotkey);
+			g_hHotKey.mod = HotkeyfToMod(HIBYTE(hHotkey));
 			
 			if(IsDlgButtonChecked(hwnd, PREF_UWIOB) == BST_CHECKED)
 			{
@@ -403,7 +446,7 @@ void SetDialog(HWND hwnd, int iDlg)
 			/**********************************************************/
 			TCHAR tTime[255];
 			SendDlgItemMessage(hwnd, IDC_ALERT_TIME,	WM_SETTEXT, 0, (LPARAM)_itot(g_iTime, tTime, 10));
-			SendDlgItemMessage(hwnd, IDC_ALERT_HOTKEY,	HKM_SETHOTKEY, MAKEWORD(g_hHotKey.key, g_hHotKey.mod), 0);
+			SendDlgItemMessage(hwnd, IDC_ALERT_HOTKEY,	HKM_SETHOTKEY, MAKEWORD(g_hHotKey.key, ModToHotkeyf(g_hHotKey.mod)), 0);
 		}
 		break;
 	}
diff --git a/plugins/xtray/utility.h b/plugins/xtray/utility.h
index ce3d541c..6bee8aed 100644
--- a/plugins/xtray/utility.h
+++ b/plugins/xtray/utility.h
@@ -19,6 +19,9 @@
 #ifndef _H_UTILITY_H
 #define _H_UTILITY_H
 
+WORD					HotkeyfToMod	(WORD);
+WORD					ModToHotkeyf	(WORD);
+
 int						SetOption		(HWND, unsigned int, unsigned int);
 int						SetCheck		(HWND, unsigned int, unsigned int);
 int						SetToggle		(HWND, unsigned int, unsigned int, bool);
-- 
cgit 1.4.1


From b6a0e0d086d5b314742b9ecc84f2392b5dada5c8 Mon Sep 17 00:00:00 2001
From: "berkeviktor@aol.com" <berkeviktor@aol.com>
Date: Thu, 28 Jul 2011 00:05:58 +0200
Subject: polish the building process of the perl interface

---
 build/strawberry-importlib.bat         |   19 +
 plugins/perl/importlib/perl512-x64.def | 1420 --------------------------------
 plugins/perl/importlib/perl512-x86.def | 1420 --------------------------------
 plugins/perl/importlib/sbperl-x64.bat  |   10 -
 plugins/perl/importlib/sbperl-x86.bat  |   10 -
 plugins/perl/makefile-512.mak          |   13 +-
 plugins/perl/makefile-514.mak          |    2 +-
 plugins/perl/perl512.def               | 1420 ++++++++++++++++++++++++++++++++
 src/makeinc.skel.mak                   |    4 +-
 9 files changed, 1452 insertions(+), 2866 deletions(-)
 create mode 100644 build/strawberry-importlib.bat
 delete mode 100644 plugins/perl/importlib/perl512-x64.def
 delete mode 100644 plugins/perl/importlib/perl512-x86.def
 delete mode 100644 plugins/perl/importlib/sbperl-x64.bat
 delete mode 100644 plugins/perl/importlib/sbperl-x86.bat
 create mode 100644 plugins/perl/perl512.def

(limited to 'plugins')

diff --git a/build/strawberry-importlib.bat b/build/strawberry-importlib.bat
new file mode 100644
index 00000000..61da96b3
--- /dev/null
+++ b/build/strawberry-importlib.bat
@@ -0,0 +1,19 @@
+@echo off
+set PATH=c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin;C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE
+cd c:\mozilla-build\perl-5.12-x86\perl\lib\CORE
+echo.Overwrite existing def file?
+pause
+dumpbin /exports ..\..\bin\perl512.dll > perl512.def
+echo.Please adjust the resulting file manually, then hit return!
+pause
+lib /machine:x86 /def:perl512.def
+pause
+set PATH=c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin\amd64
+cd c:\mozilla-build\perl-5.12-x64\perl\lib\CORE
+echo.Overwrite existing def file?
+pause
+dumpbin /exports ..\..\bin\perl512.dll > perl512.def
+echo.Please adjust the resulting file manually, then hit return!
+pause
+lib /machine:x64 /def:perl512.def
+pause 
diff --git a/plugins/perl/importlib/perl512-x64.def b/plugins/perl/importlib/perl512-x64.def
deleted file mode 100644
index 5cfcaa68..00000000
--- a/plugins/perl/importlib/perl512-x64.def
+++ /dev/null
@@ -1,1420 +0,0 @@
-LIBRARY perl512
-EXPORTS
-PL_bincompat_options
-PL_check
-PL_fold
-PL_fold_locale
-PL_freq
-PL_keyword_plugin
-PL_memory_wrap
-PL_no_aelem
-PL_no_dir_func
-PL_no_func
-PL_no_helem_sv
-PL_no_localize_ref
-PL_no_mem
-PL_no_modify
-PL_no_myglob
-PL_no_security
-PL_no_sock_func
-PL_no_symref
-PL_no_usym
-PL_no_wrongref
-PL_op_desc
-PL_op_name
-PL_opargs
-PL_perlio_mutex
-PL_ppaddr
-PL_reg_extflags_name
-PL_reg_name
-PL_regkind
-PL_sig_name
-PL_sig_num
-PL_simple
-PL_utf8skip
-PL_uuemap
-PL_varies
-PL_vtbl_amagic
-PL_vtbl_amagicelem
-PL_vtbl_arylen
-PL_vtbl_backref
-PL_vtbl_bm
-PL_vtbl_collxfrm
-PL_vtbl_dbline
-PL_vtbl_defelem
-PL_vtbl_env
-PL_vtbl_envelem
-PL_vtbl_fm
-PL_vtbl_isa
-PL_vtbl_isaelem
-PL_vtbl_mglob
-PL_vtbl_nkeys
-PL_vtbl_pack
-PL_vtbl_packelem
-PL_vtbl_pos
-PL_vtbl_regdata
-PL_vtbl_regdatum
-PL_vtbl_regexp
-PL_vtbl_sig
-PL_vtbl_sigelem
-PL_vtbl_substr
-PL_vtbl_sv
-PL_vtbl_taint
-PL_vtbl_utf8
-PL_vtbl_uvar
-PL_vtbl_vec
-PL_warn_nl
-PL_warn_nosemi
-PL_warn_reserved
-PL_warn_uninit
-PerlIOBase_binmode
-PerlIOBase_clearerr
-PerlIOBase_close
-PerlIOBase_dup
-PerlIOBase_eof
-PerlIOBase_error
-PerlIOBase_fileno
-PerlIOBase_noop_fail
-PerlIOBase_noop_ok
-PerlIOBase_popped
-PerlIOBase_pushed
-PerlIOBase_read
-PerlIOBase_setlinebuf
-PerlIOBase_unread
-PerlIOBuf_bufsiz
-PerlIOBuf_close
-PerlIOBuf_dup
-PerlIOBuf_fill
-PerlIOBuf_flush
-PerlIOBuf_get_base
-PerlIOBuf_get_cnt
-PerlIOBuf_get_ptr
-PerlIOBuf_open
-PerlIOBuf_popped
-PerlIOBuf_pushed
-PerlIOBuf_read
-PerlIOBuf_seek
-PerlIOBuf_set_ptrcnt
-PerlIOBuf_tell
-PerlIOBuf_unread
-PerlIOBuf_write
-PerlIO_allocate
-PerlIO_apply_layera
-PerlIO_apply_layers
-PerlIO_arg_fetch
-PerlIO_binmode
-PerlIO_canset_cnt
-PerlIO_debug
-PerlIO_define_layer
-PerlIO_exportFILE
-PerlIO_fast_gets
-PerlIO_fdopen
-PerlIO_findFILE
-PerlIO_find_layer
-PerlIO_getc
-PerlIO_getname
-PerlIO_getpos
-PerlIO_has_base
-PerlIO_has_cntptr
-PerlIO_importFILE
-PerlIO_init
-PerlIO_isutf8
-PerlIO_layer_fetch
-PerlIO_list_alloc
-PerlIO_list_free
-PerlIO_modestr
-PerlIO_open
-PerlIO_parse_layers
-PerlIO_pending
-PerlIO_perlio
-PerlIO_pop
-PerlIO_printf
-PerlIO_push
-PerlIO_putc
-PerlIO_puts
-PerlIO_releaseFILE
-PerlIO_reopen
-PerlIO_rewind
-PerlIO_setpos
-PerlIO_sprintf
-PerlIO_stdoutf
-PerlIO_sv_dup
-PerlIO_teardown
-PerlIO_tmpfile
-PerlIO_ungetc
-PerlIO_vprintf
-PerlIO_vsprintf
-Perl_GNo_ptr
-Perl_GYes_ptr
-Perl_Gcheck_ptr
-Perl_Gcsighandlerp_ptr
-Perl_Gcurinterp_ptr
-Perl_Gdo_undump_ptr
-Perl_Gdollarzero_mutex_ptr
-Perl_Gfold_locale_ptr
-Perl_Ghexdigit_ptr
-Perl_Ghints_mutex_ptr
-Perl_Ginterp_size_5_10_0_ptr
-Perl_Ginterp_size_ptr
-Perl_Gkeyword_plugin_ptr
-Perl_Gmy_ctx_mutex_ptr
-Perl_Gmy_cxt_index_ptr
-Perl_Gop_mutex_ptr
-Perl_Gop_seq_ptr
-Perl_Gop_sequence_ptr
-Perl_Gpatleave_ptr
-Perl_Gperlio_debug_fd_ptr
-Perl_Gperlio_fd_refcnt_ptr
-Perl_Gperlio_fd_refcnt_size_ptr
-Perl_Gperlio_mutex_ptr
-Perl_Gppaddr_ptr
-Perl_Grevision_ptr
-Perl_Grunops_dbg_ptr
-Perl_Grunops_std_ptr
-Perl_Gsh_path_ptr
-Perl_Gsig_trapped_ptr
-Perl_Gsigfpe_saved_ptr
-Perl_Gsubversion_ptr
-Perl_Gsv_placeholder_ptr
-Perl_Gthr_key_ptr
-Perl_Guse_safe_putenv_ptr
-Perl_Gv_AMupdate
-Perl_Gversion_ptr
-Perl_Gveto_cleanup_ptr
-Perl_IArgv_ptr
-Perl_ICmd_ptr
-Perl_IDBgv_ptr
-Perl_IDBline_ptr
-Perl_IDBsignal_ptr
-Perl_IDBsingle_ptr
-Perl_IDBsub_ptr
-Perl_IDBtrace_ptr
-Perl_IDir_ptr
-Perl_IEnv_ptr
-Perl_ILIO_ptr
-Perl_IMemParse_ptr
-Perl_IMemShared_ptr
-Perl_IMem_ptr
-Perl_IOpPtr_ptr
-Perl_IOpSlab_ptr
-Perl_IOpSpace_ptr
-Perl_IProc_ptr
-Perl_ISock_ptr
-Perl_IStdIO_ptr
-Perl_ISv_ptr
-Perl_IXpv_ptr
-Perl_Iamagic_generation_ptr
-Perl_Ian_ptr
-Perl_Iargvgv_ptr
-Perl_Iargvout_stack_ptr
-Perl_Iargvoutgv_ptr
-Perl_Ibasetime_ptr
-Perl_Ibeginav_ptr
-Perl_Ibeginav_save_ptr
-Perl_Ibody_arenas_ptr
-Perl_Ibody_roots_ptr
-Perl_Ibodytarget_ptr
-Perl_Ibreakable_sub_gen_ptr
-Perl_Icheckav_ptr
-Perl_Icheckav_save_ptr
-Perl_Ichopset_ptr
-Perl_Iclocktick_ptr
-Perl_Icollation_ix_ptr
-Perl_Icollation_name_ptr
-Perl_Icollation_standard_ptr
-Perl_Icollxfrm_base_ptr
-Perl_Icollxfrm_mult_ptr
-Perl_Icolors_ptr
-Perl_Icolorset_ptr
-Perl_Icompcv_ptr
-Perl_Icompiling_ptr
-Perl_Icomppad_name_fill_ptr
-Perl_Icomppad_name_floor_ptr
-Perl_Icomppad_name_ptr
-Perl_Icomppad_ptr
-Perl_Icop_seqmax_ptr
-Perl_Icurcop_ptr
-Perl_Icurcopdb_ptr
-Perl_Icurpad_ptr
-Perl_Icurpm_ptr
-Perl_Icurstack_ptr
-Perl_Icurstackinfo_ptr
-Perl_Icurstash_ptr
-Perl_Icurstname_ptr
-Perl_Icustom_op_descs_ptr
-Perl_Icustom_op_names_ptr
-Perl_Icv_has_eval_ptr
-Perl_Idbargs_ptr
-Perl_Idebstash_ptr
-Perl_Idebug_pad_ptr
-Perl_Idebug_ptr
-Perl_Idef_layerlist_ptr
-Perl_Idefgv_ptr
-Perl_Idefoutgv_ptr
-Perl_Idefstash_ptr
-Perl_Idelaymagic_ptr
-Perl_Idestroyhook_ptr
-Perl_Idiehook_ptr
-Perl_Idirty_ptr
-Perl_Idoextract_ptr
-Perl_Idoswitches_ptr
-Perl_Idowarn_ptr
-Perl_Idumpindent_ptr
-Perl_Ie_script_ptr
-Perl_Iefloatbuf_ptr
-Perl_Iefloatsize_ptr
-Perl_Iegid_ptr
-Perl_Iencoding_ptr
-Perl_Iendav_ptr
-Perl_Ienvgv_ptr
-Perl_Ierrgv_ptr
-Perl_Ierrors_ptr
-Perl_Ieuid_ptr
-Perl_Ieval_root_ptr
-Perl_Ieval_start_ptr
-Perl_Ievalseq_ptr
-Perl_Iexit_flags_ptr
-Perl_Iexitlist_ptr
-Perl_Iexitlistlen_ptr
-Perl_Ifdpid_ptr
-Perl_Ifilemode_ptr
-Perl_Ifirstgv_ptr
-Perl_Iforkprocess_ptr
-Perl_Iformfeed_ptr
-Perl_Iformtarget_ptr
-Perl_Igensym_ptr
-Perl_Igid_ptr
-Perl_Iglob_index_ptr
-Perl_Iglobalstash_ptr
-Perl_Ihash_seed_ptr
-Perl_Ihintgv_ptr
-Perl_Ihints_ptr
-Perl_Ihv_fetch_ent_mh_ptr
-Perl_Iin_clean_all_ptr
-Perl_Iin_clean_objs_ptr
-Perl_Iin_eval_ptr
-Perl_Iin_load_module_ptr
-Perl_Iincgv_ptr
-Perl_Iinitav_ptr
-Perl_Iinplace_ptr
-Perl_Iisarev_ptr
-Perl_Iknown_layers_ptr
-Perl_Ilast_in_gv_ptr
-Perl_Ilast_swash_hv_ptr
-Perl_Ilast_swash_key_ptr
-Perl_Ilast_swash_klen_ptr
-Perl_Ilast_swash_slen_ptr
-Perl_Ilast_swash_tmps_ptr
-Perl_Ilastfd_ptr
-Perl_Ilastscream_ptr
-Perl_Ilaststatval_ptr
-Perl_Ilaststype_ptr
-Perl_Ilocalizing_ptr
-Perl_Ilocalpatches_ptr
-Perl_Ilockhook_ptr
-Perl_Imain_cv_ptr
-Perl_Imain_root_ptr
-Perl_Imain_start_ptr
-Perl_Imainstack_ptr
-Perl_Imarkstack_max_ptr
-Perl_Imarkstack_ptr
-Perl_Imarkstack_ptr_ptr
-Perl_Imax_intro_pending_ptr
-Perl_Imaxo_ptr
-Perl_Imaxscream_ptr
-Perl_Imaxsysfd_ptr
-Perl_Imess_sv_ptr
-Perl_Imin_intro_pending_ptr
-Perl_Iminus_E_ptr
-Perl_Iminus_F_ptr
-Perl_Iminus_a_ptr
-Perl_Iminus_c_ptr
-Perl_Iminus_l_ptr
-Perl_Iminus_n_ptr
-Perl_Iminus_p_ptr
-Perl_Imodglobal_ptr
-Perl_Imy_cxt_list_ptr
-Perl_Imy_cxt_size_ptr
-Perl_Ina_ptr
-Perl_Inice_chunk_ptr
-Perl_Inice_chunk_size_ptr
-Perl_Inomemok_ptr
-Perl_Inumeric_local_ptr
-Perl_Inumeric_name_ptr
-Perl_Inumeric_radix_sv_ptr
-Perl_Inumeric_standard_ptr
-Perl_Iofsgv_ptr
-Perl_Ioldname_ptr
-Perl_Iop_mask_ptr
-Perl_Iop_ptr
-Perl_Iopfreehook_ptr
-Perl_Iorigalen_ptr
-Perl_Iorigargc_ptr
-Perl_Iorigargv_ptr
-Perl_Iorigenviron_ptr
-Perl_Iorigfilename_ptr
-Perl_Iors_sv_ptr
-Perl_Iosname_ptr
-Perl_Ipad_reset_pending_ptr
-Perl_Ipadix_floor_ptr
-Perl_Ipadix_ptr
-Perl_Iparser_ptr
-Perl_Ipatchlevel_ptr
-Perl_Ipeepp_ptr
-Perl_Iperl_destruct_level_ptr
-Perl_Iperldb_ptr
-Perl_Iperlio_ptr
-Perl_Ipreambleav_ptr
-Perl_Iprofiledata_ptr
-Perl_Ipsig_name_ptr
-Perl_Ipsig_pend_ptr
-Perl_Ipsig_ptr_ptr
-Perl_Iptr_table_ptr
-Perl_Ireentrant_retint_ptr
-Perl_Ireg_state_ptr
-Perl_Iregdummy_ptr
-Perl_Iregex_pad_ptr
-Perl_Iregex_padav_ptr
-Perl_Ireginterp_cnt_ptr
-Perl_Iregistered_mros_ptr
-Perl_Iregmatch_slab_ptr
-Perl_Iregmatch_state_ptr
-Perl_Irehash_seed_ptr
-Perl_Irehash_seed_set_ptr
-Perl_Ireplgv_ptr
-Perl_Irestartop_ptr
-Perl_Irs_ptr
-Perl_Irunops_ptr
-Perl_Isavebegin_ptr
-Perl_Isavestack_ix_ptr
-Perl_Isavestack_max_ptr
-Perl_Isavestack_ptr
-Perl_Isawampersand_ptr
-Perl_Iscopestack_ix_ptr
-Perl_Iscopestack_max_ptr
-Perl_Iscopestack_name_ptr
-Perl_Iscopestack_ptr
-Perl_Iscreamfirst_ptr
-Perl_Iscreamnext_ptr
-Perl_Isecondgv_ptr
-Perl_Isharehook_ptr
-Perl_Isig_pending_ptr
-Perl_Isighandlerp_ptr
-Perl_Isignals_ptr
-Perl_Isort_RealCmp_ptr
-Perl_Isortcop_ptr
-Perl_Isortstash_ptr
-Perl_Isplitstr_ptr
-Perl_Isrand_called_ptr
-Perl_Istack_base_ptr
-Perl_Istack_max_ptr
-Perl_Istack_sp_ptr
-Perl_Istart_env_ptr
-Perl_Istashcache_ptr
-Perl_Istatbuf_ptr
-Perl_Istatcache_ptr
-Perl_Istatgv_ptr
-Perl_Istatname_ptr
-Perl_Istatusvalue_posix_ptr
-Perl_Istatusvalue_ptr
-Perl_Istderrgv_ptr
-Perl_Istdingv_ptr
-Perl_Istrtab_ptr
-Perl_Isub_generation_ptr
-Perl_Isubline_ptr
-Perl_Isubname_ptr
-Perl_Isv_arenaroot_ptr
-Perl_Isv_count_ptr
-Perl_Isv_no_ptr
-Perl_Isv_objcount_ptr
-Perl_Isv_root_ptr
-Perl_Isv_undef_ptr
-Perl_Isv_yes_ptr
-Perl_Isys_intern_ptr
-Perl_Itaint_warn_ptr
-Perl_Itainted_ptr
-Perl_Itainting_ptr
-Perl_Ithreadhook_ptr
-Perl_Itmps_floor_ptr
-Perl_Itmps_ix_ptr
-Perl_Itmps_max_ptr
-Perl_Itmps_stack_ptr
-Perl_Itop_env_ptr
-Perl_Itoptarget_ptr
-Perl_Iuid_ptr
-Perl_Iunicode_ptr
-Perl_Iunitcheckav_ptr
-Perl_Iunitcheckav_save_ptr
-Perl_Iunlockhook_ptr
-Perl_Iunsafe_ptr
-Perl_Iutf8_X_LVT_ptr
-Perl_Iutf8_X_LV_LVT_V_ptr
-Perl_Iutf8_X_LV_ptr
-Perl_Iutf8_X_L_ptr
-Perl_Iutf8_X_T_ptr
-Perl_Iutf8_X_V_ptr
-Perl_Iutf8_X_begin_ptr
-Perl_Iutf8_X_extend_ptr
-Perl_Iutf8_X_non_hangul_ptr
-Perl_Iutf8_X_prepend_ptr
-Perl_Iutf8_alnum_ptr
-Perl_Iutf8_alpha_ptr
-Perl_Iutf8_ascii_ptr
-Perl_Iutf8_cntrl_ptr
-Perl_Iutf8_digit_ptr
-Perl_Iutf8_graph_ptr
-Perl_Iutf8_idcont_ptr
-Perl_Iutf8_idstart_ptr
-Perl_Iutf8_lower_ptr
-Perl_Iutf8_mark_ptr
-Perl_Iutf8_perl_space_ptr
-Perl_Iutf8_perl_word_ptr
-Perl_Iutf8_posix_digit_ptr
-Perl_Iutf8_print_ptr
-Perl_Iutf8_punct_ptr
-Perl_Iutf8_space_ptr
-Perl_Iutf8_tofold_ptr
-Perl_Iutf8_tolower_ptr
-Perl_Iutf8_totitle_ptr
-Perl_Iutf8_toupper_ptr
-Perl_Iutf8_upper_ptr
-Perl_Iutf8_xdigit_ptr
-Perl_Iutf8cache_ptr
-Perl_Iutf8locale_ptr
-Perl_Iwarnhook_ptr
-Perl_PerlIO_clearerr
-Perl_PerlIO_close
-Perl_PerlIO_context_layers
-Perl_PerlIO_eof
-Perl_PerlIO_error
-Perl_PerlIO_fileno
-Perl_PerlIO_fill
-Perl_PerlIO_flush
-Perl_PerlIO_get_base
-Perl_PerlIO_get_bufsiz
-Perl_PerlIO_get_cnt
-Perl_PerlIO_get_ptr
-Perl_PerlIO_read
-Perl_PerlIO_seek
-Perl_PerlIO_set_cnt
-Perl_PerlIO_set_ptrcnt
-Perl_PerlIO_setlinebuf
-Perl_PerlIO_stderr
-Perl_PerlIO_stdin
-Perl_PerlIO_stdout
-Perl_PerlIO_tell
-Perl_PerlIO_unread
-Perl_PerlIO_write
-Perl_Slab_Alloc
-Perl_Slab_Free
-Perl_amagic_call
-Perl_any_dup
-Perl_apply_attrs_string
-Perl_atfork_lock
-Perl_atfork_unlock
-Perl_av_arylen_p
-Perl_av_clear
-Perl_av_delete
-Perl_av_exists
-Perl_av_extend
-Perl_av_fetch
-Perl_av_fill
-Perl_av_iter_p
-Perl_av_len
-Perl_av_make
-Perl_av_pop
-Perl_av_push
-Perl_av_reify
-Perl_av_shift
-Perl_av_store
-Perl_av_undef
-Perl_av_unshift
-Perl_block_gimme
-Perl_bytes_from_utf8
-Perl_bytes_to_utf8
-Perl_call_argv
-Perl_call_atexit
-Perl_call_list
-Perl_call_method
-Perl_call_pv
-Perl_call_sv
-Perl_calloc
-Perl_cast_i32
-Perl_cast_iv
-Perl_cast_ulong
-Perl_cast_uv
-Perl_ck_warner
-Perl_ck_warner_d
-Perl_ckwarn
-Perl_ckwarn_d
-Perl_croak
-Perl_croak_nocontext
-Perl_croak_xs_usage
-Perl_csighandler
-Perl_custom_op_desc
-Perl_custom_op_name
-Perl_cv_const_sv
-Perl_cv_undef
-Perl_cx_dump
-Perl_cx_dup
-Perl_cxinc
-Perl_deb
-Perl_deb_nocontext
-Perl_delimcpy
-Perl_despatch_signals
-Perl_die
-Perl_die_nocontext
-Perl_dirp_dup
-Perl_do_aexec
-Perl_do_aspawn
-Perl_do_binmode
-Perl_do_close
-Perl_do_gv_dump
-Perl_do_gvgv_dump
-Perl_do_hv_dump
-Perl_do_join
-Perl_do_magic_dump
-Perl_do_op_dump
-Perl_do_open
-Perl_do_open9
-Perl_do_openn
-Perl_do_pmop_dump
-Perl_do_spawn
-Perl_do_spawn_nowait
-Perl_do_sprintf
-Perl_do_sv_dump
-Perl_doing_taint
-Perl_doref
-Perl_dounwind
-Perl_dowantarray
-Perl_dump_all
-Perl_dump_eval
-Perl_dump_form
-Perl_dump_indent
-Perl_dump_packsubs
-Perl_dump_sub
-Perl_dump_vindent
-Perl_emulate_cop_io
-Perl_eval_pv
-Perl_eval_sv
-Perl_fbm_compile
-Perl_fbm_instr
-Perl_fetch_cop_label
-Perl_filter_add
-Perl_filter_del
-Perl_filter_read
-Perl_find_runcv
-Perl_find_rundefsvoffset
-Perl_form
-Perl_form_nocontext
-Perl_fp_dup
-Perl_fprintf_nocontext
-Perl_free_tmps
-Perl_get_av
-Perl_get_context
-Perl_get_cv
-Perl_get_cvn_flags
-Perl_get_hv
-Perl_get_op_descs
-Perl_get_op_names
-Perl_get_ppaddr
-Perl_get_re_arg
-Perl_get_sv
-Perl_get_vtbl
-Perl_getcwd_sv
-Perl_gp_dup
-Perl_gp_free
-Perl_gp_ref
-Perl_grok_bin
-Perl_grok_hex
-Perl_grok_number
-Perl_grok_numeric_radix
-Perl_grok_oct
-Perl_gv_AVadd
-Perl_gv_HVadd
-Perl_gv_IOadd
-Perl_gv_SVadd
-Perl_gv_add_by_type
-Perl_gv_autoload4
-Perl_gv_check
-Perl_gv_const_sv
-Perl_gv_dump
-Perl_gv_efullname
-Perl_gv_efullname3
-Perl_gv_efullname4
-Perl_gv_fetchfile
-Perl_gv_fetchfile_flags
-Perl_gv_fetchmeth
-Perl_gv_fetchmeth_autoload
-Perl_gv_fetchmethod
-Perl_gv_fetchmethod_autoload
-Perl_gv_fetchmethod_flags
-Perl_gv_fetchpv
-Perl_gv_fetchpvn_flags
-Perl_gv_fetchsv
-Perl_gv_fullname
-Perl_gv_fullname3
-Perl_gv_fullname4
-Perl_gv_handler
-Perl_gv_init
-Perl_gv_name_set
-Perl_gv_stashpv
-Perl_gv_stashpvn
-Perl_gv_stashsv
-Perl_gv_try_downgrade
-Perl_he_dup
-Perl_hek_dup
-Perl_hv_clear
-Perl_hv_clear_placeholders
-Perl_hv_common
-Perl_hv_common_key_len
-Perl_hv_delayfree_ent
-Perl_hv_delete
-Perl_hv_delete_ent
-Perl_hv_eiter_p
-Perl_hv_eiter_set
-Perl_hv_exists
-Perl_hv_exists_ent
-Perl_hv_fetch
-Perl_hv_fetch_ent
-Perl_hv_free_ent
-Perl_hv_iterinit
-Perl_hv_iterkey
-Perl_hv_iterkeysv
-Perl_hv_iternext
-Perl_hv_iternext_flags
-Perl_hv_iternextsv
-Perl_hv_iterval
-Perl_hv_ksplit
-Perl_hv_magic
-Perl_hv_name_set
-Perl_hv_placeholders_get
-Perl_hv_placeholders_p
-Perl_hv_placeholders_set
-Perl_hv_riter_p
-Perl_hv_riter_set
-Perl_hv_scalar
-Perl_hv_store
-Perl_hv_store_ent
-Perl_hv_store_flags
-Perl_hv_undef
-Perl_ibcmp
-Perl_ibcmp_locale
-Perl_ibcmp_utf8
-Perl_init_i18nl10n
-Perl_init_i18nl14n
-Perl_init_os_extras
-Perl_init_stacks
-Perl_init_tm
-Perl_instr
-Perl_is_ascii_string
-Perl_is_lvalue_sub
-Perl_is_uni_alnum
-Perl_is_uni_alnum_lc
-Perl_is_uni_alpha
-Perl_is_uni_alpha_lc
-Perl_is_uni_ascii
-Perl_is_uni_ascii_lc
-Perl_is_uni_cntrl
-Perl_is_uni_cntrl_lc
-Perl_is_uni_digit
-Perl_is_uni_digit_lc
-Perl_is_uni_graph
-Perl_is_uni_graph_lc
-Perl_is_uni_idfirst
-Perl_is_uni_idfirst_lc
-Perl_is_uni_lower
-Perl_is_uni_lower_lc
-Perl_is_uni_print
-Perl_is_uni_print_lc
-Perl_is_uni_punct
-Perl_is_uni_punct_lc
-Perl_is_uni_space
-Perl_is_uni_space_lc
-Perl_is_uni_upper
-Perl_is_uni_upper_lc
-Perl_is_uni_xdigit
-Perl_is_uni_xdigit_lc
-Perl_is_utf8_X_L
-Perl_is_utf8_X_LV
-Perl_is_utf8_X_LVT
-Perl_is_utf8_X_LV_LVT_V
-Perl_is_utf8_X_T
-Perl_is_utf8_X_V
-Perl_is_utf8_X_begin
-Perl_is_utf8_X_extend
-Perl_is_utf8_X_non_hangul
-Perl_is_utf8_X_prepend
-Perl_is_utf8_alnum
-Perl_is_utf8_alpha
-Perl_is_utf8_ascii
-Perl_is_utf8_char
-Perl_is_utf8_cntrl
-Perl_is_utf8_digit
-Perl_is_utf8_graph
-Perl_is_utf8_idcont
-Perl_is_utf8_idfirst
-Perl_is_utf8_lower
-Perl_is_utf8_mark
-Perl_is_utf8_perl_space
-Perl_is_utf8_perl_word
-Perl_is_utf8_posix_digit
-Perl_is_utf8_print
-Perl_is_utf8_punct
-Perl_is_utf8_space
-Perl_is_utf8_string
-Perl_is_utf8_string_loc
-Perl_is_utf8_string_loclen
-Perl_is_utf8_upper
-Perl_is_utf8_xdigit
-Perl_leave_scope
-Perl_lex_bufutf8
-Perl_lex_discard_to
-Perl_lex_end
-Perl_lex_grow_linestr
-Perl_lex_next_chunk
-Perl_lex_peek_unichar
-Perl_lex_read_space
-Perl_lex_read_to
-Perl_lex_read_unichar
-Perl_lex_stuff_pvn
-Perl_lex_stuff_sv
-Perl_lex_unstuff
-Perl_load_module
-Perl_load_module_nocontext
-Perl_looks_like_number
-Perl_magic_dump
-Perl_malloc
-Perl_markstack_grow
-Perl_mess
-Perl_mess_nocontext
-Perl_mfree
-Perl_mg_clear
-Perl_mg_copy
-Perl_mg_dup
-Perl_mg_find
-Perl_mg_free
-Perl_mg_get
-Perl_mg_length
-Perl_mg_magical
-Perl_mg_set
-Perl_mg_size
-Perl_mini_mktime
-Perl_mod
-Perl_moreswitches
-Perl_mro_get_from_name
-Perl_mro_get_linear_isa
-Perl_mro_get_private_data
-Perl_mro_meta_init
-Perl_mro_method_changed_in
-Perl_mro_register
-Perl_mro_set_mro
-Perl_mro_set_private_data
-Perl_my_atof
-Perl_my_atof2
-Perl_my_cxt_init
-Perl_my_dirfd
-Perl_my_exit
-Perl_my_failure_exit
-Perl_my_fflush_all
-Perl_my_fork
-Perl_my_lstat
-Perl_my_popen_list
-Perl_my_setenv
-Perl_my_snprintf
-Perl_my_socketpair
-Perl_my_stat
-Perl_my_strftime
-Perl_my_strlcat
-Perl_my_strlcpy
-Perl_my_vsnprintf
-Perl_newANONATTRSUB
-Perl_newANONHASH
-Perl_newANONLIST
-Perl_newANONSUB
-Perl_newASSIGNOP
-Perl_newATTRSUB
-Perl_newAV
-Perl_newAVREF
-Perl_newBINOP
-Perl_newCONDOP
-Perl_newCONSTSUB
-Perl_newCVREF
-Perl_newFORM
-Perl_newFOROP
-Perl_newGIVENOP
-Perl_newGVOP
-Perl_newGVREF
-Perl_newGVgen
-Perl_newHV
-Perl_newHVREF
-Perl_newHVhv
-Perl_newIO
-Perl_newLISTOP
-Perl_newLOGOP
-Perl_newLOOPEX
-Perl_newLOOPOP
-Perl_newMYSUB
-Perl_newNULLLIST
-Perl_newOP
-Perl_newPADOP
-Perl_newPMOP
-Perl_newPROG
-Perl_newPVOP
-Perl_newRANGE
-Perl_newRV
-Perl_newRV_noinc
-Perl_newSLICEOP
-Perl_newSTATEOP
-Perl_newSUB
-Perl_newSV
-Perl_newSVOP
-Perl_newSVREF
-Perl_newSV_type
-Perl_newSVhek
-Perl_newSViv
-Perl_newSVnv
-Perl_newSVpv
-Perl_newSVpvf
-Perl_newSVpvf_nocontext
-Perl_newSVpvn
-Perl_newSVpvn_flags
-Perl_newSVpvn_share
-Perl_newSVrv
-Perl_newSVsv
-Perl_newSVuv
-Perl_newUNOP
-Perl_newWHENOP
-Perl_newWHILEOP
-Perl_newXS
-Perl_newXS_flags
-Perl_new_collate
-Perl_new_ctype
-Perl_new_numeric
-Perl_new_stackinfo
-Perl_new_version
-Perl_new_warnings_bitfield
-Perl_ninstr
-Perl_nothreadhook
-Perl_op_clear
-Perl_op_dump
-Perl_op_free
-Perl_op_null
-Perl_op_refcnt_lock
-Perl_op_refcnt_unlock
-Perl_pack_cat
-Perl_packlist
-Perl_pad_findmy
-Perl_pad_push
-Perl_parser_dup
-Perl_pmflag
-Perl_pmop_dump
-Perl_pop_scope
-Perl_pregcomp
-Perl_pregexec
-Perl_pregfree
-Perl_pregfree2
-Perl_prescan_version
-Perl_printf_nocontext
-Perl_ptr_table_clear
-Perl_ptr_table_fetch
-Perl_ptr_table_free
-Perl_ptr_table_new
-Perl_ptr_table_split
-Perl_ptr_table_store
-Perl_push_scope
-Perl_pv_display
-Perl_pv_escape
-Perl_pv_pretty
-Perl_pv_uni_display
-Perl_qerror
-Perl_re_compile
-Perl_re_dup_guts
-Perl_re_intuit_start
-Perl_re_intuit_string
-Perl_realloc
-Perl_reentrant_free
-Perl_reentrant_init
-Perl_reentrant_retry
-Perl_reentrant_size
-Perl_ref
-Perl_refcounted_he_chain_2hv
-Perl_refcounted_he_fetch
-Perl_refcounted_he_new
-Perl_reg_named_buff
-Perl_reg_named_buff_all
-Perl_reg_named_buff_exists
-Perl_reg_named_buff_fetch
-Perl_reg_named_buff_firstkey
-Perl_reg_named_buff_iter
-Perl_reg_named_buff_nextkey
-Perl_reg_named_buff_scalar
-Perl_reg_numbered_buff_fetch
-Perl_reg_numbered_buff_length
-Perl_reg_numbered_buff_store
-Perl_reg_qr_package
-Perl_reg_temp_copy
-Perl_regclass_swash
-Perl_regcurly
-Perl_regdump
-Perl_regdupe_internal
-Perl_regexec_flags
-Perl_regfree_internal
-Perl_reginitcolors
-Perl_regnext
-Perl_repeatcpy
-Perl_report_uninit
-Perl_require_pv
-Perl_rninstr
-Perl_rsignal
-Perl_rsignal_state
-Perl_runops_debug
-Perl_runops_standard
-Perl_rvpv_dup
-Perl_safesyscalloc
-Perl_safesysfree
-Perl_safesysmalloc
-Perl_safesysrealloc
-Perl_save_I16
-Perl_save_I32
-Perl_save_I8
-Perl_save_adelete
-Perl_save_aelem_flags
-Perl_save_alloc
-Perl_save_aptr
-Perl_save_ary
-Perl_save_bool
-Perl_save_clearsv
-Perl_save_delete
-Perl_save_destructor
-Perl_save_destructor_x
-Perl_save_freeop
-Perl_save_freepv
-Perl_save_freesv
-Perl_save_generic_pvref
-Perl_save_generic_svref
-Perl_save_gp
-Perl_save_hash
-Perl_save_hdelete
-Perl_save_helem_flags
-Perl_save_hptr
-Perl_save_int
-Perl_save_item
-Perl_save_iv
-Perl_save_list
-Perl_save_long
-Perl_save_mortalizesv
-Perl_save_nogv
-Perl_save_op
-Perl_save_padsv_and_mortalize
-Perl_save_pptr
-Perl_save_pushptr
-Perl_save_re_context
-Perl_save_scalar
-Perl_save_set_svflags
-Perl_save_shared_pvref
-Perl_save_sptr
-Perl_save_svref
-Perl_save_vptr
-Perl_savepv
-Perl_savepvn
-Perl_savesharedpv
-Perl_savesharedpvn
-Perl_savestack_grow
-Perl_savestack_grow_cnt
-Perl_savesvpv
-Perl_scan_bin
-Perl_scan_hex
-Perl_scan_num
-Perl_scan_oct
-Perl_scan_version
-Perl_scan_vstring
-Perl_screaminstr
-Perl_seed
-Perl_set_context
-Perl_set_numeric_local
-Perl_set_numeric_radix
-Perl_set_numeric_standard
-Perl_setdefout
-Perl_share_hek
-Perl_si_dup
-Perl_signbit
-Perl_sortsv
-Perl_sortsv_flags
-Perl_ss_dup
-Perl_stack_grow
-Perl_start_subparse
-Perl_stashpv_hvname_match
-Perl_str_to_version
-Perl_sv_2bool
-Perl_sv_2cv
-Perl_sv_2io
-Perl_sv_2iv
-Perl_sv_2iv_flags
-Perl_sv_2mortal
-Perl_sv_2nv
-Perl_sv_2pv
-Perl_sv_2pv_flags
-Perl_sv_2pv_nolen
-Perl_sv_2pvbyte
-Perl_sv_2pvbyte_nolen
-Perl_sv_2pvutf8
-Perl_sv_2pvutf8_nolen
-Perl_sv_2uv
-Perl_sv_2uv_flags
-Perl_sv_backoff
-Perl_sv_bless
-Perl_sv_cat_decode
-Perl_sv_catpv
-Perl_sv_catpv_mg
-Perl_sv_catpvf
-Perl_sv_catpvf_mg
-Perl_sv_catpvf_mg_nocontext
-Perl_sv_catpvf_nocontext
-Perl_sv_catpvn
-Perl_sv_catpvn_flags
-Perl_sv_catpvn_mg
-Perl_sv_catsv
-Perl_sv_catsv_flags
-Perl_sv_catsv_mg
-Perl_sv_chop
-Perl_sv_clear
-Perl_sv_cmp
-Perl_sv_cmp_locale
-Perl_sv_collxfrm
-Perl_sv_compile_2op
-Perl_sv_copypv
-Perl_sv_dec
-Perl_sv_derived_from
-Perl_sv_destroyable
-Perl_sv_does
-Perl_sv_dump
-Perl_sv_dup
-Perl_sv_eq
-Perl_sv_force_normal
-Perl_sv_force_normal_flags
-Perl_sv_free
-Perl_sv_free2
-Perl_sv_gets
-Perl_sv_grow
-Perl_sv_inc
-Perl_sv_insert
-Perl_sv_insert_flags
-Perl_sv_isa
-Perl_sv_isobject
-Perl_sv_iv
-Perl_sv_len
-Perl_sv_len_utf8
-Perl_sv_magic
-Perl_sv_magicext
-Perl_sv_mortalcopy
-Perl_sv_newmortal
-Perl_sv_newref
-Perl_sv_nolocking
-Perl_sv_nosharing
-Perl_sv_nounlocking
-Perl_sv_nv
-Perl_sv_peek
-Perl_sv_pos_b2u
-Perl_sv_pos_u2b
-Perl_sv_pos_u2b_flags
-Perl_sv_pv
-Perl_sv_pvbyte
-Perl_sv_pvbyten
-Perl_sv_pvbyten_force
-Perl_sv_pvn
-Perl_sv_pvn_force
-Perl_sv_pvn_force_flags
-Perl_sv_pvn_nomg
-Perl_sv_pvutf8
-Perl_sv_pvutf8n
-Perl_sv_pvutf8n_force
-Perl_sv_recode_to_utf8
-Perl_sv_reftype
-Perl_sv_replace
-Perl_sv_report_used
-Perl_sv_reset
-Perl_sv_rvweaken
-Perl_sv_setiv
-Perl_sv_setiv_mg
-Perl_sv_setnv
-Perl_sv_setnv_mg
-Perl_sv_setpv
-Perl_sv_setpv_mg
-Perl_sv_setpvf
-Perl_sv_setpvf_mg
-Perl_sv_setpvf_mg_nocontext
-Perl_sv_setpvf_nocontext
-Perl_sv_setpviv
-Perl_sv_setpviv_mg
-Perl_sv_setpvn
-Perl_sv_setpvn_mg
-Perl_sv_setref_iv
-Perl_sv_setref_nv
-Perl_sv_setref_pv
-Perl_sv_setref_pvn
-Perl_sv_setref_uv
-Perl_sv_setsv
-Perl_sv_setsv_flags
-Perl_sv_setsv_mg
-Perl_sv_setuv
-Perl_sv_setuv_mg
-Perl_sv_taint
-Perl_sv_tainted
-Perl_sv_true
-Perl_sv_uni_display
-Perl_sv_unmagic
-Perl_sv_unref
-Perl_sv_unref_flags
-Perl_sv_untaint
-Perl_sv_upgrade
-Perl_sv_usepvn
-Perl_sv_usepvn_flags
-Perl_sv_usepvn_mg
-Perl_sv_utf8_decode
-Perl_sv_utf8_downgrade
-Perl_sv_utf8_encode
-Perl_sv_utf8_upgrade
-Perl_sv_utf8_upgrade_flags_grow
-Perl_sv_uv
-Perl_sv_vcatpvf
-Perl_sv_vcatpvf_mg
-Perl_sv_vcatpvfn
-Perl_sv_vsetpvf
-Perl_sv_vsetpvf_mg
-Perl_sv_vsetpvfn
-Perl_swash_fetch
-Perl_swash_init
-Perl_sys_init
-Perl_sys_init3
-Perl_sys_intern_clear
-Perl_sys_intern_dup
-Perl_sys_intern_init
-Perl_sys_term
-Perl_taint_env
-Perl_taint_proper
-Perl_tmps_grow
-Perl_to_uni_fold
-Perl_to_uni_lower
-Perl_to_uni_lower_lc
-Perl_to_uni_title
-Perl_to_uni_title_lc
-Perl_to_uni_upper
-Perl_to_uni_upper_lc
-Perl_to_utf8_case
-Perl_to_utf8_fold
-Perl_to_utf8_lower
-Perl_to_utf8_title
-Perl_to_utf8_upper
-Perl_unpack_str
-Perl_unpackstring
-Perl_unsharepvn
-Perl_upg_version
-Perl_utf16_to_utf8
-Perl_utf16_to_utf8_reversed
-Perl_utf8_distance
-Perl_utf8_hop
-Perl_utf8_length
-Perl_utf8_to_bytes
-Perl_utf8_to_uvchr
-Perl_utf8_to_uvuni
-Perl_utf8n_to_uvchr
-Perl_utf8n_to_uvuni
-Perl_uvchr_to_utf8
-Perl_uvchr_to_utf8_flags
-Perl_uvuni_to_utf8
-Perl_uvuni_to_utf8_flags
-Perl_vcmp
-Perl_vcroak
-Perl_vdeb
-Perl_vform
-Perl_vivify_defelem
-Perl_vload_module
-Perl_vmess
-Perl_vnewSVpvf
-Perl_vnormal
-Perl_vnumify
-Perl_vstringify
-Perl_vverify
-Perl_vwarn
-Perl_vwarner
-Perl_warn
-Perl_warn_nocontext
-Perl_warner
-Perl_warner_nocontext
-Perl_whichsig
-Perl_win32_init
-Perl_win32_term
-Perl_yylex
-RunPerl
-boot_DynaLoader
-boot_Win32CORE
-init_Win32CORE
-perl_alloc
-perl_alloc_override
-perl_alloc_using
-perl_clone
-perl_clone_host
-perl_clone_using
-perl_construct
-perl_destruct
-perl_free
-perl_get_host_info
-perl_parse
-perl_run
-perlsio_binmode
-setgid
-setuid
-win32_abort
-win32_accept
-win32_access
-win32_alarm
-win32_ansipath
-win32_async_check
-win32_bind
-win32_calloc
-win32_chdir
-win32_chmod
-win32_chsize
-win32_clearenv
-win32_clearerr
-win32_close
-win32_closedir
-win32_closesocket
-win32_connect
-win32_crypt
-win32_dup
-win32_dup2
-win32_dynaload
-win32_endhostent
-win32_endnetent
-win32_endprotoent
-win32_endservent
-win32_environ
-win32_eof
-win32_errno
-win32_execv
-win32_execvp
-win32_fclose
-win32_fcloseall
-win32_fdopen
-win32_feof
-win32_ferror
-win32_fflush
-win32_fgetc
-win32_fgetpos
-win32_fgets
-win32_fileno
-win32_flock
-win32_flushall
-win32_fopen
-win32_fprintf
-win32_fputc
-win32_fputs
-win32_fread
-win32_free
-win32_free_childdir
-win32_free_childenv
-win32_freopen
-win32_fseek
-win32_fsetpos
-win32_fstat
-win32_ftell
-win32_fwrite
-win32_get_childdir
-win32_get_childenv
-win32_get_osfhandle
-win32_getc
-win32_getchar
-win32_getenv
-win32_gethostbyaddr
-win32_gethostbyname
-win32_gethostname
-win32_getnetbyaddr
-win32_getnetbyname
-win32_getnetent
-win32_getpeername
-win32_getpid
-win32_getprotobyname
-win32_getprotobynumber
-win32_getprotoent
-win32_gets
-win32_getservbyname
-win32_getservbyport
-win32_getservent
-win32_getsockname
-win32_getsockopt
-win32_gettimeofday
-win32_htonl
-win32_htons
-win32_inet_addr
-win32_inet_ntoa
-win32_ioctl
-win32_ioctlsocket
-win32_isatty
-win32_kill
-win32_link
-win32_listen
-win32_longpath
-win32_lseek
-win32_malloc
-win32_mkdir
-win32_ntohl
-win32_ntohs
-win32_open
-win32_open_osfhandle
-win32_opendir
-win32_os_id
-win32_pclose
-win32_perror
-win32_pipe
-win32_popen
-win32_printf
-win32_putc
-win32_putchar
-win32_putenv
-win32_puts
-win32_read
-win32_readdir
-win32_realloc
-win32_recv
-win32_recvfrom
-win32_rename
-win32_rewind
-win32_rewinddir
-win32_rmdir
-win32_seekdir
-win32_select
-win32_send
-win32_sendto
-win32_setbuf
-win32_sethostent
-win32_setmode
-win32_setnetent
-win32_setprotoent
-win32_setservent
-win32_setsockopt
-win32_setvbuf
-win32_shutdown
-win32_sleep
-win32_socket
-win32_spawnvp
-win32_stat
-win32_stderr
-win32_stdin
-win32_stdout
-win32_str_os_error
-win32_strerror
-win32_tell
-win32_telldir
-win32_times
-win32_tmpfile
-win32_uname
-win32_ungetc
-win32_unlink
-win32_utime
-win32_vfprintf
-win32_vprintf
-win32_wait
-win32_waitpid
-win32_write
diff --git a/plugins/perl/importlib/perl512-x86.def b/plugins/perl/importlib/perl512-x86.def
deleted file mode 100644
index 5cfcaa68..00000000
--- a/plugins/perl/importlib/perl512-x86.def
+++ /dev/null
@@ -1,1420 +0,0 @@
-LIBRARY perl512
-EXPORTS
-PL_bincompat_options
-PL_check
-PL_fold
-PL_fold_locale
-PL_freq
-PL_keyword_plugin
-PL_memory_wrap
-PL_no_aelem
-PL_no_dir_func
-PL_no_func
-PL_no_helem_sv
-PL_no_localize_ref
-PL_no_mem
-PL_no_modify
-PL_no_myglob
-PL_no_security
-PL_no_sock_func
-PL_no_symref
-PL_no_usym
-PL_no_wrongref
-PL_op_desc
-PL_op_name
-PL_opargs
-PL_perlio_mutex
-PL_ppaddr
-PL_reg_extflags_name
-PL_reg_name
-PL_regkind
-PL_sig_name
-PL_sig_num
-PL_simple
-PL_utf8skip
-PL_uuemap
-PL_varies
-PL_vtbl_amagic
-PL_vtbl_amagicelem
-PL_vtbl_arylen
-PL_vtbl_backref
-PL_vtbl_bm
-PL_vtbl_collxfrm
-PL_vtbl_dbline
-PL_vtbl_defelem
-PL_vtbl_env
-PL_vtbl_envelem
-PL_vtbl_fm
-PL_vtbl_isa
-PL_vtbl_isaelem
-PL_vtbl_mglob
-PL_vtbl_nkeys
-PL_vtbl_pack
-PL_vtbl_packelem
-PL_vtbl_pos
-PL_vtbl_regdata
-PL_vtbl_regdatum
-PL_vtbl_regexp
-PL_vtbl_sig
-PL_vtbl_sigelem
-PL_vtbl_substr
-PL_vtbl_sv
-PL_vtbl_taint
-PL_vtbl_utf8
-PL_vtbl_uvar
-PL_vtbl_vec
-PL_warn_nl
-PL_warn_nosemi
-PL_warn_reserved
-PL_warn_uninit
-PerlIOBase_binmode
-PerlIOBase_clearerr
-PerlIOBase_close
-PerlIOBase_dup
-PerlIOBase_eof
-PerlIOBase_error
-PerlIOBase_fileno
-PerlIOBase_noop_fail
-PerlIOBase_noop_ok
-PerlIOBase_popped
-PerlIOBase_pushed
-PerlIOBase_read
-PerlIOBase_setlinebuf
-PerlIOBase_unread
-PerlIOBuf_bufsiz
-PerlIOBuf_close
-PerlIOBuf_dup
-PerlIOBuf_fill
-PerlIOBuf_flush
-PerlIOBuf_get_base
-PerlIOBuf_get_cnt
-PerlIOBuf_get_ptr
-PerlIOBuf_open
-PerlIOBuf_popped
-PerlIOBuf_pushed
-PerlIOBuf_read
-PerlIOBuf_seek
-PerlIOBuf_set_ptrcnt
-PerlIOBuf_tell
-PerlIOBuf_unread
-PerlIOBuf_write
-PerlIO_allocate
-PerlIO_apply_layera
-PerlIO_apply_layers
-PerlIO_arg_fetch
-PerlIO_binmode
-PerlIO_canset_cnt
-PerlIO_debug
-PerlIO_define_layer
-PerlIO_exportFILE
-PerlIO_fast_gets
-PerlIO_fdopen
-PerlIO_findFILE
-PerlIO_find_layer
-PerlIO_getc
-PerlIO_getname
-PerlIO_getpos
-PerlIO_has_base
-PerlIO_has_cntptr
-PerlIO_importFILE
-PerlIO_init
-PerlIO_isutf8
-PerlIO_layer_fetch
-PerlIO_list_alloc
-PerlIO_list_free
-PerlIO_modestr
-PerlIO_open
-PerlIO_parse_layers
-PerlIO_pending
-PerlIO_perlio
-PerlIO_pop
-PerlIO_printf
-PerlIO_push
-PerlIO_putc
-PerlIO_puts
-PerlIO_releaseFILE
-PerlIO_reopen
-PerlIO_rewind
-PerlIO_setpos
-PerlIO_sprintf
-PerlIO_stdoutf
-PerlIO_sv_dup
-PerlIO_teardown
-PerlIO_tmpfile
-PerlIO_ungetc
-PerlIO_vprintf
-PerlIO_vsprintf
-Perl_GNo_ptr
-Perl_GYes_ptr
-Perl_Gcheck_ptr
-Perl_Gcsighandlerp_ptr
-Perl_Gcurinterp_ptr
-Perl_Gdo_undump_ptr
-Perl_Gdollarzero_mutex_ptr
-Perl_Gfold_locale_ptr
-Perl_Ghexdigit_ptr
-Perl_Ghints_mutex_ptr
-Perl_Ginterp_size_5_10_0_ptr
-Perl_Ginterp_size_ptr
-Perl_Gkeyword_plugin_ptr
-Perl_Gmy_ctx_mutex_ptr
-Perl_Gmy_cxt_index_ptr
-Perl_Gop_mutex_ptr
-Perl_Gop_seq_ptr
-Perl_Gop_sequence_ptr
-Perl_Gpatleave_ptr
-Perl_Gperlio_debug_fd_ptr
-Perl_Gperlio_fd_refcnt_ptr
-Perl_Gperlio_fd_refcnt_size_ptr
-Perl_Gperlio_mutex_ptr
-Perl_Gppaddr_ptr
-Perl_Grevision_ptr
-Perl_Grunops_dbg_ptr
-Perl_Grunops_std_ptr
-Perl_Gsh_path_ptr
-Perl_Gsig_trapped_ptr
-Perl_Gsigfpe_saved_ptr
-Perl_Gsubversion_ptr
-Perl_Gsv_placeholder_ptr
-Perl_Gthr_key_ptr
-Perl_Guse_safe_putenv_ptr
-Perl_Gv_AMupdate
-Perl_Gversion_ptr
-Perl_Gveto_cleanup_ptr
-Perl_IArgv_ptr
-Perl_ICmd_ptr
-Perl_IDBgv_ptr
-Perl_IDBline_ptr
-Perl_IDBsignal_ptr
-Perl_IDBsingle_ptr
-Perl_IDBsub_ptr
-Perl_IDBtrace_ptr
-Perl_IDir_ptr
-Perl_IEnv_ptr
-Perl_ILIO_ptr
-Perl_IMemParse_ptr
-Perl_IMemShared_ptr
-Perl_IMem_ptr
-Perl_IOpPtr_ptr
-Perl_IOpSlab_ptr
-Perl_IOpSpace_ptr
-Perl_IProc_ptr
-Perl_ISock_ptr
-Perl_IStdIO_ptr
-Perl_ISv_ptr
-Perl_IXpv_ptr
-Perl_Iamagic_generation_ptr
-Perl_Ian_ptr
-Perl_Iargvgv_ptr
-Perl_Iargvout_stack_ptr
-Perl_Iargvoutgv_ptr
-Perl_Ibasetime_ptr
-Perl_Ibeginav_ptr
-Perl_Ibeginav_save_ptr
-Perl_Ibody_arenas_ptr
-Perl_Ibody_roots_ptr
-Perl_Ibodytarget_ptr
-Perl_Ibreakable_sub_gen_ptr
-Perl_Icheckav_ptr
-Perl_Icheckav_save_ptr
-Perl_Ichopset_ptr
-Perl_Iclocktick_ptr
-Perl_Icollation_ix_ptr
-Perl_Icollation_name_ptr
-Perl_Icollation_standard_ptr
-Perl_Icollxfrm_base_ptr
-Perl_Icollxfrm_mult_ptr
-Perl_Icolors_ptr
-Perl_Icolorset_ptr
-Perl_Icompcv_ptr
-Perl_Icompiling_ptr
-Perl_Icomppad_name_fill_ptr
-Perl_Icomppad_name_floor_ptr
-Perl_Icomppad_name_ptr
-Perl_Icomppad_ptr
-Perl_Icop_seqmax_ptr
-Perl_Icurcop_ptr
-Perl_Icurcopdb_ptr
-Perl_Icurpad_ptr
-Perl_Icurpm_ptr
-Perl_Icurstack_ptr
-Perl_Icurstackinfo_ptr
-Perl_Icurstash_ptr
-Perl_Icurstname_ptr
-Perl_Icustom_op_descs_ptr
-Perl_Icustom_op_names_ptr
-Perl_Icv_has_eval_ptr
-Perl_Idbargs_ptr
-Perl_Idebstash_ptr
-Perl_Idebug_pad_ptr
-Perl_Idebug_ptr
-Perl_Idef_layerlist_ptr
-Perl_Idefgv_ptr
-Perl_Idefoutgv_ptr
-Perl_Idefstash_ptr
-Perl_Idelaymagic_ptr
-Perl_Idestroyhook_ptr
-Perl_Idiehook_ptr
-Perl_Idirty_ptr
-Perl_Idoextract_ptr
-Perl_Idoswitches_ptr
-Perl_Idowarn_ptr
-Perl_Idumpindent_ptr
-Perl_Ie_script_ptr
-Perl_Iefloatbuf_ptr
-Perl_Iefloatsize_ptr
-Perl_Iegid_ptr
-Perl_Iencoding_ptr
-Perl_Iendav_ptr
-Perl_Ienvgv_ptr
-Perl_Ierrgv_ptr
-Perl_Ierrors_ptr
-Perl_Ieuid_ptr
-Perl_Ieval_root_ptr
-Perl_Ieval_start_ptr
-Perl_Ievalseq_ptr
-Perl_Iexit_flags_ptr
-Perl_Iexitlist_ptr
-Perl_Iexitlistlen_ptr
-Perl_Ifdpid_ptr
-Perl_Ifilemode_ptr
-Perl_Ifirstgv_ptr
-Perl_Iforkprocess_ptr
-Perl_Iformfeed_ptr
-Perl_Iformtarget_ptr
-Perl_Igensym_ptr
-Perl_Igid_ptr
-Perl_Iglob_index_ptr
-Perl_Iglobalstash_ptr
-Perl_Ihash_seed_ptr
-Perl_Ihintgv_ptr
-Perl_Ihints_ptr
-Perl_Ihv_fetch_ent_mh_ptr
-Perl_Iin_clean_all_ptr
-Perl_Iin_clean_objs_ptr
-Perl_Iin_eval_ptr
-Perl_Iin_load_module_ptr
-Perl_Iincgv_ptr
-Perl_Iinitav_ptr
-Perl_Iinplace_ptr
-Perl_Iisarev_ptr
-Perl_Iknown_layers_ptr
-Perl_Ilast_in_gv_ptr
-Perl_Ilast_swash_hv_ptr
-Perl_Ilast_swash_key_ptr
-Perl_Ilast_swash_klen_ptr
-Perl_Ilast_swash_slen_ptr
-Perl_Ilast_swash_tmps_ptr
-Perl_Ilastfd_ptr
-Perl_Ilastscream_ptr
-Perl_Ilaststatval_ptr
-Perl_Ilaststype_ptr
-Perl_Ilocalizing_ptr
-Perl_Ilocalpatches_ptr
-Perl_Ilockhook_ptr
-Perl_Imain_cv_ptr
-Perl_Imain_root_ptr
-Perl_Imain_start_ptr
-Perl_Imainstack_ptr
-Perl_Imarkstack_max_ptr
-Perl_Imarkstack_ptr
-Perl_Imarkstack_ptr_ptr
-Perl_Imax_intro_pending_ptr
-Perl_Imaxo_ptr
-Perl_Imaxscream_ptr
-Perl_Imaxsysfd_ptr
-Perl_Imess_sv_ptr
-Perl_Imin_intro_pending_ptr
-Perl_Iminus_E_ptr
-Perl_Iminus_F_ptr
-Perl_Iminus_a_ptr
-Perl_Iminus_c_ptr
-Perl_Iminus_l_ptr
-Perl_Iminus_n_ptr
-Perl_Iminus_p_ptr
-Perl_Imodglobal_ptr
-Perl_Imy_cxt_list_ptr
-Perl_Imy_cxt_size_ptr
-Perl_Ina_ptr
-Perl_Inice_chunk_ptr
-Perl_Inice_chunk_size_ptr
-Perl_Inomemok_ptr
-Perl_Inumeric_local_ptr
-Perl_Inumeric_name_ptr
-Perl_Inumeric_radix_sv_ptr
-Perl_Inumeric_standard_ptr
-Perl_Iofsgv_ptr
-Perl_Ioldname_ptr
-Perl_Iop_mask_ptr
-Perl_Iop_ptr
-Perl_Iopfreehook_ptr
-Perl_Iorigalen_ptr
-Perl_Iorigargc_ptr
-Perl_Iorigargv_ptr
-Perl_Iorigenviron_ptr
-Perl_Iorigfilename_ptr
-Perl_Iors_sv_ptr
-Perl_Iosname_ptr
-Perl_Ipad_reset_pending_ptr
-Perl_Ipadix_floor_ptr
-Perl_Ipadix_ptr
-Perl_Iparser_ptr
-Perl_Ipatchlevel_ptr
-Perl_Ipeepp_ptr
-Perl_Iperl_destruct_level_ptr
-Perl_Iperldb_ptr
-Perl_Iperlio_ptr
-Perl_Ipreambleav_ptr
-Perl_Iprofiledata_ptr
-Perl_Ipsig_name_ptr
-Perl_Ipsig_pend_ptr
-Perl_Ipsig_ptr_ptr
-Perl_Iptr_table_ptr
-Perl_Ireentrant_retint_ptr
-Perl_Ireg_state_ptr
-Perl_Iregdummy_ptr
-Perl_Iregex_pad_ptr
-Perl_Iregex_padav_ptr
-Perl_Ireginterp_cnt_ptr
-Perl_Iregistered_mros_ptr
-Perl_Iregmatch_slab_ptr
-Perl_Iregmatch_state_ptr
-Perl_Irehash_seed_ptr
-Perl_Irehash_seed_set_ptr
-Perl_Ireplgv_ptr
-Perl_Irestartop_ptr
-Perl_Irs_ptr
-Perl_Irunops_ptr
-Perl_Isavebegin_ptr
-Perl_Isavestack_ix_ptr
-Perl_Isavestack_max_ptr
-Perl_Isavestack_ptr
-Perl_Isawampersand_ptr
-Perl_Iscopestack_ix_ptr
-Perl_Iscopestack_max_ptr
-Perl_Iscopestack_name_ptr
-Perl_Iscopestack_ptr
-Perl_Iscreamfirst_ptr
-Perl_Iscreamnext_ptr
-Perl_Isecondgv_ptr
-Perl_Isharehook_ptr
-Perl_Isig_pending_ptr
-Perl_Isighandlerp_ptr
-Perl_Isignals_ptr
-Perl_Isort_RealCmp_ptr
-Perl_Isortcop_ptr
-Perl_Isortstash_ptr
-Perl_Isplitstr_ptr
-Perl_Isrand_called_ptr
-Perl_Istack_base_ptr
-Perl_Istack_max_ptr
-Perl_Istack_sp_ptr
-Perl_Istart_env_ptr
-Perl_Istashcache_ptr
-Perl_Istatbuf_ptr
-Perl_Istatcache_ptr
-Perl_Istatgv_ptr
-Perl_Istatname_ptr
-Perl_Istatusvalue_posix_ptr
-Perl_Istatusvalue_ptr
-Perl_Istderrgv_ptr
-Perl_Istdingv_ptr
-Perl_Istrtab_ptr
-Perl_Isub_generation_ptr
-Perl_Isubline_ptr
-Perl_Isubname_ptr
-Perl_Isv_arenaroot_ptr
-Perl_Isv_count_ptr
-Perl_Isv_no_ptr
-Perl_Isv_objcount_ptr
-Perl_Isv_root_ptr
-Perl_Isv_undef_ptr
-Perl_Isv_yes_ptr
-Perl_Isys_intern_ptr
-Perl_Itaint_warn_ptr
-Perl_Itainted_ptr
-Perl_Itainting_ptr
-Perl_Ithreadhook_ptr
-Perl_Itmps_floor_ptr
-Perl_Itmps_ix_ptr
-Perl_Itmps_max_ptr
-Perl_Itmps_stack_ptr
-Perl_Itop_env_ptr
-Perl_Itoptarget_ptr
-Perl_Iuid_ptr
-Perl_Iunicode_ptr
-Perl_Iunitcheckav_ptr
-Perl_Iunitcheckav_save_ptr
-Perl_Iunlockhook_ptr
-Perl_Iunsafe_ptr
-Perl_Iutf8_X_LVT_ptr
-Perl_Iutf8_X_LV_LVT_V_ptr
-Perl_Iutf8_X_LV_ptr
-Perl_Iutf8_X_L_ptr
-Perl_Iutf8_X_T_ptr
-Perl_Iutf8_X_V_ptr
-Perl_Iutf8_X_begin_ptr
-Perl_Iutf8_X_extend_ptr
-Perl_Iutf8_X_non_hangul_ptr
-Perl_Iutf8_X_prepend_ptr
-Perl_Iutf8_alnum_ptr
-Perl_Iutf8_alpha_ptr
-Perl_Iutf8_ascii_ptr
-Perl_Iutf8_cntrl_ptr
-Perl_Iutf8_digit_ptr
-Perl_Iutf8_graph_ptr
-Perl_Iutf8_idcont_ptr
-Perl_Iutf8_idstart_ptr
-Perl_Iutf8_lower_ptr
-Perl_Iutf8_mark_ptr
-Perl_Iutf8_perl_space_ptr
-Perl_Iutf8_perl_word_ptr
-Perl_Iutf8_posix_digit_ptr
-Perl_Iutf8_print_ptr
-Perl_Iutf8_punct_ptr
-Perl_Iutf8_space_ptr
-Perl_Iutf8_tofold_ptr
-Perl_Iutf8_tolower_ptr
-Perl_Iutf8_totitle_ptr
-Perl_Iutf8_toupper_ptr
-Perl_Iutf8_upper_ptr
-Perl_Iutf8_xdigit_ptr
-Perl_Iutf8cache_ptr
-Perl_Iutf8locale_ptr
-Perl_Iwarnhook_ptr
-Perl_PerlIO_clearerr
-Perl_PerlIO_close
-Perl_PerlIO_context_layers
-Perl_PerlIO_eof
-Perl_PerlIO_error
-Perl_PerlIO_fileno
-Perl_PerlIO_fill
-Perl_PerlIO_flush
-Perl_PerlIO_get_base
-Perl_PerlIO_get_bufsiz
-Perl_PerlIO_get_cnt
-Perl_PerlIO_get_ptr
-Perl_PerlIO_read
-Perl_PerlIO_seek
-Perl_PerlIO_set_cnt
-Perl_PerlIO_set_ptrcnt
-Perl_PerlIO_setlinebuf
-Perl_PerlIO_stderr
-Perl_PerlIO_stdin
-Perl_PerlIO_stdout
-Perl_PerlIO_tell
-Perl_PerlIO_unread
-Perl_PerlIO_write
-Perl_Slab_Alloc
-Perl_Slab_Free
-Perl_amagic_call
-Perl_any_dup
-Perl_apply_attrs_string
-Perl_atfork_lock
-Perl_atfork_unlock
-Perl_av_arylen_p
-Perl_av_clear
-Perl_av_delete
-Perl_av_exists
-Perl_av_extend
-Perl_av_fetch
-Perl_av_fill
-Perl_av_iter_p
-Perl_av_len
-Perl_av_make
-Perl_av_pop
-Perl_av_push
-Perl_av_reify
-Perl_av_shift
-Perl_av_store
-Perl_av_undef
-Perl_av_unshift
-Perl_block_gimme
-Perl_bytes_from_utf8
-Perl_bytes_to_utf8
-Perl_call_argv
-Perl_call_atexit
-Perl_call_list
-Perl_call_method
-Perl_call_pv
-Perl_call_sv
-Perl_calloc
-Perl_cast_i32
-Perl_cast_iv
-Perl_cast_ulong
-Perl_cast_uv
-Perl_ck_warner
-Perl_ck_warner_d
-Perl_ckwarn
-Perl_ckwarn_d
-Perl_croak
-Perl_croak_nocontext
-Perl_croak_xs_usage
-Perl_csighandler
-Perl_custom_op_desc
-Perl_custom_op_name
-Perl_cv_const_sv
-Perl_cv_undef
-Perl_cx_dump
-Perl_cx_dup
-Perl_cxinc
-Perl_deb
-Perl_deb_nocontext
-Perl_delimcpy
-Perl_despatch_signals
-Perl_die
-Perl_die_nocontext
-Perl_dirp_dup
-Perl_do_aexec
-Perl_do_aspawn
-Perl_do_binmode
-Perl_do_close
-Perl_do_gv_dump
-Perl_do_gvgv_dump
-Perl_do_hv_dump
-Perl_do_join
-Perl_do_magic_dump
-Perl_do_op_dump
-Perl_do_open
-Perl_do_open9
-Perl_do_openn
-Perl_do_pmop_dump
-Perl_do_spawn
-Perl_do_spawn_nowait
-Perl_do_sprintf
-Perl_do_sv_dump
-Perl_doing_taint
-Perl_doref
-Perl_dounwind
-Perl_dowantarray
-Perl_dump_all
-Perl_dump_eval
-Perl_dump_form
-Perl_dump_indent
-Perl_dump_packsubs
-Perl_dump_sub
-Perl_dump_vindent
-Perl_emulate_cop_io
-Perl_eval_pv
-Perl_eval_sv
-Perl_fbm_compile
-Perl_fbm_instr
-Perl_fetch_cop_label
-Perl_filter_add
-Perl_filter_del
-Perl_filter_read
-Perl_find_runcv
-Perl_find_rundefsvoffset
-Perl_form
-Perl_form_nocontext
-Perl_fp_dup
-Perl_fprintf_nocontext
-Perl_free_tmps
-Perl_get_av
-Perl_get_context
-Perl_get_cv
-Perl_get_cvn_flags
-Perl_get_hv
-Perl_get_op_descs
-Perl_get_op_names
-Perl_get_ppaddr
-Perl_get_re_arg
-Perl_get_sv
-Perl_get_vtbl
-Perl_getcwd_sv
-Perl_gp_dup
-Perl_gp_free
-Perl_gp_ref
-Perl_grok_bin
-Perl_grok_hex
-Perl_grok_number
-Perl_grok_numeric_radix
-Perl_grok_oct
-Perl_gv_AVadd
-Perl_gv_HVadd
-Perl_gv_IOadd
-Perl_gv_SVadd
-Perl_gv_add_by_type
-Perl_gv_autoload4
-Perl_gv_check
-Perl_gv_const_sv
-Perl_gv_dump
-Perl_gv_efullname
-Perl_gv_efullname3
-Perl_gv_efullname4
-Perl_gv_fetchfile
-Perl_gv_fetchfile_flags
-Perl_gv_fetchmeth
-Perl_gv_fetchmeth_autoload
-Perl_gv_fetchmethod
-Perl_gv_fetchmethod_autoload
-Perl_gv_fetchmethod_flags
-Perl_gv_fetchpv
-Perl_gv_fetchpvn_flags
-Perl_gv_fetchsv
-Perl_gv_fullname
-Perl_gv_fullname3
-Perl_gv_fullname4
-Perl_gv_handler
-Perl_gv_init
-Perl_gv_name_set
-Perl_gv_stashpv
-Perl_gv_stashpvn
-Perl_gv_stashsv
-Perl_gv_try_downgrade
-Perl_he_dup
-Perl_hek_dup
-Perl_hv_clear
-Perl_hv_clear_placeholders
-Perl_hv_common
-Perl_hv_common_key_len
-Perl_hv_delayfree_ent
-Perl_hv_delete
-Perl_hv_delete_ent
-Perl_hv_eiter_p
-Perl_hv_eiter_set
-Perl_hv_exists
-Perl_hv_exists_ent
-Perl_hv_fetch
-Perl_hv_fetch_ent
-Perl_hv_free_ent
-Perl_hv_iterinit
-Perl_hv_iterkey
-Perl_hv_iterkeysv
-Perl_hv_iternext
-Perl_hv_iternext_flags
-Perl_hv_iternextsv
-Perl_hv_iterval
-Perl_hv_ksplit
-Perl_hv_magic
-Perl_hv_name_set
-Perl_hv_placeholders_get
-Perl_hv_placeholders_p
-Perl_hv_placeholders_set
-Perl_hv_riter_p
-Perl_hv_riter_set
-Perl_hv_scalar
-Perl_hv_store
-Perl_hv_store_ent
-Perl_hv_store_flags
-Perl_hv_undef
-Perl_ibcmp
-Perl_ibcmp_locale
-Perl_ibcmp_utf8
-Perl_init_i18nl10n
-Perl_init_i18nl14n
-Perl_init_os_extras
-Perl_init_stacks
-Perl_init_tm
-Perl_instr
-Perl_is_ascii_string
-Perl_is_lvalue_sub
-Perl_is_uni_alnum
-Perl_is_uni_alnum_lc
-Perl_is_uni_alpha
-Perl_is_uni_alpha_lc
-Perl_is_uni_ascii
-Perl_is_uni_ascii_lc
-Perl_is_uni_cntrl
-Perl_is_uni_cntrl_lc
-Perl_is_uni_digit
-Perl_is_uni_digit_lc
-Perl_is_uni_graph
-Perl_is_uni_graph_lc
-Perl_is_uni_idfirst
-Perl_is_uni_idfirst_lc
-Perl_is_uni_lower
-Perl_is_uni_lower_lc
-Perl_is_uni_print
-Perl_is_uni_print_lc
-Perl_is_uni_punct
-Perl_is_uni_punct_lc
-Perl_is_uni_space
-Perl_is_uni_space_lc
-Perl_is_uni_upper
-Perl_is_uni_upper_lc
-Perl_is_uni_xdigit
-Perl_is_uni_xdigit_lc
-Perl_is_utf8_X_L
-Perl_is_utf8_X_LV
-Perl_is_utf8_X_LVT
-Perl_is_utf8_X_LV_LVT_V
-Perl_is_utf8_X_T
-Perl_is_utf8_X_V
-Perl_is_utf8_X_begin
-Perl_is_utf8_X_extend
-Perl_is_utf8_X_non_hangul
-Perl_is_utf8_X_prepend
-Perl_is_utf8_alnum
-Perl_is_utf8_alpha
-Perl_is_utf8_ascii
-Perl_is_utf8_char
-Perl_is_utf8_cntrl
-Perl_is_utf8_digit
-Perl_is_utf8_graph
-Perl_is_utf8_idcont
-Perl_is_utf8_idfirst
-Perl_is_utf8_lower
-Perl_is_utf8_mark
-Perl_is_utf8_perl_space
-Perl_is_utf8_perl_word
-Perl_is_utf8_posix_digit
-Perl_is_utf8_print
-Perl_is_utf8_punct
-Perl_is_utf8_space
-Perl_is_utf8_string
-Perl_is_utf8_string_loc
-Perl_is_utf8_string_loclen
-Perl_is_utf8_upper
-Perl_is_utf8_xdigit
-Perl_leave_scope
-Perl_lex_bufutf8
-Perl_lex_discard_to
-Perl_lex_end
-Perl_lex_grow_linestr
-Perl_lex_next_chunk
-Perl_lex_peek_unichar
-Perl_lex_read_space
-Perl_lex_read_to
-Perl_lex_read_unichar
-Perl_lex_stuff_pvn
-Perl_lex_stuff_sv
-Perl_lex_unstuff
-Perl_load_module
-Perl_load_module_nocontext
-Perl_looks_like_number
-Perl_magic_dump
-Perl_malloc
-Perl_markstack_grow
-Perl_mess
-Perl_mess_nocontext
-Perl_mfree
-Perl_mg_clear
-Perl_mg_copy
-Perl_mg_dup
-Perl_mg_find
-Perl_mg_free
-Perl_mg_get
-Perl_mg_length
-Perl_mg_magical
-Perl_mg_set
-Perl_mg_size
-Perl_mini_mktime
-Perl_mod
-Perl_moreswitches
-Perl_mro_get_from_name
-Perl_mro_get_linear_isa
-Perl_mro_get_private_data
-Perl_mro_meta_init
-Perl_mro_method_changed_in
-Perl_mro_register
-Perl_mro_set_mro
-Perl_mro_set_private_data
-Perl_my_atof
-Perl_my_atof2
-Perl_my_cxt_init
-Perl_my_dirfd
-Perl_my_exit
-Perl_my_failure_exit
-Perl_my_fflush_all
-Perl_my_fork
-Perl_my_lstat
-Perl_my_popen_list
-Perl_my_setenv
-Perl_my_snprintf
-Perl_my_socketpair
-Perl_my_stat
-Perl_my_strftime
-Perl_my_strlcat
-Perl_my_strlcpy
-Perl_my_vsnprintf
-Perl_newANONATTRSUB
-Perl_newANONHASH
-Perl_newANONLIST
-Perl_newANONSUB
-Perl_newASSIGNOP
-Perl_newATTRSUB
-Perl_newAV
-Perl_newAVREF
-Perl_newBINOP
-Perl_newCONDOP
-Perl_newCONSTSUB
-Perl_newCVREF
-Perl_newFORM
-Perl_newFOROP
-Perl_newGIVENOP
-Perl_newGVOP
-Perl_newGVREF
-Perl_newGVgen
-Perl_newHV
-Perl_newHVREF
-Perl_newHVhv
-Perl_newIO
-Perl_newLISTOP
-Perl_newLOGOP
-Perl_newLOOPEX
-Perl_newLOOPOP
-Perl_newMYSUB
-Perl_newNULLLIST
-Perl_newOP
-Perl_newPADOP
-Perl_newPMOP
-Perl_newPROG
-Perl_newPVOP
-Perl_newRANGE
-Perl_newRV
-Perl_newRV_noinc
-Perl_newSLICEOP
-Perl_newSTATEOP
-Perl_newSUB
-Perl_newSV
-Perl_newSVOP
-Perl_newSVREF
-Perl_newSV_type
-Perl_newSVhek
-Perl_newSViv
-Perl_newSVnv
-Perl_newSVpv
-Perl_newSVpvf
-Perl_newSVpvf_nocontext
-Perl_newSVpvn
-Perl_newSVpvn_flags
-Perl_newSVpvn_share
-Perl_newSVrv
-Perl_newSVsv
-Perl_newSVuv
-Perl_newUNOP
-Perl_newWHENOP
-Perl_newWHILEOP
-Perl_newXS
-Perl_newXS_flags
-Perl_new_collate
-Perl_new_ctype
-Perl_new_numeric
-Perl_new_stackinfo
-Perl_new_version
-Perl_new_warnings_bitfield
-Perl_ninstr
-Perl_nothreadhook
-Perl_op_clear
-Perl_op_dump
-Perl_op_free
-Perl_op_null
-Perl_op_refcnt_lock
-Perl_op_refcnt_unlock
-Perl_pack_cat
-Perl_packlist
-Perl_pad_findmy
-Perl_pad_push
-Perl_parser_dup
-Perl_pmflag
-Perl_pmop_dump
-Perl_pop_scope
-Perl_pregcomp
-Perl_pregexec
-Perl_pregfree
-Perl_pregfree2
-Perl_prescan_version
-Perl_printf_nocontext
-Perl_ptr_table_clear
-Perl_ptr_table_fetch
-Perl_ptr_table_free
-Perl_ptr_table_new
-Perl_ptr_table_split
-Perl_ptr_table_store
-Perl_push_scope
-Perl_pv_display
-Perl_pv_escape
-Perl_pv_pretty
-Perl_pv_uni_display
-Perl_qerror
-Perl_re_compile
-Perl_re_dup_guts
-Perl_re_intuit_start
-Perl_re_intuit_string
-Perl_realloc
-Perl_reentrant_free
-Perl_reentrant_init
-Perl_reentrant_retry
-Perl_reentrant_size
-Perl_ref
-Perl_refcounted_he_chain_2hv
-Perl_refcounted_he_fetch
-Perl_refcounted_he_new
-Perl_reg_named_buff
-Perl_reg_named_buff_all
-Perl_reg_named_buff_exists
-Perl_reg_named_buff_fetch
-Perl_reg_named_buff_firstkey
-Perl_reg_named_buff_iter
-Perl_reg_named_buff_nextkey
-Perl_reg_named_buff_scalar
-Perl_reg_numbered_buff_fetch
-Perl_reg_numbered_buff_length
-Perl_reg_numbered_buff_store
-Perl_reg_qr_package
-Perl_reg_temp_copy
-Perl_regclass_swash
-Perl_regcurly
-Perl_regdump
-Perl_regdupe_internal
-Perl_regexec_flags
-Perl_regfree_internal
-Perl_reginitcolors
-Perl_regnext
-Perl_repeatcpy
-Perl_report_uninit
-Perl_require_pv
-Perl_rninstr
-Perl_rsignal
-Perl_rsignal_state
-Perl_runops_debug
-Perl_runops_standard
-Perl_rvpv_dup
-Perl_safesyscalloc
-Perl_safesysfree
-Perl_safesysmalloc
-Perl_safesysrealloc
-Perl_save_I16
-Perl_save_I32
-Perl_save_I8
-Perl_save_adelete
-Perl_save_aelem_flags
-Perl_save_alloc
-Perl_save_aptr
-Perl_save_ary
-Perl_save_bool
-Perl_save_clearsv
-Perl_save_delete
-Perl_save_destructor
-Perl_save_destructor_x
-Perl_save_freeop
-Perl_save_freepv
-Perl_save_freesv
-Perl_save_generic_pvref
-Perl_save_generic_svref
-Perl_save_gp
-Perl_save_hash
-Perl_save_hdelete
-Perl_save_helem_flags
-Perl_save_hptr
-Perl_save_int
-Perl_save_item
-Perl_save_iv
-Perl_save_list
-Perl_save_long
-Perl_save_mortalizesv
-Perl_save_nogv
-Perl_save_op
-Perl_save_padsv_and_mortalize
-Perl_save_pptr
-Perl_save_pushptr
-Perl_save_re_context
-Perl_save_scalar
-Perl_save_set_svflags
-Perl_save_shared_pvref
-Perl_save_sptr
-Perl_save_svref
-Perl_save_vptr
-Perl_savepv
-Perl_savepvn
-Perl_savesharedpv
-Perl_savesharedpvn
-Perl_savestack_grow
-Perl_savestack_grow_cnt
-Perl_savesvpv
-Perl_scan_bin
-Perl_scan_hex
-Perl_scan_num
-Perl_scan_oct
-Perl_scan_version
-Perl_scan_vstring
-Perl_screaminstr
-Perl_seed
-Perl_set_context
-Perl_set_numeric_local
-Perl_set_numeric_radix
-Perl_set_numeric_standard
-Perl_setdefout
-Perl_share_hek
-Perl_si_dup
-Perl_signbit
-Perl_sortsv
-Perl_sortsv_flags
-Perl_ss_dup
-Perl_stack_grow
-Perl_start_subparse
-Perl_stashpv_hvname_match
-Perl_str_to_version
-Perl_sv_2bool
-Perl_sv_2cv
-Perl_sv_2io
-Perl_sv_2iv
-Perl_sv_2iv_flags
-Perl_sv_2mortal
-Perl_sv_2nv
-Perl_sv_2pv
-Perl_sv_2pv_flags
-Perl_sv_2pv_nolen
-Perl_sv_2pvbyte
-Perl_sv_2pvbyte_nolen
-Perl_sv_2pvutf8
-Perl_sv_2pvutf8_nolen
-Perl_sv_2uv
-Perl_sv_2uv_flags
-Perl_sv_backoff
-Perl_sv_bless
-Perl_sv_cat_decode
-Perl_sv_catpv
-Perl_sv_catpv_mg
-Perl_sv_catpvf
-Perl_sv_catpvf_mg
-Perl_sv_catpvf_mg_nocontext
-Perl_sv_catpvf_nocontext
-Perl_sv_catpvn
-Perl_sv_catpvn_flags
-Perl_sv_catpvn_mg
-Perl_sv_catsv
-Perl_sv_catsv_flags
-Perl_sv_catsv_mg
-Perl_sv_chop
-Perl_sv_clear
-Perl_sv_cmp
-Perl_sv_cmp_locale
-Perl_sv_collxfrm
-Perl_sv_compile_2op
-Perl_sv_copypv
-Perl_sv_dec
-Perl_sv_derived_from
-Perl_sv_destroyable
-Perl_sv_does
-Perl_sv_dump
-Perl_sv_dup
-Perl_sv_eq
-Perl_sv_force_normal
-Perl_sv_force_normal_flags
-Perl_sv_free
-Perl_sv_free2
-Perl_sv_gets
-Perl_sv_grow
-Perl_sv_inc
-Perl_sv_insert
-Perl_sv_insert_flags
-Perl_sv_isa
-Perl_sv_isobject
-Perl_sv_iv
-Perl_sv_len
-Perl_sv_len_utf8
-Perl_sv_magic
-Perl_sv_magicext
-Perl_sv_mortalcopy
-Perl_sv_newmortal
-Perl_sv_newref
-Perl_sv_nolocking
-Perl_sv_nosharing
-Perl_sv_nounlocking
-Perl_sv_nv
-Perl_sv_peek
-Perl_sv_pos_b2u
-Perl_sv_pos_u2b
-Perl_sv_pos_u2b_flags
-Perl_sv_pv
-Perl_sv_pvbyte
-Perl_sv_pvbyten
-Perl_sv_pvbyten_force
-Perl_sv_pvn
-Perl_sv_pvn_force
-Perl_sv_pvn_force_flags
-Perl_sv_pvn_nomg
-Perl_sv_pvutf8
-Perl_sv_pvutf8n
-Perl_sv_pvutf8n_force
-Perl_sv_recode_to_utf8
-Perl_sv_reftype
-Perl_sv_replace
-Perl_sv_report_used
-Perl_sv_reset
-Perl_sv_rvweaken
-Perl_sv_setiv
-Perl_sv_setiv_mg
-Perl_sv_setnv
-Perl_sv_setnv_mg
-Perl_sv_setpv
-Perl_sv_setpv_mg
-Perl_sv_setpvf
-Perl_sv_setpvf_mg
-Perl_sv_setpvf_mg_nocontext
-Perl_sv_setpvf_nocontext
-Perl_sv_setpviv
-Perl_sv_setpviv_mg
-Perl_sv_setpvn
-Perl_sv_setpvn_mg
-Perl_sv_setref_iv
-Perl_sv_setref_nv
-Perl_sv_setref_pv
-Perl_sv_setref_pvn
-Perl_sv_setref_uv
-Perl_sv_setsv
-Perl_sv_setsv_flags
-Perl_sv_setsv_mg
-Perl_sv_setuv
-Perl_sv_setuv_mg
-Perl_sv_taint
-Perl_sv_tainted
-Perl_sv_true
-Perl_sv_uni_display
-Perl_sv_unmagic
-Perl_sv_unref
-Perl_sv_unref_flags
-Perl_sv_untaint
-Perl_sv_upgrade
-Perl_sv_usepvn
-Perl_sv_usepvn_flags
-Perl_sv_usepvn_mg
-Perl_sv_utf8_decode
-Perl_sv_utf8_downgrade
-Perl_sv_utf8_encode
-Perl_sv_utf8_upgrade
-Perl_sv_utf8_upgrade_flags_grow
-Perl_sv_uv
-Perl_sv_vcatpvf
-Perl_sv_vcatpvf_mg
-Perl_sv_vcatpvfn
-Perl_sv_vsetpvf
-Perl_sv_vsetpvf_mg
-Perl_sv_vsetpvfn
-Perl_swash_fetch
-Perl_swash_init
-Perl_sys_init
-Perl_sys_init3
-Perl_sys_intern_clear
-Perl_sys_intern_dup
-Perl_sys_intern_init
-Perl_sys_term
-Perl_taint_env
-Perl_taint_proper
-Perl_tmps_grow
-Perl_to_uni_fold
-Perl_to_uni_lower
-Perl_to_uni_lower_lc
-Perl_to_uni_title
-Perl_to_uni_title_lc
-Perl_to_uni_upper
-Perl_to_uni_upper_lc
-Perl_to_utf8_case
-Perl_to_utf8_fold
-Perl_to_utf8_lower
-Perl_to_utf8_title
-Perl_to_utf8_upper
-Perl_unpack_str
-Perl_unpackstring
-Perl_unsharepvn
-Perl_upg_version
-Perl_utf16_to_utf8
-Perl_utf16_to_utf8_reversed
-Perl_utf8_distance
-Perl_utf8_hop
-Perl_utf8_length
-Perl_utf8_to_bytes
-Perl_utf8_to_uvchr
-Perl_utf8_to_uvuni
-Perl_utf8n_to_uvchr
-Perl_utf8n_to_uvuni
-Perl_uvchr_to_utf8
-Perl_uvchr_to_utf8_flags
-Perl_uvuni_to_utf8
-Perl_uvuni_to_utf8_flags
-Perl_vcmp
-Perl_vcroak
-Perl_vdeb
-Perl_vform
-Perl_vivify_defelem
-Perl_vload_module
-Perl_vmess
-Perl_vnewSVpvf
-Perl_vnormal
-Perl_vnumify
-Perl_vstringify
-Perl_vverify
-Perl_vwarn
-Perl_vwarner
-Perl_warn
-Perl_warn_nocontext
-Perl_warner
-Perl_warner_nocontext
-Perl_whichsig
-Perl_win32_init
-Perl_win32_term
-Perl_yylex
-RunPerl
-boot_DynaLoader
-boot_Win32CORE
-init_Win32CORE
-perl_alloc
-perl_alloc_override
-perl_alloc_using
-perl_clone
-perl_clone_host
-perl_clone_using
-perl_construct
-perl_destruct
-perl_free
-perl_get_host_info
-perl_parse
-perl_run
-perlsio_binmode
-setgid
-setuid
-win32_abort
-win32_accept
-win32_access
-win32_alarm
-win32_ansipath
-win32_async_check
-win32_bind
-win32_calloc
-win32_chdir
-win32_chmod
-win32_chsize
-win32_clearenv
-win32_clearerr
-win32_close
-win32_closedir
-win32_closesocket
-win32_connect
-win32_crypt
-win32_dup
-win32_dup2
-win32_dynaload
-win32_endhostent
-win32_endnetent
-win32_endprotoent
-win32_endservent
-win32_environ
-win32_eof
-win32_errno
-win32_execv
-win32_execvp
-win32_fclose
-win32_fcloseall
-win32_fdopen
-win32_feof
-win32_ferror
-win32_fflush
-win32_fgetc
-win32_fgetpos
-win32_fgets
-win32_fileno
-win32_flock
-win32_flushall
-win32_fopen
-win32_fprintf
-win32_fputc
-win32_fputs
-win32_fread
-win32_free
-win32_free_childdir
-win32_free_childenv
-win32_freopen
-win32_fseek
-win32_fsetpos
-win32_fstat
-win32_ftell
-win32_fwrite
-win32_get_childdir
-win32_get_childenv
-win32_get_osfhandle
-win32_getc
-win32_getchar
-win32_getenv
-win32_gethostbyaddr
-win32_gethostbyname
-win32_gethostname
-win32_getnetbyaddr
-win32_getnetbyname
-win32_getnetent
-win32_getpeername
-win32_getpid
-win32_getprotobyname
-win32_getprotobynumber
-win32_getprotoent
-win32_gets
-win32_getservbyname
-win32_getservbyport
-win32_getservent
-win32_getsockname
-win32_getsockopt
-win32_gettimeofday
-win32_htonl
-win32_htons
-win32_inet_addr
-win32_inet_ntoa
-win32_ioctl
-win32_ioctlsocket
-win32_isatty
-win32_kill
-win32_link
-win32_listen
-win32_longpath
-win32_lseek
-win32_malloc
-win32_mkdir
-win32_ntohl
-win32_ntohs
-win32_open
-win32_open_osfhandle
-win32_opendir
-win32_os_id
-win32_pclose
-win32_perror
-win32_pipe
-win32_popen
-win32_printf
-win32_putc
-win32_putchar
-win32_putenv
-win32_puts
-win32_read
-win32_readdir
-win32_realloc
-win32_recv
-win32_recvfrom
-win32_rename
-win32_rewind
-win32_rewinddir
-win32_rmdir
-win32_seekdir
-win32_select
-win32_send
-win32_sendto
-win32_setbuf
-win32_sethostent
-win32_setmode
-win32_setnetent
-win32_setprotoent
-win32_setservent
-win32_setsockopt
-win32_setvbuf
-win32_shutdown
-win32_sleep
-win32_socket
-win32_spawnvp
-win32_stat
-win32_stderr
-win32_stdin
-win32_stdout
-win32_str_os_error
-win32_strerror
-win32_tell
-win32_telldir
-win32_times
-win32_tmpfile
-win32_uname
-win32_ungetc
-win32_unlink
-win32_utime
-win32_vfprintf
-win32_vprintf
-win32_wait
-win32_waitpid
-win32_write
diff --git a/plugins/perl/importlib/sbperl-x64.bat b/plugins/perl/importlib/sbperl-x64.bat
deleted file mode 100644
index a27ab442..00000000
--- a/plugins/perl/importlib/sbperl-x64.bat
+++ /dev/null
@@ -1,10 +0,0 @@
-@echo off
-set PATH=c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin\amd64
-cd c:\mozilla-build\perl-5.12-x64\perl\lib\CORE
-echo.Overwrite existing def file?
-pause
-dumpbin /exports ..\..\bin\perl512.dll > perl512.def
-echo.Please adjust the resulting file manually, then hit return!
-pause
-lib /machine:x64 /def:perl512.def
-pause
diff --git a/plugins/perl/importlib/sbperl-x86.bat b/plugins/perl/importlib/sbperl-x86.bat
deleted file mode 100644
index e0b1a3dd..00000000
--- a/plugins/perl/importlib/sbperl-x86.bat
+++ /dev/null
@@ -1,10 +0,0 @@
-@echo off
-set PATH=c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin;C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE
-cd c:\mozilla-build\perl-5.12-x86\perl\lib\CORE
-echo.Overwrite existing def file?
-pause
-dumpbin /exports ..\..\bin\perl512.dll > perl512.def
-echo.Please adjust the resulting file manually, then hit return!
-pause
-lib /machine:x86 /def:perl512.def
-pause
diff --git a/plugins/perl/makefile-512.mak b/plugins/perl/makefile-512.mak
index 15f78a23..a77dc145 100644
--- a/plugins/perl/makefile-512.mak
+++ b/plugins/perl/makefile-512.mak
@@ -12,15 +12,22 @@ perl.def:
 	echo xchat_plugin_get_info >> perl.def
 
 perl.obj: perl.c
-	$(CC) $(CFLAGS) perl.c $(GLIB) /I$(PERL512PATH) /I.. /DPERL_DLL=\"$(PERL512LIB).dll\"
+	$(CC) $(CFLAGS) perl.c $(GLIB) /I$(PERL512PATH)\perl\lib\CORE /I.. /DPERL_DLL=\"$(PERL512LIB).dll\"
+
+$(PERL512LIB).lib: perl512.def
+!ifdef X64
+	lib /machine:x64 /def:perl512.def
+!else
+	lib /machine:x86 /def:perl512.def
+!endif
 
 perl.c: xchat.pm.h
 
 xchat.pm.h: lib/Xchat.pm lib/IRC.pm
 	perl.exe generate_header
 
-$(TARGET): perl.obj perl.def
-	$(LINK) /DLL /out:$(TARGET) perl.obj $(LDFLAGS) $(PERL512LIB).lib /libpath:$(PERL512PATH) /delayload:$(PERL512LIB).dll $(DIRENTLIB) delayimp.lib user32.lib shell32.lib advapi32.lib /def:perl.def
+$(TARGET): perl.obj perl.def $(PERL512LIB).lib
+	$(LINK) /DLL /out:$(TARGET) perl.obj $(LDFLAGS) $(PERL512LIB).lib /delayload:$(PERL512LIB).dll $(DIRENTLIB) delayimp.lib user32.lib shell32.lib advapi32.lib /def:perl.def
 
 clean:
 	@del $(TARGET)
diff --git a/plugins/perl/makefile-514.mak b/plugins/perl/makefile-514.mak
index 8c689979..4d8181dd 100644
--- a/plugins/perl/makefile-514.mak
+++ b/plugins/perl/makefile-514.mak
@@ -12,7 +12,7 @@ perl.def:
 	echo xchat_plugin_get_info >> perl.def
 
 perl.obj: perl.c
-	$(CC) $(CFLAGS) perl.c $(GLIB) /I$(PERL514PATH) /I.. /DPERL_DLL=\"$(PERL514LIB).dll\"
+	$(CC) $(CFLAGS) perl.c $(GLIB) /I$(PERL514PATH)\lib\CORE /I.. /DPERL_DLL=\"$(PERL514LIB).dll\"
 
 perl.c: xchat.pm.h
 
diff --git a/plugins/perl/perl512.def b/plugins/perl/perl512.def
new file mode 100644
index 00000000..5cfcaa68
--- /dev/null
+++ b/plugins/perl/perl512.def
@@ -0,0 +1,1420 @@
+LIBRARY perl512
+EXPORTS
+PL_bincompat_options
+PL_check
+PL_fold
+PL_fold_locale
+PL_freq
+PL_keyword_plugin
+PL_memory_wrap
+PL_no_aelem
+PL_no_dir_func
+PL_no_func
+PL_no_helem_sv
+PL_no_localize_ref
+PL_no_mem
+PL_no_modify
+PL_no_myglob
+PL_no_security
+PL_no_sock_func
+PL_no_symref
+PL_no_usym
+PL_no_wrongref
+PL_op_desc
+PL_op_name
+PL_opargs
+PL_perlio_mutex
+PL_ppaddr
+PL_reg_extflags_name
+PL_reg_name
+PL_regkind
+PL_sig_name
+PL_sig_num
+PL_simple
+PL_utf8skip
+PL_uuemap
+PL_varies
+PL_vtbl_amagic
+PL_vtbl_amagicelem
+PL_vtbl_arylen
+PL_vtbl_backref
+PL_vtbl_bm
+PL_vtbl_collxfrm
+PL_vtbl_dbline
+PL_vtbl_defelem
+PL_vtbl_env
+PL_vtbl_envelem
+PL_vtbl_fm
+PL_vtbl_isa
+PL_vtbl_isaelem
+PL_vtbl_mglob
+PL_vtbl_nkeys
+PL_vtbl_pack
+PL_vtbl_packelem
+PL_vtbl_pos
+PL_vtbl_regdata
+PL_vtbl_regdatum
+PL_vtbl_regexp
+PL_vtbl_sig
+PL_vtbl_sigelem
+PL_vtbl_substr
+PL_vtbl_sv
+PL_vtbl_taint
+PL_vtbl_utf8
+PL_vtbl_uvar
+PL_vtbl_vec
+PL_warn_nl
+PL_warn_nosemi
+PL_warn_reserved
+PL_warn_uninit
+PerlIOBase_binmode
+PerlIOBase_clearerr
+PerlIOBase_close
+PerlIOBase_dup
+PerlIOBase_eof
+PerlIOBase_error
+PerlIOBase_fileno
+PerlIOBase_noop_fail
+PerlIOBase_noop_ok
+PerlIOBase_popped
+PerlIOBase_pushed
+PerlIOBase_read
+PerlIOBase_setlinebuf
+PerlIOBase_unread
+PerlIOBuf_bufsiz
+PerlIOBuf_close
+PerlIOBuf_dup
+PerlIOBuf_fill
+PerlIOBuf_flush
+PerlIOBuf_get_base
+PerlIOBuf_get_cnt
+PerlIOBuf_get_ptr
+PerlIOBuf_open
+PerlIOBuf_popped
+PerlIOBuf_pushed
+PerlIOBuf_read
+PerlIOBuf_seek
+PerlIOBuf_set_ptrcnt
+PerlIOBuf_tell
+PerlIOBuf_unread
+PerlIOBuf_write
+PerlIO_allocate
+PerlIO_apply_layera
+PerlIO_apply_layers
+PerlIO_arg_fetch
+PerlIO_binmode
+PerlIO_canset_cnt
+PerlIO_debug
+PerlIO_define_layer
+PerlIO_exportFILE
+PerlIO_fast_gets
+PerlIO_fdopen
+PerlIO_findFILE
+PerlIO_find_layer
+PerlIO_getc
+PerlIO_getname
+PerlIO_getpos
+PerlIO_has_base
+PerlIO_has_cntptr
+PerlIO_importFILE
+PerlIO_init
+PerlIO_isutf8
+PerlIO_layer_fetch
+PerlIO_list_alloc
+PerlIO_list_free
+PerlIO_modestr
+PerlIO_open
+PerlIO_parse_layers
+PerlIO_pending
+PerlIO_perlio
+PerlIO_pop
+PerlIO_printf
+PerlIO_push
+PerlIO_putc
+PerlIO_puts
+PerlIO_releaseFILE
+PerlIO_reopen
+PerlIO_rewind
+PerlIO_setpos
+PerlIO_sprintf
+PerlIO_stdoutf
+PerlIO_sv_dup
+PerlIO_teardown
+PerlIO_tmpfile
+PerlIO_ungetc
+PerlIO_vprintf
+PerlIO_vsprintf
+Perl_GNo_ptr
+Perl_GYes_ptr
+Perl_Gcheck_ptr
+Perl_Gcsighandlerp_ptr
+Perl_Gcurinterp_ptr
+Perl_Gdo_undump_ptr
+Perl_Gdollarzero_mutex_ptr
+Perl_Gfold_locale_ptr
+Perl_Ghexdigit_ptr
+Perl_Ghints_mutex_ptr
+Perl_Ginterp_size_5_10_0_ptr
+Perl_Ginterp_size_ptr
+Perl_Gkeyword_plugin_ptr
+Perl_Gmy_ctx_mutex_ptr
+Perl_Gmy_cxt_index_ptr
+Perl_Gop_mutex_ptr
+Perl_Gop_seq_ptr
+Perl_Gop_sequence_ptr
+Perl_Gpatleave_ptr
+Perl_Gperlio_debug_fd_ptr
+Perl_Gperlio_fd_refcnt_ptr
+Perl_Gperlio_fd_refcnt_size_ptr
+Perl_Gperlio_mutex_ptr
+Perl_Gppaddr_ptr
+Perl_Grevision_ptr
+Perl_Grunops_dbg_ptr
+Perl_Grunops_std_ptr
+Perl_Gsh_path_ptr
+Perl_Gsig_trapped_ptr
+Perl_Gsigfpe_saved_ptr
+Perl_Gsubversion_ptr
+Perl_Gsv_placeholder_ptr
+Perl_Gthr_key_ptr
+Perl_Guse_safe_putenv_ptr
+Perl_Gv_AMupdate
+Perl_Gversion_ptr
+Perl_Gveto_cleanup_ptr
+Perl_IArgv_ptr
+Perl_ICmd_ptr
+Perl_IDBgv_ptr
+Perl_IDBline_ptr
+Perl_IDBsignal_ptr
+Perl_IDBsingle_ptr
+Perl_IDBsub_ptr
+Perl_IDBtrace_ptr
+Perl_IDir_ptr
+Perl_IEnv_ptr
+Perl_ILIO_ptr
+Perl_IMemParse_ptr
+Perl_IMemShared_ptr
+Perl_IMem_ptr
+Perl_IOpPtr_ptr
+Perl_IOpSlab_ptr
+Perl_IOpSpace_ptr
+Perl_IProc_ptr
+Perl_ISock_ptr
+Perl_IStdIO_ptr
+Perl_ISv_ptr
+Perl_IXpv_ptr
+Perl_Iamagic_generation_ptr
+Perl_Ian_ptr
+Perl_Iargvgv_ptr
+Perl_Iargvout_stack_ptr
+Perl_Iargvoutgv_ptr
+Perl_Ibasetime_ptr
+Perl_Ibeginav_ptr
+Perl_Ibeginav_save_ptr
+Perl_Ibody_arenas_ptr
+Perl_Ibody_roots_ptr
+Perl_Ibodytarget_ptr
+Perl_Ibreakable_sub_gen_ptr
+Perl_Icheckav_ptr
+Perl_Icheckav_save_ptr
+Perl_Ichopset_ptr
+Perl_Iclocktick_ptr
+Perl_Icollation_ix_ptr
+Perl_Icollation_name_ptr
+Perl_Icollation_standard_ptr
+Perl_Icollxfrm_base_ptr
+Perl_Icollxfrm_mult_ptr
+Perl_Icolors_ptr
+Perl_Icolorset_ptr
+Perl_Icompcv_ptr
+Perl_Icompiling_ptr
+Perl_Icomppad_name_fill_ptr
+Perl_Icomppad_name_floor_ptr
+Perl_Icomppad_name_ptr
+Perl_Icomppad_ptr
+Perl_Icop_seqmax_ptr
+Perl_Icurcop_ptr
+Perl_Icurcopdb_ptr
+Perl_Icurpad_ptr
+Perl_Icurpm_ptr
+Perl_Icurstack_ptr
+Perl_Icurstackinfo_ptr
+Perl_Icurstash_ptr
+Perl_Icurstname_ptr
+Perl_Icustom_op_descs_ptr
+Perl_Icustom_op_names_ptr
+Perl_Icv_has_eval_ptr
+Perl_Idbargs_ptr
+Perl_Idebstash_ptr
+Perl_Idebug_pad_ptr
+Perl_Idebug_ptr
+Perl_Idef_layerlist_ptr
+Perl_Idefgv_ptr
+Perl_Idefoutgv_ptr
+Perl_Idefstash_ptr
+Perl_Idelaymagic_ptr
+Perl_Idestroyhook_ptr
+Perl_Idiehook_ptr
+Perl_Idirty_ptr
+Perl_Idoextract_ptr
+Perl_Idoswitches_ptr
+Perl_Idowarn_ptr
+Perl_Idumpindent_ptr
+Perl_Ie_script_ptr
+Perl_Iefloatbuf_ptr
+Perl_Iefloatsize_ptr
+Perl_Iegid_ptr
+Perl_Iencoding_ptr
+Perl_Iendav_ptr
+Perl_Ienvgv_ptr
+Perl_Ierrgv_ptr
+Perl_Ierrors_ptr
+Perl_Ieuid_ptr
+Perl_Ieval_root_ptr
+Perl_Ieval_start_ptr
+Perl_Ievalseq_ptr
+Perl_Iexit_flags_ptr
+Perl_Iexitlist_ptr
+Perl_Iexitlistlen_ptr
+Perl_Ifdpid_ptr
+Perl_Ifilemode_ptr
+Perl_Ifirstgv_ptr
+Perl_Iforkprocess_ptr
+Perl_Iformfeed_ptr
+Perl_Iformtarget_ptr
+Perl_Igensym_ptr
+Perl_Igid_ptr
+Perl_Iglob_index_ptr
+Perl_Iglobalstash_ptr
+Perl_Ihash_seed_ptr
+Perl_Ihintgv_ptr
+Perl_Ihints_ptr
+Perl_Ihv_fetch_ent_mh_ptr
+Perl_Iin_clean_all_ptr
+Perl_Iin_clean_objs_ptr
+Perl_Iin_eval_ptr
+Perl_Iin_load_module_ptr
+Perl_Iincgv_ptr
+Perl_Iinitav_ptr
+Perl_Iinplace_ptr
+Perl_Iisarev_ptr
+Perl_Iknown_layers_ptr
+Perl_Ilast_in_gv_ptr
+Perl_Ilast_swash_hv_ptr
+Perl_Ilast_swash_key_ptr
+Perl_Ilast_swash_klen_ptr
+Perl_Ilast_swash_slen_ptr
+Perl_Ilast_swash_tmps_ptr
+Perl_Ilastfd_ptr
+Perl_Ilastscream_ptr
+Perl_Ilaststatval_ptr
+Perl_Ilaststype_ptr
+Perl_Ilocalizing_ptr
+Perl_Ilocalpatches_ptr
+Perl_Ilockhook_ptr
+Perl_Imain_cv_ptr
+Perl_Imain_root_ptr
+Perl_Imain_start_ptr
+Perl_Imainstack_ptr
+Perl_Imarkstack_max_ptr
+Perl_Imarkstack_ptr
+Perl_Imarkstack_ptr_ptr
+Perl_Imax_intro_pending_ptr
+Perl_Imaxo_ptr
+Perl_Imaxscream_ptr
+Perl_Imaxsysfd_ptr
+Perl_Imess_sv_ptr
+Perl_Imin_intro_pending_ptr
+Perl_Iminus_E_ptr
+Perl_Iminus_F_ptr
+Perl_Iminus_a_ptr
+Perl_Iminus_c_ptr
+Perl_Iminus_l_ptr
+Perl_Iminus_n_ptr
+Perl_Iminus_p_ptr
+Perl_Imodglobal_ptr
+Perl_Imy_cxt_list_ptr
+Perl_Imy_cxt_size_ptr
+Perl_Ina_ptr
+Perl_Inice_chunk_ptr
+Perl_Inice_chunk_size_ptr
+Perl_Inomemok_ptr
+Perl_Inumeric_local_ptr
+Perl_Inumeric_name_ptr
+Perl_Inumeric_radix_sv_ptr
+Perl_Inumeric_standard_ptr
+Perl_Iofsgv_ptr
+Perl_Ioldname_ptr
+Perl_Iop_mask_ptr
+Perl_Iop_ptr
+Perl_Iopfreehook_ptr
+Perl_Iorigalen_ptr
+Perl_Iorigargc_ptr
+Perl_Iorigargv_ptr
+Perl_Iorigenviron_ptr
+Perl_Iorigfilename_ptr
+Perl_Iors_sv_ptr
+Perl_Iosname_ptr
+Perl_Ipad_reset_pending_ptr
+Perl_Ipadix_floor_ptr
+Perl_Ipadix_ptr
+Perl_Iparser_ptr
+Perl_Ipatchlevel_ptr
+Perl_Ipeepp_ptr
+Perl_Iperl_destruct_level_ptr
+Perl_Iperldb_ptr
+Perl_Iperlio_ptr
+Perl_Ipreambleav_ptr
+Perl_Iprofiledata_ptr
+Perl_Ipsig_name_ptr
+Perl_Ipsig_pend_ptr
+Perl_Ipsig_ptr_ptr
+Perl_Iptr_table_ptr
+Perl_Ireentrant_retint_ptr
+Perl_Ireg_state_ptr
+Perl_Iregdummy_ptr
+Perl_Iregex_pad_ptr
+Perl_Iregex_padav_ptr
+Perl_Ireginterp_cnt_ptr
+Perl_Iregistered_mros_ptr
+Perl_Iregmatch_slab_ptr
+Perl_Iregmatch_state_ptr
+Perl_Irehash_seed_ptr
+Perl_Irehash_seed_set_ptr
+Perl_Ireplgv_ptr
+Perl_Irestartop_ptr
+Perl_Irs_ptr
+Perl_Irunops_ptr
+Perl_Isavebegin_ptr
+Perl_Isavestack_ix_ptr
+Perl_Isavestack_max_ptr
+Perl_Isavestack_ptr
+Perl_Isawampersand_ptr
+Perl_Iscopestack_ix_ptr
+Perl_Iscopestack_max_ptr
+Perl_Iscopestack_name_ptr
+Perl_Iscopestack_ptr
+Perl_Iscreamfirst_ptr
+Perl_Iscreamnext_ptr
+Perl_Isecondgv_ptr
+Perl_Isharehook_ptr
+Perl_Isig_pending_ptr
+Perl_Isighandlerp_ptr
+Perl_Isignals_ptr
+Perl_Isort_RealCmp_ptr
+Perl_Isortcop_ptr
+Perl_Isortstash_ptr
+Perl_Isplitstr_ptr
+Perl_Isrand_called_ptr
+Perl_Istack_base_ptr
+Perl_Istack_max_ptr
+Perl_Istack_sp_ptr
+Perl_Istart_env_ptr
+Perl_Istashcache_ptr
+Perl_Istatbuf_ptr
+Perl_Istatcache_ptr
+Perl_Istatgv_ptr
+Perl_Istatname_ptr
+Perl_Istatusvalue_posix_ptr
+Perl_Istatusvalue_ptr
+Perl_Istderrgv_ptr
+Perl_Istdingv_ptr
+Perl_Istrtab_ptr
+Perl_Isub_generation_ptr
+Perl_Isubline_ptr
+Perl_Isubname_ptr
+Perl_Isv_arenaroot_ptr
+Perl_Isv_count_ptr
+Perl_Isv_no_ptr
+Perl_Isv_objcount_ptr
+Perl_Isv_root_ptr
+Perl_Isv_undef_ptr
+Perl_Isv_yes_ptr
+Perl_Isys_intern_ptr
+Perl_Itaint_warn_ptr
+Perl_Itainted_ptr
+Perl_Itainting_ptr
+Perl_Ithreadhook_ptr
+Perl_Itmps_floor_ptr
+Perl_Itmps_ix_ptr
+Perl_Itmps_max_ptr
+Perl_Itmps_stack_ptr
+Perl_Itop_env_ptr
+Perl_Itoptarget_ptr
+Perl_Iuid_ptr
+Perl_Iunicode_ptr
+Perl_Iunitcheckav_ptr
+Perl_Iunitcheckav_save_ptr
+Perl_Iunlockhook_ptr
+Perl_Iunsafe_ptr
+Perl_Iutf8_X_LVT_ptr
+Perl_Iutf8_X_LV_LVT_V_ptr
+Perl_Iutf8_X_LV_ptr
+Perl_Iutf8_X_L_ptr
+Perl_Iutf8_X_T_ptr
+Perl_Iutf8_X_V_ptr
+Perl_Iutf8_X_begin_ptr
+Perl_Iutf8_X_extend_ptr
+Perl_Iutf8_X_non_hangul_ptr
+Perl_Iutf8_X_prepend_ptr
+Perl_Iutf8_alnum_ptr
+Perl_Iutf8_alpha_ptr
+Perl_Iutf8_ascii_ptr
+Perl_Iutf8_cntrl_ptr
+Perl_Iutf8_digit_ptr
+Perl_Iutf8_graph_ptr
+Perl_Iutf8_idcont_ptr
+Perl_Iutf8_idstart_ptr
+Perl_Iutf8_lower_ptr
+Perl_Iutf8_mark_ptr
+Perl_Iutf8_perl_space_ptr
+Perl_Iutf8_perl_word_ptr
+Perl_Iutf8_posix_digit_ptr
+Perl_Iutf8_print_ptr
+Perl_Iutf8_punct_ptr
+Perl_Iutf8_space_ptr
+Perl_Iutf8_tofold_ptr
+Perl_Iutf8_tolower_ptr
+Perl_Iutf8_totitle_ptr
+Perl_Iutf8_toupper_ptr
+Perl_Iutf8_upper_ptr
+Perl_Iutf8_xdigit_ptr
+Perl_Iutf8cache_ptr
+Perl_Iutf8locale_ptr
+Perl_Iwarnhook_ptr
+Perl_PerlIO_clearerr
+Perl_PerlIO_close
+Perl_PerlIO_context_layers
+Perl_PerlIO_eof
+Perl_PerlIO_error
+Perl_PerlIO_fileno
+Perl_PerlIO_fill
+Perl_PerlIO_flush
+Perl_PerlIO_get_base
+Perl_PerlIO_get_bufsiz
+Perl_PerlIO_get_cnt
+Perl_PerlIO_get_ptr
+Perl_PerlIO_read
+Perl_PerlIO_seek
+Perl_PerlIO_set_cnt
+Perl_PerlIO_set_ptrcnt
+Perl_PerlIO_setlinebuf
+Perl_PerlIO_stderr
+Perl_PerlIO_stdin
+Perl_PerlIO_stdout
+Perl_PerlIO_tell
+Perl_PerlIO_unread
+Perl_PerlIO_write
+Perl_Slab_Alloc
+Perl_Slab_Free
+Perl_amagic_call
+Perl_any_dup
+Perl_apply_attrs_string
+Perl_atfork_lock
+Perl_atfork_unlock
+Perl_av_arylen_p
+Perl_av_clear
+Perl_av_delete
+Perl_av_exists
+Perl_av_extend
+Perl_av_fetch
+Perl_av_fill
+Perl_av_iter_p
+Perl_av_len
+Perl_av_make
+Perl_av_pop
+Perl_av_push
+Perl_av_reify
+Perl_av_shift
+Perl_av_store
+Perl_av_undef
+Perl_av_unshift
+Perl_block_gimme
+Perl_bytes_from_utf8
+Perl_bytes_to_utf8
+Perl_call_argv
+Perl_call_atexit
+Perl_call_list
+Perl_call_method
+Perl_call_pv
+Perl_call_sv
+Perl_calloc
+Perl_cast_i32
+Perl_cast_iv
+Perl_cast_ulong
+Perl_cast_uv
+Perl_ck_warner
+Perl_ck_warner_d
+Perl_ckwarn
+Perl_ckwarn_d
+Perl_croak
+Perl_croak_nocontext
+Perl_croak_xs_usage
+Perl_csighandler
+Perl_custom_op_desc
+Perl_custom_op_name
+Perl_cv_const_sv
+Perl_cv_undef
+Perl_cx_dump
+Perl_cx_dup
+Perl_cxinc
+Perl_deb
+Perl_deb_nocontext
+Perl_delimcpy
+Perl_despatch_signals
+Perl_die
+Perl_die_nocontext
+Perl_dirp_dup
+Perl_do_aexec
+Perl_do_aspawn
+Perl_do_binmode
+Perl_do_close
+Perl_do_gv_dump
+Perl_do_gvgv_dump
+Perl_do_hv_dump
+Perl_do_join
+Perl_do_magic_dump
+Perl_do_op_dump
+Perl_do_open
+Perl_do_open9
+Perl_do_openn
+Perl_do_pmop_dump
+Perl_do_spawn
+Perl_do_spawn_nowait
+Perl_do_sprintf
+Perl_do_sv_dump
+Perl_doing_taint
+Perl_doref
+Perl_dounwind
+Perl_dowantarray
+Perl_dump_all
+Perl_dump_eval
+Perl_dump_form
+Perl_dump_indent
+Perl_dump_packsubs
+Perl_dump_sub
+Perl_dump_vindent
+Perl_emulate_cop_io
+Perl_eval_pv
+Perl_eval_sv
+Perl_fbm_compile
+Perl_fbm_instr
+Perl_fetch_cop_label
+Perl_filter_add
+Perl_filter_del
+Perl_filter_read
+Perl_find_runcv
+Perl_find_rundefsvoffset
+Perl_form
+Perl_form_nocontext
+Perl_fp_dup
+Perl_fprintf_nocontext
+Perl_free_tmps
+Perl_get_av
+Perl_get_context
+Perl_get_cv
+Perl_get_cvn_flags
+Perl_get_hv
+Perl_get_op_descs
+Perl_get_op_names
+Perl_get_ppaddr
+Perl_get_re_arg
+Perl_get_sv
+Perl_get_vtbl
+Perl_getcwd_sv
+Perl_gp_dup
+Perl_gp_free
+Perl_gp_ref
+Perl_grok_bin
+Perl_grok_hex
+Perl_grok_number
+Perl_grok_numeric_radix
+Perl_grok_oct
+Perl_gv_AVadd
+Perl_gv_HVadd
+Perl_gv_IOadd
+Perl_gv_SVadd
+Perl_gv_add_by_type
+Perl_gv_autoload4
+Perl_gv_check
+Perl_gv_const_sv
+Perl_gv_dump
+Perl_gv_efullname
+Perl_gv_efullname3
+Perl_gv_efullname4
+Perl_gv_fetchfile
+Perl_gv_fetchfile_flags
+Perl_gv_fetchmeth
+Perl_gv_fetchmeth_autoload
+Perl_gv_fetchmethod
+Perl_gv_fetchmethod_autoload
+Perl_gv_fetchmethod_flags
+Perl_gv_fetchpv
+Perl_gv_fetchpvn_flags
+Perl_gv_fetchsv
+Perl_gv_fullname
+Perl_gv_fullname3
+Perl_gv_fullname4
+Perl_gv_handler
+Perl_gv_init
+Perl_gv_name_set
+Perl_gv_stashpv
+Perl_gv_stashpvn
+Perl_gv_stashsv
+Perl_gv_try_downgrade
+Perl_he_dup
+Perl_hek_dup
+Perl_hv_clear
+Perl_hv_clear_placeholders
+Perl_hv_common
+Perl_hv_common_key_len
+Perl_hv_delayfree_ent
+Perl_hv_delete
+Perl_hv_delete_ent
+Perl_hv_eiter_p
+Perl_hv_eiter_set
+Perl_hv_exists
+Perl_hv_exists_ent
+Perl_hv_fetch
+Perl_hv_fetch_ent
+Perl_hv_free_ent
+Perl_hv_iterinit
+Perl_hv_iterkey
+Perl_hv_iterkeysv
+Perl_hv_iternext
+Perl_hv_iternext_flags
+Perl_hv_iternextsv
+Perl_hv_iterval
+Perl_hv_ksplit
+Perl_hv_magic
+Perl_hv_name_set
+Perl_hv_placeholders_get
+Perl_hv_placeholders_p
+Perl_hv_placeholders_set
+Perl_hv_riter_p
+Perl_hv_riter_set
+Perl_hv_scalar
+Perl_hv_store
+Perl_hv_store_ent
+Perl_hv_store_flags
+Perl_hv_undef
+Perl_ibcmp
+Perl_ibcmp_locale
+Perl_ibcmp_utf8
+Perl_init_i18nl10n
+Perl_init_i18nl14n
+Perl_init_os_extras
+Perl_init_stacks
+Perl_init_tm
+Perl_instr
+Perl_is_ascii_string
+Perl_is_lvalue_sub
+Perl_is_uni_alnum
+Perl_is_uni_alnum_lc
+Perl_is_uni_alpha
+Perl_is_uni_alpha_lc
+Perl_is_uni_ascii
+Perl_is_uni_ascii_lc
+Perl_is_uni_cntrl
+Perl_is_uni_cntrl_lc
+Perl_is_uni_digit
+Perl_is_uni_digit_lc
+Perl_is_uni_graph
+Perl_is_uni_graph_lc
+Perl_is_uni_idfirst
+Perl_is_uni_idfirst_lc
+Perl_is_uni_lower
+Perl_is_uni_lower_lc
+Perl_is_uni_print
+Perl_is_uni_print_lc
+Perl_is_uni_punct
+Perl_is_uni_punct_lc
+Perl_is_uni_space
+Perl_is_uni_space_lc
+Perl_is_uni_upper
+Perl_is_uni_upper_lc
+Perl_is_uni_xdigit
+Perl_is_uni_xdigit_lc
+Perl_is_utf8_X_L
+Perl_is_utf8_X_LV
+Perl_is_utf8_X_LVT
+Perl_is_utf8_X_LV_LVT_V
+Perl_is_utf8_X_T
+Perl_is_utf8_X_V
+Perl_is_utf8_X_begin
+Perl_is_utf8_X_extend
+Perl_is_utf8_X_non_hangul
+Perl_is_utf8_X_prepend
+Perl_is_utf8_alnum
+Perl_is_utf8_alpha
+Perl_is_utf8_ascii
+Perl_is_utf8_char
+Perl_is_utf8_cntrl
+Perl_is_utf8_digit
+Perl_is_utf8_graph
+Perl_is_utf8_idcont
+Perl_is_utf8_idfirst
+Perl_is_utf8_lower
+Perl_is_utf8_mark
+Perl_is_utf8_perl_space
+Perl_is_utf8_perl_word
+Perl_is_utf8_posix_digit
+Perl_is_utf8_print
+Perl_is_utf8_punct
+Perl_is_utf8_space
+Perl_is_utf8_string
+Perl_is_utf8_string_loc
+Perl_is_utf8_string_loclen
+Perl_is_utf8_upper
+Perl_is_utf8_xdigit
+Perl_leave_scope
+Perl_lex_bufutf8
+Perl_lex_discard_to
+Perl_lex_end
+Perl_lex_grow_linestr
+Perl_lex_next_chunk
+Perl_lex_peek_unichar
+Perl_lex_read_space
+Perl_lex_read_to
+Perl_lex_read_unichar
+Perl_lex_stuff_pvn
+Perl_lex_stuff_sv
+Perl_lex_unstuff
+Perl_load_module
+Perl_load_module_nocontext
+Perl_looks_like_number
+Perl_magic_dump
+Perl_malloc
+Perl_markstack_grow
+Perl_mess
+Perl_mess_nocontext
+Perl_mfree
+Perl_mg_clear
+Perl_mg_copy
+Perl_mg_dup
+Perl_mg_find
+Perl_mg_free
+Perl_mg_get
+Perl_mg_length
+Perl_mg_magical
+Perl_mg_set
+Perl_mg_size
+Perl_mini_mktime
+Perl_mod
+Perl_moreswitches
+Perl_mro_get_from_name
+Perl_mro_get_linear_isa
+Perl_mro_get_private_data
+Perl_mro_meta_init
+Perl_mro_method_changed_in
+Perl_mro_register
+Perl_mro_set_mro
+Perl_mro_set_private_data
+Perl_my_atof
+Perl_my_atof2
+Perl_my_cxt_init
+Perl_my_dirfd
+Perl_my_exit
+Perl_my_failure_exit
+Perl_my_fflush_all
+Perl_my_fork
+Perl_my_lstat
+Perl_my_popen_list
+Perl_my_setenv
+Perl_my_snprintf
+Perl_my_socketpair
+Perl_my_stat
+Perl_my_strftime
+Perl_my_strlcat
+Perl_my_strlcpy
+Perl_my_vsnprintf
+Perl_newANONATTRSUB
+Perl_newANONHASH
+Perl_newANONLIST
+Perl_newANONSUB
+Perl_newASSIGNOP
+Perl_newATTRSUB
+Perl_newAV
+Perl_newAVREF
+Perl_newBINOP
+Perl_newCONDOP
+Perl_newCONSTSUB
+Perl_newCVREF
+Perl_newFORM
+Perl_newFOROP
+Perl_newGIVENOP
+Perl_newGVOP
+Perl_newGVREF
+Perl_newGVgen
+Perl_newHV
+Perl_newHVREF
+Perl_newHVhv
+Perl_newIO
+Perl_newLISTOP
+Perl_newLOGOP
+Perl_newLOOPEX
+Perl_newLOOPOP
+Perl_newMYSUB
+Perl_newNULLLIST
+Perl_newOP
+Perl_newPADOP
+Perl_newPMOP
+Perl_newPROG
+Perl_newPVOP
+Perl_newRANGE
+Perl_newRV
+Perl_newRV_noinc
+Perl_newSLICEOP
+Perl_newSTATEOP
+Perl_newSUB
+Perl_newSV
+Perl_newSVOP
+Perl_newSVREF
+Perl_newSV_type
+Perl_newSVhek
+Perl_newSViv
+Perl_newSVnv
+Perl_newSVpv
+Perl_newSVpvf
+Perl_newSVpvf_nocontext
+Perl_newSVpvn
+Perl_newSVpvn_flags
+Perl_newSVpvn_share
+Perl_newSVrv
+Perl_newSVsv
+Perl_newSVuv
+Perl_newUNOP
+Perl_newWHENOP
+Perl_newWHILEOP
+Perl_newXS
+Perl_newXS_flags
+Perl_new_collate
+Perl_new_ctype
+Perl_new_numeric
+Perl_new_stackinfo
+Perl_new_version
+Perl_new_warnings_bitfield
+Perl_ninstr
+Perl_nothreadhook
+Perl_op_clear
+Perl_op_dump
+Perl_op_free
+Perl_op_null
+Perl_op_refcnt_lock
+Perl_op_refcnt_unlock
+Perl_pack_cat
+Perl_packlist
+Perl_pad_findmy
+Perl_pad_push
+Perl_parser_dup
+Perl_pmflag
+Perl_pmop_dump
+Perl_pop_scope
+Perl_pregcomp
+Perl_pregexec
+Perl_pregfree
+Perl_pregfree2
+Perl_prescan_version
+Perl_printf_nocontext
+Perl_ptr_table_clear
+Perl_ptr_table_fetch
+Perl_ptr_table_free
+Perl_ptr_table_new
+Perl_ptr_table_split
+Perl_ptr_table_store
+Perl_push_scope
+Perl_pv_display
+Perl_pv_escape
+Perl_pv_pretty
+Perl_pv_uni_display
+Perl_qerror
+Perl_re_compile
+Perl_re_dup_guts
+Perl_re_intuit_start
+Perl_re_intuit_string
+Perl_realloc
+Perl_reentrant_free
+Perl_reentrant_init
+Perl_reentrant_retry
+Perl_reentrant_size
+Perl_ref
+Perl_refcounted_he_chain_2hv
+Perl_refcounted_he_fetch
+Perl_refcounted_he_new
+Perl_reg_named_buff
+Perl_reg_named_buff_all
+Perl_reg_named_buff_exists
+Perl_reg_named_buff_fetch
+Perl_reg_named_buff_firstkey
+Perl_reg_named_buff_iter
+Perl_reg_named_buff_nextkey
+Perl_reg_named_buff_scalar
+Perl_reg_numbered_buff_fetch
+Perl_reg_numbered_buff_length
+Perl_reg_numbered_buff_store
+Perl_reg_qr_package
+Perl_reg_temp_copy
+Perl_regclass_swash
+Perl_regcurly
+Perl_regdump
+Perl_regdupe_internal
+Perl_regexec_flags
+Perl_regfree_internal
+Perl_reginitcolors
+Perl_regnext
+Perl_repeatcpy
+Perl_report_uninit
+Perl_require_pv
+Perl_rninstr
+Perl_rsignal
+Perl_rsignal_state
+Perl_runops_debug
+Perl_runops_standard
+Perl_rvpv_dup
+Perl_safesyscalloc
+Perl_safesysfree
+Perl_safesysmalloc
+Perl_safesysrealloc
+Perl_save_I16
+Perl_save_I32
+Perl_save_I8
+Perl_save_adelete
+Perl_save_aelem_flags
+Perl_save_alloc
+Perl_save_aptr
+Perl_save_ary
+Perl_save_bool
+Perl_save_clearsv
+Perl_save_delete
+Perl_save_destructor
+Perl_save_destructor_x
+Perl_save_freeop
+Perl_save_freepv
+Perl_save_freesv
+Perl_save_generic_pvref
+Perl_save_generic_svref
+Perl_save_gp
+Perl_save_hash
+Perl_save_hdelete
+Perl_save_helem_flags
+Perl_save_hptr
+Perl_save_int
+Perl_save_item
+Perl_save_iv
+Perl_save_list
+Perl_save_long
+Perl_save_mortalizesv
+Perl_save_nogv
+Perl_save_op
+Perl_save_padsv_and_mortalize
+Perl_save_pptr
+Perl_save_pushptr
+Perl_save_re_context
+Perl_save_scalar
+Perl_save_set_svflags
+Perl_save_shared_pvref
+Perl_save_sptr
+Perl_save_svref
+Perl_save_vptr
+Perl_savepv
+Perl_savepvn
+Perl_savesharedpv
+Perl_savesharedpvn
+Perl_savestack_grow
+Perl_savestack_grow_cnt
+Perl_savesvpv
+Perl_scan_bin
+Perl_scan_hex
+Perl_scan_num
+Perl_scan_oct
+Perl_scan_version
+Perl_scan_vstring
+Perl_screaminstr
+Perl_seed
+Perl_set_context
+Perl_set_numeric_local
+Perl_set_numeric_radix
+Perl_set_numeric_standard
+Perl_setdefout
+Perl_share_hek
+Perl_si_dup
+Perl_signbit
+Perl_sortsv
+Perl_sortsv_flags
+Perl_ss_dup
+Perl_stack_grow
+Perl_start_subparse
+Perl_stashpv_hvname_match
+Perl_str_to_version
+Perl_sv_2bool
+Perl_sv_2cv
+Perl_sv_2io
+Perl_sv_2iv
+Perl_sv_2iv_flags
+Perl_sv_2mortal
+Perl_sv_2nv
+Perl_sv_2pv
+Perl_sv_2pv_flags
+Perl_sv_2pv_nolen
+Perl_sv_2pvbyte
+Perl_sv_2pvbyte_nolen
+Perl_sv_2pvutf8
+Perl_sv_2pvutf8_nolen
+Perl_sv_2uv
+Perl_sv_2uv_flags
+Perl_sv_backoff
+Perl_sv_bless
+Perl_sv_cat_decode
+Perl_sv_catpv
+Perl_sv_catpv_mg
+Perl_sv_catpvf
+Perl_sv_catpvf_mg
+Perl_sv_catpvf_mg_nocontext
+Perl_sv_catpvf_nocontext
+Perl_sv_catpvn
+Perl_sv_catpvn_flags
+Perl_sv_catpvn_mg
+Perl_sv_catsv
+Perl_sv_catsv_flags
+Perl_sv_catsv_mg
+Perl_sv_chop
+Perl_sv_clear
+Perl_sv_cmp
+Perl_sv_cmp_locale
+Perl_sv_collxfrm
+Perl_sv_compile_2op
+Perl_sv_copypv
+Perl_sv_dec
+Perl_sv_derived_from
+Perl_sv_destroyable
+Perl_sv_does
+Perl_sv_dump
+Perl_sv_dup
+Perl_sv_eq
+Perl_sv_force_normal
+Perl_sv_force_normal_flags
+Perl_sv_free
+Perl_sv_free2
+Perl_sv_gets
+Perl_sv_grow
+Perl_sv_inc
+Perl_sv_insert
+Perl_sv_insert_flags
+Perl_sv_isa
+Perl_sv_isobject
+Perl_sv_iv
+Perl_sv_len
+Perl_sv_len_utf8
+Perl_sv_magic
+Perl_sv_magicext
+Perl_sv_mortalcopy
+Perl_sv_newmortal
+Perl_sv_newref
+Perl_sv_nolocking
+Perl_sv_nosharing
+Perl_sv_nounlocking
+Perl_sv_nv
+Perl_sv_peek
+Perl_sv_pos_b2u
+Perl_sv_pos_u2b
+Perl_sv_pos_u2b_flags
+Perl_sv_pv
+Perl_sv_pvbyte
+Perl_sv_pvbyten
+Perl_sv_pvbyten_force
+Perl_sv_pvn
+Perl_sv_pvn_force
+Perl_sv_pvn_force_flags
+Perl_sv_pvn_nomg
+Perl_sv_pvutf8
+Perl_sv_pvutf8n
+Perl_sv_pvutf8n_force
+Perl_sv_recode_to_utf8
+Perl_sv_reftype
+Perl_sv_replace
+Perl_sv_report_used
+Perl_sv_reset
+Perl_sv_rvweaken
+Perl_sv_setiv
+Perl_sv_setiv_mg
+Perl_sv_setnv
+Perl_sv_setnv_mg
+Perl_sv_setpv
+Perl_sv_setpv_mg
+Perl_sv_setpvf
+Perl_sv_setpvf_mg
+Perl_sv_setpvf_mg_nocontext
+Perl_sv_setpvf_nocontext
+Perl_sv_setpviv
+Perl_sv_setpviv_mg
+Perl_sv_setpvn
+Perl_sv_setpvn_mg
+Perl_sv_setref_iv
+Perl_sv_setref_nv
+Perl_sv_setref_pv
+Perl_sv_setref_pvn
+Perl_sv_setref_uv
+Perl_sv_setsv
+Perl_sv_setsv_flags
+Perl_sv_setsv_mg
+Perl_sv_setuv
+Perl_sv_setuv_mg
+Perl_sv_taint
+Perl_sv_tainted
+Perl_sv_true
+Perl_sv_uni_display
+Perl_sv_unmagic
+Perl_sv_unref
+Perl_sv_unref_flags
+Perl_sv_untaint
+Perl_sv_upgrade
+Perl_sv_usepvn
+Perl_sv_usepvn_flags
+Perl_sv_usepvn_mg
+Perl_sv_utf8_decode
+Perl_sv_utf8_downgrade
+Perl_sv_utf8_encode
+Perl_sv_utf8_upgrade
+Perl_sv_utf8_upgrade_flags_grow
+Perl_sv_uv
+Perl_sv_vcatpvf
+Perl_sv_vcatpvf_mg
+Perl_sv_vcatpvfn
+Perl_sv_vsetpvf
+Perl_sv_vsetpvf_mg
+Perl_sv_vsetpvfn
+Perl_swash_fetch
+Perl_swash_init
+Perl_sys_init
+Perl_sys_init3
+Perl_sys_intern_clear
+Perl_sys_intern_dup
+Perl_sys_intern_init
+Perl_sys_term
+Perl_taint_env
+Perl_taint_proper
+Perl_tmps_grow
+Perl_to_uni_fold
+Perl_to_uni_lower
+Perl_to_uni_lower_lc
+Perl_to_uni_title
+Perl_to_uni_title_lc
+Perl_to_uni_upper
+Perl_to_uni_upper_lc
+Perl_to_utf8_case
+Perl_to_utf8_fold
+Perl_to_utf8_lower
+Perl_to_utf8_title
+Perl_to_utf8_upper
+Perl_unpack_str
+Perl_unpackstring
+Perl_unsharepvn
+Perl_upg_version
+Perl_utf16_to_utf8
+Perl_utf16_to_utf8_reversed
+Perl_utf8_distance
+Perl_utf8_hop
+Perl_utf8_length
+Perl_utf8_to_bytes
+Perl_utf8_to_uvchr
+Perl_utf8_to_uvuni
+Perl_utf8n_to_uvchr
+Perl_utf8n_to_uvuni
+Perl_uvchr_to_utf8
+Perl_uvchr_to_utf8_flags
+Perl_uvuni_to_utf8
+Perl_uvuni_to_utf8_flags
+Perl_vcmp
+Perl_vcroak
+Perl_vdeb
+Perl_vform
+Perl_vivify_defelem
+Perl_vload_module
+Perl_vmess
+Perl_vnewSVpvf
+Perl_vnormal
+Perl_vnumify
+Perl_vstringify
+Perl_vverify
+Perl_vwarn
+Perl_vwarner
+Perl_warn
+Perl_warn_nocontext
+Perl_warner
+Perl_warner_nocontext
+Perl_whichsig
+Perl_win32_init
+Perl_win32_term
+Perl_yylex
+RunPerl
+boot_DynaLoader
+boot_Win32CORE
+init_Win32CORE
+perl_alloc
+perl_alloc_override
+perl_alloc_using
+perl_clone
+perl_clone_host
+perl_clone_using
+perl_construct
+perl_destruct
+perl_free
+perl_get_host_info
+perl_parse
+perl_run
+perlsio_binmode
+setgid
+setuid
+win32_abort
+win32_accept
+win32_access
+win32_alarm
+win32_ansipath
+win32_async_check
+win32_bind
+win32_calloc
+win32_chdir
+win32_chmod
+win32_chsize
+win32_clearenv
+win32_clearerr
+win32_close
+win32_closedir
+win32_closesocket
+win32_connect
+win32_crypt
+win32_dup
+win32_dup2
+win32_dynaload
+win32_endhostent
+win32_endnetent
+win32_endprotoent
+win32_endservent
+win32_environ
+win32_eof
+win32_errno
+win32_execv
+win32_execvp
+win32_fclose
+win32_fcloseall
+win32_fdopen
+win32_feof
+win32_ferror
+win32_fflush
+win32_fgetc
+win32_fgetpos
+win32_fgets
+win32_fileno
+win32_flock
+win32_flushall
+win32_fopen
+win32_fprintf
+win32_fputc
+win32_fputs
+win32_fread
+win32_free
+win32_free_childdir
+win32_free_childenv
+win32_freopen
+win32_fseek
+win32_fsetpos
+win32_fstat
+win32_ftell
+win32_fwrite
+win32_get_childdir
+win32_get_childenv
+win32_get_osfhandle
+win32_getc
+win32_getchar
+win32_getenv
+win32_gethostbyaddr
+win32_gethostbyname
+win32_gethostname
+win32_getnetbyaddr
+win32_getnetbyname
+win32_getnetent
+win32_getpeername
+win32_getpid
+win32_getprotobyname
+win32_getprotobynumber
+win32_getprotoent
+win32_gets
+win32_getservbyname
+win32_getservbyport
+win32_getservent
+win32_getsockname
+win32_getsockopt
+win32_gettimeofday
+win32_htonl
+win32_htons
+win32_inet_addr
+win32_inet_ntoa
+win32_ioctl
+win32_ioctlsocket
+win32_isatty
+win32_kill
+win32_link
+win32_listen
+win32_longpath
+win32_lseek
+win32_malloc
+win32_mkdir
+win32_ntohl
+win32_ntohs
+win32_open
+win32_open_osfhandle
+win32_opendir
+win32_os_id
+win32_pclose
+win32_perror
+win32_pipe
+win32_popen
+win32_printf
+win32_putc
+win32_putchar
+win32_putenv
+win32_puts
+win32_read
+win32_readdir
+win32_realloc
+win32_recv
+win32_recvfrom
+win32_rename
+win32_rewind
+win32_rewinddir
+win32_rmdir
+win32_seekdir
+win32_select
+win32_send
+win32_sendto
+win32_setbuf
+win32_sethostent
+win32_setmode
+win32_setnetent
+win32_setprotoent
+win32_setservent
+win32_setsockopt
+win32_setvbuf
+win32_shutdown
+win32_sleep
+win32_socket
+win32_spawnvp
+win32_stat
+win32_stderr
+win32_stdin
+win32_stdout
+win32_str_os_error
+win32_strerror
+win32_tell
+win32_telldir
+win32_times
+win32_tmpfile
+win32_uname
+win32_ungetc
+win32_unlink
+win32_utime
+win32_vfprintf
+win32_vprintf
+win32_wait
+win32_waitpid
+win32_write
diff --git a/src/makeinc.skel.mak b/src/makeinc.skel.mak
index 5c6beb6f..1d6d23cc 100644
--- a/src/makeinc.skel.mak
+++ b/src/makeinc.skel.mak
@@ -30,8 +30,8 @@ CFLAGS = $(CFLAGS) /favor:AMD64 /D_WIN64
 CPPFLAGS = $(CPPFLAGS) /favor:AMD64 /D_WIN64
 LDFLAGS = $(LDFLAGS) msvcrt_win2003.obj
 
-PERL512PATH = c:\mozilla-build\perl-5.12-x64\perl\lib\CORE
-PERL514PATH = c:\mozilla-build\perl-5.14-x64\lib\CORE
+PERL512PATH = c:\mozilla-build\perl-5.12-x64
+PERL514PATH = c:\mozilla-build\perl-5.14-x64
 PYTHONPATH = c:\mozilla-build\python-2.7-x64
 TCLPATH = c:\mozilla-build\tcl-8.5-x64
 !else
-- 
cgit 1.4.1


From 1bf32a69bcd6544e3d5b5b572dff8241674623fb Mon Sep 17 00:00:00 2001
From: "berkeviktor@aol.com" <berkeviktor@aol.com>
Date: Thu, 28 Jul 2011 00:12:19 +0200
Subject: fix perl 5.14 linkage

---
 plugins/perl/makefile-514.mak | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/perl/makefile-514.mak b/plugins/perl/makefile-514.mak
index 4d8181dd..65ab59d5 100644
--- a/plugins/perl/makefile-514.mak
+++ b/plugins/perl/makefile-514.mak
@@ -20,7 +20,7 @@ xchat.pm.h: lib/Xchat.pm lib/IRC.pm
 	perl.exe generate_header
 
 $(TARGET): perl.obj perl.def
-	$(LINK) /DLL /out:$(TARGET) perl.obj $(LDFLAGS) $(PERL514LIB).lib /libpath:$(PERL514PATH) /delayload:$(PERL514LIB).dll $(DIRENTLIB) delayimp.lib user32.lib shell32.lib advapi32.lib /def:perl.def
+	$(LINK) /DLL /out:$(TARGET) perl.obj $(LDFLAGS) $(PERL514LIB).lib /libpath:$(PERL514PATH)\lib\CORE /delayload:$(PERL514LIB).dll $(DIRENTLIB) delayimp.lib user32.lib shell32.lib advapi32.lib /def:perl.def
 
 clean:
 	@del $(TARGET)
-- 
cgit 1.4.1


From 96caff1fbdf201164339e5e94fde04d8cb7968e8 Mon Sep 17 00:00:00 2001
From: "berkeviktor@aol.com" <berkeviktor@aol.com>
Date: Thu, 28 Jul 2011 00:32:29 +0200
Subject: instruct users to download strawberry perl instead of activeperl

---
 plugins/perl/perl.c | 10 +++++-----
 1 file changed, 5 insertions(+), 5 deletions(-)

(limited to 'plugins')

diff --git a/plugins/perl/perl.c b/plugins/perl/perl.c
index 761566f9..2f297769 100644
--- a/plugins/perl/perl.c
+++ b/plugins/perl/perl.c
@@ -1346,9 +1346,9 @@ perl_load_file (char *filename)
 				/* http://forum.xchat.org/viewtopic.php?t=3277 */
 				thread_mbox ("Cannot use this " PERL_DLL "\n\n"
 #ifdef _WIN64
-								 "64-bit ActivePerl is required.");
+								 "64-bit Strawberry Perl is required.");
 #else
-								 "32-bit ActivePerl is required.");
+								 "32-bit Strawberry Perl is required.");
 #endif
 			else {
 				/* a lot of people install this old version */
@@ -1357,14 +1357,14 @@ perl_load_file (char *filename)
 					FreeLibrary (lib);
 					lib = NULL;
 					thread_mbox ("Cannot open " PERL_DLL "\n\n"
-									 "You must have ActivePerl " PERL_REQUIRED_VERSION " installed in order to\n"
+									 "You must have Strawberry Perl " PERL_REQUIRED_VERSION " installed in order to\n"
 									 "run perl scripts.\n\n"
 									 "I have found Perl 5.6, but that is too old.");
 				} else {
 					thread_mbox ("Cannot open " PERL_DLL "\n\n"
-									 "You must have ActivePerl " PERL_REQUIRED_VERSION " installed in order to\n"
+									 "You must have Strawberry Perl " PERL_REQUIRED_VERSION " installed in order to\n"
 									 "run perl scripts.\n\n"
-									 "http://www.activestate.com/activeperl/downloads\n\n"
+									 "http://strawberryperl.com\n\n"
 									 "Make sure perl's bin directory is in your PATH.");
 				}
 			}
-- 
cgit 1.4.1


From 162fc1ead323cef91079ba5be9f47d99b3ca39d4 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Tue, 9 Aug 2011 14:05:57 +0200
Subject: update the update checker to use our shiny new git repo

---
 plugins/upd/upd.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

(limited to 'plugins')

diff --git a/plugins/upd/upd.c b/plugins/upd/upd.c
index a3a6acc4..724b37c1 100644
--- a/plugins/upd/upd.c
+++ b/plugins/upd/upd.c
@@ -42,7 +42,7 @@ check_version ()
 		return "Unknown";
 	}
 
-	hFile = InternetOpenUrl (hINet, "http://xchat-wdk.googlecode.com/hg/version.txt?r=wdk", NULL, 0, 0, 0);
+	hFile = InternetOpenUrl (hINet, "http://xchat-wdk.googlecode.com/git/version.txt?r=wdk", NULL, 0, 0, 0);
 	
 	if (hFile)
 	{
@@ -91,7 +91,7 @@ xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugi
 
 	*plugin_name = "Update Checker";
 	*plugin_desc = "Plugin for checking for XChat-WDK updates";
-	*plugin_version = "1.3";
+	*plugin_version = "1.4";
 
 	xchat_hook_command (ph, "UPDCHK", XCHAT_PRI_NORM, print_version, 0, 0);
 	xchat_command (ph, "MENU -ietc\\download.png ADD \"Help/Check for Updates\" \"UPDCHK\"");
-- 
cgit 1.4.1


From d00f7dce5a022b17c76479c458461308ccf8ab7e Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Tue, 9 Aug 2011 14:42:40 +0200
Subject: do not cache update info

---
 plugins/upd/upd.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/upd/upd.c b/plugins/upd/upd.c
index 724b37c1..8c88f0e5 100644
--- a/plugins/upd/upd.c
+++ b/plugins/upd/upd.c
@@ -42,7 +42,7 @@ check_version ()
 		return "Unknown";
 	}
 
-	hFile = InternetOpenUrl (hINet, "http://xchat-wdk.googlecode.com/git/version.txt?r=wdk", NULL, 0, 0, 0);
+	hFile = InternetOpenUrl (hINet, "http://xchat-wdk.googlecode.com/git/version.txt?r=wdk", NULL, 0, INTERNET_FLAG_NO_CACHE_WRITE | INTERNET_FLAG_RELOAD, 0);
 	
 	if (hFile)
 	{
-- 
cgit 1.4.1


From a1f4443d657182a28b124b6a1390a26680f98fc5 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Tue, 9 Aug 2011 20:51:32 +0200
Subject: include channel name in channel message and channel msg hilight event
 alerts (tdebaets)

---
 plugins/xtray/callbacks.cpp | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

(limited to 'plugins')

diff --git a/plugins/xtray/callbacks.cpp b/plugins/xtray/callbacks.cpp
index 18547ab3..443cb05d 100644
--- a/plugins/xtray/callbacks.cpp
+++ b/plugins/xtray/callbacks.cpp
@@ -89,12 +89,12 @@ int event_cb(char *word[], void *userdata)
 		{
 		case CHAN_HILIGHT:
 			_snprintf(szInfo, 512, "%s:\r\n%s", word[1], word[2]);
-			_snprintf(szName, 64, "Hilight");
+			_snprintf(szName, 64, "Highlight: %s", xchat_get_info (ph, "channel"));
 			dwInfoFlags = NIIF_INFO;
 			break;
 		case CHAN_MESSAGE:
 			_snprintf(szInfo, 512, "%s:\r\n%s", word[1], word[2]);
-			_snprintf(szName, 64, "Channel Message");
+			_snprintf(szName, 64, "Channel Message: %s", xchat_get_info (ph, "channel"));
 			dwInfoFlags = NIIF_INFO;
 			break;
 		case CHAN_TOPIC_CHANGE:
-- 
cgit 1.4.1


From 0709b95732214f48e191d591de9a652b0c9ddf82 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Thu, 11 Aug 2011 08:12:35 +0200
Subject: minor formatting

---
 plugins/checksum/checksum.c | 2 +-
 plugins/upd/upd.c           | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

(limited to 'plugins')

diff --git a/plugins/checksum/checksum.c b/plugins/checksum/checksum.c
index 170daa5b..2b5f801a 100644
--- a/plugins/checksum/checksum.c
+++ b/plugins/checksum/checksum.c
@@ -13,7 +13,7 @@
  *    documentation and/or other materials provided with the distribution.
  * 3. The name of the author may not be used to endorse or promote products
  *    derived from this software without specific prior written permission.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR
  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
diff --git a/plugins/upd/upd.c b/plugins/upd/upd.c
index 8c88f0e5..92b7d06e 100644
--- a/plugins/upd/upd.c
+++ b/plugins/upd/upd.c
@@ -11,7 +11,7 @@
  *    documentation and/or other materials provided with the distribution.
  * 3. The name of the author may not be used to endorse or promote products
  *    derived from this software without specific prior written permission.
- * 
+ *
  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR
  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
-- 
cgit 1.4.1


From 4338ddf9ec6a3662e852bcdbbfd3048e8d108a10 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Fri, 12 Aug 2011 01:39:40 +0200
Subject: add wmpa 1.0.2 sources

---
 plugins/wmpa/ReadMe.txt                |  70 ++++
 plugins/wmpa/StdAfx.cpp                |   8 +
 plugins/wmpa/StdAfx.h                  |  62 ++++
 plugins/wmpa/res/wmpa.rc2              |  13 +
 plugins/wmpa/resource.h                |  22 ++
 plugins/wmpa/wmpa.clw                  |  43 +++
 plugins/wmpa/wmpa.cpp                  | 212 ++++++++++++
 plugins/wmpa/wmpa.def                  |  16 +
 plugins/wmpa/wmpa.dsp                  | 421 +++++++++++++++++++++++
 plugins/wmpa/wmpa.dsw                  |  31 ++
 plugins/wmpa/wmpa.h                    |  61 ++++
 plugins/wmpa/wmpa.odl                  |  44 +++
 plugins/wmpa/wmpa.plg                  |  16 +
 plugins/wmpa/wmpa.rc                   | 204 ++++++++++++
 plugins/wmpa/wmpadialog.cpp            | 375 +++++++++++++++++++++
 plugins/wmpa/wmpadialog.h              |  91 +++++
 plugins/wmpa/wmpcdrom.cpp              |  37 +++
 plugins/wmpa/wmpcdrom.h                |  39 +++
 plugins/wmpa/wmpcdromcollection.cpp    |  45 +++
 plugins/wmpa/wmpcdromcollection.h      |  39 +++
 plugins/wmpa/wmpclosedcaption.cpp      |  75 +++++
 plugins/wmpa/wmpclosedcaption.h        |  40 +++
 plugins/wmpa/wmpcontrols.cpp           | 123 +++++++
 plugins/wmpa/wmpcontrols.h             |  52 +++
 plugins/wmpa/wmpdvd.cpp                |  52 +++
 plugins/wmpa/wmpdvd.h                  |  38 +++
 plugins/wmpa/wmperror.cpp              |  45 +++
 plugins/wmpa/wmperror.h                |  40 +++
 plugins/wmpa/wmperroritem.cpp          |  50 +++
 plugins/wmpa/wmperroritem.h            |  37 +++
 plugins/wmpa/wmpmedia.cpp              | 167 ++++++++++
 plugins/wmpa/wmpmedia.h                |  50 +++
 plugins/wmpa/wmpmediacollection.cpp    | 133 ++++++++
 plugins/wmpa/wmpmediacollection.h      |  50 +++
 plugins/wmpa/wmpnetwork.cpp            | 233 +++++++++++++
 plugins/wmpa/wmpnetwork.h              |  60 ++++
 plugins/wmpa/wmpplayer4.cpp            | 321 ++++++++++++++++++
 plugins/wmpa/wmpplayer4.h              | 104 ++++++
 plugins/wmpa/wmpplayerapplication.cpp  |  39 +++
 plugins/wmpa/wmpplayerapplication.h    |  36 ++
 plugins/wmpa/wmpplaylist.cpp           | 132 ++++++++
 plugins/wmpa/wmpplaylist.h             |  50 +++
 plugins/wmpa/wmpplaylistarray.cpp      |  35 ++
 plugins/wmpa/wmpplaylistarray.h        |  38 +++
 plugins/wmpa/wmpplaylistcollection.cpp |  82 +++++
 plugins/wmpa/wmpplaylistcollection.h   |  44 +++
 plugins/wmpa/wmpsettings.cpp           | 193 +++++++++++
 plugins/wmpa/wmpsettings.h             |  55 +++
 plugins/wmpa/wmpstringcollection.cpp   |  32 ++
 plugins/wmpa/wmpstringcollection.h     |  34 ++
 plugins/wmpa/xchat-plugin.cpp          | 590 +++++++++++++++++++++++++++++++++
 plugins/wmpa/xchat-plugin.h            | 368 ++++++++++++++++++++
 plugins/wmpa/xchat.ico                 | Bin 0 -> 25670 bytes
 53 files changed, 5247 insertions(+)
 create mode 100644 plugins/wmpa/ReadMe.txt
 create mode 100644 plugins/wmpa/StdAfx.cpp
 create mode 100644 plugins/wmpa/StdAfx.h
 create mode 100644 plugins/wmpa/res/wmpa.rc2
 create mode 100644 plugins/wmpa/resource.h
 create mode 100644 plugins/wmpa/wmpa.clw
 create mode 100644 plugins/wmpa/wmpa.cpp
 create mode 100644 plugins/wmpa/wmpa.def
 create mode 100644 plugins/wmpa/wmpa.dsp
 create mode 100644 plugins/wmpa/wmpa.dsw
 create mode 100644 plugins/wmpa/wmpa.h
 create mode 100644 plugins/wmpa/wmpa.odl
 create mode 100644 plugins/wmpa/wmpa.plg
 create mode 100644 plugins/wmpa/wmpa.rc
 create mode 100644 plugins/wmpa/wmpadialog.cpp
 create mode 100644 plugins/wmpa/wmpadialog.h
 create mode 100644 plugins/wmpa/wmpcdrom.cpp
 create mode 100644 plugins/wmpa/wmpcdrom.h
 create mode 100644 plugins/wmpa/wmpcdromcollection.cpp
 create mode 100644 plugins/wmpa/wmpcdromcollection.h
 create mode 100644 plugins/wmpa/wmpclosedcaption.cpp
 create mode 100644 plugins/wmpa/wmpclosedcaption.h
 create mode 100644 plugins/wmpa/wmpcontrols.cpp
 create mode 100644 plugins/wmpa/wmpcontrols.h
 create mode 100644 plugins/wmpa/wmpdvd.cpp
 create mode 100644 plugins/wmpa/wmpdvd.h
 create mode 100644 plugins/wmpa/wmperror.cpp
 create mode 100644 plugins/wmpa/wmperror.h
 create mode 100644 plugins/wmpa/wmperroritem.cpp
 create mode 100644 plugins/wmpa/wmperroritem.h
 create mode 100644 plugins/wmpa/wmpmedia.cpp
 create mode 100644 plugins/wmpa/wmpmedia.h
 create mode 100644 plugins/wmpa/wmpmediacollection.cpp
 create mode 100644 plugins/wmpa/wmpmediacollection.h
 create mode 100644 plugins/wmpa/wmpnetwork.cpp
 create mode 100644 plugins/wmpa/wmpnetwork.h
 create mode 100644 plugins/wmpa/wmpplayer4.cpp
 create mode 100644 plugins/wmpa/wmpplayer4.h
 create mode 100644 plugins/wmpa/wmpplayerapplication.cpp
 create mode 100644 plugins/wmpa/wmpplayerapplication.h
 create mode 100644 plugins/wmpa/wmpplaylist.cpp
 create mode 100644 plugins/wmpa/wmpplaylist.h
 create mode 100644 plugins/wmpa/wmpplaylistarray.cpp
 create mode 100644 plugins/wmpa/wmpplaylistarray.h
 create mode 100644 plugins/wmpa/wmpplaylistcollection.cpp
 create mode 100644 plugins/wmpa/wmpplaylistcollection.h
 create mode 100644 plugins/wmpa/wmpsettings.cpp
 create mode 100644 plugins/wmpa/wmpsettings.h
 create mode 100644 plugins/wmpa/wmpstringcollection.cpp
 create mode 100644 plugins/wmpa/wmpstringcollection.h
 create mode 100644 plugins/wmpa/xchat-plugin.cpp
 create mode 100644 plugins/wmpa/xchat-plugin.h
 create mode 100644 plugins/wmpa/xchat.ico

(limited to 'plugins')

diff --git a/plugins/wmpa/ReadMe.txt b/plugins/wmpa/ReadMe.txt
new file mode 100644
index 00000000..00a549f8
--- /dev/null
+++ b/plugins/wmpa/ReadMe.txt
@@ -0,0 +1,70 @@
+========================================================================
+       MICROSOFT FOUNDATION CLASS LIBRARY : wmpa
+========================================================================
+
+
+AppWizard has created this wmpa DLL for you.  This DLL not only
+demonstrates the basics of using the Microsoft Foundation classes but
+is also a starting point for writing your DLL.
+
+This file contains a summary of what you will find in each of the files that
+make up your wmpa DLL.
+
+wmpa.dsp
+    This file (the project file) contains information at the project level and
+    is used to build a single project or subproject. Other users can share the
+    project (.dsp) file, but they should export the makefiles locally.
+
+wmpa.h
+	This is the main header file for the DLL.  It declares the
+	CWmpaApp class.
+
+wmpa.cpp
+	This is the main DLL source file.  It contains the class CWmpaApp.
+	It also contains the OLE entry points required of inproc servers.
+
+wmpa.odl
+    This file contains the Object Description Language source code for the
+    type library of your DLL.
+
+wmpa.rc
+    This is a listing of all of the Microsoft Windows resources that the
+    program uses.  It includes the icons, bitmaps, and cursors that are stored
+    in the RES subdirectory.  This file can be directly edited in Microsoft
+	Visual C++.
+
+wmpa.clw
+    This file contains information used by ClassWizard to edit existing
+    classes or add new classes.  ClassWizard also uses this file to store
+    information needed to create and edit message maps and dialog data
+    maps and to create prototype member functions.
+
+res\wmpa.rc2
+    This file contains resources that are not edited by Microsoft 
+	Visual C++.  You should place all resources not editable by
+	the resource editor in this file.
+
+wmpa.def
+    This file contains information about the DLL that must be
+    provided to run with Microsoft Windows.  It defines parameters
+    such as the name and description of the DLL.  It also exports
+	functions from the DLL.
+
+/////////////////////////////////////////////////////////////////////////////
+Other standard files:
+
+StdAfx.h, StdAfx.cpp
+    These files are used to build a precompiled header (PCH) file
+    named wmpa.pch and a precompiled types file named StdAfx.obj.
+
+Resource.h
+    This is the standard header file, which defines new resource IDs.
+    Microsoft Visual C++ reads and updates this file.
+
+/////////////////////////////////////////////////////////////////////////////
+Other notes:
+
+AppWizard uses "TODO:" to indicate parts of the source code you
+should add to or customize.
+
+/////////////////////////////////////////////////////////////////////////////
diff --git a/plugins/wmpa/StdAfx.cpp b/plugins/wmpa/StdAfx.cpp
new file mode 100644
index 00000000..ae3c5313
--- /dev/null
+++ b/plugins/wmpa/StdAfx.cpp
@@ -0,0 +1,8 @@
+// stdafx.cpp : source file that includes just the standard includes
+//	wmpa.pch will be the pre-compiled header
+//	stdafx.obj will contain the pre-compiled type information
+
+#include "stdafx.h"
+
+
+
diff --git a/plugins/wmpa/StdAfx.h b/plugins/wmpa/StdAfx.h
new file mode 100644
index 00000000..f88a91f3
--- /dev/null
+++ b/plugins/wmpa/StdAfx.h
@@ -0,0 +1,62 @@
+// stdafx.h : include file for standard system include files,
+//  or project specific include files that are used frequently, but
+//      are changed infrequently
+//
+
+#if !defined(AFX_STDAFX_H__33D7BD1A_A9B6_4BDE_B867_5278529B95B2__INCLUDED_)
+#define AFX_STDAFX_H__33D7BD1A_A9B6_4BDE_B867_5278529B95B2__INCLUDED_
+
+#if _MSC_VER > 1000
+#pragma once
+#endif // _MSC_VER > 1000
+
+#define VC_EXTRALEAN		// Exclude rarely-used stuff from Windows headers
+
+#include <afxwin.h>         // MFC core and standard components
+#include <afxext.h>         // MFC extensions
+
+#ifndef _AFX_NO_OLE_SUPPORT
+#include <afxole.h>         // MFC OLE classes
+#include <afxodlgs.h>       // MFC OLE dialog classes
+#include <afxdisp.h>        // MFC Automation classes
+#endif // _AFX_NO_OLE_SUPPORT
+
+
+#ifndef _AFX_NO_DB_SUPPORT
+#include <afxdb.h>			// MFC ODBC database classes
+#endif // _AFX_NO_DB_SUPPORT
+
+#ifndef _AFX_NO_DAO_SUPPORT
+#include <afxdao.h>			// MFC DAO database classes
+#endif // _AFX_NO_DAO_SUPPORT
+
+#include <afxdtctl.h>		// MFC support for Internet Explorer 4 Common Controls
+#ifndef _AFX_NO_AFXCMN_SUPPORT
+#include <afxcmn.h>			// MFC support for Windows Common Controls
+#endif // _AFX_NO_AFXCMN_SUPPORT
+
+/******************************************************************
+* Includes
+******************************************************************/
+#include "wmpcdrom.h"
+#include "wmpcdromcollection.h"
+#include "wmpclosedcaption.h"
+#include "wmpcontrols.h"
+#include "wmpdvd.h"
+#include "wmperror.h"
+#include "wmperroritem.h"
+#include "wmpmedia.h"
+#include "wmpmediacollection.h"
+#include "wmpnetwork.h"
+#include "wmpplayer4.h"
+#include "wmpplayerapplication.h"
+#include "wmpplaylist.h"
+#include "wmpplaylistarray.h"
+#include "wmpplaylistcollection.h"
+#include "wmpsettings.h"
+#include "wmpstringcollection.h"
+
+//{{AFX_INSERT_LOCATION}}
+// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
+
+#endif // !defined(AFX_STDAFX_H__33D7BD1A_A9B6_4BDE_B867_5278529B95B2__INCLUDED_)
diff --git a/plugins/wmpa/res/wmpa.rc2 b/plugins/wmpa/res/wmpa.rc2
new file mode 100644
index 00000000..a45caf5c
--- /dev/null
+++ b/plugins/wmpa/res/wmpa.rc2
@@ -0,0 +1,13 @@
+//
+// WMPA.RC2 - resources Microsoft Visual C++ does not edit directly
+//
+
+#ifdef APSTUDIO_INVOKED
+	#error this file is not editable by Microsoft Visual C++
+#endif //APSTUDIO_INVOKED
+
+
+/////////////////////////////////////////////////////////////////////////////
+// Add manually edited resources here...
+
+/////////////////////////////////////////////////////////////////////////////
diff --git a/plugins/wmpa/resource.h b/plugins/wmpa/resource.h
new file mode 100644
index 00000000..0ce93a4c
--- /dev/null
+++ b/plugins/wmpa/resource.h
@@ -0,0 +1,22 @@
+//{{NO_DEPENDENCIES}}
+// Microsoft Developer Studio generated include file.
+// Used by wmpa.rc
+//
+#define IDD_WMPADIALOG                  2000
+#define IDC_PLAYLIST                    2001
+#define IDC_STATIC1                     2002
+#define IDC_WMP                         2005
+#define IDI_XCHAT                       2005
+#define IDC_SONGLIST                    2006
+#define IDC_STATIC2                     2007
+
+// Next default values for new objects
+// 
+#ifdef APSTUDIO_INVOKED
+#ifndef APSTUDIO_READONLY_SYMBOLS
+#define _APS_NEXT_RESOURCE_VALUE        2006
+#define _APS_NEXT_COMMAND_VALUE         32771
+#define _APS_NEXT_CONTROL_VALUE         2008
+#define _APS_NEXT_SYMED_VALUE           2000
+#endif
+#endif
diff --git a/plugins/wmpa/wmpa.clw b/plugins/wmpa/wmpa.clw
new file mode 100644
index 00000000..6d850e3e
--- /dev/null
+++ b/plugins/wmpa/wmpa.clw
@@ -0,0 +1,43 @@
+; CLW file contains information for the MFC ClassWizard
+
+[General Info]
+Version=1
+ODLFile=wmpa.odl
+ClassCount=2
+Class1=CWmpaApp
+LastClass=CWMPADialog
+NewFileInclude2=#include "wmpa.h"
+ResourceCount=1
+NewFileInclude1=#include "stdafx.h"
+Class2=CWMPADialog
+LastTemplate=CDialog
+Resource1=IDD_WMPADIALOG
+
+[CLS:CWmpaApp]
+Type=0
+HeaderFile=wmpa.h
+ImplementationFile=wmpa.cpp
+Filter=N
+LastObject=CWmpaApp
+BaseClass=CWinApp
+VirtualFilter=AC
+
+[DLG:IDD_WMPADIALOG]
+Type=1
+Class=CWMPADialog
+ControlCount=5
+Control1=IDC_PLAYLIST,listbox,1353777409
+Control2=IDC_STATIC1,static,1342308352
+Control3=IDC_WMP,{6BF52A52-394A-11D3-B153-00C04F79FAA6},1342242816
+Control4=IDC_SONGLIST,listbox,1352728833
+Control5=IDC_STATIC2,static,1342308352
+
+[CLS:CWMPADialog]
+Type=0
+HeaderFile=wmpadialog.h
+ImplementationFile=wmpadialog.cpp
+BaseClass=CDialog
+LastObject=CWMPADialog
+Filter=D
+VirtualFilter=dWC
+
diff --git a/plugins/wmpa/wmpa.cpp b/plugins/wmpa/wmpa.cpp
new file mode 100644
index 00000000..d9488f6d
--- /dev/null
+++ b/plugins/wmpa/wmpa.cpp
@@ -0,0 +1,212 @@
+/******************************************************************
+* $Id$
+*
+* $Log$
+*
+* Copyright � 2005 David Cullen, All rights reserved
+*
+******************************************************************/
+#include "stdafx.h"
+#include "wmpa.h"
+#include "WMPADialog.h"
+
+#ifdef _DEBUG
+#define new DEBUG_NEW
+#undef THIS_FILE
+static char THIS_FILE[] = __FILE__;
+#endif
+
+//
+//	Note!
+//
+//		If this DLL is dynamically linked against the MFC
+//		DLLs, any functions exported from this DLL which
+//		call into MFC must have the AFX_MANAGE_STATE macro
+//		added at the very beginning of the function.
+//
+//		For example:
+//
+//		extern "C" BOOL PASCAL EXPORT ExportedFunction()
+//		{
+//			AFX_MANAGE_STATE(AfxGetStaticModuleState());
+//			// normal function body here
+//		}
+//
+//		It is very important that this macro appear in each
+//		function, prior to any calls into MFC.  This means that
+//		it must appear as the first statement within the
+//		function, even before any object variable declarations
+//		as their constructors may generate calls into the MFC
+//		DLL.
+//
+//		Please see MFC Technical Notes 33 and 58 for additional
+//		details.
+//
+
+/////////////////////////////////////////////////////////////////////////////
+// CWmpaApp
+
+BEGIN_MESSAGE_MAP(CWmpaApp, CWinApp)
+	//{{AFX_MSG_MAP(CWmpaApp)
+		// NOTE - the ClassWizard will add and remove mapping macros here.
+		//    DO NOT EDIT what you see in these blocks of generated code!
+	//}}AFX_MSG_MAP
+END_MESSAGE_MAP()
+
+/////////////////////////////////////////////////////////////////////////////
+// CWmpaApp construction
+
+CWmpaApp::CWmpaApp()
+{
+	// TODO: add construction code here,
+	// Place all significant initialization in InitInstance
+   m_pDialog = NULL;
+}
+
+/////////////////////////////////////////////////////////////////////////////
+// The one and only CWmpaApp object
+
+CWmpaApp theApp;
+
+/////////////////////////////////////////////////////////////////////////////
+// CWmpaApp initialization
+
+BOOL CWmpaApp::InitInstance()
+{
+	// Register all OLE server (factories) as running.  This enables the
+	//  OLE libraries to create objects from other applications.
+	COleObjectFactory::RegisterAll();
+
+   // WARNING: This function enables the ActiveX control container
+   // Without this function you will not be able to load the WMP
+   // In fact you will get the following error:
+   // >>> If this dialog has OLE controls:
+   // >>> AfxEnableControlContainer has not been called yet.
+   // >>> You should call it in your app's InitInstance function.
+   AfxEnableControlContainer();
+
+   // WARNING: This function initializes the COM library for use
+   // Without this function you will not be able to load the WMP
+   // In fact you will get the following error:
+   // CoCreateInstance of OLE control {6BF52A52-394A-11D3-B153-00C04F79FAA6} failed.
+   // >>> Result code: 0x800401f0
+   // >>> Is the control is properly registered?
+   // The Error Lookup tool will tell you result code 0x800401F0 means
+   // CoInitialize has not been called.
+   CoInitialize(NULL);
+
+   return TRUE;
+}
+
+/******************************************************************
+* ShowWMPA
+******************************************************************/
+BOOL CWmpaApp::ShowWMPA(void)
+{
+   HRESULT result = FALSE;
+   BOOL created;
+
+   // WARNING: The following two funcions make sure we look for
+   // our resources in our DLL not in the calling EXE
+   // Without these functions you will not be able to load the
+   // Windows Media Player
+   HMODULE hModule = GetModuleHandle("WMPA.DLL");
+   AfxSetResourceHandle((HINSTANCE) hModule);
+
+   if (m_pDialog == NULL) m_pDialog = new CWMPADialog;
+
+   created = m_pDialog->Create(IDD_WMPADIALOG, m_pDialog);
+   if (!created) return(E_FAIL);
+   m_pDialog->m_hIcon = LoadIcon(IDI_XCHAT);
+   m_pDialog->SetIcon(m_pDialog->m_hIcon, TRUE);
+
+   result = m_pDialog->ShowWindow(SW_SHOWNORMAL);
+
+   return(created);
+}
+
+/////////////////////////////////////////////////////////////////////////////
+// Special entry points required for inproc servers
+
+STDAPI DllGetClassObject(REFCLSID rclsid, REFIID riid, LPVOID* ppv)
+{
+	AFX_MANAGE_STATE(AfxGetStaticModuleState());
+	return AfxDllGetClassObject(rclsid, riid, ppv);
+}
+
+STDAPI DllCanUnloadNow(void)
+{
+	AFX_MANAGE_STATE(AfxGetStaticModuleState());
+	return AfxDllCanUnloadNow();
+}
+
+// by exporting DllRegisterServer, you can use regsvr.exe
+STDAPI DllRegisterServer(void)
+{
+	AFX_MANAGE_STATE(AfxGetStaticModuleState());
+	COleObjectFactory::UpdateRegistryAll();
+   return(S_OK);
+}
+
+/******************************************************************
+* DestroyWMPA
+******************************************************************/
+BOOL CWmpaApp::DestroyWMPA(void)
+{
+   if (theApp.m_pDialog == NULL) return(FALSE);
+
+   theApp.m_pDialog->m_WMP.GetControls().stop();
+   theApp.m_pDialog->DeleteTrayIcon();
+   theApp.m_pDialog->DestroyWindow();
+
+   return(TRUE);
+}
+
+/******************************************************************
+* StartWindowsMediaPlayer
+******************************************************************/
+BOOL StartWindowsMediaPlayer(void)
+{
+	AFX_MANAGE_STATE(AfxGetStaticModuleState());
+
+   BOOL result = theApp.ShowWMPA();
+
+   return(result);
+}
+
+/******************************************************************
+* StopWindowsMediaPlayer
+******************************************************************/
+BOOL StopWindowsMediaPlayer(void)
+{
+	AFX_MANAGE_STATE(AfxGetStaticModuleState());
+
+   BOOL result = theApp.DestroyWMPA();
+
+   return(result);
+}
+
+/******************************************************************
+* GetWindowsMediaPlayer
+******************************************************************/
+CWMPPlayer4 *GetWindowsMediaPlayer(void)
+{
+	AFX_MANAGE_STATE(AfxGetStaticModuleState());
+
+   if (theApp.m_pDialog == NULL) return(NULL);
+
+	return(&(theApp.m_pDialog->m_WMP));
+}
+
+/******************************************************************
+* GetWMPADialog
+******************************************************************/
+CWMPADialog *GetWMPADialog(void)
+{
+	AFX_MANAGE_STATE(AfxGetStaticModuleState());
+
+   if (theApp.m_pDialog == NULL) return(NULL);
+
+	return(theApp.m_pDialog);
+}
+
diff --git a/plugins/wmpa/wmpa.def b/plugins/wmpa/wmpa.def
new file mode 100644
index 00000000..d3162b7d
--- /dev/null
+++ b/plugins/wmpa/wmpa.def
@@ -0,0 +1,16 @@
+; wmpa.def : Declares the module parameters for the DLL.
+
+LIBRARY      "wmpa"
+DESCRIPTION  'wmpa Windows Dynamic Link Library'
+
+EXPORTS
+    ; Explicit exports can go here
+    DllCanUnloadNow PRIVATE
+    DllGetClassObject PRIVATE
+    DllRegisterServer PRIVATE
+    xchat_plugin_init
+    xchat_plugin_deinit
+    xchat_plugin_get_info
+    StartWindowsMediaPlayer
+    GetWindowsMediaPlayer
+    GetWMPADialog
diff --git a/plugins/wmpa/wmpa.dsp b/plugins/wmpa/wmpa.dsp
new file mode 100644
index 00000000..6f2e7458
--- /dev/null
+++ b/plugins/wmpa/wmpa.dsp
@@ -0,0 +1,421 @@
+# Microsoft Developer Studio Project File - Name="wmpa" - Package Owner=<4>
+# Microsoft Developer Studio Generated Build File, Format Version 6.00
+# ** DO NOT EDIT **
+
+# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
+
+CFG=wmpa - Win32 Debug
+!MESSAGE This is not a valid makefile. To build this project using NMAKE,
+!MESSAGE use the Export Makefile command and run
+!MESSAGE 
+!MESSAGE NMAKE /f "wmpa.mak".
+!MESSAGE 
+!MESSAGE You can specify a configuration when running NMAKE
+!MESSAGE by defining the macro CFG on the command line. For example:
+!MESSAGE 
+!MESSAGE NMAKE /f "wmpa.mak" CFG="wmpa - Win32 Debug"
+!MESSAGE 
+!MESSAGE Possible choices for configuration are:
+!MESSAGE 
+!MESSAGE "wmpa - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library")
+!MESSAGE "wmpa - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library")
+!MESSAGE 
+
+# Begin Project
+# PROP AllowPerConfigDependencies 0
+# PROP Scc_ProjName ""
+# PROP Scc_LocalPath ""
+CPP=cl.exe
+MTL=midl.exe
+RSC=rc.exe
+
+!IF  "$(CFG)" == "wmpa - Win32 Release"
+
+# PROP BASE Use_MFC 6
+# PROP BASE Use_Debug_Libraries 0
+# PROP BASE Output_Dir "Release"
+# PROP BASE Intermediate_Dir "Release"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 6
+# PROP Use_Debug_Libraries 0
+# PROP Output_Dir "Release"
+# PROP Intermediate_Dir "Release"
+# PROP Ignore_Export_Lib 0
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /MD /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_WINDLL" /D "_AFXDLL" /Yu"stdafx.h" /FD /c
+# ADD CPP /nologo /MD /W3 /GX /O2 /I "C:\Program Files\Microsoft Platform SDK\Include" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_WINDLL" /D "_AFXDLL" /D "_MBCS" /D "_USRDLL" /Yu"stdafx.h" /FD /c
+# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
+# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
+# ADD BASE RSC /l 0x409 /d "NDEBUG" /d "_AFXDLL"
+# ADD RSC /l 0x409 /d "NDEBUG" /d "_AFXDLL"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# ADD BSC32 /nologo
+LINK32=link.exe
+# ADD BASE LINK32 /nologo /subsystem:windows /dll /machine:I386
+# ADD LINK32 /nologo /subsystem:windows /dll /machine:I386
+# Begin Custom Build
+InputPath=.\Release\wmpa.dll
+InputName=wmpa
+SOURCE="$(InputPath)"
+
+"C:\msys\1.0\local\src\xchat\src\fe-gtk\plugins\$(InputName).dll" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+	copy /Y $(InputPath) "C:\msys\1.0\local\src\xchat\src\fe-gtk\plugins\$(InputName).dll"
+
+# End Custom Build
+
+!ELSEIF  "$(CFG)" == "wmpa - Win32 Debug"
+
+# PROP BASE Use_MFC 6
+# PROP BASE Use_Debug_Libraries 1
+# PROP BASE Output_Dir "Debug"
+# PROP BASE Intermediate_Dir "Debug"
+# PROP BASE Target_Dir ""
+# PROP Use_MFC 6
+# PROP Use_Debug_Libraries 1
+# PROP Output_Dir "Debug"
+# PROP Intermediate_Dir "Debug"
+# PROP Ignore_Export_Lib 0
+# PROP Target_Dir ""
+# ADD BASE CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_WINDLL" /D "_AFXDLL" /Yu"stdafx.h" /FD /GZ /c
+# ADD CPP /nologo /MDd /W4 /Gm /GX /ZI /Od /I "C:\Program Files\Microsoft Platform SDK\Include" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_WINDLL" /D "_AFXDLL" /D "_MBCS" /D "_USRDLL" /FR /Yu"stdafx.h" /FD /GZ /c
+# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
+# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
+# ADD BASE RSC /l 0x409 /d "_DEBUG" /d "_AFXDLL"
+# ADD RSC /l 0x409 /d "_DEBUG" /d "_AFXDLL"
+BSC32=bscmake.exe
+# ADD BASE BSC32 /nologo
+# ADD BSC32 /nologo
+LINK32=link.exe
+# ADD BASE LINK32 /nologo /subsystem:windows /dll /debug /machine:I386 /pdbtype:sept
+# ADD LINK32 /nologo /subsystem:windows /dll /debug /machine:I386 /pdbtype:sept
+# Begin Custom Build
+InputPath=.\Debug\wmpa.dll
+InputName=wmpa
+SOURCE="$(InputPath)"
+
+"C:\msys\1.0\local\src\xchat\src\fe-gtk\plugins\$(InputName).dll" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
+	copy /Y $(InputPath) "C:\msys\1.0\local\src\xchat\src\fe-gtk\plugins\$(InputName).dll"
+
+# End Custom Build
+
+!ENDIF 
+
+# Begin Target
+
+# Name "wmpa - Win32 Release"
+# Name "wmpa - Win32 Debug"
+# Begin Group "Source Files"
+
+# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
+# Begin Source File
+
+SOURCE=.\StdAfx.cpp
+# ADD CPP /Yc"stdafx.h"
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpa.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpa.def
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpa.odl
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpa.rc
+# End Source File
+# Begin Source File
+
+SOURCE=.\WMPADialog.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpcdrom.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpcdromcollection.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpclosedcaption.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpcontrols.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpdvd.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmperror.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmperroritem.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpmedia.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpmediacollection.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpnetwork.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpplayer4.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpplayerapplication.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpplaylist.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpplaylistarray.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpplaylistcollection.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpsettings.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpstringcollection.cpp
+# End Source File
+# Begin Source File
+
+SOURCE=".\xchat-plugin.cpp"
+# End Source File
+# End Group
+# Begin Group "Header Files"
+
+# PROP Default_Filter "h;hpp;hxx;hm;inl"
+# Begin Source File
+
+SOURCE=.\Resource.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\StdAfx.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpa.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\WMPADIALOG.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpcdrom.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpcdromcollection.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpclosedcaption.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpcontrols.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpdvd.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmperror.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmperroritem.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpmedia.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpmediacollection.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpnetwork.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpplayer4.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpplayerapplication.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpplaylist.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpplaylistarray.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpplaylistcollection.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpsettings.h
+# End Source File
+# Begin Source File
+
+SOURCE=.\wmpstringcollection.h
+# End Source File
+# Begin Source File
+
+SOURCE=".\xchat-plugin.h"
+# End Source File
+# End Group
+# Begin Group "Resource Files"
+
+# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
+# Begin Source File
+
+SOURCE=.\res\wmpa.rc2
+# End Source File
+# Begin Source File
+
+SOURCE=.\xchat.ico
+# End Source File
+# End Group
+# Begin Source File
+
+SOURCE=.\ReadMe.txt
+# End Source File
+# End Target
+# End Project
+# Section wmpa : {10A13217-23A7-439B-B1C0-D847C79B7774}
+# 	2:5:Class:CWMPPlaylistCollection
+# 	2:10:HeaderFile:wmpplaylistcollection.h
+# 	2:8:ImplFile:wmpplaylistcollection.cpp
+# End Section
+# Section wmpa : {EC21B779-EDEF-462D-BBA4-AD9DDE2B29A7}
+# 	2:5:Class:CWMPNetwork
+# 	2:10:HeaderFile:wmpnetwork.h
+# 	2:8:ImplFile:wmpnetwork.cpp
+# End Section
+# Section wmpa : {4A976298-8C0D-11D3-B389-00C04F68574B}
+# 	2:5:Class:CWMPStringCollection
+# 	2:10:HeaderFile:wmpstringcollection.h
+# 	2:8:ImplFile:wmpstringcollection.cpp
+# End Section
+# Section wmpa : {B7ABC220-DF71-11CF-8E74-00A0C90F26F8}
+# 	2:5:Class:Cmci
+# 	2:10:HeaderFile:mci.h
+# 	2:8:ImplFile:mci.cpp
+# End Section
+# Section wmpa : {8363BC22-B4B4-4B19-989D-1CD765749DD1}
+# 	2:5:Class:CWMPMediaCollection
+# 	2:10:HeaderFile:wmpmediacollection.h
+# 	2:8:ImplFile:wmpmediacollection.cpp
+# End Section
+# Section wmpa : {679409C0-99F7-11D3-9FB7-00105AA620BB}
+# 	2:5:Class:CWMPPlaylistArray
+# 	2:10:HeaderFile:wmpplaylistarray.h
+# 	2:8:ImplFile:wmpplaylistarray.cpp
+# End Section
+# Section wmpa : {74C09E02-F828-11D2-A74B-00A0C905F36E}
+# 	2:5:Class:CWMPControls
+# 	2:10:HeaderFile:wmpcontrols.h
+# 	2:8:ImplFile:wmpcontrols.cpp
+# End Section
+# Section wmpa : {CFAB6E98-8730-11D3-B388-00C04F68574B}
+# 	2:5:Class:CWMPCdrom
+# 	2:10:HeaderFile:wmpcdrom.h
+# 	2:8:ImplFile:wmpcdrom.cpp
+# End Section
+# Section wmpa : {8DA61686-4668-4A5C-AE5D-803193293DBE}
+# 	2:5:Class:CWMPDVD
+# 	2:10:HeaderFile:wmpdvd.h
+# 	2:8:ImplFile:wmpdvd.cpp
+# End Section
+# Section wmpa : {6C497D62-8919-413C-82DB-E935FB3EC584}
+# 	2:5:Class:CWMPPlayer4
+# 	2:10:HeaderFile:wmpplayer4.h
+# 	2:8:ImplFile:wmpplayer4.cpp
+# End Section
+# Section wmpa : {40897764-CEAB-47BE-AD4A-8E28537F9BBF}
+# 	2:5:Class:CWMPPlayerApplication
+# 	2:10:HeaderFile:wmpplayerapplication.h
+# 	2:8:ImplFile:wmpplayerapplication.cpp
+# End Section
+# Section wmpa : {6BF52A52-394A-11D3-B153-00C04F79FAA6}
+# 	2:21:DefaultSinkHeaderFile:wmpplayer4.h
+# 	2:16:DefaultSinkClass:CWMPPlayer4
+# End Section
+# Section wmpa : {C1A8AF25-1257-101B-8FB0-0020AF039CA3}
+# 	2:21:DefaultSinkHeaderFile:mci.h
+# 	2:16:DefaultSinkClass:Cmci
+# End Section
+# Section wmpa : {9104D1AB-80C9-4FED-ABF0-2E6417A6DF14}
+# 	2:5:Class:CWMPSettings
+# 	2:10:HeaderFile:wmpsettings.h
+# 	2:8:ImplFile:wmpsettings.cpp
+# End Section
+# Section wmpa : {A12DCF7D-14AB-4C1B-A8CD-63909F06025B}
+# 	2:5:Class:CWMPError
+# 	2:10:HeaderFile:wmperror.h
+# 	2:8:ImplFile:wmperror.cpp
+# End Section
+# Section wmpa : {7BF80981-BF32-101A-8BBB-00AA00300CAB}
+# 	2:5:Class:CPicture
+# 	2:10:HeaderFile:picture.h
+# 	2:8:ImplFile:picture.cpp
+# End Section
+# Section wmpa : {D5F0F4F1-130C-11D3-B14E-00C04F79FAA6}
+# 	2:5:Class:CWMPPlaylist
+# 	2:10:HeaderFile:wmpplaylist.h
+# 	2:8:ImplFile:wmpplaylist.cpp
+# End Section
+# Section wmpa : {EE4C8FE2-34B2-11D3-A3BF-006097C9B344}
+# 	2:5:Class:CWMPCdromCollection
+# 	2:10:HeaderFile:wmpcdromcollection.h
+# 	2:8:ImplFile:wmpcdromcollection.cpp
+# End Section
+# Section wmpa : {4F2DF574-C588-11D3-9ED0-00C04FB6E937}
+# 	2:5:Class:CWMPClosedCaption
+# 	2:10:HeaderFile:wmpclosedcaption.h
+# 	2:8:ImplFile:wmpclosedcaption.cpp
+# End Section
+# Section wmpa : {94D55E95-3FAC-11D3-B155-00C04F79FAA6}
+# 	2:5:Class:CWMPMedia
+# 	2:10:HeaderFile:wmpmedia.h
+# 	2:8:ImplFile:wmpmedia.cpp
+# End Section
+# Section wmpa : {3614C646-3B3B-4DE7-A81E-930E3F2127B3}
+# 	2:5:Class:CWMPErrorItem
+# 	2:10:HeaderFile:wmperroritem.h
+# 	2:8:ImplFile:wmperroritem.cpp
+# End Section
diff --git a/plugins/wmpa/wmpa.dsw b/plugins/wmpa/wmpa.dsw
new file mode 100644
index 00000000..e0098b15
--- /dev/null
+++ b/plugins/wmpa/wmpa.dsw
@@ -0,0 +1,31 @@
+Microsoft Developer Studio Workspace File, Format Version 6.00
+# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!
+
+###############################################################################
+
+Project: "wmpa"=".\wmpa.dsp" - Package Owner=<4>
+
+Package=<5>
+{{{
+}}}
+
+Package=<4>
+{{{
+}}}
+
+###############################################################################
+
+Global:
+
+Package=<5>
+{{{
+}}}
+
+Package=<3>
+{{{
+    {6BF52A52-394A-11D3-B153-00C04F79FAA6}
+    {C1A8AF25-1257-101B-8FB0-0020AF039CA3}
+}}}
+
+###############################################################################
+
diff --git a/plugins/wmpa/wmpa.h b/plugins/wmpa/wmpa.h
new file mode 100644
index 00000000..39961835
--- /dev/null
+++ b/plugins/wmpa/wmpa.h
@@ -0,0 +1,61 @@
+/******************************************************************
+* $Id$
+*
+* $Log$
+*
+* Copyright � 2005 David Cullen, All rights reserved
+*
+******************************************************************/
+#if !defined(AFX_WMPA_H__11200FE3_F137_48DD_8020_91CF7BBB283B__INCLUDED_)
+#define AFX_WMPA_H__11200FE3_F137_48DD_8020_91CF7BBB283B__INCLUDED_
+
+#if _MSC_VER > 1000
+#pragma once
+#endif // _MSC_VER > 1000
+
+#ifndef __AFXWIN_H__
+	#error include 'stdafx.h' before including this file for PCH
+#endif
+
+#include "resource.h"		// main symbols
+#include "WMPADialog.h"
+
+/////////////////////////////////////////////////////////////////////////////
+// CWmpaApp
+// See wmpa.cpp for the implementation of this class
+//
+
+class CWmpaApp : public CWinApp
+{
+public:
+	CWmpaApp();
+
+   BOOL ShowWMPA(void);
+   BOOL DestroyWMPA(void);
+
+   CWMPADialog *m_pDialog;
+// Overrides
+	// ClassWizard generated virtual function overrides
+	//{{AFX_VIRTUAL(CWmpaApp)
+	public:
+	virtual BOOL InitInstance();
+	//}}AFX_VIRTUAL
+
+	//{{AFX_MSG(CWmpaApp)
+		// NOTE - the ClassWizard will add and remove member functions here.
+		//    DO NOT EDIT what you see in these blocks of generated code !
+	//}}AFX_MSG
+	DECLARE_MESSAGE_MAP()
+};
+
+BOOL StartWindowsMediaPlayer(void);
+BOOL StopWindowsMediaPlayer(void);
+CWMPPlayer4 *GetWindowsMediaPlayer(void);
+CWMPADialog *GetWMPADialog(void);
+
+/////////////////////////////////////////////////////////////////////////////
+
+//{{AFX_INSERT_LOCATION}}
+// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
+
+#endif // !defined(AFX_WMPA_H__11200FE3_F137_48DD_8020_91CF7BBB283B__INCLUDED_)
diff --git a/plugins/wmpa/wmpa.odl b/plugins/wmpa/wmpa.odl
new file mode 100644
index 00000000..1c354c34
--- /dev/null
+++ b/plugins/wmpa/wmpa.odl
@@ -0,0 +1,44 @@
+// wmpa.odl : type library source for wmpa.dll
+
+// This file will be processed by the MIDL compiler to produce the
+// type library (wmpa.tlb).
+
+[ uuid(2D225385-EFD3-4DD8-9377-A7F244C522D0), version(1.0) ]
+library Wmpa
+{
+	importlib("stdole32.tlb");
+	importlib("stdole2.tlb");
+
+
+
+
+	//  Primary dispatch interface for CWMPADIALOG
+	
+	[ uuid(01C1B3AA-C7FC-4023-89A5-C814E1B62B9B) ]
+	dispinterface IWMPADIALOG
+	{
+		properties:
+			// NOTE - ClassWizard will maintain property information here.
+			//    Use extreme caution when editing this section.
+			//{{AFX_ODL_PROP(CWMPADIALOG)
+			//}}AFX_ODL_PROP
+			
+		methods:
+			// NOTE - ClassWizard will maintain method information here.
+			//    Use extreme caution when editing this section.
+			//{{AFX_ODL_METHOD(CWMPADIALOG)
+			//}}AFX_ODL_METHOD
+
+	};
+
+	//  Class information for CWMPADIALOG
+
+	[ uuid(9007B1B4-0006-453D-A799-DB8CBA1AE22A) ]
+	coclass WMPADIALOG
+	{
+		[default] dispinterface IWMPADIALOG;
+	};
+
+	//{{AFX_APPEND_ODL}}
+	//}}AFX_APPEND_ODL}}
+};
diff --git a/plugins/wmpa/wmpa.plg b/plugins/wmpa/wmpa.plg
new file mode 100644
index 00000000..a1b967ae
--- /dev/null
+++ b/plugins/wmpa/wmpa.plg
@@ -0,0 +1,16 @@
+<html>
+<body>
+<pre>
+<h1>Build Log</h1>
+<h3>
+--------------------Configuration: wmpa - Win32 Release--------------------
+</h3>
+<h3>Command Lines</h3>
+
+
+
+<h3>Results</h3>
+wmpa.dll - 0 error(s), 0 warning(s)
+</pre>
+</body>
+</html>
diff --git a/plugins/wmpa/wmpa.rc b/plugins/wmpa/wmpa.rc
new file mode 100644
index 00000000..367805a5
--- /dev/null
+++ b/plugins/wmpa/wmpa.rc
@@ -0,0 +1,204 @@
+//Microsoft Developer Studio generated resource script.
+//
+#include "resource.h"
+
+#define APSTUDIO_READONLY_SYMBOLS
+/////////////////////////////////////////////////////////////////////////////
+//
+// Generated from the TEXTINCLUDE 2 resource.
+//
+#include "afxres.h"
+
+/////////////////////////////////////////////////////////////////////////////
+#undef APSTUDIO_READONLY_SYMBOLS
+
+/////////////////////////////////////////////////////////////////////////////
+// English (U.S.) resources
+
+#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
+#ifdef _WIN32
+LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
+#pragma code_page(1252)
+#endif //_WIN32
+
+#ifdef APSTUDIO_INVOKED
+/////////////////////////////////////////////////////////////////////////////
+//
+// TEXTINCLUDE
+//
+
+1 TEXTINCLUDE DISCARDABLE 
+BEGIN
+    "resource.h\0"
+END
+
+2 TEXTINCLUDE DISCARDABLE 
+BEGIN
+    "#include ""afxres.h""\r\n"
+    "\0"
+END
+
+3 TEXTINCLUDE DISCARDABLE 
+BEGIN
+    "#define _AFX_NO_SPLITTER_RESOURCES\r\n"
+    "#define _AFX_NO_OLE_RESOURCES\r\n"
+    "#define _AFX_NO_TRACKER_RESOURCES\r\n"
+    "#define _AFX_NO_PROPERTY_RESOURCES\r\n"
+    "\r\n"
+    "#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)\r\n"
+    "#ifdef _WIN32\r\n"
+    "LANGUAGE 9, 1\r\n"
+    "#pragma code_page(1252)\r\n"
+    "#endif //_WIN32\r\n"
+    "#include ""res\\wmpa.rc2""  // non-Microsoft Visual C++ edited resources\r\n"
+    "#include ""afxres.rc""         // Standard components\r\n"
+    "#endif\r\n"
+    "\0"
+END
+
+#endif    // APSTUDIO_INVOKED
+
+
+#ifndef _MAC
+/////////////////////////////////////////////////////////////////////////////
+//
+// Version
+//
+
+VS_VERSION_INFO VERSIONINFO
+ FILEVERSION 1,0,0,1
+ PRODUCTVERSION 1,0,0,1
+ FILEFLAGSMASK 0x3fL
+#ifdef _DEBUG
+ FILEFLAGS 0x1L
+#else
+ FILEFLAGS 0x0L
+#endif
+ FILEOS 0x4L
+ FILETYPE 0x2L
+ FILESUBTYPE 0x0L
+BEGIN
+    BLOCK "StringFileInfo"
+    BEGIN
+        BLOCK "040904B0"
+        BEGIN
+            VALUE "CompanyName", "\0"
+            VALUE "FileDescription", "wmpa DLL\0"
+            VALUE "FileVersion", "1, 0, 0, 1\0"
+            VALUE "InternalName", "wmpa\0"
+            VALUE "LegalCopyright", "Copyright (C) 2005\0"
+            VALUE "LegalTrademarks", "\0"
+            VALUE "OriginalFilename", "wmpa.DLL\0"
+            VALUE "ProductName", "wmpa Dynamic Link Library\0"
+            VALUE "ProductVersion", "1, 0, 0, 1\0"
+            VALUE "OLESelfRegister", "\0"
+        END
+    END
+    BLOCK "VarFileInfo"
+    BEGIN
+        VALUE "Translation", 0x409, 1200
+    END
+END
+
+#endif    // !_MAC
+
+
+/////////////////////////////////////////////////////////////////////////////
+//
+// Dialog
+//
+
+IDD_WMPADIALOG DIALOG DISCARDABLE  0, 0, 317, 236
+STYLE DS_MODALFRAME | WS_MINIMIZEBOX | WS_POPUP | WS_CAPTION | WS_SYSMENU
+CAPTION "Unitialized"
+FONT 8, "MS Sans Serif"
+BEGIN
+    LISTBOX         IDC_PLAYLIST,165,15,145,145,LBS_NOINTEGRALHEIGHT | 
+                    WS_VSCROLL | WS_HSCROLL | WS_TABSTOP
+    LTEXT           "Play Lists (Double-click to play)",IDC_STATIC1,165,5,
+                    145,10
+    CONTROL         "",IDC_WMP,"{6BF52A52-394A-11D3-B153-00C04F79FAA6}",
+                    WS_TABSTOP,5,5,155,155
+    LISTBOX         IDC_SONGLIST,5,175,305,55,LBS_NOINTEGRALHEIGHT | 
+                    WS_VSCROLL | WS_TABSTOP
+    LTEXT           "Song List (Double-click to play)",IDC_STATIC2,5,165,305,
+                    10
+END
+
+
+/////////////////////////////////////////////////////////////////////////////
+//
+// DESIGNINFO
+//
+
+#ifdef APSTUDIO_INVOKED
+GUIDELINES DESIGNINFO DISCARDABLE 
+BEGIN
+    IDD_WMPADIALOG, DIALOG
+    BEGIN
+        LEFTMARGIN, 7
+        RIGHTMARGIN, 310
+        TOPMARGIN, 7
+        BOTTOMMARGIN, 229
+    END
+END
+#endif    // APSTUDIO_INVOKED
+
+
+/////////////////////////////////////////////////////////////////////////////
+//
+// Dialog Info
+//
+
+IDD_WMPADIALOG DLGINIT
+BEGIN
+    IDC_WMP, 0x376, 166, 0
+0x0000, 0x0000, 0x0300, 0x0000, 0x0008, 0x0000, 0x0000, 0x0005, 0x0000, 
+0x0000, 0x0000, 0x3ff0, 0x0003, 0x0000, 0x0000, 0x0005, 0x0000, 0x0000, 
+0x0000, 0x0000, 0x0008, 0x0002, 0x0000, 0x0000, 0x0003, 0x0001, 0x0000, 
+0x000b, 0xffff, 0x0003, 0x0000, 0x0000, 0x000b, 0xffff, 0x0008, 0x0002, 
+0x0000, 0x0000, 0x0003, 0x0032, 0x0000, 0x000b, 0x0000, 0x0008, 0x000a, 
+0x0000, 0x0066, 0x0075, 0x006c, 0x006c, 0x0000, 0x000b, 0x0000, 0x000b, 
+0x0000, 0x000b, 0xffff, 0x000b, 0xffff, 0x000b, 0x0000, 0x0008, 0x0002, 
+0x0000, 0x0000, 0x0008, 0x0002, 0x0000, 0x0000, 0x0008, 0x0002, 0x0000, 
+0x0000, 0x0008, 0x0002, 0x0000, 0x0000, 0x000b, 0x0000, 0x1815, 0x0000, 
+0x1a0c, 0x0000, 
+    0
+END
+
+
+/////////////////////////////////////////////////////////////////////////////
+//
+// Icon
+//
+
+// Icon with lowest ID value placed first to ensure application icon
+// remains consistent on all systems.
+IDI_XCHAT               ICON    DISCARDABLE     "xchat.ico"
+#endif    // English (U.S.) resources
+/////////////////////////////////////////////////////////////////////////////
+
+
+
+#ifndef APSTUDIO_INVOKED
+/////////////////////////////////////////////////////////////////////////////
+//
+// Generated from the TEXTINCLUDE 3 resource.
+//
+#define _AFX_NO_SPLITTER_RESOURCES
+#define _AFX_NO_OLE_RESOURCES
+#define _AFX_NO_TRACKER_RESOURCES
+#define _AFX_NO_PROPERTY_RESOURCES
+
+#if !defined(AFX_RESOURCE_DLL) || defined(AFX_TARG_ENU)
+#ifdef _WIN32
+LANGUAGE 9, 1
+#pragma code_page(1252)
+#endif //_WIN32
+#include "res\wmpa.rc2"  // non-Microsoft Visual C++ edited resources
+#include "afxres.rc"         // Standard components
+#endif
+
+/////////////////////////////////////////////////////////////////////////////
+#endif    // not APSTUDIO_INVOKED
+
diff --git a/plugins/wmpa/wmpadialog.cpp b/plugins/wmpa/wmpadialog.cpp
new file mode 100644
index 00000000..b0cdd16e
--- /dev/null
+++ b/plugins/wmpa/wmpadialog.cpp
@@ -0,0 +1,375 @@
+/******************************************************************
+* $Id$
+*
+* $Log$
+*
+* Copyright � 2005 David Cullen, All rights reserved
+*
+******************************************************************/
+#include "stdafx.h"
+#include "wmpa.h"
+#include "WMPADialog.h"
+#include "shellapi.h"
+#include "xchat-plugin.h"
+
+#ifdef _DEBUG
+#define new DEBUG_NEW
+#undef THIS_FILE
+static char THIS_FILE[] = __FILE__;
+#endif
+
+#define ID_TRAY_ICON    1000
+#define WM_TRAY_ICON    (WM_APP + 1)
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPADialog dialog
+
+CWMPADialog::CWMPADialog(CWnd* pParent /*=NULL*/)
+	: CDialog(CWMPADialog::IDD, pParent)
+{
+	EnableAutomation();
+
+	//{{AFX_DATA_INIT(CWMPADialog)
+	//}}AFX_DATA_INIT
+}
+
+
+void CWMPADialog::OnFinalRelease()
+{
+	// When the last reference for an automation object is released
+	// OnFinalRelease is called.  The base class will automatically
+	// deletes the object.  Add additional cleanup required for your
+	// object before calling the base class.
+
+	CDialog::OnFinalRelease();
+}
+
+void CWMPADialog::DoDataExchange(CDataExchange* pDX)
+{
+	CDialog::DoDataExchange(pDX);
+	//{{AFX_DATA_MAP(CWMPADialog)
+	DDX_Control(pDX, IDC_SONGLIST, m_SongListBox);
+	DDX_Control(pDX, IDC_PLAYLIST, m_PlaylistBox);
+	DDX_Control(pDX, IDC_WMP, m_WMP);
+	//}}AFX_DATA_MAP
+}
+
+
+BEGIN_MESSAGE_MAP(CWMPADialog, CDialog)
+	//{{AFX_MSG_MAP(CWMPADialog)
+	ON_LBN_DBLCLK(IDC_PLAYLIST, OnDblclkPlaylist)
+	ON_WM_SHOWWINDOW()
+	ON_WM_CLOSE()
+	ON_LBN_DBLCLK(IDC_SONGLIST, OnDblclkSonglist)
+	ON_WM_DESTROY()
+	ON_WM_SIZE()
+	//}}AFX_MSG_MAP
+END_MESSAGE_MAP()
+
+BEGIN_DISPATCH_MAP(CWMPADialog, CDialog)
+	//{{AFX_DISPATCH_MAP(CWMPADialog)
+		// NOTE - the ClassWizard will add and remove mapping macros here.
+	//}}AFX_DISPATCH_MAP
+END_DISPATCH_MAP()
+
+// Note: we add support for IID_IWMPADialog to support typesafe binding
+//  from VBA.  This IID must match the GUID that is attached to the
+//  dispinterface in the .ODL file.
+
+// {01C1B3AA-C7FC-4023-89A5-C814E1B62B9B}
+static const IID IID_IWMPADialog =
+{ 0x1c1b3aa, 0xc7fc, 0x4023, { 0x89, 0xa5, 0xc8, 0x14, 0xe1, 0xb6, 0x2b, 0x9b } };
+
+BEGIN_INTERFACE_MAP(CWMPADialog, CDialog)
+	INTERFACE_PART(CWMPADialog, IID_IWMPADialog, Dispatch)
+END_INTERFACE_MAP()
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPADialog message handlers
+
+void CWMPADialog::OnDblclkPlaylist()
+{
+	// TODO: Add your control notification handler code here
+   long index;
+
+   // Get the playlist name
+   index = m_PlaylistBox.GetCurSel();
+   CString playlistName;
+   m_PlaylistBox.GetText(index, playlistName);
+
+   // Get the playlist
+   CWMPPlaylistCollection pc = m_WMP.GetPlaylistCollection();
+   CWMPPlaylistArray pa = pc.getByName((LPCTSTR) playlistName);
+   CWMPPlaylist playlist = pa.Item(0);
+   m_WMP.SetCurrentPlaylist(playlist);
+
+   // Set the song list
+   UpdateSongList();
+
+   m_WMP.GetControls().play();
+   if (autoAnnounce) {
+      xchat_commandf(ph, "me is playing %s", (LPCTSTR) wmpaGetSongTitle());
+   }
+   else {
+      xchat_printf(ph, "WMPA: Playing %s", (LPCTSTR) wmpaGetSongTitle());
+   }
+}
+
+void CWMPADialog::OnShowWindow(BOOL bShow, UINT nStatus)
+{
+	CDialog::OnShowWindow(bShow, nStatus);
+	
+	// TODO: Add your message handler code here
+   if (bShow) {
+      if (!trayInit) {
+         ZeroMemory(&nid, sizeof(nid));
+         nid.cbSize = sizeof(nid);
+         nid.hWnd = m_hWnd;
+         nid.uID = ID_TRAY_ICON;
+         nid.uFlags = NIF_ICON | NIF_MESSAGE | NIF_TIP;
+         nid.uCallbackMessage = WM_TRAY_ICON;
+         nid.hIcon = m_hIcon;
+         strcpy(nid.szTip, "WMPA");
+         strcat(nid.szTip,  VER_STRING);
+         strcat(nid.szTip, "\nWindows Media\nPlayer Announcer");
+         nid.dwState = 0;
+         nid.dwStateMask = 0;
+         strcpy(nid.szInfo, "WMPA ");
+         strcat(nid.szInfo, VER_STRING);
+         nid.uTimeout = 10000; // 10 second time out
+         strcat(nid.szInfoTitle, "WMPA");
+         nid.dwInfoFlags = 0;
+         trayInit = TRUE;
+      }
+   }
+
+}
+
+
+void CWMPADialog::PostNcDestroy()
+{
+	// TODO: Add your specialized code here and/or call the base class
+   delete this;
+
+	CDialog::PostNcDestroy();
+}
+
+
+BOOL CWMPADialog::OnInitDialog()
+{
+	CDialog::OnInitDialog();
+
+   CString title = "WMPA";
+   title += " ";
+   title += VER_STRING;
+   SetWindowText((LPCTSTR) title);
+
+   UpdatePlayLists();
+
+   autoAnnounce = FALSE;
+   trayInit = FALSE;
+   trayClicked = FALSE;
+
+	return TRUE;  // return TRUE unless you set the focus to a control
+	              // EXCEPTION: OCX Property Pages should return FALSE
+}
+
+void CWMPADialog::OnClose()
+{
+	// TODO: Add your message handler code here and/or call default
+   Shell_NotifyIcon(NIM_ADD, &nid);
+   ShowWindow(SW_HIDE);
+
+   // Don't let the user close the dialog
+//   CDialog::OnClose();
+}
+
+void CWMPADialog::OnCancel()
+{
+//   this->DestroyWindow();
+}
+
+void CWMPADialog::OnDblclkSonglist()
+{
+	// TODO: Add your control notification handler code here
+   int index = m_SongListBox.GetCurSel();
+   m_WMP.GetControls().playItem(m_WMP.GetCurrentPlaylist().GetItem(index));
+   if (autoAnnounce) {
+      xchat_commandf(ph, "me is playing %s", (LPCTSTR) wmpaGetSongTitle());
+   }
+   else {
+      xchat_printf(ph, "WMPA: Playing %s", (LPCTSTR) wmpaGetSongTitle());
+   }
+}
+
+BEGIN_EVENTSINK_MAP(CWMPADialog, CDialog)
+    //{{AFX_EVENTSINK_MAP(CWMPADialog)
+	ON_EVENT(CWMPADialog, IDC_WMP, 5806 /* CurrentItemChange */, OnCurrentItemChangeWmp, VTS_DISPATCH)
+	ON_EVENT(CWMPADialog, IDC_WMP, 5101 /* PlayStateChange */, OnPlayStateChangeWmp, VTS_I4)
+	//}}AFX_EVENTSINK_MAP
+END_EVENTSINK_MAP()
+
+void CWMPADialog::OnCurrentItemChangeWmp(LPDISPATCH pdispMedia)
+{
+	// TODO: Add your control notification handler code here
+
+   int state = m_WMP.GetPlayState();
+   if (state == 3) { // Playing
+      if (autoAnnounce) {
+         xchat_commandf(ph, "me is playing %s", (LPCTSTR) wmpaGetSongTitle());
+      }
+      else {
+         xchat_printf(ph, "WMPA: Playing %s", (LPCTSTR) wmpaGetSongTitle());
+      }
+   }
+
+   SelectCurrentSong();
+}
+
+void CWMPADialog::OnDestroy()
+{
+	CDialog::OnDestroy();
+	
+   // TODO: Add your message handler code here
+}
+
+void CWMPADialog::UpdateSongList()
+{
+   char buffer[32];
+   CString name;
+   CString artist;
+   CString title;
+   CString album;
+   CString bitrate;
+   CString duration;
+   CString song;
+   long index;
+   long count;
+
+   m_SongListBox.ResetContent();
+   CWMPPlaylist playlist = m_WMP.GetCurrentPlaylist();
+   count = playlist.GetCount();
+   m_SongListBox.ResetContent();
+   for (index = 0; index < count; index++) {
+      name         = playlist.GetItem(index).GetName();
+      artist       = playlist.GetItem(index).getItemInfo("Artist");
+      title        = playlist.GetItem(index).getItemInfo("Title");
+      album        = playlist.GetItem(index).getItemInfo("Album");
+      bitrate      = playlist.GetItem(index).getItemInfo("Bitrate");
+      duration     = playlist.GetItem(index).GetDurationString();
+
+      long krate = strtoul((LPCTSTR) bitrate, NULL, 10) / 1000;
+      _ultoa(krate, buffer, 10);
+      bitrate = CString(buffer);
+
+      if (album.IsEmpty()) {
+         playlist.removeItem(playlist.GetItem(index));
+         count = playlist.GetCount();
+      }
+      else {
+         song = "";
+         song += artist;
+         if (song.IsEmpty()) song = "Various";
+         song += " - ";
+         song += title;
+         song += " (";
+         song += album;
+         song += ") [";
+         song += duration;
+         song += "/";
+         song += bitrate;
+         song += "Kbps]";
+         m_SongListBox.AddString((LPCTSTR) song);
+      }
+
+   }
+   m_SongListBox.SetCurSel(0);
+}
+
+void CWMPADialog::SelectCurrentSong()
+{
+   CWMPMedia media;
+   long index;
+   long count;
+
+   count = m_WMP.GetCurrentPlaylist().GetCount();
+   for (index = 0; index < count; index++) {
+      media = m_WMP.GetCurrentPlaylist().GetItem(index);
+      if (m_WMP.GetCurrentMedia().GetIsIdentical(media)) {
+         m_SongListBox.SetCurSel(index);
+      }
+   }
+}
+
+void CWMPADialog::UpdatePlayLists()
+{
+	// TODO: Add extra initialization here
+   CWMPPlaylistCollection pc = m_WMP.GetPlaylistCollection();
+   CWMPPlaylistArray pa = pc.getAll();
+   CWMPPlaylist playlist;
+
+   int index;
+   int count = pa.GetCount();
+   m_PlaylistBox.ResetContent();
+   for (index = 0; index < count; index++) {
+      playlist = pa.Item(index);
+      m_PlaylistBox.AddString((LPCTSTR) playlist.GetName());
+   }
+}
+
+
+void CWMPADialog::OnPlayStateChangeWmp(long NewState)
+{
+	// TODO: Add your control notification handler code here
+}
+
+void CWMPADialog::OnSize(UINT nType, int cx, int cy)
+{
+	CDialog::OnSize(nType, cx, cy);
+	// TODO: Add your message handler code here
+   switch (nType) {
+      case SIZE_MINIMIZED:
+         break;
+
+      case SIZE_RESTORED:
+         Shell_NotifyIcon(NIM_DELETE, &nid);
+         break;
+
+      default:
+         break;
+   }
+}
+
+LRESULT CWMPADialog::WindowProc(UINT message, WPARAM wParam, LPARAM lParam)
+{
+   // TODO: Add your specialized code here and/or call the base class
+   switch (message) {
+      case WM_TRAY_ICON:
+         switch (lParam) {
+            case WM_LBUTTONDBLCLK:
+               trayClicked = TRUE;
+               break;
+
+            case WM_LBUTTONUP:
+               if (trayClicked == TRUE) {
+                  ShowWindow(SW_RESTORE);
+               }
+               break;
+
+            default:
+               trayClicked = FALSE;
+               break;
+         }
+         return(TRUE);
+         break;
+
+      default:
+         return CDialog::WindowProc(message, wParam, lParam);
+         break;
+   }
+}
+
+void CWMPADialog::DeleteTrayIcon()
+{
+   Shell_NotifyIcon(NIM_DELETE, &nid);
+}
diff --git a/plugins/wmpa/wmpadialog.h b/plugins/wmpa/wmpadialog.h
new file mode 100644
index 00000000..43e9a66a
--- /dev/null
+++ b/plugins/wmpa/wmpadialog.h
@@ -0,0 +1,91 @@
+/******************************************************************
+* $Id$
+*
+* $Log$
+*
+* Copyright � 2005 David Cullen, All rights reserved
+*
+******************************************************************/
+//{{AFX_INCLUDES()
+#include "wmpplayer4.h"
+//}}AFX_INCLUDES
+#if !defined(AFX_WMPADIALOG_H__D3838BCC_9E26_4FC0_BD42_C8D8EDF057E3__INCLUDED_)
+#define AFX_WMPADIALOG_H__D3838BCC_9E26_4FC0_BD42_C8D8EDF057E3__INCLUDED_
+
+#if _MSC_VER > 1000
+#pragma once
+#endif // _MSC_VER > 1000
+// WMPADialog.h : header file
+//
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPADialog dialog
+
+class CWMPADialog : public CDialog
+{
+// Construction
+public:
+	CWMPADialog(CWnd* pParent = NULL);   // standard constructor
+   virtual void OnCancel();
+   void UpdatePlayLists();
+   void UpdateSongList();
+   void SelectCurrentSong();
+   void DeleteTrayIcon();
+   BOOL autoAnnounce;
+   HICON m_hIcon;
+
+private:
+   BOOL trayInit;
+   BOOL trayClicked;
+   NOTIFYICONDATA nid;
+
+public:
+// Dialog Data
+	//{{AFX_DATA(CWMPADialog)
+	enum { IDD = IDD_WMPADIALOG };
+	CListBox	m_SongListBox;
+	CListBox	m_PlaylistBox;
+	CWMPPlayer4	m_WMP;
+	//}}AFX_DATA
+
+
+// Overrides
+	// ClassWizard generated virtual function overrides
+	//{{AFX_VIRTUAL(CWMPADialog)
+	public:
+	virtual void OnFinalRelease();
+	protected:
+	virtual void DoDataExchange(CDataExchange* pDX);    // DDX/DDV support
+	virtual void PostNcDestroy();
+	virtual LRESULT WindowProc(UINT message, WPARAM wParam, LPARAM lParam);
+	//}}AFX_VIRTUAL
+
+// Implementation
+protected:
+
+	// Generated message map functions
+	//{{AFX_MSG(CWMPADialog)
+	afx_msg void OnDblclkPlaylist();
+	afx_msg void OnShowWindow(BOOL bShow, UINT nStatus);
+	virtual BOOL OnInitDialog();
+	afx_msg void OnClose();
+	afx_msg void OnDblclkSonglist();
+	afx_msg void OnCurrentItemChangeWmp(LPDISPATCH pdispMedia);
+	afx_msg void OnDestroy();
+	afx_msg void OnPlayStateChangeWmp(long NewState);
+	afx_msg void OnSize(UINT nType, int cx, int cy);
+	DECLARE_EVENTSINK_MAP()
+	//}}AFX_MSG
+	DECLARE_MESSAGE_MAP()
+	// Generated OLE dispatch map functions
+	//{{AFX_DISPATCH(CWMPADialog)
+		// NOTE - the ClassWizard will add and remove member functions here.
+	//}}AFX_DISPATCH
+	DECLARE_DISPATCH_MAP()
+	DECLARE_INTERFACE_MAP()
+};
+
+//{{AFX_INSERT_LOCATION}}
+// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
+
+#endif // !defined(AFX_WMPADIALOG_H__D3838BCC_9E26_4FC0_BD42_C8D8EDF057E3__INCLUDED_)
diff --git a/plugins/wmpa/wmpcdrom.cpp b/plugins/wmpa/wmpcdrom.cpp
new file mode 100644
index 00000000..121f0535
--- /dev/null
+++ b/plugins/wmpa/wmpcdrom.cpp
@@ -0,0 +1,37 @@
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+#include "stdafx.h"
+#include "wmpcdrom.h"
+
+// Dispatch interfaces referenced by this interface
+#include "wmpplaylist.h"
+
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPCdrom properties
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPCdrom operations
+
+CString CWMPCdrom::GetDriveSpecifier()
+{
+	CString result;
+	InvokeHelper(0xfb, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
+	return result;
+}
+
+CWMPPlaylist CWMPCdrom::GetPlaylist()
+{
+	LPDISPATCH pDispatch;
+	InvokeHelper(0xfc, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
+	return CWMPPlaylist(pDispatch);
+}
+
+void CWMPCdrom::eject()
+{
+	InvokeHelper(0xfd, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
+}
diff --git a/plugins/wmpa/wmpcdrom.h b/plugins/wmpa/wmpcdrom.h
new file mode 100644
index 00000000..f52f8f10
--- /dev/null
+++ b/plugins/wmpa/wmpcdrom.h
@@ -0,0 +1,39 @@
+#if !defined(AFX_WMPCDROM_H__B7B13CE9_E69E_4D54_9370_CCA2D4A42532__INCLUDED_)
+#define AFX_WMPCDROM_H__B7B13CE9_E69E_4D54_9370_CCA2D4A42532__INCLUDED_
+
+#if _MSC_VER > 1000
+#pragma once
+#endif // _MSC_VER > 1000
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+// Dispatch interfaces referenced by this interface
+class CWMPPlaylist;
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPCdrom wrapper class
+
+class CWMPCdrom : public COleDispatchDriver
+{
+public:
+	CWMPCdrom() {}		// Calls COleDispatchDriver default constructor
+	CWMPCdrom(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
+	CWMPCdrom(const CWMPCdrom& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
+
+// Attributes
+public:
+
+// Operations
+public:
+	CString GetDriveSpecifier();
+	CWMPPlaylist GetPlaylist();
+	void eject();
+};
+
+//{{AFX_INSERT_LOCATION}}
+// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
+
+#endif // !defined(AFX_WMPCDROM_H__B7B13CE9_E69E_4D54_9370_CCA2D4A42532__INCLUDED_)
diff --git a/plugins/wmpa/wmpcdromcollection.cpp b/plugins/wmpa/wmpcdromcollection.cpp
new file mode 100644
index 00000000..3e1f7e7d
--- /dev/null
+++ b/plugins/wmpa/wmpcdromcollection.cpp
@@ -0,0 +1,45 @@
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+#include "stdafx.h"
+#include "wmpcdromcollection.h"
+
+// Dispatch interfaces referenced by this interface
+#include "WMPCdrom.h"
+
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPCdromCollection properties
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPCdromCollection operations
+
+long CWMPCdromCollection::GetCount()
+{
+	long result;
+	InvokeHelper(0x12d, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+CWMPCdrom CWMPCdromCollection::Item(long lIndex)
+{
+	LPDISPATCH pDispatch;
+	static BYTE parms[] =
+		VTS_I4;
+	InvokeHelper(0x12e, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
+		lIndex);
+	return CWMPCdrom(pDispatch);
+}
+
+CWMPCdrom CWMPCdromCollection::getByDriveSpecifier(LPCTSTR bstrDriveSpecifier)
+{
+	LPDISPATCH pDispatch;
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x12f, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
+		bstrDriveSpecifier);
+	return CWMPCdrom(pDispatch);
+}
diff --git a/plugins/wmpa/wmpcdromcollection.h b/plugins/wmpa/wmpcdromcollection.h
new file mode 100644
index 00000000..bdc32b9b
--- /dev/null
+++ b/plugins/wmpa/wmpcdromcollection.h
@@ -0,0 +1,39 @@
+#if !defined(AFX_WMPCDROMCOLLECTION_H__35F03E65_DBA5_47A8_84C1_DAA3D624A4D3__INCLUDED_)
+#define AFX_WMPCDROMCOLLECTION_H__35F03E65_DBA5_47A8_84C1_DAA3D624A4D3__INCLUDED_
+
+#if _MSC_VER > 1000
+#pragma once
+#endif // _MSC_VER > 1000
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+// Dispatch interfaces referenced by this interface
+class CWMPCdrom;
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPCdromCollection wrapper class
+
+class CWMPCdromCollection : public COleDispatchDriver
+{
+public:
+	CWMPCdromCollection() {}		// Calls COleDispatchDriver default constructor
+	CWMPCdromCollection(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
+	CWMPCdromCollection(const CWMPCdromCollection& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
+
+// Attributes
+public:
+
+// Operations
+public:
+	long GetCount();
+	CWMPCdrom Item(long lIndex);
+	CWMPCdrom getByDriveSpecifier(LPCTSTR bstrDriveSpecifier);
+};
+
+//{{AFX_INSERT_LOCATION}}
+// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
+
+#endif // !defined(AFX_WMPCDROMCOLLECTION_H__35F03E65_DBA5_47A8_84C1_DAA3D624A4D3__INCLUDED_)
diff --git a/plugins/wmpa/wmpclosedcaption.cpp b/plugins/wmpa/wmpclosedcaption.cpp
new file mode 100644
index 00000000..3ea2ec91
--- /dev/null
+++ b/plugins/wmpa/wmpclosedcaption.cpp
@@ -0,0 +1,75 @@
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+#include "stdafx.h"
+#include "wmpclosedcaption.h"
+
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPClosedCaption properties
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPClosedCaption operations
+
+CString CWMPClosedCaption::GetSAMIStyle()
+{
+	CString result;
+	InvokeHelper(0x3b7, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPClosedCaption::SetSAMIStyle(LPCTSTR lpszNewValue)
+{
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x3b7, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 lpszNewValue);
+}
+
+CString CWMPClosedCaption::GetSAMILang()
+{
+	CString result;
+	InvokeHelper(0x3b8, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPClosedCaption::SetSAMILang(LPCTSTR lpszNewValue)
+{
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x3b8, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 lpszNewValue);
+}
+
+CString CWMPClosedCaption::GetSAMIFileName()
+{
+	CString result;
+	InvokeHelper(0x3b9, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPClosedCaption::SetSAMIFileName(LPCTSTR lpszNewValue)
+{
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x3b9, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 lpszNewValue);
+}
+
+CString CWMPClosedCaption::GetCaptioningId()
+{
+	CString result;
+	InvokeHelper(0x3ba, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPClosedCaption::SetCaptioningId(LPCTSTR lpszNewValue)
+{
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x3ba, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 lpszNewValue);
+}
diff --git a/plugins/wmpa/wmpclosedcaption.h b/plugins/wmpa/wmpclosedcaption.h
new file mode 100644
index 00000000..c604c12f
--- /dev/null
+++ b/plugins/wmpa/wmpclosedcaption.h
@@ -0,0 +1,40 @@
+#if !defined(AFX_WMPCLOSEDCAPTION_H__FC0A9836_7517_4898_B25C_74C76E80CE3D__INCLUDED_)
+#define AFX_WMPCLOSEDCAPTION_H__FC0A9836_7517_4898_B25C_74C76E80CE3D__INCLUDED_
+
+#if _MSC_VER > 1000
+#pragma once
+#endif // _MSC_VER > 1000
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPClosedCaption wrapper class
+
+class CWMPClosedCaption : public COleDispatchDriver
+{
+public:
+	CWMPClosedCaption() {}		// Calls COleDispatchDriver default constructor
+	CWMPClosedCaption(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
+	CWMPClosedCaption(const CWMPClosedCaption& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
+
+// Attributes
+public:
+
+// Operations
+public:
+	CString GetSAMIStyle();
+	void SetSAMIStyle(LPCTSTR lpszNewValue);
+	CString GetSAMILang();
+	void SetSAMILang(LPCTSTR lpszNewValue);
+	CString GetSAMIFileName();
+	void SetSAMIFileName(LPCTSTR lpszNewValue);
+	CString GetCaptioningId();
+	void SetCaptioningId(LPCTSTR lpszNewValue);
+};
+
+//{{AFX_INSERT_LOCATION}}
+// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
+
+#endif // !defined(AFX_WMPCLOSEDCAPTION_H__FC0A9836_7517_4898_B25C_74C76E80CE3D__INCLUDED_)
diff --git a/plugins/wmpa/wmpcontrols.cpp b/plugins/wmpa/wmpcontrols.cpp
new file mode 100644
index 00000000..1b3046d0
--- /dev/null
+++ b/plugins/wmpa/wmpcontrols.cpp
@@ -0,0 +1,123 @@
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+#include "stdafx.h"
+#include "wmpcontrols.h"
+
+// Dispatch interfaces referenced by this interface
+#include "wmpmedia.h"
+
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPControls properties
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPControls operations
+
+BOOL CWMPControls::GetIsAvailable(LPCTSTR bstrItem)
+{
+	BOOL result;
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x3e, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, parms,
+		bstrItem);
+	return result;
+}
+
+void CWMPControls::play()
+{
+	InvokeHelper(0x33, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
+}
+
+void CWMPControls::stop()
+{
+	InvokeHelper(0x34, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
+}
+
+void CWMPControls::pause()
+{
+	InvokeHelper(0x35, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
+}
+
+void CWMPControls::fastForward()
+{
+	InvokeHelper(0x36, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
+}
+
+void CWMPControls::fastReverse()
+{
+	InvokeHelper(0x37, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
+}
+
+double CWMPControls::GetCurrentPosition()
+{
+	double result;
+	InvokeHelper(0x38, DISPATCH_PROPERTYGET, VT_R8, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPControls::SetCurrentPosition(double newValue)
+{
+	static BYTE parms[] =
+		VTS_R8;
+	InvokeHelper(0x38, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 newValue);
+}
+
+CString CWMPControls::GetCurrentPositionString()
+{
+	CString result;
+	InvokeHelper(0x39, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPControls::next()
+{
+	InvokeHelper(0x3a, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
+}
+
+void CWMPControls::previous()
+{
+	InvokeHelper(0x3b, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
+}
+
+CWMPMedia CWMPControls::GetCurrentItem()
+{
+	LPDISPATCH pDispatch;
+	InvokeHelper(0x3c, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
+	return CWMPMedia(pDispatch);
+}
+
+void CWMPControls::SetCurrentItem(LPDISPATCH newValue)
+{
+	static BYTE parms[] =
+		VTS_DISPATCH;
+	InvokeHelper(0x3c, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 newValue);
+}
+
+long CWMPControls::GetCurrentMarker()
+{
+	long result;
+	InvokeHelper(0x3d, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPControls::SetCurrentMarker(long nNewValue)
+{
+	static BYTE parms[] =
+		VTS_I4;
+	InvokeHelper(0x3d, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 nNewValue);
+}
+
+void CWMPControls::playItem(LPDISPATCH pIWMPMedia)
+{
+	static BYTE parms[] =
+		VTS_DISPATCH;
+	InvokeHelper(0x3f, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
+		 pIWMPMedia);
+}
diff --git a/plugins/wmpa/wmpcontrols.h b/plugins/wmpa/wmpcontrols.h
new file mode 100644
index 00000000..b793bcb1
--- /dev/null
+++ b/plugins/wmpa/wmpcontrols.h
@@ -0,0 +1,52 @@
+#if !defined(AFX_WMPCONTROLS_H__234DACEF_6ED9_481D_B7E8_03653189E9B2__INCLUDED_)
+#define AFX_WMPCONTROLS_H__234DACEF_6ED9_481D_B7E8_03653189E9B2__INCLUDED_
+
+#if _MSC_VER > 1000
+#pragma once
+#endif // _MSC_VER > 1000
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+// Dispatch interfaces referenced by this interface
+class CWMPMedia;
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPControls wrapper class
+
+class CWMPControls : public COleDispatchDriver
+{
+public:
+	CWMPControls() {}		// Calls COleDispatchDriver default constructor
+	CWMPControls(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
+	CWMPControls(const CWMPControls& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
+
+// Attributes
+public:
+
+// Operations
+public:
+	BOOL GetIsAvailable(LPCTSTR bstrItem);
+	void play();
+	void stop();
+	void pause();
+	void fastForward();
+	void fastReverse();
+	double GetCurrentPosition();
+	void SetCurrentPosition(double newValue);
+	CString GetCurrentPositionString();
+	void next();
+	void previous();
+	CWMPMedia GetCurrentItem();
+	void SetCurrentItem(LPDISPATCH newValue);
+	long GetCurrentMarker();
+	void SetCurrentMarker(long nNewValue);
+	void playItem(LPDISPATCH pIWMPMedia);
+};
+
+//{{AFX_INSERT_LOCATION}}
+// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
+
+#endif // !defined(AFX_WMPCONTROLS_H__234DACEF_6ED9_481D_B7E8_03653189E9B2__INCLUDED_)
diff --git a/plugins/wmpa/wmpdvd.cpp b/plugins/wmpa/wmpdvd.cpp
new file mode 100644
index 00000000..0eb48f6f
--- /dev/null
+++ b/plugins/wmpa/wmpdvd.cpp
@@ -0,0 +1,52 @@
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+#include "stdafx.h"
+#include "wmpdvd.h"
+
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPDVD properties
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPDVD operations
+
+BOOL CWMPDVD::GetIsAvailable(LPCTSTR bstrItem)
+{
+	BOOL result;
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x3e9, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, parms,
+		bstrItem);
+	return result;
+}
+
+CString CWMPDVD::GetDomain()
+{
+	CString result;
+	InvokeHelper(0x3ea, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPDVD::topMenu()
+{
+	InvokeHelper(0x3eb, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
+}
+
+void CWMPDVD::titleMenu()
+{
+	InvokeHelper(0x3ec, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
+}
+
+void CWMPDVD::back()
+{
+	InvokeHelper(0x3ed, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
+}
+
+void CWMPDVD::resume()
+{
+	InvokeHelper(0x3ee, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
+}
diff --git a/plugins/wmpa/wmpdvd.h b/plugins/wmpa/wmpdvd.h
new file mode 100644
index 00000000..4710536a
--- /dev/null
+++ b/plugins/wmpa/wmpdvd.h
@@ -0,0 +1,38 @@
+#if !defined(AFX_WMPDVD_H__E83D86CA_08B8_4ACA_A434_0837BA71E3CA__INCLUDED_)
+#define AFX_WMPDVD_H__E83D86CA_08B8_4ACA_A434_0837BA71E3CA__INCLUDED_
+
+#if _MSC_VER > 1000
+#pragma once
+#endif // _MSC_VER > 1000
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPDVD wrapper class
+
+class CWMPDVD : public COleDispatchDriver
+{
+public:
+	CWMPDVD() {}		// Calls COleDispatchDriver default constructor
+	CWMPDVD(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
+	CWMPDVD(const CWMPDVD& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
+
+// Attributes
+public:
+
+// Operations
+public:
+	BOOL GetIsAvailable(LPCTSTR bstrItem);
+	CString GetDomain();
+	void topMenu();
+	void titleMenu();
+	void back();
+	void resume();
+};
+
+//{{AFX_INSERT_LOCATION}}
+// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
+
+#endif // !defined(AFX_WMPDVD_H__E83D86CA_08B8_4ACA_A434_0837BA71E3CA__INCLUDED_)
diff --git a/plugins/wmpa/wmperror.cpp b/plugins/wmpa/wmperror.cpp
new file mode 100644
index 00000000..2fce2b59
--- /dev/null
+++ b/plugins/wmpa/wmperror.cpp
@@ -0,0 +1,45 @@
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+#include "stdafx.h"
+#include "wmperror.h"
+
+// Dispatch interfaces referenced by this interface
+#include "wmperroritem.h"
+
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPError properties
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPError operations
+
+void CWMPError::clearErrorQueue()
+{
+	InvokeHelper(0x353, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
+}
+
+long CWMPError::GetErrorCount()
+{
+	long result;
+	InvokeHelper(0x354, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+CWMPErrorItem CWMPError::GetItem(long dwIndex)
+{
+	LPDISPATCH pDispatch;
+	static BYTE parms[] =
+		VTS_I4;
+	InvokeHelper(0x355, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, parms,
+		dwIndex);
+	return CWMPErrorItem(pDispatch);
+}
+
+void CWMPError::webHelp()
+{
+	InvokeHelper(0x356, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
+}
diff --git a/plugins/wmpa/wmperror.h b/plugins/wmpa/wmperror.h
new file mode 100644
index 00000000..94ee2fff
--- /dev/null
+++ b/plugins/wmpa/wmperror.h
@@ -0,0 +1,40 @@
+#if !defined(AFX_WMPERROR_H__1E72AC7F_E0AC_4100_B7EF_A5B0D8FA75C3__INCLUDED_)
+#define AFX_WMPERROR_H__1E72AC7F_E0AC_4100_B7EF_A5B0D8FA75C3__INCLUDED_
+
+#if _MSC_VER > 1000
+#pragma once
+#endif // _MSC_VER > 1000
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+// Dispatch interfaces referenced by this interface
+class CWMPErrorItem;
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPError wrapper class
+
+class CWMPError : public COleDispatchDriver
+{
+public:
+	CWMPError() {}		// Calls COleDispatchDriver default constructor
+	CWMPError(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
+	CWMPError(const CWMPError& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
+
+// Attributes
+public:
+
+// Operations
+public:
+	void clearErrorQueue();
+	long GetErrorCount();
+	CWMPErrorItem GetItem(long dwIndex);
+	void webHelp();
+};
+
+//{{AFX_INSERT_LOCATION}}
+// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
+
+#endif // !defined(AFX_WMPERROR_H__1E72AC7F_E0AC_4100_B7EF_A5B0D8FA75C3__INCLUDED_)
diff --git a/plugins/wmpa/wmperroritem.cpp b/plugins/wmpa/wmperroritem.cpp
new file mode 100644
index 00000000..86e9740c
--- /dev/null
+++ b/plugins/wmpa/wmperroritem.cpp
@@ -0,0 +1,50 @@
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+#include "stdafx.h"
+#include "wmperroritem.h"
+
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPErrorItem properties
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPErrorItem operations
+
+long CWMPErrorItem::GetErrorCode()
+{
+	long result;
+	InvokeHelper(0x385, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+CString CWMPErrorItem::GetErrorDescription()
+{
+	CString result;
+	InvokeHelper(0x386, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
+	return result;
+}
+
+VARIANT CWMPErrorItem::GetErrorContext()
+{
+	VARIANT result;
+	InvokeHelper(0x387, DISPATCH_PROPERTYGET, VT_VARIANT, (void*)&result, NULL);
+	return result;
+}
+
+long CWMPErrorItem::GetRemedy()
+{
+	long result;
+	InvokeHelper(0x388, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+CString CWMPErrorItem::GetCustomUrl()
+{
+	CString result;
+	InvokeHelper(0x389, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
+	return result;
+}
diff --git a/plugins/wmpa/wmperroritem.h b/plugins/wmpa/wmperroritem.h
new file mode 100644
index 00000000..de66dc9b
--- /dev/null
+++ b/plugins/wmpa/wmperroritem.h
@@ -0,0 +1,37 @@
+#if !defined(AFX_WMPERRORITEM_H__9399BDE5_C96D_43D3_BF02_E7A5850421B4__INCLUDED_)
+#define AFX_WMPERRORITEM_H__9399BDE5_C96D_43D3_BF02_E7A5850421B4__INCLUDED_
+
+#if _MSC_VER > 1000
+#pragma once
+#endif // _MSC_VER > 1000
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPErrorItem wrapper class
+
+class CWMPErrorItem : public COleDispatchDriver
+{
+public:
+	CWMPErrorItem() {}		// Calls COleDispatchDriver default constructor
+	CWMPErrorItem(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
+	CWMPErrorItem(const CWMPErrorItem& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
+
+// Attributes
+public:
+
+// Operations
+public:
+	long GetErrorCode();
+	CString GetErrorDescription();
+	VARIANT GetErrorContext();
+	long GetRemedy();
+	CString GetCustomUrl();
+};
+
+//{{AFX_INSERT_LOCATION}}
+// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
+
+#endif // !defined(AFX_WMPERRORITEM_H__9399BDE5_C96D_43D3_BF02_E7A5850421B4__INCLUDED_)
diff --git a/plugins/wmpa/wmpmedia.cpp b/plugins/wmpa/wmpmedia.cpp
new file mode 100644
index 00000000..63503ab8
--- /dev/null
+++ b/plugins/wmpa/wmpmedia.cpp
@@ -0,0 +1,167 @@
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+#include "stdafx.h"
+#include "wmpmedia.h"
+
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPMedia properties
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPMedia operations
+
+BOOL CWMPMedia::GetIsIdentical(LPDISPATCH pIWMPMedia)
+{
+	BOOL result;
+	static BYTE parms[] =
+		VTS_DISPATCH;
+	InvokeHelper(0x2fb, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, parms,
+		pIWMPMedia);
+	return result;
+}
+
+CString CWMPMedia::GetSourceURL()
+{
+	CString result;
+	InvokeHelper(0x2ef, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
+	return result;
+}
+
+CString CWMPMedia::GetName()
+{
+	CString result;
+	InvokeHelper(0x2fc, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPMedia::SetName(LPCTSTR lpszNewValue)
+{
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x2fc, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 lpszNewValue);
+}
+
+long CWMPMedia::GetImageSourceWidth()
+{
+	long result;
+	InvokeHelper(0x2f0, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+long CWMPMedia::GetImageSourceHeight()
+{
+	long result;
+	InvokeHelper(0x2f1, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+long CWMPMedia::GetMarkerCount()
+{
+	long result;
+	InvokeHelper(0x2f2, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+double CWMPMedia::getMarkerTime(long MarkerNum)
+{
+	double result;
+	static BYTE parms[] =
+		VTS_I4;
+	InvokeHelper(0x2f3, DISPATCH_METHOD, VT_R8, (void*)&result, parms,
+		MarkerNum);
+	return result;
+}
+
+CString CWMPMedia::getMarkerName(long MarkerNum)
+{
+	CString result;
+	static BYTE parms[] =
+		VTS_I4;
+	InvokeHelper(0x2f4, DISPATCH_METHOD, VT_BSTR, (void*)&result, parms,
+		MarkerNum);
+	return result;
+}
+
+double CWMPMedia::GetDuration()
+{
+	double result;
+	InvokeHelper(0x2f5, DISPATCH_PROPERTYGET, VT_R8, (void*)&result, NULL);
+	return result;
+}
+
+CString CWMPMedia::GetDurationString()
+{
+	CString result;
+	InvokeHelper(0x2f6, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
+	return result;
+}
+
+long CWMPMedia::GetAttributeCount()
+{
+	long result;
+	InvokeHelper(0x2f7, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+CString CWMPMedia::getAttributeName(long lIndex)
+{
+	CString result;
+	static BYTE parms[] =
+		VTS_I4;
+	InvokeHelper(0x2f8, DISPATCH_METHOD, VT_BSTR, (void*)&result, parms,
+		lIndex);
+	return result;
+}
+
+CString CWMPMedia::getItemInfo(LPCTSTR bstrItemName)
+{
+	CString result;
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x2f9, DISPATCH_METHOD, VT_BSTR, (void*)&result, parms,
+		bstrItemName);
+	return result;
+}
+
+void CWMPMedia::setItemInfo(LPCTSTR bstrItemName, LPCTSTR bstrVal)
+{
+	static BYTE parms[] =
+		VTS_BSTR VTS_BSTR;
+	InvokeHelper(0x2fa, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
+		 bstrItemName, bstrVal);
+}
+
+CString CWMPMedia::getItemInfoByAtom(long lAtom)
+{
+	CString result;
+	static BYTE parms[] =
+		VTS_I4;
+	InvokeHelper(0x2fd, DISPATCH_METHOD, VT_BSTR, (void*)&result, parms,
+		lAtom);
+	return result;
+}
+
+BOOL CWMPMedia::isMemberOf(LPDISPATCH pPlaylist)
+{
+	BOOL result;
+	static BYTE parms[] =
+		VTS_DISPATCH;
+	InvokeHelper(0x2fe, DISPATCH_METHOD, VT_BOOL, (void*)&result, parms,
+		pPlaylist);
+	return result;
+}
+
+BOOL CWMPMedia::isReadOnlyItem(LPCTSTR bstrItemName)
+{
+	BOOL result;
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x2ff, DISPATCH_METHOD, VT_BOOL, (void*)&result, parms,
+		bstrItemName);
+	return result;
+}
diff --git a/plugins/wmpa/wmpmedia.h b/plugins/wmpa/wmpmedia.h
new file mode 100644
index 00000000..3503c403
--- /dev/null
+++ b/plugins/wmpa/wmpmedia.h
@@ -0,0 +1,50 @@
+#if !defined(AFX_WMPMEDIA_H__7736565E_C037_498E_89F1_9696912C5998__INCLUDED_)
+#define AFX_WMPMEDIA_H__7736565E_C037_498E_89F1_9696912C5998__INCLUDED_
+
+#if _MSC_VER > 1000
+#pragma once
+#endif // _MSC_VER > 1000
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPMedia wrapper class
+
+class CWMPMedia : public COleDispatchDriver
+{
+public:
+	CWMPMedia() {}		// Calls COleDispatchDriver default constructor
+	CWMPMedia(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
+	CWMPMedia(const CWMPMedia& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
+
+// Attributes
+public:
+
+// Operations
+public:
+	BOOL GetIsIdentical(LPDISPATCH pIWMPMedia);
+	CString GetSourceURL();
+	CString GetName();
+	void SetName(LPCTSTR lpszNewValue);
+	long GetImageSourceWidth();
+	long GetImageSourceHeight();
+	long GetMarkerCount();
+	double getMarkerTime(long MarkerNum);
+	CString getMarkerName(long MarkerNum);
+	double GetDuration();
+	CString GetDurationString();
+	long GetAttributeCount();
+	CString getAttributeName(long lIndex);
+	CString getItemInfo(LPCTSTR bstrItemName);
+	void setItemInfo(LPCTSTR bstrItemName, LPCTSTR bstrVal);
+	CString getItemInfoByAtom(long lAtom);
+	BOOL isMemberOf(LPDISPATCH pPlaylist);
+	BOOL isReadOnlyItem(LPCTSTR bstrItemName);
+};
+
+//{{AFX_INSERT_LOCATION}}
+// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
+
+#endif // !defined(AFX_WMPMEDIA_H__7736565E_C037_498E_89F1_9696912C5998__INCLUDED_)
diff --git a/plugins/wmpa/wmpmediacollection.cpp b/plugins/wmpa/wmpmediacollection.cpp
new file mode 100644
index 00000000..d50da652
--- /dev/null
+++ b/plugins/wmpa/wmpmediacollection.cpp
@@ -0,0 +1,133 @@
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+#include "stdafx.h"
+#include "wmpmediacollection.h"
+
+// Dispatch interfaces referenced by this interface
+#include "wmpmedia.h"
+#include "wmpplaylist.h"
+#include "wmpstringcollection.h"
+
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPMediaCollection properties
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPMediaCollection operations
+
+CWMPMedia CWMPMediaCollection::add(LPCTSTR bstrURL)
+{
+	LPDISPATCH pDispatch;
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x1c4, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
+		bstrURL);
+	return CWMPMedia(pDispatch);
+}
+
+CWMPPlaylist CWMPMediaCollection::getAll()
+{
+	LPDISPATCH pDispatch;
+	InvokeHelper(0x1c5, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, NULL);
+	return CWMPPlaylist(pDispatch);
+}
+
+CWMPPlaylist CWMPMediaCollection::getByName(LPCTSTR bstrName)
+{
+	LPDISPATCH pDispatch;
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x1c6, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
+		bstrName);
+	return CWMPPlaylist(pDispatch);
+}
+
+CWMPPlaylist CWMPMediaCollection::getByGenre(LPCTSTR bstrGenre)
+{
+	LPDISPATCH pDispatch;
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x1c7, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
+		bstrGenre);
+	return CWMPPlaylist(pDispatch);
+}
+
+CWMPPlaylist CWMPMediaCollection::getByAuthor(LPCTSTR bstrAuthor)
+{
+	LPDISPATCH pDispatch;
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x1c8, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
+		bstrAuthor);
+	return CWMPPlaylist(pDispatch);
+}
+
+CWMPPlaylist CWMPMediaCollection::getByAlbum(LPCTSTR bstrAlbum)
+{
+	LPDISPATCH pDispatch;
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x1c9, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
+		bstrAlbum);
+	return CWMPPlaylist(pDispatch);
+}
+
+CWMPPlaylist CWMPMediaCollection::getByAttribute(LPCTSTR bstrAttribute, LPCTSTR bstrValue)
+{
+	LPDISPATCH pDispatch;
+	static BYTE parms[] =
+		VTS_BSTR VTS_BSTR;
+	InvokeHelper(0x1ca, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
+		bstrAttribute, bstrValue);
+	return CWMPPlaylist(pDispatch);
+}
+
+void CWMPMediaCollection::remove(LPDISPATCH pItem, BOOL varfDeleteFile)
+{
+	static BYTE parms[] =
+		VTS_DISPATCH VTS_BOOL;
+	InvokeHelper(0x1cb, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
+		 pItem, varfDeleteFile);
+}
+
+CWMPStringCollection CWMPMediaCollection::getAttributeStringCollection(LPCTSTR bstrAttribute, LPCTSTR bstrMediaType)
+{
+	LPDISPATCH pDispatch;
+	static BYTE parms[] =
+		VTS_BSTR VTS_BSTR;
+	InvokeHelper(0x1cd, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
+		bstrAttribute, bstrMediaType);
+	return CWMPStringCollection(pDispatch);
+}
+
+long CWMPMediaCollection::getMediaAtom(LPCTSTR bstrItemName)
+{
+	long result;
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x1d6, DISPATCH_METHOD, VT_I4, (void*)&result, parms,
+		bstrItemName);
+	return result;
+}
+
+void CWMPMediaCollection::setDeleted(LPDISPATCH pItem, BOOL varfIsDeleted)
+{
+	static BYTE parms[] =
+		VTS_DISPATCH VTS_BOOL;
+	InvokeHelper(0x1d7, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
+		 pItem, varfIsDeleted);
+}
+
+BOOL CWMPMediaCollection::isDeleted(LPDISPATCH pItem)
+{
+	BOOL result;
+	static BYTE parms[] =
+		VTS_DISPATCH;
+	InvokeHelper(0x1d8, DISPATCH_METHOD, VT_BOOL, (void*)&result, parms,
+		pItem);
+	return result;
+}
diff --git a/plugins/wmpa/wmpmediacollection.h b/plugins/wmpa/wmpmediacollection.h
new file mode 100644
index 00000000..aa91026a
--- /dev/null
+++ b/plugins/wmpa/wmpmediacollection.h
@@ -0,0 +1,50 @@
+#if !defined(AFX_WMPMEDIACOLLECTION_H__8C47EB0E_4638_46DA_A405_415AEAE509CE__INCLUDED_)
+#define AFX_WMPMEDIACOLLECTION_H__8C47EB0E_4638_46DA_A405_415AEAE509CE__INCLUDED_
+
+#if _MSC_VER > 1000
+#pragma once
+#endif // _MSC_VER > 1000
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+// Dispatch interfaces referenced by this interface
+class CWMPMedia;
+class CWMPPlaylist;
+class CWMPStringCollection;
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPMediaCollection wrapper class
+
+class CWMPMediaCollection : public COleDispatchDriver
+{
+public:
+	CWMPMediaCollection() {}		// Calls COleDispatchDriver default constructor
+	CWMPMediaCollection(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
+	CWMPMediaCollection(const CWMPMediaCollection& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
+
+// Attributes
+public:
+
+// Operations
+public:
+	CWMPMedia add(LPCTSTR bstrURL);
+	CWMPPlaylist getAll();
+	CWMPPlaylist getByName(LPCTSTR bstrName);
+	CWMPPlaylist getByGenre(LPCTSTR bstrGenre);
+	CWMPPlaylist getByAuthor(LPCTSTR bstrAuthor);
+	CWMPPlaylist getByAlbum(LPCTSTR bstrAlbum);
+	CWMPPlaylist getByAttribute(LPCTSTR bstrAttribute, LPCTSTR bstrValue);
+	void remove(LPDISPATCH pItem, BOOL varfDeleteFile);
+	CWMPStringCollection getAttributeStringCollection(LPCTSTR bstrAttribute, LPCTSTR bstrMediaType);
+	long getMediaAtom(LPCTSTR bstrItemName);
+	void setDeleted(LPDISPATCH pItem, BOOL varfIsDeleted);
+	BOOL isDeleted(LPDISPATCH pItem);
+};
+
+//{{AFX_INSERT_LOCATION}}
+// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
+
+#endif // !defined(AFX_WMPMEDIACOLLECTION_H__8C47EB0E_4638_46DA_A405_415AEAE509CE__INCLUDED_)
diff --git a/plugins/wmpa/wmpnetwork.cpp b/plugins/wmpa/wmpnetwork.cpp
new file mode 100644
index 00000000..87c4d413
--- /dev/null
+++ b/plugins/wmpa/wmpnetwork.cpp
@@ -0,0 +1,233 @@
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+#include "stdafx.h"
+#include "wmpnetwork.h"
+
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPNetwork properties
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPNetwork operations
+
+long CWMPNetwork::GetBandWidth()
+{
+	long result;
+	InvokeHelper(0x321, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+long CWMPNetwork::GetRecoveredPackets()
+{
+	long result;
+	InvokeHelper(0x322, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+CString CWMPNetwork::GetSourceProtocol()
+{
+	CString result;
+	InvokeHelper(0x323, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
+	return result;
+}
+
+long CWMPNetwork::GetReceivedPackets()
+{
+	long result;
+	InvokeHelper(0x324, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+long CWMPNetwork::GetLostPackets()
+{
+	long result;
+	InvokeHelper(0x325, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+long CWMPNetwork::GetReceptionQuality()
+{
+	long result;
+	InvokeHelper(0x326, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+long CWMPNetwork::GetBufferingCount()
+{
+	long result;
+	InvokeHelper(0x327, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+long CWMPNetwork::GetBufferingProgress()
+{
+	long result;
+	InvokeHelper(0x328, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+long CWMPNetwork::GetBufferingTime()
+{
+	long result;
+	InvokeHelper(0x329, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPNetwork::SetBufferingTime(long nNewValue)
+{
+	static BYTE parms[] =
+		VTS_I4;
+	InvokeHelper(0x329, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 nNewValue);
+}
+
+long CWMPNetwork::GetFrameRate()
+{
+	long result;
+	InvokeHelper(0x32a, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+long CWMPNetwork::GetMaxBitRate()
+{
+	long result;
+	InvokeHelper(0x32b, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+long CWMPNetwork::GetBitRate()
+{
+	long result;
+	InvokeHelper(0x32c, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+long CWMPNetwork::getProxySettings(LPCTSTR bstrProtocol)
+{
+	long result;
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x32d, DISPATCH_METHOD, VT_I4, (void*)&result, parms,
+		bstrProtocol);
+	return result;
+}
+
+void CWMPNetwork::setProxySettings(LPCTSTR bstrProtocol, long lProxySetting)
+{
+	static BYTE parms[] =
+		VTS_BSTR VTS_I4;
+	InvokeHelper(0x32e, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
+		 bstrProtocol, lProxySetting);
+}
+
+CString CWMPNetwork::getProxyName(LPCTSTR bstrProtocol)
+{
+	CString result;
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x32f, DISPATCH_METHOD, VT_BSTR, (void*)&result, parms,
+		bstrProtocol);
+	return result;
+}
+
+void CWMPNetwork::setProxyName(LPCTSTR bstrProtocol, LPCTSTR bstrProxyName)
+{
+	static BYTE parms[] =
+		VTS_BSTR VTS_BSTR;
+	InvokeHelper(0x330, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
+		 bstrProtocol, bstrProxyName);
+}
+
+long CWMPNetwork::getProxyPort(LPCTSTR bstrProtocol)
+{
+	long result;
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x331, DISPATCH_METHOD, VT_I4, (void*)&result, parms,
+		bstrProtocol);
+	return result;
+}
+
+void CWMPNetwork::setProxyPort(LPCTSTR bstrProtocol, long lProxyPort)
+{
+	static BYTE parms[] =
+		VTS_BSTR VTS_I4;
+	InvokeHelper(0x332, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
+		 bstrProtocol, lProxyPort);
+}
+
+CString CWMPNetwork::getProxyExceptionList(LPCTSTR bstrProtocol)
+{
+	CString result;
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x333, DISPATCH_METHOD, VT_BSTR, (void*)&result, parms,
+		bstrProtocol);
+	return result;
+}
+
+void CWMPNetwork::setProxyExceptionList(LPCTSTR bstrProtocol, LPCTSTR pbstrExceptionList)
+{
+	static BYTE parms[] =
+		VTS_BSTR VTS_BSTR;
+	InvokeHelper(0x334, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
+		 bstrProtocol, pbstrExceptionList);
+}
+
+BOOL CWMPNetwork::getProxyBypassForLocal(LPCTSTR bstrProtocol)
+{
+	BOOL result;
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x335, DISPATCH_METHOD, VT_BOOL, (void*)&result, parms,
+		bstrProtocol);
+	return result;
+}
+
+void CWMPNetwork::setProxyBypassForLocal(LPCTSTR bstrProtocol, BOOL fBypassForLocal)
+{
+	static BYTE parms[] =
+		VTS_BSTR VTS_BOOL;
+	InvokeHelper(0x336, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
+		 bstrProtocol, fBypassForLocal);
+}
+
+long CWMPNetwork::GetMaxBandwidth()
+{
+	long result;
+	InvokeHelper(0x337, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPNetwork::SetMaxBandwidth(long nNewValue)
+{
+	static BYTE parms[] =
+		VTS_I4;
+	InvokeHelper(0x337, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 nNewValue);
+}
+
+long CWMPNetwork::GetDownloadProgress()
+{
+	long result;
+	InvokeHelper(0x338, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+long CWMPNetwork::GetEncodedFrameRate()
+{
+	long result;
+	InvokeHelper(0x339, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+long CWMPNetwork::GetFramesSkipped()
+{
+	long result;
+	InvokeHelper(0x33a, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
diff --git a/plugins/wmpa/wmpnetwork.h b/plugins/wmpa/wmpnetwork.h
new file mode 100644
index 00000000..1a0e0427
--- /dev/null
+++ b/plugins/wmpa/wmpnetwork.h
@@ -0,0 +1,60 @@
+#if !defined(AFX_WMPNETWORK_H__50BDAB41_9F78_492A_8A5E_27543B0C0CAF__INCLUDED_)
+#define AFX_WMPNETWORK_H__50BDAB41_9F78_492A_8A5E_27543B0C0CAF__INCLUDED_
+
+#if _MSC_VER > 1000
+#pragma once
+#endif // _MSC_VER > 1000
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPNetwork wrapper class
+
+class CWMPNetwork : public COleDispatchDriver
+{
+public:
+	CWMPNetwork() {}		// Calls COleDispatchDriver default constructor
+	CWMPNetwork(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
+	CWMPNetwork(const CWMPNetwork& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
+
+// Attributes
+public:
+
+// Operations
+public:
+	long GetBandWidth();
+	long GetRecoveredPackets();
+	CString GetSourceProtocol();
+	long GetReceivedPackets();
+	long GetLostPackets();
+	long GetReceptionQuality();
+	long GetBufferingCount();
+	long GetBufferingProgress();
+	long GetBufferingTime();
+	void SetBufferingTime(long nNewValue);
+	long GetFrameRate();
+	long GetMaxBitRate();
+	long GetBitRate();
+	long getProxySettings(LPCTSTR bstrProtocol);
+	void setProxySettings(LPCTSTR bstrProtocol, long lProxySetting);
+	CString getProxyName(LPCTSTR bstrProtocol);
+	void setProxyName(LPCTSTR bstrProtocol, LPCTSTR bstrProxyName);
+	long getProxyPort(LPCTSTR bstrProtocol);
+	void setProxyPort(LPCTSTR bstrProtocol, long lProxyPort);
+	CString getProxyExceptionList(LPCTSTR bstrProtocol);
+	void setProxyExceptionList(LPCTSTR bstrProtocol, LPCTSTR pbstrExceptionList);
+	BOOL getProxyBypassForLocal(LPCTSTR bstrProtocol);
+	void setProxyBypassForLocal(LPCTSTR bstrProtocol, BOOL fBypassForLocal);
+	long GetMaxBandwidth();
+	void SetMaxBandwidth(long nNewValue);
+	long GetDownloadProgress();
+	long GetEncodedFrameRate();
+	long GetFramesSkipped();
+};
+
+//{{AFX_INSERT_LOCATION}}
+// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
+
+#endif // !defined(AFX_WMPNETWORK_H__50BDAB41_9F78_492A_8A5E_27543B0C0CAF__INCLUDED_)
diff --git a/plugins/wmpa/wmpplayer4.cpp b/plugins/wmpa/wmpplayer4.cpp
new file mode 100644
index 00000000..40050678
--- /dev/null
+++ b/plugins/wmpa/wmpplayer4.cpp
@@ -0,0 +1,321 @@
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+#include "stdafx.h"
+#include "wmpplayer4.h"
+
+// Dispatch interfaces referenced by this interface
+#include "wmpcontrols.h"
+#include "WMPSettings.h"
+#include "wmpmedia.h"
+#include "wmpmediacollection.h"
+#include "wmpplaylistcollection.h"
+#include "wmpnetwork.h"
+#include "wmpplaylist.h"
+#include "wmpcdromcollection.h"
+#include "wmpclosedcaption.h"
+#include "WMPError.h"
+#include "wmpdvd.h"
+#include "WMPPlayerApplication.h"
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPPlayer4
+
+IMPLEMENT_DYNCREATE(CWMPPlayer4, CWnd)
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPPlayer4 properties
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPPlayer4 operations
+
+void CWMPPlayer4::close()
+{
+	InvokeHelper(0x3, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
+}
+
+CString CWMPPlayer4::GetUrl()
+{
+	CString result;
+	InvokeHelper(0x1, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPPlayer4::SetUrl(LPCTSTR lpszNewValue)
+{
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x1, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 lpszNewValue);
+}
+
+long CWMPPlayer4::GetOpenState()
+{
+	long result;
+	InvokeHelper(0x2, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+long CWMPPlayer4::GetPlayState()
+{
+	long result;
+	InvokeHelper(0xa, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+CWMPControls CWMPPlayer4::GetControls()
+{
+	LPDISPATCH pDispatch;
+	InvokeHelper(0x4, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
+	return CWMPControls(pDispatch);
+}
+
+CWMPSettings CWMPPlayer4::GetSettings()
+{
+	LPDISPATCH pDispatch;
+	InvokeHelper(0x5, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
+	return CWMPSettings(pDispatch);
+}
+
+CWMPMedia CWMPPlayer4::GetCurrentMedia()
+{
+	LPDISPATCH pDispatch;
+	InvokeHelper(0x6, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
+	return CWMPMedia(pDispatch);
+}
+
+void CWMPPlayer4::SetCurrentMedia(LPDISPATCH newValue)
+{
+	static BYTE parms[] =
+		VTS_DISPATCH;
+	InvokeHelper(0x6, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 newValue);
+}
+
+CWMPMediaCollection CWMPPlayer4::GetMediaCollection()
+{
+	LPDISPATCH pDispatch;
+	InvokeHelper(0x8, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
+	return CWMPMediaCollection(pDispatch);
+}
+
+CWMPPlaylistCollection CWMPPlayer4::GetPlaylistCollection()
+{
+	LPDISPATCH pDispatch;
+	InvokeHelper(0x9, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
+	return CWMPPlaylistCollection(pDispatch);
+}
+
+CString CWMPPlayer4::GetVersionInfo()
+{
+	CString result;
+	InvokeHelper(0xb, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPPlayer4::launchURL(LPCTSTR bstrURL)
+{
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0xc, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
+		 bstrURL);
+}
+
+CWMPNetwork CWMPPlayer4::GetNetwork()
+{
+	LPDISPATCH pDispatch;
+	InvokeHelper(0x7, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
+	return CWMPNetwork(pDispatch);
+}
+
+CWMPPlaylist CWMPPlayer4::GetCurrentPlaylist()
+{
+	LPDISPATCH pDispatch;
+	InvokeHelper(0xd, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
+	return CWMPPlaylist(pDispatch);
+}
+
+void CWMPPlayer4::SetCurrentPlaylist(LPDISPATCH newValue)
+{
+	static BYTE parms[] =
+		VTS_DISPATCH;
+	InvokeHelper(0xd, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 newValue);
+}
+
+CWMPCdromCollection CWMPPlayer4::GetCdromCollection()
+{
+	LPDISPATCH pDispatch;
+	InvokeHelper(0xe, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
+	return CWMPCdromCollection(pDispatch);
+}
+
+CWMPClosedCaption CWMPPlayer4::GetClosedCaption()
+{
+	LPDISPATCH pDispatch;
+	InvokeHelper(0xf, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
+	return CWMPClosedCaption(pDispatch);
+}
+
+BOOL CWMPPlayer4::GetIsOnline()
+{
+	BOOL result;
+	InvokeHelper(0x10, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
+	return result;
+}
+
+CWMPError CWMPPlayer4::GetError()
+{
+	LPDISPATCH pDispatch;
+	InvokeHelper(0x11, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
+	return CWMPError(pDispatch);
+}
+
+CString CWMPPlayer4::GetStatus()
+{
+	CString result;
+	InvokeHelper(0x12, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
+	return result;
+}
+
+CWMPDVD CWMPPlayer4::GetDvd()
+{
+	LPDISPATCH pDispatch;
+	InvokeHelper(0x28, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
+	return CWMPDVD(pDispatch);
+}
+
+CWMPPlaylist CWMPPlayer4::newPlaylist(LPCTSTR bstrName, LPCTSTR bstrURL)
+{
+	LPDISPATCH pDispatch;
+	static BYTE parms[] =
+		VTS_BSTR VTS_BSTR;
+	InvokeHelper(0x29, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
+		bstrName, bstrURL);
+	return CWMPPlaylist(pDispatch);
+}
+
+CWMPMedia CWMPPlayer4::newMedia(LPCTSTR bstrURL)
+{
+	LPDISPATCH pDispatch;
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x2a, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
+		bstrURL);
+	return CWMPMedia(pDispatch);
+}
+
+BOOL CWMPPlayer4::GetEnabled()
+{
+	BOOL result;
+	InvokeHelper(0x13, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPPlayer4::SetEnabled(BOOL bNewValue)
+{
+	static BYTE parms[] =
+		VTS_BOOL;
+	InvokeHelper(0x13, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 bNewValue);
+}
+
+BOOL CWMPPlayer4::GetFullScreen()
+{
+	BOOL result;
+	InvokeHelper(0x15, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPPlayer4::SetFullScreen(BOOL bNewValue)
+{
+	static BYTE parms[] =
+		VTS_BOOL;
+	InvokeHelper(0x15, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 bNewValue);
+}
+
+BOOL CWMPPlayer4::GetEnableContextMenu()
+{
+	BOOL result;
+	InvokeHelper(0x16, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPPlayer4::SetEnableContextMenu(BOOL bNewValue)
+{
+	static BYTE parms[] =
+		VTS_BOOL;
+	InvokeHelper(0x16, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 bNewValue);
+}
+
+void CWMPPlayer4::SetUiMode(LPCTSTR lpszNewValue)
+{
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x17, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 lpszNewValue);
+}
+
+CString CWMPPlayer4::GetUiMode()
+{
+	CString result;
+	InvokeHelper(0x17, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
+	return result;
+}
+
+BOOL CWMPPlayer4::GetStretchToFit()
+{
+	BOOL result;
+	InvokeHelper(0x18, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPPlayer4::SetStretchToFit(BOOL bNewValue)
+{
+	static BYTE parms[] =
+		VTS_BOOL;
+	InvokeHelper(0x18, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 bNewValue);
+}
+
+BOOL CWMPPlayer4::GetWindowlessVideo()
+{
+	BOOL result;
+	InvokeHelper(0x19, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPPlayer4::SetWindowlessVideo(BOOL bNewValue)
+{
+	static BYTE parms[] =
+		VTS_BOOL;
+	InvokeHelper(0x19, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 bNewValue);
+}
+
+BOOL CWMPPlayer4::GetIsRemote()
+{
+	BOOL result;
+	InvokeHelper(0x1a, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
+	return result;
+}
+
+CWMPPlayerApplication CWMPPlayer4::GetPlayerApplication()
+{
+	LPDISPATCH pDispatch;
+	InvokeHelper(0x1b, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, NULL);
+	return CWMPPlayerApplication(pDispatch);
+}
+
+void CWMPPlayer4::openPlayer(LPCTSTR bstrURL)
+{
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x1c, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
+		 bstrURL);
+}
diff --git a/plugins/wmpa/wmpplayer4.h b/plugins/wmpa/wmpplayer4.h
new file mode 100644
index 00000000..5ec3c331
--- /dev/null
+++ b/plugins/wmpa/wmpplayer4.h
@@ -0,0 +1,104 @@
+#if !defined(AFX_WMPPLAYER4_H__A318AE12_803B_4EED_B586_1395637CDD35__INCLUDED_)
+#define AFX_WMPPLAYER4_H__A318AE12_803B_4EED_B586_1395637CDD35__INCLUDED_
+
+#if _MSC_VER > 1000
+#pragma once
+#endif // _MSC_VER > 1000
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+// Dispatch interfaces referenced by this interface
+class CWMPControls;
+class CWMPSettings;
+class CWMPMedia;
+class CWMPMediaCollection;
+class CWMPPlaylistCollection;
+class CWMPNetwork;
+class CWMPPlaylist;
+class CWMPCdromCollection;
+class CWMPClosedCaption;
+class CWMPError;
+class CWMPDVD;
+class CWMPPlayerApplication;
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPPlayer4 wrapper class
+
+class CWMPPlayer4 : public CWnd
+{
+protected:
+	DECLARE_DYNCREATE(CWMPPlayer4)
+public:
+	CLSID const& GetClsid()
+	{
+		static CLSID const clsid
+			= { 0x6bf52a52, 0x394a, 0x11d3, { 0xb1, 0x53, 0x0, 0xc0, 0x4f, 0x79, 0xfa, 0xa6 } };
+		return clsid;
+	}
+	virtual BOOL Create(LPCTSTR lpszClassName,
+		LPCTSTR lpszWindowName, DWORD dwStyle,
+		const RECT& rect,
+		CWnd* pParentWnd, UINT nID,
+		CCreateContext* pContext = NULL)
+	{ return CreateControl(GetClsid(), lpszWindowName, dwStyle, rect, pParentWnd, nID); }
+
+    BOOL Create(LPCTSTR lpszWindowName, DWORD dwStyle,
+		const RECT& rect, CWnd* pParentWnd, UINT nID,
+		CFile* pPersist = NULL, BOOL bStorage = FALSE,
+		BSTR bstrLicKey = NULL)
+	{ return CreateControl(GetClsid(), lpszWindowName, dwStyle, rect, pParentWnd, nID,
+		pPersist, bStorage, bstrLicKey); }
+
+// Attributes
+public:
+
+// Operations
+public:
+	void close();
+	CString GetUrl();
+	void SetUrl(LPCTSTR lpszNewValue);
+	long GetOpenState();
+	long GetPlayState();
+	CWMPControls GetControls();
+	CWMPSettings GetSettings();
+	CWMPMedia GetCurrentMedia();
+	void SetCurrentMedia(LPDISPATCH newValue);
+	CWMPMediaCollection GetMediaCollection();
+	CWMPPlaylistCollection GetPlaylistCollection();
+	CString GetVersionInfo();
+	void launchURL(LPCTSTR bstrURL);
+	CWMPNetwork GetNetwork();
+	CWMPPlaylist GetCurrentPlaylist();
+	void SetCurrentPlaylist(LPDISPATCH newValue);
+	CWMPCdromCollection GetCdromCollection();
+	CWMPClosedCaption GetClosedCaption();
+	BOOL GetIsOnline();
+	CWMPError GetError();
+	CString GetStatus();
+	CWMPDVD GetDvd();
+	CWMPPlaylist newPlaylist(LPCTSTR bstrName, LPCTSTR bstrURL);
+	CWMPMedia newMedia(LPCTSTR bstrURL);
+	BOOL GetEnabled();
+	void SetEnabled(BOOL bNewValue);
+	BOOL GetFullScreen();
+	void SetFullScreen(BOOL bNewValue);
+	BOOL GetEnableContextMenu();
+	void SetEnableContextMenu(BOOL bNewValue);
+	void SetUiMode(LPCTSTR lpszNewValue);
+	CString GetUiMode();
+	BOOL GetStretchToFit();
+	void SetStretchToFit(BOOL bNewValue);
+	BOOL GetWindowlessVideo();
+	void SetWindowlessVideo(BOOL bNewValue);
+	BOOL GetIsRemote();
+	CWMPPlayerApplication GetPlayerApplication();
+	void openPlayer(LPCTSTR bstrURL);
+};
+
+//{{AFX_INSERT_LOCATION}}
+// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
+
+#endif // !defined(AFX_WMPPLAYER4_H__A318AE12_803B_4EED_B586_1395637CDD35__INCLUDED_)
diff --git a/plugins/wmpa/wmpplayerapplication.cpp b/plugins/wmpa/wmpplayerapplication.cpp
new file mode 100644
index 00000000..d47956a7
--- /dev/null
+++ b/plugins/wmpa/wmpplayerapplication.cpp
@@ -0,0 +1,39 @@
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+#include "stdafx.h"
+#include "wmpplayerapplication.h"
+
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPPlayerApplication properties
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPPlayerApplication operations
+
+void CWMPPlayerApplication::switchToPlayerApplication()
+{
+	InvokeHelper(0x44d, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
+}
+
+void CWMPPlayerApplication::switchToControl()
+{
+	InvokeHelper(0x44e, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
+}
+
+BOOL CWMPPlayerApplication::GetPlayerDocked()
+{
+	BOOL result;
+	InvokeHelper(0x44f, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
+	return result;
+}
+
+BOOL CWMPPlayerApplication::GetHasDisplay()
+{
+	BOOL result;
+	InvokeHelper(0x450, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
+	return result;
+}
diff --git a/plugins/wmpa/wmpplayerapplication.h b/plugins/wmpa/wmpplayerapplication.h
new file mode 100644
index 00000000..96205aae
--- /dev/null
+++ b/plugins/wmpa/wmpplayerapplication.h
@@ -0,0 +1,36 @@
+#if !defined(AFX_WMPPLAYERAPPLICATION_H__A69CB85C_22A1_4A02_979D_3FFB61135553__INCLUDED_)
+#define AFX_WMPPLAYERAPPLICATION_H__A69CB85C_22A1_4A02_979D_3FFB61135553__INCLUDED_
+
+#if _MSC_VER > 1000
+#pragma once
+#endif // _MSC_VER > 1000
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPPlayerApplication wrapper class
+
+class CWMPPlayerApplication : public COleDispatchDriver
+{
+public:
+	CWMPPlayerApplication() {}		// Calls COleDispatchDriver default constructor
+	CWMPPlayerApplication(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
+	CWMPPlayerApplication(const CWMPPlayerApplication& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
+
+// Attributes
+public:
+
+// Operations
+public:
+	void switchToPlayerApplication();
+	void switchToControl();
+	BOOL GetPlayerDocked();
+	BOOL GetHasDisplay();
+};
+
+//{{AFX_INSERT_LOCATION}}
+// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
+
+#endif // !defined(AFX_WMPPLAYERAPPLICATION_H__A69CB85C_22A1_4A02_979D_3FFB61135553__INCLUDED_)
diff --git a/plugins/wmpa/wmpplaylist.cpp b/plugins/wmpa/wmpplaylist.cpp
new file mode 100644
index 00000000..9308aa5b
--- /dev/null
+++ b/plugins/wmpa/wmpplaylist.cpp
@@ -0,0 +1,132 @@
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+#include "stdafx.h"
+#include "wmpplaylist.h"
+
+// Dispatch interfaces referenced by this interface
+#include "WMPMedia.h"
+
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPPlaylist properties
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPPlaylist operations
+
+long CWMPPlaylist::GetCount()
+{
+	long result;
+	InvokeHelper(0xc9, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+CString CWMPPlaylist::GetName()
+{
+	CString result;
+	InvokeHelper(0xca, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPPlaylist::SetName(LPCTSTR lpszNewValue)
+{
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0xca, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 lpszNewValue);
+}
+
+long CWMPPlaylist::GetAttributeCount()
+{
+	long result;
+	InvokeHelper(0xd2, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+CString CWMPPlaylist::GetAttributeName(long lIndex)
+{
+	CString result;
+	static BYTE parms[] =
+		VTS_I4;
+	InvokeHelper(0xd3, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, parms,
+		lIndex);
+	return result;
+}
+
+CWMPMedia CWMPPlaylist::GetItem(long lIndex)
+{
+	LPDISPATCH pDispatch;
+	static BYTE parms[] =
+		VTS_I4;
+	InvokeHelper(0xd4, DISPATCH_PROPERTYGET, VT_DISPATCH, (void*)&pDispatch, parms,
+		lIndex);
+	return CWMPMedia(pDispatch);
+}
+
+CString CWMPPlaylist::getItemInfo(LPCTSTR bstrName)
+{
+	CString result;
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0xcb, DISPATCH_METHOD, VT_BSTR, (void*)&result, parms,
+		bstrName);
+	return result;
+}
+
+void CWMPPlaylist::setItemInfo(LPCTSTR bstrName, LPCTSTR bstrValue)
+{
+	static BYTE parms[] =
+		VTS_BSTR VTS_BSTR;
+	InvokeHelper(0xcc, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
+		 bstrName, bstrValue);
+}
+
+BOOL CWMPPlaylist::GetIsIdentical(LPDISPATCH pIWMPPlaylist)
+{
+	BOOL result;
+	static BYTE parms[] =
+		VTS_DISPATCH;
+	InvokeHelper(0xd5, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, parms,
+		pIWMPPlaylist);
+	return result;
+}
+
+void CWMPPlaylist::clear()
+{
+	InvokeHelper(0xcd, DISPATCH_METHOD, VT_EMPTY, NULL, NULL);
+}
+
+void CWMPPlaylist::insertItem(long lIndex, LPDISPATCH pIWMPMedia)
+{
+	static BYTE parms[] =
+		VTS_I4 VTS_DISPATCH;
+	InvokeHelper(0xce, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
+		 lIndex, pIWMPMedia);
+}
+
+void CWMPPlaylist::appendItem(LPDISPATCH pIWMPMedia)
+{
+	static BYTE parms[] =
+		VTS_DISPATCH;
+	InvokeHelper(0xcf, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
+		 pIWMPMedia);
+}
+
+void CWMPPlaylist::removeItem(LPDISPATCH pIWMPMedia)
+{
+	static BYTE parms[] =
+		VTS_DISPATCH;
+	InvokeHelper(0xd0, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
+		 pIWMPMedia);
+}
+
+void CWMPPlaylist::moveItem(long lIndexOld, long lIndexNew)
+{
+	static BYTE parms[] =
+		VTS_I4 VTS_I4;
+	InvokeHelper(0xd1, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
+		 lIndexOld, lIndexNew);
+}
diff --git a/plugins/wmpa/wmpplaylist.h b/plugins/wmpa/wmpplaylist.h
new file mode 100644
index 00000000..1d28ebd1
--- /dev/null
+++ b/plugins/wmpa/wmpplaylist.h
@@ -0,0 +1,50 @@
+#if !defined(AFX_WMPPLAYLIST_H__B739DAEE_6828_4128_8A0A_E6750502339C__INCLUDED_)
+#define AFX_WMPPLAYLIST_H__B739DAEE_6828_4128_8A0A_E6750502339C__INCLUDED_
+
+#if _MSC_VER > 1000
+#pragma once
+#endif // _MSC_VER > 1000
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+// Dispatch interfaces referenced by this interface
+class CWMPMedia;
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPPlaylist wrapper class
+
+class CWMPPlaylist : public COleDispatchDriver
+{
+public:
+	CWMPPlaylist() {}		// Calls COleDispatchDriver default constructor
+	CWMPPlaylist(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
+	CWMPPlaylist(const CWMPPlaylist& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
+
+// Attributes
+public:
+
+// Operations
+public:
+	long GetCount();
+	CString GetName();
+	void SetName(LPCTSTR lpszNewValue);
+	long GetAttributeCount();
+	CString GetAttributeName(long lIndex);
+	CWMPMedia GetItem(long lIndex);
+	CString getItemInfo(LPCTSTR bstrName);
+	void setItemInfo(LPCTSTR bstrName, LPCTSTR bstrValue);
+	BOOL GetIsIdentical(LPDISPATCH pIWMPPlaylist);
+	void clear();
+	void insertItem(long lIndex, LPDISPATCH pIWMPMedia);
+	void appendItem(LPDISPATCH pIWMPMedia);
+	void removeItem(LPDISPATCH pIWMPMedia);
+	void moveItem(long lIndexOld, long lIndexNew);
+};
+
+//{{AFX_INSERT_LOCATION}}
+// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
+
+#endif // !defined(AFX_WMPPLAYLIST_H__B739DAEE_6828_4128_8A0A_E6750502339C__INCLUDED_)
diff --git a/plugins/wmpa/wmpplaylistarray.cpp b/plugins/wmpa/wmpplaylistarray.cpp
new file mode 100644
index 00000000..8baf1a87
--- /dev/null
+++ b/plugins/wmpa/wmpplaylistarray.cpp
@@ -0,0 +1,35 @@
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+#include "stdafx.h"
+#include "wmpplaylistarray.h"
+
+// Dispatch interfaces referenced by this interface
+#include "wmpplaylist.h"
+
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPPlaylistArray properties
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPPlaylistArray operations
+
+long CWMPPlaylistArray::GetCount()
+{
+	long result;
+	InvokeHelper(0x1f5, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+CWMPPlaylist CWMPPlaylistArray::Item(long lIndex)
+{
+	LPDISPATCH pDispatch;
+	static BYTE parms[] =
+		VTS_I4;
+	InvokeHelper(0x1f6, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
+		lIndex);
+	return CWMPPlaylist(pDispatch);
+}
diff --git a/plugins/wmpa/wmpplaylistarray.h b/plugins/wmpa/wmpplaylistarray.h
new file mode 100644
index 00000000..9299b42c
--- /dev/null
+++ b/plugins/wmpa/wmpplaylistarray.h
@@ -0,0 +1,38 @@
+#if !defined(AFX_WMPPLAYLISTARRAY_H__6368C8A4_18CF_4937_993F_F7FBE512B851__INCLUDED_)
+#define AFX_WMPPLAYLISTARRAY_H__6368C8A4_18CF_4937_993F_F7FBE512B851__INCLUDED_
+
+#if _MSC_VER > 1000
+#pragma once
+#endif // _MSC_VER > 1000
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+// Dispatch interfaces referenced by this interface
+class CWMPPlaylist;
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPPlaylistArray wrapper class
+
+class CWMPPlaylistArray : public COleDispatchDriver
+{
+public:
+	CWMPPlaylistArray() {}		// Calls COleDispatchDriver default constructor
+	CWMPPlaylistArray(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
+	CWMPPlaylistArray(const CWMPPlaylistArray& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
+
+// Attributes
+public:
+
+// Operations
+public:
+	long GetCount();
+	CWMPPlaylist Item(long lIndex);
+};
+
+//{{AFX_INSERT_LOCATION}}
+// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
+
+#endif // !defined(AFX_WMPPLAYLISTARRAY_H__6368C8A4_18CF_4937_993F_F7FBE512B851__INCLUDED_)
diff --git a/plugins/wmpa/wmpplaylistcollection.cpp b/plugins/wmpa/wmpplaylistcollection.cpp
new file mode 100644
index 00000000..f13c98de
--- /dev/null
+++ b/plugins/wmpa/wmpplaylistcollection.cpp
@@ -0,0 +1,82 @@
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+#include "stdafx.h"
+#include "wmpplaylistcollection.h"
+
+// Dispatch interfaces referenced by this interface
+#include "wmpplaylist.h"
+#include "WMPPlaylistArray.h"
+
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPPlaylistCollection properties
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPPlaylistCollection operations
+
+CWMPPlaylist CWMPPlaylistCollection::newPlaylist(LPCTSTR bstrName)
+{
+	LPDISPATCH pDispatch;
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x228, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
+		bstrName);
+	return CWMPPlaylist(pDispatch);
+}
+
+CWMPPlaylistArray CWMPPlaylistCollection::getAll()
+{
+	LPDISPATCH pDispatch;
+	InvokeHelper(0x229, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, NULL);
+	return CWMPPlaylistArray(pDispatch);
+}
+
+CWMPPlaylistArray CWMPPlaylistCollection::getByName(LPCTSTR bstrName)
+{
+	LPDISPATCH pDispatch;
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x22a, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
+		bstrName);
+	return CWMPPlaylistArray(pDispatch);
+}
+
+void CWMPPlaylistCollection::remove(LPDISPATCH pItem)
+{
+	static BYTE parms[] =
+		VTS_DISPATCH;
+	InvokeHelper(0x22c, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
+		 pItem);
+}
+
+void CWMPPlaylistCollection::setDeleted(LPDISPATCH pItem, BOOL varfIsDeleted)
+{
+	static BYTE parms[] =
+		VTS_DISPATCH VTS_BOOL;
+	InvokeHelper(0x230, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
+		 pItem, varfIsDeleted);
+}
+
+BOOL CWMPPlaylistCollection::isDeleted(LPDISPATCH pItem)
+{
+	BOOL result;
+	static BYTE parms[] =
+		VTS_DISPATCH;
+	InvokeHelper(0x231, DISPATCH_METHOD, VT_BOOL, (void*)&result, parms,
+		pItem);
+	return result;
+}
+
+CWMPPlaylist CWMPPlaylistCollection::importPlaylist(LPDISPATCH pItem)
+{
+	LPDISPATCH pDispatch;
+	static BYTE parms[] =
+		VTS_DISPATCH;
+	InvokeHelper(0x232, DISPATCH_METHOD, VT_DISPATCH, (void*)&pDispatch, parms,
+		pItem);
+	return CWMPPlaylist(pDispatch);
+}
diff --git a/plugins/wmpa/wmpplaylistcollection.h b/plugins/wmpa/wmpplaylistcollection.h
new file mode 100644
index 00000000..b18d95ce
--- /dev/null
+++ b/plugins/wmpa/wmpplaylistcollection.h
@@ -0,0 +1,44 @@
+#if !defined(AFX_WMPPLAYLISTCOLLECTION_H__D07F4C6A_4574_4463_8A11_4A5654E38062__INCLUDED_)
+#define AFX_WMPPLAYLISTCOLLECTION_H__D07F4C6A_4574_4463_8A11_4A5654E38062__INCLUDED_
+
+#if _MSC_VER > 1000
+#pragma once
+#endif // _MSC_VER > 1000
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+// Dispatch interfaces referenced by this interface
+class CWMPPlaylist;
+class CWMPPlaylistArray;
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPPlaylistCollection wrapper class
+
+class CWMPPlaylistCollection : public COleDispatchDriver
+{
+public:
+	CWMPPlaylistCollection() {}		// Calls COleDispatchDriver default constructor
+	CWMPPlaylistCollection(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
+	CWMPPlaylistCollection(const CWMPPlaylistCollection& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
+
+// Attributes
+public:
+
+// Operations
+public:
+	CWMPPlaylist newPlaylist(LPCTSTR bstrName);
+	CWMPPlaylistArray getAll();
+	CWMPPlaylistArray getByName(LPCTSTR bstrName);
+	void remove(LPDISPATCH pItem);
+	void setDeleted(LPDISPATCH pItem, BOOL varfIsDeleted);
+	BOOL isDeleted(LPDISPATCH pItem);
+	CWMPPlaylist importPlaylist(LPDISPATCH pItem);
+};
+
+//{{AFX_INSERT_LOCATION}}
+// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
+
+#endif // !defined(AFX_WMPPLAYLISTCOLLECTION_H__D07F4C6A_4574_4463_8A11_4A5654E38062__INCLUDED_)
diff --git a/plugins/wmpa/wmpsettings.cpp b/plugins/wmpa/wmpsettings.cpp
new file mode 100644
index 00000000..662a336a
--- /dev/null
+++ b/plugins/wmpa/wmpsettings.cpp
@@ -0,0 +1,193 @@
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+#include "stdafx.h"
+#include "wmpsettings.h"
+
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPSettings properties
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPSettings operations
+
+BOOL CWMPSettings::GetIsAvailable(LPCTSTR bstrItem)
+{
+	BOOL result;
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x71, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, parms,
+		bstrItem);
+	return result;
+}
+
+BOOL CWMPSettings::GetAutoStart()
+{
+	BOOL result;
+	InvokeHelper(0x65, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPSettings::SetAutoStart(BOOL bNewValue)
+{
+	static BYTE parms[] =
+		VTS_BOOL;
+	InvokeHelper(0x65, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 bNewValue);
+}
+
+CString CWMPSettings::GetBaseURL()
+{
+	CString result;
+	InvokeHelper(0x6c, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPSettings::SetBaseURL(LPCTSTR lpszNewValue)
+{
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x6c, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 lpszNewValue);
+}
+
+CString CWMPSettings::GetDefaultFrame()
+{
+	CString result;
+	InvokeHelper(0x6d, DISPATCH_PROPERTYGET, VT_BSTR, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPSettings::SetDefaultFrame(LPCTSTR lpszNewValue)
+{
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x6d, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 lpszNewValue);
+}
+
+BOOL CWMPSettings::GetInvokeURLs()
+{
+	BOOL result;
+	InvokeHelper(0x67, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPSettings::SetInvokeURLs(BOOL bNewValue)
+{
+	static BYTE parms[] =
+		VTS_BOOL;
+	InvokeHelper(0x67, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 bNewValue);
+}
+
+BOOL CWMPSettings::GetMute()
+{
+	BOOL result;
+	InvokeHelper(0x68, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPSettings::SetMute(BOOL bNewValue)
+{
+	static BYTE parms[] =
+		VTS_BOOL;
+	InvokeHelper(0x68, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 bNewValue);
+}
+
+long CWMPSettings::GetPlayCount()
+{
+	long result;
+	InvokeHelper(0x69, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPSettings::SetPlayCount(long nNewValue)
+{
+	static BYTE parms[] =
+		VTS_I4;
+	InvokeHelper(0x69, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 nNewValue);
+}
+
+double CWMPSettings::GetRate()
+{
+	double result;
+	InvokeHelper(0x6a, DISPATCH_PROPERTYGET, VT_R8, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPSettings::SetRate(double newValue)
+{
+	static BYTE parms[] =
+		VTS_R8;
+	InvokeHelper(0x6a, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 newValue);
+}
+
+long CWMPSettings::GetBalance()
+{
+	long result;
+	InvokeHelper(0x66, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPSettings::SetBalance(long nNewValue)
+{
+	static BYTE parms[] =
+		VTS_I4;
+	InvokeHelper(0x66, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 nNewValue);
+}
+
+long CWMPSettings::GetVolume()
+{
+	long result;
+	InvokeHelper(0x6b, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPSettings::SetVolume(long nNewValue)
+{
+	static BYTE parms[] =
+		VTS_I4;
+	InvokeHelper(0x6b, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 nNewValue);
+}
+
+BOOL CWMPSettings::getMode(LPCTSTR bstrMode)
+{
+	BOOL result;
+	static BYTE parms[] =
+		VTS_BSTR;
+	InvokeHelper(0x6e, DISPATCH_METHOD, VT_BOOL, (void*)&result, parms,
+		bstrMode);
+	return result;
+}
+
+void CWMPSettings::setMode(LPCTSTR bstrMode, BOOL varfMode)
+{
+	static BYTE parms[] =
+		VTS_BSTR VTS_BOOL;
+	InvokeHelper(0x6f, DISPATCH_METHOD, VT_EMPTY, NULL, parms,
+		 bstrMode, varfMode);
+}
+
+BOOL CWMPSettings::GetEnableErrorDialogs()
+{
+	BOOL result;
+	InvokeHelper(0x70, DISPATCH_PROPERTYGET, VT_BOOL, (void*)&result, NULL);
+	return result;
+}
+
+void CWMPSettings::SetEnableErrorDialogs(BOOL bNewValue)
+{
+	static BYTE parms[] =
+		VTS_BOOL;
+	InvokeHelper(0x70, DISPATCH_PROPERTYPUT, VT_EMPTY, NULL, parms,
+		 bNewValue);
+}
diff --git a/plugins/wmpa/wmpsettings.h b/plugins/wmpa/wmpsettings.h
new file mode 100644
index 00000000..423f7e6d
--- /dev/null
+++ b/plugins/wmpa/wmpsettings.h
@@ -0,0 +1,55 @@
+#if !defined(AFX_WMPSETTINGS_H__28D3DCCC_3E9A_48AE_97A9_3C1337309AF4__INCLUDED_)
+#define AFX_WMPSETTINGS_H__28D3DCCC_3E9A_48AE_97A9_3C1337309AF4__INCLUDED_
+
+#if _MSC_VER > 1000
+#pragma once
+#endif // _MSC_VER > 1000
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPSettings wrapper class
+
+class CWMPSettings : public COleDispatchDriver
+{
+public:
+	CWMPSettings() {}		// Calls COleDispatchDriver default constructor
+	CWMPSettings(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
+	CWMPSettings(const CWMPSettings& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
+
+// Attributes
+public:
+
+// Operations
+public:
+	BOOL GetIsAvailable(LPCTSTR bstrItem);
+	BOOL GetAutoStart();
+	void SetAutoStart(BOOL bNewValue);
+	CString GetBaseURL();
+	void SetBaseURL(LPCTSTR lpszNewValue);
+	CString GetDefaultFrame();
+	void SetDefaultFrame(LPCTSTR lpszNewValue);
+	BOOL GetInvokeURLs();
+	void SetInvokeURLs(BOOL bNewValue);
+	BOOL GetMute();
+	void SetMute(BOOL bNewValue);
+	long GetPlayCount();
+	void SetPlayCount(long nNewValue);
+	double GetRate();
+	void SetRate(double newValue);
+	long GetBalance();
+	void SetBalance(long nNewValue);
+	long GetVolume();
+	void SetVolume(long nNewValue);
+	BOOL getMode(LPCTSTR bstrMode);
+	void setMode(LPCTSTR bstrMode, BOOL varfMode);
+	BOOL GetEnableErrorDialogs();
+	void SetEnableErrorDialogs(BOOL bNewValue);
+};
+
+//{{AFX_INSERT_LOCATION}}
+// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
+
+#endif // !defined(AFX_WMPSETTINGS_H__28D3DCCC_3E9A_48AE_97A9_3C1337309AF4__INCLUDED_)
diff --git a/plugins/wmpa/wmpstringcollection.cpp b/plugins/wmpa/wmpstringcollection.cpp
new file mode 100644
index 00000000..a36d4d9c
--- /dev/null
+++ b/plugins/wmpa/wmpstringcollection.cpp
@@ -0,0 +1,32 @@
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+
+#include "stdafx.h"
+#include "wmpstringcollection.h"
+
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPStringCollection properties
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPStringCollection operations
+
+long CWMPStringCollection::GetCount()
+{
+	long result;
+	InvokeHelper(0x191, DISPATCH_PROPERTYGET, VT_I4, (void*)&result, NULL);
+	return result;
+}
+
+CString CWMPStringCollection::Item(long lIndex)
+{
+	CString result;
+	static BYTE parms[] =
+		VTS_I4;
+	InvokeHelper(0x192, DISPATCH_METHOD, VT_BSTR, (void*)&result, parms,
+		lIndex);
+	return result;
+}
diff --git a/plugins/wmpa/wmpstringcollection.h b/plugins/wmpa/wmpstringcollection.h
new file mode 100644
index 00000000..bc03db89
--- /dev/null
+++ b/plugins/wmpa/wmpstringcollection.h
@@ -0,0 +1,34 @@
+#if !defined(AFX_WMPSTRINGCOLLECTION_H__782BAE9B_652B_476D_9448_808027B17262__INCLUDED_)
+#define AFX_WMPSTRINGCOLLECTION_H__782BAE9B_652B_476D_9448_808027B17262__INCLUDED_
+
+#if _MSC_VER > 1000
+#pragma once
+#endif // _MSC_VER > 1000
+// Machine generated IDispatch wrapper class(es) created by Microsoft Visual C++
+
+// NOTE: Do not modify the contents of this file.  If this class is regenerated by
+//  Microsoft Visual C++, your modifications will be overwritten.
+
+/////////////////////////////////////////////////////////////////////////////
+// CWMPStringCollection wrapper class
+
+class CWMPStringCollection : public COleDispatchDriver
+{
+public:
+	CWMPStringCollection() {}		// Calls COleDispatchDriver default constructor
+	CWMPStringCollection(LPDISPATCH pDispatch) : COleDispatchDriver(pDispatch) {}
+	CWMPStringCollection(const CWMPStringCollection& dispatchSrc) : COleDispatchDriver(dispatchSrc) {}
+
+// Attributes
+public:
+
+// Operations
+public:
+	long GetCount();
+	CString Item(long lIndex);
+};
+
+//{{AFX_INSERT_LOCATION}}
+// Microsoft Visual C++ will insert additional declarations immediately before the previous line.
+
+#endif // !defined(AFX_WMPSTRINGCOLLECTION_H__782BAE9B_652B_476D_9448_808027B17262__INCLUDED_)
diff --git a/plugins/wmpa/xchat-plugin.cpp b/plugins/wmpa/xchat-plugin.cpp
new file mode 100644
index 00000000..c5634064
--- /dev/null
+++ b/plugins/wmpa/xchat-plugin.cpp
@@ -0,0 +1,590 @@
+/******************************************************************
+* $Id$
+*
+* $Log$
+*
+* Copyright � 2005 David Cullen, All rights reserved
+*
+******************************************************************/
+#include "stdafx.h"
+#include "xchat-plugin.h"
+#include <windows.h>
+#include <tchar.h>
+#include "wmpa.h"
+#include "WMPADialog.h"
+
+#define XMMS_SESSION 0
+
+/******************************************************************
+* Globalss
+******************************************************************/
+xchat_plugin *ph = NULL;
+CWMPPlayer4 *wmp;
+static const char subKey[] = "Software\\FlowerSoft\\WMPA";
+
+/******************************************************************
+* xchat_plugin_init
+******************************************************************/
+int xchat_plugin_init(xchat_plugin *plugin_handle,
+                      char **plugin_name,
+                      char **plugin_desc,
+                      char **plugin_version,
+                      char *arg)
+{
+   BOOL success;
+
+   ph = plugin_handle;
+
+   *plugin_name = "WMPA";
+   *plugin_desc = "Announce the current song from Windows Media Player.";
+   *plugin_version = VER_STRING;
+
+   // Show the song browser
+   success = StartWindowsMediaPlayer();
+   if (!success) {
+      xchat_printf(ph, "WMPA: Failed to show the song browser.");
+      xchat_printf(ph, "WMPA: Could not load plug-in version %s.", VER_STRING);
+      return(E_FAIL);
+   }
+
+   // Get a pointer to the Windows Media Player control
+   wmp = GetWindowsMediaPlayer();
+   if (wmp == NULL) {
+      xchat_printf(ph, "WMPA: Failed to get a pointer to the Windows Media Player interface.");
+      xchat_printf(ph, "WMPA: Could not load plug-in version %s.", VER_STRING);
+      return(E_POINTER);
+   }
+
+   // Restore the settings (need wmp first)
+   success = wmpaRestoreSettings();
+   if (!success) {
+      xchat_printf(ph, "WMPA: Failed to restore the settings.");
+   }
+
+   xchat_hook_command(ph, "auto", XCHAT_PRI_NORM, wmpaAuto, 0, 0);
+   xchat_hook_command(ph, "curr", XCHAT_PRI_NORM, wmpaCurr, 0, 0);
+   xchat_hook_command(ph, "find", XCHAT_PRI_NORM, wmpaFind, 0, 0);
+   xchat_hook_command(ph, "slist", XCHAT_PRI_NORM, wmpaList, 0, 0);
+   xchat_hook_command(ph, "next", XCHAT_PRI_NORM, wmpaNext, 0, 0);
+   xchat_hook_command(ph, "play", XCHAT_PRI_NORM, wmpaPlay, 0, 0);
+   xchat_hook_command(ph, "pause", XCHAT_PRI_NORM, wmpaPause, 0, 0);
+   xchat_hook_command(ph, "prev", XCHAT_PRI_NORM, wmpaPrev, 0, 0);
+   xchat_hook_command(ph, "song", XCHAT_PRI_NORM, wmpaSong, 0, 0);
+   xchat_hook_command(ph, "stop", XCHAT_PRI_NORM, wmpaStop, 0, 0);
+   xchat_hook_command(ph, "volume", XCHAT_PRI_NORM, wmpaVolume, 0, 0);
+   xchat_hook_command(ph, "wmpahelp", XCHAT_PRI_NORM, wmpaHelp, 0, 0);
+
+   xchat_printf(ph, "WMPA %s successfully loaded.", VER_STRING);
+   wmpaCommands();
+   xchat_printf(ph, "WMPA: e-mail me if you find any bugs: dcullen@intergate.com");
+
+   return 1;
+}
+
+/******************************************************************
+* xchat_plugin_deinit
+******************************************************************/
+int xchat_plugin_deinit(void)
+{
+   BOOL success;
+
+   xchat_printf(ph, "WMPA %s is unloading.", VER_STRING);
+
+   // Save the settings
+   success = wmpaSaveSettings();
+   if (!success) {
+      xchat_printf(ph, "WMPA: Failed to save the settings.");
+   }
+
+   wmp = NULL;
+
+   BOOL result = StopWindowsMediaPlayer();
+   if (!result) {
+      xchat_printf(ph, "WMPA could not shut down Windows Media Player.");
+   }
+
+   xchat_printf(ph, "WMPA %s has unloaded.", VER_STRING);
+   return 1;
+}
+
+/******************************************************************
+* xchat_plugin_get_info
+******************************************************************/
+void xchat_plugin_get_info(char **name, char **desc, char **version, void **reserved)
+{
+   *name = "WMPA";
+   *desc = "Announce the current song from Windows Media Player.";
+   *version = VER_STRING;
+   if (reserved) *reserved = NULL;
+}
+
+/******************************************************************
+* wmpaCommands
+******************************************************************/
+void wmpaCommands(void)
+{
+   xchat_printf(ph, "WMPA: /auto [on/off]   : Turn on/off auto announce of the current song or display the current setting");
+   xchat_printf(ph, "WMPA: /curr            : Tell what song is currently playing");
+   xchat_printf(ph, "WMPA: /find [word]     : Find songs with \"word\" in their title, create a new playlist, and play it");
+   xchat_printf(ph, "WMPA: /slist [word]    : List songs with \"word\" in their title");
+   xchat_printf(ph, "WMPA: /next            : Play the next song");
+   xchat_printf(ph, "WMPA: /play            : Play the current song");
+   xchat_printf(ph, "WMPA: /pause           : Pause the current song");
+   xchat_printf(ph, "WMPA: /prev            : Play the previous song");
+   xchat_printf(ph, "WMPA: /song            : Announce the current song from Windows Media Player in xchat");
+   xchat_printf(ph, "WMPA: /stop            : Stop the current song");
+   xchat_printf(ph, "WMPA: /volume [volume] : Set the volume (0 to 100) or display the current volume");
+   xchat_printf(ph, "WMPA: /wmpahelp        : Display this help.");
+}
+
+/******************************************************************
+* wmpaAuto
+******************************************************************/
+int wmpaAuto(char *word[], char *word_eol[], void *user_data)
+{
+   CWMPADialog *pDialog;
+   char *state;
+
+   pDialog = GetWMPADialog();
+   if (pDialog == NULL) return(XCHAT_EAT_ALL);
+
+   if (CString(word[2]).IsEmpty()) {
+      if (pDialog->autoAnnounce) {
+         state = "on";
+      }
+      else {
+         state = "off";
+      }
+   }
+   else {
+      state = word[2];
+      if (CString(state) == "on") {
+         pDialog->autoAnnounce = TRUE;
+      }
+      if (CString(state) == "off") {
+         pDialog->autoAnnounce = FALSE;
+      }
+      wmpaSaveSettings();
+   }
+
+   xchat_printf(ph, "WMPA: auto is %s", state);
+
+   return(XCHAT_EAT_ALL);
+}
+
+/******************************************************************
+* wmpaCurr
+******************************************************************/
+int wmpaCurr(char *word[], char *word_eol[], void *user_data)
+{
+   xchat_printf(ph, "WMPA: Playing %s", (LPCTSTR) wmpaGetSongTitle());
+
+   return(XCHAT_EAT_ALL);
+}
+
+/******************************************************************
+* wmpaFind
+******************************************************************/
+int wmpaFind(char *word[], char *word_eol[], void *user_data)
+{
+   long index;
+   long count;
+   long found;
+
+   if (wmp != NULL) {
+      CWMPMediaCollection mc = wmp->GetMediaCollection();
+      CWMPPlaylist all = mc.getAll();
+      CWMPPlaylistCollection pc = wmp->GetPlaylistCollection();
+      CWMPPlaylistArray pa = pc.getAll();
+      CWMPPlaylist playlist;
+      CWMPMedia media;
+
+      for (index = 0; index < pc.getAll().GetCount(); index++) {
+         if (pc.getAll().Item(index).GetName() == CString(word_eol[2])) {
+            playlist = pc.getAll().Item(index);
+            pc.remove(playlist);
+         }
+      }
+
+      playlist = pc.newPlaylist(word_eol[2]);
+
+      count = all.GetCount();
+      found = 0;
+      for (index = 0; index < count; index++) {
+         media = all.GetItem(index);
+         CString artist = media.getItemInfo("Artist");
+         CString title  = media.getItemInfo("Title");
+         CString album  = media.getItemInfo("Album");
+         if ( (artist.Find(word_eol[2]) != -1) ||
+              (title.Find(word_eol[2])  != -1) ||
+              (album.Find(word_eol[2])  != -1) ) {
+            playlist.appendItem(media);
+            found++;
+         }
+      }
+
+      if (found > 0) {
+         xchat_printf(ph, "WMPA: Found %d songs with \"%s\" in them", found, word_eol[2]);
+         wmp->SetCurrentPlaylist(playlist);
+         wmp->GetControls().play();
+         xchat_printf(ph, "WMPA: Playing %s", (LPCTSTR) wmpaGetSongTitle());
+
+         CWMPADialog *dialog = GetWMPADialog();
+         if (dialog != NULL) {
+            dialog->UpdateSongList();
+            dialog->SelectCurrentSong();
+            dialog->UpdatePlayLists();
+         }
+
+      }
+      else {
+         xchat_printf(ph, "WMPA: Could not find %s", word_eol[2]);
+      }
+
+   }
+
+   return(XCHAT_EAT_ALL);
+}
+
+/******************************************************************
+* wmpaList
+******************************************************************/
+int wmpaList(char *word[], char *word_eol[], void *user_data)
+{
+   long index;
+   long count;
+   long found;
+
+   if (wmp != NULL) {
+      xchat_printf(ph, "WMPA: Listing songs with \"%s\" in them", word_eol[2]);
+
+      CWMPMediaCollection mc = wmp->GetMediaCollection();
+      CWMPPlaylist all = mc.getAll();
+      CWMPMedia media;
+
+      count = all.GetCount();
+      found = 0;
+      for (index = 0; index < count; index++) {
+         media = all.GetItem(index);
+         CString artist = media.getItemInfo("Artist");
+         CString title  = media.getItemInfo("Title");
+         CString album  = media.getItemInfo("Album");
+         if ( (artist.Find(word_eol[2]) != -1) ||
+              (title.Find(word_eol[2])  != -1) ||
+              (album.Find(word_eol[2])  != -1) ) {
+            xchat_printf(ph, "WMPA: Found \"%s - %s (%s)\"", artist, title, album);
+            found++;
+         }
+      }
+
+      if (found > 0) {
+         if (found == 1)
+            xchat_printf(ph, "WMPA: Found %d song with \"%s\" in it", found, word_eol[2]);
+         else
+            xchat_printf(ph, "WMPA: Found %d songs with \"%s\" in them", found, word_eol[2]);
+      }
+      else {
+         xchat_printf(ph, "WMPA: Could not find any songs with \"%s\" in them", word_eol[2]);
+      }
+
+   }
+
+   return(XCHAT_EAT_ALL);
+}
+
+/******************************************************************
+* wmpaNext
+******************************************************************/
+int wmpaNext(char *word[], char *word_eol[], void *user_data)
+{
+   if (wmp != NULL) {
+      wmp->GetControls().next();
+      xchat_printf(ph, "WMPA: Playing %s", (LPCTSTR) wmpaGetSongTitle());
+   }
+   return(XCHAT_EAT_ALL);
+}
+
+/******************************************************************
+* wmpaPlay
+******************************************************************/
+int wmpaPlay(char *word[], char *word_eol[], void *user_data)
+{
+   if (wmp != NULL) {
+      wmp->GetControls().play();
+      xchat_printf(ph, "WMPA: Playing %s", (LPCTSTR) wmpaGetSongTitle());
+   }
+   return(XCHAT_EAT_ALL);
+}
+
+/******************************************************************
+* wmpaPause
+******************************************************************/
+int wmpaPause(char *word[], char *word_eol[], void *user_data)
+{
+   if (wmp != NULL) {
+      wmp->GetControls().pause();
+      xchat_printf(ph, "WMPA: Pausing %s", (LPCTSTR) wmpaGetSongTitle());
+   }
+   return(XCHAT_EAT_ALL);
+}
+
+/******************************************************************
+* wmpaPrev
+******************************************************************/
+int wmpaPrev(char *word[], char *word_eol[], void *user_data)
+{
+   if (wmp != NULL) {
+      wmp->GetControls().previous();
+      xchat_printf(ph, "WMPA: Playing %s", (LPCTSTR) wmpaGetSongTitle());
+   }
+   return(XCHAT_EAT_ALL);
+}
+
+/******************************************************************
+* wmpaSong
+******************************************************************/
+int wmpaSong(char *word[], char *word_eol[], void *user_data)
+{
+   CString songTitle = wmpaGetSongTitle();
+
+   xchat_commandf(ph, "me is playing %s", (LPCTSTR) songTitle);
+
+   return(XCHAT_EAT_ALL);
+}
+
+/******************************************************************
+* wmpaStop
+******************************************************************/
+int wmpaStop(char *word[], char *word_eol[], void *user_data)
+{
+   if (wmp != NULL) {
+      wmp->GetControls().stop();
+      xchat_printf(ph, "WMPA: Stopping %s", (LPCTSTR) wmpaGetSongTitle());
+   }
+   return(XCHAT_EAT_ALL);
+}
+
+/******************************************************************
+* wmpaHelp
+******************************************************************/
+int wmpaHelp(char *word[], char *word_eol[], void *user_data)
+{
+   xchat_printf(ph, "\n");
+   xchat_printf(ph, "WMPA %s Help", VER_STRING);
+   wmpaCommands();
+   xchat_printf(ph, "\n");
+
+   return(XCHAT_EAT_ALL);
+}
+
+/******************************************************************
+* wmpaVolume
+******************************************************************/
+int wmpaVolume(char *word[], char *word_eol[], void *user_data)
+{
+   char *endPtr;
+   long volume;
+
+   if (CString(word[2]).IsEmpty()) {
+      volume = wmp->GetSettings().GetVolume();
+   }
+   else {
+      volume = strtol(word[2], &endPtr, 10);
+
+      if ((wmp != NULL) && (volume >= 0) && (volume <= 100)) {
+         wmp->GetSettings().SetVolume(volume);
+         wmpaSaveSettings();
+      }
+   }
+
+   xchat_printf(ph, "WMPA: volume is %d", volume);
+
+   return(XCHAT_EAT_ALL);
+}
+
+/******************************************************************
+* wmpaRestoreSettings
+******************************************************************/
+BOOL wmpaRestoreSettings(void)
+{
+   CWMPADialog *pDialog;
+   DWORD type;
+   int volume;
+   BOOL autoAnnounce;
+   DWORD size;
+   BOOL result;
+
+   if (wmp == NULL) return(FALSE);
+
+   volume = 50;
+   result = GetSetting("Volume", &type, (LPBYTE) &volume, &size);
+   wmp->GetSettings().SetVolume(volume);
+
+   autoAnnounce = FALSE;
+   pDialog = GetWMPADialog();
+   if (pDialog != NULL) {
+      result = result && GetSetting("Auto", &type, (LPBYTE) &autoAnnounce, &size);
+      pDialog->autoAnnounce = autoAnnounce;
+   }
+   else {
+      result = FALSE;
+   }
+
+   return(result);
+}
+
+/******************************************************************
+* wmpaSaveSettings
+******************************************************************/
+BOOL wmpaSaveSettings(void)
+{
+   CWMPADialog *pDialog;
+   int volume;
+   BOOL autoAnnounce;
+   BOOL result;
+
+   if (wmp == NULL) return(FALSE);
+
+   volume = wmp->GetSettings().GetVolume();
+   result = SaveSetting("Volume", REG_DWORD, (CONST BYTE *) &volume, sizeof(volume));
+
+   pDialog = GetWMPADialog();
+   if (pDialog != NULL) {
+      autoAnnounce = pDialog->autoAnnounce;
+      result = result && SaveSetting("Auto", REG_DWORD, (CONST BYTE *) &autoAnnounce, sizeof(autoAnnounce));
+   }
+   else {
+      result = FALSE;
+   }
+
+   return(result);
+}
+
+/******************************************************************
+* wmpaGetSongTitle
+******************************************************************/
+CString wmpaGetSongTitle(void)
+{
+   char buffer[32];
+
+   if (wmp == NULL) return(CString());
+
+   CWMPMedia media      = wmp->GetCurrentMedia();
+   if (media == NULL) {
+      xchat_printf(ph, "WMPA: Could not get current media");
+      return(XCHAT_EAT_ALL);
+   }
+
+   CString artist       = media.getItemInfo("Artist");
+   CString title        = media.getItemInfo("Title");
+   CString album        = media.getItemInfo("Album");
+   CString bitrate      = media.getItemInfo("Bitrate");
+   CString duration     = media.GetDurationString();
+
+   long krate = strtoul((LPCTSTR) bitrate, NULL, 10) / 1000;
+   _ultoa(krate, buffer, 10);
+   bitrate = CString(buffer);
+
+   // Creatte the song title
+   CString songTitle("");
+   songTitle += artist;
+   if (songTitle.IsEmpty()) songTitle += "Various";
+   songTitle += " - ";
+   songTitle += title;
+   songTitle += " (";
+   songTitle += album;
+   songTitle += ") [";
+   songTitle += duration;
+   songTitle += "/";
+   songTitle += bitrate;
+   songTitle += "Kbps]";
+
+   return(songTitle);
+}
+
+/******************************************************************
+* SaveSetting
+******************************************************************/
+BOOL SaveSetting(LPCTSTR name, DWORD type, CONST BYTE *value, DWORD size)
+{
+   HKEY hKey;
+   DWORD disposition;
+   LONG result;
+
+   if (wmp == NULL) return(FALSE);
+   if (name == NULL) return(FALSE);
+
+   result = RegOpenKeyEx(HKEY_CURRENT_USER,
+                         subKey,
+                         0,
+                         KEY_WRITE,
+                         &hKey);
+
+   if (result != ERROR_SUCCESS) {
+      result = RegCreateKeyEx(HKEY_CURRENT_USER,
+                              subKey,
+                              0,
+                              NULL,
+                              REG_OPTION_NON_VOLATILE,
+                              KEY_WRITE,
+                              NULL,
+                              &hKey,
+                              &disposition);
+
+      if (result != ERROR_SUCCESS) return(FALSE);
+   }
+
+   result = RegSetValueEx(hKey,
+                          name,
+                          0,
+                          type,
+                          value,
+                          size);
+
+   if (result == ERROR_SUCCESS) {
+      RegCloseKey(hKey);
+      return(TRUE);
+   }
+
+   RegCloseKey(hKey);
+   return(FALSE);
+}
+
+/******************************************************************
+* GetSetting
+******************************************************************/
+BOOL GetSetting(LPCTSTR name, DWORD *type, LPBYTE value, DWORD *size)
+{
+   HKEY hKey;
+   LONG result;
+
+   if (wmp == NULL) return(FALSE);
+   if (type == NULL) return(FALSE);
+   if (value == NULL) return(FALSE);
+   if (size == NULL) return(FALSE);
+
+   result = RegOpenKeyEx(HKEY_CURRENT_USER,
+                         subKey,
+                         0,
+                         KEY_READ,
+                         &hKey);
+
+   if (result != ERROR_SUCCESS) return(FALSE);
+
+   result = RegQueryValueEx(hKey,
+                            name,
+                            0,
+                            type,
+                            value,
+                            size);
+
+   RegCloseKey(hKey);
+
+   if (result == ERROR_SUCCESS) {
+      return(TRUE);
+   }
+
+   RegCloseKey(hKey);
+   return(FALSE);
+}
+
diff --git a/plugins/wmpa/xchat-plugin.h b/plugins/wmpa/xchat-plugin.h
new file mode 100644
index 00000000..ee189ffe
--- /dev/null
+++ b/plugins/wmpa/xchat-plugin.h
@@ -0,0 +1,368 @@
+/* You can distribute this header with your plugins for easy compilation */
+#ifndef XCHAT_PLUGIN_H
+#define XCHAT_PLUGIN_H
+
+#define VER_STRING _T("1.0.2 (BETA)")
+
+#include "stdafx.h"
+#include <windows.h>
+#include <time.h>
+#include <tchar.h>
+
+#define XCHAT_IFACE_MAJOR     1
+#define XCHAT_IFACE_MINOR     9
+#define XCHAT_IFACE_MICRO     11
+#define XCHAT_IFACE_VERSION   ((XCHAT_IFACE_MAJOR * 10000) + \
+                              (XCHAT_IFACE_MINOR * 100) + \
+                              (XCHAT_IFACE_MICRO))
+
+#define XCHAT_PRI_HIGHEST  127
+#define XCHAT_PRI_HIGH     64
+#define XCHAT_PRI_NORM     0
+#define XCHAT_PRI_LOW      (-64)
+#define XCHAT_PRI_LOWEST   (-128)
+
+#define XCHAT_FD_READ      1
+#define XCHAT_FD_WRITE     2
+#define XCHAT_FD_EXCEPTION 4
+#define XCHAT_FD_NOTSOCKET 8
+
+#define XCHAT_EAT_NONE     0                                   /* pass it on through! */
+#define XCHAT_EAT_XCHAT    1                                   /* don't let xchat see this event */
+#define XCHAT_EAT_PLUGIN   2                                   /* don't let other plugins see this event */
+#define XCHAT_EAT_ALL      (XCHAT_EAT_XCHAT|XCHAT_EAT_PLUGIN)  /* don't let anything see this event */
+
+#ifdef __cplusplus
+extern "C" {
+#endif
+
+
+   typedef struct _xchat_plugin xchat_plugin;
+   typedef struct _xchat_list xchat_list;
+   typedef struct _xchat_hook xchat_hook;
+#ifndef PLUGIN_C
+   typedef struct _xchat_context xchat_context;
+#endif
+
+#ifndef PLUGIN_C
+   struct _xchat_plugin {
+      /* these are only used on win32 */
+      xchat_hook *(*xchat_hook_command) (xchat_plugin *ph,
+                                         const char *name,
+                                         int pri,
+                                         int (*callback) (char *word[], char *word_eol[], void *user_data),
+                                         const char *help_text,
+                                         void *userdata);
+      xchat_hook *(*xchat_hook_server) (xchat_plugin *ph,
+                                        const char *name,
+                                        int pri,
+                                        int (*callback) (char *word[], char *word_eol[], void *user_data),
+                                        void *userdata);
+      xchat_hook *(*xchat_hook_print) (xchat_plugin *ph,
+                                       const char *name,
+                                       int pri,
+                                       int (*callback) (char *word[], void *user_data),
+                                       void *userdata);
+      xchat_hook *(*xchat_hook_timer) (xchat_plugin *ph,
+                                       int timeout,
+                                       int (*callback) (void *user_data),
+                                       void *userdata);
+      xchat_hook *(*xchat_hook_fd) (xchat_plugin *ph,
+                                    int fd,
+                                    int flags,
+                                    int (*callback) (int fd, int flags, void *user_data),
+                                    void *userdata);
+      void *(*xchat_unhook) (xchat_plugin *ph,
+                             xchat_hook *hook);
+      void (*xchat_print) (xchat_plugin *ph,
+                           const char *text);
+      void (*xchat_printf) (xchat_plugin *ph,
+                            const char *format, ...);
+      void (*xchat_command) (xchat_plugin *ph,
+                             const char *command);
+      void (*xchat_commandf) (xchat_plugin *ph,
+                              const char *format, ...);
+      int (*xchat_nickcmp) (xchat_plugin *ph,
+                            const char *s1,
+                            const char *s2);
+      int (*xchat_set_context) (xchat_plugin *ph,
+                                xchat_context *ctx);
+      xchat_context *(*xchat_find_context) (xchat_plugin *ph,
+                                            const char *servname,
+                                            const char *channel);
+      xchat_context *(*xchat_get_context) (xchat_plugin *ph);
+      const char *(*xchat_get_info) (xchat_plugin *ph,
+                                     const char *id);
+      int (*xchat_get_prefs) (xchat_plugin *ph,
+                              const char *name,
+                              const char **string,
+                              int *integer);
+      xchat_list * (*xchat_list_get) (xchat_plugin *ph,
+                                      const char *name);
+      void (*xchat_list_free) (xchat_plugin *ph,
+                               xchat_list *xlist);
+      const char * const * (*xchat_list_fields) (xchat_plugin *ph,
+                                                 const char *name);
+      int (*xchat_list_next) (xchat_plugin *ph,
+                              xchat_list *xlist);
+      const char * (*xchat_list_str) (xchat_plugin *ph,
+                                      xchat_list *xlist,
+                                      const char *name);
+      int (*xchat_list_int) (xchat_plugin *ph,
+                             xchat_list *xlist,
+                             const char *name);
+      void * (*xchat_plugingui_add) (xchat_plugin *ph,
+                                     const char *filename,
+                                     const char *name,
+                                     const char *desc,
+                                     const char *version,
+                                     char *reserved);
+      void (*xchat_plugingui_remove) (xchat_plugin *ph,
+                                      void *handle);
+      int (*xchat_emit_print) (xchat_plugin *ph,
+                               const char *event_name, ...);
+      int (*xchat_read_fd) (xchat_plugin *ph,
+                            void *src,
+                            char *buf,
+                            int *len);
+      time_t (*xchat_list_time) (xchat_plugin *ph,
+                                 xchat_list *xlist,
+                                 const char *name);
+      char *(*xchat_gettext) (xchat_plugin *ph,
+                              const char *msgid);
+      void (*xchat_send_modes) (xchat_plugin *ph,
+                                const char **targets,
+                                int ntargets,
+                                int modes_per_line,
+                                char sign,
+                                char mode);
+      char *(*xchat_strip) (xchat_plugin *ph,
+                            const char *str,
+                            int len,
+                            int flags);
+      void (*xchat_free) (xchat_plugin *ph,
+                          void *ptr);
+   };
+#endif
+
+
+   xchat_hook *
+   xchat_hook_command (xchat_plugin *ph,
+                       const char *name,
+                       int pri,
+                       int (*callback) (char *word[], char *word_eol[], void *user_data),
+                       const char *help_text,
+                       void *userdata);
+
+   xchat_hook *
+   xchat_hook_server (xchat_plugin *ph,
+                      const char *name,
+                      int pri,
+                      int (*callback) (char *word[], char *word_eol[], void *user_data),
+                      void *userdata);
+
+   xchat_hook *
+   xchat_hook_print (xchat_plugin *ph,
+                     const char *name,
+                     int pri,
+                     int (*callback) (char *word[], void *user_data),
+                     void *userdata);
+
+   xchat_hook *
+   xchat_hook_timer (xchat_plugin *ph,
+                     int timeout,
+                     int (*callback) (void *user_data),
+                     void *userdata);
+
+   xchat_hook *
+   xchat_hook_fd (xchat_plugin *ph,
+                  int fd,
+                  int flags,
+                  int (*callback) (int fd, int flags, void *user_data),
+                  void *userdata);
+
+   void *
+   xchat_unhook (xchat_plugin *ph,
+                 xchat_hook *hook);
+
+   void
+   xchat_print (xchat_plugin *ph,
+                const char *text);
+
+   void
+   xchat_printf (xchat_plugin *ph,
+                 const char *format, ...);
+
+   void
+   xchat_command (xchat_plugin *ph,
+                  const char *command);
+
+   void
+   xchat_commandf (xchat_plugin *ph,
+                   const char *format, ...);
+
+   int
+   xchat_nickcmp (xchat_plugin *ph,
+                  const char *s1,
+                  const char *s2);
+
+   int
+   xchat_set_context (xchat_plugin *ph,
+                      xchat_context *ctx);
+
+   xchat_context *
+   xchat_find_context (xchat_plugin *ph,
+                       const char *servname,
+                       const char *channel);
+
+   xchat_context *
+   xchat_get_context (xchat_plugin *ph);
+
+   const char *
+   xchat_get_info (xchat_plugin *ph,
+                   const char *id);
+
+   int
+   xchat_get_prefs (xchat_plugin *ph,
+                    const char *name,
+                    const char **string,
+                    int *integer);
+
+   xchat_list *
+   xchat_list_get (xchat_plugin *ph,
+                   const char *name);
+
+   void
+   xchat_list_free (xchat_plugin *ph,
+                    xchat_list *xlist);
+
+   const char * const *
+   xchat_list_fields (xchat_plugin *ph,
+                      const char *name);
+
+   int
+   xchat_list_next (xchat_plugin *ph,
+                    xchat_list *xlist);
+
+   const char *
+   xchat_list_str (xchat_plugin *ph,
+                   xchat_list *xlist,
+                   const char *name);
+
+   int
+   xchat_list_int (xchat_plugin *ph,
+                   xchat_list *xlist,
+                   const char *name);
+
+   time_t
+   xchat_list_time (xchat_plugin *ph,
+                    xchat_list *xlist,
+                    const char *name);
+
+   void *
+   xchat_plugingui_add (xchat_plugin *ph,
+                        const char *filename,
+                        const char *name,
+                        const char *desc,
+                        const char *version,
+                        char *reserved);
+
+   void
+   xchat_plugingui_remove (xchat_plugin *ph,
+                           void *handle);
+
+   int
+   xchat_emit_print (xchat_plugin *ph,
+                     const char *event_name, ...);
+
+   char *
+   xchat_gettext (xchat_plugin *ph,
+                  const char *msgid);
+
+   void
+   xchat_send_modes (xchat_plugin *ph,
+                     const char **targets,
+                     int ntargets,
+                     int modes_per_line,
+                     char sign,
+                     char mode);
+
+   char *
+   xchat_strip (xchat_plugin *ph,
+                const char *str,
+                int len,
+                int flags);
+
+   void
+   xchat_free (xchat_plugin *ph,
+               void *ptr);
+
+#if !defined(PLUGIN_C) && defined(WIN32)
+#ifndef XCHAT_PLUGIN_HANDLE
+#define XCHAT_PLUGIN_HANDLE (ph)
+#endif
+#define xchat_hook_command ((XCHAT_PLUGIN_HANDLE)->xchat_hook_command)
+#define xchat_hook_server ((XCHAT_PLUGIN_HANDLE)->xchat_hook_server)
+#define xchat_hook_print ((XCHAT_PLUGIN_HANDLE)->xchat_hook_print)
+#define xchat_hook_timer ((XCHAT_PLUGIN_HANDLE)->xchat_hook_timer)
+#define xchat_hook_fd ((XCHAT_PLUGIN_HANDLE)->xchat_hook_fd)
+#define xchat_unhook ((XCHAT_PLUGIN_HANDLE)->xchat_unhook)
+#define xchat_print ((XCHAT_PLUGIN_HANDLE)->xchat_print)
+#define xchat_printf ((XCHAT_PLUGIN_HANDLE)->xchat_printf)
+#define xchat_command ((XCHAT_PLUGIN_HANDLE)->xchat_command)
+#define xchat_commandf ((XCHAT_PLUGIN_HANDLE)->xchat_commandf)
+#define xchat_nickcmp ((XCHAT_PLUGIN_HANDLE)->xchat_nickcmp)
+#define xchat_set_context ((XCHAT_PLUGIN_HANDLE)->xchat_set_context)
+#define xchat_find_context ((XCHAT_PLUGIN_HANDLE)->xchat_find_context)
+#define xchat_get_context ((XCHAT_PLUGIN_HANDLE)->xchat_get_context)
+#define xchat_get_info ((XCHAT_PLUGIN_HANDLE)->xchat_get_info)
+#define xchat_get_prefs ((XCHAT_PLUGIN_HANDLE)->xchat_get_prefs)
+#define xchat_list_get ((XCHAT_PLUGIN_HANDLE)->xchat_list_get)
+#define xchat_list_free ((XCHAT_PLUGIN_HANDLE)->xchat_list_free)
+#define xchat_list_fields ((XCHAT_PLUGIN_HANDLE)->xchat_list_fields)
+#define xchat_list_str ((XCHAT_PLUGIN_HANDLE)->xchat_list_str)
+#define xchat_list_int ((XCHAT_PLUGIN_HANDLE)->xchat_list_int)
+#define xchat_list_time ((XCHAT_PLUGIN_HANDLE)->xchat_list_time)
+#define xchat_list_next ((XCHAT_PLUGIN_HANDLE)->xchat_list_next)
+#define xchat_plugingui_add ((XCHAT_PLUGIN_HANDLE)->xchat_plugingui_add)
+#define xchat_plugingui_remove ((XCHAT_PLUGIN_HANDLE)->xchat_plugingui_remove)
+#define xchat_emit_print ((XCHAT_PLUGIN_HANDLE)->xchat_emit_print)
+#define xchat_gettext ((XCHAT_PLUGIN_HANDLE)->xchat_gettext)
+#define xchat_send_modes ((XCHAT_PLUGIN_HANDLE)->xchat_send_modes)
+#define xchat_strip ((XCHAT_PLUGIN_HANDLE)->xchat_strip)
+#define xchat_free ((XCHAT_PLUGIN_HANDLE)->xchat_free)
+#endif
+
+#ifdef __cplusplus
+}
+#endif
+
+/******************************************************************
+* Globals
+******************************************************************/
+extern xchat_plugin *ph;
+
+/******************************************************************
+* Prototypes
+******************************************************************/
+void wmpaCommands(void);
+int wmpaAuto(char *word[], char *word_eol[], void *user_data);
+int wmpaCurr(char *word[], char *word_eol[], void *user_data);
+int wmpaFind(char *word[], char *word_eol[], void *user_data);
+int wmpaList(char *word[], char *word_eol[], void *user_data);
+int wmpaNext(char *word[], char *word_eol[], void *user_data);
+int wmpaPlay(char *word[], char *word_eol[], void *user_data);
+int wmpaPause(char *word[], char *word_eol[], void *user_data);
+int wmpaPrev(char *word[], char *word_eol[], void *user_data);
+int wmpaSong(char *word[], char *word_eol[], void *user_data);
+int wmpaStop(char *word[], char *word_eol[], void *user_data);
+int wmpaVolume(char *word[], char *word_eol[], void *user_data);
+int wmpaHelp(char *word[], char *word_eol[], void *user_data);
+BOOL wmpaRestoreSettings(void);
+BOOL wmpaSaveSettings(void);
+CString wmpaGetSongTitle(void);
+BOOL SaveSetting(LPCTSTR name, DWORD type, CONST BYTE *value, DWORD size);
+BOOL GetSetting(LPCTSTR name, DWORD *type, LPBYTE value, DWORD *size);
+
+#endif /* XCHAT_PLUGIN_H */
+
diff --git a/plugins/wmpa/xchat.ico b/plugins/wmpa/xchat.ico
new file mode 100644
index 00000000..73247fd0
Binary files /dev/null and b/plugins/wmpa/xchat.ico differ
-- 
cgit 1.4.1


From 8562d1bedb1eda84b17758edc78b4354857d37c0 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Fri, 12 Aug 2011 04:52:46 +0200
Subject: add wmpa plugin

---
 build/build-small.bat             |   6 +-
 build/build-x64.bat               |   3 +-
 build/build-x86.bat               |   3 +-
 build/build.bat                   |   1 +
 build/release-x64.bat             |   3 +-
 build/release-x86.bat             |   2 +-
 build/xchat-wdk.skel.iss          |  12 +-
 plugins/makefile.mak              |  67 ++----
 plugins/wmpa/makefile.mak         |  53 +++++
 plugins/wmpa/wmpa.clw             |  43 ----
 plugins/wmpa/wmpa.def             |   3 +-
 plugins/wmpa/wmpa.dsp             | 421 --------------------------------------
 plugins/wmpa/wmpa.dsw             |  31 ---
 plugins/wmpa/wmpa.ico             | Bin 0 -> 1150 bytes
 plugins/wmpa/wmpa.plg             |  16 --
 plugins/wmpa/wmpa.rc              |   2 +-
 plugins/wmpa/wmpa.sln             |  20 ++
 plugins/wmpa/wmpa.vcxproj         | 231 +++++++++++++++++++++
 plugins/wmpa/wmpa.vcxproj.filters | 172 ++++++++++++++++
 plugins/wmpa/wmpplayer4.h         |   4 +-
 plugins/wmpa/xchat.ico            | Bin 25670 -> 0 bytes
 21 files changed, 512 insertions(+), 581 deletions(-)
 create mode 100644 plugins/wmpa/makefile.mak
 delete mode 100644 plugins/wmpa/wmpa.clw
 delete mode 100644 plugins/wmpa/wmpa.dsp
 delete mode 100644 plugins/wmpa/wmpa.dsw
 create mode 100644 plugins/wmpa/wmpa.ico
 delete mode 100644 plugins/wmpa/wmpa.plg
 create mode 100644 plugins/wmpa/wmpa.sln
 create mode 100644 plugins/wmpa/wmpa.vcxproj
 create mode 100644 plugins/wmpa/wmpa.vcxproj.filters
 delete mode 100644 plugins/wmpa/xchat.ico

(limited to 'plugins')

diff --git a/build/build-small.bat b/build/build-small.bat
index ca9f74af..cccd2af4 100644
--- a/build/build-small.bat
+++ b/build/build-small.bat
@@ -1,7 +1,7 @@
 @echo off
 set WDK_ROOT=c:\WinDDK\7600.16385.1
-set INCLUDE=%WDK_ROOT%\inc\api;%WDK_ROOT%\inc\crt;%WDK_ROOT%\inc\api\crt\stl70
-set LIB=%WDK_ROOT%\lib\wxp\i386;%WDK_ROOT%\lib\Crt\i386
+set INCLUDE=%WDK_ROOT%\inc\api;%WDK_ROOT%\inc\crt;%WDK_ROOT%\inc\api\crt\stl70;%WDK_ROOT%\inc\mfc42;%WDK_ROOT%\inc\ddk;%WDK_ROOT%\inc\api\dao360
+set LIB=%WDK_ROOT%\lib\wxp\i386;%WDK_ROOT%\lib\Crt\i386;%WDK_ROOT%\lib\Mfc\i386;%WDK_ROOT%\lib\ATL\i386
 set OPATH=%PATH%
 set DEV_32=%cd%\..\dep-x86
 set PATH=%PROGRAMFILES(X86)%\Microsoft Visual Studio 10.0\VC\bin;%PROGRAMFILES(X86)%\Microsoft Visual Studio 10.0\Common7\IDE;%PROGRAMFILES(X86)%\Microsoft SDKs\Windows\v7.0A\Bin;%DEV_32%\bin
@@ -66,8 +66,8 @@ copy ..\plugins\mpcinfo\xcmpcinfo.dll %XCHAT_DEST%\plugins
 copy ..\plugins\python\xcpython.dll %XCHAT_DEST%\plugins
 copy ..\plugins\tcl\xctcl.dll %XCHAT_DEST%\plugins
 copy ..\plugins\upd\xcupd.dll %XCHAT_DEST%\plugins
-::copy ..\plugins\xdcc\xcxdcc.dll %XCHAT_DEST%\plugins
 copy ..\plugins\xtray\xtray.dll %XCHAT_DEST%\plugins
 copy ..\plugins\winamp\xcwinamp.dll %XCHAT_DEST%\plugins
+copy ..\plugins\winamp\xcwmpa.dll %XCHAT_DEST%\plugins
 copy %DEPS_ROOT%\bin\lua51.dll %XCHAT_DEST%
 pause
diff --git a/build/build-x64.bat b/build/build-x64.bat
index 29db6400..d862736c 100644
--- a/build/build-x64.bat
+++ b/build/build-x64.bat
@@ -7,8 +7,7 @@ cd src
 echo X64 = YES > makeinc.mak
 echo DEV = %DEV_64% >> makeinc.mak
 type makeinc.skel.mak >> makeinc.mak
-set INCLUDE=%WDK_ROOT%\inc\api;%WDK_ROOT%\inc\crt;%WDK_ROOT%\inc\api\crt\stl70
-set LIB=%WDK_ROOT%\lib\wnet\amd64;%WDK_ROOT%\lib\Crt\amd64
+set LIB=%WDK_ROOT%\lib\wnet\amd64;%WDK_ROOT%\lib\Crt\amd64;%WDK_ROOT%\lib\Mfc\amd64;%WDK_ROOT%\lib\ATL\amd64
 set OPATH=%PATH%
 set PATH=%PROGRAMFILES(X86)%\Microsoft Visual Studio 10.0\VC\bin\amd64;%PROGRAMFILES(X86)%\Microsoft SDKs\Windows\v7.0A\Bin\x64;%DEV_64%\bin
 cd common
diff --git a/build/build-x86.bat b/build/build-x86.bat
index 4e7d0ef0..8cc3a30c 100644
--- a/build/build-x86.bat
+++ b/build/build-x86.bat
@@ -1,6 +1,5 @@
 @echo off
-set INCLUDE=%WDK_ROOT%\inc\api;%WDK_ROOT%\inc\crt;%WDK_ROOT%\inc\api\crt\stl70
-set LIB=%WDK_ROOT%\lib\wxp\i386;%WDK_ROOT%\lib\Crt\i386
+set LIB=%WDK_ROOT%\lib\wxp\i386;%WDK_ROOT%\lib\Crt\i386;%WDK_ROOT%\lib\Mfc\i386;%WDK_ROOT%\lib\ATL\i386
 set OPATH=%PATH%
 set DEV_32=%cd%\..\dep-x86
 set PATH=%PROGRAMFILES(X86)%\Microsoft Visual Studio 10.0\VC\bin;%PROGRAMFILES(X86)%\Microsoft Visual Studio 10.0\Common7\IDE;%PROGRAMFILES(X86)%\Microsoft SDKs\Windows\v7.0A\Bin;%DEV_32%\bin
diff --git a/build/build.bat b/build/build.bat
index 363205c0..deb7e0bc 100644
--- a/build/build.bat
+++ b/build/build.bat
@@ -1,5 +1,6 @@
 @echo off
 set WDK_ROOT=c:\WinDDK\7600.16385.1
+set INCLUDE=%WDK_ROOT%\inc\api;%WDK_ROOT%\inc\crt;%WDK_ROOT%\inc\api\crt\stl70;%WDK_ROOT%\inc\mfc42;%WDK_ROOT%\inc\ddk;%WDK_ROOT%\inc\api\dao360
 call build-x86.bat
 call build-x64.bat
 ::call compress.bat
diff --git a/build/release-x64.bat b/build/release-x64.bat
index 4c5ad3c5..08959f1d 100644
--- a/build/release-x64.bat
+++ b/build/release-x64.bat
@@ -31,7 +31,6 @@ copy %DEPS_ROOT%\bin\ssleay32.dll %XCHAT_DEST%\ssleay32.dll.x64
 copy %DEPS_ROOT%\bin\zlib1.dll %XCHAT_DEST%\zlib1.dll.x64
 copy %DEPS_ROOT%\bin\libenchant.dll %XCHAT_DEST%\libenchant.dll.x64
 copy %DEPS_ROOT%\lib\enchant\libenchant_myspell.dll %XCHAT_DEST%\lib\enchant\libenchant_myspell.dll.x64
-::copy ..\plugins\ewc\xcewc.dll %XCHAT_DEST%\plugins\xcewc.dll.x64
 copy ..\plugins\checksum\xcchecksum.dll %XCHAT_DEST%\plugins\xcchecksum.dll.x64
 copy ..\plugins\lua\xclua.dll %XCHAT_DEST%\plugins\xclua.dll.x64
 copy ..\plugins\mpcinfo\xcmpcinfo.dll %XCHAT_DEST%\plugins\xcmpcinfo.dll.x64
@@ -40,7 +39,7 @@ copy ..\plugins\perl\xcperl-514.dll %XCHAT_DEST%\plugins\xcperl-514.dll.x64
 copy ..\plugins\python\xcpython.dll %XCHAT_DEST%\plugins\xcpython.dll.x64
 copy ..\plugins\tcl\xctcl.dll %XCHAT_DEST%\plugins\xctcl.dll.x64
 copy ..\plugins\upd\xcupd.dll %XCHAT_DEST%\plugins\xcupd.dll.x64
-::copy ..\plugins\xdcc\xcxdcc.dll %XCHAT_DEST%\plugins\xcxdcc.dll.x64
 copy ..\plugins\xtray\xtray.dll %XCHAT_DEST%\plugins\xtray.dll.x64
 copy ..\plugins\winamp\xcwinamp.dll %XCHAT_DEST%\plugins\xcwinamp.dll.x64
+copy ..\plugins\winamp\xcwmpa.dll %XCHAT_DEST%\plugins\xcwmpa.dll.x64
 copy %DEPS_ROOT%\bin\lua51.dll %XCHAT_DEST%\lua51.dll.x64
diff --git a/build/release-x86.bat b/build/release-x86.bat
index 7deebb31..cd246318 100644
--- a/build/release-x86.bat
+++ b/build/release-x86.bat
@@ -54,9 +54,9 @@ copy ..\plugins\perl\xcperl-514.dll %XCHAT_DEST%\plugins
 copy ..\plugins\python\xcpython.dll %XCHAT_DEST%\plugins
 copy ..\plugins\tcl\xctcl.dll %XCHAT_DEST%\plugins
 copy ..\plugins\upd\xcupd.dll %XCHAT_DEST%\plugins
-::copy ..\plugins\xdcc\xcxdcc.dll %XCHAT_DEST%\plugins
 copy ..\plugins\xtray\xtray.dll %XCHAT_DEST%\plugins
 copy ..\plugins\winamp\xcwinamp.dll %XCHAT_DEST%\plugins
+copy ..\plugins\winamp\xcwmpa.dll %XCHAT_DEST%\plugins
 copy %DEPS_ROOT%\bin\lua51.dll %XCHAT_DEST%
 xcopy /q /s /i ..\po\locale %XCHAT_DEST%\locale
 xcopy /q /s /i %DEPS_ROOT%\share\locale %XCHAT_DEST%\share\locale
diff --git a/build/xchat-wdk.skel.iss b/build/xchat-wdk.skel.iss
index 3fc93f13..afefe28a 100644
--- a/build/xchat-wdk.skel.iss
+++ b/build/xchat-wdk.skel.iss
@@ -33,12 +33,11 @@ Name: "xctext"; Description: "XChat-Text"; Types: full custom; Flags: disablenou
 Name: "translations"; Description: "Translations"; Types: normal full custom; Flags: disablenouninstallwarning
 ;Name: "spelling"; Description: "Spelling Dictionaries"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins"; Description: "Plugins"; Types: full custom; Flags: disablenouninstallwarning
-;Name: "plugins\ewc"; Description: "EasyWinampControl"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\checksum"; Description: "Checksum"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\mpcinfo"; Description: "mpcInfo"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\upd"; Description: "Update Checker"; Types: normal full custom; Flags: disablenouninstallwarning
 Name: "plugins\winamp"; Description: "Winamp"; Types: full custom; Flags: disablenouninstallwarning
-;Name: "plugins\xdcc"; Description: "XDCC"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\wmpa"; Description: "Windows Media Player Announcer"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\xtray"; Description: "X-Tray"; Types: full custom; Flags: disablenouninstallwarning
 Name: "langs"; Description: "Language Interfaces"; Types: full custom; Flags: disablenouninstallwarning
 Name: "langs\lua"; Description: "Lua"; Types: full custom; Flags: disablenouninstallwarning
@@ -189,9 +188,6 @@ Source: "xchat-text.exe.x64"; DestDir: "{app}"; DestName: "xchat-text.exe"; Comp
 
 
 
-;Source: "plugins\xcewc.dll"; DestDir: "{app}\plugins"; Components: plugins\ewc; Tasks: x86
-;Source: "plugins\xcewc.dll.x64"; DestDir: "{app}\plugins"; DestName: "xcewc.dll"; Components: plugins\ewc; Tasks: x64
-
 Source: "plugins\xcchecksum.dll"; DestDir: "{app}\plugins"; Components: plugins\checksum; Tasks: x86
 Source: "plugins\xcchecksum.dll.x64"; DestDir: "{app}\plugins"; DestName: "xcchecksum.dll"; Components: plugins\checksum; Tasks: x64
 
@@ -204,12 +200,12 @@ Source: "plugins\xcupd.dll.x64"; DestDir: "{app}\plugins"; DestName: "xcupd.dll"
 Source: "plugins\xcwinamp.dll"; DestDir: "{app}\plugins"; Components: plugins\winamp; Tasks: x86
 Source: "plugins\xcwinamp.dll.x64"; DestDir: "{app}\plugins"; DestName: "xcwinamp.dll"; Components: plugins\winamp; Tasks: x64
 
-;Source: "plugins\xcxdcc.dll"; DestDir: "{app}\plugins"; Components: plugins\xdcc; Tasks: x86
-;Source: "plugins\xcxdcc.dll.x64"; DestDir: "{app}\plugins"; DestName: "xcxdcc.dll"; Components: plugins\xdcc; Tasks: x64
-
 Source: "plugins\xtray.dll"; DestDir: "{app}\plugins"; Components: plugins\xtray; Tasks: x86
 Source: "plugins\xtray.dll.x64"; DestDir: "{app}\plugins"; DestName: "xtray.dll"; Components: plugins\xtray; Tasks: x64
 
+Source: "plugins\xcwmpa.dll"; DestDir: "{app}\plugins"; Components: plugins\wmpa; Tasks: x86
+Source: "plugins\xcwmpa.dll.x64"; DestDir: "{app}\plugins"; DestName: "xcwmpa.dll"; Components: plugins\wmpa; Tasks: x64
+
 
 
 Source: "plugins\xclua.dll"; DestDir: "{app}\plugins"; Components: langs\lua; Tasks: x86
diff --git a/plugins/makefile.mak b/plugins/makefile.mak
index d15c7f84..e56a2db7 100644
--- a/plugins/makefile.mak
+++ b/plugins/makefile.mak
@@ -11,56 +11,29 @@ all:
 	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\upd
 	@-$(MAKE) /nologo /s /f makefile.mak $@
-#	@cd ..\xdcc
-#	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\xtray
 	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\winamp
 	@-$(MAKE) /nologo /s /f makefile.mak $@	
+	@cd ..\wmpa
+	@-$(MAKE) /nologo /s /f makefile.mak $@
 
 clean:
-	@del checksum\*.def
-	@del checksum\*.dll
-	@del checksum\*.exp
-	@del checksum\*.lib
-	@del checksum\*.obj
-	@del lua\*.def
-	@del lua\*.dll
-	@del lua\*.exp
-	@del lua\*.lib
-	@del lua\*.obj
-	@del mpcinfo\*.def
-	@del mpcinfo\*.dll
-	@del mpcinfo\*.exp
-	@del mpcinfo\*.lib
-	@del mpcinfo\*.obj
-	@del python\*.def
-	@del python\*.dll
-	@del python\*.exp
-	@del python\*.lib
-	@del python\*.obj
-	@del tcl\*.def
-	@del tcl\*.dll
-	@del tcl\*.exp
-	@del tcl\*.lib
-	@del tcl\*.obj
-	@del upd\*.def
-	@del upd\*.dll
-	@del upd\*.exp
-	@del upd\*.lib
-	@del upd\*.obj
-#	@del xdcc\*.def
-#	@del xdcc\*.dll
-#	@del xdcc\*.exp
-#	@del xdcc\*.lib
-#	@del xdcc\*.obj
-	@del xtray\*.def
-	@del xtray\*.dll
-	@del xtray\*.exp
-	@del xtray\*.lib
-	@del xtray\*.obj
-	@del winamp\*.def
-	@del winamp\*.dll
-	@del winamp\*.exp
-	@del winamp\*.lib
-	@del winamp\*.obj	
+	@cd checksum
+	@-$(MAKE) /nologo /s /f makefile.mak clean $@
+	@cd ..\lua
+	@-$(MAKE) /nologo /s /f makefile.mak clean $@
+	@cd ..\mpcinfo
+	@-$(MAKE) /nologo /s /f makefile.mak clean $@
+	@cd ..\python
+	@-$(MAKE) /nologo /s /f makefile.mak clean $@
+	@cd ..\tcl
+	@-$(MAKE) /nologo /s /f makefile.mak clean $@
+	@cd ..\upd
+	@-$(MAKE) /nologo /s /f makefile.mak clean $@
+	@cd ..\xtray
+	@-$(MAKE) /nologo /s /f makefile.mak clean $@
+	@cd ..\winamp
+	@-$(MAKE) /nologo /s /f makefile.mak clean $@
+	@cd ..\wmpa
+	@-$(MAKE) /nologo /s /f makefile.mak clean $@
diff --git a/plugins/wmpa/makefile.mak b/plugins/wmpa/makefile.mak
new file mode 100644
index 00000000..37e0ecd0
--- /dev/null
+++ b/plugins/wmpa/makefile.mak
@@ -0,0 +1,53 @@
+include "..\..\src\makeinc.mak"
+
+TARGET = xcwmpa.dll
+
+WMPA_OBJECTS = \
+wmpa.obj \
+wmpadialog.obj \
+wmpcdrom.obj \
+wmpcdromcollection.obj \
+wmpclosedcaption.obj \
+wmpcontrols.obj \
+wmpdvd.obj \
+wmperror.obj \
+wmperroritem.obj \
+wmpmedia.obj \
+wmpmediacollection.obj \
+wmpnetwork.obj \
+wmpplayer4.obj \
+wmpplayerapplication.obj \
+wmpplaylist.obj \
+wmpplaylistarray.obj \
+wmpplaylistcollection.obj \
+wmpsettings.obj \
+wmpstringcollection.obj \
+xchat-plugin.obj
+
+CPPFLAGS = $(CPPFLAGS) /EHsc /D_AFXDLL /D_AFX_NO_DAO_SUPPORT /D_WINDLL /D_USRDLL 
+
+all: $(WMPA_OBJECTS) $(TARGET)
+
+.cpp.obj:
+	$(CC) $(CPPFLAGS) /Yc"StdAfx.h" /Fp"wmpa.pch" StdAfx.cpp
+	$(CC) $(CPPFLAGS) /Yu"StdAfx.h" /Fp"wmpa.pch" /c $<
+
+$(TARGET): $(WMPA_OBJECTS)
+	rc /nologo /D_AFXDLL wmpa.rc
+!ifdef X64
+	midl /nologo /mktyplib203 /char signed /env x64 /h wmpa_h.h /tlb wmpa.tlb wmpa.odl
+!else
+	midl /nologo /mktyplib203 /char signed /env win32 /h wmpa_h.h /tlb wmpa.tlb wmpa.odl
+!endif
+	$(LINK) /DLL /out:$(TARGET) $(LDFLAGS) $(WMPA_OBJECTS) $(LIBS) /def:wmpa.def wmpa.res
+
+clean:
+	del $(TARGET)
+	del *.obj
+	del wmpa.pch
+	del wmpa.res
+	del wmpa.tlb
+	del wmpa_h.h
+	del wmpa_i.c
+	del *.exp
+	del *.lib
diff --git a/plugins/wmpa/wmpa.clw b/plugins/wmpa/wmpa.clw
deleted file mode 100644
index 6d850e3e..00000000
--- a/plugins/wmpa/wmpa.clw
+++ /dev/null
@@ -1,43 +0,0 @@
-; CLW file contains information for the MFC ClassWizard
-
-[General Info]
-Version=1
-ODLFile=wmpa.odl
-ClassCount=2
-Class1=CWmpaApp
-LastClass=CWMPADialog
-NewFileInclude2=#include "wmpa.h"
-ResourceCount=1
-NewFileInclude1=#include "stdafx.h"
-Class2=CWMPADialog
-LastTemplate=CDialog
-Resource1=IDD_WMPADIALOG
-
-[CLS:CWmpaApp]
-Type=0
-HeaderFile=wmpa.h
-ImplementationFile=wmpa.cpp
-Filter=N
-LastObject=CWmpaApp
-BaseClass=CWinApp
-VirtualFilter=AC
-
-[DLG:IDD_WMPADIALOG]
-Type=1
-Class=CWMPADialog
-ControlCount=5
-Control1=IDC_PLAYLIST,listbox,1353777409
-Control2=IDC_STATIC1,static,1342308352
-Control3=IDC_WMP,{6BF52A52-394A-11D3-B153-00C04F79FAA6},1342242816
-Control4=IDC_SONGLIST,listbox,1352728833
-Control5=IDC_STATIC2,static,1342308352
-
-[CLS:CWMPADialog]
-Type=0
-HeaderFile=wmpadialog.h
-ImplementationFile=wmpadialog.cpp
-BaseClass=CDialog
-LastObject=CWMPADialog
-Filter=D
-VirtualFilter=dWC
-
diff --git a/plugins/wmpa/wmpa.def b/plugins/wmpa/wmpa.def
index d3162b7d..3555558e 100644
--- a/plugins/wmpa/wmpa.def
+++ b/plugins/wmpa/wmpa.def
@@ -1,7 +1,6 @@
 ; wmpa.def : Declares the module parameters for the DLL.
 
-LIBRARY      "wmpa"
-DESCRIPTION  'wmpa Windows Dynamic Link Library'
+LIBRARY      "xcwmpa"
 
 EXPORTS
     ; Explicit exports can go here
diff --git a/plugins/wmpa/wmpa.dsp b/plugins/wmpa/wmpa.dsp
deleted file mode 100644
index 6f2e7458..00000000
--- a/plugins/wmpa/wmpa.dsp
+++ /dev/null
@@ -1,421 +0,0 @@
-# Microsoft Developer Studio Project File - Name="wmpa" - Package Owner=<4>
-# Microsoft Developer Studio Generated Build File, Format Version 6.00
-# ** DO NOT EDIT **
-
-# TARGTYPE "Win32 (x86) Dynamic-Link Library" 0x0102
-
-CFG=wmpa - Win32 Debug
-!MESSAGE This is not a valid makefile. To build this project using NMAKE,
-!MESSAGE use the Export Makefile command and run
-!MESSAGE 
-!MESSAGE NMAKE /f "wmpa.mak".
-!MESSAGE 
-!MESSAGE You can specify a configuration when running NMAKE
-!MESSAGE by defining the macro CFG on the command line. For example:
-!MESSAGE 
-!MESSAGE NMAKE /f "wmpa.mak" CFG="wmpa - Win32 Debug"
-!MESSAGE 
-!MESSAGE Possible choices for configuration are:
-!MESSAGE 
-!MESSAGE "wmpa - Win32 Release" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE "wmpa - Win32 Debug" (based on "Win32 (x86) Dynamic-Link Library")
-!MESSAGE 
-
-# Begin Project
-# PROP AllowPerConfigDependencies 0
-# PROP Scc_ProjName ""
-# PROP Scc_LocalPath ""
-CPP=cl.exe
-MTL=midl.exe
-RSC=rc.exe
-
-!IF  "$(CFG)" == "wmpa - Win32 Release"
-
-# PROP BASE Use_MFC 6
-# PROP BASE Use_Debug_Libraries 0
-# PROP BASE Output_Dir "Release"
-# PROP BASE Intermediate_Dir "Release"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 6
-# PROP Use_Debug_Libraries 0
-# PROP Output_Dir "Release"
-# PROP Intermediate_Dir "Release"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MD /W3 /GX /O2 /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_WINDLL" /D "_AFXDLL" /Yu"stdafx.h" /FD /c
-# ADD CPP /nologo /MD /W3 /GX /O2 /I "C:\Program Files\Microsoft Platform SDK\Include" /D "WIN32" /D "NDEBUG" /D "_WINDOWS" /D "_WINDLL" /D "_AFXDLL" /D "_MBCS" /D "_USRDLL" /Yu"stdafx.h" /FD /c
-# ADD BASE MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "NDEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "NDEBUG" /d "_AFXDLL"
-# ADD RSC /l 0x409 /d "NDEBUG" /d "_AFXDLL"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 /nologo /subsystem:windows /dll /machine:I386
-# ADD LINK32 /nologo /subsystem:windows /dll /machine:I386
-# Begin Custom Build
-InputPath=.\Release\wmpa.dll
-InputName=wmpa
-SOURCE="$(InputPath)"
-
-"C:\msys\1.0\local\src\xchat\src\fe-gtk\plugins\$(InputName).dll" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
-	copy /Y $(InputPath) "C:\msys\1.0\local\src\xchat\src\fe-gtk\plugins\$(InputName).dll"
-
-# End Custom Build
-
-!ELSEIF  "$(CFG)" == "wmpa - Win32 Debug"
-
-# PROP BASE Use_MFC 6
-# PROP BASE Use_Debug_Libraries 1
-# PROP BASE Output_Dir "Debug"
-# PROP BASE Intermediate_Dir "Debug"
-# PROP BASE Target_Dir ""
-# PROP Use_MFC 6
-# PROP Use_Debug_Libraries 1
-# PROP Output_Dir "Debug"
-# PROP Intermediate_Dir "Debug"
-# PROP Ignore_Export_Lib 0
-# PROP Target_Dir ""
-# ADD BASE CPP /nologo /MDd /W3 /Gm /GX /ZI /Od /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_WINDLL" /D "_AFXDLL" /Yu"stdafx.h" /FD /GZ /c
-# ADD CPP /nologo /MDd /W4 /Gm /GX /ZI /Od /I "C:\Program Files\Microsoft Platform SDK\Include" /D "WIN32" /D "_DEBUG" /D "_WINDOWS" /D "_WINDLL" /D "_AFXDLL" /D "_MBCS" /D "_USRDLL" /FR /Yu"stdafx.h" /FD /GZ /c
-# ADD BASE MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD MTL /nologo /D "_DEBUG" /mktyplib203 /win32
-# ADD BASE RSC /l 0x409 /d "_DEBUG" /d "_AFXDLL"
-# ADD RSC /l 0x409 /d "_DEBUG" /d "_AFXDLL"
-BSC32=bscmake.exe
-# ADD BASE BSC32 /nologo
-# ADD BSC32 /nologo
-LINK32=link.exe
-# ADD BASE LINK32 /nologo /subsystem:windows /dll /debug /machine:I386 /pdbtype:sept
-# ADD LINK32 /nologo /subsystem:windows /dll /debug /machine:I386 /pdbtype:sept
-# Begin Custom Build
-InputPath=.\Debug\wmpa.dll
-InputName=wmpa
-SOURCE="$(InputPath)"
-
-"C:\msys\1.0\local\src\xchat\src\fe-gtk\plugins\$(InputName).dll" : $(SOURCE) "$(INTDIR)" "$(OUTDIR)"
-	copy /Y $(InputPath) "C:\msys\1.0\local\src\xchat\src\fe-gtk\plugins\$(InputName).dll"
-
-# End Custom Build
-
-!ENDIF 
-
-# Begin Target
-
-# Name "wmpa - Win32 Release"
-# Name "wmpa - Win32 Debug"
-# Begin Group "Source Files"
-
-# PROP Default_Filter "cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
-# Begin Source File
-
-SOURCE=.\StdAfx.cpp
-# ADD CPP /Yc"stdafx.h"
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpa.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpa.def
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpa.odl
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpa.rc
-# End Source File
-# Begin Source File
-
-SOURCE=.\WMPADialog.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpcdrom.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpcdromcollection.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpclosedcaption.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpcontrols.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpdvd.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmperror.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmperroritem.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpmedia.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpmediacollection.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpnetwork.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpplayer4.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpplayerapplication.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpplaylist.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpplaylistarray.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpplaylistcollection.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpsettings.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpstringcollection.cpp
-# End Source File
-# Begin Source File
-
-SOURCE=".\xchat-plugin.cpp"
-# End Source File
-# End Group
-# Begin Group "Header Files"
-
-# PROP Default_Filter "h;hpp;hxx;hm;inl"
-# Begin Source File
-
-SOURCE=.\Resource.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\StdAfx.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpa.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\WMPADIALOG.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpcdrom.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpcdromcollection.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpclosedcaption.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpcontrols.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpdvd.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmperror.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmperroritem.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpmedia.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpmediacollection.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpnetwork.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpplayer4.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpplayerapplication.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpplaylist.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpplaylistarray.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpplaylistcollection.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpsettings.h
-# End Source File
-# Begin Source File
-
-SOURCE=.\wmpstringcollection.h
-# End Source File
-# Begin Source File
-
-SOURCE=".\xchat-plugin.h"
-# End Source File
-# End Group
-# Begin Group "Resource Files"
-
-# PROP Default_Filter "ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe"
-# Begin Source File
-
-SOURCE=.\res\wmpa.rc2
-# End Source File
-# Begin Source File
-
-SOURCE=.\xchat.ico
-# End Source File
-# End Group
-# Begin Source File
-
-SOURCE=.\ReadMe.txt
-# End Source File
-# End Target
-# End Project
-# Section wmpa : {10A13217-23A7-439B-B1C0-D847C79B7774}
-# 	2:5:Class:CWMPPlaylistCollection
-# 	2:10:HeaderFile:wmpplaylistcollection.h
-# 	2:8:ImplFile:wmpplaylistcollection.cpp
-# End Section
-# Section wmpa : {EC21B779-EDEF-462D-BBA4-AD9DDE2B29A7}
-# 	2:5:Class:CWMPNetwork
-# 	2:10:HeaderFile:wmpnetwork.h
-# 	2:8:ImplFile:wmpnetwork.cpp
-# End Section
-# Section wmpa : {4A976298-8C0D-11D3-B389-00C04F68574B}
-# 	2:5:Class:CWMPStringCollection
-# 	2:10:HeaderFile:wmpstringcollection.h
-# 	2:8:ImplFile:wmpstringcollection.cpp
-# End Section
-# Section wmpa : {B7ABC220-DF71-11CF-8E74-00A0C90F26F8}
-# 	2:5:Class:Cmci
-# 	2:10:HeaderFile:mci.h
-# 	2:8:ImplFile:mci.cpp
-# End Section
-# Section wmpa : {8363BC22-B4B4-4B19-989D-1CD765749DD1}
-# 	2:5:Class:CWMPMediaCollection
-# 	2:10:HeaderFile:wmpmediacollection.h
-# 	2:8:ImplFile:wmpmediacollection.cpp
-# End Section
-# Section wmpa : {679409C0-99F7-11D3-9FB7-00105AA620BB}
-# 	2:5:Class:CWMPPlaylistArray
-# 	2:10:HeaderFile:wmpplaylistarray.h
-# 	2:8:ImplFile:wmpplaylistarray.cpp
-# End Section
-# Section wmpa : {74C09E02-F828-11D2-A74B-00A0C905F36E}
-# 	2:5:Class:CWMPControls
-# 	2:10:HeaderFile:wmpcontrols.h
-# 	2:8:ImplFile:wmpcontrols.cpp
-# End Section
-# Section wmpa : {CFAB6E98-8730-11D3-B388-00C04F68574B}
-# 	2:5:Class:CWMPCdrom
-# 	2:10:HeaderFile:wmpcdrom.h
-# 	2:8:ImplFile:wmpcdrom.cpp
-# End Section
-# Section wmpa : {8DA61686-4668-4A5C-AE5D-803193293DBE}
-# 	2:5:Class:CWMPDVD
-# 	2:10:HeaderFile:wmpdvd.h
-# 	2:8:ImplFile:wmpdvd.cpp
-# End Section
-# Section wmpa : {6C497D62-8919-413C-82DB-E935FB3EC584}
-# 	2:5:Class:CWMPPlayer4
-# 	2:10:HeaderFile:wmpplayer4.h
-# 	2:8:ImplFile:wmpplayer4.cpp
-# End Section
-# Section wmpa : {40897764-CEAB-47BE-AD4A-8E28537F9BBF}
-# 	2:5:Class:CWMPPlayerApplication
-# 	2:10:HeaderFile:wmpplayerapplication.h
-# 	2:8:ImplFile:wmpplayerapplication.cpp
-# End Section
-# Section wmpa : {6BF52A52-394A-11D3-B153-00C04F79FAA6}
-# 	2:21:DefaultSinkHeaderFile:wmpplayer4.h
-# 	2:16:DefaultSinkClass:CWMPPlayer4
-# End Section
-# Section wmpa : {C1A8AF25-1257-101B-8FB0-0020AF039CA3}
-# 	2:21:DefaultSinkHeaderFile:mci.h
-# 	2:16:DefaultSinkClass:Cmci
-# End Section
-# Section wmpa : {9104D1AB-80C9-4FED-ABF0-2E6417A6DF14}
-# 	2:5:Class:CWMPSettings
-# 	2:10:HeaderFile:wmpsettings.h
-# 	2:8:ImplFile:wmpsettings.cpp
-# End Section
-# Section wmpa : {A12DCF7D-14AB-4C1B-A8CD-63909F06025B}
-# 	2:5:Class:CWMPError
-# 	2:10:HeaderFile:wmperror.h
-# 	2:8:ImplFile:wmperror.cpp
-# End Section
-# Section wmpa : {7BF80981-BF32-101A-8BBB-00AA00300CAB}
-# 	2:5:Class:CPicture
-# 	2:10:HeaderFile:picture.h
-# 	2:8:ImplFile:picture.cpp
-# End Section
-# Section wmpa : {D5F0F4F1-130C-11D3-B14E-00C04F79FAA6}
-# 	2:5:Class:CWMPPlaylist
-# 	2:10:HeaderFile:wmpplaylist.h
-# 	2:8:ImplFile:wmpplaylist.cpp
-# End Section
-# Section wmpa : {EE4C8FE2-34B2-11D3-A3BF-006097C9B344}
-# 	2:5:Class:CWMPCdromCollection
-# 	2:10:HeaderFile:wmpcdromcollection.h
-# 	2:8:ImplFile:wmpcdromcollection.cpp
-# End Section
-# Section wmpa : {4F2DF574-C588-11D3-9ED0-00C04FB6E937}
-# 	2:5:Class:CWMPClosedCaption
-# 	2:10:HeaderFile:wmpclosedcaption.h
-# 	2:8:ImplFile:wmpclosedcaption.cpp
-# End Section
-# Section wmpa : {94D55E95-3FAC-11D3-B155-00C04F79FAA6}
-# 	2:5:Class:CWMPMedia
-# 	2:10:HeaderFile:wmpmedia.h
-# 	2:8:ImplFile:wmpmedia.cpp
-# End Section
-# Section wmpa : {3614C646-3B3B-4DE7-A81E-930E3F2127B3}
-# 	2:5:Class:CWMPErrorItem
-# 	2:10:HeaderFile:wmperroritem.h
-# 	2:8:ImplFile:wmperroritem.cpp
-# End Section
diff --git a/plugins/wmpa/wmpa.dsw b/plugins/wmpa/wmpa.dsw
deleted file mode 100644
index e0098b15..00000000
--- a/plugins/wmpa/wmpa.dsw
+++ /dev/null
@@ -1,31 +0,0 @@
-Microsoft Developer Studio Workspace File, Format Version 6.00
-# WARNING: DO NOT EDIT OR DELETE THIS WORKSPACE FILE!
-
-###############################################################################
-
-Project: "wmpa"=".\wmpa.dsp" - Package Owner=<4>
-
-Package=<5>
-{{{
-}}}
-
-Package=<4>
-{{{
-}}}
-
-###############################################################################
-
-Global:
-
-Package=<5>
-{{{
-}}}
-
-Package=<3>
-{{{
-    {6BF52A52-394A-11D3-B153-00C04F79FAA6}
-    {C1A8AF25-1257-101B-8FB0-0020AF039CA3}
-}}}
-
-###############################################################################
-
diff --git a/plugins/wmpa/wmpa.ico b/plugins/wmpa/wmpa.ico
new file mode 100644
index 00000000..fb781daa
Binary files /dev/null and b/plugins/wmpa/wmpa.ico differ
diff --git a/plugins/wmpa/wmpa.plg b/plugins/wmpa/wmpa.plg
deleted file mode 100644
index a1b967ae..00000000
--- a/plugins/wmpa/wmpa.plg
+++ /dev/null
@@ -1,16 +0,0 @@
-<html>
-<body>
-<pre>
-<h1>Build Log</h1>
-<h3>
---------------------Configuration: wmpa - Win32 Release--------------------
-</h3>
-<h3>Command Lines</h3>
-
-
-
-<h3>Results</h3>
-wmpa.dll - 0 error(s), 0 warning(s)
-</pre>
-</body>
-</html>
diff --git a/plugins/wmpa/wmpa.rc b/plugins/wmpa/wmpa.rc
index 367805a5..4f3d239a 100644
--- a/plugins/wmpa/wmpa.rc
+++ b/plugins/wmpa/wmpa.rc
@@ -174,7 +174,7 @@ END
 
 // Icon with lowest ID value placed first to ensure application icon
 // remains consistent on all systems.
-IDI_XCHAT               ICON    DISCARDABLE     "xchat.ico"
+IDI_XCHAT               ICON    DISCARDABLE     "wmpa.ico"
 #endif    // English (U.S.) resources
 /////////////////////////////////////////////////////////////////////////////
 
diff --git a/plugins/wmpa/wmpa.sln b/plugins/wmpa/wmpa.sln
new file mode 100644
index 00000000..a3b71091
--- /dev/null
+++ b/plugins/wmpa/wmpa.sln
@@ -0,0 +1,20 @@
+
+Microsoft Visual Studio Solution File, Format Version 11.00
+# Visual Studio 2010
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "wmpa", "wmpa.vcxproj", "{08AD7C4D-DDDC-9545-A8D7-1808E6056143}"
+EndProject
+Global
+	GlobalSection(SolutionConfigurationPlatforms) = preSolution
+		Release|Win32 = Release|Win32
+		Release|x64 = Release|x64
+	EndGlobalSection
+	GlobalSection(ProjectConfigurationPlatforms) = postSolution
+		{08AD7C4D-DDDC-9545-A8D7-1808E6056143}.Release|Win32.ActiveCfg = Release|Win32
+		{08AD7C4D-DDDC-9545-A8D7-1808E6056143}.Release|Win32.Build.0 = Release|Win32
+		{08AD7C4D-DDDC-9545-A8D7-1808E6056143}.Release|x64.ActiveCfg = Release|x64
+		{08AD7C4D-DDDC-9545-A8D7-1808E6056143}.Release|x64.Build.0 = Release|x64
+	EndGlobalSection
+	GlobalSection(SolutionProperties) = preSolution
+		HideSolutionNode = FALSE
+	EndGlobalSection
+EndGlobal
diff --git a/plugins/wmpa/wmpa.vcxproj b/plugins/wmpa/wmpa.vcxproj
new file mode 100644
index 00000000..919c2c00
--- /dev/null
+++ b/plugins/wmpa/wmpa.vcxproj
@@ -0,0 +1,231 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup Label="ProjectConfigurations">
+    <ProjectConfiguration Include="Release|Win32">
+      <Configuration>Release</Configuration>
+      <Platform>Win32</Platform>
+    </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
+  </ItemGroup>
+  <PropertyGroup Label="Globals">
+    <SccProjectName />
+    <SccLocalPath />
+    <Keyword>MFCProj</Keyword>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseOfMfc>Dynamic</UseOfMfc>
+    <CharacterSet>MultiByte</CharacterSet>
+  </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseOfMfc>Dynamic</UseOfMfc>
+    <CharacterSet>MultiByte</CharacterSet>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
+  <ImportGroup Label="ExtensionSettings">
+  </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="$(VCTargetsPath)Microsoft.Cpp.UpgradeFromVC60.props" />
+  </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="$(VCTargetsPath)Microsoft.Cpp.UpgradeFromVC60.props" />
+  </ImportGroup>
+  <PropertyGroup Label="UserMacros" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <OutDir>.\Release\</OutDir>
+    <IntDir>.\Release\</IntDir>
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xcwmpa</TargetName>
+  </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <OutDir>.\Release\</OutDir>
+    <IntDir>.\Release\</IntDir>
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xcwmpa</TargetName>
+  </PropertyGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <ClCompile>
+      <RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
+      <InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
+      <StringPooling>true</StringPooling>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <Optimization>MaxSpeed</Optimization>
+      <SuppressStartupBanner>true</SuppressStartupBanner>
+      <WarningLevel>Level3</WarningLevel>
+      <AdditionalIncludeDirectories>c:\WinDDK\7600.16385.1\inc\api;c:\WinDDK\7600.16385.1\inc\crt;c:\WinDDK\7600.16385.1\inc\mfc42;c:\WinDDK\7600.16385.1\inc\ddk;c:\WinDDK\7600.16385.1\inc\api\dao360</AdditionalIncludeDirectories>
+      <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_WINDLL;_USRDLL;_AFXDLL;_AFX_NO_DAO_SUPPORT</PreprocessorDefinitions>
+      <AssemblerListingLocation>.\Release\</AssemblerListingLocation>
+      <PrecompiledHeaderOutputFile>.\Release\wmpa.pch</PrecompiledHeaderOutputFile>
+      <PrecompiledHeader>Use</PrecompiledHeader>
+      <PrecompiledHeaderFile>stdafx.h</PrecompiledHeaderFile>
+      <ObjectFileName>.\Release\</ObjectFileName>
+      <ProgramDataBaseFileName>.\Release\</ProgramDataBaseFileName>
+    </ClCompile>
+    <Midl>
+      <SuppressStartupBanner>true</SuppressStartupBanner>
+      <PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <TypeLibraryName>.\Release\wmpa.tlb</TypeLibraryName>
+      <MkTypLibCompatible>true</MkTypLibCompatible>
+      <TargetEnvironment>Win32</TargetEnvironment>
+    </Midl>
+    <ResourceCompile>
+      <Culture>0x0409</Culture>
+      <PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+    </ResourceCompile>
+    <Bscmake>
+      <SuppressStartupBanner>true</SuppressStartupBanner>
+      <OutputFile>.\Release\wmpa.bsc</OutputFile>
+    </Bscmake>
+    <Link>
+      <SuppressStartupBanner>true</SuppressStartupBanner>
+      <LinkDLL>true</LinkDLL>
+      <SubSystem>Windows</SubSystem>
+      <OutputFile>.\Release\xcwmpa.dll</OutputFile>
+      <ImportLibrary>.\Release\wmpa.lib</ImportLibrary>
+      <ModuleDefinitionFile>.\wmpa.def</ModuleDefinitionFile>
+      <AdditionalLibraryDirectories>c:\WinDDK\7600.16385.1\lib\Crt\i386;c:\WinDDK\7600.16385.1\lib\wxp\i386;c:\WinDDK\7600.16385.1\lib\Mfc\i386;c:\WinDDK\7600.16385.1\lib\ATL\i386</AdditionalLibraryDirectories>
+      <AdditionalDependencies>msvcrt_winxp.obj</AdditionalDependencies>
+    </Link>
+    <CustomBuildStep>
+      <Command>
+      </Command>
+      <Outputs>
+      </Outputs>
+      <Message>
+      </Message>
+    </CustomBuildStep>
+  </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
+      <InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
+      <StringPooling>true</StringPooling>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <Optimization>MaxSpeed</Optimization>
+      <SuppressStartupBanner>true</SuppressStartupBanner>
+      <WarningLevel>Level3</WarningLevel>
+      <AdditionalIncludeDirectories>c:\WinDDK\7600.16385.1\inc\api;c:\WinDDK\7600.16385.1\inc\crt;c:\WinDDK\7600.16385.1\inc\mfc42;c:\WinDDK\7600.16385.1\inc\ddk;c:\WinDDK\7600.16385.1\inc\api\dao360</AdditionalIncludeDirectories>
+      <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_WINDLL;_USRDLL;_AFXDLL;_AFX_NO_DAO_SUPPORT</PreprocessorDefinitions>
+      <AssemblerListingLocation>.\Release\</AssemblerListingLocation>
+      <PrecompiledHeaderOutputFile>.\Release\wmpa.pch</PrecompiledHeaderOutputFile>
+      <PrecompiledHeader>Use</PrecompiledHeader>
+      <PrecompiledHeaderFile>stdafx.h</PrecompiledHeaderFile>
+      <ObjectFileName>.\Release\</ObjectFileName>
+      <ProgramDataBaseFileName>.\Release\</ProgramDataBaseFileName>
+    </ClCompile>
+    <Midl>
+      <SuppressStartupBanner>true</SuppressStartupBanner>
+      <PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <TypeLibraryName>.\Release\wmpa.tlb</TypeLibraryName>
+      <MkTypLibCompatible>true</MkTypLibCompatible>
+      <TargetEnvironment>X64</TargetEnvironment>
+    </Midl>
+    <ResourceCompile>
+      <Culture>0x0409</Culture>
+      <PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+    </ResourceCompile>
+    <Bscmake>
+      <SuppressStartupBanner>true</SuppressStartupBanner>
+      <OutputFile>.\Release\wmpa.bsc</OutputFile>
+    </Bscmake>
+    <Link>
+      <SuppressStartupBanner>true</SuppressStartupBanner>
+      <LinkDLL>true</LinkDLL>
+      <SubSystem>Windows</SubSystem>
+      <OutputFile>.\Release\xcwmpa.dll</OutputFile>
+      <ImportLibrary>.\Release\wmpa.lib</ImportLibrary>
+      <ModuleDefinitionFile>.\wmpa.def</ModuleDefinitionFile>
+      <AdditionalLibraryDirectories>c:\WinDDK\7600.16385.1\lib\Crt\amd64;c:\WinDDK\7600.16385.1\lib\wnet\amd64;c:\WinDDK\7600.16385.1\lib\Mfc\amd64;c:\WinDDK\7600.16385.1\lib\ATL\amd64</AdditionalLibraryDirectories>
+      <AdditionalDependencies>msvcrt_win2003.obj</AdditionalDependencies>
+    </Link>
+    <CustomBuildStep>
+      <Command>
+      </Command>
+      <Outputs>
+      </Outputs>
+      <Message>
+      </Message>
+    </CustomBuildStep>
+  </ItemDefinitionGroup>
+  <ItemGroup>
+    <ClCompile Include="StdAfx.cpp">
+      <PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
+      <PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Create</PrecompiledHeader>
+      <PrecompiledHeaderFile Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">stdafx.h</PrecompiledHeaderFile>
+      <PrecompiledHeaderFile Condition="'$(Configuration)|$(Platform)'=='Release|x64'">stdafx.h</PrecompiledHeaderFile>
+    </ClCompile>
+    <ClCompile Include="wmpa.cpp" />
+    <ClCompile Include="WMPADialog.cpp" />
+    <ClCompile Include="wmpcdrom.cpp" />
+    <ClCompile Include="wmpcdromcollection.cpp" />
+    <ClCompile Include="wmpclosedcaption.cpp" />
+    <ClCompile Include="wmpcontrols.cpp" />
+    <ClCompile Include="wmpdvd.cpp" />
+    <ClCompile Include="wmperror.cpp" />
+    <ClCompile Include="wmperroritem.cpp" />
+    <ClCompile Include="wmpmedia.cpp" />
+    <ClCompile Include="wmpmediacollection.cpp" />
+    <ClCompile Include="wmpnetwork.cpp" />
+    <ClCompile Include="wmpplayer4.cpp" />
+    <ClCompile Include="wmpplayerapplication.cpp" />
+    <ClCompile Include="wmpplaylist.cpp" />
+    <ClCompile Include="wmpplaylistarray.cpp" />
+    <ClCompile Include="wmpplaylistcollection.cpp" />
+    <ClCompile Include="wmpsettings.cpp" />
+    <ClCompile Include="wmpstringcollection.cpp" />
+    <ClCompile Include="xchat-plugin.cpp" />
+  </ItemGroup>
+  <ItemGroup>
+    <CustomBuild Include="wmpa.def" />
+    <CustomBuild Include="res\wmpa.rc2">
+      <FileType>RC</FileType>
+    </CustomBuild>
+    <CustomBuild Include="wmpa.ico" />
+    <CustomBuild Include="ReadMe.txt" />
+  </ItemGroup>
+  <ItemGroup>
+    <Midl Include="wmpa.odl">
+      <TargetEnvironment Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Win32</TargetEnvironment>
+    </Midl>
+  </ItemGroup>
+  <ItemGroup>
+    <ResourceCompile Include="wmpa.rc">
+      <AdditionalIncludeDirectories Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(OUTDIR);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <AdditionalIncludeDirectories Condition="'$(Configuration)|$(Platform)'=='Release|x64'">$(OUTDIR);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+    </ResourceCompile>
+  </ItemGroup>
+  <ItemGroup>
+    <ClInclude Include="Resource.h" />
+    <ClInclude Include="StdAfx.h" />
+    <ClInclude Include="wmpa.h" />
+    <ClInclude Include="WMPADIALOG.h" />
+    <ClInclude Include="wmpcdrom.h" />
+    <ClInclude Include="wmpcdromcollection.h" />
+    <ClInclude Include="wmpclosedcaption.h" />
+    <ClInclude Include="wmpcontrols.h" />
+    <ClInclude Include="wmpdvd.h" />
+    <ClInclude Include="wmperror.h" />
+    <ClInclude Include="wmperroritem.h" />
+    <ClInclude Include="wmpmedia.h" />
+    <ClInclude Include="wmpmediacollection.h" />
+    <ClInclude Include="wmpnetwork.h" />
+    <ClInclude Include="wmpplayer4.h" />
+    <ClInclude Include="wmpplayerapplication.h" />
+    <ClInclude Include="wmpplaylist.h" />
+    <ClInclude Include="wmpplaylistarray.h" />
+    <ClInclude Include="wmpplaylistcollection.h" />
+    <ClInclude Include="wmpsettings.h" />
+    <ClInclude Include="wmpstringcollection.h" />
+    <ClInclude Include="xchat-plugin.h" />
+  </ItemGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
+  <ImportGroup Label="ExtensionTargets">
+  </ImportGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/wmpa/wmpa.vcxproj.filters b/plugins/wmpa/wmpa.vcxproj.filters
new file mode 100644
index 00000000..6962f46e
--- /dev/null
+++ b/plugins/wmpa/wmpa.vcxproj.filters
@@ -0,0 +1,172 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup>
+    <Filter Include="Source Files">
+      <UniqueIdentifier>{3206fd00-efdb-4bca-9740-9708bd405701}</UniqueIdentifier>
+      <Extensions>cpp;c;cxx;rc;def;r;odl;idl;hpj;bat</Extensions>
+    </Filter>
+    <Filter Include="Header Files">
+      <UniqueIdentifier>{17e13eb2-1243-4ff2-9532-1d6dab0bfef9}</UniqueIdentifier>
+      <Extensions>h;hpp;hxx;hm;inl</Extensions>
+    </Filter>
+    <Filter Include="Resource Files">
+      <UniqueIdentifier>{a1d9cf8c-f0bb-4a19-bfff-5223276e650a}</UniqueIdentifier>
+      <Extensions>ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe</Extensions>
+    </Filter>
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="StdAfx.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="wmpa.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="WMPADialog.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="wmpcdrom.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="wmpcdromcollection.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="wmpclosedcaption.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="wmpcontrols.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="wmpdvd.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="wmperror.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="wmperroritem.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="wmpmedia.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="wmpmediacollection.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="wmpnetwork.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="wmpplayer4.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="wmpplayerapplication.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="wmpplaylist.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="wmpplaylistarray.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="wmpplaylistcollection.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="wmpsettings.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="wmpstringcollection.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="xchat-plugin.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+  </ItemGroup>
+  <ItemGroup>
+    <Midl Include="wmpa.odl">
+      <Filter>Source Files</Filter>
+    </Midl>
+  </ItemGroup>
+  <ItemGroup>
+    <ResourceCompile Include="wmpa.rc">
+      <Filter>Source Files</Filter>
+    </ResourceCompile>
+  </ItemGroup>
+  <ItemGroup>
+    <ClInclude Include="Resource.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="StdAfx.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="wmpa.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="WMPADIALOG.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="wmpcdrom.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="wmpcdromcollection.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="wmpclosedcaption.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="wmpcontrols.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="wmpdvd.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="wmperror.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="wmperroritem.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="wmpmedia.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="wmpmediacollection.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="wmpnetwork.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="wmpplayer4.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="wmpplayerapplication.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="wmpplaylist.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="wmpplaylistarray.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="wmpplaylistcollection.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="wmpsettings.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="wmpstringcollection.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="xchat-plugin.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+  </ItemGroup>
+  <ItemGroup>
+    <CustomBuild Include="wmpa.def">
+      <Filter>Source Files</Filter>
+    </CustomBuild>
+    <CustomBuild Include="res\wmpa.rc2">
+      <Filter>Resource Files</Filter>
+    </CustomBuild>
+    <CustomBuild Include="wmpa.ico">
+      <Filter>Resource Files</Filter>
+    </CustomBuild>
+    <CustomBuild Include="ReadMe.txt" />
+  </ItemGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/wmpa/wmpplayer4.h b/plugins/wmpa/wmpplayer4.h
index 5ec3c331..687d9361 100644
--- a/plugins/wmpa/wmpplayer4.h
+++ b/plugins/wmpa/wmpplayer4.h
@@ -38,12 +38,12 @@ public:
 			= { 0x6bf52a52, 0x394a, 0x11d3, { 0xb1, 0x53, 0x0, 0xc0, 0x4f, 0x79, 0xfa, 0xa6 } };
 		return clsid;
 	}
-	virtual BOOL Create(LPCTSTR lpszClassName,
+	/*virtual BOOL Create(LPCTSTR lpszClassName,
 		LPCTSTR lpszWindowName, DWORD dwStyle,
 		const RECT& rect,
 		CWnd* pParentWnd, UINT nID,
 		CCreateContext* pContext = NULL)
-	{ return CreateControl(GetClsid(), lpszWindowName, dwStyle, rect, pParentWnd, nID); }
+	{ return CreateControl(GetClsid(), lpszWindowName, dwStyle, rect, pParentWnd, nID); }*/
 
     BOOL Create(LPCTSTR lpszWindowName, DWORD dwStyle,
 		const RECT& rect, CWnd* pParentWnd, UINT nID,
diff --git a/plugins/wmpa/xchat.ico b/plugins/wmpa/xchat.ico
deleted file mode 100644
index 73247fd0..00000000
Binary files a/plugins/wmpa/xchat.ico and /dev/null differ
-- 
cgit 1.4.1


From f7bc383a66e392dcdca8dc73453f78d439bff667 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Fri, 12 Aug 2011 05:13:27 +0200
Subject: add info about WMP icon

---
 plugins/wmpa/wmpa.rc | 3 +++
 1 file changed, 3 insertions(+)

(limited to 'plugins')

diff --git a/plugins/wmpa/wmpa.rc b/plugins/wmpa/wmpa.rc
index 4f3d239a..b99b4bfb 100644
--- a/plugins/wmpa/wmpa.rc
+++ b/plugins/wmpa/wmpa.rc
@@ -174,6 +174,9 @@ END
 
 // Icon with lowest ID value placed first to ensure application icon
 // remains consistent on all systems.
+//
+// the WMP icon comes from here:
+// http://www.iconarchive.com/show/phuzion-icons-by-kyo-tux/Applic-WMP-icon.html
 IDI_XCHAT               ICON    DISCARDABLE     "wmpa.ico"
 #endif    // English (U.S.) resources
 /////////////////////////////////////////////////////////////////////////////
-- 
cgit 1.4.1


From 75cef456709c0f6b143fb00d78b41e65a01ff5d6 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Fri, 12 Aug 2011 05:15:09 +0200
Subject: replace 16x16 WMP icon with 32x32 one for Win7 taskbar

---
 plugins/wmpa/wmpa.ico | Bin 1150 -> 4286 bytes
 1 file changed, 0 insertions(+), 0 deletions(-)

(limited to 'plugins')

diff --git a/plugins/wmpa/wmpa.ico b/plugins/wmpa/wmpa.ico
index fb781daa..fb68714c 100644
Binary files a/plugins/wmpa/wmpa.ico and b/plugins/wmpa/wmpa.ico differ
-- 
cgit 1.4.1


From ce902a39266619a24af32844816436ca08ef45ac Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Wed, 17 Aug 2011 15:11:25 +0200
Subject: skeleton for gtkpref launcher plugin

---
 build/gtkpref.png            | Bin 0 -> 323 bytes
 build/release-x64.bat        |   1 +
 build/release-x86.bat        |   1 +
 plugins/gtkpref/gtkpref.c    |  63 +++++++++++++++++++++++++++++++++++++++++++
 plugins/gtkpref/makefile.mak |  18 +++++++++++++
 plugins/makefile.mak         |   4 +++
 6 files changed, 87 insertions(+)
 create mode 100644 build/gtkpref.png
 create mode 100644 plugins/gtkpref/gtkpref.c
 create mode 100644 plugins/gtkpref/makefile.mak

(limited to 'plugins')

diff --git a/build/gtkpref.png b/build/gtkpref.png
new file mode 100644
index 00000000..9a6c9cf9
Binary files /dev/null and b/build/gtkpref.png differ
diff --git a/build/release-x64.bat b/build/release-x64.bat
index f42c1661..df5269c3 100644
--- a/build/release-x64.bat
+++ b/build/release-x64.bat
@@ -52,6 +52,7 @@ copy %DEPS_ROOT%\bin\libenchant.dll %XCHAT_DEST%
 xcopy /q /s /i %DEPS_ROOT%\lib\enchant\libenchant_myspell.dll %XCHAT_DEST%\lib\enchant\
 xcopy /q /s /i ..\plugins\checksum\xcchecksum.dll %XCHAT_DEST%\plugins\
 copy ..\plugins\lua\xclua.dll %XCHAT_DEST%\plugins
+copy ..\plugins\gtkpref\xcgtkpref.dll %XCHAT_DEST%\plugins
 copy ..\plugins\mpcinfo\xcmpcinfo.dll %XCHAT_DEST%\plugins
 copy ..\plugins\perl\xcperl-512.dll %XCHAT_DEST%\plugins
 copy ..\plugins\perl\xcperl-514.dll %XCHAT_DEST%\plugins
diff --git a/build/release-x86.bat b/build/release-x86.bat
index 39c1caa2..c6d54db9 100644
--- a/build/release-x86.bat
+++ b/build/release-x86.bat
@@ -52,6 +52,7 @@ copy %DEPS_ROOT%\bin\libenchant.dll %XCHAT_DEST%
 xcopy /q /s /i %DEPS_ROOT%\lib\enchant\libenchant_myspell.dll %XCHAT_DEST%\lib\enchant\
 xcopy /q /s /i ..\plugins\checksum\xcchecksum.dll %XCHAT_DEST%\plugins\
 copy ..\plugins\lua\xclua.dll %XCHAT_DEST%\plugins
+copy ..\plugins\gtkpref\xcgtkpref.dll %XCHAT_DEST%\plugins
 copy ..\plugins\mpcinfo\xcmpcinfo.dll %XCHAT_DEST%\plugins
 copy ..\plugins\perl\xcperl-512.dll %XCHAT_DEST%\plugins
 copy ..\plugins\perl\xcperl-514.dll %XCHAT_DEST%\plugins
diff --git a/plugins/gtkpref/gtkpref.c b/plugins/gtkpref/gtkpref.c
new file mode 100644
index 00000000..6bd20102
--- /dev/null
+++ b/plugins/gtkpref/gtkpref.c
@@ -0,0 +1,63 @@
+/* XChat-WDK
+ * Copyright (c) 2011 Berke Viktor.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ * 3. The name of the author may not be used to endorse or promote products
+ *    derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+ * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#include <windows.h>
+#include <wininet.h>
+
+#include "xchat-plugin.h"
+
+static xchat_plugin *ph;   /* plugin handle */
+
+static void
+launch_tool ()
+{
+
+}
+
+int
+xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugin_desc, char **plugin_version, char *arg)
+{
+	ph = plugin_handle;
+
+	*plugin_name = "GTKPref";
+	*plugin_desc = "GTK+ Preference Tool Launcher";
+	*plugin_version = "1.0";
+
+	xchat_hook_command (ph, "GTKPREF", XCHAT_PRI_NORM, launch_tool, 0, 0);
+	xchat_command (ph, "MENU -ietc\\gtkpref.png ADD \"Settings/GTK+ Preferences\" \"GTKPREF\"");
+
+	xchat_print (ph, "GTKPref plugin loaded\n");
+
+	return 1;       /* return 1 for success */
+}
+
+int
+xchat_plugin_deinit (void)
+{
+	xchat_command (ph, "MENU DEL \"Settings/GTK+ Preferences\"");
+	xchat_print (ph, "GTKPref plugin unloaded\n");
+	return 1;
+}
diff --git a/plugins/gtkpref/makefile.mak b/plugins/gtkpref/makefile.mak
new file mode 100644
index 00000000..e2292365
--- /dev/null
+++ b/plugins/gtkpref/makefile.mak
@@ -0,0 +1,18 @@
+include "..\..\src\makeinc.mak"
+
+all: gtkpref.obj gtkpref.def
+	link $(LDFLAGS) $(LIBS) /dll /out:xcgtkpref.dll /def:gtkpref.def gtkpref.obj
+
+gtkpref.def:
+	echo EXPORTS > gtkpref.def
+	echo xchat_plugin_init >> gtkpref.def
+	echo xchat_plugin_deinit >> gtkpref.def
+
+gtkpref.obj: gtkpref.c makefile.mak
+	cl $(CFLAGS) $(GLIB) /I.. gtkpref.c
+
+clean:
+	del *.obj
+	del *.dll
+	del *.exp
+	del *.lib
diff --git a/plugins/makefile.mak b/plugins/makefile.mak
index e56a2db7..145669bd 100644
--- a/plugins/makefile.mak
+++ b/plugins/makefile.mak
@@ -1,6 +1,8 @@
 all:
 	@cd checksum
 	@-$(MAKE) /nologo /s /f makefile.mak $@
+	@cd ..\gtkpref
+	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\lua
 	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\mpcinfo
@@ -21,6 +23,8 @@ all:
 clean:
 	@cd checksum
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
+	@cd ..\gtkpref
+	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\lua
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\mpcinfo
-- 
cgit 1.4.1


From 5472a813fa62370926ace45d7506f098368428eb Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Wed, 17 Aug 2011 15:22:40 +0200
Subject: working gtkpref plugin

---
 plugins/gtkpref/gtkpref.c | 14 +++++++++++++-
 1 file changed, 13 insertions(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/gtkpref/gtkpref.c b/plugins/gtkpref/gtkpref.c
index 6bd20102..18a6d958 100644
--- a/plugins/gtkpref/gtkpref.c
+++ b/plugins/gtkpref/gtkpref.c
@@ -25,7 +25,6 @@
  */
 
 #include <windows.h>
-#include <wininet.h>
 
 #include "xchat-plugin.h"
 
@@ -34,7 +33,20 @@ static xchat_plugin *ph;   /* plugin handle */
 static void
 launch_tool ()
 {
+	STARTUPINFO si;
+	PROCESS_INFORMATION pi;
 
+	ZeroMemory (&si, sizeof (si));
+	si.cb = sizeof (si);
+	ZeroMemory (&pi, sizeof (pi));
+
+	if (!CreateProcess ( NULL, "gtk2-prefs.exe", NULL, NULL, FALSE, 0, NULL, NULL, &si, &pi))
+	{
+		xchat_print (ph, "Error launching the GTK+ Preference Tool! Maybe the executable is missing?");
+	}
+
+	CloseHandle (pi.hProcess);
+	CloseHandle (pi.hThread);
 }
 
 int
-- 
cgit 1.4.1


From 49e739b511003117cc53f55447d74e95bd913ea9 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Thu, 18 Aug 2011 02:17:41 +0200
Subject: omit gtkpref messages

---
 plugins/gtkpref/gtkpref.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

(limited to 'plugins')

diff --git a/plugins/gtkpref/gtkpref.c b/plugins/gtkpref/gtkpref.c
index 18a6d958..3816abcc 100644
--- a/plugins/gtkpref/gtkpref.c
+++ b/plugins/gtkpref/gtkpref.c
@@ -61,8 +61,6 @@ xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugi
 	xchat_hook_command (ph, "GTKPREF", XCHAT_PRI_NORM, launch_tool, 0, 0);
 	xchat_command (ph, "MENU -ietc\\gtkpref.png ADD \"Settings/GTK+ Preferences\" \"GTKPREF\"");
 
-	xchat_print (ph, "GTKPref plugin loaded\n");
-
 	return 1;       /* return 1 for success */
 }
 
@@ -70,6 +68,6 @@ int
 xchat_plugin_deinit (void)
 {
 	xchat_command (ph, "MENU DEL \"Settings/GTK+ Preferences\"");
-	xchat_print (ph, "GTKPref plugin unloaded\n");
+
 	return 1;
 }
-- 
cgit 1.4.1


From 817cfa57924bc0aa95187d9e71c55a0113343736 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Tue, 22 Nov 2011 15:59:11 +0100
Subject: gtk engines are non-existent in gtk.org builds

---
 plugins/makefile.mak | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

(limited to 'plugins')

diff --git a/plugins/makefile.mak b/plugins/makefile.mak
index 145669bd..2ac155df 100644
--- a/plugins/makefile.mak
+++ b/plugins/makefile.mak
@@ -1,8 +1,8 @@
 all:
 	@cd checksum
 	@-$(MAKE) /nologo /s /f makefile.mak $@
-	@cd ..\gtkpref
-	@-$(MAKE) /nologo /s /f makefile.mak $@
+#	@cd ..\gtkpref
+#	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\lua
 	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\mpcinfo
@@ -23,8 +23,8 @@ all:
 clean:
 	@cd checksum
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
-	@cd ..\gtkpref
-	@-$(MAKE) /nologo /s /f makefile.mak clean $@
+#	@cd ..\gtkpref
+#	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\lua
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\mpcinfo
-- 
cgit 1.4.1


From caa878bc93134a07be311c287dacae2168d97ebc Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Tue, 22 Nov 2011 17:58:00 +0100
Subject: add doat plugin

---
 build/release-x64.bat     |  1 +
 build/release-x86.bat     |  1 +
 plugins/doat/doat.c       | 80 +++++++++++++++++++++++++++++++++++++++++++++++
 plugins/doat/makefile.mak | 18 +++++++++++
 plugins/makefile.mak      |  4 +++
 5 files changed, 104 insertions(+)
 create mode 100644 plugins/doat/doat.c
 create mode 100644 plugins/doat/makefile.mak

(limited to 'plugins')

diff --git a/build/release-x64.bat b/build/release-x64.bat
index 47ba3589..e96b01e2 100644
--- a/build/release-x64.bat
+++ b/build/release-x64.bat
@@ -47,6 +47,7 @@ copy %DEPS_ROOT%\bin\cert.pem %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libenchant.dll %XCHAT_DEST%
 xcopy /q /s /i %DEPS_ROOT%\lib\enchant\libenchant_myspell.dll %XCHAT_DEST%\lib\enchant\
 xcopy /q /s /i ..\plugins\checksum\xcchecksum.dll %XCHAT_DEST%\plugins\
+copy ..\plugins\doat\xcdoat.dll %XCHAT_DEST%\plugins
 copy ..\plugins\lua\xclua.dll %XCHAT_DEST%\plugins
 ::copy ..\plugins\gtkpref\xcgtkpref.dll %XCHAT_DEST%\plugins
 copy ..\plugins\mpcinfo\xcmpcinfo.dll %XCHAT_DEST%\plugins
diff --git a/build/release-x86.bat b/build/release-x86.bat
index c7223fe0..ddd1ff0c 100644
--- a/build/release-x86.bat
+++ b/build/release-x86.bat
@@ -47,6 +47,7 @@ copy %DEPS_ROOT%\bin\cert.pem %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libenchant.dll %XCHAT_DEST%
 xcopy /q /s /i %DEPS_ROOT%\lib\enchant\libenchant_myspell.dll %XCHAT_DEST%\lib\enchant\
 xcopy /q /s /i ..\plugins\checksum\xcchecksum.dll %XCHAT_DEST%\plugins\
+copy ..\plugins\doat\xcdoat.dll %XCHAT_DEST%\plugins
 copy ..\plugins\lua\xclua.dll %XCHAT_DEST%\plugins
 ::copy ..\plugins\gtkpref\xcgtkpref.dll %XCHAT_DEST%\plugins
 copy ..\plugins\mpcinfo\xcmpcinfo.dll %XCHAT_DEST%\plugins
diff --git a/plugins/doat/doat.c b/plugins/doat/doat.c
new file mode 100644
index 00000000..e03507f1
--- /dev/null
+++ b/plugins/doat/doat.c
@@ -0,0 +1,80 @@
+/* This program is free software. It comes without any warranty, to
+ * the extent permitted by applicable law. You can redistribute it
+ * and/or modify it under the terms of the Do What The Fuck You Want
+ * To Public License, Version 2, as published by Sam Hocevar. See
+ * http://sam.zoy.org/wtfpl/COPYING or http://lwsitu.com/xchat/COPYING
+ * for more details. */
+
+#include <stdlib.h>
+#include <string.h>
+#include <stdio.h>
+#include "xchat-plugin.h"
+
+static xchat_plugin *ph;
+
+static int
+parse_command( char *word[], char *word_eol[], void *userdata ) {
+	char *channel = NULL, *server = NULL, *token = NULL;
+/*	char *save_ptr1 = NULL;*/
+	char *str1 = NULL;
+	char *delimiter = NULL;
+
+	xchat_context *ctx = NULL;
+
+	if( word[2] != NULL && word[3] != NULL ) {
+		for( str1 = word[2]; ; str1 = NULL ) {
+/*			token = strtok_r( str1, ",", &save_ptr1 );*/
+			token = strtok( str1, "," );
+/*			printf( "token: %s\n", token );*/
+
+			if( token == NULL ) {
+				break;
+			}
+
+			channel = malloc( strlen( token ) + 1 );
+			strcpy( channel, token );
+				
+			delimiter = strchr( channel, '/' );
+
+			server = NULL;
+			if( delimiter != NULL ) {
+				*delimiter = '\0';
+				server = delimiter + 1;
+			}
+
+/*			printf( "channel[%s] server[%s]\n", channel, server );*/
+
+			if( (ctx = xchat_find_context( ph, server, channel ) ) != NULL ) {
+				if( xchat_set_context( ph, ctx ) ) {
+					xchat_command( ph, word_eol[3] );
+				}
+			}
+
+			free( channel );
+		}
+	}
+	return XCHAT_EAT_XCHAT;
+}
+
+int
+xchat_plugin_init( xchat_plugin * plugin_handle, char **plugin_name,
+	char **plugin_desc, char **plugin_version, char *arg ) {
+
+	ph = plugin_handle;
+	*plugin_name = "Do At";
+	*plugin_version = "1.0";
+	*plugin_desc = "Perform an arbitrary command on multiple channels";
+
+	xchat_hook_command( ph, "doat", XCHAT_PRI_NORM, parse_command, "DOAT [channel,list,/network] [command], perform a command on multiple contexts", NULL );
+
+	xchat_print (ph, "Do At plugin loaded\n");
+
+	return 1;
+}
+
+int
+xchat_plugin_deinit (void)
+{
+	xchat_print (ph, "Do At plugin unloaded\n");
+	return 1;
+}
diff --git a/plugins/doat/makefile.mak b/plugins/doat/makefile.mak
new file mode 100644
index 00000000..960cae27
--- /dev/null
+++ b/plugins/doat/makefile.mak
@@ -0,0 +1,18 @@
+include "..\..\src\makeinc.mak"
+
+all: doat.obj doat.def
+	link $(LDFLAGS) $(LIBS) /dll /out:xcdoat.dll /def:doat.def doat.obj
+
+doat.def:
+	echo EXPORTS > doat.def
+	echo xchat_plugin_init >> doat.def
+	echo xchat_plugin_deinit >> doat.def
+
+doat.obj: doat.c makefile.mak
+	cl $(CFLAGS) $(GLIB) /I.. doat.c
+
+clean:
+	del *.obj
+	del *.dll
+	del *.exp
+	del *.lib
diff --git a/plugins/makefile.mak b/plugins/makefile.mak
index 2ac155df..b08917ab 100644
--- a/plugins/makefile.mak
+++ b/plugins/makefile.mak
@@ -3,6 +3,8 @@ all:
 	@-$(MAKE) /nologo /s /f makefile.mak $@
 #	@cd ..\gtkpref
 #	@-$(MAKE) /nologo /s /f makefile.mak $@
+	@cd ..\doat
+	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\lua
 	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\mpcinfo
@@ -25,6 +27,8 @@ clean:
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 #	@cd ..\gtkpref
 #	@-$(MAKE) /nologo /s /f makefile.mak clean $@
+	@cd ..\doat
+	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\lua
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\mpcinfo
-- 
cgit 1.4.1


From b2c45b196c9a09fd2c1c7e86fe7f4391e93e0c1a Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Wed, 23 Nov 2011 02:57:45 +0100
Subject: fix update checker for separate installers

---
 plugins/upd/upd.c | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/upd/upd.c b/plugins/upd/upd.c
index 92b7d06e..00319910 100644
--- a/plugins/upd/upd.c
+++ b/plugins/upd/upd.c
@@ -80,7 +80,11 @@ print_version ()
 	}
 	else
 	{
-		xchat_printf (ph, "An XChat-WDK update is available! You can download it from here:\nhttp://xchat-wdk.googlecode.com/files/XChat-WDK%%20%s.exe\n", version);
+#ifdef _WIN64 /* use this approach, the wProcessorArchitecture method always returns 0 (=x86) for some reason */
+		xchat_printf (ph, "An XChat-WDK update is available! You can download it from here:\nhttp://xchat-wdk.googlecode.com/files/XChat-WDK%%20%s%%20x64.exe\n", version);
+#else
+		xchat_printf (ph, "An XChat-WDK update is available! You can download it from here:\nhttp://xchat-wdk.googlecode.com/files/XChat-WDK%%20%s%%20x86.exe\n", version);
+#endif
 	}
 }
 
-- 
cgit 1.4.1


From 34a77fdbc573d2302a8f15660b4a4f93fe89f1a9 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Wed, 23 Nov 2011 04:37:57 +0100
Subject: forgot to bump updater version number

---
 plugins/upd/upd.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/upd/upd.c b/plugins/upd/upd.c
index 00319910..72da7f5c 100644
--- a/plugins/upd/upd.c
+++ b/plugins/upd/upd.c
@@ -95,7 +95,7 @@ xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugi
 
 	*plugin_name = "Update Checker";
 	*plugin_desc = "Plugin for checking for XChat-WDK updates";
-	*plugin_version = "1.4";
+	*plugin_version = "1.5";
 
 	xchat_hook_command (ph, "UPDCHK", XCHAT_PRI_NORM, print_version, 0, 0);
 	xchat_command (ph, "MENU -ietc\\download.png ADD \"Help/Check for Updates\" \"UPDCHK\"");
-- 
cgit 1.4.1


From 1a96ca3edd2b3b503a00180a8d1bb225cac2059b Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Thu, 24 Nov 2011 23:17:31 +0100
Subject: add fishlim plugin

---
 build/release-x64.bat          |   1 +
 build/release-x86.bat          |   1 +
 build/xchat-wdk-x64.skel.iss   |   2 +
 build/xchat-wdk-x86.skel.iss   |   2 +
 plugins/fishlim/INSTALL        |  16 +++
 plugins/fishlim/LICENSE        |  21 ++++
 plugins/fishlim/Makefile       |  40 ++++++
 plugins/fishlim/README         |  44 +++++++
 plugins/fishlim/bool.h         |   5 +
 plugins/fishlim/fish.c         | 192 ++++++++++++++++++++++++++++
 plugins/fishlim/fish.h         |  42 +++++++
 plugins/fishlim/irc.c          | 112 +++++++++++++++++
 plugins/fishlim/irc.h          |  43 +++++++
 plugins/fishlim/keystore.c     | 217 ++++++++++++++++++++++++++++++++
 plugins/fishlim/keystore.h     |  42 +++++++
 plugins/fishlim/makefile.mak   |  30 +++++
 plugins/fishlim/misc.c         |  54 ++++++++
 plugins/fishlim/misc.h         |  36 ++++++
 plugins/fishlim/test.c         |  83 ++++++++++++
 plugins/fishlim/xchat_plugin.c | 278 +++++++++++++++++++++++++++++++++++++++++
 plugins/makefile.mak           |   4 +
 21 files changed, 1265 insertions(+)
 create mode 100644 plugins/fishlim/INSTALL
 create mode 100644 plugins/fishlim/LICENSE
 create mode 100644 plugins/fishlim/Makefile
 create mode 100644 plugins/fishlim/README
 create mode 100644 plugins/fishlim/bool.h
 create mode 100644 plugins/fishlim/fish.c
 create mode 100644 plugins/fishlim/fish.h
 create mode 100644 plugins/fishlim/irc.c
 create mode 100644 plugins/fishlim/irc.h
 create mode 100644 plugins/fishlim/keystore.c
 create mode 100644 plugins/fishlim/keystore.h
 create mode 100644 plugins/fishlim/makefile.mak
 create mode 100644 plugins/fishlim/misc.c
 create mode 100644 plugins/fishlim/misc.h
 create mode 100644 plugins/fishlim/test.c
 create mode 100644 plugins/fishlim/xchat_plugin.c

(limited to 'plugins')

diff --git a/build/release-x64.bat b/build/release-x64.bat
index 2f911897..33bd235f 100644
--- a/build/release-x64.bat
+++ b/build/release-x64.bat
@@ -48,6 +48,7 @@ copy %DEPS_ROOT%\bin\libenchant.dll %XCHAT_DEST%
 xcopy /q /s /i %DEPS_ROOT%\lib\enchant\libenchant_myspell.dll %XCHAT_DEST%\lib\enchant\
 xcopy /q /s /i ..\plugins\checksum\xcchecksum.dll %XCHAT_DEST%\plugins\
 copy ..\plugins\doat\xcdoat.dll %XCHAT_DEST%\plugins
+copy ..\plugins\fishlim\xcfishlim.dll %XCHAT_DEST%\plugins
 copy ..\plugins\lua\xclua.dll %XCHAT_DEST%\plugins
 ::copy ..\plugins\gtkpref\xcgtkpref.dll %XCHAT_DEST%\plugins
 copy ..\plugins\mpcinfo\xcmpcinfo.dll %XCHAT_DEST%\plugins
diff --git a/build/release-x86.bat b/build/release-x86.bat
index ebd629f7..9bc21126 100644
--- a/build/release-x86.bat
+++ b/build/release-x86.bat
@@ -48,6 +48,7 @@ copy %DEPS_ROOT%\bin\libenchant.dll %XCHAT_DEST%
 xcopy /q /s /i %DEPS_ROOT%\lib\enchant\libenchant_myspell.dll %XCHAT_DEST%\lib\enchant\
 xcopy /q /s /i ..\plugins\checksum\xcchecksum.dll %XCHAT_DEST%\plugins\
 copy ..\plugins\doat\xcdoat.dll %XCHAT_DEST%\plugins
+copy ..\plugins\fishlim\xcfishlim.dll %XCHAT_DEST%\plugins
 copy ..\plugins\lua\xclua.dll %XCHAT_DEST%\plugins
 ::copy ..\plugins\gtkpref\xcgtkpref.dll %XCHAT_DEST%\plugins
 copy ..\plugins\mpcinfo\xcmpcinfo.dll %XCHAT_DEST%\plugins
diff --git a/build/xchat-wdk-x64.skel.iss b/build/xchat-wdk-x64.skel.iss
index ab03ad5a..fd9f802f 100644
--- a/build/xchat-wdk-x64.skel.iss
+++ b/build/xchat-wdk-x64.skel.iss
@@ -35,6 +35,7 @@ Name: "translations"; Description: "Translations"; Types: normal full custom; Fl
 Name: "plugins"; Description: "Plugins"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\checksum"; Description: "Checksum"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\doat"; Description: "Do At"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\fishlim"; Description: "FiSHLiM"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\mpcinfo"; Description: "mpcInfo"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\upd"; Description: "Update Checker"; Types: normal full custom; Flags: disablenouninstallwarning
 Name: "plugins\winamp"; Description: "Winamp"; Types: full custom; Flags: disablenouninstallwarning
@@ -124,6 +125,7 @@ Source: "lib\gtk-2.0\modules\libgail.dll"; DestDir: "{app}\lib\gtk-2.0\modules";
 
 Source: "plugins\xcchecksum.dll"; DestDir: "{app}\plugins"; Components: plugins\checksum
 Source: "plugins\xcdoat.dll"; DestDir: "{app}\plugins"; Components: plugins\doat
+Source: "plugins\xcfishlim.dll"; DestDir: "{app}\plugins"; Components: plugins\fishlim
 Source: "plugins\xcmpcinfo.dll"; DestDir: "{app}\plugins"; Components: plugins\mpcinfo
 Source: "plugins\xcupd.dll"; DestDir: "{app}\plugins"; Components: plugins\upd
 Source: "plugins\xcwinamp.dll"; DestDir: "{app}\plugins"; Components: plugins\winamp
diff --git a/build/xchat-wdk-x86.skel.iss b/build/xchat-wdk-x86.skel.iss
index be5f7ea1..4a3b0f11 100644
--- a/build/xchat-wdk-x86.skel.iss
+++ b/build/xchat-wdk-x86.skel.iss
@@ -34,6 +34,7 @@ Name: "translations"; Description: "Translations"; Types: normal full custom; Fl
 Name: "plugins"; Description: "Plugins"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\checksum"; Description: "Checksum"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\doat"; Description: "Do At"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\fishlim"; Description: "FiSHLiM"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\mpcinfo"; Description: "mpcInfo"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\upd"; Description: "Update Checker"; Types: normal full custom; Flags: disablenouninstallwarning
 Name: "plugins\winamp"; Description: "Winamp"; Types: full custom; Flags: disablenouninstallwarning
@@ -123,6 +124,7 @@ Source: "lib\gtk-2.0\modules\libgail.dll"; DestDir: "{app}\lib\gtk-2.0\modules";
 
 Source: "plugins\xcchecksum.dll"; DestDir: "{app}\plugins"; Components: plugins\checksum
 Source: "plugins\xcdoat.dll"; DestDir: "{app}\plugins"; Components: plugins\doat
+Source: "plugins\xcfishlim.dll"; DestDir: "{app}\plugins"; Components: plugins\fishlim
 Source: "plugins\xcmpcinfo.dll"; DestDir: "{app}\plugins"; Components: plugins\mpcinfo
 Source: "plugins\xcupd.dll"; DestDir: "{app}\plugins"; Components: plugins\upd
 Source: "plugins\xcwinamp.dll"; DestDir: "{app}\plugins"; Components: plugins\winamp
diff --git a/plugins/fishlim/INSTALL b/plugins/fishlim/INSTALL
new file mode 100644
index 00000000..d0d61ff8
--- /dev/null
+++ b/plugins/fishlim/INSTALL
@@ -0,0 +1,16 @@
+
+Install dependencies (on Debian/Ubuntu):
+
+    sudo apt-get install  build-essential libglib2.0-dev libssl-dev
+
+
+Build the plugin with:
+
+    make
+
+
+Install with:
+
+    sudo make install
+
+
diff --git a/plugins/fishlim/LICENSE b/plugins/fishlim/LICENSE
new file mode 100644
index 00000000..427f2631
--- /dev/null
+++ b/plugins/fishlim/LICENSE
@@ -0,0 +1,21 @@
+
+Copyright (c) 2010-2011 Samuel Lidén Borell <samuel@slbdata.se>
+
+Permission is hereby granted, free of charge, to any person obtaining a copy
+of this software and associated documentation files (the "Software"), to deal
+in the Software without restriction, including without limitation the rights
+to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+copies of the Software, and to permit persons to whom the Software is
+furnished to do so, subject to the following conditions:
+
+The above copyright notice and this permission notice shall be included in
+all copies or substantial portions of the Software.
+
+THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+THE SOFTWARE.
+
diff --git a/plugins/fishlim/Makefile b/plugins/fishlim/Makefile
new file mode 100644
index 00000000..7a5081e4
--- /dev/null
+++ b/plugins/fishlim/Makefile
@@ -0,0 +1,40 @@
+
+OURCFLAGS = -Wall -Wextra -Wno-unused-parameter -std=c99 -pedantic `pkg-config --cflags glib-2.0 libcrypto` -DG_DISABLE_DEPRECATED=1 -fPIC $(CFLAGS)
+#OURLINKFLAGS = `pkg-config --libs glib-2.0 libcrypto` -shared -fPIC -Wl,-z,defs $(CFLAGS) $(LDFLAGS)
+OURLINKFLAGS = `pkg-config --libs glib-2.0 libcrypto` $(CFLAGS) $(LDFLAGS)
+
+BASE_OBJECTS = irc.o fish.o keystore.o misc.o
+PLUGIN_OBJECTS = $(BASE_OBJECTS) xchat_plugin.o
+TEST_OBJECTS = $(BASE_OBJECTS) test.o
+
+all: fishlim.so test
+
+fish.o: fish.h keystore.h misc.h
+irc.o: irc.h
+keystore.o: keystore.h irc.h fish.h misc.h
+misc.o: misc.h
+test.o: fish.h
+xchat_plugin.o: fish.h irc.h keystore.h
+
+.c.o:
+	$(CC) $(OURCFLAGS) -c $< -o $@
+
+fishlim.so: $(PLUGIN_OBJECTS)
+	$(CC) -shared $(OURLINKFLAGS) $(PLUGIN_OBJECTS) -o $@
+
+test: $(TEST_OBJECTS)
+	$(CC) $(OURLINKFLAGS) $(TEST_OBJECTS) -o $@
+
+
+.PHONY: all clean distclean install uninstall
+clean:
+	-$(RM) -f $(PLUGIN_OBJECTS) $(TEST_OBJECTS) fishlim.so test
+distclean: clean
+
+install: fishlim.so
+	install -d $(DESTDIR)/usr/lib/xchat/plugins/
+	install -m 644 fishlim.so $(DESTDIR)/usr/lib/xchat/plugins/
+uninstall:
+	rm $(DESTDIR)/usr/lib/xchat/plugins/fishlim.so
+
+
diff --git a/plugins/fishlim/README b/plugins/fishlim/README
new file mode 100644
index 00000000..9c5cd5fc
--- /dev/null
+++ b/plugins/fishlim/README
@@ -0,0 +1,44 @@
+
+
+                                FiSHLiM
+
+                       http://fishlim.slbdata.se/
+
+
+FiSHLiM is an XChat plugin for FiSH IRC encryption. It's my attempt at making
+a simple, lightweight and secure plugin for this encryption protocol.
+
+For installation instructions, see the INSTALL file.
+
+
+Features
+--------
+
+Working:
+  * Sending/receiving messages
+  * Topic decryption
+  * Using unecrypted keys / keys without a password from blow.ini
+  * Pure protocol-level filtering (works with highlighting, nick coloring etc)
+  * Partially encrypted messages (i.e. prefixed with nickname by a bouncer)
+
+Not working:
+  * Key exchange
+  * Password-protected key storage
+  * Topic encryption
+  * Remote exploitation (hopefully!)
+
+
+Commands
+--------
+
+/setkey  [nick or #channel]  password
+
+    Sets the encryption key for the nick or channel to password. The keys
+    are stored in the configuration file in ~/.xchat2/blow.ini
+
+
+/delkey  nick-or-#channel
+
+    Deletes the given nick or channel from the configuration file.
+
+
diff --git a/plugins/fishlim/bool.h b/plugins/fishlim/bool.h
new file mode 100644
index 00000000..2c8ddde4
--- /dev/null
+++ b/plugins/fishlim/bool.h
@@ -0,0 +1,5 @@
+/* stdbool.h replacement for MSVC */
+#define false 0
+#define true 1
+#define bool _Bool
+typedef int _Bool;
diff --git a/plugins/fishlim/fish.c b/plugins/fishlim/fish.c
new file mode 100644
index 00000000..0d92ecc9
--- /dev/null
+++ b/plugins/fishlim/fish.c
@@ -0,0 +1,192 @@
+/*
+
+  Copyright (c) 2010 Samuel Lidén Borell <samuel@slbdata.se>
+
+  Permission is hereby granted, free of charge, to any person obtaining a copy
+  of this software and associated documentation files (the "Software"), to deal
+  in the Software without restriction, including without limitation the rights
+  to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+  copies of the Software, and to permit persons to whom the Software is
+  furnished to do so, subject to the following conditions:
+
+  The above copyright notice and this permission notice shall be included in
+  all copies or substantial portions of the Software.
+
+  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+  FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+  AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+  LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+  THE SOFTWARE.
+
+*/
+
+#include <stdlib.h>
+#include <string.h>
+#include <openssl/blowfish.h>
+
+#include "keystore.h"
+#include "fish.h"
+
+#define IB 64
+static const char fish_base64[64] = "./0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ";
+static const signed char fish_unbase64[256] = {
+    IB,IB,IB,IB,IB,IB,IB,IB,  IB,IB,IB,IB,IB,IB,IB,IB,
+    IB,IB,IB,IB,IB,IB,IB,IB,  IB,IB,IB,IB,IB,IB,IB,IB,
+//      !  "  #  $  %  &  '  (    )  *  +  ,  -  .  /
+    IB,IB,IB,IB,IB,IB,IB,IB,  IB,IB,IB,IB,IB,IB, 0, 1,
+//   0  1  2  3  4  5  6  7    8  9  :  ;  <  =  >  ?
+     2, 3, 4, 5, 6, 7, 8, 9,  10,11,IB,IB,IB,IB,IB,IB,
+//   @  A  B  C  D  E  F  G    H  I  J  K  L  M  N  O
+    IB,38,39,40,41,42,43,44,  45,46,47,48,49,50,51,52,
+//   P  Q  R  S  T  U  V  W    X  Y  Z  [  \  ]  ^  _
+    53,54,55,56,57,58,59,60,  61,62,63,IB,IB,IB,IB,IB,
+//   `  a  b  c  d  e  f  g    h  i  j  k  l  m  n  o
+    IB,12,13,14,15,16,17,18,  19,20,21,22,23,24,25,26,
+//   p  q  r  s  t  u  v  w    x  y  z  {  |  }  ~  <del>
+    27,28,29,30,31,32,33,34,  35,36,37,IB,IB,IB,IB,IB,
+};
+
+#define GET_BYTES(dest, source) do { \
+    *((dest)++) = ((source) >> 24) & 0xFF; \
+    *((dest)++) = ((source) >> 16) & 0xFF; \
+    *((dest)++) = ((source) >> 8) & 0xFF; \
+    *((dest)++) = (source) & 0xFF; \
+} while (0);
+
+
+char *fish_encrypt(const char *key, size_t keylen, const char *message) {
+    BF_KEY bfkey;
+	size_t messagelen;
+	size_t i;
+	int j;
+	char *encrypted;
+	char *end;
+	unsigned char bit;
+	unsigned char word;
+	unsigned char d;
+    BF_set_key(&bfkey, keylen, (const unsigned char*)key);
+    
+    messagelen = strlen(message);
+    if (messagelen == 0) return NULL;
+    encrypted = malloc(((messagelen-1)/8)*12 + 12 + 1); // each 8-byte block becomes 12 bytes
+    end = encrypted;
+    if (!encrypted) return NULL;
+     
+    while (*message) {
+        // Read 8 bytes (a Blowfish block)
+        BF_LONG binary[2] = { 0, 0 };
+        unsigned char c;
+        for (i = 0; i < 8; i++) {
+            c = message[i];
+            binary[i >> 2] |= c << 8*(3 - (i&3));
+            if (c == '\0') break;
+        }
+        message += 8;
+        
+        // Encrypt block
+        BF_encrypt(binary, &bfkey);
+        
+        // Emit FiSH-BASE64
+        bit = 0;
+        word = 1;
+        for (j = 0; j < 12; j++) {
+            d = fish_base64[(binary[word] >> bit) & 63];
+            *(end++) = d;
+            bit += 6;
+            if (j == 5) {
+                bit = 0;
+                word = 0;
+            }
+        }
+        
+        // Stop if a null terminator was found
+        if (c == '\0') break;
+    }
+    *end = '\0';
+    return encrypted;
+}
+
+
+char *fish_decrypt(const char *key, size_t keylen, const char *data) {
+    BF_KEY bfkey;
+	size_t i;
+	char *decrypted;
+	char *end;
+	unsigned char bit;
+	unsigned char word;
+	unsigned char d;
+    BF_set_key(&bfkey, keylen, (const unsigned char*)key);
+    
+    decrypted = malloc(strlen(data)+1);
+    end = decrypted;
+    if (!decrypted) return NULL;
+    
+    while (*data) {
+        // Convert from FiSH-BASE64
+        BF_LONG binary[2] = { 0, 0 };
+        bit = 0;
+        word = 1;
+        for (i = 0; i < 12; i++) {
+            d = fish_unbase64[(const unsigned char)*(data++)];
+            if (d == IB) goto decrypt_end;
+            binary[word] |= d << bit;
+            bit += 6;
+            if (i == 5) {
+                bit = 0;
+                word = 0;
+            }
+        }
+        
+        // Decrypt block
+        BF_decrypt(binary, &bfkey);
+        
+        // Copy to buffer
+        GET_BYTES(end, binary[0]);
+        GET_BYTES(end, binary[1]);
+    }
+    
+  decrypt_end:
+    *end = '\0';
+    return decrypted;
+}
+
+/**
+ * Encrypts a message (see fish_decrypt). The key is searched for in the
+ * key store.
+ */
+char *fish_encrypt_for_nick(const char *nick, const char *data) {
+    char *key;
+    char *encrypted;
+
+    // Look for key
+    key = keystore_get_key(nick);
+    if (!key) return NULL;
+    
+    // Encrypt
+    encrypted = fish_encrypt(key, strlen(key), data);
+    
+    free(key);
+    return encrypted;
+}
+
+/**
+ * Decrypts a message (see fish_decrypt). The key is searched for in the
+ * key store.
+ */
+char *fish_decrypt_from_nick(const char *nick, const char *data) {
+    char *key;
+    char *decrypted;
+    // Look for key
+    key = keystore_get_key(nick);
+    if (!key) return NULL;
+    
+    // Decrypt
+    decrypted = fish_decrypt(key, strlen(key), data);
+    
+    free(key);
+    return decrypted;
+}
+
+
diff --git a/plugins/fishlim/fish.h b/plugins/fishlim/fish.h
new file mode 100644
index 00000000..d4057a7b
--- /dev/null
+++ b/plugins/fishlim/fish.h
@@ -0,0 +1,42 @@
+/*
+
+  Copyright (c) 2010 Samuel Lidén Borell <samuel@slbdata.se>
+
+  Permission is hereby granted, free of charge, to any person obtaining a copy
+  of this software and associated documentation files (the "Software"), to deal
+  in the Software without restriction, including without limitation the rights
+  to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+  copies of the Software, and to permit persons to whom the Software is
+  furnished to do so, subject to the following conditions:
+
+  The above copyright notice and this permission notice shall be included in
+  all copies or substantial portions of the Software.
+
+  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+  FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+  AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+  LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+  THE SOFTWARE.
+
+*/
+
+#ifndef FISH_H
+#define FISH_H
+
+#ifdef _MSC_VER
+#include "bool.h"
+#else
+#include <stdbool.h>
+#endif
+#include <stddef.h>
+
+char *fish_encrypt(const char *key, size_t keylen, const char *message);
+char *fish_decrypt(const char *key, size_t keylen, const char *data);
+char *fish_encrypt_for_nick(const char *nick, const char *data);
+char *fish_decrypt_from_nick(const char *nick, const char *data);
+
+#endif
+
+
diff --git a/plugins/fishlim/irc.c b/plugins/fishlim/irc.c
new file mode 100644
index 00000000..a96c4c91
--- /dev/null
+++ b/plugins/fishlim/irc.c
@@ -0,0 +1,112 @@
+/*
+
+  Copyright (c) 2010 Samuel Lidén Borell <samuel@slbdata.se>
+
+  Permission is hereby granted, free of charge, to any person obtaining a copy
+  of this software and associated documentation files (the "Software"), to deal
+  in the Software without restriction, including without limitation the rights
+  to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+  copies of the Software, and to permit persons to whom the Software is
+  furnished to do so, subject to the following conditions:
+
+  The above copyright notice and this permission notice shall be included in
+  all copies or substantial portions of the Software.
+
+  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+  FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+  AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+  LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+  THE SOFTWARE.
+
+*/
+
+#include <stdlib.h>
+#include <string.h>
+#include "irc.h"
+
+/**
+ * Parses an IRC message. The words array should contain the message splitted
+ * at spaces. The prefix and command is extracted from the message, and
+ * parameters_offset is set to the index of the first parameter.
+ */
+bool irc_parse_message(const char *words[],
+                       const char **prefix, const char **command,
+                       size_t *parameters_offset) {
+    size_t w = 1;
+    if (prefix) *prefix = NULL;
+    if (command) *command = NULL;
+    
+    // See if the message starts with a prefix (sender user)
+    if (words[w][0] == ':') {
+        if (prefix) *prefix = &words[w][1];
+        w++;
+    }
+    
+    // Check command
+    if (words[w][0] == '\0') return false;
+    if (command) *command = words[w];
+    w++;
+    
+    *parameters_offset = w;
+    return true;
+}
+
+
+/**
+ * Finds the nick part of a "IRC prefix", which can have any
+ * of the following forms:
+ *
+ *     nick
+ *     nick@host
+ *     nick!ident
+ *     nick!ident@host
+ */
+char *irc_prefix_get_nick(const char *prefix) {
+    const char *end;
+    char *nick;
+    size_t length;
+    
+    if (!prefix) return NULL;
+    
+    // Find end of nick
+    end = prefix;
+    while (*end != '\0' && *end != '!' && *end != '@') end++;
+    
+    // Allocate string
+    length = end - prefix;
+    nick = malloc(length+1);
+    if (!nick) return NULL;
+    
+    // Copy to string
+    memcpy(nick, prefix, length);
+    nick[length] = '\0';
+    return nick;
+}
+
+
+/**
+ * Compares two nick names. Return 0 if equal. Otherwise the return value is
+ * less than zero if a is less than b or greater than zero if a is greater
+ * than b.
+ */
+int irc_nick_cmp(const char *a, const char *b) {
+    char ac;
+    char bc;
+    char diff;
+    for (;;) {
+        ac = *(a++);
+        bc = *(b++);
+        
+        // Change into IRC uppercase (see RFC 2812 section 2.2)
+        if (ac >= 'a' && ac <= '~') ac &= ~0x20;
+        if (bc >= 'a' && bc <= '~') bc &= ~0x20;
+        
+        diff = ac - bc;
+        if (diff) return diff;
+        if (!ac) return 0;
+    }
+}
+
+
diff --git a/plugins/fishlim/irc.h b/plugins/fishlim/irc.h
new file mode 100644
index 00000000..0c1e7463
--- /dev/null
+++ b/plugins/fishlim/irc.h
@@ -0,0 +1,43 @@
+/*
+
+  Copyright (c) 2010 Samuel Lidén Borell <samuel@slbdata.se>
+
+  Permission is hereby granted, free of charge, to any person obtaining a copy
+  of this software and associated documentation files (the "Software"), to deal
+  in the Software without restriction, including without limitation the rights
+  to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+  copies of the Software, and to permit persons to whom the Software is
+  furnished to do so, subject to the following conditions:
+
+  The above copyright notice and this permission notice shall be included in
+  all copies or substantial portions of the Software.
+
+  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+  FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+  AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+  LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+  THE SOFTWARE.
+
+*/
+
+#ifndef IRC_H
+#define IRC_H
+
+#ifdef _MSC_VER
+#include "bool.h"
+#else
+#include <stdbool.h>
+#endif
+#include <stddef.h>
+
+bool irc_parse_message(const char *words[],
+                       const char **prefix, const char **command,
+                       size_t *parameters_offset);
+char *irc_prefix_get_nick(const char *prefix);
+int irc_nick_cmp(const char *a, const char *b);
+
+#endif
+
+
diff --git a/plugins/fishlim/keystore.c b/plugins/fishlim/keystore.c
new file mode 100644
index 00000000..6eccccaf
--- /dev/null
+++ b/plugins/fishlim/keystore.c
@@ -0,0 +1,217 @@
+/*
+
+  Copyright (c) 2010 Samuel Lidén Borell <samuel@slbdata.se>
+
+  Permission is hereby granted, free of charge, to any person obtaining a copy
+  of this software and associated documentation files (the "Software"), to deal
+  in the Software without restriction, including without limitation the rights
+  to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+  copies of the Software, and to permit persons to whom the Software is
+  furnished to do so, subject to the following conditions:
+
+  The above copyright notice and this permission notice shall be included in
+  all copies or substantial portions of the Software.
+
+  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+  FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+  AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+  LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+  THE SOFTWARE.
+
+*/
+
+#include <glib.h>
+#include <stdlib.h>
+#include <string.h>
+#include "irc.h"
+#include "fish.h"
+#include "misc.h"
+#include "keystore.h"
+
+
+static char *keystore_password = NULL;
+
+
+/**
+ * Returns the path to the key store file.
+ */
+static gchar *get_config_filename() {
+    // TODO use xchat_get_info(ph, "xchatdirfs")
+    const gchar *homedir = g_get_home_dir();
+    return g_build_filename(homedir, ".xchat2", "blow.ini", NULL);
+}
+
+/**
+ * Opens the key store file: ~/.xchat2/blow.ini
+ */
+static GKeyFile *getConfigFile() {
+    gchar *filename = get_config_filename();
+    
+    GKeyFile *keyfile = g_key_file_new();
+    g_key_file_load_from_file(keyfile, filename,
+                              G_KEY_FILE_KEEP_COMMENTS |
+                              G_KEY_FILE_KEEP_TRANSLATIONS, NULL);
+    
+    g_free(filename);
+    return keyfile;
+}
+
+
+/**
+ * Returns the key store password, or the default.
+ */
+static const char *get_keystore_password() {
+    return (keystore_password != NULL ?
+        keystore_password :
+        // Silly default value...
+        "blowinikey");
+}
+
+
+/**
+ * Gets a value for a nick/channel from blow.ini. Unlike
+ * g_key_file_get_string, this function is case insensitive.
+ */
+static gchar *get_nick_value(GKeyFile *keyfile, const char *nick, const char *item) {
+    gchar **group;
+    gchar **groups = g_key_file_get_groups(keyfile, NULL);
+    gchar *result = NULL;
+    
+    for (group = groups; *group != NULL; group++) {
+        if (!irc_nick_cmp(*group, nick)) {
+            result = g_key_file_get_string(keyfile, *group, item, NULL);
+            break;
+        }
+    }
+    
+    g_strfreev(groups);
+    return result;
+}
+
+
+/**
+ * Extracts a key from the key store file.
+ */
+char *keystore_get_key(const char *nick) {
+    // Get the key
+    GKeyFile *keyfile = getConfigFile();
+    gchar *value = get_nick_value(keyfile, nick, "key");
+    g_key_file_free(keyfile);
+    if (!value) return NULL;
+    
+    if (strncmp(value, "+OK ", 4) != 0) {
+        // Key is stored in plaintext
+        return import_glib_string(value);
+    } else {
+        // Key is encrypted
+        const char *encrypted = value+4;
+        const char *password = get_keystore_password();
+        char *decrypted = fish_decrypt(password, strlen(password), encrypted);
+        g_free(value);
+        return decrypted;
+    }
+}
+
+/**
+ * Deletes a nick and the associated key in the key store file.
+ */
+static bool delete_nick(GKeyFile *keyfile, const char *nick) {
+    gchar **group;
+    gchar **groups = g_key_file_get_groups(keyfile, NULL);
+    bool ok = false;
+    
+    for (group = groups; *group != NULL; group++) {
+        if (!irc_nick_cmp(*group, nick)) {
+            ok = g_key_file_remove_group(keyfile, *group, NULL);
+            break;
+        }
+    }
+    
+    g_strfreev(groups);
+    return ok;
+}
+
+/**
+ * Writes the key store file to disk.
+ */
+static bool save_keystore(GKeyFile *keyfile) {
+    char *filename;
+    bool ok;
+    // Serialize
+    gsize file_length;
+    gchar *file_data = g_key_file_to_data(keyfile, &file_length, NULL);
+    if (!file_data) return false;
+    
+    // Write to file
+    filename = get_config_filename();
+    ok = g_file_set_contents(filename, file_data, file_length, NULL);
+    g_free(filename);
+    g_free(file_data);
+    return ok;
+}
+
+/**
+ * Sets a key in the key store file.
+ */
+bool keystore_store_key(const char *nick, const char *key) {
+    const char *password;
+    char *encrypted;
+    char *wrapped;
+    bool ok = false;
+    GKeyFile *keyfile = getConfigFile();
+    
+    // Remove old key
+    delete_nick(keyfile, nick);
+    
+    // Add new key
+    password = get_keystore_password();
+    if (password) {
+        // Encrypt the password
+        encrypted = fish_encrypt(password, strlen(password), key);
+        if (!encrypted) goto end;
+        
+        // Prepend "OK+ "
+        wrapped = g_strconcat("OK+ ", encrypted, NULL);
+        g_free(encrypted);
+        
+        // Store encrypted in file
+        g_key_file_set_string(keyfile, nick, "key", wrapped);
+        free(wrapped);
+    } else {
+        // Store unencrypted in file
+        g_key_file_set_string(keyfile, nick, "key", key);
+    }
+    
+    // Save key store file
+    ok = save_keystore(keyfile);
+    
+  end:
+    g_key_file_free(keyfile);
+    return ok;
+}
+
+/**
+ * Deletes a nick from the key store.
+ */
+bool keystore_delete_nick(const char *nick) {
+    GKeyFile *keyfile = getConfigFile();
+    
+    // Delete entry
+    bool ok = delete_nick(keyfile, nick);
+    
+    // Save
+    if (ok) save_keystore(keyfile);
+    
+    g_key_file_free(keyfile);
+    return ok;
+}
+
+
+void keystore_secure_free(void *ptr, size_t size) {
+    secure_erase(ptr, size);
+    free(ptr);
+}
+
+
diff --git a/plugins/fishlim/keystore.h b/plugins/fishlim/keystore.h
new file mode 100644
index 00000000..e6c527c7
--- /dev/null
+++ b/plugins/fishlim/keystore.h
@@ -0,0 +1,42 @@
+/*
+
+  Copyright (c) 2010 Samuel Lidén Borell <samuel@slbdata.se>
+
+  Permission is hereby granted, free of charge, to any person obtaining a copy
+  of this software and associated documentation files (the "Software"), to deal
+  in the Software without restriction, including without limitation the rights
+  to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+  copies of the Software, and to permit persons to whom the Software is
+  furnished to do so, subject to the following conditions:
+
+  The above copyright notice and this permission notice shall be included in
+  all copies or substantial portions of the Software.
+
+  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+  FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+  AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+  LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+  THE SOFTWARE.
+
+*/
+
+#ifndef KEYSTORE_H
+#define KEYSTORE_H
+
+#ifdef _MSC_VER
+#include "bool.h"
+#else
+#include <stdbool.h>
+#endif
+#include <stddef.h>
+
+char *keystore_get_key(const char *nick);
+int keystore_store_key(const char *nick, const char *key);
+bool keystore_delete_nick(const char *nick);
+
+void keystore_secure_free(void *ptr, size_t size);
+
+#endif
+
diff --git a/plugins/fishlim/makefile.mak b/plugins/fishlim/makefile.mak
new file mode 100644
index 00000000..decf9bb4
--- /dev/null
+++ b/plugins/fishlim/makefile.mak
@@ -0,0 +1,30 @@
+include "..\..\src\makeinc.mak"
+
+TARGET = xcfishlim.dll
+
+CFLAGS = $(CFLAGS)
+
+FISHLIM_OBJECTS = \
+fish.obj \
+irc.obj \
+keystore.obj \
+misc.obj \
+xchat_plugin.obj
+
+all: $(FISHLIM_OBJECTS) fishlim.def
+	link $(LDFLAGS) $(LIBS) /dll /out:xcfishlim.dll /def:fishlim.def $(FISHLIM_OBJECTS)
+
+fishlim.def:
+	echo EXPORTS > fishlim.def
+	echo xchat_plugin_init >> fishlim.def
+	echo xchat_plugin_deinit >> fishlim.def
+	echo xchat_plugin_get_info >> fishlim.def
+
+.c.obj:
+	$(CC) $(CFLAGS) $(GLIB) /I.. /c $<
+
+clean:
+	del *.obj
+	del *.dll
+	del *.exp
+	del *.lib
diff --git a/plugins/fishlim/misc.c b/plugins/fishlim/misc.c
new file mode 100644
index 00000000..32fe3595
--- /dev/null
+++ b/plugins/fishlim/misc.c
@@ -0,0 +1,54 @@
+/*
+
+  Copyright (c) 2010 Samuel Lidén Borell <samuel@slbdata.se>
+
+  Permission is hereby granted, free of charge, to any person obtaining a copy
+  of this software and associated documentation files (the "Software"), to deal
+  in the Software without restriction, including without limitation the rights
+  to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+  copies of the Software, and to permit persons to whom the Software is
+  furnished to do so, subject to the following conditions:
+
+  The above copyright notice and this permission notice shall be included in
+  all copies or substantial portions of the Software.
+
+  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+  FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+  AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+  LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+  THE SOFTWARE.
+
+*/
+
+#include <glib.h>
+#include <stdlib.h>
+#include <string.h>
+#include "misc.h"
+
+
+void secure_erase(void *ptr, size_t size) {
+    // "volatile" prevents this code from being optimized away
+    volatile char* volptr = ptr;
+    while (size--) *volptr++ = 0;
+}
+
+/**
+ * Re-allocates a string with the native allocator.
+ */
+char *import_glib_string(gchar *gstr) {
+    size_t size;
+    char *native;
+    if (g_mem_is_system_malloc()) return gstr;
+    
+    size = strlen(gstr)+1;
+    native = malloc(size);
+    memcpy(native, gstr, size);
+    
+    secure_erase(gstr, size);
+    g_free(gstr);
+    return native;
+}
+
+
diff --git a/plugins/fishlim/misc.h b/plugins/fishlim/misc.h
new file mode 100644
index 00000000..0adc928c
--- /dev/null
+++ b/plugins/fishlim/misc.h
@@ -0,0 +1,36 @@
+/*
+
+  Copyright (c) 2010 Samuel Lidén Borell <samuel@slbdata.se>
+
+  Permission is hereby granted, free of charge, to any person obtaining a copy
+  of this software and associated documentation files (the "Software"), to deal
+  in the Software without restriction, including without limitation the rights
+  to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+  copies of the Software, and to permit persons to whom the Software is
+  furnished to do so, subject to the following conditions:
+
+  The above copyright notice and this permission notice shall be included in
+  all copies or substantial portions of the Software.
+
+  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+  FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+  AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+  LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+  THE SOFTWARE.
+
+*/
+
+#ifndef MISC_H
+#define MISC_H
+
+void secure_erase(void *ptr, size_t size);
+
+#ifdef __G_LIB_H__
+char *import_glib_string(gchar *gstr);
+#endif
+
+#endif
+
+
diff --git a/plugins/fishlim/test.c b/plugins/fishlim/test.c
new file mode 100644
index 00000000..2032496a
--- /dev/null
+++ b/plugins/fishlim/test.c
@@ -0,0 +1,83 @@
+/*
+
+  Copyright (c) 2010 Samuel Lidén Borell <samuel@slbdata.se>
+
+  Permission is hereby granted, free of charge, to any person obtaining a copy
+  of this software and associated documentation files (the "Software"), to deal
+  in the Software without restriction, including without limitation the rights
+  to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+  copies of the Software, and to permit persons to whom the Software is
+  furnished to do so, subject to the following conditions:
+
+  The above copyright notice and this permission notice shall be included in
+  all copies or substantial portions of the Software.
+
+  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+  FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+  AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+  LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+  THE SOFTWARE.
+
+*/
+
+#include <stdio.h>
+#include <string.h>
+#include "fish.h"
+
+static int decrypt(int nick_count, char *nicks[]) {
+    char encrypted[8192];
+    while (fgets(encrypted, sizeof(encrypted), stdin)) {
+        char *msg;
+        for (int i = 0; i < nick_count; i++) {
+            msg = fish_decrypt_from_nick(nicks[i], encrypted);
+            if (msg) goto success;
+        }
+        fprintf(stderr, "None of the recipients were found in the key store!\n");
+        return 1;
+      success:
+        fprintf(stderr, "Decrypted text >>>%s<<<\n", msg);
+    }
+    return 0;
+}
+
+static int encrypt(int nick_count, char *nicks[]) {
+    char message[8192];
+    while (fgets(message, sizeof(message), stdin)) {
+        // Remove newline character
+        char *newline = strchr(message, '\n');
+        if (newline) *newline = '\0';
+        
+        bool error = false;
+        for (int i = 0; i < nick_count; i++) {
+            char *encrypted = fish_encrypt_for_nick(nicks[i], message);
+            if (encrypted) {
+                fprintf(stderr, "Encrypted [%s]:  >>>%s<<<\n", nicks[i], encrypted);
+            } else {
+                error = true;
+            }
+        }
+        
+        if (error) {
+            fprintf(stderr, "Some of the recipients were't found in the key store!\n");
+            return 1;
+        }
+    }
+    return 0;
+}
+
+int main(int argc, char *argv[]) {
+    if (argc < 2) {
+        fprintf(stderr, "usage: %s [-e] nick...\n", argv[0]);
+        return 2;
+    }
+    
+    if (strcmp(argv[1], "-e") == 0) {
+        return encrypt(argc-2, &argv[2]);
+    } else {
+        return decrypt(argc-1, &argv[1]);
+    }
+}
+
+
diff --git a/plugins/fishlim/xchat_plugin.c b/plugins/fishlim/xchat_plugin.c
new file mode 100644
index 00000000..dc67fddb
--- /dev/null
+++ b/plugins/fishlim/xchat_plugin.c
@@ -0,0 +1,278 @@
+/*
+
+  Copyright (c) 2010-2011 Samuel Lidén Borell <samuel@slbdata.se>
+
+  Permission is hereby granted, free of charge, to any person obtaining a copy
+  of this software and associated documentation files (the "Software"), to deal
+  in the Software without restriction, including without limitation the rights
+  to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+  copies of the Software, and to permit persons to whom the Software is
+  furnished to do so, subject to the following conditions:
+
+  The above copyright notice and this permission notice shall be included in
+  all copies or substantial portions of the Software.
+
+  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+  FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+  AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+  LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+  THE SOFTWARE.
+
+*/
+
+#include <stdlib.h>
+#include <string.h>
+
+// #pragma GCC visibility push(default)
+#include "xchat-plugin.h"
+#define XCHAT_MAX_WORDS 32
+// #pragma GCC visibility pop
+
+//#define EXPORT __attribute((visibility("default")))
+//#define EXPORT
+
+#include "fish.h"
+#include "keystore.h"
+#include "irc.h"
+
+static const char plugin_name[] = "FiSHLiM";
+static const char plugin_desc[] = "Encryption plugin for the FiSH protocol. Less is More!";
+static const char plugin_version[] = "0.0.13";
+
+static const char usage_setkey[] = "Usage: SETKEY [<nick or #channel>] <password>, sets the key for a channel or nick";
+static const char usage_delkey[] = "Usage: DELKEY <nick or #channel>, deletes the key for a channel or nick";
+
+static xchat_plugin *ph;
+
+
+/**
+ * Appends data to a string. Returns true if there was sufficient memory.
+ * Frees *s and returns false if an error occurs.
+ */
+static bool append(char **s, size_t *length, const char *data) {
+    size_t datalen = strlen(data);
+    char *extended = realloc(*s, *length + datalen + 1);
+    if (!extended) {
+        free(*s);
+        return false;
+    }
+    memcpy(extended + *length, data, datalen + 1);
+    *s = extended;
+    *length += datalen;
+    return true;
+}
+
+
+/*static int handle_debug(char *word[], char *word_eol[], void *userdata) {
+    xchat_printf(ph, "debug incoming: ");
+    for (size_t i = 1; word[i] != NULL && word[i][0] != '\0'; i++) {
+        xchat_printf(ph, ">%s< ", word[i]);
+    }
+    xchat_printf(ph, "\n");
+    return XCHAT_EAT_NONE;
+}*/
+
+/**
+ * Called when a message is to be sent.
+ */
+static int handle_outgoing(char *word[], char *word_eol[], void *userdata) {
+    const char *own_nick;
+    // Encrypt the message if possible
+    const char *channel = xchat_get_info(ph, "channel");
+    char *encrypted = fish_encrypt_for_nick(channel, word_eol[1]);
+    if (!encrypted) return XCHAT_EAT_NONE;
+    
+    // Display message
+    own_nick = xchat_get_info(ph, "nick");
+    xchat_emit_print(ph, "Your Message", own_nick, word_eol[1], NULL);
+    
+    // Send message
+    xchat_commandf(ph, "PRIVMSG %s :+OK %s", channel, encrypted);
+    
+    free(encrypted);
+    return XCHAT_EAT_XCHAT;
+}
+
+/**
+ * Called when a channel message or private message is received.
+ */
+static int handle_incoming(char *word[], char *word_eol[], void *userdata) {
+    const char *prefix;
+    const char *command;
+    const char *recipient;
+    const char *encrypted;
+    const char *peice;
+	char *sender_nick;
+    char *decrypted;
+    char *message;
+    size_t w;
+    size_t ew;
+    size_t uw;
+    size_t length;
+
+    if (!irc_parse_message((const char **)word, &prefix, &command, &w))
+        return XCHAT_EAT_NONE;
+    
+    // Topic (command 332) has an extra parameter
+    if (!strcmp(command, "332")) w++;
+    
+    // Look for encrypted data
+    ew;
+    for (ew = w+1; ew < XCHAT_MAX_WORDS-1; ew++) {
+        const char *s = (ew == w+1 ? word[ew]+1 : word[ew]);
+        if (strcmp(s, "+OK") == 0) goto has_encrypted_data;
+    }
+    return XCHAT_EAT_NONE;
+  has_encrypted_data: ;
+    // Extract sender nick and recipient nick/channel
+    sender_nick = irc_prefix_get_nick(prefix);
+    recipient = word[w];
+    
+    // Try to decrypt with these (the keys are searched for in the key store)
+    encrypted = word[ew+1];
+    decrypted = fish_decrypt_from_nick(recipient, encrypted);
+    if (!decrypted) decrypted = fish_decrypt_from_nick(sender_nick, encrypted);
+    
+    // Check for error
+    if (!decrypted) goto decrypt_error;
+    
+    // Build unecrypted message
+    message = NULL;
+    length = 0;
+    if (!append(&message, &length, "RECV")) goto decrypt_error;
+    
+    for (uw = 1; uw < XCHAT_MAX_WORDS; uw++) {
+        if (word[uw][0] != '\0' && !append(&message, &length, " ")) goto decrypt_error;
+        
+        if (uw == ew) {
+            // Add the encrypted data
+            peice = decrypted;
+            uw++; // Skip "OK+"
+        } else {
+            // Add unencrypted data (for example, a prefix from a bouncer or bot)
+            peice = (uw == w+1 ? word[uw]+1 : word[uw]);
+        }
+        
+        if (!append(&message, &length, peice)) goto decrypt_error;
+    }
+    free(decrypted);
+    
+    // Simulate unencrypted message
+    //xchat_printf(ph, "simulating: %s\n", message);
+    xchat_command(ph, message);
+    
+    free(message);
+    free(sender_nick);
+    return XCHAT_EAT_XCHAT;
+  
+  decrypt_error:
+    free(decrypted);
+    free(sender_nick);
+    return XCHAT_EAT_NONE;
+}
+
+/**
+ * Command handler for /setkey
+ */
+static int handle_setkey(char *word[], char *word_eol[], void *userdata) {
+    const char *nick;
+    const char *key;
+    
+    // Check syntax
+    if (*word[2] == '\0') {
+        xchat_printf(ph, "%s\n", usage_setkey);
+        return XCHAT_EAT_XCHAT;
+    }
+    
+    if (*word[3] == '\0') {
+        // /setkey password
+        nick = xchat_get_info(ph, "channel");
+        key = word_eol[2];
+    } else {
+        // /setkey #channel password
+        nick = word[2];
+        key = word_eol[3];
+    }
+    
+    // Set password
+    if (keystore_store_key(nick, key)) {
+        xchat_printf(ph, "Stored key for %s\n", nick);
+    } else {
+        xchat_printf(ph, "\00305Failed to store key in blow.ini\n", nick, key);
+    }
+    
+    return XCHAT_EAT_XCHAT;
+}
+
+/**
+ * Command handler for /delkey
+ */
+static int handle_delkey(char *word[], char *word_eol[], void *userdata) {
+    const char *nick;
+    
+    // Check syntax
+    if (*word[2] == '\0' || *word[3] != '\0') {
+        xchat_printf(ph, "%s\n", usage_delkey);
+        return XCHAT_EAT_XCHAT;
+    }
+    
+    nick = word_eol[2];
+    
+    // Delete the given nick from the key store
+    if (keystore_delete_nick(nick)) {
+        xchat_printf(ph, "Deleted key for %s\n", nick);
+    } else {
+        xchat_printf(ph, "\00305Failed to delete key in blow.ini!\n", nick);
+    }
+    
+    return XCHAT_EAT_XCHAT;
+}
+
+/**
+ * Returns the plugin name version information.
+ */
+void xchat_plugin_get_info(const char **name, const char **desc,
+                                  const char **version, void **reserved) {
+    *name = plugin_name;
+    *desc = plugin_desc;
+    *version = plugin_version;
+}
+
+/**
+ * Plugin entry point.
+ */
+int xchat_plugin_init(xchat_plugin *plugin_handle,
+                             const char **name,
+                             const char **desc,
+                             const char **version,
+                             char *arg) {
+    ph = plugin_handle;
+    
+    /* Send our info to XChat */
+    *name = plugin_name;
+    *desc = plugin_desc;
+    *version = plugin_version;
+    
+    /* Register commands */
+    xchat_hook_command(ph, "SETKEY", XCHAT_PRI_NORM, handle_setkey, usage_setkey, NULL);
+    xchat_hook_command(ph, "DELKEY", XCHAT_PRI_NORM, handle_delkey, usage_delkey, NULL);
+    
+    /* Add handlers */
+    xchat_hook_command(ph, "", XCHAT_PRI_NORM, handle_outgoing, NULL, NULL);
+    xchat_hook_server(ph, "NOTICE", XCHAT_PRI_NORM, handle_incoming, NULL);
+    xchat_hook_server(ph, "PRIVMSG", XCHAT_PRI_NORM, handle_incoming, NULL);
+    //xchat_hook_server(ph, "RAW LINE", XCHAT_PRI_NORM, handle_debug, NULL);
+    xchat_hook_server(ph, "TOPIC", XCHAT_PRI_NORM, handle_incoming, NULL);
+    xchat_hook_server(ph, "332", XCHAT_PRI_NORM, handle_incoming, NULL);
+    
+    xchat_printf (ph, "%s plugin loaded\n", plugin_name);
+    /* Return success */
+    return 1;
+}
+
+int xchat_plugin_deinit(void) {
+    xchat_printf (ph, "%s plugin unloaded\n", plugin_name);
+    return 1;
+}
diff --git a/plugins/makefile.mak b/plugins/makefile.mak
index b08917ab..a308cae3 100644
--- a/plugins/makefile.mak
+++ b/plugins/makefile.mak
@@ -5,6 +5,8 @@ all:
 #	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\doat
 	@-$(MAKE) /nologo /s /f makefile.mak $@
+	@cd ..\fishlim
+	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\lua
 	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\mpcinfo
@@ -29,6 +31,8 @@ clean:
 #	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\doat
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
+	@cd ..\fishlim
+	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\lua
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\mpcinfo
-- 
cgit 1.4.1


From b15fe1ddf13de866d1ad8068db1d4632b5bbe094 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Thu, 24 Nov 2011 23:37:43 +0100
Subject: fix fishlim config handler

---
 plugins/fishlim/keystore.c     | 10 +---------
 plugins/fishlim/xchat_plugin.c |  8 ++++++++
 plugins/fishlim/xchat_plugin.h |  1 +
 3 files changed, 10 insertions(+), 9 deletions(-)
 create mode 100644 plugins/fishlim/xchat_plugin.h

(limited to 'plugins')

diff --git a/plugins/fishlim/keystore.c b/plugins/fishlim/keystore.c
index 6eccccaf..ff30faa7 100644
--- a/plugins/fishlim/keystore.c
+++ b/plugins/fishlim/keystore.c
@@ -29,20 +29,12 @@
 #include "fish.h"
 #include "misc.h"
 #include "keystore.h"
+#include "xchat_plugin.h"
 
 
 static char *keystore_password = NULL;
 
 
-/**
- * Returns the path to the key store file.
- */
-static gchar *get_config_filename() {
-    // TODO use xchat_get_info(ph, "xchatdirfs")
-    const gchar *homedir = g_get_home_dir();
-    return g_build_filename(homedir, ".xchat2", "blow.ini", NULL);
-}
-
 /**
  * Opens the key store file: ~/.xchat2/blow.ini
  */
diff --git a/plugins/fishlim/xchat_plugin.c b/plugins/fishlim/xchat_plugin.c
index dc67fddb..dd410548 100644
--- a/plugins/fishlim/xchat_plugin.c
+++ b/plugins/fishlim/xchat_plugin.c
@@ -22,6 +22,7 @@
 
 */
 
+#include <glib.h>
 #include <stdlib.h>
 #include <string.h>
 
@@ -47,6 +48,13 @@ static const char usage_delkey[] = "Usage: DELKEY <nick or #channel>, deletes th
 static xchat_plugin *ph;
 
 
+/**
+ * Returns the path to the key store file.
+ */
+gchar *get_config_filename() {
+    return g_build_filename(xchat_get_info(ph, "xchatdirfs"), "blow.ini", NULL);
+}
+
 /**
  * Appends data to a string. Returns true if there was sufficient memory.
  * Frees *s and returns false if an error occurs.
diff --git a/plugins/fishlim/xchat_plugin.h b/plugins/fishlim/xchat_plugin.h
new file mode 100644
index 00000000..40e21816
--- /dev/null
+++ b/plugins/fishlim/xchat_plugin.h
@@ -0,0 +1 @@
+gchar *get_config_filename();
-- 
cgit 1.4.1


From 3067b7b267d881963498d277d657e679ac15af45 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Fri, 25 Nov 2011 10:23:23 +0100
Subject: rename fishlim main file to avoid confusion

---
 plugins/fishlim/plugin_xchat.c | 286 +++++++++++++++++++++++++++++++++++++++++
 plugins/fishlim/plugin_xchat.h |   1 +
 plugins/fishlim/xchat_plugin.c | 286 -----------------------------------------
 plugins/fishlim/xchat_plugin.h |   1 -
 4 files changed, 287 insertions(+), 287 deletions(-)
 create mode 100644 plugins/fishlim/plugin_xchat.c
 create mode 100644 plugins/fishlim/plugin_xchat.h
 delete mode 100644 plugins/fishlim/xchat_plugin.c
 delete mode 100644 plugins/fishlim/xchat_plugin.h

(limited to 'plugins')

diff --git a/plugins/fishlim/plugin_xchat.c b/plugins/fishlim/plugin_xchat.c
new file mode 100644
index 00000000..dd410548
--- /dev/null
+++ b/plugins/fishlim/plugin_xchat.c
@@ -0,0 +1,286 @@
+/*
+
+  Copyright (c) 2010-2011 Samuel Lidén Borell <samuel@slbdata.se>
+
+  Permission is hereby granted, free of charge, to any person obtaining a copy
+  of this software and associated documentation files (the "Software"), to deal
+  in the Software without restriction, including without limitation the rights
+  to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+  copies of the Software, and to permit persons to whom the Software is
+  furnished to do so, subject to the following conditions:
+
+  The above copyright notice and this permission notice shall be included in
+  all copies or substantial portions of the Software.
+
+  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+  FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+  AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+  LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+  THE SOFTWARE.
+
+*/
+
+#include <glib.h>
+#include <stdlib.h>
+#include <string.h>
+
+// #pragma GCC visibility push(default)
+#include "xchat-plugin.h"
+#define XCHAT_MAX_WORDS 32
+// #pragma GCC visibility pop
+
+//#define EXPORT __attribute((visibility("default")))
+//#define EXPORT
+
+#include "fish.h"
+#include "keystore.h"
+#include "irc.h"
+
+static const char plugin_name[] = "FiSHLiM";
+static const char plugin_desc[] = "Encryption plugin for the FiSH protocol. Less is More!";
+static const char plugin_version[] = "0.0.13";
+
+static const char usage_setkey[] = "Usage: SETKEY [<nick or #channel>] <password>, sets the key for a channel or nick";
+static const char usage_delkey[] = "Usage: DELKEY <nick or #channel>, deletes the key for a channel or nick";
+
+static xchat_plugin *ph;
+
+
+/**
+ * Returns the path to the key store file.
+ */
+gchar *get_config_filename() {
+    return g_build_filename(xchat_get_info(ph, "xchatdirfs"), "blow.ini", NULL);
+}
+
+/**
+ * Appends data to a string. Returns true if there was sufficient memory.
+ * Frees *s and returns false if an error occurs.
+ */
+static bool append(char **s, size_t *length, const char *data) {
+    size_t datalen = strlen(data);
+    char *extended = realloc(*s, *length + datalen + 1);
+    if (!extended) {
+        free(*s);
+        return false;
+    }
+    memcpy(extended + *length, data, datalen + 1);
+    *s = extended;
+    *length += datalen;
+    return true;
+}
+
+
+/*static int handle_debug(char *word[], char *word_eol[], void *userdata) {
+    xchat_printf(ph, "debug incoming: ");
+    for (size_t i = 1; word[i] != NULL && word[i][0] != '\0'; i++) {
+        xchat_printf(ph, ">%s< ", word[i]);
+    }
+    xchat_printf(ph, "\n");
+    return XCHAT_EAT_NONE;
+}*/
+
+/**
+ * Called when a message is to be sent.
+ */
+static int handle_outgoing(char *word[], char *word_eol[], void *userdata) {
+    const char *own_nick;
+    // Encrypt the message if possible
+    const char *channel = xchat_get_info(ph, "channel");
+    char *encrypted = fish_encrypt_for_nick(channel, word_eol[1]);
+    if (!encrypted) return XCHAT_EAT_NONE;
+    
+    // Display message
+    own_nick = xchat_get_info(ph, "nick");
+    xchat_emit_print(ph, "Your Message", own_nick, word_eol[1], NULL);
+    
+    // Send message
+    xchat_commandf(ph, "PRIVMSG %s :+OK %s", channel, encrypted);
+    
+    free(encrypted);
+    return XCHAT_EAT_XCHAT;
+}
+
+/**
+ * Called when a channel message or private message is received.
+ */
+static int handle_incoming(char *word[], char *word_eol[], void *userdata) {
+    const char *prefix;
+    const char *command;
+    const char *recipient;
+    const char *encrypted;
+    const char *peice;
+	char *sender_nick;
+    char *decrypted;
+    char *message;
+    size_t w;
+    size_t ew;
+    size_t uw;
+    size_t length;
+
+    if (!irc_parse_message((const char **)word, &prefix, &command, &w))
+        return XCHAT_EAT_NONE;
+    
+    // Topic (command 332) has an extra parameter
+    if (!strcmp(command, "332")) w++;
+    
+    // Look for encrypted data
+    ew;
+    for (ew = w+1; ew < XCHAT_MAX_WORDS-1; ew++) {
+        const char *s = (ew == w+1 ? word[ew]+1 : word[ew]);
+        if (strcmp(s, "+OK") == 0) goto has_encrypted_data;
+    }
+    return XCHAT_EAT_NONE;
+  has_encrypted_data: ;
+    // Extract sender nick and recipient nick/channel
+    sender_nick = irc_prefix_get_nick(prefix);
+    recipient = word[w];
+    
+    // Try to decrypt with these (the keys are searched for in the key store)
+    encrypted = word[ew+1];
+    decrypted = fish_decrypt_from_nick(recipient, encrypted);
+    if (!decrypted) decrypted = fish_decrypt_from_nick(sender_nick, encrypted);
+    
+    // Check for error
+    if (!decrypted) goto decrypt_error;
+    
+    // Build unecrypted message
+    message = NULL;
+    length = 0;
+    if (!append(&message, &length, "RECV")) goto decrypt_error;
+    
+    for (uw = 1; uw < XCHAT_MAX_WORDS; uw++) {
+        if (word[uw][0] != '\0' && !append(&message, &length, " ")) goto decrypt_error;
+        
+        if (uw == ew) {
+            // Add the encrypted data
+            peice = decrypted;
+            uw++; // Skip "OK+"
+        } else {
+            // Add unencrypted data (for example, a prefix from a bouncer or bot)
+            peice = (uw == w+1 ? word[uw]+1 : word[uw]);
+        }
+        
+        if (!append(&message, &length, peice)) goto decrypt_error;
+    }
+    free(decrypted);
+    
+    // Simulate unencrypted message
+    //xchat_printf(ph, "simulating: %s\n", message);
+    xchat_command(ph, message);
+    
+    free(message);
+    free(sender_nick);
+    return XCHAT_EAT_XCHAT;
+  
+  decrypt_error:
+    free(decrypted);
+    free(sender_nick);
+    return XCHAT_EAT_NONE;
+}
+
+/**
+ * Command handler for /setkey
+ */
+static int handle_setkey(char *word[], char *word_eol[], void *userdata) {
+    const char *nick;
+    const char *key;
+    
+    // Check syntax
+    if (*word[2] == '\0') {
+        xchat_printf(ph, "%s\n", usage_setkey);
+        return XCHAT_EAT_XCHAT;
+    }
+    
+    if (*word[3] == '\0') {
+        // /setkey password
+        nick = xchat_get_info(ph, "channel");
+        key = word_eol[2];
+    } else {
+        // /setkey #channel password
+        nick = word[2];
+        key = word_eol[3];
+    }
+    
+    // Set password
+    if (keystore_store_key(nick, key)) {
+        xchat_printf(ph, "Stored key for %s\n", nick);
+    } else {
+        xchat_printf(ph, "\00305Failed to store key in blow.ini\n", nick, key);
+    }
+    
+    return XCHAT_EAT_XCHAT;
+}
+
+/**
+ * Command handler for /delkey
+ */
+static int handle_delkey(char *word[], char *word_eol[], void *userdata) {
+    const char *nick;
+    
+    // Check syntax
+    if (*word[2] == '\0' || *word[3] != '\0') {
+        xchat_printf(ph, "%s\n", usage_delkey);
+        return XCHAT_EAT_XCHAT;
+    }
+    
+    nick = word_eol[2];
+    
+    // Delete the given nick from the key store
+    if (keystore_delete_nick(nick)) {
+        xchat_printf(ph, "Deleted key for %s\n", nick);
+    } else {
+        xchat_printf(ph, "\00305Failed to delete key in blow.ini!\n", nick);
+    }
+    
+    return XCHAT_EAT_XCHAT;
+}
+
+/**
+ * Returns the plugin name version information.
+ */
+void xchat_plugin_get_info(const char **name, const char **desc,
+                                  const char **version, void **reserved) {
+    *name = plugin_name;
+    *desc = plugin_desc;
+    *version = plugin_version;
+}
+
+/**
+ * Plugin entry point.
+ */
+int xchat_plugin_init(xchat_plugin *plugin_handle,
+                             const char **name,
+                             const char **desc,
+                             const char **version,
+                             char *arg) {
+    ph = plugin_handle;
+    
+    /* Send our info to XChat */
+    *name = plugin_name;
+    *desc = plugin_desc;
+    *version = plugin_version;
+    
+    /* Register commands */
+    xchat_hook_command(ph, "SETKEY", XCHAT_PRI_NORM, handle_setkey, usage_setkey, NULL);
+    xchat_hook_command(ph, "DELKEY", XCHAT_PRI_NORM, handle_delkey, usage_delkey, NULL);
+    
+    /* Add handlers */
+    xchat_hook_command(ph, "", XCHAT_PRI_NORM, handle_outgoing, NULL, NULL);
+    xchat_hook_server(ph, "NOTICE", XCHAT_PRI_NORM, handle_incoming, NULL);
+    xchat_hook_server(ph, "PRIVMSG", XCHAT_PRI_NORM, handle_incoming, NULL);
+    //xchat_hook_server(ph, "RAW LINE", XCHAT_PRI_NORM, handle_debug, NULL);
+    xchat_hook_server(ph, "TOPIC", XCHAT_PRI_NORM, handle_incoming, NULL);
+    xchat_hook_server(ph, "332", XCHAT_PRI_NORM, handle_incoming, NULL);
+    
+    xchat_printf (ph, "%s plugin loaded\n", plugin_name);
+    /* Return success */
+    return 1;
+}
+
+int xchat_plugin_deinit(void) {
+    xchat_printf (ph, "%s plugin unloaded\n", plugin_name);
+    return 1;
+}
diff --git a/plugins/fishlim/plugin_xchat.h b/plugins/fishlim/plugin_xchat.h
new file mode 100644
index 00000000..40e21816
--- /dev/null
+++ b/plugins/fishlim/plugin_xchat.h
@@ -0,0 +1 @@
+gchar *get_config_filename();
diff --git a/plugins/fishlim/xchat_plugin.c b/plugins/fishlim/xchat_plugin.c
deleted file mode 100644
index dd410548..00000000
--- a/plugins/fishlim/xchat_plugin.c
+++ /dev/null
@@ -1,286 +0,0 @@
-/*
-
-  Copyright (c) 2010-2011 Samuel Lidén Borell <samuel@slbdata.se>
-
-  Permission is hereby granted, free of charge, to any person obtaining a copy
-  of this software and associated documentation files (the "Software"), to deal
-  in the Software without restriction, including without limitation the rights
-  to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-  copies of the Software, and to permit persons to whom the Software is
-  furnished to do so, subject to the following conditions:
-
-  The above copyright notice and this permission notice shall be included in
-  all copies or substantial portions of the Software.
-
-  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-  FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-  AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-  LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-  THE SOFTWARE.
-
-*/
-
-#include <glib.h>
-#include <stdlib.h>
-#include <string.h>
-
-// #pragma GCC visibility push(default)
-#include "xchat-plugin.h"
-#define XCHAT_MAX_WORDS 32
-// #pragma GCC visibility pop
-
-//#define EXPORT __attribute((visibility("default")))
-//#define EXPORT
-
-#include "fish.h"
-#include "keystore.h"
-#include "irc.h"
-
-static const char plugin_name[] = "FiSHLiM";
-static const char plugin_desc[] = "Encryption plugin for the FiSH protocol. Less is More!";
-static const char plugin_version[] = "0.0.13";
-
-static const char usage_setkey[] = "Usage: SETKEY [<nick or #channel>] <password>, sets the key for a channel or nick";
-static const char usage_delkey[] = "Usage: DELKEY <nick or #channel>, deletes the key for a channel or nick";
-
-static xchat_plugin *ph;
-
-
-/**
- * Returns the path to the key store file.
- */
-gchar *get_config_filename() {
-    return g_build_filename(xchat_get_info(ph, "xchatdirfs"), "blow.ini", NULL);
-}
-
-/**
- * Appends data to a string. Returns true if there was sufficient memory.
- * Frees *s and returns false if an error occurs.
- */
-static bool append(char **s, size_t *length, const char *data) {
-    size_t datalen = strlen(data);
-    char *extended = realloc(*s, *length + datalen + 1);
-    if (!extended) {
-        free(*s);
-        return false;
-    }
-    memcpy(extended + *length, data, datalen + 1);
-    *s = extended;
-    *length += datalen;
-    return true;
-}
-
-
-/*static int handle_debug(char *word[], char *word_eol[], void *userdata) {
-    xchat_printf(ph, "debug incoming: ");
-    for (size_t i = 1; word[i] != NULL && word[i][0] != '\0'; i++) {
-        xchat_printf(ph, ">%s< ", word[i]);
-    }
-    xchat_printf(ph, "\n");
-    return XCHAT_EAT_NONE;
-}*/
-
-/**
- * Called when a message is to be sent.
- */
-static int handle_outgoing(char *word[], char *word_eol[], void *userdata) {
-    const char *own_nick;
-    // Encrypt the message if possible
-    const char *channel = xchat_get_info(ph, "channel");
-    char *encrypted = fish_encrypt_for_nick(channel, word_eol[1]);
-    if (!encrypted) return XCHAT_EAT_NONE;
-    
-    // Display message
-    own_nick = xchat_get_info(ph, "nick");
-    xchat_emit_print(ph, "Your Message", own_nick, word_eol[1], NULL);
-    
-    // Send message
-    xchat_commandf(ph, "PRIVMSG %s :+OK %s", channel, encrypted);
-    
-    free(encrypted);
-    return XCHAT_EAT_XCHAT;
-}
-
-/**
- * Called when a channel message or private message is received.
- */
-static int handle_incoming(char *word[], char *word_eol[], void *userdata) {
-    const char *prefix;
-    const char *command;
-    const char *recipient;
-    const char *encrypted;
-    const char *peice;
-	char *sender_nick;
-    char *decrypted;
-    char *message;
-    size_t w;
-    size_t ew;
-    size_t uw;
-    size_t length;
-
-    if (!irc_parse_message((const char **)word, &prefix, &command, &w))
-        return XCHAT_EAT_NONE;
-    
-    // Topic (command 332) has an extra parameter
-    if (!strcmp(command, "332")) w++;
-    
-    // Look for encrypted data
-    ew;
-    for (ew = w+1; ew < XCHAT_MAX_WORDS-1; ew++) {
-        const char *s = (ew == w+1 ? word[ew]+1 : word[ew]);
-        if (strcmp(s, "+OK") == 0) goto has_encrypted_data;
-    }
-    return XCHAT_EAT_NONE;
-  has_encrypted_data: ;
-    // Extract sender nick and recipient nick/channel
-    sender_nick = irc_prefix_get_nick(prefix);
-    recipient = word[w];
-    
-    // Try to decrypt with these (the keys are searched for in the key store)
-    encrypted = word[ew+1];
-    decrypted = fish_decrypt_from_nick(recipient, encrypted);
-    if (!decrypted) decrypted = fish_decrypt_from_nick(sender_nick, encrypted);
-    
-    // Check for error
-    if (!decrypted) goto decrypt_error;
-    
-    // Build unecrypted message
-    message = NULL;
-    length = 0;
-    if (!append(&message, &length, "RECV")) goto decrypt_error;
-    
-    for (uw = 1; uw < XCHAT_MAX_WORDS; uw++) {
-        if (word[uw][0] != '\0' && !append(&message, &length, " ")) goto decrypt_error;
-        
-        if (uw == ew) {
-            // Add the encrypted data
-            peice = decrypted;
-            uw++; // Skip "OK+"
-        } else {
-            // Add unencrypted data (for example, a prefix from a bouncer or bot)
-            peice = (uw == w+1 ? word[uw]+1 : word[uw]);
-        }
-        
-        if (!append(&message, &length, peice)) goto decrypt_error;
-    }
-    free(decrypted);
-    
-    // Simulate unencrypted message
-    //xchat_printf(ph, "simulating: %s\n", message);
-    xchat_command(ph, message);
-    
-    free(message);
-    free(sender_nick);
-    return XCHAT_EAT_XCHAT;
-  
-  decrypt_error:
-    free(decrypted);
-    free(sender_nick);
-    return XCHAT_EAT_NONE;
-}
-
-/**
- * Command handler for /setkey
- */
-static int handle_setkey(char *word[], char *word_eol[], void *userdata) {
-    const char *nick;
-    const char *key;
-    
-    // Check syntax
-    if (*word[2] == '\0') {
-        xchat_printf(ph, "%s\n", usage_setkey);
-        return XCHAT_EAT_XCHAT;
-    }
-    
-    if (*word[3] == '\0') {
-        // /setkey password
-        nick = xchat_get_info(ph, "channel");
-        key = word_eol[2];
-    } else {
-        // /setkey #channel password
-        nick = word[2];
-        key = word_eol[3];
-    }
-    
-    // Set password
-    if (keystore_store_key(nick, key)) {
-        xchat_printf(ph, "Stored key for %s\n", nick);
-    } else {
-        xchat_printf(ph, "\00305Failed to store key in blow.ini\n", nick, key);
-    }
-    
-    return XCHAT_EAT_XCHAT;
-}
-
-/**
- * Command handler for /delkey
- */
-static int handle_delkey(char *word[], char *word_eol[], void *userdata) {
-    const char *nick;
-    
-    // Check syntax
-    if (*word[2] == '\0' || *word[3] != '\0') {
-        xchat_printf(ph, "%s\n", usage_delkey);
-        return XCHAT_EAT_XCHAT;
-    }
-    
-    nick = word_eol[2];
-    
-    // Delete the given nick from the key store
-    if (keystore_delete_nick(nick)) {
-        xchat_printf(ph, "Deleted key for %s\n", nick);
-    } else {
-        xchat_printf(ph, "\00305Failed to delete key in blow.ini!\n", nick);
-    }
-    
-    return XCHAT_EAT_XCHAT;
-}
-
-/**
- * Returns the plugin name version information.
- */
-void xchat_plugin_get_info(const char **name, const char **desc,
-                                  const char **version, void **reserved) {
-    *name = plugin_name;
-    *desc = plugin_desc;
-    *version = plugin_version;
-}
-
-/**
- * Plugin entry point.
- */
-int xchat_plugin_init(xchat_plugin *plugin_handle,
-                             const char **name,
-                             const char **desc,
-                             const char **version,
-                             char *arg) {
-    ph = plugin_handle;
-    
-    /* Send our info to XChat */
-    *name = plugin_name;
-    *desc = plugin_desc;
-    *version = plugin_version;
-    
-    /* Register commands */
-    xchat_hook_command(ph, "SETKEY", XCHAT_PRI_NORM, handle_setkey, usage_setkey, NULL);
-    xchat_hook_command(ph, "DELKEY", XCHAT_PRI_NORM, handle_delkey, usage_delkey, NULL);
-    
-    /* Add handlers */
-    xchat_hook_command(ph, "", XCHAT_PRI_NORM, handle_outgoing, NULL, NULL);
-    xchat_hook_server(ph, "NOTICE", XCHAT_PRI_NORM, handle_incoming, NULL);
-    xchat_hook_server(ph, "PRIVMSG", XCHAT_PRI_NORM, handle_incoming, NULL);
-    //xchat_hook_server(ph, "RAW LINE", XCHAT_PRI_NORM, handle_debug, NULL);
-    xchat_hook_server(ph, "TOPIC", XCHAT_PRI_NORM, handle_incoming, NULL);
-    xchat_hook_server(ph, "332", XCHAT_PRI_NORM, handle_incoming, NULL);
-    
-    xchat_printf (ph, "%s plugin loaded\n", plugin_name);
-    /* Return success */
-    return 1;
-}
-
-int xchat_plugin_deinit(void) {
-    xchat_printf (ph, "%s plugin unloaded\n", plugin_name);
-    return 1;
-}
diff --git a/plugins/fishlim/xchat_plugin.h b/plugins/fishlim/xchat_plugin.h
deleted file mode 100644
index 40e21816..00000000
--- a/plugins/fishlim/xchat_plugin.h
+++ /dev/null
@@ -1 +0,0 @@
-gchar *get_config_filename();
-- 
cgit 1.4.1


From 81ed389e71cda96c1bd5935dd5f9cb98327870ce Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Fri, 25 Nov 2011 10:24:33 +0100
Subject: get in sync with fishlim upstream

---
 plugins/fishlim/Makefile       |  6 +++---
 plugins/fishlim/README         |  2 +-
 plugins/fishlim/fish.c         | 28 ++++++++++++++--------------
 plugins/fishlim/keystore.c     |  2 +-
 plugins/fishlim/keystore.h     |  2 +-
 plugins/fishlim/plugin_xchat.c | 24 ++++++++++++++----------
 plugins/fishlim/plugin_xchat.h | 30 ++++++++++++++++++++++++++++++
 plugins/fishlim/test.c         |  8 ++++++++
 8 files changed, 72 insertions(+), 30 deletions(-)

(limited to 'plugins')

diff --git a/plugins/fishlim/Makefile b/plugins/fishlim/Makefile
index 7a5081e4..a1832c84 100644
--- a/plugins/fishlim/Makefile
+++ b/plugins/fishlim/Makefile
@@ -4,17 +4,17 @@ OURCFLAGS = -Wall -Wextra -Wno-unused-parameter -std=c99 -pedantic `pkg-config -
 OURLINKFLAGS = `pkg-config --libs glib-2.0 libcrypto` $(CFLAGS) $(LDFLAGS)
 
 BASE_OBJECTS = irc.o fish.o keystore.o misc.o
-PLUGIN_OBJECTS = $(BASE_OBJECTS) xchat_plugin.o
+PLUGIN_OBJECTS = $(BASE_OBJECTS) plugin_xchat.o
 TEST_OBJECTS = $(BASE_OBJECTS) test.o
 
 all: fishlim.so test
 
 fish.o: fish.h keystore.h misc.h
 irc.o: irc.h
-keystore.o: keystore.h irc.h fish.h misc.h
+keystore.o: keystore.h irc.h fish.h misc.h plugin_xchat.h
 misc.o: misc.h
 test.o: fish.h
-xchat_plugin.o: fish.h irc.h keystore.h
+plugin_xchat.o: fish.h irc.h keystore.h plugin_xchat.h
 
 .c.o:
 	$(CC) $(OURCFLAGS) -c $< -o $@
diff --git a/plugins/fishlim/README b/plugins/fishlim/README
index 9c5cd5fc..4f315b44 100644
--- a/plugins/fishlim/README
+++ b/plugins/fishlim/README
@@ -2,7 +2,7 @@
 
                                 FiSHLiM
 
-                       http://fishlim.slbdata.se/
+                       http://fishlim.kodafritt.se/
 
 
 FiSHLiM is an XChat plugin for FiSH IRC encryption. It's my attempt at making
diff --git a/plugins/fishlim/fish.c b/plugins/fishlim/fish.c
index 0d92ecc9..cb977d7f 100644
--- a/plugins/fishlim/fish.c
+++ b/plugins/fishlim/fish.c
@@ -58,14 +58,14 @@ static const signed char fish_unbase64[256] = {
 
 char *fish_encrypt(const char *key, size_t keylen, const char *message) {
     BF_KEY bfkey;
-	size_t messagelen;
-	size_t i;
-	int j;
-	char *encrypted;
-	char *end;
-	unsigned char bit;
-	unsigned char word;
-	unsigned char d;
+    size_t messagelen;
+    size_t i;
+    int j;
+    char *encrypted;
+    char *end;
+    unsigned char bit;
+    unsigned char word;
+    unsigned char d;
     BF_set_key(&bfkey, keylen, (const unsigned char*)key);
     
     messagelen = strlen(message);
@@ -111,12 +111,12 @@ char *fish_encrypt(const char *key, size_t keylen, const char *message) {
 
 char *fish_decrypt(const char *key, size_t keylen, const char *data) {
     BF_KEY bfkey;
-	size_t i;
-	char *decrypted;
-	char *end;
-	unsigned char bit;
-	unsigned char word;
-	unsigned char d;
+    size_t i;
+    char *decrypted;
+    char *end;
+    unsigned char bit;
+    unsigned char word;
+    unsigned char d;
     BF_set_key(&bfkey, keylen, (const unsigned char*)key);
     
     decrypted = malloc(strlen(data)+1);
diff --git a/plugins/fishlim/keystore.c b/plugins/fishlim/keystore.c
index ff30faa7..ce029a2e 100644
--- a/plugins/fishlim/keystore.c
+++ b/plugins/fishlim/keystore.c
@@ -29,7 +29,7 @@
 #include "fish.h"
 #include "misc.h"
 #include "keystore.h"
-#include "xchat_plugin.h"
+#include "plugin_xchat.h"
 
 
 static char *keystore_password = NULL;
diff --git a/plugins/fishlim/keystore.h b/plugins/fishlim/keystore.h
index e6c527c7..b0c1c69c 100644
--- a/plugins/fishlim/keystore.h
+++ b/plugins/fishlim/keystore.h
@@ -33,7 +33,7 @@
 #include <stddef.h>
 
 char *keystore_get_key(const char *nick);
-int keystore_store_key(const char *nick, const char *key);
+bool keystore_store_key(const char *nick, const char *key);
 bool keystore_delete_nick(const char *nick);
 
 void keystore_secure_free(void *ptr, size_t size);
diff --git a/plugins/fishlim/plugin_xchat.c b/plugins/fishlim/plugin_xchat.c
index dd410548..ba0e1280 100644
--- a/plugins/fishlim/plugin_xchat.c
+++ b/plugins/fishlim/plugin_xchat.c
@@ -27,7 +27,11 @@
 #include <string.h>
 
 // #pragma GCC visibility push(default)
+#ifdef _MSC_VER
 #include "xchat-plugin.h"
+#else
+#include <xchat/xchat-plugin.h>
+#endif
 #define XCHAT_MAX_WORDS 32
 // #pragma GCC visibility pop
 
@@ -40,7 +44,7 @@
 
 static const char plugin_name[] = "FiSHLiM";
 static const char plugin_desc[] = "Encryption plugin for the FiSH protocol. Less is More!";
-static const char plugin_version[] = "0.0.13";
+static const char plugin_version[] = "0.0.14";
 
 static const char usage_setkey[] = "Usage: SETKEY [<nick or #channel>] <password>, sets the key for a channel or nick";
 static const char usage_delkey[] = "Usage: DELKEY <nick or #channel>, deletes the key for a channel or nick";
@@ -112,7 +116,7 @@ static int handle_incoming(char *word[], char *word_eol[], void *userdata) {
     const char *recipient;
     const char *encrypted;
     const char *peice;
-	char *sender_nick;
+    char *sender_nick;
     char *decrypted;
     char *message;
     size_t w;
@@ -127,7 +131,6 @@ static int handle_incoming(char *word[], char *word_eol[], void *userdata) {
     if (!strcmp(command, "332")) w++;
     
     // Look for encrypted data
-    ew;
     for (ew = w+1; ew < XCHAT_MAX_WORDS-1; ew++) {
         const char *s = (ew == w+1 ? word[ew]+1 : word[ew]);
         if (strcmp(s, "+OK") == 0) goto has_encrypted_data;
@@ -242,7 +245,7 @@ static int handle_delkey(char *word[], char *word_eol[], void *userdata) {
  * Returns the plugin name version information.
  */
 void xchat_plugin_get_info(const char **name, const char **desc,
-                                  const char **version, void **reserved) {
+                           const char **version, void **reserved) {
     *name = plugin_name;
     *desc = plugin_desc;
     *version = plugin_version;
@@ -252,10 +255,10 @@ void xchat_plugin_get_info(const char **name, const char **desc,
  * Plugin entry point.
  */
 int xchat_plugin_init(xchat_plugin *plugin_handle,
-                             const char **name,
-                             const char **desc,
-                             const char **version,
-                             char *arg) {
+                      const char **name,
+                      const char **desc,
+                      const char **version,
+                      char *arg) {
     ph = plugin_handle;
     
     /* Send our info to XChat */
@@ -275,12 +278,13 @@ int xchat_plugin_init(xchat_plugin *plugin_handle,
     xchat_hook_server(ph, "TOPIC", XCHAT_PRI_NORM, handle_incoming, NULL);
     xchat_hook_server(ph, "332", XCHAT_PRI_NORM, handle_incoming, NULL);
     
-    xchat_printf (ph, "%s plugin loaded\n", plugin_name);
+    xchat_printf(ph, "%s plugin loaded\n", plugin_name);
     /* Return success */
     return 1;
 }
 
 int xchat_plugin_deinit(void) {
-    xchat_printf (ph, "%s plugin unloaded\n", plugin_name);
+    xchat_printf(ph, "%s plugin unloaded\n", plugin_name);
     return 1;
 }
+
diff --git a/plugins/fishlim/plugin_xchat.h b/plugins/fishlim/plugin_xchat.h
index 40e21816..0243e81f 100644
--- a/plugins/fishlim/plugin_xchat.h
+++ b/plugins/fishlim/plugin_xchat.h
@@ -1 +1,31 @@
+/*
+
+  Copyright (c) 2010 Samuel Lidén Borell <samuel@slbdata.se>
+
+  Permission is hereby granted, free of charge, to any person obtaining a copy
+  of this software and associated documentation files (the "Software"), to deal
+  in the Software without restriction, including without limitation the rights
+  to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+  copies of the Software, and to permit persons to whom the Software is
+  furnished to do so, subject to the following conditions:
+
+  The above copyright notice and this permission notice shall be included in
+  all copies or substantial portions of the Software.
+
+  THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+  IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+  FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+  AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+  LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+  THE SOFTWARE.
+
+*/
+
+#ifndef XCHAT_PLUGIN_H
+#define XCHAT_PLUGIN_H
+
 gchar *get_config_filename();
+
+#endif
+
diff --git a/plugins/fishlim/test.c b/plugins/fishlim/test.c
index 2032496a..3511bbb1 100644
--- a/plugins/fishlim/test.c
+++ b/plugins/fishlim/test.c
@@ -22,10 +22,18 @@
 
 */
 
+#include <glib.h>
 #include <stdio.h>
 #include <string.h>
 #include "fish.h"
 
+// We can't use the XChat plugin API from here...
+gchar *get_config_filename() {
+    const gchar *homedir = g_get_home_dir();
+    return g_build_filename(homedir, ".xchat2", "blow.ini", NULL);
+}
+
+
 static int decrypt(int nick_count, char *nicks[]) {
     char encrypted[8192];
     while (fgets(encrypted, sizeof(encrypted), stdin)) {
-- 
cgit 1.4.1


From 090974960eeb7b70def20e8bb189e7380a2b932b Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Fri, 25 Nov 2011 10:26:59 +0100
Subject: rename fishlim main file in makefile too

---
 plugins/fishlim/makefile.mak | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/fishlim/makefile.mak b/plugins/fishlim/makefile.mak
index decf9bb4..4d0be66b 100644
--- a/plugins/fishlim/makefile.mak
+++ b/plugins/fishlim/makefile.mak
@@ -9,7 +9,7 @@ fish.obj \
 irc.obj \
 keystore.obj \
 misc.obj \
-xchat_plugin.obj
+plugin_xchat.obj
 
 all: $(FISHLIM_OBJECTS) fishlim.def
 	link $(LDFLAGS) $(LIBS) /dll /out:xcfishlim.dll /def:fishlim.def $(FISHLIM_OBJECTS)
-- 
cgit 1.4.1


From 408487f89bce1d0fdbf54e3c42e01e92f61a1c25 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Fri, 25 Nov 2011 21:44:08 +0100
Subject: perform periodic update checks automatically

---
 plugins/upd/upd.c | 37 +++++++++++++++++++++++++++++++++----
 1 file changed, 33 insertions(+), 4 deletions(-)

(limited to 'plugins')

diff --git a/plugins/upd/upd.c b/plugins/upd/upd.c
index 72da7f5c..b4fa5704 100644
--- a/plugins/upd/upd.c
+++ b/plugins/upd/upd.c
@@ -65,7 +65,7 @@ check_version ()
 	return "Unknown";
 }
 
-static void
+static int
 print_version ()
 {
 	char *version = check_version ();
@@ -73,10 +73,12 @@ print_version ()
 	if (strcmp (version, xchat_get_info (ph, "wdk_version")) == 0)
 	{
 		xchat_printf (ph, "You have the latest version of XChat-WDK installed!\n");
+		return 0;
 	}
 	else if (strcmp (version, "Unknown") == 0)
 	{
 		xchat_printf (ph, "Unable to check for XChat-WDK updates!\n");
+		return 0;
 	}
 	else
 	{
@@ -85,9 +87,30 @@ print_version ()
 #else
 		xchat_printf (ph, "An XChat-WDK update is available! You can download it from here:\nhttp://xchat-wdk.googlecode.com/files/XChat-WDK%%20%s%%20x86.exe\n", version);
 #endif
+		return 1;
 	}
 }
 
+static int
+print_version_quiet (void *userdata)
+{
+	char *version = check_version ();
+
+	/* if it's not the current version AND not network error */
+	if (!(strcmp (version, xchat_get_info (ph, "wdk_version")) == 0) && !(strcmp (version, "Unknown") == 0))
+	{
+#ifdef _WIN64 /* use this approach, the wProcessorArchitecture method always returns 0 (=x86) for plugins for some reason */
+		xchat_printf (ph, "An XChat-WDK update is available! You can download it from here:\nhttp://xchat-wdk.googlecode.com/files/XChat-WDK%%20%s%%20x64.exe\n", version);
+#else
+		xchat_printf (ph, "An XChat-WDK update is available! You can download it from here:\nhttp://xchat-wdk.googlecode.com/files/XChat-WDK%%20%s%%20x86.exe\n", version);
+#endif
+		/* print update url once, then stop the timer */
+		return 0;
+	}
+	/* keep checking */
+	return 1;
+}
+
 int
 xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugin_desc, char **plugin_version, char *arg)
 {
@@ -95,13 +118,19 @@ xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugi
 
 	*plugin_name = "Update Checker";
 	*plugin_desc = "Plugin for checking for XChat-WDK updates";
-	*plugin_version = "1.5";
+	*plugin_version = "2.0";
 
 	xchat_hook_command (ph, "UPDCHK", XCHAT_PRI_NORM, print_version, 0, 0);
 	xchat_command (ph, "MENU -ietc\\download.png ADD \"Help/Check for Updates\" \"UPDCHK\"");
 
-	xchat_print (ph, "Update Checker plugin loaded\n");
-	print_version ();
+	xchat_printf (ph, "%s plugin loaded\n", *plugin_name);
+
+	/* only start the timer if there's no update available during startup */
+	if (!print_version ())
+	{
+		/* check for updates every 6 hours */
+		xchat_hook_timer (ph, 21600000, print_version_quiet, NULL);
+	}
 
 	return 1;       /* return 1 for success */
 }
-- 
cgit 1.4.1


From fa7991495e70918603b071d6cbb4147347ccc13b Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sun, 27 Nov 2011 07:24:42 +0100
Subject: initial exec

---
 plugins/exec/exec.c       | 197 ++++++++++++++++++++++++++++++++++++++++++++++
 plugins/exec/makefile.mak |  18 +++++
 2 files changed, 215 insertions(+)
 create mode 100644 plugins/exec/exec.c
 create mode 100644 plugins/exec/makefile.mak

(limited to 'plugins')

diff --git a/plugins/exec/exec.c b/plugins/exec/exec.c
new file mode 100644
index 00000000..1c8f5a06
--- /dev/null
+++ b/plugins/exec/exec.c
@@ -0,0 +1,197 @@
+/* XChat-WDK
+ * Copyright (c) 2011 Berke Viktor.
+ *
+ * Redistribution and use in source and binary forms, with or without
+ * modification, are permitted provided that the following conditions
+ * are met:
+ * 1. Redistributions of source code must retain the above copyright
+ *    notice, this list of conditions and the following disclaimer.
+ * 2. Redistributions in binary form must reproduce the above copyright
+ *    notice, this list of conditions and the following disclaimer in the
+ *    documentation and/or other materials provided with the distribution.
+ * 3. The name of the author may not be used to endorse or promote products
+ *    derived from this software without specific prior written permission.
+ *
+ * THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR
+ * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
+ * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
+ * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
+ * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
+ * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+ * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+ * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+ * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
+ * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ */
+
+#include <windows.h>
+
+#include "xchat-plugin.h"
+
+static xchat_plugin *ph;   /* plugin handle */
+
+
+
+
+
+
+/*static void
+run_command (char *word[], char *word_eol[], void *userdata)
+{
+	char commandLine[1024];
+	char buf[100];
+	char buff1[256];
+	DWORD dwRead,tdwRead,tdwAfail,tdwLeft, dwAvail, ctr = 0;
+
+	HANDLE readPipe, writePipe;
+	STARTUPINFO sInfo; 
+	PROCESS_INFORMATION pInfo; 
+	BOOL res;	
+	DWORD reDword; 
+
+	SECURITY_ATTRIBUTES secattr; 
+	ZeroMemory(&secattr,sizeof(secattr));
+	secattr.nLength = sizeof(secattr);
+	secattr.bInheritHandle = TRUE;
+	
+	xchat_printf (ph, "%d", strlen(word[2]));
+	if (strlen (word[2]) > 0)
+	{
+		strcpy (commandLine, "cmd.exe /c ");
+		strcat (commandLine, word_eol[2]);
+
+		CreatePipe(&readPipe,&writePipe,&secattr,0);
+
+		
+		ZeroMemory(&sInfo,sizeof(sInfo));
+		ZeroMemory(&pInfo,sizeof(pInfo));
+		sInfo.cb=sizeof(sInfo);
+		sInfo.dwFlags=STARTF_USESTDHANDLES;
+		sInfo.hStdInput=NULL; 
+		sInfo.hStdOutput=writePipe; 
+		sInfo.hStdError=writePipe;
+
+		CreateProcess(0, commandLine, 0, 0, TRUE, NORMAL_PRIORITY_CLASS|CREATE_NO_WINDOW, 0, 0, &sInfo, &pInfo);
+		CloseHandle(writePipe);
+
+		//now read the output pipe here.
+
+		//do
+		//{
+		//	res=ReadFile(readPipe,buf,100,&reDword,0);
+			//csTemp=buf;
+			//m_csOutput+=csTemp.Left(reDword);
+			//xchat_printf (ph, "%s", buf);
+			//strcpy(buf, "\0");
+			//fflush(buf);
+		//}while(res);
+		
+
+		while (PeekNamedPipe(readPipe, buff1, 1, &dwRead, &dwAvail, &tdwLeft))
+		{
+			if (dwRead)
+			{
+				if (ReadFile(readPipe, buff1, sizeof(buff1) - 1, &dwRead, NULL) && dwRead != 0 )
+				{
+				buff1[dwRead] = '\0';
+				//cout << buff1;
+				xchat_printf (ph, "%s\n", buff1);
+				//cout.flush();
+				//fflush(buff1);
+				//memset(&buff1[0], 0, sizeof(buff1));
+				strcpy (buff1, "");
+				}
+			}
+		}
+	}
+	
+	return XCHAT_EAT_ALL;
+
+}*/
+
+static void
+run_command (char *word[], char *word_eol[], void *userdata)
+{
+	return XCHAT_EAT_ALL;
+}
+
+
+
+
+
+
+
+
+/*static void
+run_command (char *word[], char *word_eol[], void *userdata)
+{
+	STARTUPINFO si;
+	PROCESS_INFORMATION pi;
+	char commandLine[1024];
+	HANDLE pipeWriter;
+	HANDLE pipeReader;
+
+	char buff1[128];
+	DWORD dwRead,tdwRead,tdwAfail,tdwLeft, dwAvail, ctr = 0;
+	
+	//CreatePipe (&pipeReader, &pipeWriter, NULL, NULL);
+
+	ZeroMemory (&si, sizeof (si));
+	si.cb = sizeof (si);
+	ZeroMemory (&pi, sizeof (pi));
+	si.hStdOutput = pipeWriter;
+	
+	strcpy (commandLine, "cmd.exe /c ");
+	strcat (commandLine, word_eol[2]);
+
+	if (!CreateProcess ( NULL, commandLine, NULL, NULL, FALSE, 0, NULL, NULL, &si, &pi))
+	{
+		xchat_print (ph, "Error launching the Command Line!");
+	}
+
+	while (PeekNamedPipe(pipeReader, buff1, 1, &dwRead, &dwAvail, &tdwLeft)) {
+		if (dwRead)
+		{
+			if (ReadFile(pipeReader, buff1, sizeof(buff1) - 1, &dwRead, NULL) && dwRead != 0 )
+			{
+				buff1[dwRead] = '\0';
+				xchat_printf (ph, "%s\n", buff1);
+				//cout.flush();
+			}
+		}
+		else
+		{
+			sprintf(buff1, "No data loop count = %d. Do something here\n", ++ctr);
+			xchat_printf (ph, "%s\n", buff1);
+			//cout.flush();
+			SleepEx(1000, FALSE);
+		}
+	}
+
+	CloseHandle (pipeWriter);
+	CloseHandle (pipeReader);
+	CloseHandle (pi.hProcess);
+	CloseHandle (pi.hThread);
+}*/
+
+int
+xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugin_desc, char **plugin_version, char *arg)
+{
+	ph = plugin_handle;
+
+	*plugin_name = "Exec";
+	*plugin_desc = "Execute commands inside XChat";
+	*plugin_version = "1.0";
+
+	xchat_hook_command (ph, "EXEC", XCHAT_PRI_NORM, run_command, 0, 0);
+	xchat_printf (ph, "Exec plugin loaded\n");
+
+	return 1;       /* return 1 for success */
+}
+
+int
+xchat_plugin_deinit (void)
+{
+	xchat_print (ph, "Exec plugin unloaded\n");
+	return 1;
+}
diff --git a/plugins/exec/makefile.mak b/plugins/exec/makefile.mak
new file mode 100644
index 00000000..d2153faf
--- /dev/null
+++ b/plugins/exec/makefile.mak
@@ -0,0 +1,18 @@
+include "..\..\src\makeinc.mak"
+
+all: exec.obj exec.def
+	link $(LDFLAGS) $(LIBS) /dll /out:xcexec.dll /def:exec.def exec.obj
+
+exec.def:
+	echo EXPORTS > exec.def
+	echo xchat_plugin_init >> exec.def
+	echo xchat_plugin_deinit >> exec.def
+
+exec.obj: exec.c makefile.mak
+	cl $(CFLAGS) $(GLIB) /I.. exec.c
+
+clean:
+	del *.obj
+	del *.dll
+	del *.exp
+	del *.lib
-- 
cgit 1.4.1


From 76a8166320d66ddcea3d0ef7209e5877d7a5ef7d Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sun, 27 Nov 2011 07:31:46 +0100
Subject: exec support for releaser and makefile

---
 build/release-x64.bat | 1 +
 build/release-x86.bat | 1 +
 plugins/makefile.mak  | 4 ++++
 3 files changed, 6 insertions(+)

(limited to 'plugins')

diff --git a/build/release-x64.bat b/build/release-x64.bat
index 33bd235f..4bd8905a 100644
--- a/build/release-x64.bat
+++ b/build/release-x64.bat
@@ -48,6 +48,7 @@ copy %DEPS_ROOT%\bin\libenchant.dll %XCHAT_DEST%
 xcopy /q /s /i %DEPS_ROOT%\lib\enchant\libenchant_myspell.dll %XCHAT_DEST%\lib\enchant\
 xcopy /q /s /i ..\plugins\checksum\xcchecksum.dll %XCHAT_DEST%\plugins\
 copy ..\plugins\doat\xcdoat.dll %XCHAT_DEST%\plugins
+copy ..\plugins\exec\xcexec.dll %XCHAT_DEST%\plugins
 copy ..\plugins\fishlim\xcfishlim.dll %XCHAT_DEST%\plugins
 copy ..\plugins\lua\xclua.dll %XCHAT_DEST%\plugins
 ::copy ..\plugins\gtkpref\xcgtkpref.dll %XCHAT_DEST%\plugins
diff --git a/build/release-x86.bat b/build/release-x86.bat
index 9bc21126..96dedac1 100644
--- a/build/release-x86.bat
+++ b/build/release-x86.bat
@@ -48,6 +48,7 @@ copy %DEPS_ROOT%\bin\libenchant.dll %XCHAT_DEST%
 xcopy /q /s /i %DEPS_ROOT%\lib\enchant\libenchant_myspell.dll %XCHAT_DEST%\lib\enchant\
 xcopy /q /s /i ..\plugins\checksum\xcchecksum.dll %XCHAT_DEST%\plugins\
 copy ..\plugins\doat\xcdoat.dll %XCHAT_DEST%\plugins
+copy ..\plugins\exec\xcexec.dll %XCHAT_DEST%\plugins
 copy ..\plugins\fishlim\xcfishlim.dll %XCHAT_DEST%\plugins
 copy ..\plugins\lua\xclua.dll %XCHAT_DEST%\plugins
 ::copy ..\plugins\gtkpref\xcgtkpref.dll %XCHAT_DEST%\plugins
diff --git a/plugins/makefile.mak b/plugins/makefile.mak
index a308cae3..c767dd0d 100644
--- a/plugins/makefile.mak
+++ b/plugins/makefile.mak
@@ -5,6 +5,8 @@ all:
 #	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\doat
 	@-$(MAKE) /nologo /s /f makefile.mak $@
+	@cd ..\exec
+	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\fishlim
 	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\lua
@@ -31,6 +33,8 @@ clean:
 #	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\doat
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
+	@cd ..\exec
+	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\fishlim
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\lua
-- 
cgit 1.4.1


From 5d50ec01cb03122cdabb5fd2dace903e50c565e8 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sun, 27 Nov 2011 08:53:17 +0100
Subject: exec cleanup

---
 plugins/exec/exec.c | 161 ++++++++++++++--------------------------------------
 1 file changed, 42 insertions(+), 119 deletions(-)

(limited to 'plugins')

diff --git a/plugins/exec/exec.c b/plugins/exec/exec.c
index 1c8f5a06..71adf15c 100644
--- a/plugins/exec/exec.c
+++ b/plugins/exec/exec.c
@@ -25,154 +25,77 @@
  */
 
 #include <windows.h>
+#include <time.h>
 
 #include "xchat-plugin.h"
 
 static xchat_plugin *ph;   /* plugin handle */
 
-
-
-
-
-
-/*static void
+static int
 run_command (char *word[], char *word_eol[], void *userdata)
 {
 	char commandLine[1024];
-	char buf[100];
-	char buff1[256];
-	DWORD dwRead,tdwRead,tdwAfail,tdwLeft, dwAvail, ctr = 0;
-
-	HANDLE readPipe, writePipe;
+	char buffer[4096];
+	DWORD dwRead = 0;
+	DWORD dwLeft = 0;
+	DWORD dwAvail = 0;
+	time_t start;
+	double timeElapsed;
+
+	HANDLE readPipe;
+	HANDLE writePipe;
 	STARTUPINFO sInfo; 
 	PROCESS_INFORMATION pInfo; 
-	BOOL res;	
-	DWORD reDword; 
-
 	SECURITY_ATTRIBUTES secattr; 
-	ZeroMemory(&secattr,sizeof(secattr));
-	secattr.nLength = sizeof(secattr);
+
+	ZeroMemory (&secattr, sizeof (secattr));
+	secattr.nLength = sizeof (secattr);
 	secattr.bInheritHandle = TRUE;
-	
-	xchat_printf (ph, "%d", strlen(word[2]));
+
 	if (strlen (word[2]) > 0)
 	{
 		strcpy (commandLine, "cmd.exe /c ");
 		strcat (commandLine, word_eol[2]);
 
-		CreatePipe(&readPipe,&writePipe,&secattr,0);
-
-		
-		ZeroMemory(&sInfo,sizeof(sInfo));
-		ZeroMemory(&pInfo,sizeof(pInfo));
-		sInfo.cb=sizeof(sInfo);
-		sInfo.dwFlags=STARTF_USESTDHANDLES;
-		sInfo.hStdInput=NULL; 
-		sInfo.hStdOutput=writePipe; 
-		sInfo.hStdError=writePipe;
-
-		CreateProcess(0, commandLine, 0, 0, TRUE, NORMAL_PRIORITY_CLASS|CREATE_NO_WINDOW, 0, 0, &sInfo, &pInfo);
-		CloseHandle(writePipe);
-
-		//now read the output pipe here.
-
-		//do
-		//{
-		//	res=ReadFile(readPipe,buf,100,&reDword,0);
-			//csTemp=buf;
-			//m_csOutput+=csTemp.Left(reDword);
-			//xchat_printf (ph, "%s", buf);
-			//strcpy(buf, "\0");
-			//fflush(buf);
-		//}while(res);
-		
-
-		while (PeekNamedPipe(readPipe, buff1, 1, &dwRead, &dwAvail, &tdwLeft))
+		CreatePipe (&readPipe, &writePipe, &secattr, 0);
+
+		ZeroMemory (&sInfo, sizeof (sInfo));
+		ZeroMemory (&pInfo, sizeof (pInfo));
+		sInfo.cb = sizeof (sInfo);
+		sInfo.dwFlags = STARTF_USESTDHANDLES;
+		sInfo.hStdInput = NULL;
+		sInfo.hStdOutput = writePipe;
+		sInfo.hStdError = writePipe;
+
+		CreateProcess (0, commandLine, 0, 0, TRUE, NORMAL_PRIORITY_CLASS|CREATE_NO_WINDOW, 0, 0, &sInfo, &pInfo);
+		CloseHandle (writePipe);
+
+		start = time (0);
+		while (PeekNamedPipe (readPipe, buffer, 1, &dwRead, &dwAvail, &dwLeft) && timeElapsed < 10)
 		{
 			if (dwRead)
 			{
-				if (ReadFile(readPipe, buff1, sizeof(buff1) - 1, &dwRead, NULL) && dwRead != 0 )
+				if (ReadFile (readPipe, buffer, sizeof (buffer) - 1, &dwRead, NULL) && dwRead != 0 )
 				{
-				buff1[dwRead] = '\0';
-				//cout << buff1;
-				xchat_printf (ph, "%s\n", buff1);
-				//cout.flush();
-				//fflush(buff1);
-				//memset(&buff1[0], 0, sizeof(buff1));
-				strcpy (buff1, "");
+					buffer[dwRead] = '\0';
+					xchat_printf (ph, "%s\n", buffer);
 				}
 			}
+			timeElapsed = difftime (time (0), start);
 		}
 	}
 	
-	return XCHAT_EAT_ALL;
-
-}*/
-
-static void
-run_command (char *word[], char *word_eol[], void *userdata)
-{
-	return XCHAT_EAT_ALL;
-}
-
-
-
-
-
-
-
-
-/*static void
-run_command (char *word[], char *word_eol[], void *userdata)
-{
-	STARTUPINFO si;
-	PROCESS_INFORMATION pi;
-	char commandLine[1024];
-	HANDLE pipeWriter;
-	HANDLE pipeReader;
-
-	char buff1[128];
-	DWORD dwRead,tdwRead,tdwAfail,tdwLeft, dwAvail, ctr = 0;
-	
-	//CreatePipe (&pipeReader, &pipeWriter, NULL, NULL);
-
-	ZeroMemory (&si, sizeof (si));
-	si.cb = sizeof (si);
-	ZeroMemory (&pi, sizeof (pi));
-	si.hStdOutput = pipeWriter;
-	
-	strcpy (commandLine, "cmd.exe /c ");
-	strcat (commandLine, word_eol[2]);
-
-	if (!CreateProcess ( NULL, commandLine, NULL, NULL, FALSE, 0, NULL, NULL, &si, &pi))
+	if (timeElapsed >= 10)
 	{
-		xchat_print (ph, "Error launching the Command Line!");
+		xchat_printf (ph, "Execution took too long, aborting.\n");
 	}
 
-	while (PeekNamedPipe(pipeReader, buff1, 1, &dwRead, &dwAvail, &tdwLeft)) {
-		if (dwRead)
-		{
-			if (ReadFile(pipeReader, buff1, sizeof(buff1) - 1, &dwRead, NULL) && dwRead != 0 )
-			{
-				buff1[dwRead] = '\0';
-				xchat_printf (ph, "%s\n", buff1);
-				//cout.flush();
-			}
-		}
-		else
-		{
-			sprintf(buff1, "No data loop count = %d. Do something here\n", ++ctr);
-			xchat_printf (ph, "%s\n", buff1);
-			//cout.flush();
-			SleepEx(1000, FALSE);
-		}
-	}
+	CloseHandle (readPipe);
+	CloseHandle (pInfo.hProcess);
+	CloseHandle (pInfo.hThread);
 
-	CloseHandle (pipeWriter);
-	CloseHandle (pipeReader);
-	CloseHandle (pi.hProcess);
-	CloseHandle (pi.hThread);
-}*/
+	return XCHAT_EAT_XCHAT;
+}
 
 int
 xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugin_desc, char **plugin_version, char *arg)
@@ -184,7 +107,7 @@ xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugi
 	*plugin_version = "1.0";
 
 	xchat_hook_command (ph, "EXEC", XCHAT_PRI_NORM, run_command, 0, 0);
-	xchat_printf (ph, "Exec plugin loaded\n");
+	xchat_printf (ph, "%s plugin loaded\n", *plugin_name);
 
 	return 1;       /* return 1 for success */
 }
-- 
cgit 1.4.1


From 837557e9c73b0b266d06bdf2ca7428ecdbc9f35c Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sun, 27 Nov 2011 11:05:38 +0100
Subject: make exec display as nice as possible

---
 plugins/exec/exec.c | 14 ++++++++++----
 1 file changed, 10 insertions(+), 4 deletions(-)

(limited to 'plugins')

diff --git a/plugins/exec/exec.c b/plugins/exec/exec.c
index 71adf15c..9d400e10 100644
--- a/plugins/exec/exec.c
+++ b/plugins/exec/exec.c
@@ -57,7 +57,7 @@ run_command (char *word[], char *word_eol[], void *userdata)
 		strcpy (commandLine, "cmd.exe /c ");
 		strcat (commandLine, word_eol[2]);
 
-		CreatePipe (&readPipe, &writePipe, &secattr, 0);
+		CreatePipe (&readPipe, &writePipe, &secattr, 0); /* might be replaced with MyCreatePipeEx */
 
 		ZeroMemory (&sInfo, sizeof (sInfo));
 		ZeroMemory (&pInfo, sizeof (pInfo));
@@ -67,7 +67,7 @@ run_command (char *word[], char *word_eol[], void *userdata)
 		sInfo.hStdOutput = writePipe;
 		sInfo.hStdError = writePipe;
 
-		CreateProcess (0, commandLine, 0, 0, TRUE, NORMAL_PRIORITY_CLASS|CREATE_NO_WINDOW, 0, 0, &sInfo, &pInfo);
+		CreateProcess (0, commandLine, 0, 0, TRUE, NORMAL_PRIORITY_CLASS | CREATE_NO_WINDOW, 0, 0, &sInfo, &pInfo);
 		CloseHandle (writePipe);
 
 		start = time (0);
@@ -77,17 +77,23 @@ run_command (char *word[], char *word_eol[], void *userdata)
 			{
 				if (ReadFile (readPipe, buffer, sizeof (buffer) - 1, &dwRead, NULL) && dwRead != 0 )
 				{
+					/* avoid garbage */
 					buffer[dwRead] = '\0';
-					xchat_printf (ph, "%s\n", buffer);
+					xchat_printf (ph, "%s", buffer);
 				}
 			}
+			else
+			{
+				/* this way we'll more likely get full lines */
+				SleepEx (100, TRUE);
+			}
 			timeElapsed = difftime (time (0), start);
 		}
 	}
 	
 	if (timeElapsed >= 10)
 	{
-		xchat_printf (ph, "Execution took too long, aborting.\n");
+		xchat_printf (ph, "Command took too much time to run, execution aborted.\n");
 	}
 
 	CloseHandle (readPipe);
-- 
cgit 1.4.1


From d5dd1d3307038932be89e67840f29f5012cd46d4 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sun, 27 Nov 2011 11:15:40 +0100
Subject: some formatting for exec

---
 plugins/exec/exec.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/exec/exec.c b/plugins/exec/exec.c
index 9d400e10..9571faad 100644
--- a/plugins/exec/exec.c
+++ b/plugins/exec/exec.c
@@ -90,7 +90,10 @@ run_command (char *word[], char *word_eol[], void *userdata)
 			timeElapsed = difftime (time (0), start);
 		}
 	}
-	
+
+	/* display a newline to separate things */
+	xchat_printf (ph, "\n");
+
 	if (timeElapsed >= 10)
 	{
 		xchat_printf (ph, "Command took too much time to run, execution aborted.\n");
-- 
cgit 1.4.1


From cc0726d83a2f5eaba42dcd0ed02e0f1f91d6b264 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sun, 27 Nov 2011 11:17:22 +0100
Subject: fix the update checker, return correctly with callback

---
 plugins/upd/upd.c | 13 +++++++++----
 1 file changed, 9 insertions(+), 4 deletions(-)

(limited to 'plugins')

diff --git a/plugins/upd/upd.c b/plugins/upd/upd.c
index b4fa5704..a6ece301 100644
--- a/plugins/upd/upd.c
+++ b/plugins/upd/upd.c
@@ -31,6 +31,9 @@
 
 static xchat_plugin *ph;   /* plugin handle */
 
+/* we need this to store the result of the initial update check since the return value is preserved for XCHAT_EAT */
+static int update_available;
+
 static char*
 check_version ()
 {
@@ -73,12 +76,12 @@ print_version ()
 	if (strcmp (version, xchat_get_info (ph, "wdk_version")) == 0)
 	{
 		xchat_printf (ph, "You have the latest version of XChat-WDK installed!\n");
-		return 0;
+		update_available = 0;
 	}
 	else if (strcmp (version, "Unknown") == 0)
 	{
 		xchat_printf (ph, "Unable to check for XChat-WDK updates!\n");
-		return 0;
+		update_available = 0;
 	}
 	else
 	{
@@ -87,8 +90,10 @@ print_version ()
 #else
 		xchat_printf (ph, "An XChat-WDK update is available! You can download it from here:\nhttp://xchat-wdk.googlecode.com/files/XChat-WDK%%20%s%%20x86.exe\n", version);
 #endif
-		return 1;
+		update_available = 1;
 	}
+
+	return XCHAT_EAT_XCHAT;
 }
 
 static int
@@ -126,7 +131,7 @@ xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugi
 	xchat_printf (ph, "%s plugin loaded\n", *plugin_name);
 
 	/* only start the timer if there's no update available during startup */
-	if (!print_version ())
+	if (!update_available)
 	{
 		/* check for updates every 6 hours */
 		xchat_hook_timer (ph, 21600000, print_version_quiet, NULL);
-- 
cgit 1.4.1


From eaad8edbee8b7110ae7a885421db4df97cc244cc Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sun, 27 Nov 2011 19:38:37 +0100
Subject: initial version of winsys sysinfo plugin

---
 build/release-x64.bat        |   1 +
 build/release-x86.bat        |   1 +
 build/xchat-wdk-x64.skel.iss |   2 +
 build/xchat-wdk-x86.skel.iss |   2 +
 plugins/makefile.mak         |   4 +
 plugins/winsys/makefile.mak  |  18 +++
 plugins/winsys/winsys.c      | 329 +++++++++++++++++++++++++++++++++++++++++++
 7 files changed, 357 insertions(+)
 create mode 100644 plugins/winsys/makefile.mak
 create mode 100644 plugins/winsys/winsys.c

(limited to 'plugins')

diff --git a/build/release-x64.bat b/build/release-x64.bat
index 4bd8905a..871fef80 100644
--- a/build/release-x64.bat
+++ b/build/release-x64.bat
@@ -60,6 +60,7 @@ copy ..\plugins\tcl\xctcl.dll %XCHAT_DEST%\plugins
 copy ..\plugins\upd\xcupd.dll %XCHAT_DEST%\plugins
 copy ..\plugins\xtray\xtray.dll %XCHAT_DEST%\plugins
 copy ..\plugins\winamp\xcwinamp.dll %XCHAT_DEST%\plugins
+copy ..\plugins\winsys\xcwinsys.dll %XCHAT_DEST%\plugins
 copy ..\plugins\wmpa\xcwmpa.dll %XCHAT_DEST%\plugins
 copy %DEPS_ROOT%\bin\lua51.dll %XCHAT_DEST%
 xcopy /q /s /i ..\po\locale %XCHAT_DEST%\locale
diff --git a/build/release-x86.bat b/build/release-x86.bat
index 96dedac1..d6d8589b 100644
--- a/build/release-x86.bat
+++ b/build/release-x86.bat
@@ -60,6 +60,7 @@ copy ..\plugins\tcl\xctcl.dll %XCHAT_DEST%\plugins
 copy ..\plugins\upd\xcupd.dll %XCHAT_DEST%\plugins
 copy ..\plugins\xtray\xtray.dll %XCHAT_DEST%\plugins
 copy ..\plugins\winamp\xcwinamp.dll %XCHAT_DEST%\plugins
+copy ..\plugins\winsys\xcwinsys.dll %XCHAT_DEST%\plugins
 copy ..\plugins\wmpa\xcwmpa.dll %XCHAT_DEST%\plugins
 copy %DEPS_ROOT%\bin\lua51.dll %XCHAT_DEST%
 xcopy /q /s /i ..\po\locale %XCHAT_DEST%\locale
diff --git a/build/xchat-wdk-x64.skel.iss b/build/xchat-wdk-x64.skel.iss
index 7b6c5302..ff325d79 100644
--- a/build/xchat-wdk-x64.skel.iss
+++ b/build/xchat-wdk-x64.skel.iss
@@ -40,6 +40,7 @@ Name: "plugins\fishlim"; Description: "FiSHLiM"; Types: full custom; Flags: disa
 Name: "plugins\mpcinfo"; Description: "mpcInfo"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\upd"; Description: "Update Checker"; Types: normal full custom; Flags: disablenouninstallwarning
 Name: "plugins\winamp"; Description: "Winamp"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\winsys"; Description: "WinSys"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\wmpa"; Description: "Windows Media Player Announcer"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\xtray"; Description: "X-Tray"; Types: full custom; Flags: disablenouninstallwarning
 Name: "langs"; Description: "Language Interfaces"; Types: full custom; Flags: disablenouninstallwarning
@@ -131,6 +132,7 @@ Source: "plugins\xcfishlim.dll"; DestDir: "{app}\plugins"; Components: plugins\f
 Source: "plugins\xcmpcinfo.dll"; DestDir: "{app}\plugins"; Components: plugins\mpcinfo
 Source: "plugins\xcupd.dll"; DestDir: "{app}\plugins"; Components: plugins\upd
 Source: "plugins\xcwinamp.dll"; DestDir: "{app}\plugins"; Components: plugins\winamp
+Source: "plugins\xcwinsys.dll"; DestDir: "{app}\plugins"; Components: plugins\winsys
 Source: "plugins\xtray.dll"; DestDir: "{app}\plugins"; Components: plugins\xtray
 Source: "plugins\xcwmpa.dll"; DestDir: "{app}\plugins"; Components: plugins\wmpa
 
diff --git a/build/xchat-wdk-x86.skel.iss b/build/xchat-wdk-x86.skel.iss
index 14d5ae21..8a99ebfe 100644
--- a/build/xchat-wdk-x86.skel.iss
+++ b/build/xchat-wdk-x86.skel.iss
@@ -39,6 +39,7 @@ Name: "plugins\fishlim"; Description: "FiSHLiM"; Types: full custom; Flags: disa
 Name: "plugins\mpcinfo"; Description: "mpcInfo"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\upd"; Description: "Update Checker"; Types: normal full custom; Flags: disablenouninstallwarning
 Name: "plugins\winamp"; Description: "Winamp"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\winsys"; Description: "WinSys"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\wmpa"; Description: "Windows Media Player Announcer"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\xtray"; Description: "X-Tray"; Types: full custom; Flags: disablenouninstallwarning
 Name: "langs"; Description: "Language Interfaces"; Types: full custom; Flags: disablenouninstallwarning
@@ -130,6 +131,7 @@ Source: "plugins\xcfishlim.dll"; DestDir: "{app}\plugins"; Components: plugins\f
 Source: "plugins\xcmpcinfo.dll"; DestDir: "{app}\plugins"; Components: plugins\mpcinfo
 Source: "plugins\xcupd.dll"; DestDir: "{app}\plugins"; Components: plugins\upd
 Source: "plugins\xcwinamp.dll"; DestDir: "{app}\plugins"; Components: plugins\winamp
+Source: "plugins\xcwinsys.dll"; DestDir: "{app}\plugins"; Components: plugins\winsys
 Source: "plugins\xtray.dll"; DestDir: "{app}\plugins"; Components: plugins\xtray
 Source: "plugins\xcwmpa.dll"; DestDir: "{app}\plugins"; Components: plugins\wmpa
 
diff --git a/plugins/makefile.mak b/plugins/makefile.mak
index c767dd0d..b63e2e54 100644
--- a/plugins/makefile.mak
+++ b/plugins/makefile.mak
@@ -22,6 +22,8 @@ all:
 	@cd ..\xtray
 	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\winamp
+	@-$(MAKE) /nologo /s /f makefile.mak $@
+	@cd ..\winsys
 	@-$(MAKE) /nologo /s /f makefile.mak $@	
 	@cd ..\wmpa
 	@-$(MAKE) /nologo /s /f makefile.mak $@
@@ -51,5 +53,7 @@ clean:
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\winamp
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
+	@cd ..\winsys
+	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\wmpa
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
diff --git a/plugins/winsys/makefile.mak b/plugins/winsys/makefile.mak
new file mode 100644
index 00000000..5d125ab7
--- /dev/null
+++ b/plugins/winsys/makefile.mak
@@ -0,0 +1,18 @@
+include "..\..\src\makeinc.mak"
+
+all: winsys.obj winsys.def
+	link $(LDFLAGS) $(LIBS) wbemuuid.lib /dll /out:xcwinsys.dll /def:winsys.def winsys.obj
+
+winsys.def:
+	echo EXPORTS > winsys.def
+	echo xchat_plugin_init >> winsys.def
+	echo xchat_plugin_deinit >> winsys.def
+
+winsys.obj: winsys.c makefile.mak
+	cl $(CFLAGS) $(GLIB) /I.. winsys.c
+
+clean:
+	del *.obj
+	del *.dll
+	del *.exp
+	del *.lib
diff --git a/plugins/winsys/winsys.c b/plugins/winsys/winsys.c
new file mode 100644
index 00000000..5ec462c8
--- /dev/null
+++ b/plugins/winsys/winsys.c
@@ -0,0 +1,329 @@
+/* XChat-WDK
+ * Copyright (c) 2011 Berke Viktor.
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in
+ * all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+ * THE SOFTWARE.
+ */
+
+#define _WIN32_DCOM
+#include <stdio.h>
+#include <windows.h>
+#include <intrin.h>
+#include <comdef.h>
+#include <Wbemidl.h>
+
+#include "xchat-plugin.h"
+
+static xchat_plugin *ph;   /* plugin handle */
+
+static char *
+getOsName (void)
+{
+	static char winver[32];
+	double mhz;
+	OSVERSIONINFOEX osvi;
+	SYSTEM_INFO si;
+
+	osvi.dwOSVersionInfoSize = sizeof (OSVERSIONINFOEX);
+	GetVersionEx ((LPOSVERSIONINFOW)&osvi);
+
+	GetSystemInfo (&si);
+
+	strcpy (winver, "Windows ");
+
+	switch (osvi.dwMajorVersion)
+	{
+		case 5:
+			switch (osvi.dwMinorVersion)
+			{
+				case 1:
+					strcat (winver, "XP");
+					break;
+				case 2:
+					if (osvi.wProductType == VER_NT_WORKSTATION)
+					{
+						strcat (winver, "XP x64 Edition");
+					}
+					else
+					{
+						if (GetSystemMetrics(SM_SERVERR2) == 0)
+						{
+							strcat (winver, "Server 2003");
+						}
+						else
+						{
+							strcat (winver, "Server 2003 R2");
+						}
+					}
+					break;
+			}
+			break;
+		case 6:
+			switch (osvi.dwMinorVersion)
+			{
+				case 0:
+					if (osvi.wProductType == VER_NT_WORKSTATION)
+					{
+						strcat (winver, "Vista");
+					}
+					else
+					{
+						strcat (winver, "Server 2008");
+					}
+					break;
+				case 1:
+					if (osvi.wProductType == VER_NT_WORKSTATION)
+					{
+						strcat (winver, "7");
+					}
+					else
+					{
+						strcat (winver, "Server 2008 R2");
+					}
+					break;
+				case 2:
+					if (osvi.wProductType == VER_NT_WORKSTATION)
+					{
+						strcat (winver, "8");
+					}
+					else
+					{
+						strcat (winver, "8 Server");
+					}
+					break;
+			}
+			break;
+	}
+
+	if (si.wProcessorArchitecture == 9)
+	{
+		strcat (winver, " (x64)");
+	}
+	else
+	{
+		strcat (winver, " (x86)");
+	}
+
+	return winver;
+}
+
+static char*
+getCpuName (void)
+{
+	// Get extended ids.
+	unsigned int nExIds;
+	unsigned int i;
+	int CPUInfo[4] = {-1};
+	static char CPUBrandString[128];
+
+	__cpuid (CPUInfo, 0x80000000);
+	nExIds = CPUInfo[0];
+
+	/* Get the information associated with each extended ID. */
+	for (i=0x80000000; i <= nExIds; ++i)
+	{
+		__cpuid (CPUInfo, i);
+
+		if (i == 0x80000002)
+		{
+			memcpy (CPUBrandString, CPUInfo, sizeof (CPUInfo));
+		}
+		else if (i == 0x80000003)
+		{
+			memcpy( CPUBrandString + 16, CPUInfo, sizeof (CPUInfo));
+		}
+		else if (i == 0x80000004)
+		{
+			memcpy (CPUBrandString + 32, CPUInfo, sizeof (CPUInfo));
+		}
+	}
+
+	return CPUBrandString;
+}
+
+static char*
+getCpuMhz (void)
+{
+	HKEY hKey;
+	int result;
+	int data;
+	int dataSize;
+	double cpuspeed;
+	static char buffer[16];
+	const char *cpuspeedstr;
+
+	if (RegOpenKeyEx (HKEY_LOCAL_MACHINE, TEXT("Hardware\\Description\\System\\CentralProcessor\\0"), 0, KEY_QUERY_VALUE, &hKey) == ERROR_SUCCESS)
+	{
+		dataSize = sizeof (data);
+		result = RegQueryValueEx (hKey, TEXT("~MHz"), 0, 0, (LPBYTE)&data, (LPDWORD)&dataSize);
+		RegCloseKey (hKey);
+		if (result == ERROR_SUCCESS)
+		{
+			cpuspeed = ( data > 1000 ) ? data / 1000 : data;
+			cpuspeedstr = ( data > 1000 ) ? "GHz" : "MHz";
+			sprintf (buffer, "%.2f %s", cpuspeed, cpuspeedstr);
+		}
+	}
+
+	return buffer;
+}
+
+static char*
+getMemoryInfo (void)
+{
+	static char buffer[16];
+	MEMORYSTATUSEX meminfo;
+
+	meminfo.dwLength = sizeof (meminfo);
+	GlobalMemoryStatusEx (&meminfo);
+
+	sprintf (buffer, "%I64d MB Total (%I64d MB Free)", meminfo.ullTotalPhys/1024/1024, meminfo.ullAvailPhys/1024/1024);
+
+	return buffer;
+}
+
+static char*
+getVgaName (void)
+{
+	/* for more details about this wonderful API, see 
+	http://msdn.microsoft.com/en-us/site/aa394138
+	http://msdn.microsoft.com/en-us/site/aa390423
+	http://msdn.microsoft.com/en-us/library/windows/desktop/aa394138%28v=vs.85%29.aspx
+	http://social.msdn.microsoft.com/forums/en-US/vcgeneral/thread/d6420012-e432-4964-8506-6f6b65e5a451
+	*/
+
+	char buffer[128];
+	HRESULT hres;
+	HRESULT hr;
+	IWbemLocator *pLoc = NULL;
+	IWbemServices *pSvc = NULL;
+	IEnumWbemClassObject *pEnumerator = NULL;
+	IWbemClassObject *pclsObj;
+	ULONG uReturn = 0;
+
+	strcpy (buffer, "Unknown");
+	hres =  CoInitializeEx (0, COINIT_MULTITHREADED);
+
+	if (FAILED (hres))
+	{
+		return buffer;
+	}
+
+	hres =  CoInitializeSecurity (NULL, -1, NULL, NULL, RPC_C_AUTHN_LEVEL_DEFAULT, RPC_C_IMP_LEVEL_IMPERSONATE, NULL, EOAC_NONE, NULL);
+
+	if (FAILED (hres))
+	{
+		CoUninitialize ();
+		return buffer;
+	}
+
+	hres = CoCreateInstance (CLSID_WbemLocator, 0, CLSCTX_INPROC_SERVER, IID_IWbemLocator, (LPVOID *) &pLoc);
+
+	if (FAILED (hres))
+	{
+		CoUninitialize ();
+		return buffer;
+	}
+
+	hres = pLoc->ConnectServer (_bstr_t (L"root\\CIMV2"), NULL, NULL, 0, NULL, 0, 0, &pSvc);
+
+	if (FAILED (hres))
+	{
+		pLoc->Release ();
+		CoUninitialize ();
+		return buffer;
+	}
+
+	hres = CoSetProxyBlanket (pSvc, RPC_C_AUTHN_WINNT, RPC_C_AUTHZ_NONE, NULL, RPC_C_AUTHN_LEVEL_CALL, RPC_C_IMP_LEVEL_IMPERSONATE, NULL, EOAC_NONE);
+
+	if (FAILED (hres))
+	{
+		pSvc->Release ();
+		pLoc->Release ();
+		CoUninitialize ();
+		return buffer;
+	}
+
+	hres = pSvc->ExecQuery (bstr_t ("WQL"), bstr_t ("SELECT * FROM Win32_VideoController"), WBEM_FLAG_FORWARD_ONLY | WBEM_FLAG_RETURN_IMMEDIATELY, NULL, &pEnumerator);
+
+	if (FAILED (hres))
+	{
+		pSvc->Release ();
+		pLoc->Release ();
+		CoUninitialize ();
+		return buffer;
+	}
+
+	while (pEnumerator)
+	{
+		hr = pEnumerator->Next (WBEM_INFINITE, 1, &pclsObj, &uReturn);
+		if (0 == uReturn)
+		{
+			break;
+		}
+		VARIANT vtProp;
+		hr = pclsObj->Get (L"Caption", 0, &vtProp, 0, 0);
+		WideCharToMultiByte (CP_ACP, 0, vtProp.bstrVal, -1, buffer, SysStringLen (vtProp.bstrVal)+1, NULL, NULL);
+		VariantClear (&vtProp);
+    }
+
+	pSvc->Release ();
+	pLoc->Release ();
+	pEnumerator->Release ();
+	pclsObj->Release ();
+	CoUninitialize ();
+
+	return buffer;
+}
+
+static int
+printInfo()
+{
+	xchat_printf (ph, "OS:\t%s\n", getOsName ());
+	xchat_printf (ph, "CPU:\t%s (%s)\n", getCpuName (), getCpuMhz ());
+	xchat_printf (ph, "RAM:\t%s\n", getMemoryInfo ());
+	xchat_printf (ph, "VGA:\t%s\n", getVgaName ());
+	/* will work correctly for up to 50 days, should be enough */
+	xchat_printf (ph, "Uptime:\t%.2f Hours\n", (float) GetTickCount() / 1000 / 60 / 60);
+	return XCHAT_EAT_XCHAT;
+}
+
+int
+xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugin_desc, char **plugin_version, char *arg)
+{
+	ph = plugin_handle;
+
+	*plugin_name = "WinSys";
+	*plugin_desc = "Display info about your hardware and OS";
+	*plugin_version = "1.0";
+
+	xchat_hook_command (ph, "WINSYS", XCHAT_PRI_NORM, printInfo, 0, 0);
+	xchat_command (ph, "MENU -ietc\\download.png ADD \"Window/Display System Info\" \"WINSYS\"");
+
+	xchat_printf (ph, "%s plugin loaded\n", *plugin_name);
+
+	return 1;       /* return 1 for success */
+}
+
+int
+xchat_plugin_deinit (void)
+{
+	xchat_command (ph, "MENU DEL \"Window/Display System Info\"");
+	xchat_print (ph, "WinSys plugin unloaded\n");
+	return 1;
+}
-- 
cgit 1.4.1


From 53c223dea44cd54fb6aca2de952da49a8105d1b0 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Mon, 28 Nov 2011 14:53:28 +0100
Subject: first piece of wdk fixes for winsys

---
 plugins/winsys/winsys.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/winsys/winsys.c b/plugins/winsys/winsys.c
index 5ec462c8..2a1e65ad 100644
--- a/plugins/winsys/winsys.c
+++ b/plugins/winsys/winsys.c
@@ -23,7 +23,9 @@
 #define _WIN32_DCOM
 #include <stdio.h>
 #include <windows.h>
-#include <intrin.h>
+/* use intrin.h for SDK builds
+#include <intrin.h> */
+#include <ntddk.h>
 #include <comdef.h>
 #include <Wbemidl.h>
 
-- 
cgit 1.4.1


From 71c1a46c32e99d2999dce5a5a44564c3bbab9ace Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Mon, 28 Nov 2011 17:51:38 +0100
Subject: installer support for obs and gtk engines, x64 support

---
 build/glibconfig-x64.h       | 225 +++++++++++++++++++++++++++++++++++++++++++
 build/release-x64.bat        |  18 ++--
 build/release-x86.bat        |  22 +++--
 build/xchat-wdk-x64.skel.iss |  38 ++++++--
 build/xchat-wdk-x86.skel.iss |  36 +++++--
 dep-x64/deps-x64.txt         |  50 ++++++----
 dep-x86/deps-x86.txt         |   3 +-
 plugins/makefile.mak         |  12 +--
 8 files changed, 348 insertions(+), 56 deletions(-)
 create mode 100644 build/glibconfig-x64.h

(limited to 'plugins')

diff --git a/build/glibconfig-x64.h b/build/glibconfig-x64.h
new file mode 100644
index 00000000..84a6e22b
--- /dev/null
+++ b/build/glibconfig-x64.h
@@ -0,0 +1,225 @@
+/* glibconfig.h
+ *
+ * This is a generated file.  Please modify 'configure.ac'
+ */
+
+#ifndef __G_LIBCONFIG_H__
+#define __G_LIBCONFIG_H__
+
+#include <glib/gmacros.h>
+
+#include <limits.h>
+#include <float.h>
+
+G_BEGIN_DECLS
+
+#define G_MINFLOAT	FLT_MIN
+#define G_MAXFLOAT	FLT_MAX
+#define G_MINDOUBLE	DBL_MIN
+#define G_MAXDOUBLE	DBL_MAX
+#define G_MINSHORT	SHRT_MIN
+#define G_MAXSHORT	SHRT_MAX
+#define G_MAXUSHORT	USHRT_MAX
+#define G_MININT	INT_MIN
+#define G_MAXINT	INT_MAX
+#define G_MAXUINT	UINT_MAX
+#define G_MINLONG	LONG_MIN
+#define G_MAXLONG	LONG_MAX
+#define G_MAXULONG	ULONG_MAX
+
+typedef signed char gint8;
+typedef unsigned char guint8;
+typedef signed short gint16;
+typedef unsigned short guint16;
+#define G_GINT16_MODIFIER "h"
+#define G_GINT16_FORMAT "hi"
+#define G_GUINT16_FORMAT "hu"
+typedef signed int gint32;
+typedef unsigned int guint32;
+#define G_GINT32_MODIFIER ""
+#define G_GINT32_FORMAT "i"
+#define G_GUINT32_FORMAT "u"
+#define G_HAVE_GINT64 1          /* deprecated, always true */
+
+G_GNUC_EXTENSION typedef signed long long gint64;
+G_GNUC_EXTENSION typedef unsigned long long guint64;
+
+#define G_GINT64_CONSTANT(val)	(G_GNUC_EXTENSION (val##LL))
+#define G_GUINT64_CONSTANT(val)	(G_GNUC_EXTENSION (val##ULL))
+#define G_GINT64_MODIFIER "I64"
+#define G_GINT64_FORMAT "I64i"
+#define G_GUINT64_FORMAT "I64u"
+
+#define GLIB_SIZEOF_VOID_P 8
+#define GLIB_SIZEOF_LONG   4
+#define GLIB_SIZEOF_SIZE_T 8
+
+typedef signed long long gssize;
+typedef unsigned long long gsize;
+#define G_GSIZE_MODIFIER "I64"
+#define G_GSSIZE_FORMAT "I64i"
+#define G_GSIZE_FORMAT "I64u"
+
+#define G_MAXSIZE	G_MAXUINT64
+#define G_MINSSIZE	G_MININT64
+#define G_MAXSSIZE	G_MAXINT64
+
+typedef gint64 goffset;
+#define G_MINOFFSET	G_MININT64
+#define G_MAXOFFSET	G_MAXINT64
+
+#define G_GOFFSET_MODIFIER      G_GINT64_MODIFIER
+#define G_GOFFSET_FORMAT        G_GINT64_FORMAT
+#define G_GOFFSET_CONSTANT(val) G_GINT64_CONSTANT(val)
+
+
+#define GPOINTER_TO_INT(p)	((gint)  (gint64) (p))
+#define GPOINTER_TO_UINT(p)	((guint) (guint64) (p))
+
+#define GINT_TO_POINTER(i)	((gpointer) (gint64) (i))
+#define GUINT_TO_POINTER(u)	((gpointer) (guint64) (u))
+
+typedef signed long long gintptr;
+typedef unsigned long long guintptr;
+
+#define G_GINTPTR_MODIFIER      "I64"
+#define G_GINTPTR_FORMAT        "I64i"
+#define G_GUINTPTR_FORMAT       "I64u"
+
+#ifdef NeXT /* @#%@! NeXTStep */
+# define g_ATEXIT(proc)	(!atexit (proc))
+#else
+# define g_ATEXIT(proc)	(atexit (proc))
+#endif
+
+#define g_memmove(dest,src,len) G_STMT_START { memmove ((dest), (src), (len)); } G_STMT_END
+
+#define GLIB_MAJOR_VERSION 2
+#define GLIB_MINOR_VERSION 30
+#define GLIB_MICRO_VERSION 2
+
+#define G_OS_WIN32
+#define G_PLATFORM_WIN32
+
+
+#define G_VA_COPY	va_copy
+
+#ifdef	__cplusplus
+#define	G_HAVE_INLINE	1
+#else	/* !__cplusplus */
+#ifndef _MSC_VER
+#define G_HAVE_INLINE 1
+#endif /* _MSC_VER */
+#define G_HAVE___INLINE 1
+#if !defined(_MSC_VER) && !defined(__DMC__)
+#define G_HAVE___INLINE__ 1
+#endif /* !_MSC_VER and !__DMC__ */
+#endif	/* !__cplusplus */
+
+#ifdef	__cplusplus
+#define G_CAN_INLINE	1
+#else	/* !__cplusplus */
+#define G_CAN_INLINE	1
+#endif
+
+#ifndef __cplusplus
+# define G_HAVE_ISO_VARARGS 1
+#endif
+
+/* gcc-2.95.x supports both gnu style and ISO varargs, but if -ansi
+ * is passed ISO vararg support is turned off, and there is no work
+ * around to turn it on, so we unconditionally turn it off.
+ */
+#if __GNUC__ == 2 && __GNUC_MINOR__ == 95
+#  undef G_HAVE_ISO_VARARGS
+#endif
+
+#define G_HAVE_GNUC_VARARGS 1
+#define G_HAVE_GROWING_STACK 0
+
+#if defined(__SUNPRO_C) && (__SUNPRO_C >= 0x590)
+#define G_GNUC_INTERNAL __attribute__((visibility("hidden")))
+#elif defined(__SUNPRO_C) && (__SUNPRO_C >= 0x550)
+#define G_GNUC_INTERNAL __hidden
+#elif defined (__GNUC__) && defined (G_HAVE_GNUC_VISIBILITY)
+#define G_GNUC_INTERNAL __attribute__((visibility("hidden")))
+#else
+#define G_GNUC_INTERNAL
+#endif
+
+#define G_THREADS_ENABLED
+#define G_THREADS_IMPL_WIN32
+typedef struct _GMutex* GStaticMutex;
+#define G_STATIC_MUTEX_INIT NULL
+#define g_static_mutex_get_mutex(mutex) \
+  (g_static_mutex_get_mutex_impl_shortcut (mutex))
+/* This represents a system thread as used by the implementation. An
+ * alien implementaion, as loaded by g_thread_init can only count on
+ * "sizeof (gpointer)" bytes to store their info. We however need more
+ * for some of our native implementations. */
+typedef union _GSystemThread GSystemThread;
+union _GSystemThread
+{
+  char   data[8];
+  double dummy_double;
+  void  *dummy_pointer;
+  long   dummy_long;
+};
+
+#define G_ATOMIC_OP_USE_GCC_BUILTINS 1
+
+#define GINT16_TO_LE(val)	((gint16) (val))
+#define GUINT16_TO_LE(val)	((guint16) (val))
+#define GINT16_TO_BE(val)	((gint16) GUINT16_SWAP_LE_BE (val))
+#define GUINT16_TO_BE(val)	(GUINT16_SWAP_LE_BE (val))
+#define GINT32_TO_LE(val)	((gint32) (val))
+#define GUINT32_TO_LE(val)	((guint32) (val))
+#define GINT32_TO_BE(val)	((gint32) GUINT32_SWAP_LE_BE (val))
+#define GUINT32_TO_BE(val)	(GUINT32_SWAP_LE_BE (val))
+#define GINT64_TO_LE(val)	((gint64) (val))
+#define GUINT64_TO_LE(val)	((guint64) (val))
+#define GINT64_TO_BE(val)	((gint64) GUINT64_SWAP_LE_BE (val))
+#define GUINT64_TO_BE(val)	(GUINT64_SWAP_LE_BE (val))
+#define GLONG_TO_LE(val)	((glong) GINT32_TO_LE (val))
+#define GULONG_TO_LE(val)	((gulong) GUINT32_TO_LE (val))
+#define GLONG_TO_BE(val)	((glong) GINT32_TO_BE (val))
+#define GULONG_TO_BE(val)	((gulong) GUINT32_TO_BE (val))
+#define GINT_TO_LE(val)		((gint) GINT32_TO_LE (val))
+#define GUINT_TO_LE(val)	((guint) GUINT32_TO_LE (val))
+#define GINT_TO_BE(val)		((gint) GINT32_TO_BE (val))
+#define GUINT_TO_BE(val)	((guint) GUINT32_TO_BE (val))
+#define GSIZE_TO_LE(val)	((gsize) GUINT64_TO_LE (val))
+#define GSSIZE_TO_LE(val)	((gssize) GINT64_TO_LE (val))
+#define GSIZE_TO_BE(val)	((gsize) GUINT64_TO_BE (val))
+#define GSSIZE_TO_BE(val)	((gssize) GINT64_TO_BE (val))
+#define G_BYTE_ORDER G_LITTLE_ENDIAN
+
+#define GLIB_SYSDEF_POLLIN =1
+#define GLIB_SYSDEF_POLLOUT =4
+#define GLIB_SYSDEF_POLLPRI =2
+#define GLIB_SYSDEF_POLLHUP =16
+#define GLIB_SYSDEF_POLLERR =8
+#define GLIB_SYSDEF_POLLNVAL =32
+
+#define G_MODULE_SUFFIX "dll"
+
+/* A GPid is an abstraction for a process "handle". It is *not* an
+ * abstraction for a process identifier in general. GPid is used in
+ * GLib only for descendant processes spawned with the g_spawn*
+ * functions. On POSIX there is no "process handle" concept as such,
+ * but on Windows a GPid is a handle to a process, a kind of pointer,
+ * not a process identifier.
+ */
+typedef void * GPid;
+
+#define GLIB_SYSDEF_AF_UNIX 1
+#define GLIB_SYSDEF_AF_INET 2
+#define GLIB_SYSDEF_AF_INET6 23
+
+#define GLIB_SYSDEF_MSG_OOB 1
+#define GLIB_SYSDEF_MSG_PEEK 2
+#define GLIB_SYSDEF_MSG_DONTROUTE 4
+
+G_END_DECLS
+
+#endif /* GLIBCONFIG_H */
diff --git a/build/release-x64.bat b/build/release-x64.bat
index 871fef80..4f60f256 100644
--- a/build/release-x64.bat
+++ b/build/release-x64.bat
@@ -7,10 +7,11 @@ echo 2> portable-mode
 move portable-mode %XCHAT_DEST%
 copy ..\src\fe-gtk\xchat.exe %XCHAT_DEST%
 copy ..\src\fe-text\xchat-text.exe %XCHAT_DEST%
-::copy ..\src\gtk2-prefs\gtk2-prefs.exe %XCHAT_DEST%
+copy ..\src\gtk2-prefs\gtk2-prefs.exe %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libatk-1.0-0.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libcairo-2.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libexpat-1.dll %XCHAT_DEST%
+copy %DEPS_ROOT%\bin\libffi-5.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libfontconfig-1.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libfreetype-6.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libgdk_pixbuf-2.0-0.dll %XCHAT_DEST%
@@ -22,16 +23,21 @@ copy %DEPS_ROOT%\bin\libgobject-2.0-0.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libgthread-2.0-0.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libgtk-win32-2.0-0.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libintl-8.dll %XCHAT_DEST%
+copy %DEPS_ROOT%\bin\libjasper-1.dll %XCHAT_DEST%
+copy %DEPS_ROOT%\bin\libjpeg-8.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libpango-1.0-0.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libpangocairo-1.0-0.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libpangoft2-1.0-0.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libpangowin32-1.0-0.dll %XCHAT_DEST%
-copy %DEPS_ROOT%\bin\libpng14-14.dll %XCHAT_DEST%
-copy %DEPS_ROOT%\bin\libxml2.dll %XCHAT_DEST%
+copy %DEPS_ROOT%\bin\libpixman-1-0.dll %XCHAT_DEST%
+copy %DEPS_ROOT%\bin\libpng15-15.dll %XCHAT_DEST%
+copy %DEPS_ROOT%\bin\libtiff-3.dll %XCHAT_DEST%
+copy %DEPS_ROOT%\bin\libxml2-2.dll %XCHAT_DEST%
 xcopy /q /s /i %DEPS_ROOT%\lib\gtk-2.0\2.10.0\engines %XCHAT_DEST%\lib\gtk-2.0\2.10.0\engines
 xcopy /q /s /i %DEPS_ROOT%\lib\gtk-2.0\modules\libgail.dll %XCHAT_DEST%\lib\gtk-2.0\modules\
 xcopy /q /s /i etc %XCHAT_DEST%\etc
 xcopy /q /s /i share %XCHAT_DEST%\share
+xcopy /q /s /i %DEPS_ROOT%\share\themes %XCHAT_DEST%\share\themes
 copy ..\COPYING %XCHAT_DEST%
 copy %DEPS_ROOT%\LICENSE.OPENSSL %XCHAT_DEST%
 copy %DEPS_ROOT%\LICENSE.ZLIB %XCHAT_DEST%
@@ -39,7 +45,7 @@ copy %DEPS_ROOT%\share\gettext\intl\COPYING.LIB-2.0 %XCHAT_DEST%\LICENSE.GTK
 copy %DEPS_ROOT%\share\gettext\intl\COPYING.LIB-2.1 %XCHAT_DEST%\LICENSE.CAIRO
 copy %DEPS_ROOT%\LICENSE.LUA %XCHAT_DEST%
 copy %DEPS_ROOT%\LICENSE.ENCHANT %XCHAT_DEST%
-copy %DEPS_ROOT%\LICENSE.LIBXML %XCHAT_DEST%
+copy %DEPS_ROOT%\share\doc\libxml2-2.7.8\Copyright %XCHAT_DEST%\LICENSE.LIBXML
 copy %DEPS_ROOT%\bin\libeay32.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\ssleay32.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\zlib1.dll %XCHAT_DEST%
@@ -51,7 +57,7 @@ copy ..\plugins\doat\xcdoat.dll %XCHAT_DEST%\plugins
 copy ..\plugins\exec\xcexec.dll %XCHAT_DEST%\plugins
 copy ..\plugins\fishlim\xcfishlim.dll %XCHAT_DEST%\plugins
 copy ..\plugins\lua\xclua.dll %XCHAT_DEST%\plugins
-::copy ..\plugins\gtkpref\xcgtkpref.dll %XCHAT_DEST%\plugins
+copy ..\plugins\gtkpref\xcgtkpref.dll %XCHAT_DEST%\plugins
 copy ..\plugins\mpcinfo\xcmpcinfo.dll %XCHAT_DEST%\plugins
 copy ..\plugins\perl\xcperl-512.dll %XCHAT_DEST%\plugins
 copy ..\plugins\perl\xcperl-514.dll %XCHAT_DEST%\plugins
@@ -60,7 +66,7 @@ copy ..\plugins\tcl\xctcl.dll %XCHAT_DEST%\plugins
 copy ..\plugins\upd\xcupd.dll %XCHAT_DEST%\plugins
 copy ..\plugins\xtray\xtray.dll %XCHAT_DEST%\plugins
 copy ..\plugins\winamp\xcwinamp.dll %XCHAT_DEST%\plugins
-copy ..\plugins\winsys\xcwinsys.dll %XCHAT_DEST%\plugins
+::copy ..\plugins\winsys\xcwinsys.dll %XCHAT_DEST%\plugins
 copy ..\plugins\wmpa\xcwmpa.dll %XCHAT_DEST%\plugins
 copy %DEPS_ROOT%\bin\lua51.dll %XCHAT_DEST%
 xcopy /q /s /i ..\po\locale %XCHAT_DEST%\locale
diff --git a/build/release-x86.bat b/build/release-x86.bat
index d6d8589b..39d8ca01 100644
--- a/build/release-x86.bat
+++ b/build/release-x86.bat
@@ -7,12 +7,13 @@ echo 2> portable-mode
 move portable-mode %XCHAT_DEST%
 copy ..\src\fe-gtk\xchat.exe %XCHAT_DEST%
 copy ..\src\fe-text\xchat-text.exe %XCHAT_DEST%
-::copy ..\src\gtk2-prefs\gtk2-prefs.exe %XCHAT_DEST%
+copy ..\src\gtk2-prefs\gtk2-prefs.exe %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libatk-1.0-0.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libcairo-2.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libexpat-1.dll %XCHAT_DEST%
+copy %DEPS_ROOT%\bin\libffi-5.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libfontconfig-1.dll %XCHAT_DEST%
-copy %DEPS_ROOT%\bin\freetype6.dll %XCHAT_DEST%
+copy %DEPS_ROOT%\bin\libfreetype-6.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libgdk_pixbuf-2.0-0.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libgdk-win32-2.0-0.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libgio-2.0-0.dll %XCHAT_DEST%
@@ -21,17 +22,22 @@ copy %DEPS_ROOT%\bin\libgmodule-2.0-0.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libgobject-2.0-0.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libgthread-2.0-0.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libgtk-win32-2.0-0.dll %XCHAT_DEST%
-copy %DEPS_ROOT%\bin\intl.dll %XCHAT_DEST%
+copy %DEPS_ROOT%\bin\libintl-8.dll %XCHAT_DEST%
+copy %DEPS_ROOT%\bin\libjasper-1.dll %XCHAT_DEST%
+copy %DEPS_ROOT%\bin\libjpeg-8.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libpango-1.0-0.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libpangocairo-1.0-0.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libpangoft2-1.0-0.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libpangowin32-1.0-0.dll %XCHAT_DEST%
-copy %DEPS_ROOT%\bin\libpng14-14.dll %XCHAT_DEST%
-copy %DEPS_ROOT%\bin\libxml2.dll %XCHAT_DEST%
+copy %DEPS_ROOT%\bin\libpixman-1-0.dll %XCHAT_DEST%
+copy %DEPS_ROOT%\bin\libpng15-15.dll %XCHAT_DEST%
+copy %DEPS_ROOT%\bin\libtiff-3.dll %XCHAT_DEST%
+copy %DEPS_ROOT%\bin\libxml2-2.dll %XCHAT_DEST%
 xcopy /q /s /i %DEPS_ROOT%\lib\gtk-2.0\2.10.0\engines %XCHAT_DEST%\lib\gtk-2.0\2.10.0\engines
 xcopy /q /s /i %DEPS_ROOT%\lib\gtk-2.0\modules\libgail.dll %XCHAT_DEST%\lib\gtk-2.0\modules\
 xcopy /q /s /i etc %XCHAT_DEST%\etc
 xcopy /q /s /i share %XCHAT_DEST%\share
+xcopy /q /s /i %DEPS_ROOT%\share\themes %XCHAT_DEST%\share\themes
 copy ..\COPYING %XCHAT_DEST%
 copy %DEPS_ROOT%\LICENSE.OPENSSL %XCHAT_DEST%
 copy %DEPS_ROOT%\LICENSE.ZLIB %XCHAT_DEST%
@@ -39,7 +45,7 @@ copy %DEPS_ROOT%\share\gettext\intl\COPYING.LIB-2.0 %XCHAT_DEST%\LICENSE.GTK
 copy %DEPS_ROOT%\share\gettext\intl\COPYING.LIB-2.1 %XCHAT_DEST%\LICENSE.CAIRO
 copy %DEPS_ROOT%\LICENSE.LUA %XCHAT_DEST%
 copy %DEPS_ROOT%\LICENSE.ENCHANT %XCHAT_DEST%
-copy %DEPS_ROOT%\LICENSE.LIBXML %XCHAT_DEST%
+copy %DEPS_ROOT%\share\doc\libxml2-2.7.8\Copyright %XCHAT_DEST%\LICENSE.LIBXML
 copy %DEPS_ROOT%\bin\libeay32.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\ssleay32.dll %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\zlib1.dll %XCHAT_DEST%
@@ -51,7 +57,7 @@ copy ..\plugins\doat\xcdoat.dll %XCHAT_DEST%\plugins
 copy ..\plugins\exec\xcexec.dll %XCHAT_DEST%\plugins
 copy ..\plugins\fishlim\xcfishlim.dll %XCHAT_DEST%\plugins
 copy ..\plugins\lua\xclua.dll %XCHAT_DEST%\plugins
-::copy ..\plugins\gtkpref\xcgtkpref.dll %XCHAT_DEST%\plugins
+copy ..\plugins\gtkpref\xcgtkpref.dll %XCHAT_DEST%\plugins
 copy ..\plugins\mpcinfo\xcmpcinfo.dll %XCHAT_DEST%\plugins
 copy ..\plugins\perl\xcperl-512.dll %XCHAT_DEST%\plugins
 copy ..\plugins\perl\xcperl-514.dll %XCHAT_DEST%\plugins
@@ -60,7 +66,7 @@ copy ..\plugins\tcl\xctcl.dll %XCHAT_DEST%\plugins
 copy ..\plugins\upd\xcupd.dll %XCHAT_DEST%\plugins
 copy ..\plugins\xtray\xtray.dll %XCHAT_DEST%\plugins
 copy ..\plugins\winamp\xcwinamp.dll %XCHAT_DEST%\plugins
-copy ..\plugins\winsys\xcwinsys.dll %XCHAT_DEST%\plugins
+::copy ..\plugins\winsys\xcwinsys.dll %XCHAT_DEST%\plugins
 copy ..\plugins\wmpa\xcwmpa.dll %XCHAT_DEST%\plugins
 copy %DEPS_ROOT%\bin\lua51.dll %XCHAT_DEST%
 xcopy /q /s /i ..\po\locale %XCHAT_DEST%\locale
diff --git a/build/xchat-wdk-x64.skel.iss b/build/xchat-wdk-x64.skel.iss
index ff325d79..e4bcde9f 100644
--- a/build/xchat-wdk-x64.skel.iss
+++ b/build/xchat-wdk-x64.skel.iss
@@ -31,6 +31,7 @@ Name: "custom"; Description: "Custom Installation"; Flags: iscustom
 Name: "libs"; Description: "XChat-WDK"; Types: normal full minimal custom; Flags: fixed
 Name: "xctext"; Description: "XChat-Text"; Types: full custom; Flags: disablenouninstallwarning
 Name: "translations"; Description: "Translations"; Types: normal full custom; Flags: disablenouninstallwarning
+Name: "gtkengines"; Description: "GTK+ Engines"; Types: full custom; Flags: disablenouninstallwarning
 ;Name: "spelling"; Description: "Spelling Dictionaries"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins"; Description: "Plugins"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\checksum"; Description: "Checksum"; Types: full custom; Flags: disablenouninstallwarning
@@ -40,7 +41,7 @@ Name: "plugins\fishlim"; Description: "FiSHLiM"; Types: full custom; Flags: disa
 Name: "plugins\mpcinfo"; Description: "mpcInfo"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\upd"; Description: "Update Checker"; Types: normal full custom; Flags: disablenouninstallwarning
 Name: "plugins\winamp"; Description: "Winamp"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\winsys"; Description: "WinSys"; Types: full custom; Flags: disablenouninstallwarning
+;Name: "plugins\winsys"; Description: "WinSys"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\wmpa"; Description: "Windows Media Player Announcer"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\xtray"; Description: "X-Tray"; Types: full custom; Flags: disablenouninstallwarning
 Name: "langs"; Description: "Language Interfaces"; Types: full custom; Flags: disablenouninstallwarning
@@ -73,7 +74,7 @@ Source: ISSkinU.dll; DestDir: {app}; Flags: dontcopy
 
 ; Add the Visual Style resource contains resources used for skinning,
 ; you can also use Microsoft Visual Styles (*.msstyles) resources.
-Source: watercolorlite-blue.cjstyles; DestDir: {tmp}; Flags: dontcopy
+Source: watercolorlite-green.cjstyles; DestDir: {tmp}; Flags: dontcopy
 
 Source: "portable-mode"; DestDir: "{app}"; Tasks: portable
 
@@ -86,19 +87,20 @@ Source: "LICENSE.CAIRO"; DestDir: "{app}"; Components: libs
 Source: "LICENSE.LUA"; DestDir: "{app}"; Components: libs
 Source: "LICENSE.ENCHANT"; DestDir: "{app}"; Components: libs
 Source: "LICENSE.LIBXML"; DestDir: "{app}"; Components: libs
-Source: "etc\*"; DestDir: "{app}\etc"; Flags: createallsubdirs recursesubdirs; Components: libs
+;Source: "etc\gtk-2.0\gtkrc"; DestDir: "{app}\etc\gtk-2.0"; Components: libs and not gtkengines
+Source: "etc\download.png"; DestDir: "{app}\etc"; Components: libs
+Source: "etc\music.png"; DestDir: "{app}\etc"; Components: libs
 Source: "share\xml\*"; DestDir: "{app}\share\xml"; Flags: createallsubdirs recursesubdirs; Components: libs
 Source: "locale\*"; DestDir: "{app}\locale"; Flags: createallsubdirs recursesubdirs; Components: translations
 Source: "share\locale\*"; DestDir: "{app}\share\locale"; Flags: createallsubdirs recursesubdirs; Components: translations
 ;Source: "share\myspell\*"; DestDir: "{app}\share\myspell"; Flags: createallsubdirs recursesubdirs; Components: spelling
 
-Source: "libfreetype-6.dll"; DestDir: "{app}"; Components: libs
-Source: "libintl-8.dll"; DestDir: "{app}"; Components: libs
-
 Source: "libatk-1.0-0.dll"; DestDir: "{app}"; Components: libs
 Source: "libcairo-2.dll"; DestDir: "{app}"; Components: libs
 Source: "libeay32.dll"; DestDir: "{app}"; Components: libs
 Source: "libexpat-1.dll"; DestDir: "{app}"; Components: libs
+Source: "libffi-5.dll"; DestDir: "{app}"; Components: libs
+Source: "libfreetype-6.dll"; DestDir: "{app}"; Components: libs
 Source: "libfontconfig-1.dll"; DestDir: "{app}"; Components: libs
 Source: "libgdk_pixbuf-2.0-0.dll"; DestDir: "{app}"; Components: libs
 Source: "libgdk-win32-2.0-0.dll"; DestDir: "{app}"; Components: libs
@@ -108,15 +110,20 @@ Source: "libgmodule-2.0-0.dll"; DestDir: "{app}"; Components: libs
 Source: "libgobject-2.0-0.dll"; DestDir: "{app}"; Components: libs
 Source: "libgthread-2.0-0.dll"; DestDir: "{app}"; Components: libs
 Source: "libgtk-win32-2.0-0.dll"; DestDir: "{app}"; Components: libs
+Source: "libintl-8.dll"; DestDir: "{app}"; Components: libs
+Source: "libjasper-1.dll"; DestDir: "{app}"; Components: libs
+Source: "libjpeg-8.dll"; DestDir: "{app}"; Components: libs
 Source: "libpango-1.0-0.dll"; DestDir: "{app}"; Components: libs
 Source: "libpangocairo-1.0-0.dll"; DestDir: "{app}"; Components: libs
 Source: "libpangoft2-1.0-0.dll"; DestDir: "{app}"; Components: libs
 Source: "libpangowin32-1.0-0.dll"; DestDir: "{app}"; Components: libs
-Source: "libpng14-14.dll"; DestDir: "{app}"; Components: libs
+Source: "libpixman-1-0.dll"; DestDir: "{app}"; Components: libs
+Source: "libtiff-3.dll"; DestDir: "{app}"; Components: libs
+Source: "libpng15-15.dll"; DestDir: "{app}"; Components: libs
 Source: "lua51.dll"; DestDir: "{app}"; Components: libs
 Source: "ssleay32.dll"; DestDir: "{app}"; Components: libs
 Source: "zlib1.dll"; DestDir: "{app}"; Components: libs
-Source: "libxml2.dll"; DestDir: "{app}"; Components: libs
+Source: "libxml2-2.dll"; DestDir: "{app}"; Components: libs
 Source: "libenchant.dll"; DestDir: "{app}"; Components: libs
 
 Source: "lib\enchant\libenchant_myspell.dll"; DestDir: "{app}\lib\enchant"; Components: libs
@@ -125,6 +132,19 @@ Source: "lib\gtk-2.0\2.10.0\engines\libpixmap.dll"; DestDir: "{app}\lib\gtk-2.0\
 Source: "lib\gtk-2.0\2.10.0\engines\libwimp.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Components: libs
 Source: "lib\gtk-2.0\modules\libgail.dll"; DestDir: "{app}\lib\gtk-2.0\modules"; Components: libs
 
+Source: "etc\gtkpref.png"; DestDir: "{app}\etc"; Components: gtkengines
+Source: "lib\gtk-2.0\2.10.0\engines\libclearlooks.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Components: gtkengines
+Source: "lib\gtk-2.0\2.10.0\engines\libcrux-engine.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Components: gtkengines
+Source: "lib\gtk-2.0\2.10.0\engines\libglide.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Components: gtkengines
+Source: "lib\gtk-2.0\2.10.0\engines\libhcengine.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Components: gtkengines
+Source: "lib\gtk-2.0\2.10.0\engines\libindustrial.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Components: gtkengines
+Source: "lib\gtk-2.0\2.10.0\engines\libmist.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Components: gtkengines
+Source: "lib\gtk-2.0\2.10.0\engines\libredmond95.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Components: gtkengines
+Source: "lib\gtk-2.0\2.10.0\engines\libthinice.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Components: gtkengines
+Source: "plugins\xcgtkpref.dll"; DestDir: "{app}\plugins"; Components: gtkengines
+Source: "share\themes\*"; DestDir: "{app}\share\themes"; Flags: createallsubdirs recursesubdirs; Components: gtkengines
+Source: "gtk2-prefs.exe"; DestDir: "{app}"; Components: gtkengines
+
 Source: "plugins\xcchecksum.dll"; DestDir: "{app}\plugins"; Components: plugins\checksum
 Source: "plugins\xcdoat.dll"; DestDir: "{app}\plugins"; Components: plugins\doat
 Source: "plugins\xcexec.dll"; DestDir: "{app}\plugins"; Components: plugins\exec
@@ -132,7 +152,7 @@ Source: "plugins\xcfishlim.dll"; DestDir: "{app}\plugins"; Components: plugins\f
 Source: "plugins\xcmpcinfo.dll"; DestDir: "{app}\plugins"; Components: plugins\mpcinfo
 Source: "plugins\xcupd.dll"; DestDir: "{app}\plugins"; Components: plugins\upd
 Source: "plugins\xcwinamp.dll"; DestDir: "{app}\plugins"; Components: plugins\winamp
-Source: "plugins\xcwinsys.dll"; DestDir: "{app}\plugins"; Components: plugins\winsys
+;Source: "plugins\xcwinsys.dll"; DestDir: "{app}\plugins"; Components: plugins\winsys
 Source: "plugins\xtray.dll"; DestDir: "{app}\plugins"; Components: plugins\xtray
 Source: "plugins\xcwmpa.dll"; DestDir: "{app}\plugins"; Components: plugins\wmpa
 
diff --git a/build/xchat-wdk-x86.skel.iss b/build/xchat-wdk-x86.skel.iss
index 8a99ebfe..1b68b426 100644
--- a/build/xchat-wdk-x86.skel.iss
+++ b/build/xchat-wdk-x86.skel.iss
@@ -30,6 +30,7 @@ Name: "custom"; Description: "Custom Installation"; Flags: iscustom
 Name: "libs"; Description: "XChat-WDK"; Types: normal full minimal custom; Flags: fixed
 Name: "xctext"; Description: "XChat-Text"; Types: full custom; Flags: disablenouninstallwarning
 Name: "translations"; Description: "Translations"; Types: normal full custom; Flags: disablenouninstallwarning
+Name: "gtkengines"; Description: "GTK+ Engines"; Types: full custom; Flags: disablenouninstallwarning
 ;Name: "spelling"; Description: "Spelling Dictionaries"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins"; Description: "Plugins"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\checksum"; Description: "Checksum"; Types: full custom; Flags: disablenouninstallwarning
@@ -39,7 +40,7 @@ Name: "plugins\fishlim"; Description: "FiSHLiM"; Types: full custom; Flags: disa
 Name: "plugins\mpcinfo"; Description: "mpcInfo"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\upd"; Description: "Update Checker"; Types: normal full custom; Flags: disablenouninstallwarning
 Name: "plugins\winamp"; Description: "Winamp"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\winsys"; Description: "WinSys"; Types: full custom; Flags: disablenouninstallwarning
+;Name: "plugins\winsys"; Description: "WinSys"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\wmpa"; Description: "Windows Media Player Announcer"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\xtray"; Description: "X-Tray"; Types: full custom; Flags: disablenouninstallwarning
 Name: "langs"; Description: "Language Interfaces"; Types: full custom; Flags: disablenouninstallwarning
@@ -85,19 +86,20 @@ Source: "LICENSE.CAIRO"; DestDir: "{app}"; Components: libs
 Source: "LICENSE.LUA"; DestDir: "{app}"; Components: libs
 Source: "LICENSE.ENCHANT"; DestDir: "{app}"; Components: libs
 Source: "LICENSE.LIBXML"; DestDir: "{app}"; Components: libs
-Source: "etc\*"; DestDir: "{app}\etc"; Flags: createallsubdirs recursesubdirs; Components: libs
+;Source: "etc\gtk-2.0\gtkrc"; DestDir: "{app}\etc\gtk-2.0"; Components: libs and not gtkengines
+Source: "etc\download.png"; DestDir: "{app}\etc"; Components: libs
+Source: "etc\music.png"; DestDir: "{app}\etc"; Components: libs
 Source: "share\xml\*"; DestDir: "{app}\share\xml"; Flags: createallsubdirs recursesubdirs; Components: libs
 Source: "locale\*"; DestDir: "{app}\locale"; Flags: createallsubdirs recursesubdirs; Components: translations
 Source: "share\locale\*"; DestDir: "{app}\share\locale"; Flags: createallsubdirs recursesubdirs; Components: translations
 ;Source: "share\myspell\*"; DestDir: "{app}\share\myspell"; Flags: createallsubdirs recursesubdirs; Components: spelling
 
-Source: "freetype6.dll"; DestDir: "{app}"; Components: libs
-Source: "intl.dll"; DestDir: "{app}"; Components: libs
-
 Source: "libatk-1.0-0.dll"; DestDir: "{app}"; Components: libs
 Source: "libcairo-2.dll"; DestDir: "{app}"; Components: libs
 Source: "libeay32.dll"; DestDir: "{app}"; Components: libs
 Source: "libexpat-1.dll"; DestDir: "{app}"; Components: libs
+Source: "libffi-5.dll"; DestDir: "{app}"; Components: libs
+Source: "libfreetype-6.dll"; DestDir: "{app}"; Components: libs
 Source: "libfontconfig-1.dll"; DestDir: "{app}"; Components: libs
 Source: "libgdk_pixbuf-2.0-0.dll"; DestDir: "{app}"; Components: libs
 Source: "libgdk-win32-2.0-0.dll"; DestDir: "{app}"; Components: libs
@@ -107,15 +109,20 @@ Source: "libgmodule-2.0-0.dll"; DestDir: "{app}"; Components: libs
 Source: "libgobject-2.0-0.dll"; DestDir: "{app}"; Components: libs
 Source: "libgthread-2.0-0.dll"; DestDir: "{app}"; Components: libs
 Source: "libgtk-win32-2.0-0.dll"; DestDir: "{app}"; Components: libs
+Source: "libintl-8.dll"; DestDir: "{app}"; Components: libs
+Source: "libjasper-1.dll"; DestDir: "{app}"; Components: libs
+Source: "libjpeg-8.dll"; DestDir: "{app}"; Components: libs
 Source: "libpango-1.0-0.dll"; DestDir: "{app}"; Components: libs
 Source: "libpangocairo-1.0-0.dll"; DestDir: "{app}"; Components: libs
 Source: "libpangoft2-1.0-0.dll"; DestDir: "{app}"; Components: libs
 Source: "libpangowin32-1.0-0.dll"; DestDir: "{app}"; Components: libs
-Source: "libpng14-14.dll"; DestDir: "{app}"; Components: libs
+Source: "libpixman-1-0.dll"; DestDir: "{app}"; Components: libs
+Source: "libtiff-3.dll"; DestDir: "{app}"; Components: libs
+Source: "libpng15-15.dll"; DestDir: "{app}"; Components: libs
 Source: "lua51.dll"; DestDir: "{app}"; Components: libs
 Source: "ssleay32.dll"; DestDir: "{app}"; Components: libs
 Source: "zlib1.dll"; DestDir: "{app}"; Components: libs
-Source: "libxml2.dll"; DestDir: "{app}"; Components: libs
+Source: "libxml2-2.dll"; DestDir: "{app}"; Components: libs
 Source: "libenchant.dll"; DestDir: "{app}"; Components: libs
 
 Source: "lib\enchant\libenchant_myspell.dll"; DestDir: "{app}\lib\enchant"; Components: libs
@@ -124,6 +131,19 @@ Source: "lib\gtk-2.0\2.10.0\engines\libpixmap.dll"; DestDir: "{app}\lib\gtk-2.0\
 Source: "lib\gtk-2.0\2.10.0\engines\libwimp.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Components: libs
 Source: "lib\gtk-2.0\modules\libgail.dll"; DestDir: "{app}\lib\gtk-2.0\modules"; Components: libs
 
+Source: "etc\gtkpref.png"; DestDir: "{app}\etc"; Components: gtkengines
+Source: "lib\gtk-2.0\2.10.0\engines\libclearlooks.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Components: gtkengines
+Source: "lib\gtk-2.0\2.10.0\engines\libcrux-engine.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Components: gtkengines
+Source: "lib\gtk-2.0\2.10.0\engines\libglide.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Components: gtkengines
+Source: "lib\gtk-2.0\2.10.0\engines\libhcengine.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Components: gtkengines
+Source: "lib\gtk-2.0\2.10.0\engines\libindustrial.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Components: gtkengines
+Source: "lib\gtk-2.0\2.10.0\engines\libmist.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Components: gtkengines
+Source: "lib\gtk-2.0\2.10.0\engines\libredmond95.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Components: gtkengines
+Source: "lib\gtk-2.0\2.10.0\engines\libthinice.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Components: gtkengines
+Source: "plugins\xcgtkpref.dll"; DestDir: "{app}\plugins"; Components: gtkengines
+Source: "share\themes\*"; DestDir: "{app}\share\themes"; Flags: createallsubdirs recursesubdirs; Components: gtkengines
+Source: "gtk2-prefs.exe"; DestDir: "{app}"; Components: gtkengines
+
 Source: "plugins\xcchecksum.dll"; DestDir: "{app}\plugins"; Components: plugins\checksum
 Source: "plugins\xcdoat.dll"; DestDir: "{app}\plugins"; Components: plugins\doat
 Source: "plugins\xcexec.dll"; DestDir: "{app}\plugins"; Components: plugins\exec
@@ -131,7 +151,7 @@ Source: "plugins\xcfishlim.dll"; DestDir: "{app}\plugins"; Components: plugins\f
 Source: "plugins\xcmpcinfo.dll"; DestDir: "{app}\plugins"; Components: plugins\mpcinfo
 Source: "plugins\xcupd.dll"; DestDir: "{app}\plugins"; Components: plugins\upd
 Source: "plugins\xcwinamp.dll"; DestDir: "{app}\plugins"; Components: plugins\winamp
-Source: "plugins\xcwinsys.dll"; DestDir: "{app}\plugins"; Components: plugins\winsys
+;Source: "plugins\xcwinsys.dll"; DestDir: "{app}\plugins"; Components: plugins\winsys
 Source: "plugins\xtray.dll"; DestDir: "{app}\plugins"; Components: plugins\xtray
 Source: "plugins\xcwmpa.dll"; DestDir: "{app}\plugins"; Components: plugins\wmpa
 
diff --git a/dep-x64/deps-x64.txt b/dep-x64/deps-x64.txt
index ed52c2ca..a21b88a2 100644
--- a/dep-x64/deps-x64.txt
+++ b/dep-x64/deps-x64.txt
@@ -1,21 +1,35 @@
-http://ftp.gnome.org/pub/gnome/binaries/win64/atk/1.32/atk_1.32.0-1_win64.zip
-http://ftp.gnome.org/pub/gnome/binaries/win64/atk/1.32/atk-dev_1.32.0-1_win64.zip
-http://ftp.gnome.org/pub/gnome/binaries/win64/dependencies/cairo_1.10.2-1_win64.zip
-http://ftp.gnome.org/pub/gnome/binaries/win64/dependencies/cairo-dev_1.10.2-1_win64.zip
-http://ftp.gnome.org/pub/gnome/binaries/win64/dependencies/expat_2.0.1-3_win64.zip
-http://ftp.gnome.org/pub/gnome/binaries/win64/dependencies/fontconfig_2.8.0-2_win64.zip
-http://ftp.gnome.org/pub/gnome/binaries/win64/dependencies/freetype_2.4.4-1_win64.zip
-http://ftp.gnome.org/pub/gnome/binaries/win64/dependencies/gettext-runtime_0.18.1.1-2_win64.zip
-http://ftp.gnome.org/pub/gnome/binaries/win64/dependencies/gettext-runtime-dev_0.18.1.1-2_win64.zip
-http://ftp.gnome.org/pub/gnome/binaries/win64/dependencies/gettext-tools-dev_0.18.1.1-2_win64.zip
-http://ftp.gnome.org/pub/gnome/binaries/win64/dependencies/libpng_1.4.3-1_win64.zip
-http://ftp.gnome.org/pub/gnome/binaries/win64/glib/2.26/glib_2.26.1-1_win64.zip
-http://ftp.gnome.org/pub/gnome/binaries/win64/glib/2.26/glib-dev_2.26.1-1_win64.zip
-http://ftp.gnome.org/pub/gnome/binaries/win64/gtk+/2.16/gtk+_2.16.6-3_win64.zip
-http://ftp.gnome.org/pub/gnome/binaries/win64/gtk+/2.16/gtk+-dev_2.16.6-3_win64.zip
-http://ftp.gnome.org/pub/gnome/binaries/win64/pango/1.28/pango_1.28.3-1_win64.zip
-http://ftp.gnome.org/pub/gnome/binaries/win64/pango/1.28/pango-dev_1.28.3-1_win64.zip
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-atk-2.2.0-1.3.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-atk-devel-2.2.0-1.3.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-cairo-devel-1.10.2-6.3.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-expat-2.0.1-3.2.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-fontconfig-2.8.0-5.2.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-freetype-2.4.7-1.2.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-gdk-pixbuf-2.24.0-1.3.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-gdk-pixbuf-devel-2.24.0-1.3.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-gdk-pixbuf-devel-tools-2.24.0-1.3.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-gettext-runtime-0.18.1.1-11.2.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-gettext-tools-0.18.1.1-11.2.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-glib2-2.30.2-1.1.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-glib2-devel-2.30.2-1.1.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-gtk2-2.24.8-1.2.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-gtk2-devel-2.24.8-1.2.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-gtk2-engines-2.20.2-6.2.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-gtk2-lang-2.24.8-1.2.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-libcairo2-1.10.2-6.3.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-libexpat-2.0.1-3.2.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-libffi-3.0.10-6.2.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-libgcc-4.6.2-3.1.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-libintl-0.18.1.1-11.2.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-libintl-devel-0.18.1.1-11.2.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-libjasper-1.900.1-6.2.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-libjpeg-8c-2.2.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-libpng-1.5.6-1.2.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-libtiff-3.9.5-1.2.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-libxml2-2.7.8-9.2.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-libxml2-devel-2.7.8-9.2.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-pango-1.29.4-1.3.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-pango-devel-1.29.4-1.3.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win64/openSUSE_12.1/noarch/mingw64-pixman-0.24.0-1.2.noarch.rpm
 http://xchat-wdk.googlecode.com/files/Enchant-WDK%201.6.0-2%20x64.7z
 http://xchat-wdk.googlecode.com/files/Lua-WDK%205.1.4-2-2%20x64.7z
 http://xchat-wdk.googlecode.com/files/OpenSSL-WDK%201.0.0e-2%20x64.7z
-http://xchat-wdk.googlecode.com/files/LibXML-WDK%202.7.8%20x64.7z
diff --git a/dep-x86/deps-x86.txt b/dep-x86/deps-x86.txt
index 27732940..8f3ef55a 100644
--- a/dep-x86/deps-x86.txt
+++ b/dep-x86/deps-x86.txt
@@ -25,10 +25,11 @@ http://download.opensuse.org/repositories/windows:/mingw:/win32/openSUSE_12.1/no
 http://download.opensuse.org/repositories/windows:/mingw:/win32/openSUSE_12.1/noarch/mingw32-libjpeg-8c-2.3.noarch.rpm
 http://download.opensuse.org/repositories/windows:/mingw:/win32/openSUSE_12.1/noarch/mingw32-libpng-1.5.6-1.3.noarch.rpm
 http://download.opensuse.org/repositories/windows:/mingw:/win32/openSUSE_12.1/noarch/mingw32-libtiff-3.9.5-1.3.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win32/openSUSE_12.1/noarch/mingw32-libxml2-2.7.8-8.3.noarch.rpm
+http://download.opensuse.org/repositories/windows:/mingw:/win32/openSUSE_12.1/noarch/mingw32-libxml2-devel-2.7.8-8.3.noarch.rpm
 http://download.opensuse.org/repositories/windows:/mingw:/win32/openSUSE_12.1/noarch/mingw32-pango-1.29.4-1.3.noarch.rpm
 http://download.opensuse.org/repositories/windows:/mingw:/win32/openSUSE_12.1/noarch/mingw32-pango-devel-1.29.4-1.3.noarch.rpm
 http://download.opensuse.org/repositories/windows:/mingw:/win32/openSUSE_12.1/noarch/mingw32-pixman-0.24.0-1.3.noarch.rpm
 http://xchat-wdk.googlecode.com/files/Enchant-WDK%201.6.0-2%20x86.7z
 http://xchat-wdk.googlecode.com/files/Lua-WDK%205.1.4-2-2%20x86.7z
 http://xchat-wdk.googlecode.com/files/OpenSSL-WDK%201.0.0e-2%20x86.7z
-http://xchat-wdk.googlecode.com/files/LibXML-WDK%202.7.8%20x86.7z
diff --git a/plugins/makefile.mak b/plugins/makefile.mak
index b63e2e54..c7faaf37 100644
--- a/plugins/makefile.mak
+++ b/plugins/makefile.mak
@@ -1,8 +1,8 @@
 all:
 	@cd checksum
 	@-$(MAKE) /nologo /s /f makefile.mak $@
-#	@cd ..\gtkpref
-#	@-$(MAKE) /nologo /s /f makefile.mak $@
+	@cd ..\gtkpref
+	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\doat
 	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\exec
@@ -23,16 +23,16 @@ all:
 	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\winamp
 	@-$(MAKE) /nologo /s /f makefile.mak $@
-	@cd ..\winsys
-	@-$(MAKE) /nologo /s /f makefile.mak $@	
+#	@cd ..\winsys
+#	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\wmpa
 	@-$(MAKE) /nologo /s /f makefile.mak $@
 
 clean:
 	@cd checksum
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
-#	@cd ..\gtkpref
-#	@-$(MAKE) /nologo /s /f makefile.mak clean $@
+	@cd ..\gtkpref
+	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\doat
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\exec
-- 
cgit 1.4.1


From 7116b36d87f73270af3827b9acbaa9456d290cac Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Mon, 28 Nov 2011 20:22:59 +0100
Subject: more winsys fixes for wdk

---
 plugins/winsys/makefile.mak |  2 +-
 plugins/winsys/winsys.c     | 27 ++++++++++++++++-----------
 2 files changed, 17 insertions(+), 12 deletions(-)

(limited to 'plugins')

diff --git a/plugins/winsys/makefile.mak b/plugins/winsys/makefile.mak
index 5d125ab7..d7d1e4a9 100644
--- a/plugins/winsys/makefile.mak
+++ b/plugins/winsys/makefile.mak
@@ -9,7 +9,7 @@ winsys.def:
 	echo xchat_plugin_deinit >> winsys.def
 
 winsys.obj: winsys.c makefile.mak
-	cl $(CFLAGS) $(GLIB) /I.. winsys.c
+	cl $(CFLAGS) $(GLIB) /Zc:wchar_t- /I.. winsys.c
 
 clean:
 	del *.obj
diff --git a/plugins/winsys/winsys.c b/plugins/winsys/winsys.c
index 2a1e65ad..b3a77629 100644
--- a/plugins/winsys/winsys.c
+++ b/plugins/winsys/winsys.c
@@ -20,14 +20,10 @@
  * THE SOFTWARE.
  */
 
-#define _WIN32_DCOM
 #include <stdio.h>
 #include <windows.h>
-/* use intrin.h for SDK builds
-#include <intrin.h> */
-#include <ntddk.h>
-#include <comdef.h>
-#include <Wbemidl.h>
+#include <comutil.h>
+#include <wbemidl.h>
 
 #include "xchat-plugin.h"
 
@@ -124,6 +120,7 @@ getOsName (void)
 	return winver;
 }
 
+#if 0
 static char*
 getCpuName (void)
 {
@@ -157,6 +154,7 @@ getCpuName (void)
 
 	return CPUBrandString;
 }
+#endif
 
 static char*
 getCpuMhz (void)
@@ -200,7 +198,7 @@ getMemoryInfo (void)
 }
 
 static char*
-getVgaName (void)
+getWmiInfo (int mode)
 {
 	/* for more details about this wonderful API, see 
 	http://msdn.microsoft.com/en-us/site/aa394138
@@ -261,7 +259,14 @@ getVgaName (void)
 		return buffer;
 	}
 
-	hres = pSvc->ExecQuery (bstr_t ("WQL"), bstr_t ("SELECT * FROM Win32_VideoController"), WBEM_FLAG_FORWARD_ONLY | WBEM_FLAG_RETURN_IMMEDIATELY, NULL, &pEnumerator);
+	if (mode)
+	{
+		hres = pSvc->ExecQuery (_bstr_t ("WQL"), _bstr_t ("SELECT * FROM Win32_VideoController"), WBEM_FLAG_FORWARD_ONLY | WBEM_FLAG_RETURN_IMMEDIATELY, NULL, &pEnumerator);
+	}
+	else
+	{
+		hres = pSvc->ExecQuery (_bstr_t ("WQL"), _bstr_t ("SELECT * FROM Win32_Processor"), WBEM_FLAG_FORWARD_ONLY | WBEM_FLAG_RETURN_IMMEDIATELY, NULL, &pEnumerator);
+	}
 
 	if (FAILED (hres))
 	{
@@ -279,7 +284,7 @@ getVgaName (void)
 			break;
 		}
 		VARIANT vtProp;
-		hr = pclsObj->Get (L"Caption", 0, &vtProp, 0, 0);
+		hr = pclsObj->Get (L"Name", 0, &vtProp, 0, 0);
 		WideCharToMultiByte (CP_ACP, 0, vtProp.bstrVal, -1, buffer, SysStringLen (vtProp.bstrVal)+1, NULL, NULL);
 		VariantClear (&vtProp);
     }
@@ -297,9 +302,9 @@ static int
 printInfo()
 {
 	xchat_printf (ph, "OS:\t%s\n", getOsName ());
-	xchat_printf (ph, "CPU:\t%s (%s)\n", getCpuName (), getCpuMhz ());
+	xchat_printf (ph, "CPU:\t%s (%s)\n", getWmiInfo (0), getCpuMhz ());
 	xchat_printf (ph, "RAM:\t%s\n", getMemoryInfo ());
-	xchat_printf (ph, "VGA:\t%s\n", getVgaName ());
+	xchat_printf (ph, "VGA:\t%s\n", getWmiInfo (1));
 	/* will work correctly for up to 50 days, should be enough */
 	xchat_printf (ph, "Uptime:\t%.2f Hours\n", (float) GetTickCount() / 1000 / 60 / 60);
 	return XCHAT_EAT_XCHAT;
-- 
cgit 1.4.1


From 5f758e821af54b244dc9f5f60822f99028267121 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Mon, 28 Nov 2011 20:42:10 +0100
Subject: more winsys fixes and build as c++

---
 plugins/winsys/makefile.mak |   6 +-
 plugins/winsys/winsys.c     | 336 --------------------------------------------
 plugins/winsys/winsys.cpp   | 336 ++++++++++++++++++++++++++++++++++++++++++++
 3 files changed, 339 insertions(+), 339 deletions(-)
 delete mode 100644 plugins/winsys/winsys.c
 create mode 100644 plugins/winsys/winsys.cpp

(limited to 'plugins')

diff --git a/plugins/winsys/makefile.mak b/plugins/winsys/makefile.mak
index d7d1e4a9..cb480ac0 100644
--- a/plugins/winsys/makefile.mak
+++ b/plugins/winsys/makefile.mak
@@ -1,15 +1,15 @@
 include "..\..\src\makeinc.mak"
 
 all: winsys.obj winsys.def
-	link $(LDFLAGS) $(LIBS) wbemuuid.lib /dll /out:xcwinsys.dll /def:winsys.def winsys.obj
+	link $(LDFLAGS) $(LIBS) /NODEFAULTLIB:comsupp.lib wbemuuid.lib vccomsup.lib /dll /out:xcwinsys.dll /def:winsys.def winsys.obj
 
 winsys.def:
 	echo EXPORTS > winsys.def
 	echo xchat_plugin_init >> winsys.def
 	echo xchat_plugin_deinit >> winsys.def
 
-winsys.obj: winsys.c makefile.mak
-	cl $(CFLAGS) $(GLIB) /Zc:wchar_t- /I.. winsys.c
+winsys.obj: winsys.cpp makefile.mak
+	cl $(CFLAGS) $(GLIB) /Zc:wchar_t- /I.. winsys.cpp
 
 clean:
 	del *.obj
diff --git a/plugins/winsys/winsys.c b/plugins/winsys/winsys.c
deleted file mode 100644
index b3a77629..00000000
--- a/plugins/winsys/winsys.c
+++ /dev/null
@@ -1,336 +0,0 @@
-/* XChat-WDK
- * Copyright (c) 2011 Berke Viktor.
- *
- * Permission is hereby granted, free of charge, to any person obtaining a copy
- * of this software and associated documentation files (the "Software"), to deal
- * in the Software without restriction, including without limitation the rights
- * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
- * copies of the Software, and to permit persons to whom the Software is
- * furnished to do so, subject to the following conditions:
- *
- * The above copyright notice and this permission notice shall be included in
- * all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
- * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
- * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
- * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
- * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
- * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
- * THE SOFTWARE.
- */
-
-#include <stdio.h>
-#include <windows.h>
-#include <comutil.h>
-#include <wbemidl.h>
-
-#include "xchat-plugin.h"
-
-static xchat_plugin *ph;   /* plugin handle */
-
-static char *
-getOsName (void)
-{
-	static char winver[32];
-	double mhz;
-	OSVERSIONINFOEX osvi;
-	SYSTEM_INFO si;
-
-	osvi.dwOSVersionInfoSize = sizeof (OSVERSIONINFOEX);
-	GetVersionEx ((LPOSVERSIONINFOW)&osvi);
-
-	GetSystemInfo (&si);
-
-	strcpy (winver, "Windows ");
-
-	switch (osvi.dwMajorVersion)
-	{
-		case 5:
-			switch (osvi.dwMinorVersion)
-			{
-				case 1:
-					strcat (winver, "XP");
-					break;
-				case 2:
-					if (osvi.wProductType == VER_NT_WORKSTATION)
-					{
-						strcat (winver, "XP x64 Edition");
-					}
-					else
-					{
-						if (GetSystemMetrics(SM_SERVERR2) == 0)
-						{
-							strcat (winver, "Server 2003");
-						}
-						else
-						{
-							strcat (winver, "Server 2003 R2");
-						}
-					}
-					break;
-			}
-			break;
-		case 6:
-			switch (osvi.dwMinorVersion)
-			{
-				case 0:
-					if (osvi.wProductType == VER_NT_WORKSTATION)
-					{
-						strcat (winver, "Vista");
-					}
-					else
-					{
-						strcat (winver, "Server 2008");
-					}
-					break;
-				case 1:
-					if (osvi.wProductType == VER_NT_WORKSTATION)
-					{
-						strcat (winver, "7");
-					}
-					else
-					{
-						strcat (winver, "Server 2008 R2");
-					}
-					break;
-				case 2:
-					if (osvi.wProductType == VER_NT_WORKSTATION)
-					{
-						strcat (winver, "8");
-					}
-					else
-					{
-						strcat (winver, "8 Server");
-					}
-					break;
-			}
-			break;
-	}
-
-	if (si.wProcessorArchitecture == 9)
-	{
-		strcat (winver, " (x64)");
-	}
-	else
-	{
-		strcat (winver, " (x86)");
-	}
-
-	return winver;
-}
-
-#if 0
-static char*
-getCpuName (void)
-{
-	// Get extended ids.
-	unsigned int nExIds;
-	unsigned int i;
-	int CPUInfo[4] = {-1};
-	static char CPUBrandString[128];
-
-	__cpuid (CPUInfo, 0x80000000);
-	nExIds = CPUInfo[0];
-
-	/* Get the information associated with each extended ID. */
-	for (i=0x80000000; i <= nExIds; ++i)
-	{
-		__cpuid (CPUInfo, i);
-
-		if (i == 0x80000002)
-		{
-			memcpy (CPUBrandString, CPUInfo, sizeof (CPUInfo));
-		}
-		else if (i == 0x80000003)
-		{
-			memcpy( CPUBrandString + 16, CPUInfo, sizeof (CPUInfo));
-		}
-		else if (i == 0x80000004)
-		{
-			memcpy (CPUBrandString + 32, CPUInfo, sizeof (CPUInfo));
-		}
-	}
-
-	return CPUBrandString;
-}
-#endif
-
-static char*
-getCpuMhz (void)
-{
-	HKEY hKey;
-	int result;
-	int data;
-	int dataSize;
-	double cpuspeed;
-	static char buffer[16];
-	const char *cpuspeedstr;
-
-	if (RegOpenKeyEx (HKEY_LOCAL_MACHINE, TEXT("Hardware\\Description\\System\\CentralProcessor\\0"), 0, KEY_QUERY_VALUE, &hKey) == ERROR_SUCCESS)
-	{
-		dataSize = sizeof (data);
-		result = RegQueryValueEx (hKey, TEXT("~MHz"), 0, 0, (LPBYTE)&data, (LPDWORD)&dataSize);
-		RegCloseKey (hKey);
-		if (result == ERROR_SUCCESS)
-		{
-			cpuspeed = ( data > 1000 ) ? data / 1000 : data;
-			cpuspeedstr = ( data > 1000 ) ? "GHz" : "MHz";
-			sprintf (buffer, "%.2f %s", cpuspeed, cpuspeedstr);
-		}
-	}
-
-	return buffer;
-}
-
-static char*
-getMemoryInfo (void)
-{
-	static char buffer[16];
-	MEMORYSTATUSEX meminfo;
-
-	meminfo.dwLength = sizeof (meminfo);
-	GlobalMemoryStatusEx (&meminfo);
-
-	sprintf (buffer, "%I64d MB Total (%I64d MB Free)", meminfo.ullTotalPhys/1024/1024, meminfo.ullAvailPhys/1024/1024);
-
-	return buffer;
-}
-
-static char*
-getWmiInfo (int mode)
-{
-	/* for more details about this wonderful API, see 
-	http://msdn.microsoft.com/en-us/site/aa394138
-	http://msdn.microsoft.com/en-us/site/aa390423
-	http://msdn.microsoft.com/en-us/library/windows/desktop/aa394138%28v=vs.85%29.aspx
-	http://social.msdn.microsoft.com/forums/en-US/vcgeneral/thread/d6420012-e432-4964-8506-6f6b65e5a451
-	*/
-
-	char buffer[128];
-	HRESULT hres;
-	HRESULT hr;
-	IWbemLocator *pLoc = NULL;
-	IWbemServices *pSvc = NULL;
-	IEnumWbemClassObject *pEnumerator = NULL;
-	IWbemClassObject *pclsObj;
-	ULONG uReturn = 0;
-
-	strcpy (buffer, "Unknown");
-	hres =  CoInitializeEx (0, COINIT_MULTITHREADED);
-
-	if (FAILED (hres))
-	{
-		return buffer;
-	}
-
-	hres =  CoInitializeSecurity (NULL, -1, NULL, NULL, RPC_C_AUTHN_LEVEL_DEFAULT, RPC_C_IMP_LEVEL_IMPERSONATE, NULL, EOAC_NONE, NULL);
-
-	if (FAILED (hres))
-	{
-		CoUninitialize ();
-		return buffer;
-	}
-
-	hres = CoCreateInstance (CLSID_WbemLocator, 0, CLSCTX_INPROC_SERVER, IID_IWbemLocator, (LPVOID *) &pLoc);
-
-	if (FAILED (hres))
-	{
-		CoUninitialize ();
-		return buffer;
-	}
-
-	hres = pLoc->ConnectServer (_bstr_t (L"root\\CIMV2"), NULL, NULL, 0, NULL, 0, 0, &pSvc);
-
-	if (FAILED (hres))
-	{
-		pLoc->Release ();
-		CoUninitialize ();
-		return buffer;
-	}
-
-	hres = CoSetProxyBlanket (pSvc, RPC_C_AUTHN_WINNT, RPC_C_AUTHZ_NONE, NULL, RPC_C_AUTHN_LEVEL_CALL, RPC_C_IMP_LEVEL_IMPERSONATE, NULL, EOAC_NONE);
-
-	if (FAILED (hres))
-	{
-		pSvc->Release ();
-		pLoc->Release ();
-		CoUninitialize ();
-		return buffer;
-	}
-
-	if (mode)
-	{
-		hres = pSvc->ExecQuery (_bstr_t ("WQL"), _bstr_t ("SELECT * FROM Win32_VideoController"), WBEM_FLAG_FORWARD_ONLY | WBEM_FLAG_RETURN_IMMEDIATELY, NULL, &pEnumerator);
-	}
-	else
-	{
-		hres = pSvc->ExecQuery (_bstr_t ("WQL"), _bstr_t ("SELECT * FROM Win32_Processor"), WBEM_FLAG_FORWARD_ONLY | WBEM_FLAG_RETURN_IMMEDIATELY, NULL, &pEnumerator);
-	}
-
-	if (FAILED (hres))
-	{
-		pSvc->Release ();
-		pLoc->Release ();
-		CoUninitialize ();
-		return buffer;
-	}
-
-	while (pEnumerator)
-	{
-		hr = pEnumerator->Next (WBEM_INFINITE, 1, &pclsObj, &uReturn);
-		if (0 == uReturn)
-		{
-			break;
-		}
-		VARIANT vtProp;
-		hr = pclsObj->Get (L"Name", 0, &vtProp, 0, 0);
-		WideCharToMultiByte (CP_ACP, 0, vtProp.bstrVal, -1, buffer, SysStringLen (vtProp.bstrVal)+1, NULL, NULL);
-		VariantClear (&vtProp);
-    }
-
-	pSvc->Release ();
-	pLoc->Release ();
-	pEnumerator->Release ();
-	pclsObj->Release ();
-	CoUninitialize ();
-
-	return buffer;
-}
-
-static int
-printInfo()
-{
-	xchat_printf (ph, "OS:\t%s\n", getOsName ());
-	xchat_printf (ph, "CPU:\t%s (%s)\n", getWmiInfo (0), getCpuMhz ());
-	xchat_printf (ph, "RAM:\t%s\n", getMemoryInfo ());
-	xchat_printf (ph, "VGA:\t%s\n", getWmiInfo (1));
-	/* will work correctly for up to 50 days, should be enough */
-	xchat_printf (ph, "Uptime:\t%.2f Hours\n", (float) GetTickCount() / 1000 / 60 / 60);
-	return XCHAT_EAT_XCHAT;
-}
-
-int
-xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugin_desc, char **plugin_version, char *arg)
-{
-	ph = plugin_handle;
-
-	*plugin_name = "WinSys";
-	*plugin_desc = "Display info about your hardware and OS";
-	*plugin_version = "1.0";
-
-	xchat_hook_command (ph, "WINSYS", XCHAT_PRI_NORM, printInfo, 0, 0);
-	xchat_command (ph, "MENU -ietc\\download.png ADD \"Window/Display System Info\" \"WINSYS\"");
-
-	xchat_printf (ph, "%s plugin loaded\n", *plugin_name);
-
-	return 1;       /* return 1 for success */
-}
-
-int
-xchat_plugin_deinit (void)
-{
-	xchat_command (ph, "MENU DEL \"Window/Display System Info\"");
-	xchat_print (ph, "WinSys plugin unloaded\n");
-	return 1;
-}
diff --git a/plugins/winsys/winsys.cpp b/plugins/winsys/winsys.cpp
new file mode 100644
index 00000000..b3a77629
--- /dev/null
+++ b/plugins/winsys/winsys.cpp
@@ -0,0 +1,336 @@
+/* XChat-WDK
+ * Copyright (c) 2011 Berke Viktor.
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in
+ * all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+ * THE SOFTWARE.
+ */
+
+#include <stdio.h>
+#include <windows.h>
+#include <comutil.h>
+#include <wbemidl.h>
+
+#include "xchat-plugin.h"
+
+static xchat_plugin *ph;   /* plugin handle */
+
+static char *
+getOsName (void)
+{
+	static char winver[32];
+	double mhz;
+	OSVERSIONINFOEX osvi;
+	SYSTEM_INFO si;
+
+	osvi.dwOSVersionInfoSize = sizeof (OSVERSIONINFOEX);
+	GetVersionEx ((LPOSVERSIONINFOW)&osvi);
+
+	GetSystemInfo (&si);
+
+	strcpy (winver, "Windows ");
+
+	switch (osvi.dwMajorVersion)
+	{
+		case 5:
+			switch (osvi.dwMinorVersion)
+			{
+				case 1:
+					strcat (winver, "XP");
+					break;
+				case 2:
+					if (osvi.wProductType == VER_NT_WORKSTATION)
+					{
+						strcat (winver, "XP x64 Edition");
+					}
+					else
+					{
+						if (GetSystemMetrics(SM_SERVERR2) == 0)
+						{
+							strcat (winver, "Server 2003");
+						}
+						else
+						{
+							strcat (winver, "Server 2003 R2");
+						}
+					}
+					break;
+			}
+			break;
+		case 6:
+			switch (osvi.dwMinorVersion)
+			{
+				case 0:
+					if (osvi.wProductType == VER_NT_WORKSTATION)
+					{
+						strcat (winver, "Vista");
+					}
+					else
+					{
+						strcat (winver, "Server 2008");
+					}
+					break;
+				case 1:
+					if (osvi.wProductType == VER_NT_WORKSTATION)
+					{
+						strcat (winver, "7");
+					}
+					else
+					{
+						strcat (winver, "Server 2008 R2");
+					}
+					break;
+				case 2:
+					if (osvi.wProductType == VER_NT_WORKSTATION)
+					{
+						strcat (winver, "8");
+					}
+					else
+					{
+						strcat (winver, "8 Server");
+					}
+					break;
+			}
+			break;
+	}
+
+	if (si.wProcessorArchitecture == 9)
+	{
+		strcat (winver, " (x64)");
+	}
+	else
+	{
+		strcat (winver, " (x86)");
+	}
+
+	return winver;
+}
+
+#if 0
+static char*
+getCpuName (void)
+{
+	// Get extended ids.
+	unsigned int nExIds;
+	unsigned int i;
+	int CPUInfo[4] = {-1};
+	static char CPUBrandString[128];
+
+	__cpuid (CPUInfo, 0x80000000);
+	nExIds = CPUInfo[0];
+
+	/* Get the information associated with each extended ID. */
+	for (i=0x80000000; i <= nExIds; ++i)
+	{
+		__cpuid (CPUInfo, i);
+
+		if (i == 0x80000002)
+		{
+			memcpy (CPUBrandString, CPUInfo, sizeof (CPUInfo));
+		}
+		else if (i == 0x80000003)
+		{
+			memcpy( CPUBrandString + 16, CPUInfo, sizeof (CPUInfo));
+		}
+		else if (i == 0x80000004)
+		{
+			memcpy (CPUBrandString + 32, CPUInfo, sizeof (CPUInfo));
+		}
+	}
+
+	return CPUBrandString;
+}
+#endif
+
+static char*
+getCpuMhz (void)
+{
+	HKEY hKey;
+	int result;
+	int data;
+	int dataSize;
+	double cpuspeed;
+	static char buffer[16];
+	const char *cpuspeedstr;
+
+	if (RegOpenKeyEx (HKEY_LOCAL_MACHINE, TEXT("Hardware\\Description\\System\\CentralProcessor\\0"), 0, KEY_QUERY_VALUE, &hKey) == ERROR_SUCCESS)
+	{
+		dataSize = sizeof (data);
+		result = RegQueryValueEx (hKey, TEXT("~MHz"), 0, 0, (LPBYTE)&data, (LPDWORD)&dataSize);
+		RegCloseKey (hKey);
+		if (result == ERROR_SUCCESS)
+		{
+			cpuspeed = ( data > 1000 ) ? data / 1000 : data;
+			cpuspeedstr = ( data > 1000 ) ? "GHz" : "MHz";
+			sprintf (buffer, "%.2f %s", cpuspeed, cpuspeedstr);
+		}
+	}
+
+	return buffer;
+}
+
+static char*
+getMemoryInfo (void)
+{
+	static char buffer[16];
+	MEMORYSTATUSEX meminfo;
+
+	meminfo.dwLength = sizeof (meminfo);
+	GlobalMemoryStatusEx (&meminfo);
+
+	sprintf (buffer, "%I64d MB Total (%I64d MB Free)", meminfo.ullTotalPhys/1024/1024, meminfo.ullAvailPhys/1024/1024);
+
+	return buffer;
+}
+
+static char*
+getWmiInfo (int mode)
+{
+	/* for more details about this wonderful API, see 
+	http://msdn.microsoft.com/en-us/site/aa394138
+	http://msdn.microsoft.com/en-us/site/aa390423
+	http://msdn.microsoft.com/en-us/library/windows/desktop/aa394138%28v=vs.85%29.aspx
+	http://social.msdn.microsoft.com/forums/en-US/vcgeneral/thread/d6420012-e432-4964-8506-6f6b65e5a451
+	*/
+
+	char buffer[128];
+	HRESULT hres;
+	HRESULT hr;
+	IWbemLocator *pLoc = NULL;
+	IWbemServices *pSvc = NULL;
+	IEnumWbemClassObject *pEnumerator = NULL;
+	IWbemClassObject *pclsObj;
+	ULONG uReturn = 0;
+
+	strcpy (buffer, "Unknown");
+	hres =  CoInitializeEx (0, COINIT_MULTITHREADED);
+
+	if (FAILED (hres))
+	{
+		return buffer;
+	}
+
+	hres =  CoInitializeSecurity (NULL, -1, NULL, NULL, RPC_C_AUTHN_LEVEL_DEFAULT, RPC_C_IMP_LEVEL_IMPERSONATE, NULL, EOAC_NONE, NULL);
+
+	if (FAILED (hres))
+	{
+		CoUninitialize ();
+		return buffer;
+	}
+
+	hres = CoCreateInstance (CLSID_WbemLocator, 0, CLSCTX_INPROC_SERVER, IID_IWbemLocator, (LPVOID *) &pLoc);
+
+	if (FAILED (hres))
+	{
+		CoUninitialize ();
+		return buffer;
+	}
+
+	hres = pLoc->ConnectServer (_bstr_t (L"root\\CIMV2"), NULL, NULL, 0, NULL, 0, 0, &pSvc);
+
+	if (FAILED (hres))
+	{
+		pLoc->Release ();
+		CoUninitialize ();
+		return buffer;
+	}
+
+	hres = CoSetProxyBlanket (pSvc, RPC_C_AUTHN_WINNT, RPC_C_AUTHZ_NONE, NULL, RPC_C_AUTHN_LEVEL_CALL, RPC_C_IMP_LEVEL_IMPERSONATE, NULL, EOAC_NONE);
+
+	if (FAILED (hres))
+	{
+		pSvc->Release ();
+		pLoc->Release ();
+		CoUninitialize ();
+		return buffer;
+	}
+
+	if (mode)
+	{
+		hres = pSvc->ExecQuery (_bstr_t ("WQL"), _bstr_t ("SELECT * FROM Win32_VideoController"), WBEM_FLAG_FORWARD_ONLY | WBEM_FLAG_RETURN_IMMEDIATELY, NULL, &pEnumerator);
+	}
+	else
+	{
+		hres = pSvc->ExecQuery (_bstr_t ("WQL"), _bstr_t ("SELECT * FROM Win32_Processor"), WBEM_FLAG_FORWARD_ONLY | WBEM_FLAG_RETURN_IMMEDIATELY, NULL, &pEnumerator);
+	}
+
+	if (FAILED (hres))
+	{
+		pSvc->Release ();
+		pLoc->Release ();
+		CoUninitialize ();
+		return buffer;
+	}
+
+	while (pEnumerator)
+	{
+		hr = pEnumerator->Next (WBEM_INFINITE, 1, &pclsObj, &uReturn);
+		if (0 == uReturn)
+		{
+			break;
+		}
+		VARIANT vtProp;
+		hr = pclsObj->Get (L"Name", 0, &vtProp, 0, 0);
+		WideCharToMultiByte (CP_ACP, 0, vtProp.bstrVal, -1, buffer, SysStringLen (vtProp.bstrVal)+1, NULL, NULL);
+		VariantClear (&vtProp);
+    }
+
+	pSvc->Release ();
+	pLoc->Release ();
+	pEnumerator->Release ();
+	pclsObj->Release ();
+	CoUninitialize ();
+
+	return buffer;
+}
+
+static int
+printInfo()
+{
+	xchat_printf (ph, "OS:\t%s\n", getOsName ());
+	xchat_printf (ph, "CPU:\t%s (%s)\n", getWmiInfo (0), getCpuMhz ());
+	xchat_printf (ph, "RAM:\t%s\n", getMemoryInfo ());
+	xchat_printf (ph, "VGA:\t%s\n", getWmiInfo (1));
+	/* will work correctly for up to 50 days, should be enough */
+	xchat_printf (ph, "Uptime:\t%.2f Hours\n", (float) GetTickCount() / 1000 / 60 / 60);
+	return XCHAT_EAT_XCHAT;
+}
+
+int
+xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugin_desc, char **plugin_version, char *arg)
+{
+	ph = plugin_handle;
+
+	*plugin_name = "WinSys";
+	*plugin_desc = "Display info about your hardware and OS";
+	*plugin_version = "1.0";
+
+	xchat_hook_command (ph, "WINSYS", XCHAT_PRI_NORM, printInfo, 0, 0);
+	xchat_command (ph, "MENU -ietc\\download.png ADD \"Window/Display System Info\" \"WINSYS\"");
+
+	xchat_printf (ph, "%s plugin loaded\n", *plugin_name);
+
+	return 1;       /* return 1 for success */
+}
+
+int
+xchat_plugin_deinit (void)
+{
+	xchat_command (ph, "MENU DEL \"Window/Display System Info\"");
+	xchat_print (ph, "WinSys plugin unloaded\n");
+	return 1;
+}
-- 
cgit 1.4.1


From 439c382d950e72e9f9fafc71d4aebe1f9e628737 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Mon, 28 Nov 2011 20:42:27 +0100
Subject: enable building of winsys with other plugins

---
 plugins/makefile.mak | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

(limited to 'plugins')

diff --git a/plugins/makefile.mak b/plugins/makefile.mak
index c7faaf37..f8642d2e 100644
--- a/plugins/makefile.mak
+++ b/plugins/makefile.mak
@@ -23,8 +23,8 @@ all:
 	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\winamp
 	@-$(MAKE) /nologo /s /f makefile.mak $@
-#	@cd ..\winsys
-#	@-$(MAKE) /nologo /s /f makefile.mak $@
+	@cd ..\winsys
+	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\wmpa
 	@-$(MAKE) /nologo /s /f makefile.mak $@
 
-- 
cgit 1.4.1


From de8865585304a2d78874e0e42ba69bb25d9d5565 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Mon, 28 Nov 2011 22:54:17 +0100
Subject: now winsys actually works as a plugin

---
 plugins/winsys/makefile.mak |  2 +-
 plugins/winsys/winsys.cpp   | 36 +++++++++++++++++++++---------------
 2 files changed, 22 insertions(+), 16 deletions(-)

(limited to 'plugins')

diff --git a/plugins/winsys/makefile.mak b/plugins/winsys/makefile.mak
index cb480ac0..31f24eb1 100644
--- a/plugins/winsys/makefile.mak
+++ b/plugins/winsys/makefile.mak
@@ -9,7 +9,7 @@ winsys.def:
 	echo xchat_plugin_deinit >> winsys.def
 
 winsys.obj: winsys.cpp makefile.mak
-	cl $(CFLAGS) $(GLIB) /Zc:wchar_t- /I.. winsys.cpp
+	cl $(CFLAGS) $(GLIB) /DUNICODE /D_UNICODE /Zc:wchar_t- /I.. winsys.cpp
 
 clean:
 	del *.obj
diff --git a/plugins/winsys/winsys.cpp b/plugins/winsys/winsys.cpp
index b3a77629..54f4641d 100644
--- a/plugins/winsys/winsys.cpp
+++ b/plugins/winsys/winsys.cpp
@@ -38,7 +38,7 @@ getOsName (void)
 	SYSTEM_INFO si;
 
 	osvi.dwOSVersionInfoSize = sizeof (OSVERSIONINFOEX);
-	GetVersionEx ((LPOSVERSIONINFOW)&osvi);
+	GetVersionEx ((LPOSVERSIONINFOW) &osvi);
 
 	GetSystemInfo (&si);
 
@@ -120,8 +120,8 @@ getOsName (void)
 	return winver;
 }
 
-#if 0
-static char*
+#if 0 /* x86-only, SDK-only, use WMI instead */
+static char *
 getCpuName (void)
 {
 	// Get extended ids.
@@ -156,7 +156,7 @@ getCpuName (void)
 }
 #endif
 
-static char*
+static char *
 getCpuMhz (void)
 {
 	HKEY hKey;
@@ -183,7 +183,7 @@ getCpuMhz (void)
 	return buffer;
 }
 
-static char*
+static char *
 getMemoryInfo (void)
 {
 	static char buffer[16];
@@ -192,12 +192,12 @@ getMemoryInfo (void)
 	meminfo.dwLength = sizeof (meminfo);
 	GlobalMemoryStatusEx (&meminfo);
 
-	sprintf (buffer, "%I64d MB Total (%I64d MB Free)", meminfo.ullTotalPhys/1024/1024, meminfo.ullAvailPhys/1024/1024);
+	sprintf (buffer, "%lld MB Total (%lld MB Free)", meminfo.ullTotalPhys / 1024 / 1024, meminfo.ullAvailPhys / 1024 / 1024);
 
 	return buffer;
 }
 
-static char*
+static char *
 getWmiInfo (int mode)
 {
 	/* for more details about this wonderful API, see 
@@ -207,7 +207,7 @@ getWmiInfo (int mode)
 	http://social.msdn.microsoft.com/forums/en-US/vcgeneral/thread/d6420012-e432-4964-8506-6f6b65e5a451
 	*/
 
-	char buffer[128];
+	static char buffer[128];
 	HRESULT hres;
 	HRESULT hr;
 	IWbemLocator *pLoc = NULL;
@@ -216,27 +216,30 @@ getWmiInfo (int mode)
 	IWbemClassObject *pclsObj;
 	ULONG uReturn = 0;
 
-	strcpy (buffer, "Unknown");
-	hres =  CoInitializeEx (0, COINIT_MULTITHREADED);
+	hres =  CoInitializeEx (0, COINIT_APARTMENTTHREADED | COINIT_SPEED_OVER_MEMORY);
 
 	if (FAILED (hres))
 	{
+		strcpy (buffer, "Error Code 0");
 		return buffer;
 	}
 
 	hres =  CoInitializeSecurity (NULL, -1, NULL, NULL, RPC_C_AUTHN_LEVEL_DEFAULT, RPC_C_IMP_LEVEL_IMPERSONATE, NULL, EOAC_NONE, NULL);
 
-	if (FAILED (hres))
+	/* mysteriously failing after the first execution, but only when used as a plugin, skip it */
+	/*if (FAILED (hres))
 	{
 		CoUninitialize ();
+		strcpy (buffer, "Error Code 1");
 		return buffer;
-	}
+	}*/
 
 	hres = CoCreateInstance (CLSID_WbemLocator, 0, CLSCTX_INPROC_SERVER, IID_IWbemLocator, (LPVOID *) &pLoc);
 
 	if (FAILED (hres))
 	{
 		CoUninitialize ();
+		strcpy (buffer, "Error Code 2");
 		return buffer;
 	}
 
@@ -246,6 +249,7 @@ getWmiInfo (int mode)
 	{
 		pLoc->Release ();
 		CoUninitialize ();
+		strcpy (buffer, "Error Code 3");
 		return buffer;
 	}
 
@@ -256,6 +260,7 @@ getWmiInfo (int mode)
 		pSvc->Release ();
 		pLoc->Release ();
 		CoUninitialize ();
+		strcpy (buffer, "Error Code 4");
 		return buffer;
 	}
 
@@ -273,6 +278,7 @@ getWmiInfo (int mode)
 		pSvc->Release ();
 		pLoc->Release ();
 		CoUninitialize ();
+		strcpy (buffer, "Error Code 5");
 		return buffer;
 	}
 
@@ -294,12 +300,11 @@ getWmiInfo (int mode)
 	pEnumerator->Release ();
 	pclsObj->Release ();
 	CoUninitialize ();
-
 	return buffer;
 }
 
 static int
-printInfo()
+printInfo (char *word[], char *word_eol[], void *user_data)
 {
 	xchat_printf (ph, "OS:\t%s\n", getOsName ());
 	xchat_printf (ph, "CPU:\t%s (%s)\n", getWmiInfo (0), getCpuMhz ());
@@ -319,7 +324,7 @@ xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugi
 	*plugin_desc = "Display info about your hardware and OS";
 	*plugin_version = "1.0";
 
-	xchat_hook_command (ph, "WINSYS", XCHAT_PRI_NORM, printInfo, 0, 0);
+	xchat_hook_command (ph, "WINSYS", XCHAT_PRI_NORM, printInfo, NULL, NULL);
 	xchat_command (ph, "MENU -ietc\\download.png ADD \"Window/Display System Info\" \"WINSYS\"");
 
 	xchat_printf (ph, "%s plugin loaded\n", *plugin_name);
@@ -327,6 +332,7 @@ xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugi
 	return 1;       /* return 1 for success */
 }
 
+
 int
 xchat_plugin_deinit (void)
 {
-- 
cgit 1.4.1


From 687203adbbb962f79780586dcf601622b6e4a3ec Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Mon, 28 Nov 2011 23:11:43 +0100
Subject: fix winsys freeze

---
 plugins/winsys/winsys.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/winsys/winsys.cpp b/plugins/winsys/winsys.cpp
index 54f4641d..299b8f87 100644
--- a/plugins/winsys/winsys.cpp
+++ b/plugins/winsys/winsys.cpp
@@ -186,7 +186,7 @@ getCpuMhz (void)
 static char *
 getMemoryInfo (void)
 {
-	static char buffer[16];
+	static char buffer[32];
 	MEMORYSTATUSEX meminfo;
 
 	meminfo.dwLength = sizeof (meminfo);
-- 
cgit 1.4.1


From d010c4ff1b0b8afcac0d61e24af2276aa9f8f0e7 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Mon, 28 Nov 2011 23:41:17 +0100
Subject: MSVC-style print

---
 plugins/winsys/winsys.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/winsys/winsys.cpp b/plugins/winsys/winsys.cpp
index 299b8f87..b6d27f45 100644
--- a/plugins/winsys/winsys.cpp
+++ b/plugins/winsys/winsys.cpp
@@ -192,7 +192,7 @@ getMemoryInfo (void)
 	meminfo.dwLength = sizeof (meminfo);
 	GlobalMemoryStatusEx (&meminfo);
 
-	sprintf (buffer, "%lld MB Total (%lld MB Free)", meminfo.ullTotalPhys / 1024 / 1024, meminfo.ullAvailPhys / 1024 / 1024);
+	sprintf (buffer, "%I64d MB Total (%I64d MB Free)", meminfo.ullTotalPhys / 1024 / 1024, meminfo.ullAvailPhys / 1024 / 1024);
 
 	return buffer;
 }
-- 
cgit 1.4.1


From 6f019e63f13085d1c5f0133a4e2f31a0a365eb77 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Tue, 29 Nov 2011 01:10:57 +0100
Subject: winsys cosmetics and extensions

---
 plugins/winsys/winsys.cpp | 78 ++++++++++++++++++++++++++++++++++++++---------
 1 file changed, 64 insertions(+), 14 deletions(-)

(limited to 'plugins')

diff --git a/plugins/winsys/winsys.cpp b/plugins/winsys/winsys.cpp
index b6d27f45..08e5d809 100644
--- a/plugins/winsys/winsys.cpp
+++ b/plugins/winsys/winsys.cpp
@@ -29,6 +29,29 @@
 
 static xchat_plugin *ph;   /* plugin handle */
 
+static int
+getCpuArch (void)
+{
+	OSVERSIONINFOEX osvi;
+	SYSTEM_INFO si;
+
+	osvi.dwOSVersionInfoSize = sizeof (OSVERSIONINFOEX);
+	GetVersionEx ((LPOSVERSIONINFOW) &osvi);
+
+	GetSystemInfo (&si);
+
+	if (si.wProcessorArchitecture == 9)
+	{
+		return 64;
+	}
+	else
+	{
+		return 86;
+	}
+}
+
+#if 0
+/* use WMI instead, wProcessorArchitecture displays current binary arch instead OS arch anyway */
 static char *
 getOsName (void)
 {
@@ -120,7 +143,7 @@ getOsName (void)
 	return winver;
 }
 
-#if 0 /* x86-only, SDK-only, use WMI instead */
+/* x86-only, SDK-only, use WMI instead */
 static char *
 getCpuName (void)
 {
@@ -264,13 +287,18 @@ getWmiInfo (int mode)
 		return buffer;
 	}
 
-	if (mode)
-	{
-		hres = pSvc->ExecQuery (_bstr_t ("WQL"), _bstr_t ("SELECT * FROM Win32_VideoController"), WBEM_FLAG_FORWARD_ONLY | WBEM_FLAG_RETURN_IMMEDIATELY, NULL, &pEnumerator);
-	}
-	else
+	switch (mode)
 	{
-		hres = pSvc->ExecQuery (_bstr_t ("WQL"), _bstr_t ("SELECT * FROM Win32_Processor"), WBEM_FLAG_FORWARD_ONLY | WBEM_FLAG_RETURN_IMMEDIATELY, NULL, &pEnumerator);
+		case 0:
+			hres = pSvc->ExecQuery (_bstr_t ("WQL"), _bstr_t ("SELECT * FROM Win32_OperatingSystem"), WBEM_FLAG_FORWARD_ONLY | WBEM_FLAG_RETURN_IMMEDIATELY, NULL, &pEnumerator);
+			break;
+		case 1:
+			hres = pSvc->ExecQuery (_bstr_t ("WQL"), _bstr_t ("SELECT * FROM Win32_Processor"), WBEM_FLAG_FORWARD_ONLY | WBEM_FLAG_RETURN_IMMEDIATELY, NULL, &pEnumerator);
+			break;
+		case 2:
+			hres = pSvc->ExecQuery (_bstr_t ("WQL"), _bstr_t ("SELECT * FROM Win32_VideoController"), WBEM_FLAG_FORWARD_ONLY | WBEM_FLAG_RETURN_IMMEDIATELY, NULL, &pEnumerator);
+			break;
+
 	}
 
 	if (FAILED (hres))
@@ -290,7 +318,18 @@ getWmiInfo (int mode)
 			break;
 		}
 		VARIANT vtProp;
-		hr = pclsObj->Get (L"Name", 0, &vtProp, 0, 0);
+		switch (mode)
+		{
+			case 0:
+				hr = pclsObj->Get (L"Caption", 0, &vtProp, 0, 0);
+				break;
+			case 1:
+				hr = pclsObj->Get (L"Name", 0, &vtProp, 0, 0);
+				break;
+			case 2:
+				hr = pclsObj->Get (L"Name", 0, &vtProp, 0, 0);
+				break;
+		}
 		WideCharToMultiByte (CP_ACP, 0, vtProp.bstrVal, -1, buffer, SysStringLen (vtProp.bstrVal)+1, NULL, NULL);
 		VariantClear (&vtProp);
     }
@@ -306,12 +345,23 @@ getWmiInfo (int mode)
 static int
 printInfo (char *word[], char *word_eol[], void *user_data)
 {
-	xchat_printf (ph, "OS:\t%s\n", getOsName ());
-	xchat_printf (ph, "CPU:\t%s (%s)\n", getWmiInfo (0), getCpuMhz ());
-	xchat_printf (ph, "RAM:\t%s\n", getMemoryInfo ());
-	xchat_printf (ph, "VGA:\t%s\n", getWmiInfo (1));
-	/* will work correctly for up to 50 days, should be enough */
-	xchat_printf (ph, "Uptime:\t%.2f Hours\n", (float) GetTickCount() / 1000 / 60 / 60);
+	if (xchat_list_int (ph, NULL, "type") >= 2)
+	{
+		/* xchat_commandf (ph, "ME * WinSys - system details *");
+		xchat_commandf (ph, "ME ***************************"); */
+		xchat_commandf (ph, "ME * Client:  XChat-WDK %s (x%d)", xchat_get_info (ph, "wdk_version"), getCpuArch ());
+		xchat_commandf (ph, "ME * OS:      %s", getWmiInfo (0));
+		xchat_commandf (ph, "ME * CPU:     %s (%s)", getWmiInfo (1), getCpuMhz ());
+		xchat_commandf (ph, "ME * RAM:     %s", getMemoryInfo ());
+		xchat_commandf (ph, "ME * VGA:     %s", getWmiInfo (2));
+		/* will work correctly for up to 50 days, should be enough */
+		xchat_commandf (ph, "ME * Uptime:  %.2f Hours", (float) GetTickCount() / 1000 / 60 / 60);
+	}
+	else
+	{
+		/* print standard error message */
+		xchat_printf (ph, "No channel joined. Try /join #<channel>");
+	}
 	return XCHAT_EAT_XCHAT;
 }
 
-- 
cgit 1.4.1


From 7c0baeffbc302ff0851790b7bc7f87e033368d07 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Tue, 29 Nov 2011 02:04:08 +0100
Subject: relicense own plugins under the MIT license

---
 plugins/checksum/checksum.c | 37 ++++++++++++++++---------------------
 plugins/exec/exec.c         | 36 ++++++++++++++++--------------------
 plugins/gtkpref/gtkpref.c   | 36 ++++++++++++++++--------------------
 plugins/upd/upd.c           | 36 ++++++++++++++++--------------------
 4 files changed, 64 insertions(+), 81 deletions(-)

(limited to 'plugins')

diff --git a/plugins/checksum/checksum.c b/plugins/checksum/checksum.c
index 2b5f801a..12fc0d93 100644
--- a/plugins/checksum/checksum.c
+++ b/plugins/checksum/checksum.c
@@ -1,29 +1,23 @@
 /* XChat-WDK
  * Copyright (c) 2010-2011 Berke Viktor.
  *
- * Use of OpenSSL SHA256 interface: http://adamlamers.com/?p=5
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
  *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- * 3. The name of the author may not be used to endorse or promote products
- *    derived from this software without specific prior written permission.
+ * The above copyright notice and this permission notice shall be included in
+ * all copies or substantial portions of the Software.
  *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+ * THE SOFTWARE.
  */
 
 #include <stdio.h>
@@ -50,6 +44,7 @@
 static xchat_plugin *ph;									/* plugin handle */
 static int config_fail;										/* variable for config availability */
 
+/* Use of OpenSSL SHA256 interface: http://adamlamers.com/?p=5 */
 static void
 sha256_hash_string (unsigned char hash[SHA256_DIGEST_LENGTH], char outputBuffer[65])
 {
diff --git a/plugins/exec/exec.c b/plugins/exec/exec.c
index 9571faad..b043ae83 100644
--- a/plugins/exec/exec.c
+++ b/plugins/exec/exec.c
@@ -1,27 +1,23 @@
 /* XChat-WDK
  * Copyright (c) 2011 Berke Viktor.
  *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- * 3. The name of the author may not be used to endorse or promote products
- *    derived from this software without specific prior written permission.
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
  *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ * The above copyright notice and this permission notice shall be included in
+ * all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+ * THE SOFTWARE.
  */
 
 #include <windows.h>
diff --git a/plugins/gtkpref/gtkpref.c b/plugins/gtkpref/gtkpref.c
index 3816abcc..5cc754bf 100644
--- a/plugins/gtkpref/gtkpref.c
+++ b/plugins/gtkpref/gtkpref.c
@@ -1,27 +1,23 @@
 /* XChat-WDK
  * Copyright (c) 2011 Berke Viktor.
  *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- * 3. The name of the author may not be used to endorse or promote products
- *    derived from this software without specific prior written permission.
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
  *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ * The above copyright notice and this permission notice shall be included in
+ * all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+ * THE SOFTWARE.
  */
 
 #include <windows.h>
diff --git a/plugins/upd/upd.c b/plugins/upd/upd.c
index a6ece301..3eec06dc 100644
--- a/plugins/upd/upd.c
+++ b/plugins/upd/upd.c
@@ -1,27 +1,23 @@
 /* XChat-WDK
  * Copyright (c) 2010-2011 Berke Viktor.
  *
- * Redistribution and use in source and binary forms, with or without
- * modification, are permitted provided that the following conditions
- * are met:
- * 1. Redistributions of source code must retain the above copyright
- *    notice, this list of conditions and the following disclaimer.
- * 2. Redistributions in binary form must reproduce the above copyright
- *    notice, this list of conditions and the following disclaimer in the
- *    documentation and/or other materials provided with the distribution.
- * 3. The name of the author may not be used to endorse or promote products
- *    derived from this software without specific prior written permission.
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
  *
- * THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR
- * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
- * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
- * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
- * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
- * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
- * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
- * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
- * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
- * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+ * The above copyright notice and this permission notice shall be included in
+ * all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+ * THE SOFTWARE.
  */
 
 #include <windows.h>
-- 
cgit 1.4.1


From 7b0555e380ca92285925d18c1045f28f9298bfd6 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Tue, 29 Nov 2011 03:58:20 +0100
Subject: own icon for winsys

---
 build/etc/system.png      | Bin 0 -> 3578 bytes
 plugins/winsys/winsys.cpp |   2 +-
 2 files changed, 1 insertion(+), 1 deletion(-)
 create mode 100644 build/etc/system.png

(limited to 'plugins')

diff --git a/build/etc/system.png b/build/etc/system.png
new file mode 100644
index 00000000..fc4282c7
Binary files /dev/null and b/build/etc/system.png differ
diff --git a/plugins/winsys/winsys.cpp b/plugins/winsys/winsys.cpp
index 08e5d809..a3fa94f9 100644
--- a/plugins/winsys/winsys.cpp
+++ b/plugins/winsys/winsys.cpp
@@ -375,7 +375,7 @@ xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugi
 	*plugin_version = "1.0";
 
 	xchat_hook_command (ph, "WINSYS", XCHAT_PRI_NORM, printInfo, NULL, NULL);
-	xchat_command (ph, "MENU -ietc\\download.png ADD \"Window/Display System Info\" \"WINSYS\"");
+	xchat_command (ph, "MENU -ietc\\system.png ADD \"Window/Display System Info\" \"WINSYS\"");
 
 	xchat_printf (ph, "%s plugin loaded\n", *plugin_name);
 
-- 
cgit 1.4.1


From b5934a75b338f72c34ebf3e8e31cee57dd34d697 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Tue, 29 Nov 2011 04:05:54 +0100
Subject: display sysinfo for self when not in channel/dialog

---
 plugins/winsys/winsys.cpp | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

(limited to 'plugins')

diff --git a/plugins/winsys/winsys.cpp b/plugins/winsys/winsys.cpp
index a3fa94f9..f8d74e2b 100644
--- a/plugins/winsys/winsys.cpp
+++ b/plugins/winsys/winsys.cpp
@@ -359,9 +359,14 @@ printInfo (char *word[], char *word_eol[], void *user_data)
 	}
 	else
 	{
-		/* print standard error message */
-		xchat_printf (ph, "No channel joined. Try /join #<channel>");
+		xchat_printf (ph, " * Client:  XChat-WDK %s (x%d)\n", xchat_get_info (ph, "wdk_version"), getCpuArch ());
+		xchat_printf (ph, " * OS:      %s\n", getWmiInfo (0));
+		xchat_printf (ph, " * CPU:     %s (%s)\n", getWmiInfo (1), getCpuMhz ());
+		xchat_printf (ph, " * RAM:     %s\n", getMemoryInfo ());
+		xchat_printf (ph, " * VGA:     %s\n", getWmiInfo (2));
+		xchat_printf (ph, " * Uptime:  %.2f Hours\n", (float) GetTickCount() / 1000 / 60 / 60);
 	}
+
 	return XCHAT_EAT_XCHAT;
 }
 
-- 
cgit 1.4.1


From b16ca3fa64fc1fa83d40d00d0090cc7fd27a9840 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Tue, 29 Nov 2011 20:15:56 +0100
Subject: initial plugin config framework, can't save multiple entries

---
 plugins/xchat-plugin.h    | 20 +++++++++++
 src/common/cfgfiles.c     |  2 +-
 src/common/cfgfiles.h     |  1 +
 src/common/plugin.c       | 89 +++++++++++++++++++++++++++++++++++++++++++++++
 src/common/plugin.h       |  7 ++++
 src/common/util.c         | 18 ++++++++++
 src/common/util.h         |  1 +
 src/common/xchat-plugin.h | 20 +++++++++++
 8 files changed, 157 insertions(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/xchat-plugin.h b/plugins/xchat-plugin.h
index 30b19295..e9dd1be8 100644
--- a/plugins/xchat-plugin.h
+++ b/plugins/xchat-plugin.h
@@ -137,6 +137,13 @@ struct _xchat_plugin
 	     int flags);
 	void (*xchat_free) (xchat_plugin *ph,
 	    void *ptr);
+	int (*xchat_set_plugin_pref) (xchat_plugin *ph,
+		char *var,
+		char *value);
+	int (*xchat_get_plugin_pref) (xchat_plugin *ph,
+		char *var,
+		char *dest,
+		int dest_len);
 };
 #endif
 
@@ -292,6 +299,17 @@ void
 xchat_free (xchat_plugin *ph,
 	    void *ptr);
 
+int
+xchat_set_plugin_pref (xchat_plugin *ph,
+		char *var,
+		char *value);
+
+int
+xchat_get_plugin_pref (xchat_plugin *ph,
+		char *var,
+		char *dest,
+		int dest_len);
+
 #if !defined(PLUGIN_C) && defined(WIN32)
 #ifndef XCHAT_PLUGIN_HANDLE
 #define XCHAT_PLUGIN_HANDLE (ph)
@@ -326,6 +344,8 @@ xchat_free (xchat_plugin *ph,
 #define xchat_send_modes ((XCHAT_PLUGIN_HANDLE)->xchat_send_modes)
 #define xchat_strip ((XCHAT_PLUGIN_HANDLE)->xchat_strip)
 #define xchat_free ((XCHAT_PLUGIN_HANDLE)->xchat_free)
+#define xchat_set_plugin_pref ((XCHAT_PLUGIN_HANDLE)->xchat_set_plugin_pref)
+#define xchat_get_plugin_pref ((XCHAT_PLUGIN_HANDLE)->xchat_get_plugin_pref)
 #endif
 
 #ifdef __cplusplus
diff --git a/src/common/cfgfiles.c b/src/common/cfgfiles.c
index e5d0eaef..ff4f3756 100644
--- a/src/common/cfgfiles.c
+++ b/src/common/cfgfiles.c
@@ -197,7 +197,7 @@ cfg_get_str (char *cfg, char *var, char *dest, int dest_len)
 	}
 }
 
-static int
+int
 cfg_put_str (int fh, char *var, char *value)
 {
 	char buf[512];
diff --git a/src/common/cfgfiles.h b/src/common/cfgfiles.h
index 984b9472..59fc34b0 100644
--- a/src/common/cfgfiles.h
+++ b/src/common/cfgfiles.h
@@ -9,6 +9,7 @@ extern char *xdir_fs;
 extern char *xdir_utf;
 
 char *cfg_get_str (char *cfg, char *var, char *dest, int dest_len);
+int cfg_put_str (int fh, char *var, char *value);
 int cfg_get_bool (char *var);
 int cfg_get_int_with_result (char *cfg, char *var, int *result);
 int cfg_get_int (char *cfg, char *var);
diff --git a/src/common/plugin.c b/src/common/plugin.c
index b40660a1..ffdc013e 100644
--- a/src/common/plugin.c
+++ b/src/common/plugin.c
@@ -20,6 +20,8 @@
 #include <string.h>
 #include <stdarg.h>
 #include <stdio.h>
+#include <fcntl.h>
+#include <sys/stat.h>
 
 #include "xchat.h"
 #include "fe.h"
@@ -262,6 +264,8 @@ plugin_add (session *sess, char *filename, void *handle, void *init_func,
 		pl->xchat_send_modes = xchat_send_modes;
 		pl->xchat_strip = xchat_strip;
 		pl->xchat_free = xchat_free;
+		pl->xchat_set_plugin_pref = xchat_set_plugin_pref;
+		pl->xchat_get_plugin_pref = xchat_get_plugin_pref;
 
 		/* incase new plugins are loaded on older xchat */
 		pl->xchat_dummy4 = xchat_dummy;
@@ -1570,3 +1574,88 @@ xchat_free (xchat_plugin *ph, void *ptr)
 {
 	g_free (ptr);
 }
+
+int
+xchat_set_plugin_pref (xchat_plugin *pl, char *var, char *value)
+{
+	int fh;
+	char confname[32];
+	char *canon;
+
+	canon = g_strdup (pl->name);
+	canonalize_key (canon);
+	sprintf (confname, "plugin_%s.conf", canon);
+	g_free (canon);
+
+	/* partly borrowed from palette.c */
+	fh = xchat_open_file (confname, O_TRUNC | O_WRONLY | O_CREAT, 0600, XOF_DOMODE);
+	if (fh != -1)
+	{
+		cfg_put_str (fh, var, value);
+		close (fh);
+
+		return 1;
+	}
+	else
+	{
+		return 0;
+	}
+}
+
+int
+xchat_get_plugin_pref (xchat_plugin *pl, char *var, char *dest, int dest_len)
+{
+	//cfg_get_str (char *cfg, char *var, char *dest, int dest_len)
+	int fh;
+	int l;
+	char confname[32];
+	//char *buffer;
+	char *canon;
+	char *cfg;
+	struct stat st;
+
+	canon = g_strdup (pl->name);
+	canonalize_key (canon);
+	sprintf (confname, "plugin_%s.conf", canon);
+	g_free (canon);
+
+	//buffer = (char*) malloc (dest_len);
+
+	/* partly borrowed from palette.c */
+	fh = xchat_open_file (confname, O_RDONLY, 0, 0);
+
+	if (fh != -1)
+	{
+		fstat (fh, &st);
+		cfg = malloc (st.st_size + 1);
+
+		if (cfg)
+		{
+			cfg[0] = '\0';
+			l = read (fh, cfg, st.st_size);
+
+			if (l >= 0)
+			{
+				cfg[l] = '\0';
+			}
+
+			if (!cfg_get_str (cfg, var, dest, dest_len))
+			{
+				return 0;
+			}
+
+			free (cfg);
+		}
+		else
+		{
+			return 0;
+		}
+
+		close (fh);
+		return 1;
+	}
+	else
+	{
+		return 0;
+	}
+}
diff --git a/src/common/plugin.h b/src/common/plugin.h
index b0c89d1b..6a2d62e2 100644
--- a/src/common/plugin.h
+++ b/src/common/plugin.h
@@ -98,6 +98,13 @@ struct _xchat_plugin
 	     int flags);
 	void (*xchat_free) (xchat_plugin *ph,
 	    void *ptr);
+	int (*xchat_set_plugin_pref) (xchat_plugin *ph,
+		char *var,
+		char *value);
+	int (*xchat_get_plugin_pref) (xchat_plugin *ph,
+		char *var,
+		char *dest,
+		int dest_len);
 	void *(*xchat_dummy4) (xchat_plugin *ph);
 	void *(*xchat_dummy3) (xchat_plugin *ph);
 	void *(*xchat_dummy2) (xchat_plugin *ph);
diff --git a/src/common/util.c b/src/common/util.c
index 870f4d5c..c16d41f5 100644
--- a/src/common/util.c
+++ b/src/common/util.c
@@ -1830,3 +1830,21 @@ safe_strcpy (char *dest, const char *src, int bytes_left)
 		}
 	}
 }
+
+void
+canonalize_key (char *key)
+{
+	char *pos, token;
+
+	for (pos = key; (token = *pos) != 0; pos++)
+	{
+		if (token != '_' && (token < '0' || token > '9') && (token < 'A' || token > 'Z') && (token < 'a' || token > 'z'))
+		{
+			*pos = '_';
+		}
+		else
+		{
+			*pos = tolower(token);
+		}
+	}
+}
diff --git a/src/common/util.h b/src/common/util.h
index 92d2a843..bee6ec3c 100644
--- a/src/common/util.h
+++ b/src/common/util.h
@@ -56,5 +56,6 @@ int token_foreach (char *str, char sep, int (*callback) (char *str, void *ud), v
 guint32 str_hash (const char *key);
 guint32 str_ihash (const unsigned char *key);
 void safe_strcpy (char *dest, const char *src, int bytes_left);
+void canonalize_key (char *key);
 
 #endif
diff --git a/src/common/xchat-plugin.h b/src/common/xchat-plugin.h
index 30b19295..e9dd1be8 100644
--- a/src/common/xchat-plugin.h
+++ b/src/common/xchat-plugin.h
@@ -137,6 +137,13 @@ struct _xchat_plugin
 	     int flags);
 	void (*xchat_free) (xchat_plugin *ph,
 	    void *ptr);
+	int (*xchat_set_plugin_pref) (xchat_plugin *ph,
+		char *var,
+		char *value);
+	int (*xchat_get_plugin_pref) (xchat_plugin *ph,
+		char *var,
+		char *dest,
+		int dest_len);
 };
 #endif
 
@@ -292,6 +299,17 @@ void
 xchat_free (xchat_plugin *ph,
 	    void *ptr);
 
+int
+xchat_set_plugin_pref (xchat_plugin *ph,
+		char *var,
+		char *value);
+
+int
+xchat_get_plugin_pref (xchat_plugin *ph,
+		char *var,
+		char *dest,
+		int dest_len);
+
 #if !defined(PLUGIN_C) && defined(WIN32)
 #ifndef XCHAT_PLUGIN_HANDLE
 #define XCHAT_PLUGIN_HANDLE (ph)
@@ -326,6 +344,8 @@ xchat_free (xchat_plugin *ph,
 #define xchat_send_modes ((XCHAT_PLUGIN_HANDLE)->xchat_send_modes)
 #define xchat_strip ((XCHAT_PLUGIN_HANDLE)->xchat_strip)
 #define xchat_free ((XCHAT_PLUGIN_HANDLE)->xchat_free)
+#define xchat_set_plugin_pref ((XCHAT_PLUGIN_HANDLE)->xchat_set_plugin_pref)
+#define xchat_get_plugin_pref ((XCHAT_PLUGIN_HANDLE)->xchat_get_plugin_pref)
 #endif
 
 #ifdef __cplusplus
-- 
cgit 1.4.1


From f9fa102690cef217b1565af35b34a727a9b58b33 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Wed, 30 Nov 2011 01:41:34 +0100
Subject: plugin config save is done via raw file access, now works with
 multiple vars

---
 plugins/xchat-plugin.h    |   6 +-
 src/common/plugin.c       | 143 ++++++++++++++++++++++++++++++++--------------
 src/common/xchat-plugin.h |   6 +-
 3 files changed, 105 insertions(+), 50 deletions(-)

(limited to 'plugins')

diff --git a/plugins/xchat-plugin.h b/plugins/xchat-plugin.h
index e9dd1be8..c3606b19 100644
--- a/plugins/xchat-plugin.h
+++ b/plugins/xchat-plugin.h
@@ -142,8 +142,7 @@ struct _xchat_plugin
 		char *value);
 	int (*xchat_get_plugin_pref) (xchat_plugin *ph,
 		char *var,
-		char *dest,
-		int dest_len);
+		char *dest);
 };
 #endif
 
@@ -307,8 +306,7 @@ xchat_set_plugin_pref (xchat_plugin *ph,
 int
 xchat_get_plugin_pref (xchat_plugin *ph,
 		char *var,
-		char *dest,
-		int dest_len);
+		char *dest);
 
 #if !defined(PLUGIN_C) && defined(WIN32)
 #ifndef XCHAT_PLUGIN_HANDLE
diff --git a/src/common/plugin.c b/src/common/plugin.c
index ffdc013e..96510265 100644
--- a/src/common/plugin.c
+++ b/src/common/plugin.c
@@ -1578,38 +1578,104 @@ xchat_free (xchat_plugin *ph, void *ptr)
 int
 xchat_set_plugin_pref (xchat_plugin *pl, char *var, char *value)
 {
-	int fh;
-	char confname[32];
+	FILE *fpIn;
+	int fhOut;
+	int prevConfig;
+	char confname[64];
+	char confname_tmp[69];
+	char buffer[512];		/* the same as in cfg_put_str */
+	char buffer_tmp[512];
 	char *canon;
 
 	canon = g_strdup (pl->name);
 	canonalize_key (canon);
 	sprintf (confname, "plugin_%s.conf", canon);
 	g_free (canon);
+	sprintf (confname_tmp, "%s.new", confname);
 
-	/* partly borrowed from palette.c */
-	fh = xchat_open_file (confname, O_TRUNC | O_WRONLY | O_CREAT, 0600, XOF_DOMODE);
-	if (fh != -1)
+	fhOut = xchat_open_file (confname_tmp, O_TRUNC | O_WRONLY | O_CREAT, 0600, XOF_DOMODE);
+	fpIn = xchat_fopen_file (confname, "r", 0);
+
+	if (fhOut == -1)		/* unable to save, abort */
 	{
-		cfg_put_str (fh, var, value);
-		close (fh);
+		return 0;
+	}
+	else if (fpIn == NULL)	/* no previous config, no parsing */
+	{
+		sprintf (buffer, "%s = %s\n", var, value);
+		write (fhOut, buffer, strlen (buffer));
+		close (fhOut);
 
-		return 1;
+#ifdef WIN32
+		sprintf (buffer, "%s/%s", get_xdir_fs (), confname);
+		unlink (buffer);
+#endif
+
+		sprintf (buffer_tmp, "%s/%s", get_xdir_fs (), confname_tmp);
+		if (rename (buffer_tmp, buffer) == 0)
+		{
+			return 1;
+		}
+		else
+		{
+			return 0;
+		}
 	}
-	else
+	else					/* existing config, preserve settings and find & replace current var value if any */
 	{
-		return 0;
+		prevConfig = 0;
+
+		while (fscanf (fpIn, " %[^\n]", &buffer) != EOF)	/* read whole lines including whitespaces */
+		{
+			sprintf (buffer_tmp, "%s ", var);				/* add one space, this way it works against var - var2 checks too */
+
+			if (strncmp (buffer_tmp, buffer, strlen (var) + 1) == 0)	/* given setting already exists */
+			{
+				sprintf (buffer, "%s = %s\n", var, value);
+				prevConfig = 1;
+			}
+			else
+			{
+				strcat (buffer, "\n");
+			}
+
+			write (fhOut, buffer, strlen (buffer));
+		}
+
+		fclose (fpIn);
+
+		if (!prevConfig)
+		{
+			sprintf (buffer, "%s = %s\n", var, value);
+			write (fhOut, buffer, strlen (buffer));
+		}
+
+		close (fhOut);
+
+#ifdef WIN32
+		sprintf (buffer, "%s/%s", get_xdir_fs (), confname);
+		unlink (buffer);
+#endif
+
+		sprintf (buffer_tmp, "%s/%s", get_xdir_fs (), confname_tmp);
+
+		if (rename (buffer_tmp, buffer) == 0)
+		{
+			return 1;
+		}
+		else
+		{
+			return 0;
+		}
 	}
 }
 
 int
-xchat_get_plugin_pref (xchat_plugin *pl, char *var, char *dest, int dest_len)
+xchat_get_plugin_pref (xchat_plugin *pl, char *var, char *dest)
 {
-	//cfg_get_str (char *cfg, char *var, char *dest, int dest_len)
 	int fh;
 	int l;
-	char confname[32];
-	//char *buffer;
+	char confname[64];
 	char *canon;
 	char *cfg;
 	struct stat st;
@@ -1619,43 +1685,36 @@ xchat_get_plugin_pref (xchat_plugin *pl, char *var, char *dest, int dest_len)
 	sprintf (confname, "plugin_%s.conf", canon);
 	g_free (canon);
 
-	//buffer = (char*) malloc (dest_len);
-
 	/* partly borrowed from palette.c */
-	fh = xchat_open_file (confname, O_RDONLY, 0, 0);
+	fh = xchat_open_file (confname, _O_RDONLY, 0, 0);
 
-	if (fh != -1)
+	if (fh == -1)
 	{
-		fstat (fh, &st);
-		cfg = malloc (st.st_size + 1);
-
-		if (cfg)
-		{
-			cfg[0] = '\0';
-			l = read (fh, cfg, st.st_size);
+		return 0;
+	}
 
-			if (l >= 0)
-			{
-				cfg[l] = '\0';
-			}
+	fstat (fh, &st);
+	cfg = malloc (st.st_size + 1);
 
-			if (!cfg_get_str (cfg, var, dest, dest_len))
-			{
-				return 0;
-			}
+	if (!cfg)
+	{
+		return 0;
+	}
 
-			free (cfg);
-		}
-		else
-		{
-			return 0;
-		}
+	cfg[0] = '\0';
+	l = read (fh, cfg, st.st_size);
 
-		close (fh);
-		return 1;
+	if (l >= 0)
+	{
+		cfg[l] = '\0';
 	}
-	else
+
+	if (!cfg_get_str (cfg, var, dest, 512)) /* dest_len is the same as buffer size in set */
 	{
 		return 0;
 	}
+
+	free (cfg);
+	close (fh);
+	return 1;
 }
diff --git a/src/common/xchat-plugin.h b/src/common/xchat-plugin.h
index e9dd1be8..c3606b19 100644
--- a/src/common/xchat-plugin.h
+++ b/src/common/xchat-plugin.h
@@ -142,8 +142,7 @@ struct _xchat_plugin
 		char *value);
 	int (*xchat_get_plugin_pref) (xchat_plugin *ph,
 		char *var,
-		char *dest,
-		int dest_len);
+		char *dest);
 };
 #endif
 
@@ -307,8 +306,7 @@ xchat_set_plugin_pref (xchat_plugin *ph,
 int
 xchat_get_plugin_pref (xchat_plugin *ph,
 		char *var,
-		char *dest,
-		int dest_len);
+		char *dest);
 
 #if !defined(PLUGIN_C) && defined(WIN32)
 #ifndef XCHAT_PLUGIN_HANDLE
-- 
cgit 1.4.1


From ab3e3926abce49f0741edf90a1300d4cdcc79670 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Wed, 30 Nov 2011 02:22:38 +0100
Subject: use global xchat-plugin.h for xtray

---
 plugins/xtray/callbacks.cpp |   3 +-
 plugins/xtray/makefile.mak  |   2 +-
 plugins/xtray/plugin.h      | 335 --------------------------------------------
 plugins/xtray/utility.cpp   |   3 +-
 plugins/xtray/xchat.cpp     |   3 +-
 plugins/xtray/xtray.cpp     |   4 +-
 6 files changed, 9 insertions(+), 341 deletions(-)
 delete mode 100644 plugins/xtray/plugin.h

(limited to 'plugins')

diff --git a/plugins/xtray/callbacks.cpp b/plugins/xtray/callbacks.cpp
index 443cb05d..1b7f452f 100644
--- a/plugins/xtray/callbacks.cpp
+++ b/plugins/xtray/callbacks.cpp
@@ -22,8 +22,9 @@
 #include <stdio.h>
 #include <commctrl.h>
 #include <tchar.h>
+
+#include "xchat-plugin.h"
 #include "utility.h"
-#include "plugin.h"
 #include "xtray.h"
 #include "xchat.h"
 #include "callbacks.h"
diff --git a/plugins/xtray/makefile.mak b/plugins/xtray/makefile.mak
index d1f8d295..ec2c94b3 100644
--- a/plugins/xtray/makefile.mak
+++ b/plugins/xtray/makefile.mak
@@ -20,7 +20,7 @@ xtray.def:
 	echo xchat_plugin_deinit >> xtray.def
 
 .cpp.obj:
-	$(CC) $(CPPFLAGS) /c $<
+	$(CC) $(CPPFLAGS) /I.. /c $<
 
 res:
 	rc /nologo resource.rc
diff --git a/plugins/xtray/plugin.h b/plugins/xtray/plugin.h
deleted file mode 100644
index 50b0de21..00000000
--- a/plugins/xtray/plugin.h
+++ /dev/null
@@ -1,335 +0,0 @@
-/* You can distribute this header with your plugins for easy compilation */
-#ifndef XCHAT_PLUGIN_H
-#define XCHAT_PLUGIN_H
-
-#include <time.h>
-
-#define XCHAT_IFACE_MAJOR	1
-#define XCHAT_IFACE_MINOR	9
-#define XCHAT_IFACE_MICRO	11
-#define XCHAT_IFACE_VERSION	((XCHAT_IFACE_MAJOR * 10000) + \
-				 (XCHAT_IFACE_MINOR * 100) + \
-				 (XCHAT_IFACE_MICRO))
-
-#define XCHAT_PRI_HIGHEST	127
-#define XCHAT_PRI_HIGH		64
-#define XCHAT_PRI_NORM		0
-#define XCHAT_PRI_LOW		(-64)
-#define XCHAT_PRI_LOWEST	(-128)
-
-#define XCHAT_FD_READ		1
-#define XCHAT_FD_WRITE		2
-#define XCHAT_FD_EXCEPTION	4
-#define XCHAT_FD_NOTSOCKET	8
-
-#define XCHAT_EAT_NONE		0	/* pass it on through! */
-#define XCHAT_EAT_XCHAT		1	/* don't let xchat see this event */
-#define XCHAT_EAT_PLUGIN	2	/* don't let other plugins see this event */
-#define XCHAT_EAT_ALL		(XCHAT_EAT_XCHAT|XCHAT_EAT_PLUGIN)	/* don't let anything see this event */
-
-#ifdef __cplusplus
-extern "C" {
-#endif
-
-typedef struct _xchat_plugin xchat_plugin;
-typedef struct _xchat_list xchat_list;
-typedef struct _xchat_hook xchat_hook;
-#ifndef PLUGIN_C
-typedef struct _xchat_context xchat_context;
-#endif
-
-#ifndef PLUGIN_C
-struct _xchat_plugin
-{
-	/* these are only used on win32 */
-	xchat_hook *(*xchat_hook_command) (xchat_plugin *ph,
-		    const char *name,
-		    int pri,
-		    int (*callback) (char *word[], char *word_eol[], void *user_data),
-		    const char *help_text,
-		    void *userdata);
-	xchat_hook *(*xchat_hook_server) (xchat_plugin *ph,
-		   const char *name,
-		   int pri,
-		   int (*callback) (char *word[], char *word_eol[], void *user_data),
-		   void *userdata);
-	xchat_hook *(*xchat_hook_print) (xchat_plugin *ph,
-		  const char *name,
-		  int pri,
-		  int (*callback) (char *word[], void *user_data),
-		  void *userdata);
-	xchat_hook *(*xchat_hook_timer) (xchat_plugin *ph,
-		  int timeout,
-		  int (*callback) (void *user_data),
-		  void *userdata);
-	xchat_hook *(*xchat_hook_fd) (xchat_plugin *ph,
-		   int fd,
-		   int flags,
-		   int (*callback) (int fd, int flags, void *user_data),
-		   void *userdata);
-	void *(*xchat_unhook) (xchat_plugin *ph,
-	      xchat_hook *hook);
-	void (*xchat_print) (xchat_plugin *ph,
-	     const char *text);
-	void (*xchat_printf) (xchat_plugin *ph,
-	      const char *format, ...);
-	void (*xchat_command) (xchat_plugin *ph,
-	       const char *command);
-	void (*xchat_commandf) (xchat_plugin *ph,
-		const char *format, ...);
-	int (*xchat_nickcmp) (xchat_plugin *ph,
-	       const char *s1,
-	       const char *s2);
-	int (*xchat_set_context) (xchat_plugin *ph,
-		   xchat_context *ctx);
-	xchat_context *(*xchat_find_context) (xchat_plugin *ph,
-		    const char *servname,
-		    const char *channel);
-	xchat_context *(*xchat_get_context) (xchat_plugin *ph);
-	const char *(*xchat_get_info) (xchat_plugin *ph,
-		const char *id);
-	int (*xchat_get_prefs) (xchat_plugin *ph,
-		 const char *name,
-		 const char **string,
-		 int *integer);
-	xchat_list * (*xchat_list_get) (xchat_plugin *ph,
-		const char *name);
-	void (*xchat_list_free) (xchat_plugin *ph,
-		 xchat_list *xlist);
-	const char * const * (*xchat_list_fields) (xchat_plugin *ph,
-		   const char *name);
-	int (*xchat_list_next) (xchat_plugin *ph,
-		 xchat_list *xlist);
-	const char * (*xchat_list_str) (xchat_plugin *ph,
-		xchat_list *xlist,
-		const char *name);
-	int (*xchat_list_int) (xchat_plugin *ph,
-		xchat_list *xlist,
-		const char *name);
-	void * (*xchat_plugingui_add) (xchat_plugin *ph,
-		     const char *filename,
-		     const char *name,
-		     const char *desc,
-		     const char *version,
-		     char *reserved);
-	void (*xchat_plugingui_remove) (xchat_plugin *ph,
-			void *handle);
-	int (*xchat_emit_print) (xchat_plugin *ph,
-			const char *event_name, ...);
-	int (*xchat_read_fd) (xchat_plugin *ph,
-			void *src,
-			char *buf,
-			int *len);
-	time_t (*xchat_list_time) (xchat_plugin *ph,
-		xchat_list *xlist,
-		const char *name);
-	char *(*xchat_gettext) (xchat_plugin *ph,
-		const char *msgid);
-	void (*xchat_send_modes) (xchat_plugin *ph,
-		  const char **targets,
-		  int ntargets,
-		  int modes_per_line,
-		  char sign,
-		  char mode);
-	char *(*xchat_strip) (xchat_plugin *ph,
-	     const char *str,
-	     int len,
-	     int flags);
-	void (*xchat_free) (xchat_plugin *ph,
-	    void *ptr);
-};
-#endif
-
-
-
-xchat_hook *
-xchat_hook_command (xchat_plugin *ph,
-		    const char *name,
-		    int pri,
-		    int (*callback) (char *word[], char *word_eol[], void *user_data),
-		    const char *help_text,
-		    void *userdata);
-
-xchat_hook *
-xchat_hook_server (xchat_plugin *ph,
-		   const char *name,
-		   int pri,
-		   int (*callback) (char *word[], char *word_eol[], void *user_data),
-		   void *userdata);
-
-xchat_hook *
-xchat_hook_print (xchat_plugin *ph,
-		  const char *name,
-		  int pri,
-		  int (*callback) (char *word[], void *user_data),
-		  void *userdata);
-
-xchat_hook *
-xchat_hook_timer (xchat_plugin *ph,
-		  int timeout,
-		  int (*callback) (void *user_data),
-		  void *userdata);
-
-xchat_hook *
-xchat_hook_fd (xchat_plugin *ph,
-		int fd,
-		int flags,
-		int (*callback) (int fd, int flags, void *user_data),
-		void *userdata);
-
-void *
-xchat_unhook (xchat_plugin *ph,
-	      xchat_hook *hook);
-
-void
-xchat_print (xchat_plugin *ph,
-	     const char *text);
-
-void
-xchat_printf (xchat_plugin *ph,
-	      const char *format, ...);
-
-void
-xchat_command (xchat_plugin *ph,
-	       const char *command);
-
-void
-xchat_commandf (xchat_plugin *ph,
-		const char *format, ...);
-
-int
-xchat_nickcmp (xchat_plugin *ph,
-	       const char *s1,
-	       const char *s2);
-
-int
-xchat_set_context (xchat_plugin *ph,
-		   xchat_context *ctx);
-
-xchat_context *
-xchat_find_context (xchat_plugin *ph,
-		    const char *servname,
-		    const char *channel);
-
-xchat_context *
-xchat_get_context (xchat_plugin *ph);
-
-const char *
-xchat_get_info (xchat_plugin *ph,
-		const char *id);
-
-int
-xchat_get_prefs (xchat_plugin *ph,
-		 const char *name,
-		 const char **string,
-		 int *integer);
-
-xchat_list *
-xchat_list_get (xchat_plugin *ph,
-		const char *name);
-
-void
-xchat_list_free (xchat_plugin *ph,
-		 xchat_list *xlist);
-
-const char * const *
-xchat_list_fields (xchat_plugin *ph,
-		   const char *name);
-
-int
-xchat_list_next (xchat_plugin *ph,
-		 xchat_list *xlist);
-
-const char *
-xchat_list_str (xchat_plugin *ph,
-		xchat_list *xlist,
-		const char *name);
-
-int
-xchat_list_int (xchat_plugin *ph,
-		xchat_list *xlist,
-		const char *name);
-
-time_t
-xchat_list_time (xchat_plugin *ph,
-		 xchat_list *xlist,
-		 const char *name);
-
-void *
-xchat_plugingui_add (xchat_plugin *ph,
-		     const char *filename,
-		     const char *name,
-		     const char *desc,
-		     const char *version,
-		     char *reserved);
-
-void
-xchat_plugingui_remove (xchat_plugin *ph,
-			void *handle);
-
-int 
-xchat_emit_print (xchat_plugin *ph,
-		  const char *event_name, ...);
-
-char *
-xchat_gettext (xchat_plugin *ph,
-	       const char *msgid);
-
-void
-xchat_send_modes (xchat_plugin *ph,
-		  const char **targets,
-		  int ntargets,
-		  int modes_per_line,
-		  char sign,
-		  char mode);
-
-char *
-xchat_strip (xchat_plugin *ph,
-	     const char *str,
-	     int len,
-	     int flags);
-
-void
-xchat_free (xchat_plugin *ph,
-	    void *ptr);
-
-#if !defined(PLUGIN_C) && defined(WIN32)
-#ifndef XCHAT_PLUGIN_HANDLE
-#define XCHAT_PLUGIN_HANDLE (ph)
-#endif
-#define xchat_hook_command ((XCHAT_PLUGIN_HANDLE)->xchat_hook_command)
-#define xchat_hook_server ((XCHAT_PLUGIN_HANDLE)->xchat_hook_server)
-#define xchat_hook_print ((XCHAT_PLUGIN_HANDLE)->xchat_hook_print)
-#define xchat_hook_timer ((XCHAT_PLUGIN_HANDLE)->xchat_hook_timer)
-#define xchat_hook_fd ((XCHAT_PLUGIN_HANDLE)->xchat_hook_fd)
-#define xchat_unhook ((XCHAT_PLUGIN_HANDLE)->xchat_unhook)
-#define xchat_print ((XCHAT_PLUGIN_HANDLE)->xchat_print)
-#define xchat_printf ((XCHAT_PLUGIN_HANDLE)->xchat_printf)
-#define xchat_command ((XCHAT_PLUGIN_HANDLE)->xchat_command)
-#define xchat_commandf ((XCHAT_PLUGIN_HANDLE)->xchat_commandf)
-#define xchat_nickcmp ((XCHAT_PLUGIN_HANDLE)->xchat_nickcmp)
-#define xchat_set_context ((XCHAT_PLUGIN_HANDLE)->xchat_set_context)
-#define xchat_find_context ((XCHAT_PLUGIN_HANDLE)->xchat_find_context)
-#define xchat_get_context ((XCHAT_PLUGIN_HANDLE)->xchat_get_context)
-#define xchat_get_info ((XCHAT_PLUGIN_HANDLE)->xchat_get_info)
-#define xchat_get_prefs ((XCHAT_PLUGIN_HANDLE)->xchat_get_prefs)
-#define xchat_list_get ((XCHAT_PLUGIN_HANDLE)->xchat_list_get)
-#define xchat_list_free ((XCHAT_PLUGIN_HANDLE)->xchat_list_free)
-#define xchat_list_fields ((XCHAT_PLUGIN_HANDLE)->xchat_list_fields)
-#define xchat_list_str ((XCHAT_PLUGIN_HANDLE)->xchat_list_str)
-#define xchat_list_int ((XCHAT_PLUGIN_HANDLE)->xchat_list_int)
-#define xchat_list_time ((XCHAT_PLUGIN_HANDLE)->xchat_list_time)
-#define xchat_list_next ((XCHAT_PLUGIN_HANDLE)->xchat_list_next)
-#define xchat_plugingui_add ((XCHAT_PLUGIN_HANDLE)->xchat_plugingui_add)
-#define xchat_plugingui_remove ((XCHAT_PLUGIN_HANDLE)->xchat_plugingui_remove)
-#define xchat_emit_print ((XCHAT_PLUGIN_HANDLE)->xchat_emit_print)
-#define xchat_gettext ((XCHAT_PLUGIN_HANDLE)->xchat_gettext)
-#define xchat_send_modes ((XCHAT_PLUGIN_HANDLE)->xchat_send_modes)
-#define xchat_strip ((XCHAT_PLUGIN_HANDLE)->xchat_strip)
-#define xchat_free ((XCHAT_PLUGIN_HANDLE)->xchat_free)
-#endif
-
-#ifdef __cplusplus
-}
-#endif
-#endif
diff --git a/plugins/xtray/utility.cpp b/plugins/xtray/utility.cpp
index 4faed90b..66489bc0 100644
--- a/plugins/xtray/utility.cpp
+++ b/plugins/xtray/utility.cpp
@@ -20,8 +20,9 @@
 #include <stdio.h>
 #include <commctrl.h>
 #include <tchar.h>
+
+#include "xchat-plugin.h"
 #include "utility.h"
-#include "plugin.h"
 #include "xtray.h"
 #include "callbacks.h"
 #include "resource.h"
diff --git a/plugins/xtray/xchat.cpp b/plugins/xtray/xchat.cpp
index 581970f1..47ce46a9 100644
--- a/plugins/xtray/xchat.cpp
+++ b/plugins/xtray/xchat.cpp
@@ -21,7 +21,8 @@
 #include <algorithm>
 #include <stdio.h>
 #include <tchar.h>
-#include "plugin.h"
+
+#include "xchat-plugin.h"
 #include "xtray.h"
 #include "resource.h"
 #include "xchat.h"
diff --git a/plugins/xtray/xtray.cpp b/plugins/xtray/xtray.cpp
index a7c8c8bd..33ce125f 100644
--- a/plugins/xtray/xtray.cpp
+++ b/plugins/xtray/xtray.cpp
@@ -22,14 +22,14 @@
 #include <list>
 #include <string>
 #include <shobjidl.h>
+
+#include "xchat-plugin.h"
 #include "resource.h"
 #include "callbacks.h"
-#include "plugin.h"
 #include "utility.h"
 #include "xtray.h"
 #include "sdTray.h"
 #include "sdAlerts.h"
-#include "plugin.h"
 
 /*****************************************************/
 /**** Don't want to pollute the namespace do we? *****/
-- 
cgit 1.4.1


From 1567d326971811fd956042aaa43c932d247b4681 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Wed, 30 Nov 2011 08:28:19 +0100
Subject: plugin config - separate string and int functions

---
 plugins/xchat-plugin.h    | 27 +++++++++++++++++++++------
 src/common/plugin.c       | 26 ++++++++++++++++++++++----
 src/common/plugin.h       | 12 ++++++++----
 src/common/xchat-plugin.h | 27 +++++++++++++++++++++------
 4 files changed, 72 insertions(+), 20 deletions(-)

(limited to 'plugins')

diff --git a/plugins/xchat-plugin.h b/plugins/xchat-plugin.h
index c3606b19..c278012a 100644
--- a/plugins/xchat-plugin.h
+++ b/plugins/xchat-plugin.h
@@ -137,12 +137,17 @@ struct _xchat_plugin
 	     int flags);
 	void (*xchat_free) (xchat_plugin *ph,
 	    void *ptr);
-	int (*xchat_set_plugin_pref) (xchat_plugin *ph,
+	int (*xchat_set_plugin_pref_str) (xchat_plugin *ph,
 		char *var,
 		char *value);
-	int (*xchat_get_plugin_pref) (xchat_plugin *ph,
+	int (*xchat_get_plugin_pref_str) (xchat_plugin *ph,
 		char *var,
 		char *dest);
+	int (*xchat_set_plugin_pref_int) (xchat_plugin *ph,
+		char *var,
+		int value);
+	int (*xchat_get_plugin_pref_int) (xchat_plugin *ph,
+		char *var);
 };
 #endif
 
@@ -299,15 +304,23 @@ xchat_free (xchat_plugin *ph,
 	    void *ptr);
 
 int
-xchat_set_plugin_pref (xchat_plugin *ph,
+xchat_set_plugin_pref_str (xchat_plugin *ph,
 		char *var,
 		char *value);
 
 int
-xchat_get_plugin_pref (xchat_plugin *ph,
+xchat_get_plugin_pref_str (xchat_plugin *ph,
 		char *var,
 		char *dest);
 
+int
+xchat_set_plugin_pref_int (xchat_plugin *ph,
+		char *var,
+		int value);
+int
+xchat_get_plugin_pref_int (xchat_plugin *ph,
+		char *var);
+
 #if !defined(PLUGIN_C) && defined(WIN32)
 #ifndef XCHAT_PLUGIN_HANDLE
 #define XCHAT_PLUGIN_HANDLE (ph)
@@ -342,8 +355,10 @@ xchat_get_plugin_pref (xchat_plugin *ph,
 #define xchat_send_modes ((XCHAT_PLUGIN_HANDLE)->xchat_send_modes)
 #define xchat_strip ((XCHAT_PLUGIN_HANDLE)->xchat_strip)
 #define xchat_free ((XCHAT_PLUGIN_HANDLE)->xchat_free)
-#define xchat_set_plugin_pref ((XCHAT_PLUGIN_HANDLE)->xchat_set_plugin_pref)
-#define xchat_get_plugin_pref ((XCHAT_PLUGIN_HANDLE)->xchat_get_plugin_pref)
+#define xchat_set_plugin_pref_str ((XCHAT_PLUGIN_HANDLE)->xchat_set_plugin_pref_str)
+#define xchat_get_plugin_pref_str ((XCHAT_PLUGIN_HANDLE)->xchat_get_plugin_pref_str)
+#define xchat_set_plugin_pref_int ((XCHAT_PLUGIN_HANDLE)->xchat_set_plugin_pref_int)
+#define xchat_get_plugin_pref_int ((XCHAT_PLUGIN_HANDLE)->xchat_get_plugin_pref_int)
 #endif
 
 #ifdef __cplusplus
diff --git a/src/common/plugin.c b/src/common/plugin.c
index 41690038..bd960ea5 100644
--- a/src/common/plugin.c
+++ b/src/common/plugin.c
@@ -270,8 +270,10 @@ plugin_add (session *sess, char *filename, void *handle, void *init_func,
 		pl->xchat_send_modes = xchat_send_modes;
 		pl->xchat_strip = xchat_strip;
 		pl->xchat_free = xchat_free;
-		pl->xchat_set_plugin_pref = xchat_set_plugin_pref;
-		pl->xchat_get_plugin_pref = xchat_get_plugin_pref;
+		pl->xchat_set_plugin_pref_str = xchat_set_plugin_pref_str;
+		pl->xchat_get_plugin_pref_str = xchat_get_plugin_pref_str;
+		pl->xchat_set_plugin_pref_int = xchat_set_plugin_pref_int;
+		pl->xchat_get_plugin_pref_int= xchat_get_plugin_pref_int;
 
 		/* incase new plugins are loaded on older xchat */
 		pl->xchat_dummy4 = xchat_dummy;
@@ -1582,7 +1584,7 @@ xchat_free (xchat_plugin *ph, void *ptr)
 }
 
 int
-xchat_set_plugin_pref (xchat_plugin *pl, char *var, char *value)
+xchat_set_plugin_pref_str (xchat_plugin *pl, char *var, char *value)
 {
 	FILE *fpIn;
 	int fhOut;
@@ -1678,7 +1680,7 @@ xchat_set_plugin_pref (xchat_plugin *pl, char *var, char *value)
 }
 
 int
-xchat_get_plugin_pref (xchat_plugin *pl, char *var, char *dest)
+xchat_get_plugin_pref_str (xchat_plugin *pl, char *var, char *dest)
 {
 	int fh;
 	int l;
@@ -1728,3 +1730,19 @@ xchat_get_plugin_pref (xchat_plugin *pl, char *var, char *dest)
 	close (fh);
 	return 1;
 }
+
+int
+xchat_set_plugin_pref_int (xchat_plugin *pl, char *var, int value)
+{
+	char buffer[12];
+	sprintf (buffer, "%d", value);
+	return xchat_set_plugin_pref_str (pl, var, buffer);
+}
+
+int
+xchat_get_plugin_pref_int (xchat_plugin *pl, char *var)
+{
+	char buffer[12];
+	xchat_get_plugin_pref_str (pl, var, buffer);
+	return atoi (buffer);
+}
diff --git a/src/common/plugin.h b/src/common/plugin.h
index 6a2d62e2..f0ae6fc4 100644
--- a/src/common/plugin.h
+++ b/src/common/plugin.h
@@ -98,13 +98,17 @@ struct _xchat_plugin
 	     int flags);
 	void (*xchat_free) (xchat_plugin *ph,
 	    void *ptr);
-	int (*xchat_set_plugin_pref) (xchat_plugin *ph,
+	int (*xchat_set_plugin_pref_str) (xchat_plugin *ph,
 		char *var,
 		char *value);
-	int (*xchat_get_plugin_pref) (xchat_plugin *ph,
+	int (*xchat_get_plugin_pref_str) (xchat_plugin *ph,
 		char *var,
-		char *dest,
-		int dest_len);
+		char *dest);
+	int (*xchat_set_plugin_pref_int) (xchat_plugin *ph,
+		char *var,
+		int value);
+	int (*xchat_get_plugin_pref_int) (xchat_plugin *ph,
+		char *var);
 	void *(*xchat_dummy4) (xchat_plugin *ph);
 	void *(*xchat_dummy3) (xchat_plugin *ph);
 	void *(*xchat_dummy2) (xchat_plugin *ph);
diff --git a/src/common/xchat-plugin.h b/src/common/xchat-plugin.h
index c3606b19..c278012a 100644
--- a/src/common/xchat-plugin.h
+++ b/src/common/xchat-plugin.h
@@ -137,12 +137,17 @@ struct _xchat_plugin
 	     int flags);
 	void (*xchat_free) (xchat_plugin *ph,
 	    void *ptr);
-	int (*xchat_set_plugin_pref) (xchat_plugin *ph,
+	int (*xchat_set_plugin_pref_str) (xchat_plugin *ph,
 		char *var,
 		char *value);
-	int (*xchat_get_plugin_pref) (xchat_plugin *ph,
+	int (*xchat_get_plugin_pref_str) (xchat_plugin *ph,
 		char *var,
 		char *dest);
+	int (*xchat_set_plugin_pref_int) (xchat_plugin *ph,
+		char *var,
+		int value);
+	int (*xchat_get_plugin_pref_int) (xchat_plugin *ph,
+		char *var);
 };
 #endif
 
@@ -299,15 +304,23 @@ xchat_free (xchat_plugin *ph,
 	    void *ptr);
 
 int
-xchat_set_plugin_pref (xchat_plugin *ph,
+xchat_set_plugin_pref_str (xchat_plugin *ph,
 		char *var,
 		char *value);
 
 int
-xchat_get_plugin_pref (xchat_plugin *ph,
+xchat_get_plugin_pref_str (xchat_plugin *ph,
 		char *var,
 		char *dest);
 
+int
+xchat_set_plugin_pref_int (xchat_plugin *ph,
+		char *var,
+		int value);
+int
+xchat_get_plugin_pref_int (xchat_plugin *ph,
+		char *var);
+
 #if !defined(PLUGIN_C) && defined(WIN32)
 #ifndef XCHAT_PLUGIN_HANDLE
 #define XCHAT_PLUGIN_HANDLE (ph)
@@ -342,8 +355,10 @@ xchat_get_plugin_pref (xchat_plugin *ph,
 #define xchat_send_modes ((XCHAT_PLUGIN_HANDLE)->xchat_send_modes)
 #define xchat_strip ((XCHAT_PLUGIN_HANDLE)->xchat_strip)
 #define xchat_free ((XCHAT_PLUGIN_HANDLE)->xchat_free)
-#define xchat_set_plugin_pref ((XCHAT_PLUGIN_HANDLE)->xchat_set_plugin_pref)
-#define xchat_get_plugin_pref ((XCHAT_PLUGIN_HANDLE)->xchat_get_plugin_pref)
+#define xchat_set_plugin_pref_str ((XCHAT_PLUGIN_HANDLE)->xchat_set_plugin_pref_str)
+#define xchat_get_plugin_pref_str ((XCHAT_PLUGIN_HANDLE)->xchat_get_plugin_pref_str)
+#define xchat_set_plugin_pref_int ((XCHAT_PLUGIN_HANDLE)->xchat_set_plugin_pref_int)
+#define xchat_get_plugin_pref_int ((XCHAT_PLUGIN_HANDLE)->xchat_get_plugin_pref_int)
 #endif
 
 #ifdef __cplusplus
-- 
cgit 1.4.1


From b692172aa907243c7543015468da0fb077a9ac99 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Wed, 30 Nov 2011 08:59:40 +0100
Subject: refactoring

---
 plugins/xchat-plugin.h    | 24 ++++++++++++------------
 src/common/plugin.c       | 20 ++++++++++----------
 src/common/plugin.h       |  8 ++++----
 src/common/xchat-plugin.h | 24 ++++++++++++------------
 src/version-script        |  8 ++++----
 5 files changed, 42 insertions(+), 42 deletions(-)

(limited to 'plugins')

diff --git a/plugins/xchat-plugin.h b/plugins/xchat-plugin.h
index c278012a..48e3bc02 100644
--- a/plugins/xchat-plugin.h
+++ b/plugins/xchat-plugin.h
@@ -137,16 +137,16 @@ struct _xchat_plugin
 	     int flags);
 	void (*xchat_free) (xchat_plugin *ph,
 	    void *ptr);
-	int (*xchat_set_plugin_pref_str) (xchat_plugin *ph,
+	int (*xchat_set_pluginpref_str) (xchat_plugin *ph,
 		char *var,
 		char *value);
-	int (*xchat_get_plugin_pref_str) (xchat_plugin *ph,
+	int (*xchat_get_pluginpref_str) (xchat_plugin *ph,
 		char *var,
 		char *dest);
-	int (*xchat_set_plugin_pref_int) (xchat_plugin *ph,
+	int (*xchat_set_pluginpref_int) (xchat_plugin *ph,
 		char *var,
 		int value);
-	int (*xchat_get_plugin_pref_int) (xchat_plugin *ph,
+	int (*xchat_get_pluginpref_int) (xchat_plugin *ph,
 		char *var);
 };
 #endif
@@ -304,21 +304,21 @@ xchat_free (xchat_plugin *ph,
 	    void *ptr);
 
 int
-xchat_set_plugin_pref_str (xchat_plugin *ph,
+xchat_set_pluginpref_str (xchat_plugin *ph,
 		char *var,
 		char *value);
 
 int
-xchat_get_plugin_pref_str (xchat_plugin *ph,
+xchat_get_pluginpref_str (xchat_plugin *ph,
 		char *var,
 		char *dest);
 
 int
-xchat_set_plugin_pref_int (xchat_plugin *ph,
+xchat_set_pluginpref_int (xchat_plugin *ph,
 		char *var,
 		int value);
 int
-xchat_get_plugin_pref_int (xchat_plugin *ph,
+xchat_get_pluginpref_int (xchat_plugin *ph,
 		char *var);
 
 #if !defined(PLUGIN_C) && defined(WIN32)
@@ -355,10 +355,10 @@ xchat_get_plugin_pref_int (xchat_plugin *ph,
 #define xchat_send_modes ((XCHAT_PLUGIN_HANDLE)->xchat_send_modes)
 #define xchat_strip ((XCHAT_PLUGIN_HANDLE)->xchat_strip)
 #define xchat_free ((XCHAT_PLUGIN_HANDLE)->xchat_free)
-#define xchat_set_plugin_pref_str ((XCHAT_PLUGIN_HANDLE)->xchat_set_plugin_pref_str)
-#define xchat_get_plugin_pref_str ((XCHAT_PLUGIN_HANDLE)->xchat_get_plugin_pref_str)
-#define xchat_set_plugin_pref_int ((XCHAT_PLUGIN_HANDLE)->xchat_set_plugin_pref_int)
-#define xchat_get_plugin_pref_int ((XCHAT_PLUGIN_HANDLE)->xchat_get_plugin_pref_int)
+#define xchat_set_pluginpref_str ((XCHAT_PLUGIN_HANDLE)->xchat_set_pluginpref_str)
+#define xchat_get_pluginpref_str ((XCHAT_PLUGIN_HANDLE)->xchat_get_pluginpref_str)
+#define xchat_set_pluginpref_int ((XCHAT_PLUGIN_HANDLE)->xchat_set_pluginpref_int)
+#define xchat_get_pluginpref_int ((XCHAT_PLUGIN_HANDLE)->xchat_get_pluginpref_int)
 #endif
 
 #ifdef __cplusplus
diff --git a/src/common/plugin.c b/src/common/plugin.c
index d1493ccd..b5b10a0e 100644
--- a/src/common/plugin.c
+++ b/src/common/plugin.c
@@ -270,10 +270,10 @@ plugin_add (session *sess, char *filename, void *handle, void *init_func,
 		pl->xchat_send_modes = xchat_send_modes;
 		pl->xchat_strip = xchat_strip;
 		pl->xchat_free = xchat_free;
-		pl->xchat_set_plugin_pref_str = xchat_set_plugin_pref_str;
-		pl->xchat_get_plugin_pref_str = xchat_get_plugin_pref_str;
-		pl->xchat_set_plugin_pref_int = xchat_set_plugin_pref_int;
-		pl->xchat_get_plugin_pref_int = xchat_get_plugin_pref_int;
+		pl->xchat_set_pluginpref_str = xchat_set_pluginpref_str;
+		pl->xchat_get_pluginpref_str = xchat_get_pluginpref_str;
+		pl->xchat_set_pluginpref_int = xchat_set_pluginpref_int;
+		pl->xchat_get_pluginpref_int = xchat_get_pluginpref_int;
 
 		/* incase new plugins are loaded on older xchat */
 		pl->xchat_dummy4 = xchat_dummy;
@@ -1584,7 +1584,7 @@ xchat_free (xchat_plugin *ph, void *ptr)
 }
 
 int
-xchat_set_plugin_pref_str (xchat_plugin *pl, char *var, char *value)
+xchat_set_pluginpref_str (xchat_plugin *pl, char *var, char *value)
 {
 	FILE *fpIn;
 	int fhOut;
@@ -1680,7 +1680,7 @@ xchat_set_plugin_pref_str (xchat_plugin *pl, char *var, char *value)
 }
 
 int
-xchat_get_plugin_pref_str (xchat_plugin *pl, char *var, char *dest)
+xchat_get_pluginpref_str (xchat_plugin *pl, char *var, char *dest)
 {
 	int fh;
 	int l;
@@ -1732,20 +1732,20 @@ xchat_get_plugin_pref_str (xchat_plugin *pl, char *var, char *dest)
 }
 
 int
-xchat_set_plugin_pref_int (xchat_plugin *pl, char *var, int value)
+xchat_set_pluginpref_int (xchat_plugin *pl, char *var, int value)
 {
 	char buffer[12];
 
 	sprintf (buffer, "%d", value);
-	return xchat_set_plugin_pref_str (pl, var, buffer);
+	return xchat_set_pluginpref_str (pl, var, buffer);
 }
 
 int
-xchat_get_plugin_pref_int (xchat_plugin *pl, char *var)
+xchat_get_pluginpref_int (xchat_plugin *pl, char *var)
 {
 	char buffer[12];
 
-	if (xchat_get_plugin_pref_str (pl, var, buffer))
+	if (xchat_get_pluginpref_str (pl, var, buffer))
 	{
 		return atoi (buffer);
 	}
diff --git a/src/common/plugin.h b/src/common/plugin.h
index f0ae6fc4..858ed815 100644
--- a/src/common/plugin.h
+++ b/src/common/plugin.h
@@ -98,16 +98,16 @@ struct _xchat_plugin
 	     int flags);
 	void (*xchat_free) (xchat_plugin *ph,
 	    void *ptr);
-	int (*xchat_set_plugin_pref_str) (xchat_plugin *ph,
+	int (*xchat_set_pluginpref_str) (xchat_plugin *ph,
 		char *var,
 		char *value);
-	int (*xchat_get_plugin_pref_str) (xchat_plugin *ph,
+	int (*xchat_get_pluginpref_str) (xchat_plugin *ph,
 		char *var,
 		char *dest);
-	int (*xchat_set_plugin_pref_int) (xchat_plugin *ph,
+	int (*xchat_set_pluginpref_int) (xchat_plugin *ph,
 		char *var,
 		int value);
-	int (*xchat_get_plugin_pref_int) (xchat_plugin *ph,
+	int (*xchat_get_pluginpref_int) (xchat_plugin *ph,
 		char *var);
 	void *(*xchat_dummy4) (xchat_plugin *ph);
 	void *(*xchat_dummy3) (xchat_plugin *ph);
diff --git a/src/common/xchat-plugin.h b/src/common/xchat-plugin.h
index c278012a..48e3bc02 100644
--- a/src/common/xchat-plugin.h
+++ b/src/common/xchat-plugin.h
@@ -137,16 +137,16 @@ struct _xchat_plugin
 	     int flags);
 	void (*xchat_free) (xchat_plugin *ph,
 	    void *ptr);
-	int (*xchat_set_plugin_pref_str) (xchat_plugin *ph,
+	int (*xchat_set_pluginpref_str) (xchat_plugin *ph,
 		char *var,
 		char *value);
-	int (*xchat_get_plugin_pref_str) (xchat_plugin *ph,
+	int (*xchat_get_pluginpref_str) (xchat_plugin *ph,
 		char *var,
 		char *dest);
-	int (*xchat_set_plugin_pref_int) (xchat_plugin *ph,
+	int (*xchat_set_pluginpref_int) (xchat_plugin *ph,
 		char *var,
 		int value);
-	int (*xchat_get_plugin_pref_int) (xchat_plugin *ph,
+	int (*xchat_get_pluginpref_int) (xchat_plugin *ph,
 		char *var);
 };
 #endif
@@ -304,21 +304,21 @@ xchat_free (xchat_plugin *ph,
 	    void *ptr);
 
 int
-xchat_set_plugin_pref_str (xchat_plugin *ph,
+xchat_set_pluginpref_str (xchat_plugin *ph,
 		char *var,
 		char *value);
 
 int
-xchat_get_plugin_pref_str (xchat_plugin *ph,
+xchat_get_pluginpref_str (xchat_plugin *ph,
 		char *var,
 		char *dest);
 
 int
-xchat_set_plugin_pref_int (xchat_plugin *ph,
+xchat_set_pluginpref_int (xchat_plugin *ph,
 		char *var,
 		int value);
 int
-xchat_get_plugin_pref_int (xchat_plugin *ph,
+xchat_get_pluginpref_int (xchat_plugin *ph,
 		char *var);
 
 #if !defined(PLUGIN_C) && defined(WIN32)
@@ -355,10 +355,10 @@ xchat_get_plugin_pref_int (xchat_plugin *ph,
 #define xchat_send_modes ((XCHAT_PLUGIN_HANDLE)->xchat_send_modes)
 #define xchat_strip ((XCHAT_PLUGIN_HANDLE)->xchat_strip)
 #define xchat_free ((XCHAT_PLUGIN_HANDLE)->xchat_free)
-#define xchat_set_plugin_pref_str ((XCHAT_PLUGIN_HANDLE)->xchat_set_plugin_pref_str)
-#define xchat_get_plugin_pref_str ((XCHAT_PLUGIN_HANDLE)->xchat_get_plugin_pref_str)
-#define xchat_set_plugin_pref_int ((XCHAT_PLUGIN_HANDLE)->xchat_set_plugin_pref_int)
-#define xchat_get_plugin_pref_int ((XCHAT_PLUGIN_HANDLE)->xchat_get_plugin_pref_int)
+#define xchat_set_pluginpref_str ((XCHAT_PLUGIN_HANDLE)->xchat_set_pluginpref_str)
+#define xchat_get_pluginpref_str ((XCHAT_PLUGIN_HANDLE)->xchat_get_pluginpref_str)
+#define xchat_set_pluginpref_int ((XCHAT_PLUGIN_HANDLE)->xchat_set_pluginpref_int)
+#define xchat_get_pluginpref_int ((XCHAT_PLUGIN_HANDLE)->xchat_get_pluginpref_int)
 #endif
 
 #ifdef __cplusplus
diff --git a/src/version-script b/src/version-script
index 94a95a0b..e76f4fe9 100644
--- a/src/version-script
+++ b/src/version-script
@@ -30,9 +30,9 @@ EXPORTED {
 		xchat_send_modes;
 		xchat_strip;
 		xchat_free;
-		xchat_set_plugin_pref_str;
-		xchat_get_plugin_pref_str;
-		xchat_set_plugin_pref_int;
-		xchat_get_plugin_pref_int;
+		xchat_set_pluginpref_str;
+		xchat_get_pluginpref_str;
+		xchat_set_pluginpref_int;
+		xchat_get_pluginpref_int;
 	local: *;
 };
-- 
cgit 1.4.1


From 455032938a9d5336e55684692113fbca8a156810 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Thu, 1 Dec 2011 21:24:58 +0100
Subject: plugin api conformance

---
 plugins/xchat-plugin.h    | 20 ++++++++++----------
 src/common/plugin.c       | 10 +++++-----
 src/common/plugin.h       | 10 +++++-----
 src/common/xchat-plugin.h | 20 ++++++++++----------
 4 files changed, 30 insertions(+), 30 deletions(-)

(limited to 'plugins')

diff --git a/plugins/xchat-plugin.h b/plugins/xchat-plugin.h
index 48e3bc02..15799424 100644
--- a/plugins/xchat-plugin.h
+++ b/plugins/xchat-plugin.h
@@ -138,16 +138,16 @@ struct _xchat_plugin
 	void (*xchat_free) (xchat_plugin *ph,
 	    void *ptr);
 	int (*xchat_set_pluginpref_str) (xchat_plugin *ph,
-		char *var,
-		char *value);
+		const char *var,
+		const char *value);
 	int (*xchat_get_pluginpref_str) (xchat_plugin *ph,
-		char *var,
+		const char *var,
 		char *dest);
 	int (*xchat_set_pluginpref_int) (xchat_plugin *ph,
-		char *var,
+		const char *var,
 		int value);
 	int (*xchat_get_pluginpref_int) (xchat_plugin *ph,
-		char *var);
+		const char *var);
 };
 #endif
 
@@ -305,21 +305,21 @@ xchat_free (xchat_plugin *ph,
 
 int
 xchat_set_pluginpref_str (xchat_plugin *ph,
-		char *var,
-		char *value);
+		const char *var,
+		const char *value);
 
 int
 xchat_get_pluginpref_str (xchat_plugin *ph,
-		char *var,
+		const char *var,
 		char *dest);
 
 int
 xchat_set_pluginpref_int (xchat_plugin *ph,
-		char *var,
+		const char *var,
 		int value);
 int
 xchat_get_pluginpref_int (xchat_plugin *ph,
-		char *var);
+		const char *var);
 
 #if !defined(PLUGIN_C) && defined(WIN32)
 #ifndef XCHAT_PLUGIN_HANDLE
diff --git a/src/common/plugin.c b/src/common/plugin.c
index b5b10a0e..b443b586 100644
--- a/src/common/plugin.c
+++ b/src/common/plugin.c
@@ -1584,7 +1584,7 @@ xchat_free (xchat_plugin *ph, void *ptr)
 }
 
 int
-xchat_set_pluginpref_str (xchat_plugin *pl, char *var, char *value)
+xchat_set_pluginpref_str (xchat_plugin *pl, const char *var, const char *value)
 {
 	FILE *fpIn;
 	int fhOut;
@@ -1653,7 +1653,7 @@ xchat_set_pluginpref_str (xchat_plugin *pl, char *var, char *value)
 
 		fclose (fpIn);
 
-		if (!prevConfig)
+		if (!prevConfig)	/* var doesn't exist currently, append */
 		{
 			sprintf (buffer, "%s = %s\n", var, value);
 			write (fhOut, buffer, strlen (buffer));
@@ -1680,7 +1680,7 @@ xchat_set_pluginpref_str (xchat_plugin *pl, char *var, char *value)
 }
 
 int
-xchat_get_pluginpref_str (xchat_plugin *pl, char *var, char *dest)
+xchat_get_pluginpref_str (xchat_plugin *pl, const char *var, char *dest)
 {
 	int fh;
 	int l;
@@ -1732,7 +1732,7 @@ xchat_get_pluginpref_str (xchat_plugin *pl, char *var, char *dest)
 }
 
 int
-xchat_set_pluginpref_int (xchat_plugin *pl, char *var, int value)
+xchat_set_pluginpref_int (xchat_plugin *pl, const char *var, int value)
 {
 	char buffer[12];
 
@@ -1741,7 +1741,7 @@ xchat_set_pluginpref_int (xchat_plugin *pl, char *var, int value)
 }
 
 int
-xchat_get_pluginpref_int (xchat_plugin *pl, char *var)
+xchat_get_pluginpref_int (xchat_plugin *pl, const char *var)
 {
 	char buffer[12];
 
diff --git a/src/common/plugin.h b/src/common/plugin.h
index 858ed815..cddb86fb 100644
--- a/src/common/plugin.h
+++ b/src/common/plugin.h
@@ -99,16 +99,16 @@ struct _xchat_plugin
 	void (*xchat_free) (xchat_plugin *ph,
 	    void *ptr);
 	int (*xchat_set_pluginpref_str) (xchat_plugin *ph,
-		char *var,
-		char *value);
+		const char *var,
+		const char *value);
 	int (*xchat_get_pluginpref_str) (xchat_plugin *ph,
-		char *var,
+		const char *var,
 		char *dest);
 	int (*xchat_set_pluginpref_int) (xchat_plugin *ph,
-		char *var,
+		const char *var,
 		int value);
 	int (*xchat_get_pluginpref_int) (xchat_plugin *ph,
-		char *var);
+		const char *var);
 	void *(*xchat_dummy4) (xchat_plugin *ph);
 	void *(*xchat_dummy3) (xchat_plugin *ph);
 	void *(*xchat_dummy2) (xchat_plugin *ph);
diff --git a/src/common/xchat-plugin.h b/src/common/xchat-plugin.h
index 48e3bc02..15799424 100644
--- a/src/common/xchat-plugin.h
+++ b/src/common/xchat-plugin.h
@@ -138,16 +138,16 @@ struct _xchat_plugin
 	void (*xchat_free) (xchat_plugin *ph,
 	    void *ptr);
 	int (*xchat_set_pluginpref_str) (xchat_plugin *ph,
-		char *var,
-		char *value);
+		const char *var,
+		const char *value);
 	int (*xchat_get_pluginpref_str) (xchat_plugin *ph,
-		char *var,
+		const char *var,
 		char *dest);
 	int (*xchat_set_pluginpref_int) (xchat_plugin *ph,
-		char *var,
+		const char *var,
 		int value);
 	int (*xchat_get_pluginpref_int) (xchat_plugin *ph,
-		char *var);
+		const char *var);
 };
 #endif
 
@@ -305,21 +305,21 @@ xchat_free (xchat_plugin *ph,
 
 int
 xchat_set_pluginpref_str (xchat_plugin *ph,
-		char *var,
-		char *value);
+		const char *var,
+		const char *value);
 
 int
 xchat_get_pluginpref_str (xchat_plugin *ph,
-		char *var,
+		const char *var,
 		char *dest);
 
 int
 xchat_set_pluginpref_int (xchat_plugin *ph,
-		char *var,
+		const char *var,
 		int value);
 int
 xchat_get_pluginpref_int (xchat_plugin *ph,
-		char *var);
+		const char *var);
 
 #if !defined(PLUGIN_C) && defined(WIN32)
 #ifndef XCHAT_PLUGIN_HANDLE
-- 
cgit 1.4.1


From e2f7e4f091465f8f6d9fbcbf320b470e0e32e6c1 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Thu, 1 Dec 2011 23:01:52 +0100
Subject: speed up winsys executions

---
 plugins/winsys/winsys.cpp | 29 ++++++++++++++++++++++-------
 1 file changed, 22 insertions(+), 7 deletions(-)

(limited to 'plugins')

diff --git a/plugins/winsys/winsys.cpp b/plugins/winsys/winsys.cpp
index f8d74e2b..2f68f75b 100644
--- a/plugins/winsys/winsys.cpp
+++ b/plugins/winsys/winsys.cpp
@@ -28,6 +28,10 @@
 #include "xchat-plugin.h"
 
 static xchat_plugin *ph;   /* plugin handle */
+static int firstRun;
+static char *wmiOs;
+static char *wmiCpu;
+static char *wmiVga;
 
 static int
 getCpuArch (void)
@@ -230,7 +234,7 @@ getWmiInfo (int mode)
 	http://social.msdn.microsoft.com/forums/en-US/vcgeneral/thread/d6420012-e432-4964-8506-6f6b65e5a451
 	*/
 
-	static char buffer[128];
+	char *buffer = (char *) malloc (128);
 	HRESULT hres;
 	HRESULT hr;
 	IWbemLocator *pLoc = NULL;
@@ -345,25 +349,34 @@ getWmiInfo (int mode)
 static int
 printInfo (char *word[], char *word_eol[], void *user_data)
 {
+	/* query WMI info only at the first time WinSys is called, then cache it to save time */
+	if (firstRun)
+	{
+		xchat_printf (ph, "WinSys first execution, querying and caching WMI info...\n");
+		wmiOs = getWmiInfo (0);
+		wmiCpu = getWmiInfo (1);
+		wmiVga = getWmiInfo (2);
+		firstRun = 0;
+	}
 	if (xchat_list_int (ph, NULL, "type") >= 2)
 	{
 		/* xchat_commandf (ph, "ME * WinSys - system details *");
 		xchat_commandf (ph, "ME ***************************"); */
 		xchat_commandf (ph, "ME * Client:  XChat-WDK %s (x%d)", xchat_get_info (ph, "wdk_version"), getCpuArch ());
-		xchat_commandf (ph, "ME * OS:      %s", getWmiInfo (0));
-		xchat_commandf (ph, "ME * CPU:     %s (%s)", getWmiInfo (1), getCpuMhz ());
+		xchat_commandf (ph, "ME * OS:      %s", wmiOs);
+		xchat_commandf (ph, "ME * CPU:     %s (%s)", wmiCpu, getCpuMhz ());
 		xchat_commandf (ph, "ME * RAM:     %s", getMemoryInfo ());
-		xchat_commandf (ph, "ME * VGA:     %s", getWmiInfo (2));
+		xchat_commandf (ph, "ME * VGA:     %s", wmiVga);
 		/* will work correctly for up to 50 days, should be enough */
 		xchat_commandf (ph, "ME * Uptime:  %.2f Hours", (float) GetTickCount() / 1000 / 60 / 60);
 	}
 	else
 	{
 		xchat_printf (ph, " * Client:  XChat-WDK %s (x%d)\n", xchat_get_info (ph, "wdk_version"), getCpuArch ());
-		xchat_printf (ph, " * OS:      %s\n", getWmiInfo (0));
-		xchat_printf (ph, " * CPU:     %s (%s)\n", getWmiInfo (1), getCpuMhz ());
+		xchat_printf (ph, " * OS:      %s\n", wmiOs);
+		xchat_printf (ph, " * CPU:     %s (%s)\n", wmiCpu, getCpuMhz ());
 		xchat_printf (ph, " * RAM:     %s\n", getMemoryInfo ());
-		xchat_printf (ph, " * VGA:     %s\n", getWmiInfo (2));
+		xchat_printf (ph, " * VGA:     %s\n", wmiVga);
 		xchat_printf (ph, " * Uptime:  %.2f Hours\n", (float) GetTickCount() / 1000 / 60 / 60);
 	}
 
@@ -379,6 +392,8 @@ xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugi
 	*plugin_desc = "Display info about your hardware and OS";
 	*plugin_version = "1.0";
 
+	firstRun = 1;
+
 	xchat_hook_command (ph, "WINSYS", XCHAT_PRI_NORM, printInfo, NULL, NULL);
 	xchat_command (ph, "MENU -ietc\\system.png ADD \"Window/Display System Info\" \"WINSYS\"");
 
-- 
cgit 1.4.1


From 0f9c35e214a7d047286b0d2ae69fcd60b223b9d4 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Fri, 2 Dec 2011 00:43:12 +0100
Subject: add documentation for plugin config framework

---
 plugins/plugin20.html | 85 +++++++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 85 insertions(+)

(limited to 'plugins')

diff --git a/plugins/plugin20.html b/plugins/plugin20.html
index 787c048b..b36490ba 100644
--- a/plugins/plugin20.html
+++ b/plugins/plugin20.html
@@ -81,6 +81,11 @@ margin-right: 32px;
 <br><a href="#xchat_strip">xchat_strip</a>
 <br><a href="#xchat_free">xchat_free</a>
 <br>
+<br><a href="#xchat_set_pluginpref_str">xchat_set_pluginpref_str</a>
+<br><a href="#xchat_get_pluginpref_str">xchat_get_pluginpref_str</a>
+<br><a href="#xchat_set_pluginpref_int">xchat_set_pluginpref_int</a>
+<br><a href="#xchat_get_pluginpref_int">xchat_get_pluginpref_int</a>
+<br>
 <br><a href="#lists">xchat_list_get</a>
 <br><a href="#lists">xchat_list_free</a>
 <br><a href="#lists">xchat_list_fields</a> (not documented yet)
@@ -998,5 +1003,85 @@ A newly allocated string or NULL for failure. You must free this string with xch
 
 <br><br>
 
+<h3><a class=cmd name="xchat_set_pluginpref_str">&nbsp;xchat_set_pluginpref_str()&nbsp;</a><small>(new for 2.8.10)</small></h3>
+<b>Prototype:</b> int xchat_set_pluginpref_str (xchat_plugin *ph, const char *var, const char *value);
+<br>
+<br><b>Description:</b> Saves a plugin-specific setting with string value to a plugin-specific config file.
+<br>
+<br><b>Arguments:</b>
+<blockquote><b>ph:</b> Plugin handle (as given to xchat_plugin_init).
+<br><b>var:</b> Name of the setting to save.
+<br><b>value:</b> String value of the the setting.
+<br>
+</blockquote>
+<b>Returns:</b> 1 for success, 0 for failure.
+<br><br><b>Example:</b>
+<blockquote>
+<pre>int xchat_plugin_init (xchat_plugin *plugin_handle,
+			char **plugin_name,
+			char **plugin_desc,
+			char **plugin_version,
+			char *arg)
+{
+	ph = plugin_handle;
+	*plugin_name = "Tester Thingie";
+	*plugin_desc = "Testing stuff";
+	*plugin_version = "1.0";
+
+	xchat_set_pluginpref_str (ph, "myvar1", "I want to save this string!");
+	xchat_set_pluginpref_str (ph, "myvar2", "This is important, too.");
+
+	return 1;       /* return 1 for success */
+}</pre>
+</blockquote>
+In the example above, the settings will be saved to the plugin_tester_thingie.conf file, and its content will be:
+<blockquote>
+<pre>myvar1 = I want to save this string!
+myvar2 = This is important, too.</pre>
+</blockquote>
+You should never need to edit this file manually.
+<br><br><br>
+
+<h3><a class=cmd name="xchat_get_pluginpref_str">&nbsp;xchat_get_pluginpref_str()&nbsp;</a><small>(new for 2.8.10)</small></h3>
+<b>Prototype:</b> int xchat_get_pluginpref_str (xchat_plugin *ph, const char *var, char *dest);
+<br>
+<br><b>Description:</b> Loads a plugin-specific setting with string value from a plugin-specific config file.
+<br>
+<br><b>Arguments:</b>
+<blockquote><b>ph:</b> Plugin handle (as given to xchat_plugin_init).
+<br><b>var:</b> Name of the setting to load.
+<br><b>dest:</b> Array to save the loaded setting's string value to.
+<br>
+</blockquote>
+<b>Returns:</b> 1 for success, 0 for failure.
+<br><br><br>
+
+<h3><a class=cmd name="xchat_set_pluginpref_int">&nbsp;xchat_set_pluginpref_int()&nbsp;</a><small>(new for 2.8.10)</small></h3>
+<b>Prototype:</b> int xchat_set_pluginpref_int (xchat_plugin *ph, const char *var, int value);
+<br>
+<br><b>Description:</b> Saves a plugin-specific setting with decimal value to a plugin-specific config file.
+<br>
+<br><b>Arguments:</b>
+<blockquote><b>ph:</b> Plugin handle (as given to xchat_plugin_init).
+<br><b>var:</b> Name of the setting to save.
+<br><b>value:</b> Decimal value of the the setting.
+<br>
+</blockquote>
+<b>Returns:</b> 1 for success, 0 for failure.
+<br><br><br>
+
+<h3><a class=cmd name="xchat_get_pluginpref_int">&nbsp;xchat_get_pluginpref_int()&nbsp;</a><small>(new for 2.8.10)</small></h3>
+<b>Prototype:</b> int xchat_get_pluginpref_int (xchat_plugin *ph, const char *var);
+<br>
+<br><b>Description:</b> Loads a plugin-specific setting with decimal value from a plugin-specific config file.
+<br>
+<br><b>Arguments:</b>
+<blockquote><b>ph:</b> Plugin handle (as given to xchat_plugin_init).
+<br><b>var:</b> Name of the setting to load.
+<br>
+</blockquote>
+<b>Returns:</b> The decimal value of the requested setting upon success, -1 for failure.
+<br><br><br>
+
 </body>
 </html>
-- 
cgit 1.4.1


From e2acf19d42b874eecd1b142a0e1192721fb295f5 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Fri, 2 Dec 2011 01:05:59 +0100
Subject: don't use hardcoded strings for plugin names

---
 plugins/checksum/checksum.c | 13 ++++++++-----
 plugins/exec/exec.c         | 13 ++++++++-----
 plugins/upd/upd.c           | 13 ++++++++-----
 plugins/winsys/winsys.cpp   | 15 +++++++++------
 4 files changed, 33 insertions(+), 21 deletions(-)

(limited to 'plugins')

diff --git a/plugins/checksum/checksum.c b/plugins/checksum/checksum.c
index 12fc0d93..103a80ca 100644
--- a/plugins/checksum/checksum.c
+++ b/plugins/checksum/checksum.c
@@ -42,6 +42,9 @@
 #endif
 
 static xchat_plugin *ph;									/* plugin handle */
+static const char name[] = "Checksum";
+static const char desc[] = "Calculate checksum for DCC file transfers";
+static const char version[] = "2.0";
 static int config_fail;										/* variable for config availability */
 
 /* Use of OpenSSL SHA256 interface: http://adamlamers.com/?p=5 */
@@ -324,9 +327,9 @@ xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugi
 {
 	ph = plugin_handle;
 
-	*plugin_name = "Checksum";
-	*plugin_desc = "Calculate checksum for DCC file transfers";
-	*plugin_version = "2.0";
+	*plugin_name = name;
+	*plugin_desc = desc;
+	*plugin_version = version;
 
 	init ();
 
@@ -334,13 +337,13 @@ xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugi
 	xchat_hook_print (ph, "DCC RECV Complete", XCHAT_PRI_NORM, dccrecv_cb, NULL);
 	xchat_hook_print (ph, "DCC Offer", XCHAT_PRI_NORM, dccoffer_cb, NULL);
 
-	xchat_print (ph, "Checksum plugin loaded\n");
+	xchat_printf (ph, "%s plugin loaded\n", name);
 	return 1;
 }
 
 int
 xchat_plugin_deinit (void)
 {
-	xchat_print (ph, "Checksum plugin unloaded\n");
+	xchat_printf (ph, "%s plugin unloaded\n", name);
 	return 1;
 }
diff --git a/plugins/exec/exec.c b/plugins/exec/exec.c
index b043ae83..fc8c8ec9 100644
--- a/plugins/exec/exec.c
+++ b/plugins/exec/exec.c
@@ -26,6 +26,9 @@
 #include "xchat-plugin.h"
 
 static xchat_plugin *ph;   /* plugin handle */
+static const char name[] = "Exec";
+static const char desc[] = "Execute commands inside XChat";
+static const char version[] = "1.0";
 
 static int
 run_command (char *word[], char *word_eol[], void *userdata)
@@ -107,12 +110,12 @@ xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugi
 {
 	ph = plugin_handle;
 
-	*plugin_name = "Exec";
-	*plugin_desc = "Execute commands inside XChat";
-	*plugin_version = "1.0";
+	*plugin_name = name;
+	*plugin_desc = desc;
+	*plugin_version = version;
 
 	xchat_hook_command (ph, "EXEC", XCHAT_PRI_NORM, run_command, 0, 0);
-	xchat_printf (ph, "%s plugin loaded\n", *plugin_name);
+	xchat_printf (ph, "%s plugin loaded\n", name);
 
 	return 1;       /* return 1 for success */
 }
@@ -120,6 +123,6 @@ xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugi
 int
 xchat_plugin_deinit (void)
 {
-	xchat_print (ph, "Exec plugin unloaded\n");
+	xchat_print (ph, "%s plugin unloaded\n", name);
 	return 1;
 }
diff --git a/plugins/upd/upd.c b/plugins/upd/upd.c
index 3eec06dc..7ab5edca 100644
--- a/plugins/upd/upd.c
+++ b/plugins/upd/upd.c
@@ -26,6 +26,9 @@
 #include "xchat-plugin.h"
 
 static xchat_plugin *ph;   /* plugin handle */
+static const char name[] = "Update Checker";
+static const char desc[] = "Check for XChat-WDK updates automatically";
+static const char version[] = "2.0";
 
 /* we need this to store the result of the initial update check since the return value is preserved for XCHAT_EAT */
 static int update_available;
@@ -117,14 +120,14 @@ xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugi
 {
 	ph = plugin_handle;
 
-	*plugin_name = "Update Checker";
-	*plugin_desc = "Plugin for checking for XChat-WDK updates";
-	*plugin_version = "2.0";
+	*plugin_name = name;
+	*plugin_desc = desc;
+	*plugin_version = version;
 
 	xchat_hook_command (ph, "UPDCHK", XCHAT_PRI_NORM, print_version, 0, 0);
 	xchat_command (ph, "MENU -ietc\\download.png ADD \"Help/Check for Updates\" \"UPDCHK\"");
 
-	xchat_printf (ph, "%s plugin loaded\n", *plugin_name);
+	xchat_printf (ph, "%s plugin loaded\n", name);
 
 	/* only start the timer if there's no update available during startup */
 	if (!update_available)
@@ -140,6 +143,6 @@ int
 xchat_plugin_deinit (void)
 {
 	xchat_command (ph, "MENU DEL \"Help/Check for updates\"");
-	xchat_print (ph, "Update Checker plugin unloaded\n");
+	xchat_printf (ph, "%s plugin unloaded\n", name);
 	return 1;
 }
diff --git a/plugins/winsys/winsys.cpp b/plugins/winsys/winsys.cpp
index 2f68f75b..55a5ddaf 100644
--- a/plugins/winsys/winsys.cpp
+++ b/plugins/winsys/winsys.cpp
@@ -28,6 +28,9 @@
 #include "xchat-plugin.h"
 
 static xchat_plugin *ph;   /* plugin handle */
+static const char name[] = "WinSys";
+static const char desc[] = "Display info about your hardware and OS";
+static const char version[] = "1.0";
 static int firstRun;
 static char *wmiOs;
 static char *wmiCpu;
@@ -352,7 +355,7 @@ printInfo (char *word[], char *word_eol[], void *user_data)
 	/* query WMI info only at the first time WinSys is called, then cache it to save time */
 	if (firstRun)
 	{
-		xchat_printf (ph, "WinSys first execution, querying and caching WMI info...\n");
+		xchat_printf (ph, "%s first execution, querying and caching WMI info...\n", name);
 		wmiOs = getWmiInfo (0);
 		wmiCpu = getWmiInfo (1);
 		wmiVga = getWmiInfo (2);
@@ -388,16 +391,16 @@ xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugi
 {
 	ph = plugin_handle;
 
-	*plugin_name = "WinSys";
-	*plugin_desc = "Display info about your hardware and OS";
-	*plugin_version = "1.0";
+	*plugin_name = name;
+	*plugin_desc = desc;
+	*plugin_version = version;
 
 	firstRun = 1;
 
 	xchat_hook_command (ph, "WINSYS", XCHAT_PRI_NORM, printInfo, NULL, NULL);
 	xchat_command (ph, "MENU -ietc\\system.png ADD \"Window/Display System Info\" \"WINSYS\"");
 
-	xchat_printf (ph, "%s plugin loaded\n", *plugin_name);
+	xchat_printf (ph, "%s plugin loaded\n", name);
 
 	return 1;       /* return 1 for success */
 }
@@ -407,6 +410,6 @@ int
 xchat_plugin_deinit (void)
 {
 	xchat_command (ph, "MENU DEL \"Window/Display System Info\"");
-	xchat_print (ph, "WinSys plugin unloaded\n");
+	xchat_printf (ph, "%s plugin unloaded\n", name);
 	return 1;
 }
-- 
cgit 1.4.1


From 1fe5dfae7f27053a286edc597695873618977f17 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Fri, 2 Dec 2011 01:09:52 +0100
Subject: apparently this is not allowed in C++

---
 plugins/winsys/winsys.cpp | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

(limited to 'plugins')

diff --git a/plugins/winsys/winsys.cpp b/plugins/winsys/winsys.cpp
index 55a5ddaf..68c47016 100644
--- a/plugins/winsys/winsys.cpp
+++ b/plugins/winsys/winsys.cpp
@@ -28,9 +28,9 @@
 #include "xchat-plugin.h"
 
 static xchat_plugin *ph;   /* plugin handle */
-static const char name[] = "WinSys";
-static const char desc[] = "Display info about your hardware and OS";
-static const char version[] = "1.0";
+static char name[] = "WinSys";
+static char desc[] = "Display info about your hardware and OS";
+static char version[] = "1.0";
 static int firstRun;
 static char *wmiOs;
 static char *wmiCpu;
-- 
cgit 1.4.1


From deee38c5ce3d407bad80df0f9cffb214a287f7ef Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Fri, 2 Dec 2011 08:07:27 +0100
Subject: fix deinit message in exec

---
 plugins/exec/exec.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/exec/exec.c b/plugins/exec/exec.c
index fc8c8ec9..f9450210 100644
--- a/plugins/exec/exec.c
+++ b/plugins/exec/exec.c
@@ -123,6 +123,6 @@ xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugi
 int
 xchat_plugin_deinit (void)
 {
-	xchat_print (ph, "%s plugin unloaded\n", name);
+	xchat_printf (ph, "%s plugin unloaded\n", name);
 	return 1;
 }
-- 
cgit 1.4.1


From 6ccfa8aaeafd315fe8c305e42756248e1d4e6f0c Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Fri, 2 Dec 2011 12:21:33 +0100
Subject: fix automatic update checking

---
 plugins/upd/upd.c | 9 +--------
 1 file changed, 1 insertion(+), 8 deletions(-)

(limited to 'plugins')

diff --git a/plugins/upd/upd.c b/plugins/upd/upd.c
index 7ab5edca..578da0d9 100644
--- a/plugins/upd/upd.c
+++ b/plugins/upd/upd.c
@@ -30,9 +30,6 @@ static const char name[] = "Update Checker";
 static const char desc[] = "Check for XChat-WDK updates automatically";
 static const char version[] = "2.0";
 
-/* we need this to store the result of the initial update check since the return value is preserved for XCHAT_EAT */
-static int update_available;
-
 static char*
 check_version ()
 {
@@ -75,12 +72,10 @@ print_version ()
 	if (strcmp (version, xchat_get_info (ph, "wdk_version")) == 0)
 	{
 		xchat_printf (ph, "You have the latest version of XChat-WDK installed!\n");
-		update_available = 0;
 	}
 	else if (strcmp (version, "Unknown") == 0)
 	{
 		xchat_printf (ph, "Unable to check for XChat-WDK updates!\n");
-		update_available = 0;
 	}
 	else
 	{
@@ -89,7 +84,6 @@ print_version ()
 #else
 		xchat_printf (ph, "An XChat-WDK update is available! You can download it from here:\nhttp://xchat-wdk.googlecode.com/files/XChat-WDK%%20%s%%20x86.exe\n", version);
 #endif
-		update_available = 1;
 	}
 
 	return XCHAT_EAT_XCHAT;
@@ -126,11 +120,10 @@ xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugi
 
 	xchat_hook_command (ph, "UPDCHK", XCHAT_PRI_NORM, print_version, 0, 0);
 	xchat_command (ph, "MENU -ietc\\download.png ADD \"Help/Check for Updates\" \"UPDCHK\"");
-
 	xchat_printf (ph, "%s plugin loaded\n", name);
 
 	/* only start the timer if there's no update available during startup */
-	if (!update_available)
+	if (print_version_quiet (NULL))
 	{
 		/* check for updates every 6 hours */
 		xchat_hook_timer (ph, 21600000, print_version_quiet, NULL);
-- 
cgit 1.4.1


From 588c862f662eef73b100e2170dc5484b56ee1526 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Fri, 2 Dec 2011 12:33:22 +0100
Subject: no need for an extra newline during tcl init

---
 plugins/tcl/tclplugin.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/tcl/tclplugin.c b/plugins/tcl/tclplugin.c
index 1f9b33e7..9289d01d 100644
--- a/plugins/tcl/tclplugin.c
+++ b/plugins/tcl/tclplugin.c
@@ -2219,7 +2219,7 @@ int xchat_plugin_init(xchat_plugin * plugin_handle, char **plugin_name, char **p
 #ifdef WIN32
     lib = LoadLibraryA(TCL_DLL);
     if (!lib) {
-        xchat_print(ph, "You must have ActiveTCL 8.5 installed in order to run Tcl scripts.\n" "http://www.activestate.com/activetcl/downloads\n" "Make sure Tcl's bin directory is in your PATH.\n\n");
+        xchat_print(ph, "You must have ActiveTCL 8.5 installed in order to run Tcl scripts.\n" "http://www.activestate.com/activetcl/downloads\n" "Make sure Tcl's bin directory is in your PATH.\n");
         return 0;
     }
     FreeLibrary(lib);
-- 
cgit 1.4.1


From 71036733e31a72fa49bc992d8ca7217774c8e00c Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Fri, 2 Dec 2011 15:37:40 +0100
Subject: add example for sanitizing xchat_set_pluginpref_int input

---
 plugins/plugin20.html | 27 ++++++++++++++++++++++++++-
 1 file changed, 26 insertions(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/plugin20.html b/plugins/plugin20.html
index b36490ba..a9aaaace 100644
--- a/plugins/plugin20.html
+++ b/plugins/plugin20.html
@@ -1068,7 +1068,32 @@ You should never need to edit this file manually.
 <br>
 </blockquote>
 <b>Returns:</b> 1 for success, 0 for failure.
-<br><br><br>
+<br><br><b>Example:</b>
+<blockquote>
+<pre>static int saveint_cb (char *word[], char *word_eol[], void *user_data)
+{
+	int buffer = atoi (word[2]);
+
+	if (buffer > 0 && buffer < INT_MAX)
+	{
+		if (xchat_set_pluginpref_int (ph, "myint1", buffer))
+		{
+			xchat_printf (ph, "Setting successfully saved!\n");
+		}
+		else
+		{
+			xchat_printf (ph, "Error while saving!\n");
+		}
+	}
+	else
+	{
+		xchat_printf (ph, "Invalid input!\n");
+	}
+
+	return XCHAT_EAT_XCHAT;
+}</pre>
+</blockquote>
+<br><br>
 
 <h3><a class=cmd name="xchat_get_pluginpref_int">&nbsp;xchat_get_pluginpref_int()&nbsp;</a><small>(new for 2.8.10)</small></h3>
 <b>Prototype:</b> int xchat_get_pluginpref_int (xchat_plugin *ph, const char *var);
-- 
cgit 1.4.1


From a2f84209c0a9dc0030a7d2a1e67ca81b319334bb Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sat, 3 Dec 2011 18:52:13 +0100
Subject: print system info in one line for others

---
 plugins/winsys/winsys.cpp | 18 +++++++++---------
 1 file changed, 9 insertions(+), 9 deletions(-)

(limited to 'plugins')

diff --git a/plugins/winsys/winsys.cpp b/plugins/winsys/winsys.cpp
index 68c47016..2c1c7f83 100644
--- a/plugins/winsys/winsys.cpp
+++ b/plugins/winsys/winsys.cpp
@@ -363,15 +363,15 @@ printInfo (char *word[], char *word_eol[], void *user_data)
 	}
 	if (xchat_list_int (ph, NULL, "type") >= 2)
 	{
-		/* xchat_commandf (ph, "ME * WinSys - system details *");
-		xchat_commandf (ph, "ME ***************************"); */
-		xchat_commandf (ph, "ME * Client:  XChat-WDK %s (x%d)", xchat_get_info (ph, "wdk_version"), getCpuArch ());
-		xchat_commandf (ph, "ME * OS:      %s", wmiOs);
-		xchat_commandf (ph, "ME * CPU:     %s (%s)", wmiCpu, getCpuMhz ());
-		xchat_commandf (ph, "ME * RAM:     %s", getMemoryInfo ());
-		xchat_commandf (ph, "ME * VGA:     %s", wmiVga);
-		/* will work correctly for up to 50 days, should be enough */
-		xchat_commandf (ph, "ME * Uptime:  %.2f Hours", (float) GetTickCount() / 1000 / 60 / 60);
+		/* uptime will work correctly for up to 50 days, should be enough */
+		xchat_commandf (ph, "ME ** Client: XChat-WDK %s (x%d) ** OS: %s ** CPU: %s (%s) ** RAM: %s ** VGA: %s ** Uptime: %.2f Hours **",
+			xchat_get_info (ph, "wdk_version"),
+			getCpuArch (),
+			wmiOs,
+			wmiCpu,
+			getCpuMhz (),
+			getMemoryInfo (),
+			wmiVga, (float) GetTickCount() / 1000 / 60 / 60);
 	}
 	else
 	{
-- 
cgit 1.4.1


From 4a127d0bb4c3a265c7ffef9bdbd449aac8311c8a Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sat, 3 Dec 2011 18:59:43 +0100
Subject: add some branding to winsys output

---
 plugins/winsys/winsys.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/winsys/winsys.cpp b/plugins/winsys/winsys.cpp
index 2c1c7f83..0b4aef1e 100644
--- a/plugins/winsys/winsys.cpp
+++ b/plugins/winsys/winsys.cpp
@@ -364,7 +364,7 @@ printInfo (char *word[], char *word_eol[], void *user_data)
 	if (xchat_list_int (ph, NULL, "type") >= 2)
 	{
 		/* uptime will work correctly for up to 50 days, should be enough */
-		xchat_commandf (ph, "ME ** Client: XChat-WDK %s (x%d) ** OS: %s ** CPU: %s (%s) ** RAM: %s ** VGA: %s ** Uptime: %.2f Hours **",
+		xchat_commandf (ph, "ME ** WinSys ** Client: XChat-WDK %s (x%d) ** OS: %s ** CPU: %s (%s) ** RAM: %s ** VGA: %s ** Uptime: %.2f Hours **",
 			xchat_get_info (ph, "wdk_version"),
 			getCpuArch (),
 			wmiOs,
-- 
cgit 1.4.1


From 6fc70632316076a477fcc438812e52fa21d67b15 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sat, 3 Dec 2011 19:53:20 +0100
Subject: placeholder for /exec -o

---
 plugins/exec/exec.c | 16 +++++++++++++---
 1 file changed, 13 insertions(+), 3 deletions(-)

(limited to 'plugins')

diff --git a/plugins/exec/exec.c b/plugins/exec/exec.c
index f9450210..22f38814 100644
--- a/plugins/exec/exec.c
+++ b/plugins/exec/exec.c
@@ -28,7 +28,7 @@
 static xchat_plugin *ph;   /* plugin handle */
 static const char name[] = "Exec";
 static const char desc[] = "Execute commands inside XChat";
-static const char version[] = "1.0";
+static const char version[] = "1.1";
 
 static int
 run_command (char *word[], char *word_eol[], void *userdata)
@@ -54,7 +54,17 @@ run_command (char *word[], char *word_eol[], void *userdata)
 	if (strlen (word[2]) > 0)
 	{
 		strcpy (commandLine, "cmd.exe /c ");
-		strcat (commandLine, word_eol[2]);
+
+		if (!stricmp("-O", word[2]))
+		{
+			/*strcat (commandLine, word_eol[3]);*/
+			xchat_printf (ph, "Printing Exec output to others is not supported yet.\n");
+			return XCHAT_EAT_XCHAT;
+		}
+		else
+		{
+			strcat (commandLine, word_eol[2]);
+		}
 
 		CreatePipe (&readPipe, &writePipe, &secattr, 0); /* might be replaced with MyCreatePipeEx */
 
@@ -114,7 +124,7 @@ xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugi
 	*plugin_desc = desc;
 	*plugin_version = version;
 
-	xchat_hook_command (ph, "EXEC", XCHAT_PRI_NORM, run_command, 0, 0);
+	xchat_hook_command (ph, "EXEC", XCHAT_PRI_NORM, run_command, "Usage: /EXEC [-O] - execute commands inside XChat", 0);
 	xchat_printf (ph, "%s plugin loaded\n", name);
 
 	return 1;       /* return 1 for success */
-- 
cgit 1.4.1


From 86c43f53a5b9abe8aec611c2a5d576c7c3017598 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sat, 3 Dec 2011 21:44:36 +0100
Subject: use strawberry perl for 5.14 too and use gendef for def generation

---
 build/build-x64.bat            |    4 +-
 build/build-x86.bat            |    4 +-
 build/strawberry-importlib.bat |   19 -
 plugins/perl/makefile-512.mak  |    5 +-
 plugins/perl/makefile-514.mak  |   20 +-
 plugins/perl/perl.def          |    4 -
 plugins/perl/perl512.def       | 1420 ----------------------------------------
 7 files changed, 24 insertions(+), 1452 deletions(-)
 delete mode 100644 build/strawberry-importlib.bat
 delete mode 100644 plugins/perl/perl.def
 delete mode 100644 plugins/perl/perl512.def

(limited to 'plugins')

diff --git a/build/build-x64.bat b/build/build-x64.bat
index a35069d6..b7a12351 100644
--- a/build/build-x64.bat
+++ b/build/build-x64.bat
@@ -4,9 +4,9 @@ set INCLUDE=%WDK_ROOT%\inc\api;%WDK_ROOT%\inc\crt;%WDK_ROOT%\inc\api\crt\stl70;%
 set LIB=%WDK_ROOT%\lib\wnet\amd64;%WDK_ROOT%\lib\Crt\amd64;%WDK_ROOT%\lib\Mfc\amd64;%WDK_ROOT%\lib\ATL\amd64
 set OPATH=%PATH%
 set DEV_64=%cd%\..\dep-x64
-set PATH=%PROGRAMFILES(X86)%\Microsoft Visual Studio 10.0\VC\bin\amd64;%PROGRAMFILES(X86)%\Microsoft SDKs\Windows\v7.0A\Bin\x64;%DEV_64%\bin
+set PATH=%PROGRAMFILES(X86)%\Microsoft Visual Studio 10.0\VC\bin\amd64;%PROGRAMFILES(X86)%\Microsoft SDKs\Windows\v7.0A\Bin\x64;%DEV_64%\bin;c:\mozilla-build\gendef
 set PERL_512=c:\mozilla-build\perl-5.12-x64\perl
-set PERL_514=c:\mozilla-build\perl-5.14-x64
+set PERL_514=c:\mozilla-build\perl-5.14-x64\perl
 echo [Setup] > xchat-wdk-x64.iss
 echo WizardImageFile=%cd%\bitmaps\wizardimage.bmp >> xchat-wdk-x64.iss
 echo WizardSmallImageFile=%cd%\bitmaps\wizardsmallimage.bmp >> xchat-wdk-x64.iss
diff --git a/build/build-x86.bat b/build/build-x86.bat
index 08f1413a..2e31a69b 100644
--- a/build/build-x86.bat
+++ b/build/build-x86.bat
@@ -4,9 +4,9 @@ set INCLUDE=%WDK_ROOT%\inc\api;%WDK_ROOT%\inc\crt;%WDK_ROOT%\inc\api\crt\stl70;%
 set LIB=%WDK_ROOT%\lib\wxp\i386;%WDK_ROOT%\lib\Crt\i386;%WDK_ROOT%\lib\Mfc\i386;%WDK_ROOT%\lib\ATL\i386
 set OPATH=%PATH%
 set DEV_32=%cd%\..\dep-x86
-set PATH=%PROGRAMFILES(X86)%\Microsoft Visual Studio 10.0\VC\bin;%PROGRAMFILES(X86)%\Microsoft Visual Studio 10.0\Common7\IDE;%PROGRAMFILES(X86)%\Microsoft SDKs\Windows\v7.0A\Bin;%DEV_32%\bin
+set PATH=%PROGRAMFILES(X86)%\Microsoft Visual Studio 10.0\VC\bin;%PROGRAMFILES(X86)%\Microsoft Visual Studio 10.0\Common7\IDE;%PROGRAMFILES(X86)%\Microsoft SDKs\Windows\v7.0A\Bin;%DEV_32%\bin;c:\mozilla-build\gendef
 set PERL_512=c:\mozilla-build\perl-5.12-x86\perl
-set PERL_514=c:\mozilla-build\perl-5.14-x86
+set PERL_514=c:\mozilla-build\perl-5.14-x86\perl
 echo [Setup] > xchat-wdk-x86.iss
 echo WizardImageFile=%cd%\bitmaps\wizardimage.bmp >> xchat-wdk-x86.iss
 echo WizardSmallImageFile=%cd%\bitmaps\wizardsmallimage.bmp >> xchat-wdk-x86.iss
diff --git a/build/strawberry-importlib.bat b/build/strawberry-importlib.bat
deleted file mode 100644
index 61da96b3..00000000
--- a/build/strawberry-importlib.bat
+++ /dev/null
@@ -1,19 +0,0 @@
-@echo off
-set PATH=c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin;C:\Program Files (x86)\Microsoft Visual Studio 10.0\Common7\IDE
-cd c:\mozilla-build\perl-5.12-x86\perl\lib\CORE
-echo.Overwrite existing def file?
-pause
-dumpbin /exports ..\..\bin\perl512.dll > perl512.def
-echo.Please adjust the resulting file manually, then hit return!
-pause
-lib /machine:x86 /def:perl512.def
-pause
-set PATH=c:\Program Files (x86)\Microsoft Visual Studio 10.0\VC\bin\amd64
-cd c:\mozilla-build\perl-5.12-x64\perl\lib\CORE
-echo.Overwrite existing def file?
-pause
-dumpbin /exports ..\..\bin\perl512.dll > perl512.def
-echo.Please adjust the resulting file manually, then hit return!
-pause
-lib /machine:x64 /def:perl512.def
-pause 
diff --git a/plugins/perl/makefile-512.mak b/plugins/perl/makefile-512.mak
index a77dc145..9fcb29a2 100644
--- a/plugins/perl/makefile-512.mak
+++ b/plugins/perl/makefile-512.mak
@@ -14,6 +14,9 @@ perl.def:
 perl.obj: perl.c
 	$(CC) $(CFLAGS) perl.c $(GLIB) /I$(PERL512PATH)\perl\lib\CORE /I.. /DPERL_DLL=\"$(PERL512LIB).dll\"
 
+perl512.def:
+	gendef $(PERL512PATH)\perl\bin\perl512.dll
+
 $(PERL512LIB).lib: perl512.def
 !ifdef X64
 	lib /machine:x64 /def:perl512.def
@@ -32,6 +35,6 @@ $(TARGET): perl.obj perl.def $(PERL512LIB).lib
 clean:
 	@del $(TARGET)
 	@del *.obj
-	@del perl.def
+	@del *.def
 	@del *.lib
 	@del *.exp
diff --git a/plugins/perl/makefile-514.mak b/plugins/perl/makefile-514.mak
index 65ab59d5..0eadd344 100644
--- a/plugins/perl/makefile-514.mak
+++ b/plugins/perl/makefile-514.mak
@@ -11,20 +11,32 @@ perl.def:
 	echo xchat_plugin_deinit >> perl.def
 	echo xchat_plugin_get_info >> perl.def
 
+# MSVC only supports __inline, while GCC only supports __inline__. This is defined incorretly
+# in lib\CORE\config.h in Strawberry Perl, see #define PERL_STATIC_INLINE static __inline__
 perl.obj: perl.c
-	$(CC) $(CFLAGS) perl.c $(GLIB) /I$(PERL514PATH)\lib\CORE /I.. /DPERL_DLL=\"$(PERL514LIB).dll\"
+	$(CC) $(CFLAGS) perl.c $(GLIB) /I$(PERL514PATH)\perl\lib\CORE /I.. /DPERL_DLL=\"$(PERL514LIB).dll\" /D__inline__=__inline
+
+perl514.def:
+	gendef $(PERL514PATH)\perl\bin\perl514.dll
+
+$(PERL514LIB).lib: perl514.def
+!ifdef X64
+	lib /machine:x64 /def:perl514.def
+!else
+	lib /machine:x86 /def:perl514.def
+!endif
 
 perl.c: xchat.pm.h
 
 xchat.pm.h: lib/Xchat.pm lib/IRC.pm
 	perl.exe generate_header
 
-$(TARGET): perl.obj perl.def
-	$(LINK) /DLL /out:$(TARGET) perl.obj $(LDFLAGS) $(PERL514LIB).lib /libpath:$(PERL514PATH)\lib\CORE /delayload:$(PERL514LIB).dll $(DIRENTLIB) delayimp.lib user32.lib shell32.lib advapi32.lib /def:perl.def
+$(TARGET): perl.obj perl.def $(PERL514LIB).lib
+	$(LINK) /DLL /out:$(TARGET) perl.obj $(LDFLAGS) $(PERL514LIB).lib /delayload:$(PERL514LIB).dll $(DIRENTLIB) delayimp.lib user32.lib shell32.lib advapi32.lib /def:perl.def
 
 clean:
 	@del $(TARGET)
 	@del *.obj
-	@del perl.def
+	@del *.def
 	@del *.lib
 	@del *.exp
diff --git a/plugins/perl/perl.def b/plugins/perl/perl.def
deleted file mode 100644
index a2ec6566..00000000
--- a/plugins/perl/perl.def
+++ /dev/null
@@ -1,4 +0,0 @@
-EXPORTS
-  xchat_plugin_init
-  xchat_plugin_deinit
-  xchat_plugin_get_info
\ No newline at end of file
diff --git a/plugins/perl/perl512.def b/plugins/perl/perl512.def
deleted file mode 100644
index 5cfcaa68..00000000
--- a/plugins/perl/perl512.def
+++ /dev/null
@@ -1,1420 +0,0 @@
-LIBRARY perl512
-EXPORTS
-PL_bincompat_options
-PL_check
-PL_fold
-PL_fold_locale
-PL_freq
-PL_keyword_plugin
-PL_memory_wrap
-PL_no_aelem
-PL_no_dir_func
-PL_no_func
-PL_no_helem_sv
-PL_no_localize_ref
-PL_no_mem
-PL_no_modify
-PL_no_myglob
-PL_no_security
-PL_no_sock_func
-PL_no_symref
-PL_no_usym
-PL_no_wrongref
-PL_op_desc
-PL_op_name
-PL_opargs
-PL_perlio_mutex
-PL_ppaddr
-PL_reg_extflags_name
-PL_reg_name
-PL_regkind
-PL_sig_name
-PL_sig_num
-PL_simple
-PL_utf8skip
-PL_uuemap
-PL_varies
-PL_vtbl_amagic
-PL_vtbl_amagicelem
-PL_vtbl_arylen
-PL_vtbl_backref
-PL_vtbl_bm
-PL_vtbl_collxfrm
-PL_vtbl_dbline
-PL_vtbl_defelem
-PL_vtbl_env
-PL_vtbl_envelem
-PL_vtbl_fm
-PL_vtbl_isa
-PL_vtbl_isaelem
-PL_vtbl_mglob
-PL_vtbl_nkeys
-PL_vtbl_pack
-PL_vtbl_packelem
-PL_vtbl_pos
-PL_vtbl_regdata
-PL_vtbl_regdatum
-PL_vtbl_regexp
-PL_vtbl_sig
-PL_vtbl_sigelem
-PL_vtbl_substr
-PL_vtbl_sv
-PL_vtbl_taint
-PL_vtbl_utf8
-PL_vtbl_uvar
-PL_vtbl_vec
-PL_warn_nl
-PL_warn_nosemi
-PL_warn_reserved
-PL_warn_uninit
-PerlIOBase_binmode
-PerlIOBase_clearerr
-PerlIOBase_close
-PerlIOBase_dup
-PerlIOBase_eof
-PerlIOBase_error
-PerlIOBase_fileno
-PerlIOBase_noop_fail
-PerlIOBase_noop_ok
-PerlIOBase_popped
-PerlIOBase_pushed
-PerlIOBase_read
-PerlIOBase_setlinebuf
-PerlIOBase_unread
-PerlIOBuf_bufsiz
-PerlIOBuf_close
-PerlIOBuf_dup
-PerlIOBuf_fill
-PerlIOBuf_flush
-PerlIOBuf_get_base
-PerlIOBuf_get_cnt
-PerlIOBuf_get_ptr
-PerlIOBuf_open
-PerlIOBuf_popped
-PerlIOBuf_pushed
-PerlIOBuf_read
-PerlIOBuf_seek
-PerlIOBuf_set_ptrcnt
-PerlIOBuf_tell
-PerlIOBuf_unread
-PerlIOBuf_write
-PerlIO_allocate
-PerlIO_apply_layera
-PerlIO_apply_layers
-PerlIO_arg_fetch
-PerlIO_binmode
-PerlIO_canset_cnt
-PerlIO_debug
-PerlIO_define_layer
-PerlIO_exportFILE
-PerlIO_fast_gets
-PerlIO_fdopen
-PerlIO_findFILE
-PerlIO_find_layer
-PerlIO_getc
-PerlIO_getname
-PerlIO_getpos
-PerlIO_has_base
-PerlIO_has_cntptr
-PerlIO_importFILE
-PerlIO_init
-PerlIO_isutf8
-PerlIO_layer_fetch
-PerlIO_list_alloc
-PerlIO_list_free
-PerlIO_modestr
-PerlIO_open
-PerlIO_parse_layers
-PerlIO_pending
-PerlIO_perlio
-PerlIO_pop
-PerlIO_printf
-PerlIO_push
-PerlIO_putc
-PerlIO_puts
-PerlIO_releaseFILE
-PerlIO_reopen
-PerlIO_rewind
-PerlIO_setpos
-PerlIO_sprintf
-PerlIO_stdoutf
-PerlIO_sv_dup
-PerlIO_teardown
-PerlIO_tmpfile
-PerlIO_ungetc
-PerlIO_vprintf
-PerlIO_vsprintf
-Perl_GNo_ptr
-Perl_GYes_ptr
-Perl_Gcheck_ptr
-Perl_Gcsighandlerp_ptr
-Perl_Gcurinterp_ptr
-Perl_Gdo_undump_ptr
-Perl_Gdollarzero_mutex_ptr
-Perl_Gfold_locale_ptr
-Perl_Ghexdigit_ptr
-Perl_Ghints_mutex_ptr
-Perl_Ginterp_size_5_10_0_ptr
-Perl_Ginterp_size_ptr
-Perl_Gkeyword_plugin_ptr
-Perl_Gmy_ctx_mutex_ptr
-Perl_Gmy_cxt_index_ptr
-Perl_Gop_mutex_ptr
-Perl_Gop_seq_ptr
-Perl_Gop_sequence_ptr
-Perl_Gpatleave_ptr
-Perl_Gperlio_debug_fd_ptr
-Perl_Gperlio_fd_refcnt_ptr
-Perl_Gperlio_fd_refcnt_size_ptr
-Perl_Gperlio_mutex_ptr
-Perl_Gppaddr_ptr
-Perl_Grevision_ptr
-Perl_Grunops_dbg_ptr
-Perl_Grunops_std_ptr
-Perl_Gsh_path_ptr
-Perl_Gsig_trapped_ptr
-Perl_Gsigfpe_saved_ptr
-Perl_Gsubversion_ptr
-Perl_Gsv_placeholder_ptr
-Perl_Gthr_key_ptr
-Perl_Guse_safe_putenv_ptr
-Perl_Gv_AMupdate
-Perl_Gversion_ptr
-Perl_Gveto_cleanup_ptr
-Perl_IArgv_ptr
-Perl_ICmd_ptr
-Perl_IDBgv_ptr
-Perl_IDBline_ptr
-Perl_IDBsignal_ptr
-Perl_IDBsingle_ptr
-Perl_IDBsub_ptr
-Perl_IDBtrace_ptr
-Perl_IDir_ptr
-Perl_IEnv_ptr
-Perl_ILIO_ptr
-Perl_IMemParse_ptr
-Perl_IMemShared_ptr
-Perl_IMem_ptr
-Perl_IOpPtr_ptr
-Perl_IOpSlab_ptr
-Perl_IOpSpace_ptr
-Perl_IProc_ptr
-Perl_ISock_ptr
-Perl_IStdIO_ptr
-Perl_ISv_ptr
-Perl_IXpv_ptr
-Perl_Iamagic_generation_ptr
-Perl_Ian_ptr
-Perl_Iargvgv_ptr
-Perl_Iargvout_stack_ptr
-Perl_Iargvoutgv_ptr
-Perl_Ibasetime_ptr
-Perl_Ibeginav_ptr
-Perl_Ibeginav_save_ptr
-Perl_Ibody_arenas_ptr
-Perl_Ibody_roots_ptr
-Perl_Ibodytarget_ptr
-Perl_Ibreakable_sub_gen_ptr
-Perl_Icheckav_ptr
-Perl_Icheckav_save_ptr
-Perl_Ichopset_ptr
-Perl_Iclocktick_ptr
-Perl_Icollation_ix_ptr
-Perl_Icollation_name_ptr
-Perl_Icollation_standard_ptr
-Perl_Icollxfrm_base_ptr
-Perl_Icollxfrm_mult_ptr
-Perl_Icolors_ptr
-Perl_Icolorset_ptr
-Perl_Icompcv_ptr
-Perl_Icompiling_ptr
-Perl_Icomppad_name_fill_ptr
-Perl_Icomppad_name_floor_ptr
-Perl_Icomppad_name_ptr
-Perl_Icomppad_ptr
-Perl_Icop_seqmax_ptr
-Perl_Icurcop_ptr
-Perl_Icurcopdb_ptr
-Perl_Icurpad_ptr
-Perl_Icurpm_ptr
-Perl_Icurstack_ptr
-Perl_Icurstackinfo_ptr
-Perl_Icurstash_ptr
-Perl_Icurstname_ptr
-Perl_Icustom_op_descs_ptr
-Perl_Icustom_op_names_ptr
-Perl_Icv_has_eval_ptr
-Perl_Idbargs_ptr
-Perl_Idebstash_ptr
-Perl_Idebug_pad_ptr
-Perl_Idebug_ptr
-Perl_Idef_layerlist_ptr
-Perl_Idefgv_ptr
-Perl_Idefoutgv_ptr
-Perl_Idefstash_ptr
-Perl_Idelaymagic_ptr
-Perl_Idestroyhook_ptr
-Perl_Idiehook_ptr
-Perl_Idirty_ptr
-Perl_Idoextract_ptr
-Perl_Idoswitches_ptr
-Perl_Idowarn_ptr
-Perl_Idumpindent_ptr
-Perl_Ie_script_ptr
-Perl_Iefloatbuf_ptr
-Perl_Iefloatsize_ptr
-Perl_Iegid_ptr
-Perl_Iencoding_ptr
-Perl_Iendav_ptr
-Perl_Ienvgv_ptr
-Perl_Ierrgv_ptr
-Perl_Ierrors_ptr
-Perl_Ieuid_ptr
-Perl_Ieval_root_ptr
-Perl_Ieval_start_ptr
-Perl_Ievalseq_ptr
-Perl_Iexit_flags_ptr
-Perl_Iexitlist_ptr
-Perl_Iexitlistlen_ptr
-Perl_Ifdpid_ptr
-Perl_Ifilemode_ptr
-Perl_Ifirstgv_ptr
-Perl_Iforkprocess_ptr
-Perl_Iformfeed_ptr
-Perl_Iformtarget_ptr
-Perl_Igensym_ptr
-Perl_Igid_ptr
-Perl_Iglob_index_ptr
-Perl_Iglobalstash_ptr
-Perl_Ihash_seed_ptr
-Perl_Ihintgv_ptr
-Perl_Ihints_ptr
-Perl_Ihv_fetch_ent_mh_ptr
-Perl_Iin_clean_all_ptr
-Perl_Iin_clean_objs_ptr
-Perl_Iin_eval_ptr
-Perl_Iin_load_module_ptr
-Perl_Iincgv_ptr
-Perl_Iinitav_ptr
-Perl_Iinplace_ptr
-Perl_Iisarev_ptr
-Perl_Iknown_layers_ptr
-Perl_Ilast_in_gv_ptr
-Perl_Ilast_swash_hv_ptr
-Perl_Ilast_swash_key_ptr
-Perl_Ilast_swash_klen_ptr
-Perl_Ilast_swash_slen_ptr
-Perl_Ilast_swash_tmps_ptr
-Perl_Ilastfd_ptr
-Perl_Ilastscream_ptr
-Perl_Ilaststatval_ptr
-Perl_Ilaststype_ptr
-Perl_Ilocalizing_ptr
-Perl_Ilocalpatches_ptr
-Perl_Ilockhook_ptr
-Perl_Imain_cv_ptr
-Perl_Imain_root_ptr
-Perl_Imain_start_ptr
-Perl_Imainstack_ptr
-Perl_Imarkstack_max_ptr
-Perl_Imarkstack_ptr
-Perl_Imarkstack_ptr_ptr
-Perl_Imax_intro_pending_ptr
-Perl_Imaxo_ptr
-Perl_Imaxscream_ptr
-Perl_Imaxsysfd_ptr
-Perl_Imess_sv_ptr
-Perl_Imin_intro_pending_ptr
-Perl_Iminus_E_ptr
-Perl_Iminus_F_ptr
-Perl_Iminus_a_ptr
-Perl_Iminus_c_ptr
-Perl_Iminus_l_ptr
-Perl_Iminus_n_ptr
-Perl_Iminus_p_ptr
-Perl_Imodglobal_ptr
-Perl_Imy_cxt_list_ptr
-Perl_Imy_cxt_size_ptr
-Perl_Ina_ptr
-Perl_Inice_chunk_ptr
-Perl_Inice_chunk_size_ptr
-Perl_Inomemok_ptr
-Perl_Inumeric_local_ptr
-Perl_Inumeric_name_ptr
-Perl_Inumeric_radix_sv_ptr
-Perl_Inumeric_standard_ptr
-Perl_Iofsgv_ptr
-Perl_Ioldname_ptr
-Perl_Iop_mask_ptr
-Perl_Iop_ptr
-Perl_Iopfreehook_ptr
-Perl_Iorigalen_ptr
-Perl_Iorigargc_ptr
-Perl_Iorigargv_ptr
-Perl_Iorigenviron_ptr
-Perl_Iorigfilename_ptr
-Perl_Iors_sv_ptr
-Perl_Iosname_ptr
-Perl_Ipad_reset_pending_ptr
-Perl_Ipadix_floor_ptr
-Perl_Ipadix_ptr
-Perl_Iparser_ptr
-Perl_Ipatchlevel_ptr
-Perl_Ipeepp_ptr
-Perl_Iperl_destruct_level_ptr
-Perl_Iperldb_ptr
-Perl_Iperlio_ptr
-Perl_Ipreambleav_ptr
-Perl_Iprofiledata_ptr
-Perl_Ipsig_name_ptr
-Perl_Ipsig_pend_ptr
-Perl_Ipsig_ptr_ptr
-Perl_Iptr_table_ptr
-Perl_Ireentrant_retint_ptr
-Perl_Ireg_state_ptr
-Perl_Iregdummy_ptr
-Perl_Iregex_pad_ptr
-Perl_Iregex_padav_ptr
-Perl_Ireginterp_cnt_ptr
-Perl_Iregistered_mros_ptr
-Perl_Iregmatch_slab_ptr
-Perl_Iregmatch_state_ptr
-Perl_Irehash_seed_ptr
-Perl_Irehash_seed_set_ptr
-Perl_Ireplgv_ptr
-Perl_Irestartop_ptr
-Perl_Irs_ptr
-Perl_Irunops_ptr
-Perl_Isavebegin_ptr
-Perl_Isavestack_ix_ptr
-Perl_Isavestack_max_ptr
-Perl_Isavestack_ptr
-Perl_Isawampersand_ptr
-Perl_Iscopestack_ix_ptr
-Perl_Iscopestack_max_ptr
-Perl_Iscopestack_name_ptr
-Perl_Iscopestack_ptr
-Perl_Iscreamfirst_ptr
-Perl_Iscreamnext_ptr
-Perl_Isecondgv_ptr
-Perl_Isharehook_ptr
-Perl_Isig_pending_ptr
-Perl_Isighandlerp_ptr
-Perl_Isignals_ptr
-Perl_Isort_RealCmp_ptr
-Perl_Isortcop_ptr
-Perl_Isortstash_ptr
-Perl_Isplitstr_ptr
-Perl_Isrand_called_ptr
-Perl_Istack_base_ptr
-Perl_Istack_max_ptr
-Perl_Istack_sp_ptr
-Perl_Istart_env_ptr
-Perl_Istashcache_ptr
-Perl_Istatbuf_ptr
-Perl_Istatcache_ptr
-Perl_Istatgv_ptr
-Perl_Istatname_ptr
-Perl_Istatusvalue_posix_ptr
-Perl_Istatusvalue_ptr
-Perl_Istderrgv_ptr
-Perl_Istdingv_ptr
-Perl_Istrtab_ptr
-Perl_Isub_generation_ptr
-Perl_Isubline_ptr
-Perl_Isubname_ptr
-Perl_Isv_arenaroot_ptr
-Perl_Isv_count_ptr
-Perl_Isv_no_ptr
-Perl_Isv_objcount_ptr
-Perl_Isv_root_ptr
-Perl_Isv_undef_ptr
-Perl_Isv_yes_ptr
-Perl_Isys_intern_ptr
-Perl_Itaint_warn_ptr
-Perl_Itainted_ptr
-Perl_Itainting_ptr
-Perl_Ithreadhook_ptr
-Perl_Itmps_floor_ptr
-Perl_Itmps_ix_ptr
-Perl_Itmps_max_ptr
-Perl_Itmps_stack_ptr
-Perl_Itop_env_ptr
-Perl_Itoptarget_ptr
-Perl_Iuid_ptr
-Perl_Iunicode_ptr
-Perl_Iunitcheckav_ptr
-Perl_Iunitcheckav_save_ptr
-Perl_Iunlockhook_ptr
-Perl_Iunsafe_ptr
-Perl_Iutf8_X_LVT_ptr
-Perl_Iutf8_X_LV_LVT_V_ptr
-Perl_Iutf8_X_LV_ptr
-Perl_Iutf8_X_L_ptr
-Perl_Iutf8_X_T_ptr
-Perl_Iutf8_X_V_ptr
-Perl_Iutf8_X_begin_ptr
-Perl_Iutf8_X_extend_ptr
-Perl_Iutf8_X_non_hangul_ptr
-Perl_Iutf8_X_prepend_ptr
-Perl_Iutf8_alnum_ptr
-Perl_Iutf8_alpha_ptr
-Perl_Iutf8_ascii_ptr
-Perl_Iutf8_cntrl_ptr
-Perl_Iutf8_digit_ptr
-Perl_Iutf8_graph_ptr
-Perl_Iutf8_idcont_ptr
-Perl_Iutf8_idstart_ptr
-Perl_Iutf8_lower_ptr
-Perl_Iutf8_mark_ptr
-Perl_Iutf8_perl_space_ptr
-Perl_Iutf8_perl_word_ptr
-Perl_Iutf8_posix_digit_ptr
-Perl_Iutf8_print_ptr
-Perl_Iutf8_punct_ptr
-Perl_Iutf8_space_ptr
-Perl_Iutf8_tofold_ptr
-Perl_Iutf8_tolower_ptr
-Perl_Iutf8_totitle_ptr
-Perl_Iutf8_toupper_ptr
-Perl_Iutf8_upper_ptr
-Perl_Iutf8_xdigit_ptr
-Perl_Iutf8cache_ptr
-Perl_Iutf8locale_ptr
-Perl_Iwarnhook_ptr
-Perl_PerlIO_clearerr
-Perl_PerlIO_close
-Perl_PerlIO_context_layers
-Perl_PerlIO_eof
-Perl_PerlIO_error
-Perl_PerlIO_fileno
-Perl_PerlIO_fill
-Perl_PerlIO_flush
-Perl_PerlIO_get_base
-Perl_PerlIO_get_bufsiz
-Perl_PerlIO_get_cnt
-Perl_PerlIO_get_ptr
-Perl_PerlIO_read
-Perl_PerlIO_seek
-Perl_PerlIO_set_cnt
-Perl_PerlIO_set_ptrcnt
-Perl_PerlIO_setlinebuf
-Perl_PerlIO_stderr
-Perl_PerlIO_stdin
-Perl_PerlIO_stdout
-Perl_PerlIO_tell
-Perl_PerlIO_unread
-Perl_PerlIO_write
-Perl_Slab_Alloc
-Perl_Slab_Free
-Perl_amagic_call
-Perl_any_dup
-Perl_apply_attrs_string
-Perl_atfork_lock
-Perl_atfork_unlock
-Perl_av_arylen_p
-Perl_av_clear
-Perl_av_delete
-Perl_av_exists
-Perl_av_extend
-Perl_av_fetch
-Perl_av_fill
-Perl_av_iter_p
-Perl_av_len
-Perl_av_make
-Perl_av_pop
-Perl_av_push
-Perl_av_reify
-Perl_av_shift
-Perl_av_store
-Perl_av_undef
-Perl_av_unshift
-Perl_block_gimme
-Perl_bytes_from_utf8
-Perl_bytes_to_utf8
-Perl_call_argv
-Perl_call_atexit
-Perl_call_list
-Perl_call_method
-Perl_call_pv
-Perl_call_sv
-Perl_calloc
-Perl_cast_i32
-Perl_cast_iv
-Perl_cast_ulong
-Perl_cast_uv
-Perl_ck_warner
-Perl_ck_warner_d
-Perl_ckwarn
-Perl_ckwarn_d
-Perl_croak
-Perl_croak_nocontext
-Perl_croak_xs_usage
-Perl_csighandler
-Perl_custom_op_desc
-Perl_custom_op_name
-Perl_cv_const_sv
-Perl_cv_undef
-Perl_cx_dump
-Perl_cx_dup
-Perl_cxinc
-Perl_deb
-Perl_deb_nocontext
-Perl_delimcpy
-Perl_despatch_signals
-Perl_die
-Perl_die_nocontext
-Perl_dirp_dup
-Perl_do_aexec
-Perl_do_aspawn
-Perl_do_binmode
-Perl_do_close
-Perl_do_gv_dump
-Perl_do_gvgv_dump
-Perl_do_hv_dump
-Perl_do_join
-Perl_do_magic_dump
-Perl_do_op_dump
-Perl_do_open
-Perl_do_open9
-Perl_do_openn
-Perl_do_pmop_dump
-Perl_do_spawn
-Perl_do_spawn_nowait
-Perl_do_sprintf
-Perl_do_sv_dump
-Perl_doing_taint
-Perl_doref
-Perl_dounwind
-Perl_dowantarray
-Perl_dump_all
-Perl_dump_eval
-Perl_dump_form
-Perl_dump_indent
-Perl_dump_packsubs
-Perl_dump_sub
-Perl_dump_vindent
-Perl_emulate_cop_io
-Perl_eval_pv
-Perl_eval_sv
-Perl_fbm_compile
-Perl_fbm_instr
-Perl_fetch_cop_label
-Perl_filter_add
-Perl_filter_del
-Perl_filter_read
-Perl_find_runcv
-Perl_find_rundefsvoffset
-Perl_form
-Perl_form_nocontext
-Perl_fp_dup
-Perl_fprintf_nocontext
-Perl_free_tmps
-Perl_get_av
-Perl_get_context
-Perl_get_cv
-Perl_get_cvn_flags
-Perl_get_hv
-Perl_get_op_descs
-Perl_get_op_names
-Perl_get_ppaddr
-Perl_get_re_arg
-Perl_get_sv
-Perl_get_vtbl
-Perl_getcwd_sv
-Perl_gp_dup
-Perl_gp_free
-Perl_gp_ref
-Perl_grok_bin
-Perl_grok_hex
-Perl_grok_number
-Perl_grok_numeric_radix
-Perl_grok_oct
-Perl_gv_AVadd
-Perl_gv_HVadd
-Perl_gv_IOadd
-Perl_gv_SVadd
-Perl_gv_add_by_type
-Perl_gv_autoload4
-Perl_gv_check
-Perl_gv_const_sv
-Perl_gv_dump
-Perl_gv_efullname
-Perl_gv_efullname3
-Perl_gv_efullname4
-Perl_gv_fetchfile
-Perl_gv_fetchfile_flags
-Perl_gv_fetchmeth
-Perl_gv_fetchmeth_autoload
-Perl_gv_fetchmethod
-Perl_gv_fetchmethod_autoload
-Perl_gv_fetchmethod_flags
-Perl_gv_fetchpv
-Perl_gv_fetchpvn_flags
-Perl_gv_fetchsv
-Perl_gv_fullname
-Perl_gv_fullname3
-Perl_gv_fullname4
-Perl_gv_handler
-Perl_gv_init
-Perl_gv_name_set
-Perl_gv_stashpv
-Perl_gv_stashpvn
-Perl_gv_stashsv
-Perl_gv_try_downgrade
-Perl_he_dup
-Perl_hek_dup
-Perl_hv_clear
-Perl_hv_clear_placeholders
-Perl_hv_common
-Perl_hv_common_key_len
-Perl_hv_delayfree_ent
-Perl_hv_delete
-Perl_hv_delete_ent
-Perl_hv_eiter_p
-Perl_hv_eiter_set
-Perl_hv_exists
-Perl_hv_exists_ent
-Perl_hv_fetch
-Perl_hv_fetch_ent
-Perl_hv_free_ent
-Perl_hv_iterinit
-Perl_hv_iterkey
-Perl_hv_iterkeysv
-Perl_hv_iternext
-Perl_hv_iternext_flags
-Perl_hv_iternextsv
-Perl_hv_iterval
-Perl_hv_ksplit
-Perl_hv_magic
-Perl_hv_name_set
-Perl_hv_placeholders_get
-Perl_hv_placeholders_p
-Perl_hv_placeholders_set
-Perl_hv_riter_p
-Perl_hv_riter_set
-Perl_hv_scalar
-Perl_hv_store
-Perl_hv_store_ent
-Perl_hv_store_flags
-Perl_hv_undef
-Perl_ibcmp
-Perl_ibcmp_locale
-Perl_ibcmp_utf8
-Perl_init_i18nl10n
-Perl_init_i18nl14n
-Perl_init_os_extras
-Perl_init_stacks
-Perl_init_tm
-Perl_instr
-Perl_is_ascii_string
-Perl_is_lvalue_sub
-Perl_is_uni_alnum
-Perl_is_uni_alnum_lc
-Perl_is_uni_alpha
-Perl_is_uni_alpha_lc
-Perl_is_uni_ascii
-Perl_is_uni_ascii_lc
-Perl_is_uni_cntrl
-Perl_is_uni_cntrl_lc
-Perl_is_uni_digit
-Perl_is_uni_digit_lc
-Perl_is_uni_graph
-Perl_is_uni_graph_lc
-Perl_is_uni_idfirst
-Perl_is_uni_idfirst_lc
-Perl_is_uni_lower
-Perl_is_uni_lower_lc
-Perl_is_uni_print
-Perl_is_uni_print_lc
-Perl_is_uni_punct
-Perl_is_uni_punct_lc
-Perl_is_uni_space
-Perl_is_uni_space_lc
-Perl_is_uni_upper
-Perl_is_uni_upper_lc
-Perl_is_uni_xdigit
-Perl_is_uni_xdigit_lc
-Perl_is_utf8_X_L
-Perl_is_utf8_X_LV
-Perl_is_utf8_X_LVT
-Perl_is_utf8_X_LV_LVT_V
-Perl_is_utf8_X_T
-Perl_is_utf8_X_V
-Perl_is_utf8_X_begin
-Perl_is_utf8_X_extend
-Perl_is_utf8_X_non_hangul
-Perl_is_utf8_X_prepend
-Perl_is_utf8_alnum
-Perl_is_utf8_alpha
-Perl_is_utf8_ascii
-Perl_is_utf8_char
-Perl_is_utf8_cntrl
-Perl_is_utf8_digit
-Perl_is_utf8_graph
-Perl_is_utf8_idcont
-Perl_is_utf8_idfirst
-Perl_is_utf8_lower
-Perl_is_utf8_mark
-Perl_is_utf8_perl_space
-Perl_is_utf8_perl_word
-Perl_is_utf8_posix_digit
-Perl_is_utf8_print
-Perl_is_utf8_punct
-Perl_is_utf8_space
-Perl_is_utf8_string
-Perl_is_utf8_string_loc
-Perl_is_utf8_string_loclen
-Perl_is_utf8_upper
-Perl_is_utf8_xdigit
-Perl_leave_scope
-Perl_lex_bufutf8
-Perl_lex_discard_to
-Perl_lex_end
-Perl_lex_grow_linestr
-Perl_lex_next_chunk
-Perl_lex_peek_unichar
-Perl_lex_read_space
-Perl_lex_read_to
-Perl_lex_read_unichar
-Perl_lex_stuff_pvn
-Perl_lex_stuff_sv
-Perl_lex_unstuff
-Perl_load_module
-Perl_load_module_nocontext
-Perl_looks_like_number
-Perl_magic_dump
-Perl_malloc
-Perl_markstack_grow
-Perl_mess
-Perl_mess_nocontext
-Perl_mfree
-Perl_mg_clear
-Perl_mg_copy
-Perl_mg_dup
-Perl_mg_find
-Perl_mg_free
-Perl_mg_get
-Perl_mg_length
-Perl_mg_magical
-Perl_mg_set
-Perl_mg_size
-Perl_mini_mktime
-Perl_mod
-Perl_moreswitches
-Perl_mro_get_from_name
-Perl_mro_get_linear_isa
-Perl_mro_get_private_data
-Perl_mro_meta_init
-Perl_mro_method_changed_in
-Perl_mro_register
-Perl_mro_set_mro
-Perl_mro_set_private_data
-Perl_my_atof
-Perl_my_atof2
-Perl_my_cxt_init
-Perl_my_dirfd
-Perl_my_exit
-Perl_my_failure_exit
-Perl_my_fflush_all
-Perl_my_fork
-Perl_my_lstat
-Perl_my_popen_list
-Perl_my_setenv
-Perl_my_snprintf
-Perl_my_socketpair
-Perl_my_stat
-Perl_my_strftime
-Perl_my_strlcat
-Perl_my_strlcpy
-Perl_my_vsnprintf
-Perl_newANONATTRSUB
-Perl_newANONHASH
-Perl_newANONLIST
-Perl_newANONSUB
-Perl_newASSIGNOP
-Perl_newATTRSUB
-Perl_newAV
-Perl_newAVREF
-Perl_newBINOP
-Perl_newCONDOP
-Perl_newCONSTSUB
-Perl_newCVREF
-Perl_newFORM
-Perl_newFOROP
-Perl_newGIVENOP
-Perl_newGVOP
-Perl_newGVREF
-Perl_newGVgen
-Perl_newHV
-Perl_newHVREF
-Perl_newHVhv
-Perl_newIO
-Perl_newLISTOP
-Perl_newLOGOP
-Perl_newLOOPEX
-Perl_newLOOPOP
-Perl_newMYSUB
-Perl_newNULLLIST
-Perl_newOP
-Perl_newPADOP
-Perl_newPMOP
-Perl_newPROG
-Perl_newPVOP
-Perl_newRANGE
-Perl_newRV
-Perl_newRV_noinc
-Perl_newSLICEOP
-Perl_newSTATEOP
-Perl_newSUB
-Perl_newSV
-Perl_newSVOP
-Perl_newSVREF
-Perl_newSV_type
-Perl_newSVhek
-Perl_newSViv
-Perl_newSVnv
-Perl_newSVpv
-Perl_newSVpvf
-Perl_newSVpvf_nocontext
-Perl_newSVpvn
-Perl_newSVpvn_flags
-Perl_newSVpvn_share
-Perl_newSVrv
-Perl_newSVsv
-Perl_newSVuv
-Perl_newUNOP
-Perl_newWHENOP
-Perl_newWHILEOP
-Perl_newXS
-Perl_newXS_flags
-Perl_new_collate
-Perl_new_ctype
-Perl_new_numeric
-Perl_new_stackinfo
-Perl_new_version
-Perl_new_warnings_bitfield
-Perl_ninstr
-Perl_nothreadhook
-Perl_op_clear
-Perl_op_dump
-Perl_op_free
-Perl_op_null
-Perl_op_refcnt_lock
-Perl_op_refcnt_unlock
-Perl_pack_cat
-Perl_packlist
-Perl_pad_findmy
-Perl_pad_push
-Perl_parser_dup
-Perl_pmflag
-Perl_pmop_dump
-Perl_pop_scope
-Perl_pregcomp
-Perl_pregexec
-Perl_pregfree
-Perl_pregfree2
-Perl_prescan_version
-Perl_printf_nocontext
-Perl_ptr_table_clear
-Perl_ptr_table_fetch
-Perl_ptr_table_free
-Perl_ptr_table_new
-Perl_ptr_table_split
-Perl_ptr_table_store
-Perl_push_scope
-Perl_pv_display
-Perl_pv_escape
-Perl_pv_pretty
-Perl_pv_uni_display
-Perl_qerror
-Perl_re_compile
-Perl_re_dup_guts
-Perl_re_intuit_start
-Perl_re_intuit_string
-Perl_realloc
-Perl_reentrant_free
-Perl_reentrant_init
-Perl_reentrant_retry
-Perl_reentrant_size
-Perl_ref
-Perl_refcounted_he_chain_2hv
-Perl_refcounted_he_fetch
-Perl_refcounted_he_new
-Perl_reg_named_buff
-Perl_reg_named_buff_all
-Perl_reg_named_buff_exists
-Perl_reg_named_buff_fetch
-Perl_reg_named_buff_firstkey
-Perl_reg_named_buff_iter
-Perl_reg_named_buff_nextkey
-Perl_reg_named_buff_scalar
-Perl_reg_numbered_buff_fetch
-Perl_reg_numbered_buff_length
-Perl_reg_numbered_buff_store
-Perl_reg_qr_package
-Perl_reg_temp_copy
-Perl_regclass_swash
-Perl_regcurly
-Perl_regdump
-Perl_regdupe_internal
-Perl_regexec_flags
-Perl_regfree_internal
-Perl_reginitcolors
-Perl_regnext
-Perl_repeatcpy
-Perl_report_uninit
-Perl_require_pv
-Perl_rninstr
-Perl_rsignal
-Perl_rsignal_state
-Perl_runops_debug
-Perl_runops_standard
-Perl_rvpv_dup
-Perl_safesyscalloc
-Perl_safesysfree
-Perl_safesysmalloc
-Perl_safesysrealloc
-Perl_save_I16
-Perl_save_I32
-Perl_save_I8
-Perl_save_adelete
-Perl_save_aelem_flags
-Perl_save_alloc
-Perl_save_aptr
-Perl_save_ary
-Perl_save_bool
-Perl_save_clearsv
-Perl_save_delete
-Perl_save_destructor
-Perl_save_destructor_x
-Perl_save_freeop
-Perl_save_freepv
-Perl_save_freesv
-Perl_save_generic_pvref
-Perl_save_generic_svref
-Perl_save_gp
-Perl_save_hash
-Perl_save_hdelete
-Perl_save_helem_flags
-Perl_save_hptr
-Perl_save_int
-Perl_save_item
-Perl_save_iv
-Perl_save_list
-Perl_save_long
-Perl_save_mortalizesv
-Perl_save_nogv
-Perl_save_op
-Perl_save_padsv_and_mortalize
-Perl_save_pptr
-Perl_save_pushptr
-Perl_save_re_context
-Perl_save_scalar
-Perl_save_set_svflags
-Perl_save_shared_pvref
-Perl_save_sptr
-Perl_save_svref
-Perl_save_vptr
-Perl_savepv
-Perl_savepvn
-Perl_savesharedpv
-Perl_savesharedpvn
-Perl_savestack_grow
-Perl_savestack_grow_cnt
-Perl_savesvpv
-Perl_scan_bin
-Perl_scan_hex
-Perl_scan_num
-Perl_scan_oct
-Perl_scan_version
-Perl_scan_vstring
-Perl_screaminstr
-Perl_seed
-Perl_set_context
-Perl_set_numeric_local
-Perl_set_numeric_radix
-Perl_set_numeric_standard
-Perl_setdefout
-Perl_share_hek
-Perl_si_dup
-Perl_signbit
-Perl_sortsv
-Perl_sortsv_flags
-Perl_ss_dup
-Perl_stack_grow
-Perl_start_subparse
-Perl_stashpv_hvname_match
-Perl_str_to_version
-Perl_sv_2bool
-Perl_sv_2cv
-Perl_sv_2io
-Perl_sv_2iv
-Perl_sv_2iv_flags
-Perl_sv_2mortal
-Perl_sv_2nv
-Perl_sv_2pv
-Perl_sv_2pv_flags
-Perl_sv_2pv_nolen
-Perl_sv_2pvbyte
-Perl_sv_2pvbyte_nolen
-Perl_sv_2pvutf8
-Perl_sv_2pvutf8_nolen
-Perl_sv_2uv
-Perl_sv_2uv_flags
-Perl_sv_backoff
-Perl_sv_bless
-Perl_sv_cat_decode
-Perl_sv_catpv
-Perl_sv_catpv_mg
-Perl_sv_catpvf
-Perl_sv_catpvf_mg
-Perl_sv_catpvf_mg_nocontext
-Perl_sv_catpvf_nocontext
-Perl_sv_catpvn
-Perl_sv_catpvn_flags
-Perl_sv_catpvn_mg
-Perl_sv_catsv
-Perl_sv_catsv_flags
-Perl_sv_catsv_mg
-Perl_sv_chop
-Perl_sv_clear
-Perl_sv_cmp
-Perl_sv_cmp_locale
-Perl_sv_collxfrm
-Perl_sv_compile_2op
-Perl_sv_copypv
-Perl_sv_dec
-Perl_sv_derived_from
-Perl_sv_destroyable
-Perl_sv_does
-Perl_sv_dump
-Perl_sv_dup
-Perl_sv_eq
-Perl_sv_force_normal
-Perl_sv_force_normal_flags
-Perl_sv_free
-Perl_sv_free2
-Perl_sv_gets
-Perl_sv_grow
-Perl_sv_inc
-Perl_sv_insert
-Perl_sv_insert_flags
-Perl_sv_isa
-Perl_sv_isobject
-Perl_sv_iv
-Perl_sv_len
-Perl_sv_len_utf8
-Perl_sv_magic
-Perl_sv_magicext
-Perl_sv_mortalcopy
-Perl_sv_newmortal
-Perl_sv_newref
-Perl_sv_nolocking
-Perl_sv_nosharing
-Perl_sv_nounlocking
-Perl_sv_nv
-Perl_sv_peek
-Perl_sv_pos_b2u
-Perl_sv_pos_u2b
-Perl_sv_pos_u2b_flags
-Perl_sv_pv
-Perl_sv_pvbyte
-Perl_sv_pvbyten
-Perl_sv_pvbyten_force
-Perl_sv_pvn
-Perl_sv_pvn_force
-Perl_sv_pvn_force_flags
-Perl_sv_pvn_nomg
-Perl_sv_pvutf8
-Perl_sv_pvutf8n
-Perl_sv_pvutf8n_force
-Perl_sv_recode_to_utf8
-Perl_sv_reftype
-Perl_sv_replace
-Perl_sv_report_used
-Perl_sv_reset
-Perl_sv_rvweaken
-Perl_sv_setiv
-Perl_sv_setiv_mg
-Perl_sv_setnv
-Perl_sv_setnv_mg
-Perl_sv_setpv
-Perl_sv_setpv_mg
-Perl_sv_setpvf
-Perl_sv_setpvf_mg
-Perl_sv_setpvf_mg_nocontext
-Perl_sv_setpvf_nocontext
-Perl_sv_setpviv
-Perl_sv_setpviv_mg
-Perl_sv_setpvn
-Perl_sv_setpvn_mg
-Perl_sv_setref_iv
-Perl_sv_setref_nv
-Perl_sv_setref_pv
-Perl_sv_setref_pvn
-Perl_sv_setref_uv
-Perl_sv_setsv
-Perl_sv_setsv_flags
-Perl_sv_setsv_mg
-Perl_sv_setuv
-Perl_sv_setuv_mg
-Perl_sv_taint
-Perl_sv_tainted
-Perl_sv_true
-Perl_sv_uni_display
-Perl_sv_unmagic
-Perl_sv_unref
-Perl_sv_unref_flags
-Perl_sv_untaint
-Perl_sv_upgrade
-Perl_sv_usepvn
-Perl_sv_usepvn_flags
-Perl_sv_usepvn_mg
-Perl_sv_utf8_decode
-Perl_sv_utf8_downgrade
-Perl_sv_utf8_encode
-Perl_sv_utf8_upgrade
-Perl_sv_utf8_upgrade_flags_grow
-Perl_sv_uv
-Perl_sv_vcatpvf
-Perl_sv_vcatpvf_mg
-Perl_sv_vcatpvfn
-Perl_sv_vsetpvf
-Perl_sv_vsetpvf_mg
-Perl_sv_vsetpvfn
-Perl_swash_fetch
-Perl_swash_init
-Perl_sys_init
-Perl_sys_init3
-Perl_sys_intern_clear
-Perl_sys_intern_dup
-Perl_sys_intern_init
-Perl_sys_term
-Perl_taint_env
-Perl_taint_proper
-Perl_tmps_grow
-Perl_to_uni_fold
-Perl_to_uni_lower
-Perl_to_uni_lower_lc
-Perl_to_uni_title
-Perl_to_uni_title_lc
-Perl_to_uni_upper
-Perl_to_uni_upper_lc
-Perl_to_utf8_case
-Perl_to_utf8_fold
-Perl_to_utf8_lower
-Perl_to_utf8_title
-Perl_to_utf8_upper
-Perl_unpack_str
-Perl_unpackstring
-Perl_unsharepvn
-Perl_upg_version
-Perl_utf16_to_utf8
-Perl_utf16_to_utf8_reversed
-Perl_utf8_distance
-Perl_utf8_hop
-Perl_utf8_length
-Perl_utf8_to_bytes
-Perl_utf8_to_uvchr
-Perl_utf8_to_uvuni
-Perl_utf8n_to_uvchr
-Perl_utf8n_to_uvuni
-Perl_uvchr_to_utf8
-Perl_uvchr_to_utf8_flags
-Perl_uvuni_to_utf8
-Perl_uvuni_to_utf8_flags
-Perl_vcmp
-Perl_vcroak
-Perl_vdeb
-Perl_vform
-Perl_vivify_defelem
-Perl_vload_module
-Perl_vmess
-Perl_vnewSVpvf
-Perl_vnormal
-Perl_vnumify
-Perl_vstringify
-Perl_vverify
-Perl_vwarn
-Perl_vwarner
-Perl_warn
-Perl_warn_nocontext
-Perl_warner
-Perl_warner_nocontext
-Perl_whichsig
-Perl_win32_init
-Perl_win32_term
-Perl_yylex
-RunPerl
-boot_DynaLoader
-boot_Win32CORE
-init_Win32CORE
-perl_alloc
-perl_alloc_override
-perl_alloc_using
-perl_clone
-perl_clone_host
-perl_clone_using
-perl_construct
-perl_destruct
-perl_free
-perl_get_host_info
-perl_parse
-perl_run
-perlsio_binmode
-setgid
-setuid
-win32_abort
-win32_accept
-win32_access
-win32_alarm
-win32_ansipath
-win32_async_check
-win32_bind
-win32_calloc
-win32_chdir
-win32_chmod
-win32_chsize
-win32_clearenv
-win32_clearerr
-win32_close
-win32_closedir
-win32_closesocket
-win32_connect
-win32_crypt
-win32_dup
-win32_dup2
-win32_dynaload
-win32_endhostent
-win32_endnetent
-win32_endprotoent
-win32_endservent
-win32_environ
-win32_eof
-win32_errno
-win32_execv
-win32_execvp
-win32_fclose
-win32_fcloseall
-win32_fdopen
-win32_feof
-win32_ferror
-win32_fflush
-win32_fgetc
-win32_fgetpos
-win32_fgets
-win32_fileno
-win32_flock
-win32_flushall
-win32_fopen
-win32_fprintf
-win32_fputc
-win32_fputs
-win32_fread
-win32_free
-win32_free_childdir
-win32_free_childenv
-win32_freopen
-win32_fseek
-win32_fsetpos
-win32_fstat
-win32_ftell
-win32_fwrite
-win32_get_childdir
-win32_get_childenv
-win32_get_osfhandle
-win32_getc
-win32_getchar
-win32_getenv
-win32_gethostbyaddr
-win32_gethostbyname
-win32_gethostname
-win32_getnetbyaddr
-win32_getnetbyname
-win32_getnetent
-win32_getpeername
-win32_getpid
-win32_getprotobyname
-win32_getprotobynumber
-win32_getprotoent
-win32_gets
-win32_getservbyname
-win32_getservbyport
-win32_getservent
-win32_getsockname
-win32_getsockopt
-win32_gettimeofday
-win32_htonl
-win32_htons
-win32_inet_addr
-win32_inet_ntoa
-win32_ioctl
-win32_ioctlsocket
-win32_isatty
-win32_kill
-win32_link
-win32_listen
-win32_longpath
-win32_lseek
-win32_malloc
-win32_mkdir
-win32_ntohl
-win32_ntohs
-win32_open
-win32_open_osfhandle
-win32_opendir
-win32_os_id
-win32_pclose
-win32_perror
-win32_pipe
-win32_popen
-win32_printf
-win32_putc
-win32_putchar
-win32_putenv
-win32_puts
-win32_read
-win32_readdir
-win32_realloc
-win32_recv
-win32_recvfrom
-win32_rename
-win32_rewind
-win32_rewinddir
-win32_rmdir
-win32_seekdir
-win32_select
-win32_send
-win32_sendto
-win32_setbuf
-win32_sethostent
-win32_setmode
-win32_setnetent
-win32_setprotoent
-win32_setservent
-win32_setsockopt
-win32_setvbuf
-win32_shutdown
-win32_sleep
-win32_socket
-win32_spawnvp
-win32_stat
-win32_stderr
-win32_stdin
-win32_stdout
-win32_str_os_error
-win32_strerror
-win32_tell
-win32_telldir
-win32_times
-win32_tmpfile
-win32_uname
-win32_ungetc
-win32_unlink
-win32_utime
-win32_vfprintf
-win32_vprintf
-win32_wait
-win32_waitpid
-win32_write
-- 
cgit 1.4.1


From 551576daf3c2c0e4841cbb2f06e534cb6e6240c9 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sat, 3 Dec 2011 21:50:39 +0100
Subject: omit library manager banner

---
 plugins/perl/makefile-512.mak | 4 ++--
 plugins/perl/makefile-514.mak | 4 ++--
 2 files changed, 4 insertions(+), 4 deletions(-)

(limited to 'plugins')

diff --git a/plugins/perl/makefile-512.mak b/plugins/perl/makefile-512.mak
index 9fcb29a2..677c9073 100644
--- a/plugins/perl/makefile-512.mak
+++ b/plugins/perl/makefile-512.mak
@@ -19,9 +19,9 @@ perl512.def:
 
 $(PERL512LIB).lib: perl512.def
 !ifdef X64
-	lib /machine:x64 /def:perl512.def
+	lib /nologo /machine:x64 /def:perl512.def
 !else
-	lib /machine:x86 /def:perl512.def
+	lib /nologo /machine:x86 /def:perl512.def
 !endif
 
 perl.c: xchat.pm.h
diff --git a/plugins/perl/makefile-514.mak b/plugins/perl/makefile-514.mak
index 0eadd344..c31a7ec4 100644
--- a/plugins/perl/makefile-514.mak
+++ b/plugins/perl/makefile-514.mak
@@ -21,9 +21,9 @@ perl514.def:
 
 $(PERL514LIB).lib: perl514.def
 !ifdef X64
-	lib /machine:x64 /def:perl514.def
+	lib /nologo /machine:x64 /def:perl514.def
 !else
-	lib /machine:x86 /def:perl514.def
+	lib /nologo /machine:x86 /def:perl514.def
 !endif
 
 perl.c: xchat.pm.h
-- 
cgit 1.4.1


From 370cb88c44193f6c3e53765511463da3b70f141f Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Tue, 6 Dec 2011 02:35:00 +0100
Subject: typofix

---
 plugins/winsys/winsys.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/winsys/winsys.cpp b/plugins/winsys/winsys.cpp
index 0b4aef1e..1a58f26a 100644
--- a/plugins/winsys/winsys.cpp
+++ b/plugins/winsys/winsys.cpp
@@ -58,7 +58,7 @@ getCpuArch (void)
 }
 
 #if 0
-/* use WMI instead, wProcessorArchitecture displays current binary arch instead OS arch anyway */
+/* use WMI instead, wProcessorArchitecture displays current binary arch instead of OS arch anyway */
 static char *
 getOsName (void)
 {
-- 
cgit 1.4.1


From 1b84f0467a169e2b20018dce0787973a0ba52273 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Tue, 6 Dec 2011 02:36:26 +0100
Subject: forgot to bump version

---
 plugins/winsys/winsys.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/winsys/winsys.cpp b/plugins/winsys/winsys.cpp
index 1a58f26a..398767d0 100644
--- a/plugins/winsys/winsys.cpp
+++ b/plugins/winsys/winsys.cpp
@@ -30,7 +30,7 @@
 static xchat_plugin *ph;   /* plugin handle */
 static char name[] = "WinSys";
 static char desc[] = "Display info about your hardware and OS";
-static char version[] = "1.0";
+static char version[] = "1.1";
 static int firstRun;
 static char *wmiOs;
 static char *wmiCpu;
-- 
cgit 1.4.1


From 132ef6cb50201cb6ab8ab0609a88ccce62aa6a21 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sun, 11 Dec 2011 17:34:02 +0100
Subject: initial patches for linux compatibility

---
 plugins/perl/perl.c           |  2 +-
 plugins/perl/perl.def         |  4 +++
 plugins/python/python.c       |  6 ++++
 plugins/tcl/tclplugin.c       |  2 ++
 plugins/xdcc/xdcc.c           |  4 +++
 src/common/cfgfiles.c         | 20 +++++++++---
 src/common/chanopt.c          |  4 +++
 src/common/ctcp.c             |  9 ++++++
 src/common/dcc.c              |  8 ++++-
 src/common/ignore.c           |  4 +++
 src/common/inbound.c          |  4 +++
 src/common/makefile.mak       |  1 -
 src/common/msproxy.c          |  4 +++
 src/common/network.c          |  4 +++
 src/common/notify.c           |  4 +++
 src/common/outbound.c         |  7 ++++-
 src/common/plugin-timer.c     |  2 +-
 src/common/proto-irc.c        |  4 +++
 src/common/server.c           |  5 +++
 src/common/servlist.c         |  4 +++
 src/common/text.c             | 71 +++++++++++++++++++++++++++++++++++++++++++
 src/common/util.c             | 42 +++++++++++++++++++++++--
 src/common/util.h             |  2 ++
 src/common/wdkutil.c          | 27 ----------------
 src/common/wdkutil.h          |  2 --
 src/common/xchat.c            |  4 +--
 src/common/xchat.h            |  4 +++
 src/fe-gtk/about.c            |  4 +--
 src/fe-gtk/banlist.c          |  4 +++
 src/fe-gtk/chanlist.c         |  4 +++
 src/fe-gtk/editlist.c         |  5 +++
 src/fe-gtk/fe-gtk.c           |  6 +++-
 src/fe-gtk/fkeys.c            |  6 +++-
 src/fe-gtk/gtkutil.c          |  4 +++
 src/fe-gtk/joind.c            |  4 +++
 src/fe-gtk/maingui.c          |  3 +-
 src/fe-gtk/menu.c             |  8 ++++-
 src/fe-gtk/palette.c          |  4 +++
 src/fe-gtk/plugin-tray.c      | 18 ++++++++---
 src/fe-gtk/plugingui.c        |  9 ++++--
 src/fe-gtk/rawlog.c           |  4 +++
 src/fe-gtk/setup.c            | 13 ++++++--
 src/fe-gtk/sexy-spell-entry.c | 11 +++++++
 src/fe-gtk/xtext.c            |  2 ++
 44 files changed, 304 insertions(+), 59 deletions(-)
 create mode 100644 plugins/perl/perl.def
 delete mode 100644 src/common/wdkutil.c
 delete mode 100644 src/common/wdkutil.h

(limited to 'plugins')

diff --git a/plugins/perl/perl.c b/plugins/perl/perl.c
index a454b43d..a2763771 100644
--- a/plugins/perl/perl.c
+++ b/plugins/perl/perl.c
@@ -27,7 +27,7 @@
 #endif
 #ifdef WIN32
 #include <windows.h>
-#define  _INC_DIRENT
+#define  _INC_DIRENT /* disable inclusion of perl's dirent.h, we use an own version for win32 */
 #include "../../src/common/dirent.h"
 #else
 #include <dirent.h>
diff --git a/plugins/perl/perl.def b/plugins/perl/perl.def
new file mode 100644
index 00000000..a2ec6566
--- /dev/null
+++ b/plugins/perl/perl.def
@@ -0,0 +1,4 @@
+EXPORTS
+  xchat_plugin_init
+  xchat_plugin_deinit
+  xchat_plugin_get_info
\ No newline at end of file
diff --git a/plugins/python/python.c b/plugins/python/python.c
index 55adf989..3c535057 100644
--- a/plugins/python/python.c
+++ b/plugins/python/python.c
@@ -55,8 +55,14 @@
 #include <string.h>
 #include <stdlib.h>
 #include <sys/types.h>
+
+#ifdef WIN32
 #include "../../src/common/dirent.h"
 #include "../../config.h"
+#else
+#include <unistd.h>
+#include <dirent.h>
+#endif
 
 #include "xchat-plugin.h"
 #include "Python.h"
diff --git a/plugins/tcl/tclplugin.c b/plugins/tcl/tclplugin.c
index 9289d01d..920a48ad 100644
--- a/plugins/tcl/tclplugin.c
+++ b/plugins/tcl/tclplugin.c
@@ -32,6 +32,8 @@ static char RCSID[] = "$Id: tclplugin.c,v 1.64 2010/03/10 04:24:16 mooooooo Exp
 #include <windows.h>
 #define bzero(mem, sz) memset((mem), 0, (sz))
 #define bcopy(src, dest, count) memmove((dest), (src), (count))
+#else
+#include <unistd.h>
 #endif
 
 #include "xchat-plugin.h"
diff --git a/plugins/xdcc/xdcc.c b/plugins/xdcc/xdcc.c
index a8fda540..060dbbe3 100644
--- a/plugins/xdcc/xdcc.c
+++ b/plugins/xdcc/xdcc.c
@@ -5,6 +5,10 @@
 #include <stdlib.h>
 #include <stdio.h>
 
+#ifndef WIN32
+#include <unistd.h>
+#endif
+
 #include "xchat-plugin.h"
 #include "../../src/common/xchat.h"
 
diff --git a/src/common/cfgfiles.c b/src/common/cfgfiles.c
index 22ef00d7..130ad9d9 100644
--- a/src/common/cfgfiles.c
+++ b/src/common/cfgfiles.c
@@ -29,11 +29,12 @@
 #include "fe.h"
 #include "text.h"
 #include "xchatc.h"
-#include "wdkutil.h"
 
 #ifndef WIN32
+#include <unistd.h>
 #define XCHAT_DIR ".xchat2"
 #endif
+
 #define DEF_FONT "Monospace 9"
 
 void
@@ -402,7 +403,9 @@ const struct prefs vars[] = {
 	{"dcc_blocksize", P_OFFINT (dcc_blocksize), TYPE_INT},
 	{"dcc_completed_dir", P_OFFSET (dcc_completed_dir), TYPE_STR},
 	{"dcc_dir", P_OFFSET (dccdir), TYPE_STR},
-	/* {"dcc_fast_send", P_OFFINT (fastdccsend), TYPE_BOOL}, */
+#ifndef WIN32
+	{"dcc_fast_send", P_OFFINT (fastdccsend), TYPE_BOOL},
+#endif
 	{"dcc_global_max_get_cps", P_OFFINT (dcc_global_max_get_cps), TYPE_INT},
 	{"dcc_global_max_send_cps", P_OFFINT (dcc_global_max_send_cps), TYPE_INT},
 	{"dcc_ip", P_OFFSET (dcc_ip_str), TYPE_STR},
@@ -440,7 +443,9 @@ const struct prefs vars[] = {
 	{"gui_lagometer", P_OFFINT (lagometer), TYPE_INT},
 	{"gui_license", P_OFFSET (gui_license), TYPE_STR},
 	{"gui_mode_buttons", P_OFFINT (chanmodebuttons), TYPE_BOOL},
+#ifdef WIN32
 	{"gui_one_instance", P_OFFINT (gui_one_instance), TYPE_BOOL},
+#endif
 	{"gui_pane_left_size", P_OFFINT (gui_pane_left_size), TYPE_INT},
 	{"gui_pane_right_size", P_OFFINT (gui_pane_right_size), TYPE_INT},
 	{"gui_quit_dialog", P_OFFINT (gui_quit_dialog), TYPE_BOOL},
@@ -547,7 +552,9 @@ const struct prefs vars[] = {
 
 	{"tab_chans", P_OFFINT (tabchannels), TYPE_BOOL},
 	{"tab_dialogs", P_OFFINT (privmsgtab), TYPE_BOOL},
+#ifdef WIN32
 	{"tab_icons", P_OFFINT (tab_icons), TYPE_BOOL},
+#endif
 	{"tab_layout", P_OFFINT (tab_layout), TYPE_INT},
 	{"tab_new_to_front", P_OFFINT (newtabstofront), TYPE_INT},
 	{"tab_notices", P_OFFINT (notices_tabs), TYPE_BOOL},
@@ -558,14 +565,18 @@ const struct prefs vars[] = {
 	{"tab_sort", P_OFFINT (tab_sort), TYPE_BOOL},
 	{"tab_trunc", P_OFFINT (truncchans), TYPE_INT},
 	{"tab_utils", P_OFFINT (windows_as_tabs), TYPE_BOOL},
+#ifdef WIN32
 	{"tab_xp", P_OFFINT (tab_xp), TYPE_BOOL},
+#endif
 
 	{"text_auto_copy_color", P_OFFINT (autocopy_color), TYPE_BOOL},	
 	{"text_auto_copy_stamp", P_OFFINT (autocopy_stamp), TYPE_BOOL},
 	{"text_auto_copy_text", P_OFFINT (autocopy_text), TYPE_BOOL},
 	{"text_background", P_OFFSET (background), TYPE_STR},
 	{"text_color_nicks", P_OFFINT (colorednicks), TYPE_BOOL},
+#ifdef WIN32
 	{"text_emoticons", P_OFFINT (emoticons), TYPE_BOOL},
+#endif
 	{"text_font", P_OFFSET (font_normal), TYPE_STR},
 	{"text_indent", P_OFFINT (indent_nicks), TYPE_BOOL},
 	{"text_max_indent", P_OFFINT (max_auto_indent), TYPE_INT},
@@ -642,7 +653,9 @@ load_config (void)
 	prefs.indent_nicks = 1;
 	prefs.thin_separator = 1;
 	prefs._tabs_position = 2; /* 2 = left */
-	/* prefs.fastdccsend = 1; */
+#ifndef WIN32
+	prefs.fastdccsend = 1;
+#endif
 	prefs.wordwrap = 1;
 	prefs.autosave = 1;
 	prefs.autodialog = 1;
@@ -667,7 +680,6 @@ load_config (void)
 	prefs.dialog_height = 256;
 	prefs.gui_join_dialog = 1;
 	prefs.gui_quit_dialog = 1;
-	prefs.slist_skip = 1;
 	prefs.dcctimeout = 180;
 	prefs.dccstalltimeout = 60;
 	prefs.notify_timeout = 15;
diff --git a/src/common/chanopt.c b/src/common/chanopt.c
index ce37157a..f8e16e8b 100644
--- a/src/common/chanopt.c
+++ b/src/common/chanopt.c
@@ -8,6 +8,10 @@
 #include <fcntl.h>
 #include <errno.h>
 
+#ifndef WIN32
+#include <unistd.h>
+#endif
+
 #include "xchat.h"
 
 #include "cfgfiles.h"
diff --git a/src/common/ctcp.c b/src/common/ctcp.c
index 37392372..2bb75746 100644
--- a/src/common/ctcp.c
+++ b/src/common/ctcp.c
@@ -20,6 +20,10 @@
 #include <string.h>
 #include <stdlib.h>
 
+#ifndef WIN32
+#include <unistd.h>
+#endif
+
 #include "xchat.h"
 #include "cfgfiles.h"
 #include "util.h"
@@ -133,8 +137,13 @@ ctcp_handle (session *sess, char *to, char *nick, char *ip,
 
 	if (!strcasecmp (msg, "VERSION") && !prefs.hidever)
 	{
+#ifdef WIN32
 		snprintf (outbuf, sizeof (outbuf), "VERSION XChat-WDK "PACKAGE_VERSION" [x%d] / %s",
 					 get_cpu_arch (), get_cpu_str ());
+#else
+		snprintf (outbuf, sizeof (outbuf), "VERSION XChat-WDK "PACKAGE_VERSION" %s",
+					 get_cpu_str ());
+#endif
 		serv->p_nctcp (serv, nick, outbuf);
 	}
 
diff --git a/src/common/dcc.c b/src/common/dcc.c
index 9375095e..d91b7e8e 100644
--- a/src/common/dcc.c
+++ b/src/common/dcc.c
@@ -40,6 +40,8 @@
 
 #ifdef WIN32
 #include <windows.h>
+#else
+#include <unistd.h>
 #endif
 
 #include "xchat.h"
@@ -56,7 +58,9 @@
 
 #ifdef USE_DCC64
 #define BIG_STR_TO_INT(x) strtoull(x,NULL,10)
+#ifdef WIN32
 #define stat _stat64
+#endif
 #else
 #define BIG_STR_TO_INT(x) strtoul(x,NULL,10)
 #endif
@@ -1983,7 +1987,9 @@ is_same_file (struct DCC *dcc, struct DCC *new_dcc)
 		return TRUE;
 
 	/* now handle case-insensitive Filesystems: HFS+, FAT */
-#ifndef WIN32
+#ifdef WIN32
+	/* warning no win32 implementation - behaviour may be unreliable */
+#else
 	/* this fstat() shouldn't really fail */
 	if ((dcc->fp == -1 ? stat (dcc->destfile_fs, &st_a) : fstat (dcc->fp, &st_a)) == -1)
 		return FALSE;
diff --git a/src/common/ignore.c b/src/common/ignore.c
index adb61f37..0ed23daa 100644
--- a/src/common/ignore.c
+++ b/src/common/ignore.c
@@ -23,6 +23,10 @@
 #include <sys/stat.h>
 #include <fcntl.h>
 
+#ifndef WIN32
+#include <unistd.h>
+#endif
+
 #include "xchat.h"
 #include "ignore.h"
 #include "cfgfiles.h"
diff --git a/src/common/inbound.c b/src/common/inbound.c
index 3485dfd4..bd7252c5 100644
--- a/src/common/inbound.c
+++ b/src/common/inbound.c
@@ -23,6 +23,10 @@
 #include <sys/types.h>
 #include <time.h>
 
+#ifndef WIN32
+#include <unistd.h>
+#endif
+
 #define WANTARPA
 #define WANTDNS
 #include "inet.h"
diff --git a/src/common/makefile.mak b/src/common/makefile.mak
index 424316c0..8b350efc 100644
--- a/src/common/makefile.mak
+++ b/src/common/makefile.mak
@@ -25,7 +25,6 @@ tree.obj \
 url.obj \
 userlist.obj \
 util.obj \
-wdkutil.obj \
 xchat.obj
 
 all: $(COMMON_OBJECTS) xchatcommon.lib dirent.lib
diff --git a/src/common/msproxy.c b/src/common/msproxy.c
index 8ad37ffc..5103233a 100644
--- a/src/common/msproxy.c
+++ b/src/common/msproxy.c
@@ -28,6 +28,10 @@
 #include <stdlib.h>
 #include <fcntl.h>
 
+#ifndef WIN32
+#include <unistd.h>
+#endif
+
 #define WANTSOCKET
 #define WANTARPA
 #include "inet.h"
diff --git a/src/common/network.c b/src/common/network.c
index b7d9aa1f..eba24b05 100644
--- a/src/common/network.c
+++ b/src/common/network.c
@@ -23,6 +23,10 @@
 #include <stdio.h>
 #include <glib.h>
 
+#ifndef WIN32
+#include <unistd.h>
+#endif
+
 #include "../../config.h"				  /* grab USE_IPV6 and LOOKUPD defines */
 
 #define WANTSOCKET
diff --git a/src/common/notify.c b/src/common/notify.c
index 4aa5ea17..9c6e54de 100644
--- a/src/common/notify.c
+++ b/src/common/notify.c
@@ -24,6 +24,10 @@
 #include <fcntl.h>
 #include <time.h>
 
+#ifndef WIN32
+#include <unistd.h>
+#endif
+
 #include "xchat.h"
 #include "notify.h"
 #include "cfgfiles.h"
diff --git a/src/common/outbound.c b/src/common/outbound.c
index 917562b9..8b0432ec 100644
--- a/src/common/outbound.c
+++ b/src/common/outbound.c
@@ -30,6 +30,7 @@
 
 #ifndef WIN32
 #include <sys/wait.h>
+#include <unistd.h>
 #endif
 
 #include <time.h>
@@ -2880,6 +2881,7 @@ cmd_recv (struct session *sess, char *tbuf, char *word[], char *word_eol[])
 	return FALSE;
 }
 
+#if 0 /* manual command for flushing prefs to disk, but we use an autosave-upon-set approach instead */
 static int
 cmd_saveconf (struct session *sess, char *tbuf, char *word[], char *word_eol[])
 {
@@ -2894,6 +2896,7 @@ cmd_saveconf (struct session *sess, char *tbuf, char *word[], char *word_eol[])
 
 	return TRUE;
 }
+#endif
 
 static int
 cmd_say (struct session *sess, char *tbuf, char *word[], char *word_eol[])
@@ -3647,7 +3650,9 @@ const struct commands xc_cmds[] = {
 #endif
 	{"RECV", cmd_recv, 1, 0, 1, N_("RECV <text>, send raw data to xchat, as if it was received from the irc server")},
 
-	/*{"SAVECONF", cmd_saveconf, 0, 0, 1, N_("SAVECONF, saves the current settings to disk")},*/
+#if 0
+	{"SAVECONF", cmd_saveconf, 0, 0, 1, N_("SAVECONF, saves the current settings to disk")},
+#endif
 	{"SAY", cmd_say, 0, 0, 1,
 	 N_("SAY <text>, sends the text to the object in the current window")},
 	{"SEND", cmd_send, 0, 0, 1, N_("SEND <nick> [<file>]")},
diff --git a/src/common/plugin-timer.c b/src/common/plugin-timer.c
index 2524439d..f09074a8 100644
--- a/src/common/plugin-timer.c
+++ b/src/common/plugin-timer.c
@@ -1,7 +1,7 @@
 #include <stdlib.h>
 #include <string.h>
 #include <glib.h>
-#include "../../plugins/xchat-plugin.h"
+#include "xchat-plugin.h"
 
 #ifdef WIN32
 #define strcasecmp stricmp
diff --git a/src/common/proto-irc.c b/src/common/proto-irc.c
index 3d45e1b0..91a57abe 100644
--- a/src/common/proto-irc.c
+++ b/src/common/proto-irc.c
@@ -24,6 +24,10 @@
 #include <ctype.h>
 #include <stdarg.h>
 
+#ifndef WIN32
+#include <unistd.h>
+#endif
+
 #include "xchat.h"
 #include "ctcp.h"
 #include "fe.h"
diff --git a/src/common/server.c b/src/common/server.c
index f7347052..cdd67cda 100644
--- a/src/common/server.c
+++ b/src/common/server.c
@@ -36,6 +36,7 @@
 #ifndef WIN32
 #include <signal.h>
 #include <sys/wait.h>
+#include <unistd.h>
 #else
 #include <winbase.h>
 #endif
@@ -1763,7 +1764,11 @@ server_connect (server *serv, char *hostname, int port, int no_login)
 	}
 #endif
 	serv->childpid = pid;
+#ifdef WIN32
 	serv->iotag = fe_input_add (serv->childread, FIA_READ|FIA_FD, server_read_child,
+#else
+	serv->iotag = fe_input_add (serv->childread, FIA_READ, server_read_child,
+#endif
 										 serv);
 }
 
diff --git a/src/common/servlist.c b/src/common/servlist.c
index 1ca63201..a94c260a 100644
--- a/src/common/servlist.c
+++ b/src/common/servlist.c
@@ -22,6 +22,10 @@
 #include <sys/types.h>
 #include <sys/stat.h>
 
+#ifndef WIN32
+#include <unistd.h>
+#endif
+
 #include "xchat.h"
 #include <glib/ghash.h>
 
diff --git a/src/common/text.c b/src/common/text.c
index fcde5870..fd5d25e9 100644
--- a/src/common/text.c
+++ b/src/common/text.c
@@ -25,6 +25,11 @@
 #include <fcntl.h>
 #include <sys/stat.h>
 
+#ifndef WIN32
+#include <unistd.h>
+#include <sys/mman.h>
+#endif
+
 #include "xchat.h"
 #include <glib/ghash.h>
 #include "cfgfiles.h"
@@ -270,6 +275,12 @@ scrollback_load (session *sess)
 	time_t stamp;
 	int lines;
 
+#ifndef WIN32
+	char *map, *end_map;
+	struct stat statbuf;
+	const char *begin, *eol;
+#endif
+
 	if (sess->text_scrollback == SET_DEFAULT)
 	{
 		if (!prefs.text_replay)
@@ -288,6 +299,65 @@ scrollback_load (session *sess)
 	if (fh == -1)
 		return;
 
+#ifndef WIN32
+	if (fstat (fh, &statbuf) < 0)
+		return;
+
+	map = mmap (NULL, statbuf.st_size, PROT_READ, MAP_PRIVATE, fh, 0);
+	if (map == MAP_FAILED)
+		return;
+
+	end_map = map + statbuf.st_size;
+
+	lines = 0;
+	begin = map;
+	while (begin < end_map)
+	{
+		int n_bytes;
+
+		eol = memchr (begin, '\n', end_map - begin);
+
+		if (!eol)
+			eol = end_map;
+
+		n_bytes = MIN (eol - begin, sizeof (buf) - 1);
+
+		strncpy (buf, begin, n_bytes);
+
+		buf[n_bytes] = 0;
+
+		if (buf[0] == 'T')
+		{
+			if (sizeof (time_t) == 4)
+				stamp = strtoul (buf + 2, NULL, 10);
+			else
+				stamp = strtoull (buf + 2, NULL, 10); /* just incase time_t is 64 bits */
+			text = strchr (buf + 3, ' ');
+			if (text)
+			{
+				text = strip_color (text + 1, -1, STRIP_COLOR);
+				fe_print_text (sess, text, stamp);
+				g_free (text);
+			}
+			lines++;
+		}
+
+		begin = eol + 1;
+	}
+
+	sess->scrollwritten = lines;
+
+	if (lines)
+	{
+		text = ctime (&stamp);
+		text[24] = 0;	/* get rid of the \n */
+		snprintf (buf, sizeof (buf), "\n*\t%s %s\n\n", _("Loaded log from"), text);
+		fe_print_text (sess, buf, 0);
+		/*EMIT_SIGNAL (XP_TE_GENMSG, sess, "*", buf, NULL, NULL, NULL, 0);*/
+	}
+
+	munmap (map, statbuf.st_size);
+#else
 	lines = 0;
 	while (waitline (fh, buf, sizeof buf, FALSE) != -1)
 	{
@@ -318,6 +388,7 @@ scrollback_load (session *sess)
 		fe_print_text (sess, buf, 0);
 		/*EMIT_SIGNAL (XP_TE_GENMSG, sess, "*", buf, NULL, NULL, NULL, 0);*/
 	}
+#endif
 
 	close (fh);
 }
diff --git a/src/common/util.c b/src/common/util.c
index c16d41f5..ccc48657 100644
--- a/src/common/util.c
+++ b/src/common/util.c
@@ -27,17 +27,21 @@
 #include <stdlib.h>
 #include <sys/types.h>
 #include <sys/stat.h>
+
 #ifdef WIN32
 #include <sys/timeb.h>
 #include <process.h>
+#include <io.h>
+#include "dirent.h"
 #else
-#include <sys/types.h>
+#include <unistd.h>
 #include <pwd.h>
 #include <sys/time.h>
 #include <sys/utsname.h>
+#include <dirent.h>
 #endif
+
 #include <fcntl.h>
-#include "dirent.h"
 #include <errno.h>
 #include "xchat.h"
 #include "xchatc.h"
@@ -1848,3 +1852,37 @@ canonalize_key (char *key)
 		}
 	}
 }
+
+int
+portable_mode ()
+{
+#ifdef WIN32
+	if ((_access( "portable-mode", 0 )) != -1)
+	{
+		return 1;
+	}
+	else
+	{
+		return 0;
+	}
+#else
+	return 0;
+#endif
+}
+
+int
+xtray_mode ()
+{
+#ifdef WIN32
+	if ((_access( "plugins/xtray.dll", 0 )) != -1)
+	{
+		return 1;
+	}
+	else
+	{
+		return 0;
+	}
+#else
+	return 0;
+#endif
+}
diff --git a/src/common/util.h b/src/common/util.h
index bee6ec3c..82d74366 100644
--- a/src/common/util.h
+++ b/src/common/util.h
@@ -57,5 +57,7 @@ guint32 str_hash (const char *key);
 guint32 str_ihash (const unsigned char *key);
 void safe_strcpy (char *dest, const char *src, int bytes_left);
 void canonalize_key (char *key);
+int portable_mode ();
+int xtray_mode ();
 
 #endif
diff --git a/src/common/wdkutil.c b/src/common/wdkutil.c
deleted file mode 100644
index 5bf4f0c0..00000000
--- a/src/common/wdkutil.c
+++ /dev/null
@@ -1,27 +0,0 @@
-#include <io.h>
-
-int
-portable_mode ()
-{
-	if ((_access( "portable-mode", 0 )) != -1)
-	{
-		return 1;
-	}
-	else
-	{
-		return 0;
-	}
-}
-
-int
-xtray_mode ()
-{
-	if ((_access( "plugins/xtray.dll", 0 )) != -1)
-	{
-		return 1;
-	}
-	else
-	{
-		return 0;
-	}
-}
diff --git a/src/common/wdkutil.h b/src/common/wdkutil.h
deleted file mode 100644
index 2e4c693a..00000000
--- a/src/common/wdkutil.h
+++ /dev/null
@@ -1,2 +0,0 @@
-int portable_mode ();
-int xtray_mode ();
diff --git a/src/common/xchat.c b/src/common/xchat.c
index c0847a32..22c4eddb 100644
--- a/src/common/xchat.c
+++ b/src/common/xchat.c
@@ -31,6 +31,7 @@
 #else
 #include <sys/wait.h>
 #include <signal.h>
+#include <unistd.h>
 #endif
 
 #include "xchat.h"
@@ -39,7 +40,7 @@
 #include "cfgfiles.h"
 #include "chanopt.h"
 #include "ignore.h"
-#include "../../plugins/xchat-plugin.h"
+#include "xchat-plugin.h"
 #include "plugin.h"
 #include "plugin-timer.h"
 #include "notify.h"
@@ -49,7 +50,6 @@
 #include "text.h"
 #include "url.h"
 #include "xchatc.h"
-#include "wdkutil.h"
 
 #ifdef USE_OPENSSL
 #include <openssl/ssl.h>		  /* SSL_() */
diff --git a/src/common/xchat.h b/src/common/xchat.h
index 08177e20..91e2d50e 100644
--- a/src/common/xchat.h
+++ b/src/common/xchat.h
@@ -186,7 +186,9 @@ struct xchatprefs
 	int gui_usermenu;
 	int gui_join_dialog;
 	int gui_quit_dialog;
+#ifdef WIN32
 	int gui_one_instance;
+#endif
 	int dialog_left;
 	int dialog_top;
 	int dialog_width;
@@ -304,10 +306,12 @@ struct xchatprefs
 	unsigned int wait_on_exit;
 	unsigned int confmode;
 	unsigned int utf8_locale;
+#ifdef WIN32
 	unsigned int identd;
 	unsigned int emoticons;
 	unsigned int tab_icons;
 	unsigned int tab_xp;
+#endif
 
 	unsigned int ctcp_number_limit;	/*flood */
 	unsigned int ctcp_time_limit;	/*seconds of floods */
diff --git a/src/fe-gtk/about.c b/src/fe-gtk/about.c
index a5772e39..41f3c09b 100644
--- a/src/fe-gtk/about.c
+++ b/src/fe-gtk/about.c
@@ -39,7 +39,6 @@
 
 #include "../common/xchat.h"
 #include "../common/util.h"
-#include "../common/wdkutil.h"
 #include "../common/xchatc.h"
 #include "palette.h"
 #include "pixmaps.h"
@@ -71,7 +70,7 @@ menu_about (GtkWidget * wid, gpointer sess)
 							"(C) 1998-2005 Peter Zelezny", author, buf, 0));
 }
 
-#else
+#endif
 
 static GtkWidget *about = 0;
 
@@ -171,4 +170,3 @@ menu_about (GtkWidget * wid, gpointer sess)
 
 	gtk_widget_show_all (about);
 }
-#endif
diff --git a/src/fe-gtk/banlist.c b/src/fe-gtk/banlist.c
index a714d186..fecb62a5 100644
--- a/src/fe-gtk/banlist.c
+++ b/src/fe-gtk/banlist.c
@@ -22,6 +22,10 @@
 #include <fcntl.h>
 #include <time.h>
 
+#ifndef WIN32
+#include <unistd.h>
+#endif
+
 #include "fe-gtk.h"
 
 #include <gtk/gtkhbox.h>
diff --git a/src/fe-gtk/chanlist.c b/src/fe-gtk/chanlist.c
index 6203083b..4dca935b 100644
--- a/src/fe-gtk/chanlist.c
+++ b/src/fe-gtk/chanlist.c
@@ -22,6 +22,10 @@
 #include <fcntl.h>
 #include <time.h>
 
+#ifndef WIN32
+#include <unistd.h>
+#endif
+
 #include "fe-gtk.h"
 
 #include <gtk/gtkalignment.h>
diff --git a/src/fe-gtk/editlist.c b/src/fe-gtk/editlist.c
index fd2d6810..d374d064 100644
--- a/src/fe-gtk/editlist.c
+++ b/src/fe-gtk/editlist.c
@@ -22,6 +22,11 @@
 #include <fcntl.h>
 #include <sys/types.h>
 #include <sys/stat.h>
+
+#ifndef WIN32
+#include <unistd.h>
+#endif
+
 #include "fe-gtk.h"
 
 #include <gtk/gtkstock.h>
diff --git a/src/fe-gtk/fe-gtk.c b/src/fe-gtk/fe-gtk.c
index c11f5235..88a1138c 100644
--- a/src/fe-gtk/fe-gtk.c
+++ b/src/fe-gtk/fe-gtk.c
@@ -31,7 +31,11 @@
 #include <gtk/gtkmessagedialog.h>
 #include <gtk/gtkversion.h>
 
+#ifdef WIN32
 #include <gdk/gdkwin32.h>
+#else
+#include <unistd.h>
+#endif
 
 #include "../common/xchat.h"
 #include "../common/fe.h"
@@ -411,7 +415,7 @@ log_handler (const gchar   *log_domain,
 {
 	session *sess;
 
-	/* if (getenv ("XCHAT_WARNING_IGNORE")) */
+	/* if (getenv ("XCHAT_WARNING_IGNORE")) this gets ignored sometimes, so simply just disable all warnings */
 		return;
 
 	sess = find_dialog (serv_list->data, "(warnings)");
diff --git a/src/fe-gtk/fkeys.c b/src/fe-gtk/fkeys.c
index 7330854a..b9690731 100644
--- a/src/fe-gtk/fkeys.c
+++ b/src/fe-gtk/fkeys.c
@@ -24,6 +24,10 @@
 #include <fcntl.h>
 #include <ctype.h>
 
+#ifndef WIN32
+#include <unistd.h>
+#endif
+
 #include "fe-gtk.h"
 
 #include <gtk/gtklabel.h>
@@ -314,7 +318,7 @@ key_handle_key_press (GtkWidget *wid, GdkEventKey *evt, session *sess)
 		key_action_tab_clean ();
 		break;
 
-#if defined(USE_GTKSPELL)/* && !defined(WIN32)
+#if defined(USE_GTKSPELL)/* && !defined(WIN32) */
 	/* gtktextview has no 'activate' event, so we trap ENTER here */
 	case GDK_Return:
 	case GDK_KP_Enter:
diff --git a/src/fe-gtk/gtkutil.c b/src/fe-gtk/gtkutil.c
index 522b44df..fe4e1737 100644
--- a/src/fe-gtk/gtkutil.c
+++ b/src/fe-gtk/gtkutil.c
@@ -23,6 +23,7 @@
 #include <sys/types.h>
 #include <sys/stat.h>
 #include <fcntl.h>
+
 #include "fe-gtk.h"
 
 #include <gtk/gtkbutton.h>
@@ -50,9 +51,12 @@
 #include "../common/util.h"
 #include "gtkutil.h"
 #include "pixmaps.h"
+
 #ifdef WIN32
 #include "../common/fe.h"
 #include "../common/thread.h"
+#else
+#include <unistd.h>
 #endif
 
 /* gtkutil.c, just some gtk wrappers */
diff --git a/src/fe-gtk/joind.c b/src/fe-gtk/joind.c
index 6cd812cf..e645f0bc 100644
--- a/src/fe-gtk/joind.c
+++ b/src/fe-gtk/joind.c
@@ -12,6 +12,10 @@
 #include <string.h>
 #include <stdio.h>
 
+#ifndef WIN32
+#include <unistd.h>
+#endif
+
 #include <gtk/gtkbbox.h>
 #include <gtk/gtkbutton.h>
 #include <gtk/gtkdialog.h>
diff --git a/src/fe-gtk/maingui.c b/src/fe-gtk/maingui.c
index 74157a7f..28cf46a9 100644
--- a/src/fe-gtk/maingui.c
+++ b/src/fe-gtk/maingui.c
@@ -53,7 +53,8 @@
 #include "../common/plugin.h"
 #include "../common/modes.h"
 #include "../common/url.h"
-#include "../common/wdkutil.h"
+#include "../common/util.h"
+
 #include "fe-gtk.h"
 #include "banlist.h"
 #include "gtkutil.h"
diff --git a/src/fe-gtk/menu.c b/src/fe-gtk/menu.c
index 90c784f0..e6a5eca0 100644
--- a/src/fe-gtk/menu.c
+++ b/src/fe-gtk/menu.c
@@ -23,6 +23,8 @@
 
 #ifdef WIN32
 #include <windows.h>
+#else
+#include <unistd.h>
 #endif
 
 #include "fe-gtk.h"
@@ -1121,6 +1123,7 @@ usermenu_update (void)
 	}
 }
 
+#if 0
 static void
 menu_saveconf (void)
 {
@@ -1135,6 +1138,7 @@ menu_saveconf (void)
 		PrintText (sess, "Error saving settings.\n");
 	}
 }
+#endif
 
 static void
 menu_newserver_window (GtkWidget * wid, gpointer none)
@@ -1653,7 +1657,9 @@ static struct mymenu mymenu[] = {
 		{N_("Userlist Popup..."), menu_ulpopup, 0, M_MENUITEM, 0, 0, 1},
 		{0, 0, 0, M_END, 0, 0, 0},		/* 53 */
 
-	/* {N_("Save Settings to Disk"), menu_saveconf, GTK_STOCK_SAVE, M_MENUSTOCK, 0, 0, 1}, don't use this, a /set auto-save approach will be added instead */
+#if 0
+	{N_("Save Settings to Disk"), menu_saveconf, GTK_STOCK_SAVE, M_MENUSTOCK, 0, 0, 1}, /* don't use this, a /set auto-save approach will be added instead */
+#endif
 
 	{N_("_Window"), 0, 0, M_NEWMENU, 0, 0, 1},
 	{N_("Ban List..."), menu_banlist, 0, M_MENUITEM, 0, 0, 1},
diff --git a/src/fe-gtk/palette.c b/src/fe-gtk/palette.c
index b94ac874..104700c2 100644
--- a/src/fe-gtk/palette.c
+++ b/src/fe-gtk/palette.c
@@ -22,6 +22,10 @@
 #include <sys/stat.h>
 #include <fcntl.h>
 
+#ifndef WIN32
+#include <unistd.h>
+#endif
+
 #include "fe-gtk.h"
 #include "palette.h"
 
diff --git a/src/fe-gtk/plugin-tray.c b/src/fe-gtk/plugin-tray.c
index 62a726a4..b9f60f8d 100644
--- a/src/fe-gtk/plugin-tray.c
+++ b/src/fe-gtk/plugin-tray.c
@@ -1,20 +1,23 @@
 /* Copyright (C) 2006-2007 Peter Zelezny. */
 
 #include <string.h>
-#include "../../plugins/xchat-plugin.h"
+#include "../common/xchat-plugin.h"
 #include "../common/xchat.h"
 #include "../common/xchatc.h"
 #include "../common/inbound.h"
 #include "../common/server.h"
 #include "../common/fe.h"
 #include "../common/util.h"
-#include "../common/wdkutil.h"
 #include "fe-gtk.h"
 #include "pixmaps.h"
 #include "maingui.h"
 #include "menu.h"
 #include <gtk/gtk.h>
 
+#ifndef WIN32
+#include <unistd.h>
+#endif
+
 #ifdef USE_LIBNOTIFY
 #include <libnotify/notify.h>
 #ifndef NOTIFY_CHECK_VERSION
@@ -510,7 +513,7 @@ tray_menu_cb (GtkWidget *widget, guint button, guint time, gpointer userdata)
 		tray_make_item (menu, _("_Hide Window"), tray_menu_restore_cb, NULL);
 	tray_make_item (menu, NULL, tray_menu_quit_cb, NULL);
 
-#if 0
+#ifndef WIN32 /* somehow this is broken on win32 */
 	submenu = mg_submenu (menu, _("_Blink on"));
 	blink_item (&prefs.input_tray_chans, submenu, _("Channel Message"));
 	blink_item (&prefs.input_tray_priv, submenu, _("Private Message"));
@@ -528,6 +531,7 @@ tray_menu_cb (GtkWidget *widget, guint button, guint time, gpointer userdata)
 
 	tray_make_item (menu, NULL, tray_menu_quit_cb, NULL);
 #endif
+
 	mg_create_icon_item (_("_Quit"), GTK_STOCK_QUIT, menu, tray_menu_quit_cb, NULL);
 
 	menu_add_plugin_items (menu, "\x5$TRAY", NULL);
@@ -553,8 +557,12 @@ tray_init (void)
 	sticon = gtk_status_icon_new_from_pixbuf (ICON_NORMAL);
 	if (!sticon)
 		return;
-	/* g_signal_connect (G_OBJECT (sticon), "popup-menu",
-							G_CALLBACK (tray_menu_cb), sticon); */
+
+#ifndef WIN32
+	g_signal_connect (G_OBJECT (sticon), "popup-menu",
+							G_CALLBACK (tray_menu_cb), sticon);
+#endif
+
 	g_signal_connect (G_OBJECT (sticon), "activate",
 							G_CALLBACK (tray_menu_restore_cb), NULL);
 }
diff --git a/src/fe-gtk/plugingui.c b/src/fe-gtk/plugingui.c
index 0edfc62b..71d2f02e 100644
--- a/src/fe-gtk/plugingui.c
+++ b/src/fe-gtk/plugingui.c
@@ -35,7 +35,7 @@
 #include "../common/xchat.h"
 #define PLUGIN_C
 typedef struct session xchat_context;
-#include "../../plugins/xchat-plugin.h"
+#include "../common/xchat-plugin.h"
 #include "../common/plugin.h"
 #include "../common/util.h"
 #include "../common/outbound.h"
@@ -146,10 +146,13 @@ plugingui_load_cb (session *sess, char *file)
 void
 plugingui_load (void)
 {
-	gtkutil_file_req (_("Select a Plugin or Script to load"), plugingui_load_cb,
-							current_sess,
+	gtkutil_file_req (_("Select a Plugin or Script to load"), plugingui_load_cb, current_sess,
+#ifdef WIN32
 							"Plugins and Scripts\0*.dll;*.lua;*.pl;*.py;*.tcl\0"
 							"All files\0*.*\0\0", 0);
+#else
+							NULL, FRF_ADDFOLDER);
+#endif
 }
 
 static void
diff --git a/src/fe-gtk/rawlog.c b/src/fe-gtk/rawlog.c
index a3e1a63b..593468c1 100644
--- a/src/fe-gtk/rawlog.c
+++ b/src/fe-gtk/rawlog.c
@@ -21,6 +21,10 @@
 #include <fcntl.h>
 #include <stdlib.h>
 
+#ifndef WIN32
+#include <unistd.h>
+#endif
+
 #include "fe-gtk.h"
 
 #include <gtk/gtkbutton.h>
diff --git a/src/fe-gtk/setup.c b/src/fe-gtk/setup.c
index 5b242508..1f1be0b4 100644
--- a/src/fe-gtk/setup.c
+++ b/src/fe-gtk/setup.c
@@ -14,7 +14,6 @@
 #include "../common/text.h"
 #include "../common/userlist.h"
 #include "../common/util.h"
-#include "../common/wdkutil.h"
 #include "../common/xchatc.h"
 #include "fe-gtk.h"
 #include "gtkutil.h"
@@ -111,7 +110,7 @@ static const setting textbox_settings[] =
 	{ST_TOGGLR, N_("Indent nick names"), P_OFFINTNL(indent_nicks),
 					N_("Make nick names right-justified"),0,0},
 	{ST_TOGGLE, N_("Transparent background"), P_OFFINTNL(transparent),0,0,0},
-	{ST_TOGGLE, N_("Show marker line"), P_OFFINTNL(show_marker),
+	{ST_TOGGLR, N_("Show marker line"), P_OFFINTNL(show_marker),
 					N_("Insert a red line after the last read text."),0,0},
 	{ST_HEADER, N_("Transparency Settings"), 0,0,0},
 	{ST_HSCALE, N_("Red:"), P_OFFINTNL(tint_red),0,0,0},
@@ -153,7 +152,11 @@ static const setting inputbox_settings[] =
 #if defined(USE_GTKSPELL) || defined(USE_LIBSEXY)
 	{ST_TOGGLE, N_("Spell checking"), P_OFFINTNL(gui_input_spell),0,0,0},
 	{ST_ENTRY,	N_("Dictionaries to use:"), P_OFFSETNL(spell_langs),0,0,sizeof prefs.spell_langs},
+#ifdef WIN32
 	{ST_LABEL,	N_("Use language codes (as in \"share\\myspell\\dicts\").\nSeparate multiple entries with commas.")},
+#else
+	{ST_LABEL,	N_("Use language codes. Separate multiple entries with commas.")},
+#endif
 #endif
 
 	{ST_HEADER, N_("Nick Completion"),0,0,0},
@@ -413,6 +416,7 @@ static const setting advanced_settings[] =
 	{ST_END, 0, 0, 0, 0, 0}
 };
 
+#ifdef WIN32
 static const setting advanced_settings_oneinstance[] =
 {
 	{ST_HEADER,	N_("Advanced Settings"),0,0,0},
@@ -429,6 +433,7 @@ static const setting advanced_settings_oneinstance[] =
 
 	{ST_END, 0, 0, 0, 0, 0}
 };
+#endif
 
 static const setting logging_settings[] =
 {
@@ -1797,6 +1802,7 @@ setup_create_pages (GtkWidget *box)
 	setup_add_page (cata[10], book, setup_create_page (logging_settings));
 	setup_add_page (cata[11], book, setup_create_sound_page ());
 
+#ifdef WIN32
 	if (portable_mode ())
 	{
 		setup_add_page (cata[12], book, setup_create_page (advanced_settings));
@@ -1805,6 +1811,9 @@ setup_create_pages (GtkWidget *box)
 	{
 		setup_add_page (cata[12], book, setup_create_page (advanced_settings_oneinstance));
 	}
+#else
+	setup_add_page (cata[12], book, setup_create_page (advanced_settings));
+#endif
 
 	setup_add_page (cata[14], book, setup_create_page (network_settings));
 	setup_add_page (cata[15], book, setup_create_page (filexfer_settings));
diff --git a/src/fe-gtk/sexy-spell-entry.c b/src/fe-gtk/sexy-spell-entry.c
index 8f21e977..9483f04b 100644
--- a/src/fe-gtk/sexy-spell-entry.c
+++ b/src/fe-gtk/sexy-spell-entry.c
@@ -33,7 +33,9 @@
 #include "sexy-iso-codes.h"
 #include "sexy-marshal.h"
 
+#ifdef WIN32
 #include "typedef.h"
+#endif
 
 #include "../common/cfgfiles.h"
 #include "../common/xchatc.h"
@@ -141,9 +143,18 @@ initialize_enchant ()
 	GModule *enchant;
 	gpointer funcptr;
 
+#ifdef WIN32
 	enchant = g_module_open("libenchant.dll", 0);
+#else
+	enchant = g_module_open("libenchant", 0);
+#endif
 	if (enchant == NULL)
 	{
+#ifndef WIN32
+		enchant = g_module_open("libenchant.so.1", 0);
+				if (enchant == NULL)
+					return;
+#endif
 		return;
 	}
 
diff --git a/src/fe-gtk/xtext.c b/src/fe-gtk/xtext.c
index 5a83062b..3bc9b6a8 100644
--- a/src/fe-gtk/xtext.c
+++ b/src/fe-gtk/xtext.c
@@ -74,6 +74,8 @@
 #ifdef WIN32
 #include <windows.h>
 #include <gdk/gdkwin32.h>
+#else
+#include <unistd.h>
 #endif
 
 /* is delimiter */
-- 
cgit 1.4.1


From 13ee029364b37eca95c43641420e75c872b32653 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sun, 11 Dec 2011 18:04:35 +0100
Subject: some more multiplatform support

---
 plugins/lua/lua.c             |   2 +-
 plugins/lua/makefile.mak      |   2 +-
 plugins/perl/makefile-512.mak |   2 +-
 plugins/perl/makefile-514.mak |   2 +-
 plugins/perl/perl.c           |   2 +-
 plugins/python/makefile.mak   |   2 +-
 plugins/python/python.c       |   2 +-
 src/common/dirent-win32.c     | 199 ++++++++++++++++++++++++++++++++++++++++++
 src/common/dirent-win32.h     |  28 ++++++
 src/common/dirent.c           | 199 ------------------------------------------
 src/common/dirent.h           |  28 ------
 src/common/makefile.mak       |  10 +--
 src/common/plugin.c           |   4 +
 src/common/util.c             |   2 +-
 src/fe-gtk/about.c            |   2 +-
 src/fe-gtk/fe-gtk.h           |   7 --
 src/fe-gtk/setup.c            |   2 +
 17 files changed, 247 insertions(+), 248 deletions(-)
 create mode 100644 src/common/dirent-win32.c
 create mode 100644 src/common/dirent-win32.h
 delete mode 100644 src/common/dirent.c
 delete mode 100644 src/common/dirent.h

(limited to 'plugins')

diff --git a/plugins/lua/lua.c b/plugins/lua/lua.c
index 9574fd4d..9f29bf08 100644
--- a/plugins/lua/lua.c
+++ b/plugins/lua/lua.c
@@ -43,12 +43,12 @@
 #include <sys/types.h>
 #include <sys/stat.h>
 #include <fcntl.h>
-#include "../../src/common/dirent.h"
 #include <errno.h>
 #include <ctype.h>
 
 #ifdef _WIN32
 #include <direct.h>	/* for getcwd */
+#include "../../src/common/dirent-win32.h"
 #endif
 
 #if !( defined(_WIN32) || defined(LXC_XCHAT_GETTEXT) )
diff --git a/plugins/lua/makefile.mak b/plugins/lua/makefile.mak
index fbc94072..97a7e10b 100644
--- a/plugins/lua/makefile.mak
+++ b/plugins/lua/makefile.mak
@@ -1,6 +1,6 @@
 include "..\..\src\makeinc.mak"
 
-DIRENTLIB = ..\..\src\common\dirent.lib
+DIRENTLIB = ..\..\src\common\dirent-win32.lib
 
 all: lua.obj lua.def
 	link $(LDFLAGS) $(LIBS) /dll /out:xclua.dll $(LUALIB).lib $(DIRENTLIB) /def:lua.def lua.obj 
diff --git a/plugins/perl/makefile-512.mak b/plugins/perl/makefile-512.mak
index 677c9073..7f2fbe04 100644
--- a/plugins/perl/makefile-512.mak
+++ b/plugins/perl/makefile-512.mak
@@ -1,6 +1,6 @@
 include "..\..\src\makeinc.mak"
 
-DIRENTLIB = ..\..\src\common\dirent.lib
+DIRENTLIB = ..\..\src\common\dirent-win32.lib
 TARGET = $(PERL512OUTPUT)
 
 all: $(TARGET)
diff --git a/plugins/perl/makefile-514.mak b/plugins/perl/makefile-514.mak
index c31a7ec4..4c8d0ebd 100644
--- a/plugins/perl/makefile-514.mak
+++ b/plugins/perl/makefile-514.mak
@@ -1,6 +1,6 @@
 include "..\..\src\makeinc.mak"
 
-DIRENTLIB = ..\..\src\common\dirent.lib
+DIRENTLIB = ..\..\src\common\dirent-win32.lib
 TARGET = $(PERL514OUTPUT)
 
 all: $(TARGET)
diff --git a/plugins/perl/perl.c b/plugins/perl/perl.c
index a2763771..719ef292 100644
--- a/plugins/perl/perl.c
+++ b/plugins/perl/perl.c
@@ -28,7 +28,7 @@
 #ifdef WIN32
 #include <windows.h>
 #define  _INC_DIRENT /* disable inclusion of perl's dirent.h, we use an own version for win32 */
-#include "../../src/common/dirent.h"
+#include "../../src/common/dirent-win32.h"
 #else
 #include <dirent.h>
 #endif
diff --git a/plugins/python/makefile.mak b/plugins/python/makefile.mak
index 8cbba3f5..bc004577 100644
--- a/plugins/python/makefile.mak
+++ b/plugins/python/makefile.mak
@@ -1,6 +1,6 @@
 include "..\..\src\makeinc.mak"
 
-DIRENTLIB = ..\..\src\common\dirent.lib
+DIRENTLIB = ..\..\src\common\dirent-win32.lib
 TARGET = $(PYTHONOUTPUT)
 
 all: $(TARGET)
diff --git a/plugins/python/python.c b/plugins/python/python.c
index 3c535057..dcf4fc8f 100644
--- a/plugins/python/python.c
+++ b/plugins/python/python.c
@@ -57,7 +57,7 @@
 #include <sys/types.h>
 
 #ifdef WIN32
-#include "../../src/common/dirent.h"
+#include "../../src/common/dirent-win32.h"
 #include "../../config.h"
 #else
 #include <unistd.h>
diff --git a/src/common/dirent-win32.c b/src/common/dirent-win32.c
new file mode 100644
index 00000000..273c6732
--- /dev/null
+++ b/src/common/dirent-win32.c
@@ -0,0 +1,199 @@
+/*****************************************************************************
+ * dirent.h - dirent API for Microsoft Visual Studio
+ *
+ * Copyright (C) 2006 Toni Ronkko
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining
+ * a copy of this software and associated documentation files (the
+ * ``Software''), to deal in the Software without restriction, including
+ * without limitation the rights to use, copy, modify, merge, publish,
+ * distribute, sublicense, and/or sell copies of the Software, and to
+ * permit persons to whom the Software is furnished to do so, subject to
+ * the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included
+ * in all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED ``AS IS'', WITHOUT WARRANTY OF ANY KIND, EXPRESS
+ * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
+ * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
+ * IN NO EVENT SHALL TONI RONKKO BE LIABLE FOR ANY CLAIM, DAMAGES OR
+ * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
+ * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
+ * OTHER DEALINGS IN THE SOFTWARE.
+ *
+ * Dec 15, 2009, John Cunningham
+ * Added rewinddir member function
+ *
+ * Jan 18, 2008, Toni Ronkko
+ * Using FindFirstFileA and WIN32_FIND_DATAA to avoid converting string
+ * between multi-byte and unicode representations.  This makes the
+ * code simpler and also allows the code to be compiled under MingW.  Thanks
+ * to Azriel Fasten for the suggestion.
+ *
+ * Mar 4, 2007, Toni Ronkko
+ * Bug fix: due to the strncpy_s() function this file only compiled in
+ * Visual Studio 2005.  Using the new string functions only when the
+ * compiler version allows.
+ *
+ * Nov  2, 2006, Toni Ronkko
+ * Major update: removed support for Watcom C, MS-DOS and Turbo C to
+ * simplify the file, updated the code to compile cleanly on Visual
+ * Studio 2005 with both unicode and multi-byte character strings,
+ * removed rewinddir() as it had a bug.
+ *
+ * Aug 20, 2006, Toni Ronkko
+ * Removed all remarks about MSVC 1.0, which is antiqued now.  Simplified
+ * comments by removing SGML tags.
+ *
+ * May 14 2002, Toni Ronkko
+ * Embedded the function definitions directly to the header so that no
+ * source modules need to be included in the Visual Studio project.  Removed
+ * all the dependencies to other projects so that this very header can be
+ * used independently.
+ *
+ * May 28 1998, Toni Ronkko
+ * First version.
+ *****************************************************************************/
+
+#include "dirent-win32.h"
+
+/* Use the new safe string functions introduced in Visual Studio 2005 */
+#if defined(_MSC_VER) && _MSC_VER >= 1400
+# define STRNCPY(dest,src,size) strncpy_s((dest),(size),(src),_TRUNCATE)
+#else
+# define STRNCPY(dest,src,size) strncpy((dest),(src),(size))
+#endif
+
+
+/*****************************************************************************
+ * Open directory stream DIRNAME for read and return a pointer to the
+ * internal working area that is used to retrieve individual directory
+ * entries.
+ */
+DIR *opendir(const char *dirname)
+{
+   DIR *dirp;
+   assert (dirname != NULL);
+   assert (strlen (dirname) < MAX_PATH);
+
+   /* construct new DIR structure */
+   dirp = (DIR*) malloc (sizeof (struct DIR));
+   if (dirp != NULL) {
+      char *p;
+
+      /* take directory name... */
+      STRNCPY (dirp->patt, dirname, sizeof(dirp->patt));
+      dirp->patt[MAX_PATH] = '\0';
+
+      /* ... and append search pattern to it */
+      p = strchr (dirp->patt, '\0');
+      if (dirp->patt < p  &&  *(p-1) != '\\'  &&  *(p-1) != ':') {
+         *p++ = '\\';
+      }
+      *p++ = '*';
+      *p = '\0';
+
+      /* open stream and retrieve first file */
+      dirp->search_handle = FindFirstFileA (dirp->patt, &dirp->current.data);
+      if (dirp->search_handle == INVALID_HANDLE_VALUE) {
+         /* invalid search pattern? */
+         free (dirp);
+         return NULL;
+      }
+
+      /* there is an un-processed directory entry in memory now */
+      dirp->cached = 1;
+   }
+
+   return dirp;
+}
+
+
+/*****************************************************************************
+ * Read a directory entry, and return a pointer to a dirent structure
+ * containing the name of the entry in d_name field.  Individual directory
+ * entries returned by this very function include regular files,
+ * sub-directories, pseudo-directories "." and "..", but also volume labels,
+ * hidden files and system files may be returned.
+ */
+struct dirent *readdir(DIR *dirp)
+{
+   assert (dirp != NULL);
+
+   if (dirp->search_handle == INVALID_HANDLE_VALUE) {
+      /* directory stream was opened/rewound incorrectly or ended normally */
+      return NULL;
+   }
+
+   /* get next directory entry */
+   if (dirp->cached != 0) {
+      /* a valid directory entry already in memory */
+      dirp->cached = 0;
+   } else {
+      /* read next directory entry from disk */
+      if (FindNextFileA (dirp->search_handle, &dirp->current.data) == FALSE) {
+         /* the very last file has been processed or an error occured */
+         FindClose (dirp->search_handle);
+         dirp->search_handle = INVALID_HANDLE_VALUE;
+         return NULL;
+      }
+   }
+
+   /* copy as a multibyte character string */
+   STRNCPY ( dirp->current.d_name,
+             dirp->current.data.cFileName,
+             sizeof(dirp->current.d_name) );
+   dirp->current.d_name[MAX_PATH] = '\0';
+
+   return &dirp->current;
+}
+
+
+/*****************************************************************************
+ * Close directory stream opened by opendir() function.  Close of the
+ * directory stream invalidates the DIR structure as well as any previously
+ * read directory entry.
+ */
+int closedir(DIR *dirp)
+{
+   assert (dirp != NULL);
+
+   /* release search handle */
+   if (dirp->search_handle != INVALID_HANDLE_VALUE) {
+      FindClose (dirp->search_handle);
+      dirp->search_handle = INVALID_HANDLE_VALUE;
+   }
+
+   /* release directory handle */
+   free (dirp);
+   return 0;
+}
+
+
+/*****************************************************************************
+ * Resets the position of the directory stream to which dirp refers to the
+ * beginning of the directory. It also causes the directory stream to refer
+ * to the current state of the corresponding directory, as a call to opendir()
+ * would have done. If dirp does not refer to a directory stream, the effect
+ * is undefined.
+ */
+void rewinddir(DIR* dirp)
+{
+   /* release search handle */
+   if (dirp->search_handle != INVALID_HANDLE_VALUE) {
+      FindClose (dirp->search_handle);
+      dirp->search_handle = INVALID_HANDLE_VALUE;
+   }
+
+   /* open new search handle and retrieve first file */
+   dirp->search_handle = FindFirstFileA (dirp->patt, &dirp->current.data);
+   if (dirp->search_handle == INVALID_HANDLE_VALUE) {
+      /* invalid search pattern? */
+      free (dirp);
+      return;
+   }
+
+   /* there is an un-processed directory entry in memory now */
+   dirp->cached = 1;
+}
diff --git a/src/common/dirent-win32.h b/src/common/dirent-win32.h
new file mode 100644
index 00000000..cbb753e6
--- /dev/null
+++ b/src/common/dirent-win32.h
@@ -0,0 +1,28 @@
+#ifndef DIRENT_H
+#define DIRENT_H
+
+#include <windows.h>
+#include <string.h>
+#include <assert.h>
+
+typedef struct dirent
+{
+   char d_name[MAX_PATH + 1]; /* current dir entry (multi-byte char string) */
+   WIN32_FIND_DATAA data;     /* file attributes */
+}  dirent;
+
+typedef struct DIR
+{
+   dirent current;            /* Current directory entry */
+   int    cached;             /* Indicates un-processed entry in memory */
+   HANDLE search_handle;      /* File search handle */
+   char   patt[MAX_PATH + 3]; /* search pattern (3 = pattern + "\\*\0") */
+} DIR;
+
+/* Forward declarations */
+DIR *opendir (const char *dirname);
+struct dirent *readdir (DIR *dirp);
+int closedir (DIR *dirp);
+void rewinddir(DIR* dirp);
+
+#endif /*DIRENT_H*/
diff --git a/src/common/dirent.c b/src/common/dirent.c
deleted file mode 100644
index a84f1b65..00000000
--- a/src/common/dirent.c
+++ /dev/null
@@ -1,199 +0,0 @@
-/*****************************************************************************
- * dirent.h - dirent API for Microsoft Visual Studio
- *
- * Copyright (C) 2006 Toni Ronkko
- *
- * Permission is hereby granted, free of charge, to any person obtaining
- * a copy of this software and associated documentation files (the
- * ``Software''), to deal in the Software without restriction, including
- * without limitation the rights to use, copy, modify, merge, publish,
- * distribute, sublicense, and/or sell copies of the Software, and to
- * permit persons to whom the Software is furnished to do so, subject to
- * the following conditions:
- *
- * The above copyright notice and this permission notice shall be included
- * in all copies or substantial portions of the Software.
- *
- * THE SOFTWARE IS PROVIDED ``AS IS'', WITHOUT WARRANTY OF ANY KIND, EXPRESS
- * OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
- * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
- * IN NO EVENT SHALL TONI RONKKO BE LIABLE FOR ANY CLAIM, DAMAGES OR
- * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
- * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
- * OTHER DEALINGS IN THE SOFTWARE.
- *
- * Dec 15, 2009, John Cunningham
- * Added rewinddir member function
- *
- * Jan 18, 2008, Toni Ronkko
- * Using FindFirstFileA and WIN32_FIND_DATAA to avoid converting string
- * between multi-byte and unicode representations.  This makes the
- * code simpler and also allows the code to be compiled under MingW.  Thanks
- * to Azriel Fasten for the suggestion.
- *
- * Mar 4, 2007, Toni Ronkko
- * Bug fix: due to the strncpy_s() function this file only compiled in
- * Visual Studio 2005.  Using the new string functions only when the
- * compiler version allows.
- *
- * Nov  2, 2006, Toni Ronkko
- * Major update: removed support for Watcom C, MS-DOS and Turbo C to
- * simplify the file, updated the code to compile cleanly on Visual
- * Studio 2005 with both unicode and multi-byte character strings,
- * removed rewinddir() as it had a bug.
- *
- * Aug 20, 2006, Toni Ronkko
- * Removed all remarks about MSVC 1.0, which is antiqued now.  Simplified
- * comments by removing SGML tags.
- *
- * May 14 2002, Toni Ronkko
- * Embedded the function definitions directly to the header so that no
- * source modules need to be included in the Visual Studio project.  Removed
- * all the dependencies to other projects so that this very header can be
- * used independently.
- *
- * May 28 1998, Toni Ronkko
- * First version.
- *****************************************************************************/
-
-#include "dirent.h"
-
-/* Use the new safe string functions introduced in Visual Studio 2005 */
-#if defined(_MSC_VER) && _MSC_VER >= 1400
-# define STRNCPY(dest,src,size) strncpy_s((dest),(size),(src),_TRUNCATE)
-#else
-# define STRNCPY(dest,src,size) strncpy((dest),(src),(size))
-#endif
-
-
-/*****************************************************************************
- * Open directory stream DIRNAME for read and return a pointer to the
- * internal working area that is used to retrieve individual directory
- * entries.
- */
-DIR *opendir(const char *dirname)
-{
-   DIR *dirp;
-   assert (dirname != NULL);
-   assert (strlen (dirname) < MAX_PATH);
-
-   /* construct new DIR structure */
-   dirp = (DIR*) malloc (sizeof (struct DIR));
-   if (dirp != NULL) {
-      char *p;
-
-      /* take directory name... */
-      STRNCPY (dirp->patt, dirname, sizeof(dirp->patt));
-      dirp->patt[MAX_PATH] = '\0';
-
-      /* ... and append search pattern to it */
-      p = strchr (dirp->patt, '\0');
-      if (dirp->patt < p  &&  *(p-1) != '\\'  &&  *(p-1) != ':') {
-         *p++ = '\\';
-      }
-      *p++ = '*';
-      *p = '\0';
-
-      /* open stream and retrieve first file */
-      dirp->search_handle = FindFirstFileA (dirp->patt, &dirp->current.data);
-      if (dirp->search_handle == INVALID_HANDLE_VALUE) {
-         /* invalid search pattern? */
-         free (dirp);
-         return NULL;
-      }
-
-      /* there is an un-processed directory entry in memory now */
-      dirp->cached = 1;
-   }
-
-   return dirp;
-}
-
-
-/*****************************************************************************
- * Read a directory entry, and return a pointer to a dirent structure
- * containing the name of the entry in d_name field.  Individual directory
- * entries returned by this very function include regular files,
- * sub-directories, pseudo-directories "." and "..", but also volume labels,
- * hidden files and system files may be returned.
- */
-struct dirent *readdir(DIR *dirp)
-{
-   assert (dirp != NULL);
-
-   if (dirp->search_handle == INVALID_HANDLE_VALUE) {
-      /* directory stream was opened/rewound incorrectly or ended normally */
-      return NULL;
-   }
-
-   /* get next directory entry */
-   if (dirp->cached != 0) {
-      /* a valid directory entry already in memory */
-      dirp->cached = 0;
-   } else {
-      /* read next directory entry from disk */
-      if (FindNextFileA (dirp->search_handle, &dirp->current.data) == FALSE) {
-         /* the very last file has been processed or an error occured */
-         FindClose (dirp->search_handle);
-         dirp->search_handle = INVALID_HANDLE_VALUE;
-         return NULL;
-      }
-   }
-
-   /* copy as a multibyte character string */
-   STRNCPY ( dirp->current.d_name,
-             dirp->current.data.cFileName,
-             sizeof(dirp->current.d_name) );
-   dirp->current.d_name[MAX_PATH] = '\0';
-
-   return &dirp->current;
-}
-
-
-/*****************************************************************************
- * Close directory stream opened by opendir() function.  Close of the
- * directory stream invalidates the DIR structure as well as any previously
- * read directory entry.
- */
-int closedir(DIR *dirp)
-{
-   assert (dirp != NULL);
-
-   /* release search handle */
-   if (dirp->search_handle != INVALID_HANDLE_VALUE) {
-      FindClose (dirp->search_handle);
-      dirp->search_handle = INVALID_HANDLE_VALUE;
-   }
-
-   /* release directory handle */
-   free (dirp);
-   return 0;
-}
-
-
-/*****************************************************************************
- * Resets the position of the directory stream to which dirp refers to the
- * beginning of the directory. It also causes the directory stream to refer
- * to the current state of the corresponding directory, as a call to opendir()
- * would have done. If dirp does not refer to a directory stream, the effect
- * is undefined.
- */
-void rewinddir(DIR* dirp)
-{
-   /* release search handle */
-   if (dirp->search_handle != INVALID_HANDLE_VALUE) {
-      FindClose (dirp->search_handle);
-      dirp->search_handle = INVALID_HANDLE_VALUE;
-   }
-
-   /* open new search handle and retrieve first file */
-   dirp->search_handle = FindFirstFileA (dirp->patt, &dirp->current.data);
-   if (dirp->search_handle == INVALID_HANDLE_VALUE) {
-      /* invalid search pattern? */
-      free (dirp);
-      return;
-   }
-
-   /* there is an un-processed directory entry in memory now */
-   dirp->cached = 1;
-}
diff --git a/src/common/dirent.h b/src/common/dirent.h
deleted file mode 100644
index cbb753e6..00000000
--- a/src/common/dirent.h
+++ /dev/null
@@ -1,28 +0,0 @@
-#ifndef DIRENT_H
-#define DIRENT_H
-
-#include <windows.h>
-#include <string.h>
-#include <assert.h>
-
-typedef struct dirent
-{
-   char d_name[MAX_PATH + 1]; /* current dir entry (multi-byte char string) */
-   WIN32_FIND_DATAA data;     /* file attributes */
-}  dirent;
-
-typedef struct DIR
-{
-   dirent current;            /* Current directory entry */
-   int    cached;             /* Indicates un-processed entry in memory */
-   HANDLE search_handle;      /* File search handle */
-   char   patt[MAX_PATH + 3]; /* search pattern (3 = pattern + "\\*\0") */
-} DIR;
-
-/* Forward declarations */
-DIR *opendir (const char *dirname);
-struct dirent *readdir (DIR *dirp);
-int closedir (DIR *dirp);
-void rewinddir(DIR* dirp);
-
-#endif /*DIRENT_H*/
diff --git a/src/common/makefile.mak b/src/common/makefile.mak
index 8b350efc..f78a6d8d 100644
--- a/src/common/makefile.mak
+++ b/src/common/makefile.mak
@@ -5,7 +5,7 @@ cfgfiles.obj \
 chanopt.obj \
 ctcp.obj \
 dcc.obj \
-dirent.obj \
+dirent-win32.obj \
 history.obj \
 ignore.obj \
 inbound.obj \
@@ -27,13 +27,13 @@ userlist.obj \
 util.obj \
 xchat.obj
 
-all: $(COMMON_OBJECTS) xchatcommon.lib dirent.lib
+all: $(COMMON_OBJECTS) xchatcommon.lib dirent-win32.lib
 
 xchatcommon.lib: $(COMMON_OBJECTS)
 	lib /nologo /out:xchatcommon.lib $(COMMON_OBJECTS)
 
-dirent.lib: dirent.obj
-	lib /nologo /out:dirent.lib dirent.obj
+dirent-win32.lib: dirent-win32.obj
+	lib /nologo /out:dirent-win32.lib dirent-win32.obj
 
 .c.obj::
 	$(CC) $(CFLAGS) $(GLIB) $<
@@ -41,4 +41,4 @@ dirent.lib: dirent.obj
 clean:
 	@del *.obj
 	@del xchatcommon.lib
-	@del dirent.lib
+	@del dirent-win32.lib
diff --git a/src/common/plugin.c b/src/common/plugin.c
index ccb64e93..5ed20b87 100644
--- a/src/common/plugin.c
+++ b/src/common/plugin.c
@@ -1008,7 +1008,11 @@ xchat_get_info (xchat_plugin *ph, const char *id)
 		return XCHATLIBDIR;
 
 	case 0x14f51cd8: /* version */
+#ifdef WIN32
 		return XCHAT_RELEASE;
+#else
+		return PACKAGE_VERSION;
+#endif
 
 	case 0xdd9b1abd:	/* xchatdir */
 		return get_xdir_utf8 ();
diff --git a/src/common/util.c b/src/common/util.c
index ccc48657..51222e40 100644
--- a/src/common/util.c
+++ b/src/common/util.c
@@ -32,7 +32,7 @@
 #include <sys/timeb.h>
 #include <process.h>
 #include <io.h>
-#include "dirent.h"
+#include "dirent-win32.h"
 #else
 #include <unistd.h>
 #include <pwd.h>
diff --git a/src/fe-gtk/about.c b/src/fe-gtk/about.c
index 41f3c09b..dc1cbf08 100644
--- a/src/fe-gtk/about.c
+++ b/src/fe-gtk/about.c
@@ -139,7 +139,7 @@ menu_about (GtkWidget * wid, gpointer sess)
 				(portable_mode () ? "Yes" : "No"),
 				get_cpu_arch ()
 #else
-				"%s\n\n"
+				"\n%s\n\n"
 				"%s\n"
 				"<b>Charset</b>: %s "
 				"<b>Renderer</b>: %s\n"
diff --git a/src/fe-gtk/fe-gtk.h b/src/fe-gtk/fe-gtk.h
index 4183f559..8fffb3cc 100644
--- a/src/fe-gtk/fe-gtk.h
+++ b/src/fe-gtk/fe-gtk.h
@@ -1,13 +1,6 @@
 #include "../../config.h"
 
-#ifdef WIN32
-/* If you're compiling this for Windows, your release is un-official
- * and not condoned. Please don't use the XChat name. Make up your
- * own name! */
 #define DISPLAY_NAME "XChat-WDK"
-#else
-#define DISPLAY_NAME "XChat"
-#endif
 
 #ifndef WIN32
 #include <sys/types.h>
diff --git a/src/fe-gtk/setup.c b/src/fe-gtk/setup.c
index 1f1be0b4..cce85d30 100644
--- a/src/fe-gtk/setup.c
+++ b/src/fe-gtk/setup.c
@@ -1383,7 +1383,9 @@ setup_create_color_page (void)
 	setup_create_other_color (_("New message:"), COL_NEW_MSG, 10, tab);
 	setup_create_other_colorR (_("Away user:"), COL_AWAY, 10, tab);
 	setup_create_other_color (_("Highlight:"), COL_HILIGHT, 11, tab);
+#if defined(USE_GTKSPELL) || defined(USE_LIBSEXY)
 	setup_create_other_colorR (_("Spell checker:"), COL_SPELL, 11, tab);
+#endif
 
 	return box;
 }
-- 
cgit 1.4.1


From 18404054b0e7bad84c552530fa5771f38469f2d3 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Tue, 3 Jan 2012 16:38:40 +0100
Subject: sync with fishlim head

---
 plugins/fishlim/Makefile       | 2 +-
 plugins/fishlim/keystore.c     | 4 ++--
 plugins/fishlim/plugin_xchat.c | 2 +-
 3 files changed, 4 insertions(+), 4 deletions(-)

(limited to 'plugins')

diff --git a/plugins/fishlim/Makefile b/plugins/fishlim/Makefile
index a1832c84..3f0e93d2 100644
--- a/plugins/fishlim/Makefile
+++ b/plugins/fishlim/Makefile
@@ -23,7 +23,7 @@ fishlim.so: $(PLUGIN_OBJECTS)
 	$(CC) -shared $(OURLINKFLAGS) $(PLUGIN_OBJECTS) -o $@
 
 test: $(TEST_OBJECTS)
-	$(CC) $(OURLINKFLAGS) $(TEST_OBJECTS) -o $@
+	$(CC) $(TEST_OBJECTS) -o $@ $(OURLINKFLAGS)
 
 
 .PHONY: all clean distclean install uninstall
diff --git a/plugins/fishlim/keystore.c b/plugins/fishlim/keystore.c
index ce029a2e..d97107fd 100644
--- a/plugins/fishlim/keystore.c
+++ b/plugins/fishlim/keystore.c
@@ -164,8 +164,8 @@ bool keystore_store_key(const char *nick, const char *key) {
         encrypted = fish_encrypt(password, strlen(password), key);
         if (!encrypted) goto end;
         
-        // Prepend "OK+ "
-        wrapped = g_strconcat("OK+ ", encrypted, NULL);
+        // Prepend "+OK "
+        wrapped = g_strconcat("+OK ", encrypted, NULL);
         g_free(encrypted);
         
         // Store encrypted in file
diff --git a/plugins/fishlim/plugin_xchat.c b/plugins/fishlim/plugin_xchat.c
index ba0e1280..01f5d747 100644
--- a/plugins/fishlim/plugin_xchat.c
+++ b/plugins/fishlim/plugin_xchat.c
@@ -44,7 +44,7 @@
 
 static const char plugin_name[] = "FiSHLiM";
 static const char plugin_desc[] = "Encryption plugin for the FiSH protocol. Less is More!";
-static const char plugin_version[] = "0.0.14";
+static const char plugin_version[] = "0.0.15";
 
 static const char usage_setkey[] = "Usage: SETKEY [<nick or #channel>] <password>, sets the key for a channel or nick";
 static const char usage_delkey[] = "Usage: DELKEY <nick or #channel>, deletes the key for a channel or nick";
-- 
cgit 1.4.1


From 66d8b0ad7b849ed743d3c3b4199fd05ece3891bb Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Tue, 10 Jan 2012 04:00:20 +0100
Subject: initial XSASL plugin based on cap_sasl

---
 plugins/makefile.mak       |   4 +
 plugins/xsasl/makefile.mak |  18 ++++
 plugins/xsasl/xsasl.c      | 224 +++++++++++++++++++++++++++++++++++++++++++++
 win32/release-x64.bat      |   1 +
 win32/release-x86.bat      |   1 +
 5 files changed, 248 insertions(+)
 create mode 100644 plugins/xsasl/makefile.mak
 create mode 100644 plugins/xsasl/xsasl.c

(limited to 'plugins')

diff --git a/plugins/makefile.mak b/plugins/makefile.mak
index f8642d2e..b692c41f 100644
--- a/plugins/makefile.mak
+++ b/plugins/makefile.mak
@@ -19,6 +19,8 @@ all:
 	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\upd
 	@-$(MAKE) /nologo /s /f makefile.mak $@
+	@cd ..\xsasl
+	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\xtray
 	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\winamp
@@ -49,6 +51,8 @@ clean:
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\upd
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
+	@cd ..\xsasl
+	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\xtray
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\winamp
diff --git a/plugins/xsasl/makefile.mak b/plugins/xsasl/makefile.mak
new file mode 100644
index 00000000..e1ffd0ec
--- /dev/null
+++ b/plugins/xsasl/makefile.mak
@@ -0,0 +1,18 @@
+include "..\..\src\makeinc.mak"
+
+all: xsasl.obj xsasl.def
+	link $(LDFLAGS) $(LIBS) /dll /out:xcxsasl.dll /def:xsasl.def xsasl.obj
+
+xsasl.def:
+	echo EXPORTS > xsasl.def
+	echo xchat_plugin_init >> xsasl.def
+	echo xchat_plugin_deinit >> xsasl.def
+
+xsasl.obj: xsasl.c makefile.mak
+	cl $(CFLAGS) $(GLIB) /I.. xsasl.c
+
+clean:
+	del *.obj
+	del *.dll
+	del *.exp
+	del *.lib
diff --git a/plugins/xsasl/xsasl.c b/plugins/xsasl/xsasl.c
new file mode 100644
index 00000000..776b8137
--- /dev/null
+++ b/plugins/xsasl/xsasl.c
@@ -0,0 +1,224 @@
+/*
+ * SASL authentication plugin for XChat
+ * Extremely primitive: only PLAIN, no error checking
+ *
+ * Copyright (c) 2010, <ygrek@autistici.org>
+ * http://ygrek.org.ua/p/cap_sasl.html
+ *
+ * Docs:
+ *  http://hg.atheme.org/charybdis/charybdis/file/6144f52a119b/doc/sasl.txt
+ *  http://tools.ietf.org/html/rfc4422
+ */
+
+
+#include <string.h>
+#include <stdlib.h>
+#include <assert.h>
+#include <glib/gbase64.h>
+
+#include "xchat-plugin.h"
+
+#define PNAME "XSASL"
+#define PDESC "SASL authentication plugin";
+#define PVERSION "0.0.4"
+
+static xchat_plugin *ph;   /* plugin handle */
+
+struct sasl_info;
+
+struct sasl_info
+{
+  char const* login;
+  char const* password;
+  char const* network;
+  struct sasl_info* next;
+};
+
+typedef struct sasl_info sasl_info;
+
+sasl_info* all_info = NULL;
+
+static void add_info(char const* login, char const* password, char const* network)
+{
+  sasl_info* prev = all_info;
+  sasl_info* info = (sasl_info*)malloc(sizeof(sasl_info));
+
+  info->login = strdup(login);
+  info->password = strdup(password);
+  info->network = strdup(network);
+  info->next = prev;
+
+  all_info = info;
+}
+
+static sasl_info* find_info(char const* network)
+{
+  sasl_info* cur = all_info;
+  while (cur)
+  {
+    if (0 == strcmp(cur->network, network)) return cur;
+    cur = cur->next;
+  }
+  return NULL;
+}
+
+static sasl_info* get_info(void)
+{
+  const char* name = xchat_get_info(ph, "network");
+  if (name) 
+    return find_info(name);
+  else 
+    return NULL;
+}
+
+static int authend_cb(char *word[], char *word_eol[], void *userdata)
+{
+  if (get_info())
+  {
+    xchat_printf(ph, "XSASL result: %s", word_eol[1]);
+    xchat_commandf(ph, "QUOTE CAP END");
+  }
+  return XCHAT_EAT_ALL;
+}
+
+/*
+static int disconnect_cb(char *word[], void *userdata)
+{
+  xchat_printf(ph, "disconnected");
+  return XCHAT_EAT_NONE;
+}
+*/
+
+static int server_cb(char *word[], char *word_eol[], void *userdata)
+{
+  if (0 == strcmp("AUTHENTICATE",word[1]) && 0 == strcmp("+",word[2]))
+  {
+    size_t len;
+    char* buf;
+    char* enc;
+    sasl_info* p = get_info();
+    if (!p) return XCHAT_EAT_NONE;
+
+    xchat_printf(ph,"XSASL authenticating as %s",p->login);
+
+    len = strlen(p->login)*2 + 2 + strlen(p->password);
+    buf = (char*)malloc(len + 1);
+    strcpy(buf,p->login);
+    strcpy(buf+strlen(p->login)+1,p->login);
+    strcpy(buf+strlen(p->login)*2+2,p->password);
+    enc = g_base64_encode((unsigned char*)buf,len);
+
+    /*xchat_printf(ph,"AUTHENTICATE %s",enc);*/
+    xchat_commandf(ph,"QUOTE AUTHENTICATE %s",enc);
+
+    free(enc);
+    free(buf);
+
+    return XCHAT_EAT_ALL;
+  }
+	return XCHAT_EAT_NONE;
+}
+
+static int cap_cb(char *word[], char *word_eol[], void *userdata)
+{
+  if (get_info())
+  {
+    /* FIXME test sasl cap */
+    xchat_printf(ph, "XSASL info: %s", word_eol[1]);
+    xchat_commandf(ph,"QUOTE AUTHENTICATE PLAIN");
+  }
+
+  return XCHAT_EAT_ALL;
+}
+
+static int sasl_cmd_cb(char *word[], char *word_eol[], void *userdata)
+{
+  const char* login = word[2];
+  const char* password = word[3];
+  const char* network = word_eol[4];
+
+  if (!login || !*login)
+  {
+    sasl_info *cur = all_info;
+    if (NULL == cur)
+    {
+      xchat_printf(ph,"Nothing, see /help sasl");
+      return XCHAT_EAT_ALL;
+    }
+
+    while (cur)
+    {
+      xchat_printf(ph,"%s:%s at %s",cur->login,cur->password,cur->network);
+      cur = cur->next;
+    }
+    return XCHAT_EAT_ALL;
+  }
+
+  if (!login || !password || !network || !*login || !*password || !*network)
+  {
+    xchat_printf(ph,"Wrong usage, try /help sasl");
+    return XCHAT_EAT_ALL;
+  }
+
+  add_info(login,password,network);
+
+  xchat_printf(ph,"Enabled SASL authentication for %s",network);
+
+  return XCHAT_EAT_ALL;
+}
+
+static int connect_cb(char *word[], void *userdata)
+{
+  if (get_info())
+  {
+    xchat_printf(ph, "XSASL enabled");
+    xchat_commandf(ph, "QUOTE CAP REQ :sasl");
+  }
+
+  return XCHAT_EAT_NONE;
+}
+
+int xchat_plugin_init(xchat_plugin *plugin_handle,
+                      char **plugin_name,
+                      char **plugin_desc,
+                      char **plugin_version,
+                      char *arg)
+{
+  /* we need to save this for use with any xchat_* functions */
+  ph = plugin_handle;
+
+  /* tell xchat our info */
+  *plugin_name = PNAME;
+  *plugin_desc = PDESC;
+  *plugin_version = PVERSION;
+
+  xchat_hook_command(ph, "sasl", XCHAT_PRI_NORM, sasl_cmd_cb, 
+    "Usage: SASL <login> <password> <network>, enable SASL authentication for given network", 0);
+
+  xchat_hook_print(ph, "Connected", XCHAT_PRI_NORM, connect_cb, NULL);
+/*
+  xchat_hook_print(ph, "Disconnected", XCHAT_PRI_NORM, disconnect_cb, NULL);
+*/
+
+  xchat_hook_server(ph, "CAP", XCHAT_PRI_NORM, cap_cb, NULL);
+  xchat_hook_server(ph, "RAW LINE", XCHAT_PRI_NORM, server_cb, NULL);
+
+  xchat_hook_server(ph, "903", XCHAT_PRI_NORM, authend_cb, NULL);
+  xchat_hook_server(ph, "904", XCHAT_PRI_NORM, authend_cb, NULL);
+  xchat_hook_server(ph, "905", XCHAT_PRI_NORM, authend_cb, NULL);
+  xchat_hook_server(ph, "906", XCHAT_PRI_NORM, authend_cb, NULL);
+  xchat_hook_server(ph, "907", XCHAT_PRI_NORM, authend_cb, NULL);
+
+  /* xchat_print(ph,"Loading cap_sasl.conf");
+  xchat_commandf(ph, "load -e %s/cap_sasl.conf",xchat_get_info(ph, "xchatdir")); */
+
+  xchat_printf(ph, PNAME " plugin loaded\n");
+
+  return 1;
+}
+
+int xchat_plugin_deinit (void)
+{
+	xchat_printf(ph, PNAME " plugin unloaded\n");
+	return 1;
+}
diff --git a/win32/release-x64.bat b/win32/release-x64.bat
index 6483a950..9e092a2b 100644
--- a/win32/release-x64.bat
+++ b/win32/release-x64.bat
@@ -67,6 +67,7 @@ copy ..\plugins\perl\xcperl-514.dll %XCHAT_DEST%\plugins
 copy ..\plugins\python\xcpython.dll %XCHAT_DEST%\plugins
 copy ..\plugins\tcl\xctcl.dll %XCHAT_DEST%\plugins
 copy ..\plugins\upd\xcupd.dll %XCHAT_DEST%\plugins
+copy ..\plugins\xsasl\xcxsasl.dll %XCHAT_DEST%\plugins
 copy ..\plugins\xtray\xtray.dll %XCHAT_DEST%\plugins
 copy ..\plugins\winamp\xcwinamp.dll %XCHAT_DEST%\plugins
 copy ..\plugins\winsys\xcwinsys.dll %XCHAT_DEST%\plugins
diff --git a/win32/release-x86.bat b/win32/release-x86.bat
index dc45146a..bf0a8db6 100644
--- a/win32/release-x86.bat
+++ b/win32/release-x86.bat
@@ -69,6 +69,7 @@ copy ..\plugins\perl\xcperl-514.dll %XCHAT_DEST%\plugins
 copy ..\plugins\python\xcpython.dll %XCHAT_DEST%\plugins
 copy ..\plugins\tcl\xctcl.dll %XCHAT_DEST%\plugins
 copy ..\plugins\upd\xcupd.dll %XCHAT_DEST%\plugins
+copy ..\plugins\xsasl\xcxsasl.dll %XCHAT_DEST%\plugins
 copy ..\plugins\xtray\xtray.dll %XCHAT_DEST%\plugins
 copy ..\plugins\winamp\xcwinamp.dll %XCHAT_DEST%\plugins
 copy ..\plugins\winsys\xcwinsys.dll %XCHAT_DEST%\plugins
-- 
cgit 1.4.1


From 1cbe3789da4a3684db9de79f6bfd98ff3de3c5ff Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Tue, 10 Jan 2012 05:22:58 +0100
Subject: xsasl save/load more or less works, need to get rid of lists

---
 plugins/xsasl/xsasl.c | 38 +++++++++++++++++++++++++++++++++-----
 1 file changed, 33 insertions(+), 5 deletions(-)

(limited to 'plugins')

diff --git a/plugins/xsasl/xsasl.c b/plugins/xsasl/xsasl.c
index 776b8137..4b1e06b3 100644
--- a/plugins/xsasl/xsasl.c
+++ b/plugins/xsasl/xsasl.c
@@ -20,7 +20,7 @@
 
 #define PNAME "XSASL"
 #define PDESC "SASL authentication plugin";
-#define PVERSION "0.0.4"
+#define PVERSION "1.0"
 
 static xchat_plugin *ph;   /* plugin handle */
 
@@ -40,6 +40,7 @@ sasl_info* all_info = NULL;
 
 static void add_info(char const* login, char const* password, char const* network)
 {
+  char buffer[512];
   sasl_info* prev = all_info;
   sasl_info* info = (sasl_info*)malloc(sizeof(sasl_info));
 
@@ -49,16 +50,43 @@ static void add_info(char const* login, char const* password, char const* networ
   info->next = prev;
 
   all_info = info;
+
+  sprintf (buffer, "%s:%s", login, password);
+  xchat_set_pluginpref_str (ph, network, buffer);
 }
 
 static sasl_info* find_info(char const* network)
 {
-  sasl_info* cur = all_info;
+  //sasl_info* cur;
+  sasl_info* cur = (sasl_info*)malloc(sizeof(sasl_info));
+  char buffer[512];
+  char* pos;
+  char* token;
+
+  // DEBUG
+  if (xchat_get_pluginpref_str (ph, network, buffer))
+  {
+    cur->network = strdup (network);
+	//pos = strchr (buffer, ':');
+	//cur->login = g_strndup (buffer, pos-buffer);
+	token = strtok (buffer, ":");
+	cur->login = g_strdup (token);
+	token = strtok (NULL, ":");
+	cur->password = g_strdup (token);
+	//xchat_printf (ph, "network: %s\n", cur->network);
+	//xchat_printf (ph, "login: %s\n", cur->login);
+	//xchat_printf (ph, "password: %s\n", cur->password);
+	cur->next = NULL;
+	return cur;
+  }
+#if 0
+  cur = all_info;
   while (cur)
   {
     if (0 == strcmp(cur->network, network)) return cur;
     cur = cur->next;
   }
+#endif
   return NULL;
 }
 
@@ -142,7 +170,7 @@ static int sasl_cmd_cb(char *word[], char *word_eol[], void *userdata)
     sasl_info *cur = all_info;
     if (NULL == cur)
     {
-      xchat_printf(ph,"Nothing, see /help sasl");
+      xchat_printf(ph,"Nothing, see /HELP XSASL");
       return XCHAT_EAT_ALL;
     }
 
@@ -156,7 +184,7 @@ static int sasl_cmd_cb(char *word[], char *word_eol[], void *userdata)
 
   if (!login || !password || !network || !*login || !*password || !*network)
   {
-    xchat_printf(ph,"Wrong usage, try /help sasl");
+    xchat_printf(ph,"Wrong usage, try /HELP XSASL");
     return XCHAT_EAT_ALL;
   }
 
@@ -192,7 +220,7 @@ int xchat_plugin_init(xchat_plugin *plugin_handle,
   *plugin_desc = PDESC;
   *plugin_version = PVERSION;
 
-  xchat_hook_command(ph, "sasl", XCHAT_PRI_NORM, sasl_cmd_cb, 
+  xchat_hook_command(ph, "xsasl", XCHAT_PRI_NORM, sasl_cmd_cb,
     "Usage: SASL <login> <password> <network>, enable SASL authentication for given network", 0);
 
   xchat_hook_print(ph, "Connected", XCHAT_PRI_NORM, connect_cb, NULL);
-- 
cgit 1.4.1


From 2456d0d3fa48b155eb870eebf011732463782562 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Tue, 10 Jan 2012 06:15:03 +0100
Subject: reformatting, cleanup

---
 plugins/xsasl/xsasl.c | 359 ++++++++++++++++++++++++--------------------------
 1 file changed, 172 insertions(+), 187 deletions(-)

(limited to 'plugins')

diff --git a/plugins/xsasl/xsasl.c b/plugins/xsasl/xsasl.c
index 4b1e06b3..c8f452a0 100644
--- a/plugins/xsasl/xsasl.c
+++ b/plugins/xsasl/xsasl.c
@@ -1,8 +1,30 @@
+/* XChat-WDK
+ * Copyright (c) 2010 <ygrek@autistici.org>
+ * Copyright (c) 2012 Berke Viktor.
+ *
+ * Permission is hereby granted, free of charge, to any person obtaining a copy
+ * of this software and associated documentation files (the "Software"), to deal
+ * in the Software without restriction, including without limitation the rights
+ * to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+ * copies of the Software, and to permit persons to whom the Software is
+ * furnished to do so, subject to the following conditions:
+ *
+ * The above copyright notice and this permission notice shall be included in
+ * all copies or substantial portions of the Software.
+ *
+ * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+ * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+ * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+ * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+ * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+ * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+ * THE SOFTWARE.
+ */
+
 /*
  * SASL authentication plugin for XChat
  * Extremely primitive: only PLAIN, no error checking
  *
- * Copyright (c) 2010, <ygrek@autistici.org>
  * http://ygrek.org.ua/p/cap_sasl.html
  *
  * Docs:
@@ -10,7 +32,6 @@
  *  http://tools.ietf.org/html/rfc4422
  */
 
-
 #include <string.h>
 #include <stdlib.h>
 #include <assert.h>
@@ -18,235 +39,199 @@
 
 #include "xchat-plugin.h"
 
-#define PNAME "XSASL"
-#define PDESC "SASL authentication plugin";
-#define PVERSION "1.0"
-
 static xchat_plugin *ph;   /* plugin handle */
-
-struct sasl_info;
+static const char name[] = "XSASL";
+static const char desc[] = "SASL authentication plugin for XChat";
+static const char version[] = "1.0";
 
 struct sasl_info
 {
-  char const* login;
-  char const* password;
-  char const* network;
-  struct sasl_info* next;
+	char const* login;
+	char const* password;
+	char const* network;
 };
 
 typedef struct sasl_info sasl_info;
 
-sasl_info* all_info = NULL;
-
-static void add_info(char const* login, char const* password, char const* network)
+static void
+add_info (char const* login, char const* password, char const* network)
 {
-  char buffer[512];
-  sasl_info* prev = all_info;
-  sasl_info* info = (sasl_info*)malloc(sizeof(sasl_info));
+	char buffer[512];
 
-  info->login = strdup(login);
-  info->password = strdup(password);
-  info->network = strdup(network);
-  info->next = prev;
-
-  all_info = info;
-
-  sprintf (buffer, "%s:%s", login, password);
-  xchat_set_pluginpref_str (ph, network, buffer);
+	sprintf (buffer, "%s:%s", login, password);
+	xchat_set_pluginpref_str (ph, network, buffer);
 }
 
-static sasl_info* find_info(char const* network)
+static sasl_info*
+find_info (char const* network)
 {
-  //sasl_info* cur;
-  sasl_info* cur = (sasl_info*)malloc(sizeof(sasl_info));
-  char buffer[512];
-  char* pos;
-  char* token;
-
-  // DEBUG
-  if (xchat_get_pluginpref_str (ph, network, buffer))
-  {
-    cur->network = strdup (network);
-	//pos = strchr (buffer, ':');
-	//cur->login = g_strndup (buffer, pos-buffer);
-	token = strtok (buffer, ":");
-	cur->login = g_strdup (token);
-	token = strtok (NULL, ":");
-	cur->password = g_strdup (token);
-	//xchat_printf (ph, "network: %s\n", cur->network);
-	//xchat_printf (ph, "login: %s\n", cur->login);
-	//xchat_printf (ph, "password: %s\n", cur->password);
-	cur->next = NULL;
-	return cur;
-  }
-#if 0
-  cur = all_info;
-  while (cur)
-  {
-    if (0 == strcmp(cur->network, network)) return cur;
-    cur = cur->next;
-  }
-#endif
-  return NULL;
+	char buffer[512];
+	char* token;
+	sasl_info* cur = (sasl_info*) malloc (sizeof (sasl_info));
+
+	if (xchat_get_pluginpref_str (ph, network, buffer))
+	{
+		token = strtok (buffer, ":");
+		cur->login = g_strdup (token);
+		token = strtok (NULL, ":");
+		cur->password = g_strdup (token);
+		cur->network = g_strdup (network);
+
+		return cur;
+	}
+
+	return NULL;
 }
 
-static sasl_info* get_info(void)
+static sasl_info*
+get_info (void)
 {
-  const char* name = xchat_get_info(ph, "network");
-  if (name) 
-    return find_info(name);
-  else 
-    return NULL;
+	const char* name;
+	name = xchat_get_info (ph, "network");
+
+	if (name)
+	{
+		return find_info (name);
+	}
+	else
+	{
+		return NULL;
+	}
 }
 
-static int authend_cb(char *word[], char *word_eol[], void *userdata)
+static int
+authend_cb (char *word[], char *word_eol[], void *userdata)
 {
-  if (get_info())
-  {
-    xchat_printf(ph, "XSASL result: %s", word_eol[1]);
-    xchat_commandf(ph, "QUOTE CAP END");
-  }
-  return XCHAT_EAT_ALL;
+	if (get_info ())
+	{
+		xchat_printf (ph, "XSASL result: %s\n", word_eol[1]);
+		xchat_commandf (ph, "QUOTE CAP END");
+	}
+
+	return XCHAT_EAT_ALL;
 }
 
 /*
-static int disconnect_cb(char *word[], void *userdata)
+static int
+disconnect_cb (char *word[], void *userdata)
 {
-  xchat_printf(ph, "disconnected");
-  return XCHAT_EAT_NONE;
+	xchat_printf (ph, "disconnected\n");
+	return XCHAT_EAT_NONE;
 }
 */
 
-static int server_cb(char *word[], char *word_eol[], void *userdata)
+static int
+server_cb (char *word[], char *word_eol[], void *userdata)
 {
-  if (0 == strcmp("AUTHENTICATE",word[1]) && 0 == strcmp("+",word[2]))
-  {
-    size_t len;
-    char* buf;
-    char* enc;
-    sasl_info* p = get_info();
-    if (!p) return XCHAT_EAT_NONE;
-
-    xchat_printf(ph,"XSASL authenticating as %s",p->login);
-
-    len = strlen(p->login)*2 + 2 + strlen(p->password);
-    buf = (char*)malloc(len + 1);
-    strcpy(buf,p->login);
-    strcpy(buf+strlen(p->login)+1,p->login);
-    strcpy(buf+strlen(p->login)*2+2,p->password);
-    enc = g_base64_encode((unsigned char*)buf,len);
-
-    /*xchat_printf(ph,"AUTHENTICATE %s",enc);*/
-    xchat_commandf(ph,"QUOTE AUTHENTICATE %s",enc);
-
-    free(enc);
-    free(buf);
-
-    return XCHAT_EAT_ALL;
-  }
-	return XCHAT_EAT_NONE;
-}
+	size_t len;
+	char* buf;
+	char* enc;
+	sasl_info* p;
 
-static int cap_cb(char *word[], char *word_eol[], void *userdata)
-{
-  if (get_info())
-  {
-    /* FIXME test sasl cap */
-    xchat_printf(ph, "XSASL info: %s", word_eol[1]);
-    xchat_commandf(ph,"QUOTE AUTHENTICATE PLAIN");
-  }
-
-  return XCHAT_EAT_ALL;
-}
+	if (strcmp ("AUTHENTICATE", word[1]) == 0 && strcmp ("+", word[2]) == 0)
+	{
+		p = get_info ();
 
-static int sasl_cmd_cb(char *word[], char *word_eol[], void *userdata)
-{
-  const char* login = word[2];
-  const char* password = word[3];
-  const char* network = word_eol[4];
-
-  if (!login || !*login)
-  {
-    sasl_info *cur = all_info;
-    if (NULL == cur)
-    {
-      xchat_printf(ph,"Nothing, see /HELP XSASL");
-      return XCHAT_EAT_ALL;
-    }
-
-    while (cur)
-    {
-      xchat_printf(ph,"%s:%s at %s",cur->login,cur->password,cur->network);
-      cur = cur->next;
-    }
-    return XCHAT_EAT_ALL;
-  }
-
-  if (!login || !password || !network || !*login || !*password || !*network)
-  {
-    xchat_printf(ph,"Wrong usage, try /HELP XSASL");
-    return XCHAT_EAT_ALL;
-  }
-
-  add_info(login,password,network);
-
-  xchat_printf(ph,"Enabled SASL authentication for %s",network);
-
-  return XCHAT_EAT_ALL;
+		if (!p)
+		{
+			return XCHAT_EAT_NONE;
+		}
+
+		xchat_printf (ph, "XSASL authenticating as %s\n", p->login);
+
+		len = strlen (p->login) * 2 + 2 + strlen (p->password);
+		buf = (char*) malloc (len + 1);
+		strcpy (buf, p->login);
+		strcpy (buf + strlen (p->login) + 1, p->login);
+		strcpy (buf + strlen (p->login) * 2 + 2, p->password);
+		enc = g_base64_encode ((unsigned char*) buf, len);
+
+		/* xchat_printf (ph, "AUTHENTICATE %s\}", enc); */
+		xchat_commandf (ph, "QUOTE AUTHENTICATE %s", enc);
+
+		free (enc);
+		free (buf);
+
+		return XCHAT_EAT_ALL;
+	}
+
+	return XCHAT_EAT_NONE;
 }
 
-static int connect_cb(char *word[], void *userdata)
+static int
+cap_cb (char *word[], char *word_eol[], void *userdata)
 {
-  if (get_info())
-  {
-    xchat_printf(ph, "XSASL enabled");
-    xchat_commandf(ph, "QUOTE CAP REQ :sasl");
-  }
-
-  return XCHAT_EAT_NONE;
+	if (get_info ())
+	{
+		/* FIXME test sasl cap */
+		xchat_printf (ph, "XSASL info: %s\n", word_eol[1]);
+		xchat_commandf (ph, "QUOTE AUTHENTICATE PLAIN");
+	}
+
+	return XCHAT_EAT_ALL;
 }
 
-int xchat_plugin_init(xchat_plugin *plugin_handle,
-                      char **plugin_name,
-                      char **plugin_desc,
-                      char **plugin_version,
-                      char *arg)
+static int
+sasl_cmd_cb (char *word[], char *word_eol[], void *userdata)
 {
-  /* we need to save this for use with any xchat_* functions */
-  ph = plugin_handle;
+	const char* login = word[2];
+	const char* password = word[3];
+	const char* network = word_eol[4];
 
-  /* tell xchat our info */
-  *plugin_name = PNAME;
-  *plugin_desc = PDESC;
-  *plugin_version = PVERSION;
+	if (!login || !password || !network || !*login || !*password || !*network)
+	{
+		xchat_printf (ph, "Usage: SASL <login> <password> <network>, enable SASL authentication for given network\n");
+		return XCHAT_EAT_ALL;
+	}
 
-  xchat_hook_command(ph, "xsasl", XCHAT_PRI_NORM, sasl_cmd_cb,
-    "Usage: SASL <login> <password> <network>, enable SASL authentication for given network", 0);
+	add_info (login, password, network);
+	xchat_printf (ph, "Enabled SASL authentication for the \"%s\" network\n", network);
 
-  xchat_hook_print(ph, "Connected", XCHAT_PRI_NORM, connect_cb, NULL);
-/*
-  xchat_hook_print(ph, "Disconnected", XCHAT_PRI_NORM, disconnect_cb, NULL);
-*/
-
-  xchat_hook_server(ph, "CAP", XCHAT_PRI_NORM, cap_cb, NULL);
-  xchat_hook_server(ph, "RAW LINE", XCHAT_PRI_NORM, server_cb, NULL);
+	return XCHAT_EAT_ALL;
+}
 
-  xchat_hook_server(ph, "903", XCHAT_PRI_NORM, authend_cb, NULL);
-  xchat_hook_server(ph, "904", XCHAT_PRI_NORM, authend_cb, NULL);
-  xchat_hook_server(ph, "905", XCHAT_PRI_NORM, authend_cb, NULL);
-  xchat_hook_server(ph, "906", XCHAT_PRI_NORM, authend_cb, NULL);
-  xchat_hook_server(ph, "907", XCHAT_PRI_NORM, authend_cb, NULL);
+static int
+connect_cb (char *word[], void *userdata)
+{
+	if (get_info ())
+	{
+		xchat_printf (ph, "XSASL enabled\n");
+		xchat_commandf (ph, "QUOTE CAP REQ :sasl");
+	}
 
-  /* xchat_print(ph,"Loading cap_sasl.conf");
-  xchat_commandf(ph, "load -e %s/cap_sasl.conf",xchat_get_info(ph, "xchatdir")); */
+	return XCHAT_EAT_NONE;
+}
 
-  xchat_printf(ph, PNAME " plugin loaded\n");
+int
+xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugin_desc, char **plugin_version, char *arg)
+{
+	/* we need to save this for use with any xchat_* functions */
+	ph = plugin_handle;
+
+	/* tell xchat our info */
+	*plugin_name = name;
+	*plugin_desc = desc;
+	*plugin_version = version;
+
+	xchat_hook_command (ph, "XSASL", XCHAT_PRI_NORM, sasl_cmd_cb, "Usage: SASL <login> <password> <network>, enable SASL authentication for given network", 0);
+	xchat_hook_print (ph, "Connected", XCHAT_PRI_NORM, connect_cb, NULL);
+	/* xchat_hook_print (ph, "Disconnected", XCHAT_PRI_NORM, disconnect_cb, NULL); */
+	xchat_hook_server (ph, "CAP", XCHAT_PRI_NORM, cap_cb, NULL);
+	xchat_hook_server (ph, "RAW LINE", XCHAT_PRI_NORM, server_cb, NULL);
+	xchat_hook_server (ph, "903", XCHAT_PRI_NORM, authend_cb, NULL);
+	xchat_hook_server (ph, "904", XCHAT_PRI_NORM, authend_cb, NULL);
+	xchat_hook_server (ph, "905", XCHAT_PRI_NORM, authend_cb, NULL);
+	xchat_hook_server (ph, "906", XCHAT_PRI_NORM, authend_cb, NULL);
+	xchat_hook_server (ph, "907", XCHAT_PRI_NORM, authend_cb, NULL);
+
+	xchat_printf (ph, "%s plugin loaded\n", name);
 
-  return 1;
+	return 1;
 }
 
-int xchat_plugin_deinit (void)
+int
+xchat_plugin_deinit (void)
 {
-	xchat_printf(ph, PNAME " plugin unloaded\n");
+	xchat_printf (ph, "%s plugin unloaded\n", name);
 	return 1;
 }
-- 
cgit 1.4.1


From 6a0aa95fee2de466dfc925db7cc475ec538a4a88 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Tue, 10 Jan 2012 08:28:03 +0100
Subject: update command names

---
 plugins/xsasl/xsasl.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

(limited to 'plugins')

diff --git a/plugins/xsasl/xsasl.c b/plugins/xsasl/xsasl.c
index c8f452a0..c902c7b6 100644
--- a/plugins/xsasl/xsasl.c
+++ b/plugins/xsasl/xsasl.c
@@ -180,7 +180,7 @@ sasl_cmd_cb (char *word[], char *word_eol[], void *userdata)
 
 	if (!login || !password || !network || !*login || !*password || !*network)
 	{
-		xchat_printf (ph, "Usage: SASL <login> <password> <network>, enable SASL authentication for given network\n");
+		xchat_printf (ph, "Usage: XSASL <login> <password> <network>, enable SASL authentication for given network\n");
 		return XCHAT_EAT_ALL;
 	}
 
@@ -213,7 +213,7 @@ xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugi
 	*plugin_desc = desc;
 	*plugin_version = version;
 
-	xchat_hook_command (ph, "XSASL", XCHAT_PRI_NORM, sasl_cmd_cb, "Usage: SASL <login> <password> <network>, enable SASL authentication for given network", 0);
+	xchat_hook_command (ph, "XSASL", XCHAT_PRI_NORM, sasl_cmd_cb, "Usage: XSASL <login> <password> <network>, enable SASL authentication for given network", 0);
 	xchat_hook_print (ph, "Connected", XCHAT_PRI_NORM, connect_cb, NULL);
 	/* xchat_hook_print (ph, "Disconnected", XCHAT_PRI_NORM, disconnect_cb, NULL); */
 	xchat_hook_server (ph, "CAP", XCHAT_PRI_NORM, cap_cb, NULL);
-- 
cgit 1.4.1


From 3321be6edbf6bf7325639bb762825f3836295019 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Tue, 10 Jan 2012 08:30:31 +0100
Subject: update xtray compilation date

---
 plugins/xtray/resource.rc | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/xtray/resource.rc b/plugins/xtray/resource.rc
index 906cf591..312c74c4 100644
--- a/plugins/xtray/resource.rc
+++ b/plugins/xtray/resource.rc
@@ -99,7 +99,7 @@ BEGIN
     GROUPBOX        "Version Information:",IDC_STATIC,101,92,109,49
     LTEXT           "1.2.4",IDC_STATIC,170,105,33,8,0,WS_EX_RIGHT
     LTEXT           "Compiled In: ",IDC_STATIC,110,117,54,8
-    LTEXT           "2011",IDC_STATIC,170,117,33,8,0,WS_EX_RIGHT
+    LTEXT           "2012",IDC_STATIC,170,117,33,8,0,WS_EX_RIGHT
     LTEXT           "Version Number:",IDC_STATIC,110,105,54,8
 END
 
-- 
cgit 1.4.1


From 9eae6db37feb2a66bf44d351e805e451d309f42a Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Wed, 11 Jan 2012 20:16:23 +0100
Subject: X-SASL cosmetics

---
 plugins/xsasl/xsasl.c | 12 ++++++------
 1 file changed, 6 insertions(+), 6 deletions(-)

(limited to 'plugins')

diff --git a/plugins/xsasl/xsasl.c b/plugins/xsasl/xsasl.c
index c902c7b6..e6840ad1 100644
--- a/plugins/xsasl/xsasl.c
+++ b/plugins/xsasl/xsasl.c
@@ -40,7 +40,7 @@
 #include "xchat-plugin.h"
 
 static xchat_plugin *ph;   /* plugin handle */
-static const char name[] = "XSASL";
+static const char name[] = "X-SASL";
 static const char desc[] = "SASL authentication plugin for XChat";
 static const char version[] = "1.0";
 
@@ -104,7 +104,7 @@ authend_cb (char *word[], char *word_eol[], void *userdata)
 {
 	if (get_info ())
 	{
-		xchat_printf (ph, "XSASL result: %s\n", word_eol[1]);
+		xchat_printf (ph, "%s\t %s\n", name, word_eol[1]);
 		xchat_commandf (ph, "QUOTE CAP END");
 	}
 
@@ -137,7 +137,7 @@ server_cb (char *word[], char *word_eol[], void *userdata)
 			return XCHAT_EAT_NONE;
 		}
 
-		xchat_printf (ph, "XSASL authenticating as %s\n", p->login);
+		xchat_printf (ph, "%s\tAuthenticating as %s\n", name, p->login);
 
 		len = strlen (p->login) * 2 + 2 + strlen (p->password);
 		buf = (char*) malloc (len + 1);
@@ -164,7 +164,7 @@ cap_cb (char *word[], char *word_eol[], void *userdata)
 	if (get_info ())
 	{
 		/* FIXME test sasl cap */
-		xchat_printf (ph, "XSASL info: %s\n", word_eol[1]);
+		xchat_printf (ph, "%s\t %s\n", name, word_eol[1]);
 		xchat_commandf (ph, "QUOTE AUTHENTICATE PLAIN");
 	}
 
@@ -185,7 +185,7 @@ sasl_cmd_cb (char *word[], char *word_eol[], void *userdata)
 	}
 
 	add_info (login, password, network);
-	xchat_printf (ph, "Enabled SASL authentication for the \"%s\" network\n", network);
+	xchat_printf (ph, "%s\tEnabled SASL authentication for the \"%s\" network\n", name, network);
 
 	return XCHAT_EAT_ALL;
 }
@@ -195,7 +195,7 @@ connect_cb (char *word[], void *userdata)
 {
 	if (get_info ())
 	{
-		xchat_printf (ph, "XSASL enabled\n");
+		xchat_printf (ph, "%s\tSASL enabled\n", name);
 		xchat_commandf (ph, "QUOTE CAP REQ :sasl");
 	}
 
-- 
cgit 1.4.1


From 6eb1fcbbe7438812620ce40f4c2c1a82e2820a1c Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Wed, 11 Jan 2012 20:31:11 +0100
Subject: remove extra spaces from xsasl messages

---
 plugins/xsasl/xsasl.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

(limited to 'plugins')

diff --git a/plugins/xsasl/xsasl.c b/plugins/xsasl/xsasl.c
index e6840ad1..e6d6312f 100644
--- a/plugins/xsasl/xsasl.c
+++ b/plugins/xsasl/xsasl.c
@@ -104,7 +104,7 @@ authend_cb (char *word[], char *word_eol[], void *userdata)
 {
 	if (get_info ())
 	{
-		xchat_printf (ph, "%s\t %s\n", name, word_eol[1]);
+		xchat_printf (ph, "%s\t%s\n", name, word_eol[1]);
 		xchat_commandf (ph, "QUOTE CAP END");
 	}
 
@@ -164,7 +164,7 @@ cap_cb (char *word[], char *word_eol[], void *userdata)
 	if (get_info ())
 	{
 		/* FIXME test sasl cap */
-		xchat_printf (ph, "%s\t %s\n", name, word_eol[1]);
+		xchat_printf (ph, "%s\t%s\n", name, word_eol[1]);
 		xchat_commandf (ph, "QUOTE AUTHENTICATE PLAIN");
 	}
 
-- 
cgit 1.4.1


From c979a8a8b7493538dde5b80936b298ad6b57c877 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Wed, 11 Jan 2012 21:35:02 +0100
Subject: some more xsasl cosmetics

---
 plugins/xsasl/xsasl.c        | 6 ++++--
 win32/xchat-wdk-x64.skel.iss | 2 +-
 win32/xchat-wdk-x86.skel.iss | 2 +-
 3 files changed, 6 insertions(+), 4 deletions(-)

(limited to 'plugins')

diff --git a/plugins/xsasl/xsasl.c b/plugins/xsasl/xsasl.c
index e6d6312f..f0521c47 100644
--- a/plugins/xsasl/xsasl.c
+++ b/plugins/xsasl/xsasl.c
@@ -104,7 +104,8 @@ authend_cb (char *word[], char *word_eol[], void *userdata)
 {
 	if (get_info ())
 	{
-		xchat_printf (ph, "%s\t%s\n", name, word_eol[1]);
+		/* omit cryptic server message parts */
+		xchat_printf (ph, "%s\t%s\n", name, ++word_eol[4]);
 		xchat_commandf (ph, "QUOTE CAP END");
 	}
 
@@ -164,7 +165,8 @@ cap_cb (char *word[], char *word_eol[], void *userdata)
 	if (get_info ())
 	{
 		/* FIXME test sasl cap */
-		xchat_printf (ph, "%s\t%s\n", name, word_eol[1]);
+		/* this is visible in the rawlog in case someone needs it, otherwise it's just noise */
+		/* xchat_printf (ph, "%s\t%s\n", name, word_eol[1]); */
 		xchat_commandf (ph, "QUOTE AUTHENTICATE PLAIN");
 	}
 
diff --git a/win32/xchat-wdk-x64.skel.iss b/win32/xchat-wdk-x64.skel.iss
index c903a8d1..815bdd48 100644
--- a/win32/xchat-wdk-x64.skel.iss
+++ b/win32/xchat-wdk-x64.skel.iss
@@ -43,7 +43,7 @@ Name: "plugins\upd"; Description: "Update Checker"; Types: normal full custom; F
 Name: "plugins\winamp"; Description: "Winamp"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\winsys"; Description: "WinSys"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\wmpa"; Description: "Windows Media Player Announcer"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\xsasl"; Description: "XSASL"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\xsasl"; Description: "X-SASL"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\xtray"; Description: "X-Tray"; Types: full custom; Flags: disablenouninstallwarning
 Name: "langs"; Description: "Language Interfaces"; Types: full custom; Flags: disablenouninstallwarning
 Name: "langs\lua"; Description: "Lua"; Types: full custom; Flags: disablenouninstallwarning
diff --git a/win32/xchat-wdk-x86.skel.iss b/win32/xchat-wdk-x86.skel.iss
index 1dfeec09..2bc7969f 100644
--- a/win32/xchat-wdk-x86.skel.iss
+++ b/win32/xchat-wdk-x86.skel.iss
@@ -42,7 +42,7 @@ Name: "plugins\upd"; Description: "Update Checker"; Types: normal full custom; F
 Name: "plugins\winamp"; Description: "Winamp"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\winsys"; Description: "WinSys"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\wmpa"; Description: "Windows Media Player Announcer"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\xsasl"; Description: "XSASL"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\xsasl"; Description: "X-SASL"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\xtray"; Description: "X-Tray"; Types: full custom; Flags: disablenouninstallwarning
 Name: "langs"; Description: "Language Interfaces"; Types: full custom; Flags: disablenouninstallwarning
 Name: "langs\lua"; Description: "Lua"; Types: full custom; Flags: disablenouninstallwarning
-- 
cgit 1.4.1


From c3821b6316c3d25ef6affd5215796d3abbefd2fe Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sat, 14 Jan 2012 00:29:01 +0100
Subject: skeleton for xchat_del_pluginpref

---
 plugins/xchat-plugin.h    |  7 +++++++
 src/common/plugin.c       | 21 ++++++++++++++++++---
 src/common/plugin.h       |  2 ++
 src/common/xchat-plugin.h |  7 +++++++
 src/version-script        |  1 +
 5 files changed, 35 insertions(+), 3 deletions(-)

(limited to 'plugins')

diff --git a/plugins/xchat-plugin.h b/plugins/xchat-plugin.h
index 15799424..373c664e 100644
--- a/plugins/xchat-plugin.h
+++ b/plugins/xchat-plugin.h
@@ -148,6 +148,8 @@ struct _xchat_plugin
 		int value);
 	int (*xchat_get_pluginpref_int) (xchat_plugin *ph,
 		const char *var);
+	int (*xchat_del_pluginpref) (xchat_plugin *ph,
+		const char *var);
 };
 #endif
 
@@ -321,6 +323,10 @@ int
 xchat_get_pluginpref_int (xchat_plugin *ph,
 		const char *var);
 
+int
+xchat_del_pluginpref (xchat_plugin *ph,
+		const char *var);
+
 #if !defined(PLUGIN_C) && defined(WIN32)
 #ifndef XCHAT_PLUGIN_HANDLE
 #define XCHAT_PLUGIN_HANDLE (ph)
@@ -359,6 +365,7 @@ xchat_get_pluginpref_int (xchat_plugin *ph,
 #define xchat_get_pluginpref_str ((XCHAT_PLUGIN_HANDLE)->xchat_get_pluginpref_str)
 #define xchat_set_pluginpref_int ((XCHAT_PLUGIN_HANDLE)->xchat_set_pluginpref_int)
 #define xchat_get_pluginpref_int ((XCHAT_PLUGIN_HANDLE)->xchat_get_pluginpref_int)
+#define xchat_del_pluginpref ((XCHAT_PLUGIN_HANDLE)->xchat_del_pluginpref)
 #endif
 
 #ifdef __cplusplus
diff --git a/src/common/plugin.c b/src/common/plugin.c
index 5ed20b87..02cdcce5 100644
--- a/src/common/plugin.c
+++ b/src/common/plugin.c
@@ -274,6 +274,7 @@ plugin_add (session *sess, char *filename, void *handle, void *init_func,
 		pl->xchat_get_pluginpref_str = xchat_get_pluginpref_str;
 		pl->xchat_set_pluginpref_int = xchat_set_pluginpref_int;
 		pl->xchat_get_pluginpref_int = xchat_get_pluginpref_int;
+		pl->xchat_del_pluginpref = xchat_del_pluginpref;
 
 		/* incase new plugins are loaded on older xchat */
 		pl->xchat_dummy4 = xchat_dummy;
@@ -1587,9 +1588,11 @@ xchat_free (xchat_plugin *ph, void *ptr)
 	g_free (ptr);
 }
 
-int
-xchat_set_pluginpref_str (xchat_plugin *pl, const char *var, const char *value)
+static int
+xchat_set_pluginpref_str_real (xchat_plugin *pl, const char *var, const char *value, int mode)
 {
+	/* mode: 0 = delete, 1 = save */
+
 	FILE *fpIn;
 	int fhOut;
 	int prevConfig;
@@ -1683,6 +1686,12 @@ xchat_set_pluginpref_str (xchat_plugin *pl, const char *var, const char *value)
 	}
 }
 
+int
+xchat_set_pluginpref_str (xchat_plugin *pl, const char *var, const char *value)
+{
+	return xchat_set_pluginpref_str (pl, var, value, 1);
+}
+
 int
 xchat_get_pluginpref_str (xchat_plugin *pl, const char *var, char *dest)
 {
@@ -1741,7 +1750,7 @@ xchat_set_pluginpref_int (xchat_plugin *pl, const char *var, int value)
 	char buffer[12];
 
 	sprintf (buffer, "%d", value);
-	return xchat_set_pluginpref_str (pl, var, buffer);
+	return xchat_set_pluginpref_str_real (pl, var, buffer, 1);
 }
 
 int
@@ -1758,3 +1767,9 @@ xchat_get_pluginpref_int (xchat_plugin *pl, const char *var)
 		return -1;
 	}
 }
+
+int
+xchat_del_pluginpref (xchat_plugin *pl, const char *var)
+{
+	xchat_set_pluginpref_str_real (pl, var, 0, 0);
+}
diff --git a/src/common/plugin.h b/src/common/plugin.h
index cddb86fb..bb86f0a3 100644
--- a/src/common/plugin.h
+++ b/src/common/plugin.h
@@ -109,6 +109,8 @@ struct _xchat_plugin
 		int value);
 	int (*xchat_get_pluginpref_int) (xchat_plugin *ph,
 		const char *var);
+	int (*xchat_del_pluginpref) (xchat_plugin *ph,
+		const char *var);
 	void *(*xchat_dummy4) (xchat_plugin *ph);
 	void *(*xchat_dummy3) (xchat_plugin *ph);
 	void *(*xchat_dummy2) (xchat_plugin *ph);
diff --git a/src/common/xchat-plugin.h b/src/common/xchat-plugin.h
index 15799424..373c664e 100644
--- a/src/common/xchat-plugin.h
+++ b/src/common/xchat-plugin.h
@@ -148,6 +148,8 @@ struct _xchat_plugin
 		int value);
 	int (*xchat_get_pluginpref_int) (xchat_plugin *ph,
 		const char *var);
+	int (*xchat_del_pluginpref) (xchat_plugin *ph,
+		const char *var);
 };
 #endif
 
@@ -321,6 +323,10 @@ int
 xchat_get_pluginpref_int (xchat_plugin *ph,
 		const char *var);
 
+int
+xchat_del_pluginpref (xchat_plugin *ph,
+		const char *var);
+
 #if !defined(PLUGIN_C) && defined(WIN32)
 #ifndef XCHAT_PLUGIN_HANDLE
 #define XCHAT_PLUGIN_HANDLE (ph)
@@ -359,6 +365,7 @@ xchat_get_pluginpref_int (xchat_plugin *ph,
 #define xchat_get_pluginpref_str ((XCHAT_PLUGIN_HANDLE)->xchat_get_pluginpref_str)
 #define xchat_set_pluginpref_int ((XCHAT_PLUGIN_HANDLE)->xchat_set_pluginpref_int)
 #define xchat_get_pluginpref_int ((XCHAT_PLUGIN_HANDLE)->xchat_get_pluginpref_int)
+#define xchat_del_pluginpref ((XCHAT_PLUGIN_HANDLE)->xchat_del_pluginpref)
 #endif
 
 #ifdef __cplusplus
diff --git a/src/version-script b/src/version-script
index e76f4fe9..fe04dd46 100644
--- a/src/version-script
+++ b/src/version-script
@@ -34,5 +34,6 @@ EXPORTED {
 		xchat_get_pluginpref_str;
 		xchat_set_pluginpref_int;
 		xchat_get_pluginpref_int;
+		xchat_del_pluginpref;
 	local: *;
 };
-- 
cgit 1.4.1


From e421c11686c7ab9e21d9fbf34ba363f990d45fa9 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sat, 14 Jan 2012 03:05:42 +0100
Subject: support for removing existing networks in xsasl

---
 plugins/xsasl/xsasl.c | 71 ++++++++++++++++++++++++++++++++++++++++++---------
 1 file changed, 59 insertions(+), 12 deletions(-)

(limited to 'plugins')

diff --git a/plugins/xsasl/xsasl.c b/plugins/xsasl/xsasl.c
index f0521c47..cbf569e2 100644
--- a/plugins/xsasl/xsasl.c
+++ b/plugins/xsasl/xsasl.c
@@ -42,7 +42,8 @@
 static xchat_plugin *ph;   /* plugin handle */
 static const char name[] = "X-SASL";
 static const char desc[] = "SASL authentication plugin for XChat";
-static const char version[] = "1.0";
+static const char version[] = "1.1";
+static const char xsasl_help[] = "X-SASL Usage:\n /XSASL ADD <login> <password> <network>, enable SASL authentication for given network\n /XSASL DEL <network>, disable SASL authentication for given network\n";
 
 struct sasl_info
 {
@@ -53,13 +54,19 @@ struct sasl_info
 
 typedef struct sasl_info sasl_info;
 
-static void
+static int
 add_info (char const* login, char const* password, char const* network)
 {
 	char buffer[512];
 
 	sprintf (buffer, "%s:%s", login, password);
-	xchat_set_pluginpref_str (ph, network, buffer);
+	return xchat_set_pluginpref_str (ph, network, buffer);
+}
+
+static int
+del_info (char const* network)
+{
+	return xchat_del_pluginpref (ph, network);
 }
 
 static sasl_info*
@@ -176,20 +183,60 @@ cap_cb (char *word[], char *word_eol[], void *userdata)
 static int
 sasl_cmd_cb (char *word[], char *word_eol[], void *userdata)
 {
-	const char* login = word[2];
-	const char* password = word[3];
-	const char* network = word_eol[4];
+	const char* login;
+	const char* password;
+	const char* network;
+	const char* mode = word[2];
 
-	if (!login || !password || !network || !*login || !*password || !*network)
+	if (!stricmp ("ADD", mode))
 	{
-		xchat_printf (ph, "Usage: XSASL <login> <password> <network>, enable SASL authentication for given network\n");
+		login = word[3];
+		password = word[4];
+		network = word_eol[5];
+
+		if (!network || !*network)	/* only check for the last word, if it's there, the previous ones will be there, too */
+		{
+			xchat_printf (ph, "%s", xsasl_help);
+			return XCHAT_EAT_ALL;
+		}
+
+		if (add_info (login, password, network))
+		{
+			xchat_printf (ph, "%s\tEnabled SASL authentication for the \"%s\" network\n", name, network);
+		}
+		else
+		{
+			xchat_printf (ph, "%s\tFailed to enable SASL authentication for the \"%s\" network\n", name, network);
+		}
+
 		return XCHAT_EAT_ALL;
 	}
+	else if (!stricmp ("DEL", mode))
+	{
+		network = word_eol[3];
 
-	add_info (login, password, network);
-	xchat_printf (ph, "%s\tEnabled SASL authentication for the \"%s\" network\n", name, network);
+		if (!network || !*network)
+		{
+			xchat_printf (ph, "%s", xsasl_help);
+			return XCHAT_EAT_ALL;
+		}
 
-	return XCHAT_EAT_ALL;
+		if (del_info (network))
+		{
+			xchat_printf (ph, "%s\tDisabled SASL authentication for the \"%s\" network\n", name, network);
+		}
+		else
+		{
+			xchat_printf (ph, "%s\tFailed to disable SASL authentication for the \"%s\" network\n", name, network);
+		}
+
+		return XCHAT_EAT_ALL;
+	}
+	else
+	{
+		xchat_printf (ph, "%s", xsasl_help);
+		return XCHAT_EAT_ALL;
+	}
 }
 
 static int
@@ -215,7 +262,7 @@ xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugi
 	*plugin_desc = desc;
 	*plugin_version = version;
 
-	xchat_hook_command (ph, "XSASL", XCHAT_PRI_NORM, sasl_cmd_cb, "Usage: XSASL <login> <password> <network>, enable SASL authentication for given network", 0);
+	xchat_hook_command (ph, "XSASL", XCHAT_PRI_NORM, sasl_cmd_cb, xsasl_help, 0);
 	xchat_hook_print (ph, "Connected", XCHAT_PRI_NORM, connect_cb, NULL);
 	/* xchat_hook_print (ph, "Disconnected", XCHAT_PRI_NORM, disconnect_cb, NULL); */
 	xchat_hook_server (ph, "CAP", XCHAT_PRI_NORM, cap_cb, NULL);
-- 
cgit 1.4.1


From 4942dc667f3ff40601b7afd2efd91dff1f73789a Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sun, 15 Jan 2012 19:07:48 +0100
Subject: refactor plugin config API and add skeleton for xchat_pluginpref_list

---
 plugins/plugin20.html     | 61 ++++++++++++++++++++++++++++++++++-------------
 plugins/xchat-plugin.h    | 37 ++++++++++++++++------------
 src/common/plugin.c       | 37 ++++++++++++++++------------
 src/common/plugin.h       | 12 ++++++----
 src/common/xchat-plugin.h | 37 ++++++++++++++++------------
 src/version-script        | 11 +++++----
 6 files changed, 124 insertions(+), 71 deletions(-)

(limited to 'plugins')

diff --git a/plugins/plugin20.html b/plugins/plugin20.html
index a9aaaace..6323cd80 100644
--- a/plugins/plugin20.html
+++ b/plugins/plugin20.html
@@ -81,10 +81,12 @@ margin-right: 32px;
 <br><a href="#xchat_strip">xchat_strip</a>
 <br><a href="#xchat_free">xchat_free</a>
 <br>
-<br><a href="#xchat_set_pluginpref_str">xchat_set_pluginpref_str</a>
-<br><a href="#xchat_get_pluginpref_str">xchat_get_pluginpref_str</a>
-<br><a href="#xchat_set_pluginpref_int">xchat_set_pluginpref_int</a>
-<br><a href="#xchat_get_pluginpref_int">xchat_get_pluginpref_int</a>
+<br><a href="#xchat_pluginpref_set_str">xchat_pluginpref_set_str</a>
+<br><a href="#xchat_pluginpref_get_str">xchat_pluginpref_get_str</a>
+<br><a href="#xchat_pluginpref_set_int">xchat_pluginpref_set_int</a>
+<br><a href="#xchat_pluginpref_get_int">xchat_pluginpref_get_int</a>
+<br><a href="#xchat_pluginpref_delete">xchat_pluginpref_delete</a>
+<br><a href="#xchat_pluginpref_list">xchat_pluginpref_list</a>
 <br>
 <br><a href="#lists">xchat_list_get</a>
 <br><a href="#lists">xchat_list_free</a>
@@ -1003,8 +1005,8 @@ A newly allocated string or NULL for failure. You must free this string with xch
 
 <br><br>
 
-<h3><a class=cmd name="xchat_set_pluginpref_str">&nbsp;xchat_set_pluginpref_str()&nbsp;</a><small>(new for 2.8.10)</small></h3>
-<b>Prototype:</b> int xchat_set_pluginpref_str (xchat_plugin *ph, const char *var, const char *value);
+<h3><a class=cmd name="xchat_pluginpref_set_str">&nbsp;xchat_pluginpref_set_str()&nbsp;</a><small>(new for 2.8.10)</small></h3>
+<b>Prototype:</b> int xchat_pluginpref_set_str (xchat_plugin *ph, const char *var, const char *value);
 <br>
 <br><b>Description:</b> Saves a plugin-specific setting with string value to a plugin-specific config file.
 <br>
@@ -1028,8 +1030,8 @@ A newly allocated string or NULL for failure. You must free this string with xch
 	*plugin_desc = "Testing stuff";
 	*plugin_version = "1.0";
 
-	xchat_set_pluginpref_str (ph, "myvar1", "I want to save this string!");
-	xchat_set_pluginpref_str (ph, "myvar2", "This is important, too.");
+	xchat_pluginpref_set_str (ph, "myvar1", "I want to save this string!");
+	xchat_pluginpref_set_str (ph, "myvar2", "This is important, too.");
 
 	return 1;       /* return 1 for success */
 }</pre>
@@ -1042,8 +1044,8 @@ myvar2 = This is important, too.</pre>
 You should never need to edit this file manually.
 <br><br><br>
 
-<h3><a class=cmd name="xchat_get_pluginpref_str">&nbsp;xchat_get_pluginpref_str()&nbsp;</a><small>(new for 2.8.10)</small></h3>
-<b>Prototype:</b> int xchat_get_pluginpref_str (xchat_plugin *ph, const char *var, char *dest);
+<h3><a class=cmd name="xchat_pluginpref_get_str">&nbsp;xchat_pluginpref_get_str()&nbsp;</a><small>(new for 2.8.10)</small></h3>
+<b>Prototype:</b> int xchat_pluginpref_get_str (xchat_plugin *ph, const char *var, char *dest);
 <br>
 <br><b>Description:</b> Loads a plugin-specific setting with string value from a plugin-specific config file.
 <br>
@@ -1056,8 +1058,8 @@ You should never need to edit this file manually.
 <b>Returns:</b> 1 for success, 0 for failure.
 <br><br><br>
 
-<h3><a class=cmd name="xchat_set_pluginpref_int">&nbsp;xchat_set_pluginpref_int()&nbsp;</a><small>(new for 2.8.10)</small></h3>
-<b>Prototype:</b> int xchat_set_pluginpref_int (xchat_plugin *ph, const char *var, int value);
+<h3><a class=cmd name="xchat_pluginpref_set_int">&nbsp;xchat_pluginpref_set_int()&nbsp;</a><small>(new for 2.8.10)</small></h3>
+<b>Prototype:</b> int xchat_pluginpref_set_int (xchat_plugin *ph, const char *var, int value);
 <br>
 <br><b>Description:</b> Saves a plugin-specific setting with decimal value to a plugin-specific config file.
 <br>
@@ -1076,7 +1078,7 @@ You should never need to edit this file manually.
 
 	if (buffer > 0 && buffer < INT_MAX)
 	{
-		if (xchat_set_pluginpref_int (ph, "myint1", buffer))
+		if (xchat_pluginpref_set_int (ph, "myint1", buffer))
 		{
 			xchat_printf (ph, "Setting successfully saved!\n");
 		}
@@ -1093,10 +1095,11 @@ You should never need to edit this file manually.
 	return XCHAT_EAT_XCHAT;
 }</pre>
 </blockquote>
-<br><br>
+You only need these kind of complex checks if you're saving user input, which can be non-numeric.
+<br><br><br>
 
-<h3><a class=cmd name="xchat_get_pluginpref_int">&nbsp;xchat_get_pluginpref_int()&nbsp;</a><small>(new for 2.8.10)</small></h3>
-<b>Prototype:</b> int xchat_get_pluginpref_int (xchat_plugin *ph, const char *var);
+<h3><a class=cmd name="xchat_pluginpref_get_int">&nbsp;xchat_pluginpref_get_int()&nbsp;</a><small>(new for 2.8.10)</small></h3>
+<b>Prototype:</b> int xchat_pluginpref_get_int (xchat_plugin *ph, const char *var);
 <br>
 <br><b>Description:</b> Loads a plugin-specific setting with decimal value from a plugin-specific config file.
 <br>
@@ -1108,5 +1111,31 @@ You should never need to edit this file manually.
 <b>Returns:</b> The decimal value of the requested setting upon success, -1 for failure.
 <br><br><br>
 
+<h3><a class=cmd name="xchat_pluginpref_delete">&nbsp;xchat_pluginpref_delete()&nbsp;</a><small>(new for 2.8.10)</small></h3>
+<b>Prototype:</b> int xchat_pluginpref_delete (xchat_plugin *ph, const char *var);
+<br>
+<br><b>Description:</b> Deletes a plugin-specific setting from a plugin-specific config file.
+<br>
+<br><b>Arguments:</b>
+<blockquote><b>ph:</b> Plugin handle (as given to xchat_plugin_init).
+<br><b>var:</b> Name of the setting to delete.
+<br>
+</blockquote>
+<b>Returns:</b> 1 for success, 0 for failure. If the given setting didn't exist, it also returns 1, so 1 only indicates that the setting won't exist after the call.
+<br><br><br>
+
+<h3><a class=cmd name="xchat_pluginpref_list">&nbsp;xchat_pluginpref_list()&nbsp;</a><small>(new for 2.8.10)</small></h3>
+<b>Prototype:</b> int xchat_pluginpref_list (xchat_plugin *ph, const char *dest);
+<br>
+<br><b>Description:</b> Builds a comma-separated list of the currently saved settings from a plugin-specific config file.
+<br>
+<br><b>Arguments:</b>
+<blockquote><b>ph:</b> Plugin handle (as given to xchat_plugin_init).
+<br><b>dest:</b> Array to save the list to.
+<br>
+</blockquote>
+<b>Returns:</b> 1 for success, 0 for failure.
+<br><br><br>
+
 </body>
 </html>
diff --git a/plugins/xchat-plugin.h b/plugins/xchat-plugin.h
index 373c664e..1b7da8fb 100644
--- a/plugins/xchat-plugin.h
+++ b/plugins/xchat-plugin.h
@@ -137,19 +137,21 @@ struct _xchat_plugin
 	     int flags);
 	void (*xchat_free) (xchat_plugin *ph,
 	    void *ptr);
-	int (*xchat_set_pluginpref_str) (xchat_plugin *ph,
+	int (*xchat_pluginpref_set_str) (xchat_plugin *ph,
 		const char *var,
 		const char *value);
-	int (*xchat_get_pluginpref_str) (xchat_plugin *ph,
+	int (*xchat_pluginpref_get_str) (xchat_plugin *ph,
 		const char *var,
 		char *dest);
-	int (*xchat_set_pluginpref_int) (xchat_plugin *ph,
+	int (*xchat_pluginpref_set_int) (xchat_plugin *ph,
 		const char *var,
 		int value);
-	int (*xchat_get_pluginpref_int) (xchat_plugin *ph,
+	int (*xchat_pluginpref_get_int) (xchat_plugin *ph,
 		const char *var);
-	int (*xchat_del_pluginpref) (xchat_plugin *ph,
+	int (*xchat_pluginpref_delete) (xchat_plugin *ph,
 		const char *var);
+	int (*xchat_pluginpref_list) (xchat_plugin *ph,
+		char *dest);
 };
 #endif
 
@@ -306,27 +308,31 @@ xchat_free (xchat_plugin *ph,
 	    void *ptr);
 
 int
-xchat_set_pluginpref_str (xchat_plugin *ph,
+xchat_pluginpref_set_str (xchat_plugin *ph,
 		const char *var,
 		const char *value);
 
 int
-xchat_get_pluginpref_str (xchat_plugin *ph,
+xchat_pluginpref_get_str (xchat_plugin *ph,
 		const char *var,
 		char *dest);
 
 int
-xchat_set_pluginpref_int (xchat_plugin *ph,
+xchat_pluginpref_set_int (xchat_plugin *ph,
 		const char *var,
 		int value);
 int
-xchat_get_pluginpref_int (xchat_plugin *ph,
+xchat_pluginpref_get_int (xchat_plugin *ph,
 		const char *var);
 
 int
-xchat_del_pluginpref (xchat_plugin *ph,
+xchat_pluginpref_delete (xchat_plugin *ph,
 		const char *var);
 
+int
+xchat_pluginpref_list (xchat_plugin *ph,
+		char *dest);
+
 #if !defined(PLUGIN_C) && defined(WIN32)
 #ifndef XCHAT_PLUGIN_HANDLE
 #define XCHAT_PLUGIN_HANDLE (ph)
@@ -361,11 +367,12 @@ xchat_del_pluginpref (xchat_plugin *ph,
 #define xchat_send_modes ((XCHAT_PLUGIN_HANDLE)->xchat_send_modes)
 #define xchat_strip ((XCHAT_PLUGIN_HANDLE)->xchat_strip)
 #define xchat_free ((XCHAT_PLUGIN_HANDLE)->xchat_free)
-#define xchat_set_pluginpref_str ((XCHAT_PLUGIN_HANDLE)->xchat_set_pluginpref_str)
-#define xchat_get_pluginpref_str ((XCHAT_PLUGIN_HANDLE)->xchat_get_pluginpref_str)
-#define xchat_set_pluginpref_int ((XCHAT_PLUGIN_HANDLE)->xchat_set_pluginpref_int)
-#define xchat_get_pluginpref_int ((XCHAT_PLUGIN_HANDLE)->xchat_get_pluginpref_int)
-#define xchat_del_pluginpref ((XCHAT_PLUGIN_HANDLE)->xchat_del_pluginpref)
+#define xchat_pluginpref_set_str ((XCHAT_PLUGIN_HANDLE)->xchat_pluginpref_set_str)
+#define xchat_pluginpref_get_str ((XCHAT_PLUGIN_HANDLE)->xchat_pluginpref_get_str)
+#define xchat_pluginpref_set_int ((XCHAT_PLUGIN_HANDLE)->xchat_pluginpref_set_int)
+#define xchat_pluginpref_get_int ((XCHAT_PLUGIN_HANDLE)->xchat_pluginpref_get_int)
+#define xchat_pluginpref_delete ((XCHAT_PLUGIN_HANDLE)->xchat_pluginpref_delete)
+#define xchat_pluginpref_list ((XCHAT_PLUGIN_HANDLE)->xchat_pluginpref_list)
 #endif
 
 #ifdef __cplusplus
diff --git a/src/common/plugin.c b/src/common/plugin.c
index b08143e0..cff8d49b 100644
--- a/src/common/plugin.c
+++ b/src/common/plugin.c
@@ -270,11 +270,12 @@ plugin_add (session *sess, char *filename, void *handle, void *init_func,
 		pl->xchat_send_modes = xchat_send_modes;
 		pl->xchat_strip = xchat_strip;
 		pl->xchat_free = xchat_free;
-		pl->xchat_set_pluginpref_str = xchat_set_pluginpref_str;
-		pl->xchat_get_pluginpref_str = xchat_get_pluginpref_str;
-		pl->xchat_set_pluginpref_int = xchat_set_pluginpref_int;
-		pl->xchat_get_pluginpref_int = xchat_get_pluginpref_int;
-		pl->xchat_del_pluginpref = xchat_del_pluginpref;
+		pl->xchat_pluginpref_set_str = xchat_pluginpref_set_str;
+		pl->xchat_pluginpref_get_str = xchat_pluginpref_get_str;
+		pl->xchat_pluginpref_set_int = xchat_pluginpref_set_int;
+		pl->xchat_pluginpref_get_int = xchat_pluginpref_get_int;
+		pl->xchat_pluginpref_delete = xchat_pluginpref_delete;
+		pl->xchat_pluginpref_list = xchat_pluginpref_list;
 
 		/* incase new plugins are loaded on older xchat */
 		pl->xchat_dummy4 = xchat_dummy;
@@ -1589,7 +1590,7 @@ xchat_free (xchat_plugin *ph, void *ptr)
 }
 
 static int
-xchat_set_pluginpref_str_real (xchat_plugin *pl, const char *var, const char *value, int mode) /* mode: 0 = delete, 1 = save */
+xchat_pluginpref_set_str_real (xchat_plugin *pl, const char *var, const char *value, int mode) /* mode: 0 = delete, 1 = save */
 {
 	FILE *fpIn;
 	int fhOut;
@@ -1702,13 +1703,13 @@ xchat_set_pluginpref_str_real (xchat_plugin *pl, const char *var, const char *va
 }
 
 int
-xchat_set_pluginpref_str (xchat_plugin *pl, const char *var, const char *value)
+xchat_pluginpref_set_str (xchat_plugin *pl, const char *var, const char *value)
 {
-	return xchat_set_pluginpref_str_real (pl, var, value, 1);
+	return xchat_pluginpref_set_str_real (pl, var, value, 1);
 }
 
 int
-xchat_get_pluginpref_str (xchat_plugin *pl, const char *var, char *dest)
+xchat_pluginpref_get_str (xchat_plugin *pl, const char *var, char *dest)
 {
 	int fh;
 	int l;
@@ -1760,20 +1761,20 @@ xchat_get_pluginpref_str (xchat_plugin *pl, const char *var, char *dest)
 }
 
 int
-xchat_set_pluginpref_int (xchat_plugin *pl, const char *var, int value)
+xchat_pluginpref_set_int (xchat_plugin *pl, const char *var, int value)
 {
 	char buffer[12];
 
 	sprintf (buffer, "%d", value);
-	return xchat_set_pluginpref_str_real (pl, var, buffer, 1);
+	return xchat_pluginpref_set_str_real (pl, var, buffer, 1);
 }
 
 int
-xchat_get_pluginpref_int (xchat_plugin *pl, const char *var)
+xchat_pluginpref_get_int (xchat_plugin *pl, const char *var)
 {
 	char buffer[12];
 
-	if (xchat_get_pluginpref_str (pl, var, buffer))
+	if (xchat_pluginpref_get_str (pl, var, buffer))
 	{
 		return atoi (buffer);
 	}
@@ -1784,7 +1785,13 @@ xchat_get_pluginpref_int (xchat_plugin *pl, const char *var)
 }
 
 int
-xchat_del_pluginpref (xchat_plugin *pl, const char *var)
+xchat_pluginpref_delete (xchat_plugin *pl, const char *var)
 {
-	return xchat_set_pluginpref_str_real (pl, var, 0, 0);
+	return xchat_pluginpref_set_str_real (pl, var, 0, 0);
 }
+
+int
+xchat_pluginpref_list (char* dest)
+{
+	return 0;
+}
\ No newline at end of file
diff --git a/src/common/plugin.h b/src/common/plugin.h
index bb86f0a3..8c347d51 100644
--- a/src/common/plugin.h
+++ b/src/common/plugin.h
@@ -98,19 +98,21 @@ struct _xchat_plugin
 	     int flags);
 	void (*xchat_free) (xchat_plugin *ph,
 	    void *ptr);
-	int (*xchat_set_pluginpref_str) (xchat_plugin *ph,
+	int (*xchat_pluginpref_set_str) (xchat_plugin *ph,
 		const char *var,
 		const char *value);
-	int (*xchat_get_pluginpref_str) (xchat_plugin *ph,
+	int (*xchat_pluginpref_get_str) (xchat_plugin *ph,
 		const char *var,
 		char *dest);
-	int (*xchat_set_pluginpref_int) (xchat_plugin *ph,
+	int (*xchat_pluginpref_set_int) (xchat_plugin *ph,
 		const char *var,
 		int value);
-	int (*xchat_get_pluginpref_int) (xchat_plugin *ph,
+	int (*xchat_pluginpref_get_int) (xchat_plugin *ph,
 		const char *var);
-	int (*xchat_del_pluginpref) (xchat_plugin *ph,
+	int (*xchat_pluginpref_delete) (xchat_plugin *ph,
 		const char *var);
+	int (*xchat_pluginpref_list) (xchat_plugin *ph,
+		char *dest);
 	void *(*xchat_dummy4) (xchat_plugin *ph);
 	void *(*xchat_dummy3) (xchat_plugin *ph);
 	void *(*xchat_dummy2) (xchat_plugin *ph);
diff --git a/src/common/xchat-plugin.h b/src/common/xchat-plugin.h
index 373c664e..1b7da8fb 100644
--- a/src/common/xchat-plugin.h
+++ b/src/common/xchat-plugin.h
@@ -137,19 +137,21 @@ struct _xchat_plugin
 	     int flags);
 	void (*xchat_free) (xchat_plugin *ph,
 	    void *ptr);
-	int (*xchat_set_pluginpref_str) (xchat_plugin *ph,
+	int (*xchat_pluginpref_set_str) (xchat_plugin *ph,
 		const char *var,
 		const char *value);
-	int (*xchat_get_pluginpref_str) (xchat_plugin *ph,
+	int (*xchat_pluginpref_get_str) (xchat_plugin *ph,
 		const char *var,
 		char *dest);
-	int (*xchat_set_pluginpref_int) (xchat_plugin *ph,
+	int (*xchat_pluginpref_set_int) (xchat_plugin *ph,
 		const char *var,
 		int value);
-	int (*xchat_get_pluginpref_int) (xchat_plugin *ph,
+	int (*xchat_pluginpref_get_int) (xchat_plugin *ph,
 		const char *var);
-	int (*xchat_del_pluginpref) (xchat_plugin *ph,
+	int (*xchat_pluginpref_delete) (xchat_plugin *ph,
 		const char *var);
+	int (*xchat_pluginpref_list) (xchat_plugin *ph,
+		char *dest);
 };
 #endif
 
@@ -306,27 +308,31 @@ xchat_free (xchat_plugin *ph,
 	    void *ptr);
 
 int
-xchat_set_pluginpref_str (xchat_plugin *ph,
+xchat_pluginpref_set_str (xchat_plugin *ph,
 		const char *var,
 		const char *value);
 
 int
-xchat_get_pluginpref_str (xchat_plugin *ph,
+xchat_pluginpref_get_str (xchat_plugin *ph,
 		const char *var,
 		char *dest);
 
 int
-xchat_set_pluginpref_int (xchat_plugin *ph,
+xchat_pluginpref_set_int (xchat_plugin *ph,
 		const char *var,
 		int value);
 int
-xchat_get_pluginpref_int (xchat_plugin *ph,
+xchat_pluginpref_get_int (xchat_plugin *ph,
 		const char *var);
 
 int
-xchat_del_pluginpref (xchat_plugin *ph,
+xchat_pluginpref_delete (xchat_plugin *ph,
 		const char *var);
 
+int
+xchat_pluginpref_list (xchat_plugin *ph,
+		char *dest);
+
 #if !defined(PLUGIN_C) && defined(WIN32)
 #ifndef XCHAT_PLUGIN_HANDLE
 #define XCHAT_PLUGIN_HANDLE (ph)
@@ -361,11 +367,12 @@ xchat_del_pluginpref (xchat_plugin *ph,
 #define xchat_send_modes ((XCHAT_PLUGIN_HANDLE)->xchat_send_modes)
 #define xchat_strip ((XCHAT_PLUGIN_HANDLE)->xchat_strip)
 #define xchat_free ((XCHAT_PLUGIN_HANDLE)->xchat_free)
-#define xchat_set_pluginpref_str ((XCHAT_PLUGIN_HANDLE)->xchat_set_pluginpref_str)
-#define xchat_get_pluginpref_str ((XCHAT_PLUGIN_HANDLE)->xchat_get_pluginpref_str)
-#define xchat_set_pluginpref_int ((XCHAT_PLUGIN_HANDLE)->xchat_set_pluginpref_int)
-#define xchat_get_pluginpref_int ((XCHAT_PLUGIN_HANDLE)->xchat_get_pluginpref_int)
-#define xchat_del_pluginpref ((XCHAT_PLUGIN_HANDLE)->xchat_del_pluginpref)
+#define xchat_pluginpref_set_str ((XCHAT_PLUGIN_HANDLE)->xchat_pluginpref_set_str)
+#define xchat_pluginpref_get_str ((XCHAT_PLUGIN_HANDLE)->xchat_pluginpref_get_str)
+#define xchat_pluginpref_set_int ((XCHAT_PLUGIN_HANDLE)->xchat_pluginpref_set_int)
+#define xchat_pluginpref_get_int ((XCHAT_PLUGIN_HANDLE)->xchat_pluginpref_get_int)
+#define xchat_pluginpref_delete ((XCHAT_PLUGIN_HANDLE)->xchat_pluginpref_delete)
+#define xchat_pluginpref_list ((XCHAT_PLUGIN_HANDLE)->xchat_pluginpref_list)
 #endif
 
 #ifdef __cplusplus
diff --git a/src/version-script b/src/version-script
index fe04dd46..4441aeae 100644
--- a/src/version-script
+++ b/src/version-script
@@ -30,10 +30,11 @@ EXPORTED {
 		xchat_send_modes;
 		xchat_strip;
 		xchat_free;
-		xchat_set_pluginpref_str;
-		xchat_get_pluginpref_str;
-		xchat_set_pluginpref_int;
-		xchat_get_pluginpref_int;
-		xchat_del_pluginpref;
+		xchat_pluginpref_set_str;
+		xchat_pluginpref_get_str;
+		xchat_pluginpref_set_int;
+		xchat_pluginpref_get_int;
+		xchat_pluginpref_delete;
+		xchat_pluginpref_list;
 	local: *;
 };
-- 
cgit 1.4.1


From 44e404838683b9256f60ccd8e3370a39e27c6b58 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sun, 15 Jan 2012 19:10:31 +0100
Subject: update xsasl according to api changes

---
 plugins/xsasl/xsasl.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

(limited to 'plugins')

diff --git a/plugins/xsasl/xsasl.c b/plugins/xsasl/xsasl.c
index cbf569e2..2b2ec0c7 100644
--- a/plugins/xsasl/xsasl.c
+++ b/plugins/xsasl/xsasl.c
@@ -60,13 +60,13 @@ add_info (char const* login, char const* password, char const* network)
 	char buffer[512];
 
 	sprintf (buffer, "%s:%s", login, password);
-	return xchat_set_pluginpref_str (ph, network, buffer);
+	return xchat_pluginpref_set_str (ph, network, buffer);
 }
 
 static int
 del_info (char const* network)
 {
-	return xchat_del_pluginpref (ph, network);
+	return xchat_pluginpref_delete (ph, network);
 }
 
 static sasl_info*
@@ -76,7 +76,7 @@ find_info (char const* network)
 	char* token;
 	sasl_info* cur = (sasl_info*) malloc (sizeof (sasl_info));
 
-	if (xchat_get_pluginpref_str (ph, network, buffer))
+	if (xchat_pluginpref_get_str (ph, network, buffer))
 	{
 		token = strtok (buffer, ":");
 		cur->login = g_strdup (token);
-- 
cgit 1.4.1


From 306b2a87075cfce4eb13e7821763bf27614c25f4 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sun, 15 Jan 2012 21:15:33 +0100
Subject: implement XSASL LIST

---
 plugins/xsasl/xsasl.c | 30 +++++++++++++++++++++++++++++-
 1 file changed, 29 insertions(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/xsasl/xsasl.c b/plugins/xsasl/xsasl.c
index 2b2ec0c7..43689fd3 100644
--- a/plugins/xsasl/xsasl.c
+++ b/plugins/xsasl/xsasl.c
@@ -43,7 +43,7 @@ static xchat_plugin *ph;   /* plugin handle */
 static const char name[] = "X-SASL";
 static const char desc[] = "SASL authentication plugin for XChat";
 static const char version[] = "1.1";
-static const char xsasl_help[] = "X-SASL Usage:\n /XSASL ADD <login> <password> <network>, enable SASL authentication for given network\n /XSASL DEL <network>, disable SASL authentication for given network\n";
+static const char xsasl_help[] = "X-SASL Usage:\n /XSASL ADD <login> <password> <network>, enable SASL authentication for given network\n /XSASL DEL <network>, disable SASL authentication for given network\n /XSASL LIST, get the list of SASL-enabled networks\n";
 
 struct sasl_info
 {
@@ -69,6 +69,29 @@ del_info (char const* network)
 	return xchat_pluginpref_delete (ph, network);
 }
 
+static void
+print_info ()
+{
+	char list[512];
+	char* token;
+
+	if (xchat_pluginpref_list (ph, list))
+	{
+		xchat_printf (ph, "%s\tSASL-enabled networks:", name);
+		xchat_printf (ph, "%s\t----------------------", name);
+		token = strtok (list, ",");
+		while (token != NULL)
+		{
+			xchat_printf (ph, "%s\t%s", name, token);
+			token = strtok (NULL, ",");
+		}
+	}
+	else
+	{
+		xchat_printf (ph, "%s\tThere are no SASL-enabled networks currently", name);
+	}
+}
+
 static sasl_info*
 find_info (char const* network)
 {
@@ -232,6 +255,11 @@ sasl_cmd_cb (char *word[], char *word_eol[], void *userdata)
 
 		return XCHAT_EAT_ALL;
 	}
+	else if (!stricmp ("LIST", mode))
+	{
+		print_info ();
+		return XCHAT_EAT_ALL;
+	}
 	else
 	{
 		xchat_printf (ph, "%s", xsasl_help);
-- 
cgit 1.4.1


From 3e93c323922ef073b2db9c61e5f04f4bc3db0637 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sun, 15 Jan 2012 21:24:56 +0100
Subject: additional hints about xchat_pluginpref_list return value

---
 plugins/plugin20.html | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/plugin20.html b/plugins/plugin20.html
index 6323cd80..32b479a7 100644
--- a/plugins/plugin20.html
+++ b/plugins/plugin20.html
@@ -1134,7 +1134,7 @@ You only need these kind of complex checks if you're saving user input, which ca
 <br><b>dest:</b> Array to save the list to.
 <br>
 </blockquote>
-<b>Returns:</b> 1 for success, 0 for failure.
+<b>Returns:</b> 1 for success, 0 for failure (nonexistent, empty or inaccessible config file).
 <br><br><br>
 
 </body>
-- 
cgit 1.4.1


From 70771ba2c60ee56b85ad84a09ed3cfcc8f5e40c9 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sun, 15 Jan 2012 21:41:45 +0100
Subject: add info about xsasl add replacing existing config

---
 plugins/xsasl/xsasl.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/xsasl/xsasl.c b/plugins/xsasl/xsasl.c
index 43689fd3..8abce20b 100644
--- a/plugins/xsasl/xsasl.c
+++ b/plugins/xsasl/xsasl.c
@@ -43,7 +43,7 @@ static xchat_plugin *ph;   /* plugin handle */
 static const char name[] = "X-SASL";
 static const char desc[] = "SASL authentication plugin for XChat";
 static const char version[] = "1.1";
-static const char xsasl_help[] = "X-SASL Usage:\n /XSASL ADD <login> <password> <network>, enable SASL authentication for given network\n /XSASL DEL <network>, disable SASL authentication for given network\n /XSASL LIST, get the list of SASL-enabled networks\n";
+static const char xsasl_help[] = "X-SASL Usage:\n /XSASL ADD <login> <password> <network>, enable/update SASL authentication for given network\n /XSASL DEL <network>, disable SASL authentication for given network\n /XSASL LIST, get the list of SASL-enabled networks\n";
 
 struct sasl_info
 {
-- 
cgit 1.4.1


From 66e0f75e148110d489d3a5f680e620fdf45a4451 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sun, 15 Jan 2012 22:31:39 +0100
Subject: fix prototype in plugin docs

---
 plugins/plugin20.html | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/plugin20.html b/plugins/plugin20.html
index 32b479a7..fcdff2ed 100644
--- a/plugins/plugin20.html
+++ b/plugins/plugin20.html
@@ -1125,7 +1125,7 @@ You only need these kind of complex checks if you're saving user input, which ca
 <br><br><br>
 
 <h3><a class=cmd name="xchat_pluginpref_list">&nbsp;xchat_pluginpref_list()&nbsp;</a><small>(new for 2.8.10)</small></h3>
-<b>Prototype:</b> int xchat_pluginpref_list (xchat_plugin *ph, const char *dest);
+<b>Prototype:</b> int xchat_pluginpref_list (xchat_plugin *ph, char *dest);
 <br>
 <br><b>Description:</b> Builds a comma-separated list of the currently saved settings from a plugin-specific config file.
 <br>
-- 
cgit 1.4.1


From 569cb3dbbfb854038f9ebcdb5a5374e1de6ec9c0 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Wed, 18 Jan 2012 09:25:05 +0100
Subject: add Non-BMP plugin against GTK+ exploits

---
 plugins/makefile.mak         |  4 ++
 plugins/nonbmp/makefile.mak  | 18 +++++++++
 plugins/nonbmp/nonbmp.c      | 87 ++++++++++++++++++++++++++++++++++++++++++++
 win32/release-x64.bat        |  1 +
 win32/release-x86.bat        |  1 +
 win32/xchat-wdk-x64.skel.iss |  2 +
 win32/xchat-wdk-x86.skel.iss |  2 +
 7 files changed, 115 insertions(+)
 create mode 100644 plugins/nonbmp/makefile.mak
 create mode 100644 plugins/nonbmp/nonbmp.c

(limited to 'plugins')

diff --git a/plugins/makefile.mak b/plugins/makefile.mak
index b692c41f..6a44e34d 100644
--- a/plugins/makefile.mak
+++ b/plugins/makefile.mak
@@ -13,6 +13,8 @@ all:
 	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\mpcinfo
 	@-$(MAKE) /nologo /s /f makefile.mak $@
+	@cd ..\nonbmp
+	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\python
 	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\tcl
@@ -45,6 +47,8 @@ clean:
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\mpcinfo
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
+	@cd ..\nonbmp
+	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\python
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\tcl
diff --git a/plugins/nonbmp/makefile.mak b/plugins/nonbmp/makefile.mak
new file mode 100644
index 00000000..1c28610d
--- /dev/null
+++ b/plugins/nonbmp/makefile.mak
@@ -0,0 +1,18 @@
+include "..\..\src\makeinc.mak"
+
+all: nonbmp.obj nonbmp.def
+	link $(LDFLAGS) $(LIBS) /dll /out:xcnonbmp.dll /def:nonbmp.def nonbmp.obj
+
+nonbmp.def:
+	echo EXPORTS > nonbmp.def
+	echo xchat_plugin_init >> nonbmp.def
+	echo xchat_plugin_deinit >> nonbmp.def
+
+nonbmp.obj: nonbmp.c makefile.mak
+	cl $(CFLAGS) $(GLIB) /I.. nonbmp.c
+
+clean:
+	del *.obj
+	del *.dll
+	del *.exp
+	del *.lib
diff --git a/plugins/nonbmp/nonbmp.c b/plugins/nonbmp/nonbmp.c
new file mode 100644
index 00000000..fe9571b7
--- /dev/null
+++ b/plugins/nonbmp/nonbmp.c
@@ -0,0 +1,87 @@
+#include <stdlib.h>
+#include <glib.h>
+#include <string.h>
+
+#include "xchat-plugin.h"
+
+static xchat_plugin *ph;
+static const char name[] = "Non-BMP";
+static const char desc[] = "Replace non-BMP characters with replacment characters";
+static const char version[] = "1.0000";
+static int recursing = 0;
+
+static int filter(
+	char *word[],
+	char *word_eol[],
+	void *unused
+) {
+	gunichar *line;
+	gchar *utf8_line;
+	glong length;
+	glong index;
+
+	if( recursing ) {
+		return XCHAT_EAT_NONE;
+	}
+
+	/* the input has already been checked so we can use the _fast version */
+	line = g_utf8_to_ucs4_fast(
+		(char *)word_eol[1],
+		-1, /* NUL terminated input */
+		&length
+	);
+	
+	for( index = 0; index < length; index++ ) {
+		if( line[ index ] > 0xFFFF ) {
+			line[ index ] = 0xFFFD; /* replacement character */
+		}
+	}
+
+	utf8_line = g_ucs4_to_utf8(
+		line,
+		-1, /* NUL terminated input */
+		NULL, /* items read */
+		NULL, /* items written */
+		NULL  /* ignore conversion error */
+	);
+
+	if( utf8_line == NULL ) {
+		/* conversion failed ... I guess we are screwed? */
+		g_free( line );
+		return XCHAT_EAT_NONE;
+	}
+
+	recursing = 1;
+	xchat_commandf( ph, "RECV %s", utf8_line );
+	recursing = 0;
+
+	g_free( line );
+	g_free( utf8_line );
+	return XCHAT_EAT_ALL;
+}
+
+int xchat_plugin_init(
+	xchat_plugin *plugin_handle,
+	char **plugin_name,
+	char **plugin_desc,
+	char **plugin_version,
+	char *arg 
+) {
+/*	int index = 0;*/
+
+	ph = plugin_handle;
+	*plugin_name = name;
+	*plugin_desc = desc;
+	*plugin_version = version;
+
+	xchat_hook_server( ph, "RAW LINE", XCHAT_PRI_HIGHEST, filter, (void *)NULL );
+	xchat_printf (ph, "%s plugin loaded\n", name);
+	return 1;
+}
+
+int
+xchat_plugin_deinit (void)
+{
+	xchat_printf (ph, "%s plugin unloaded\n", name);
+	return 1;
+}
\ No newline at end of file
diff --git a/win32/release-x64.bat b/win32/release-x64.bat
index 9e092a2b..9cf634a5 100644
--- a/win32/release-x64.bat
+++ b/win32/release-x64.bat
@@ -62,6 +62,7 @@ copy ..\plugins\fishlim\xcfishlim.dll %XCHAT_DEST%\plugins
 copy ..\plugins\lua\xclua.dll %XCHAT_DEST%\plugins
 ::obs copy ..\plugins\gtkpref\xcgtkpref.dll %XCHAT_DEST%\plugins
 copy ..\plugins\mpcinfo\xcmpcinfo.dll %XCHAT_DEST%\plugins
+copy ..\plugins\nonbmp\xcnonbmp.dll %XCHAT_DEST%\plugins
 copy ..\plugins\perl\xcperl-512.dll %XCHAT_DEST%\plugins
 copy ..\plugins\perl\xcperl-514.dll %XCHAT_DEST%\plugins
 copy ..\plugins\python\xcpython.dll %XCHAT_DEST%\plugins
diff --git a/win32/release-x86.bat b/win32/release-x86.bat
index bf0a8db6..05419beb 100644
--- a/win32/release-x86.bat
+++ b/win32/release-x86.bat
@@ -64,6 +64,7 @@ copy ..\plugins\fishlim\xcfishlim.dll %XCHAT_DEST%\plugins
 copy ..\plugins\lua\xclua.dll %XCHAT_DEST%\plugins
 ::obs copy ..\plugins\gtkpref\xcgtkpref.dll %XCHAT_DEST%\plugins
 copy ..\plugins\mpcinfo\xcmpcinfo.dll %XCHAT_DEST%\plugins
+copy ..\plugins\nonbmp\xcnonbmp.dll %XCHAT_DEST%\plugins
 copy ..\plugins\perl\xcperl-512.dll %XCHAT_DEST%\plugins
 copy ..\plugins\perl\xcperl-514.dll %XCHAT_DEST%\plugins
 copy ..\plugins\python\xcpython.dll %XCHAT_DEST%\plugins
diff --git a/win32/xchat-wdk-x64.skel.iss b/win32/xchat-wdk-x64.skel.iss
index 815bdd48..12fa3667 100644
--- a/win32/xchat-wdk-x64.skel.iss
+++ b/win32/xchat-wdk-x64.skel.iss
@@ -39,6 +39,7 @@ Name: "plugins\doat"; Description: "Do At"; Types: full custom; Flags: disableno
 Name: "plugins\exec"; Description: "Exec"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\fishlim"; Description: "FiSHLiM"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\mpcinfo"; Description: "mpcInfo"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\nonbmp"; Description: "Non-BMP"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\upd"; Description: "Update Checker"; Types: normal full custom; Flags: disablenouninstallwarning
 Name: "plugins\winamp"; Description: "Winamp"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\winsys"; Description: "WinSys"; Types: full custom; Flags: disablenouninstallwarning
@@ -154,6 +155,7 @@ Source: "plugins\xcexec.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Co
 Source: "plugins\xcfishlim.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\fishlim
 Source: "etc\music.png"; DestDir: "{app}\etc"; Flags: ignoreversion; Components: plugins\winamp or plugins\mpcinfo
 Source: "plugins\xcmpcinfo.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\mpcinfo
+Source: "plugins\xcnonbmp.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\nonbmp
 Source: "etc\download.png"; DestDir: "{app}\etc"; Flags: ignoreversion; Components: plugins\upd
 Source: "plugins\xcupd.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\upd
 Source: "plugins\xcwinamp.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\winamp
diff --git a/win32/xchat-wdk-x86.skel.iss b/win32/xchat-wdk-x86.skel.iss
index 2bc7969f..2bef323f 100644
--- a/win32/xchat-wdk-x86.skel.iss
+++ b/win32/xchat-wdk-x86.skel.iss
@@ -38,6 +38,7 @@ Name: "plugins\doat"; Description: "Do At"; Types: full custom; Flags: disableno
 Name: "plugins\exec"; Description: "Exec"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\fishlim"; Description: "FiSHLiM"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\mpcinfo"; Description: "mpcInfo"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\nonbmp"; Description: "Non-BMP"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\upd"; Description: "Update Checker"; Types: normal full custom; Flags: disablenouninstallwarning
 Name: "plugins\winamp"; Description: "Winamp"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\winsys"; Description: "WinSys"; Types: full custom; Flags: disablenouninstallwarning
@@ -155,6 +156,7 @@ Source: "plugins\xcexec.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Co
 Source: "plugins\xcfishlim.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\fishlim
 Source: "etc\music.png"; DestDir: "{app}\etc"; Flags: ignoreversion; Components: plugins\winamp or plugins\mpcinfo
 Source: "plugins\xcmpcinfo.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\mpcinfo
+Source: "plugins\xcnonbmp.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\nonbmp
 Source: "etc\download.png"; DestDir: "{app}\etc"; Flags: ignoreversion; Components: plugins\upd
 Source: "plugins\xcupd.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\upd
 Source: "plugins\xcwinamp.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\winamp
-- 
cgit 1.4.1


From 405a2965e0e256d80d93b7325a9dcc6c5fd1ecd4 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Wed, 18 Jan 2012 09:47:08 +0100
Subject: typofix

---
 plugins/nonbmp/nonbmp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/nonbmp/nonbmp.c b/plugins/nonbmp/nonbmp.c
index fe9571b7..824c395e 100644
--- a/plugins/nonbmp/nonbmp.c
+++ b/plugins/nonbmp/nonbmp.c
@@ -6,7 +6,7 @@
 
 static xchat_plugin *ph;
 static const char name[] = "Non-BMP";
-static const char desc[] = "Replace non-BMP characters with replacment characters";
+static const char desc[] = "Replace non-BMP characters with replacement characters";
 static const char version[] = "1.0000";
 static int recursing = 0;
 
-- 
cgit 1.4.1


From bddd5b3a06f1d6254e2436992780b5d0479f27b1 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Fri, 20 Jan 2012 01:33:55 +0100
Subject: disable the non-bmp plugin

---
 plugins/makefile.mak         | 8 ++++----
 win32/release-x64.bat        | 2 +-
 win32/release-x86.bat        | 2 +-
 win32/xchat-wdk-x64.skel.iss | 4 ++--
 win32/xchat-wdk-x86.skel.iss | 4 ++--
 5 files changed, 10 insertions(+), 10 deletions(-)

(limited to 'plugins')

diff --git a/plugins/makefile.mak b/plugins/makefile.mak
index 6a44e34d..07205ab4 100644
--- a/plugins/makefile.mak
+++ b/plugins/makefile.mak
@@ -13,8 +13,8 @@ all:
 	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\mpcinfo
 	@-$(MAKE) /nologo /s /f makefile.mak $@
-	@cd ..\nonbmp
-	@-$(MAKE) /nologo /s /f makefile.mak $@
+#	@cd ..\nonbmp
+#	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\python
 	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\tcl
@@ -47,8 +47,8 @@ clean:
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\mpcinfo
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
-	@cd ..\nonbmp
-	@-$(MAKE) /nologo /s /f makefile.mak clean $@
+#	@cd ..\nonbmp
+#	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\python
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\tcl
diff --git a/win32/release-x64.bat b/win32/release-x64.bat
index 9cf634a5..1b3c2586 100644
--- a/win32/release-x64.bat
+++ b/win32/release-x64.bat
@@ -62,7 +62,7 @@ copy ..\plugins\fishlim\xcfishlim.dll %XCHAT_DEST%\plugins
 copy ..\plugins\lua\xclua.dll %XCHAT_DEST%\plugins
 ::obs copy ..\plugins\gtkpref\xcgtkpref.dll %XCHAT_DEST%\plugins
 copy ..\plugins\mpcinfo\xcmpcinfo.dll %XCHAT_DEST%\plugins
-copy ..\plugins\nonbmp\xcnonbmp.dll %XCHAT_DEST%\plugins
+::copy ..\plugins\nonbmp\xcnonbmp.dll %XCHAT_DEST%\plugins
 copy ..\plugins\perl\xcperl-512.dll %XCHAT_DEST%\plugins
 copy ..\plugins\perl\xcperl-514.dll %XCHAT_DEST%\plugins
 copy ..\plugins\python\xcpython.dll %XCHAT_DEST%\plugins
diff --git a/win32/release-x86.bat b/win32/release-x86.bat
index 05419beb..4583add6 100644
--- a/win32/release-x86.bat
+++ b/win32/release-x86.bat
@@ -64,7 +64,7 @@ copy ..\plugins\fishlim\xcfishlim.dll %XCHAT_DEST%\plugins
 copy ..\plugins\lua\xclua.dll %XCHAT_DEST%\plugins
 ::obs copy ..\plugins\gtkpref\xcgtkpref.dll %XCHAT_DEST%\plugins
 copy ..\plugins\mpcinfo\xcmpcinfo.dll %XCHAT_DEST%\plugins
-copy ..\plugins\nonbmp\xcnonbmp.dll %XCHAT_DEST%\plugins
+::copy ..\plugins\nonbmp\xcnonbmp.dll %XCHAT_DEST%\plugins
 copy ..\plugins\perl\xcperl-512.dll %XCHAT_DEST%\plugins
 copy ..\plugins\perl\xcperl-514.dll %XCHAT_DEST%\plugins
 copy ..\plugins\python\xcpython.dll %XCHAT_DEST%\plugins
diff --git a/win32/xchat-wdk-x64.skel.iss b/win32/xchat-wdk-x64.skel.iss
index 75d2ec17..955eeb42 100644
--- a/win32/xchat-wdk-x64.skel.iss
+++ b/win32/xchat-wdk-x64.skel.iss
@@ -39,7 +39,7 @@ Name: "plugins\doat"; Description: "Do At"; Types: full custom; Flags: disableno
 Name: "plugins\exec"; Description: "Exec"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\fishlim"; Description: "FiSHLiM"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\mpcinfo"; Description: "mpcInfo"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\nonbmp"; Description: "Non-BMP"; Types: normal full custom; Flags: disablenouninstallwarning
+;Name: "plugins\nonbmp"; Description: "Non-BMP"; Types: normal full custom; Flags: disablenouninstallwarning
 Name: "plugins\upd"; Description: "Update Checker"; Types: normal full custom; Flags: disablenouninstallwarning
 Name: "plugins\winamp"; Description: "Winamp"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\winsys"; Description: "WinSys"; Types: full custom; Flags: disablenouninstallwarning
@@ -155,7 +155,7 @@ Source: "plugins\xcexec.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Co
 Source: "plugins\xcfishlim.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\fishlim
 Source: "etc\music.png"; DestDir: "{app}\etc"; Flags: ignoreversion; Components: plugins\winamp or plugins\mpcinfo
 Source: "plugins\xcmpcinfo.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\mpcinfo
-Source: "plugins\xcnonbmp.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\nonbmp
+;Source: "plugins\xcnonbmp.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\nonbmp
 Source: "etc\download.png"; DestDir: "{app}\etc"; Flags: ignoreversion; Components: plugins\upd
 Source: "plugins\xcupd.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\upd
 Source: "plugins\xcwinamp.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\winamp
diff --git a/win32/xchat-wdk-x86.skel.iss b/win32/xchat-wdk-x86.skel.iss
index deeaf970..dbc75f80 100644
--- a/win32/xchat-wdk-x86.skel.iss
+++ b/win32/xchat-wdk-x86.skel.iss
@@ -38,7 +38,7 @@ Name: "plugins\doat"; Description: "Do At"; Types: full custom; Flags: disableno
 Name: "plugins\exec"; Description: "Exec"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\fishlim"; Description: "FiSHLiM"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\mpcinfo"; Description: "mpcInfo"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\nonbmp"; Description: "Non-BMP"; Types: normal full custom; Flags: disablenouninstallwarning
+;Name: "plugins\nonbmp"; Description: "Non-BMP"; Types: normal full custom; Flags: disablenouninstallwarning
 Name: "plugins\upd"; Description: "Update Checker"; Types: normal full custom; Flags: disablenouninstallwarning
 Name: "plugins\winamp"; Description: "Winamp"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\winsys"; Description: "WinSys"; Types: full custom; Flags: disablenouninstallwarning
@@ -156,7 +156,7 @@ Source: "plugins\xcexec.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Co
 Source: "plugins\xcfishlim.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\fishlim
 Source: "etc\music.png"; DestDir: "{app}\etc"; Flags: ignoreversion; Components: plugins\winamp or plugins\mpcinfo
 Source: "plugins\xcmpcinfo.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\mpcinfo
-Source: "plugins\xcnonbmp.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\nonbmp
+;Source: "plugins\xcnonbmp.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\nonbmp
 Source: "etc\download.png"; DestDir: "{app}\etc"; Flags: ignoreversion; Components: plugins\upd
 Source: "plugins\xcupd.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\upd
 Source: "plugins\xcwinamp.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\winamp
-- 
cgit 1.4.1


From bfee90f11c9766808a0c7decccc3289d4764019f Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Fri, 20 Jan 2012 05:43:13 +0100
Subject: add DNS plugin

---
 plugins/dns/dns.c            | 329 +++++++++++++++++++++++++++++++++++++++++++
 plugins/dns/makefile.mak     |  22 +++
 plugins/dns/thread.c         |  33 +++++
 plugins/dns/thread.h         |  11 ++
 plugins/makefile.mak         |   4 +
 win32/release-x64.bat        |   1 +
 win32/release-x86.bat        |   1 +
 win32/xchat-wdk-x64.skel.iss |   2 +
 win32/xchat-wdk-x86.skel.iss |   2 +
 9 files changed, 405 insertions(+)
 create mode 100644 plugins/dns/dns.c
 create mode 100644 plugins/dns/makefile.mak
 create mode 100644 plugins/dns/thread.c
 create mode 100644 plugins/dns/thread.h

(limited to 'plugins')

diff --git a/plugins/dns/dns.c b/plugins/dns/dns.c
new file mode 100644
index 00000000..2bf58195
--- /dev/null
+++ b/plugins/dns/dns.c
@@ -0,0 +1,329 @@
+/* XChat Win32 DNS Plugin
+ * Copyright (C) 2003-2004 Peter Zelezny.
+ * Copyright (C) 2012 Berke Viktor.
+ *
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License
+ * along with this program; if not, write to the Free Software
+ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA
+ */
+/*
+ * Requires MS Visual Studio and IPV6 headers to compile (run nmake).
+ * Compiling with gcc (mingw) will fail due to missing gai_strerror.
+ */
+
+#define DNS_VERSION "2.4"
+
+#include <string.h>
+#include <stdio.h>
+#include <stdlib.h>
+#include <fcntl.h>
+
+#define USE_IPV6
+
+#ifdef WIN32
+#ifdef USE_IPV6
+#include <winsock2.h>
+#include <ws2tcpip.h>
+#else
+#include <winsock2.h>
+#endif
+#else
+#include <unistd.h>
+#include <netdb.h>
+#include <sys/socket.h>
+#endif
+
+#include "xchat-plugin.h"
+#include "thread.h"
+
+#define HELP "Usage: DNS <nickname|hostname|numerical address>\n"
+#define HEAD "\0034[DNS]\017\t"
+
+#define PIPE_READ 0
+#define PIPE_WRITE 1
+#define MAX_HOSTNAME 128
+
+static xchat_plugin *ph;
+static thread *active_thread = NULL;
+
+
+static int
+waitline (void *source, char *buf, int bufsize)
+{
+	int i = 0;
+	int len;
+
+	while(1)
+	{
+		len = 1;
+		/* we can't read() here, due to glib's giowin32 */
+		if(ph->xchat_read_fd(ph, source, buf + i, &len) != 0)
+			return -1;
+		if(buf[i] == '\n' || bufsize == i + 1)
+		{
+			buf[i] = 0;
+			return i;
+		}
+		i++;
+	}
+}
+
+static void *
+thread_function (void *ud)
+{
+#ifdef USE_IPV6
+	struct addrinfo *ent;
+	struct addrinfo *cur;
+	struct addrinfo hints;
+#else
+	struct hostent *ent;
+#endif
+	thread *th = ud;
+	int fd = th->pipe_fd[PIPE_WRITE];
+	int ret;
+	char ipstring[MAX_HOSTNAME];
+	char reverse[MAX_HOSTNAME];
+//	int i;
+
+	active_thread = th;
+
+#ifdef USE_IPV6
+	memset (&hints, 0, sizeof (hints));
+	hints.ai_family = PF_UNSPEC; /* support ipv6 and ipv4 */
+	hints.ai_flags = AI_CANONNAME;
+//	hints.ai_socktype = SOCK_STREAM;
+
+	ret = getaddrinfo (th->userdata, NULL, &hints, &ent);
+	if (ret != 0)
+	{
+		sprintf (ipstring, "1%d\n", ret);	/* failed */
+		write (fd, ipstring, strlen (ipstring));
+//		Sleep (3000);
+		active_thread = NULL;
+		return 0;
+	}
+
+//	i = 0;
+	cur = ent;
+	while (cur)
+	{
+		/* find the numeric IP number */
+		ipstring[0] = 0;
+		getnameinfo (cur->ai_addr, cur->ai_addrlen,
+						 ipstring, sizeof (ipstring), NULL, 0, NI_NUMERICHOST);
+
+		if (cur->ai_canonname)
+		{
+			/* force reverse lookup if canonname & ipstring are the same */
+			if (/*i == 0 &&*/ strcmp (cur->ai_canonname, ipstring) == 0)
+				goto lamecode;
+		}
+
+		if (cur->ai_canonname)
+		{
+			write (fd, "0", 1);
+			write (fd, ipstring, strlen (ipstring));
+			write (fd, "\n", 1);
+			write (fd, cur->ai_canonname, strlen (cur->ai_canonname));
+		} else
+		{
+lamecode:
+	//		ret = 1;
+	//		if (i == 0)
+			{
+				/* reverse lookup */
+				reverse[0] = 0;
+				ret = getnameinfo (cur->ai_addr, cur->ai_addrlen,
+							 reverse, sizeof (reverse), NULL, 0, NI_NAMEREQD);
+			}
+
+			write (fd, "0", 1);
+			write (fd, ipstring, strlen (ipstring));
+
+			write (fd, "\n", 1);
+			if (ret == 0)
+				write (fd, reverse, strlen (reverse));
+		}
+		write (fd, "\n", 1);
+
+//		i++;
+		cur = cur->ai_next;
+	}
+
+	/* tell the parent we're done */
+	write (fd, "2\n", 2);
+	freeaddrinfo (ent);
+
+#else
+	ent = gethostbyname (th->userdata);
+	if (ent)
+	{
+		write (fd, "0", 1);
+		write (fd, ent->h_name, strlen (ent->h_name));
+		write (fd, "\n", 1);
+		write (fd, ent->h_name, strlen (ent->h_name));
+		write (fd, "\n", 1);
+		write (fd, "2\n", 2);
+	} else
+	{
+		write (fd, "10\n", 1);
+	}
+#endif
+
+//	Sleep (3000);
+	active_thread = NULL;	/* race condition, better than nothing */
+
+	return 0;
+}
+
+static int
+dns_close_pipe (int fd)
+{
+	close (fd);
+	return 0;
+}
+
+/* read messages comming from the child (through the pipe) */
+
+static int
+dns_read_cb (int fd, int flags, thread *th, void *source)
+{
+	char buf[512];
+	char buf2[512];
+
+	while (waitline (source, buf, sizeof (buf)))
+	{
+		switch (buf[0])
+		{
+		case '0':		/* got data to show */
+			waitline (source, buf2, sizeof (buf2));
+			if (buf2[0] == 0)
+				xchat_printf(ph, HEAD"\002Numerical\002: %s\n", buf + 1);
+			else
+				xchat_printf(ph, HEAD"\002Canonical\002: %s \002Numerical\002: %s\n", buf2, buf + 1);
+			return 1;
+
+		case '1':		/* failed */
+			xchat_printf(ph, HEAD"Lookup failed. %s\n", gai_strerrorA (atoi (buf + 1)));
+
+		case '2':		/* done */
+		//	close (th->pipe_fd[PIPE_WRITE]);
+		//	close (th->pipe_fd[PIPE_READ]);
+			xchat_hook_timer(ph, 3000, dns_close_pipe, (void *)th->pipe_fd[PIPE_WRITE]);
+			xchat_hook_timer(ph, 4000, dns_close_pipe, (void *)th->pipe_fd[PIPE_READ]);
+			free (th->userdata); 	/* hostname strdup'ed */
+			free (th);
+			return 0;
+		}
+	}
+
+	return 1;
+}
+
+/* find hostname from nickname (search the userlist, current chan only) */
+
+static char *
+find_nick_host (char *nick)
+{
+	xchat_list *list;
+	char *at;
+	const char *host;
+
+	list = xchat_list_get (ph, "users");
+	if (!list)
+		return NULL;
+
+	while (xchat_list_next (ph, list))
+	{
+		if (stricmp (nick, xchat_list_str (ph, list, "nick")) == 0)
+		{
+			host = xchat_list_str (ph, list, "host");
+			if (host)
+			{
+				at = strrchr (host, '@');
+				if (at)
+					return at + 1;
+			}
+			break;
+		}
+	}
+
+	return NULL;
+}
+
+static int
+dns_cmd_cb (char *word[], char *word_eol[], void *ud)
+{
+	thread *th;
+	char *nickhost;
+
+	if (!word[2][0])
+	{
+		xchat_print (ph, HELP);
+		return XCHAT_EAT_ALL;
+	}
+
+	th = thread_new ();
+	if (th)
+	{
+		nickhost = find_nick_host (word[2]);
+		if (nickhost)
+		{
+			xchat_printf (ph, HEAD"Looking up %s (%s)...\n", nickhost, word[2]);
+			th->userdata = strdup (nickhost);
+		} else
+		{
+			xchat_printf (ph, HEAD"Looking up %s...\n", word[2]);
+			th->userdata = strdup (word[2]);
+		}
+
+		if (thread_start (th, thread_function, th))
+		{
+			xchat_hook_fd(ph, th->pipe_fd[PIPE_READ],
+							XCHAT_FD_READ | XCHAT_FD_EXCEPTION | XCHAT_FD_NOTSOCKET,
+							(void *)dns_read_cb, th);
+
+		}
+	}
+
+	return XCHAT_EAT_ALL;
+}
+
+int
+xchat_plugin_deinit (xchat_plugin *plugin_handle)
+{
+	while (active_thread)	/* children will set this var to NULL soon... */
+	{
+		Sleep (1000);
+	}
+	xchat_printf (ph, "DNS plugin unloaded\n");
+	return 1;
+}
+
+int
+xchat_plugin_init
+				(xchat_plugin *plugin_handle, char **plugin_name,
+				char **plugin_desc, char **plugin_version, char *arg)
+{
+	/* we need to save this for use with any xchat_* functions */
+	ph = plugin_handle;
+
+	*plugin_name = "DNS";
+	*plugin_desc = "Threaded IPv4/6 DNS Command";
+	*plugin_version = DNS_VERSION;
+
+	xchat_hook_command(ph, "DNS", XCHAT_PRI_LOW, dns_cmd_cb, HELP, 0);
+	xchat_printf (ph, "DNS plugin loaded\n");
+
+	return 1;       /* return 1 for success */
+}
diff --git a/plugins/dns/makefile.mak b/plugins/dns/makefile.mak
new file mode 100644
index 00000000..384e6be1
--- /dev/null
+++ b/plugins/dns/makefile.mak
@@ -0,0 +1,22 @@
+include "..\..\src\makeinc.mak"
+
+DNS_OBJECTS = \
+dns.obj \
+thread.obj
+
+all: $(DNS_OBJECTS) dns.def
+	link $(LDFLAGS) $(LIBS) /dll /out:xcdns.dll /def:dns.def $(DNS_OBJECTS)
+
+dns.def:
+	echo EXPORTS > dns.def
+	echo xchat_plugin_init >> dns.def
+	echo xchat_plugin_deinit >> dns.def
+
+.c.obj:
+	$(CC) $(CFLAGS) $(GLIB) /I.. /c $<
+
+clean:
+	del *.obj
+	del *.dll
+	del *.exp
+	del *.lib
diff --git a/plugins/dns/thread.c b/plugins/dns/thread.c
new file mode 100644
index 00000000..02b17cfb
--- /dev/null
+++ b/plugins/dns/thread.c
@@ -0,0 +1,33 @@
+#include <fcntl.h>
+#include "thread.h"
+
+thread *
+thread_new (void)
+{
+	thread *th;
+
+	th = calloc (1, sizeof (*th));
+	if (!th)
+	{
+		return NULL;
+	}
+
+	if (_pipe (th->pipe_fd, 4096, _O_BINARY) == -1)
+	{
+		free (th);
+		return NULL;
+	}
+
+	return th;
+}
+
+int
+thread_start (thread *th, void *(*start_routine)(void *), void *arg)
+{
+	DWORD id;
+
+	CloseHandle (CreateThread (NULL, 0, (LPTHREAD_START_ROUTINE)start_routine, arg, 0, (DWORD *)&id));
+	th->threadid = id;
+
+	return 1;
+}
diff --git a/plugins/dns/thread.h b/plugins/dns/thread.h
new file mode 100644
index 00000000..1ec6932d
--- /dev/null
+++ b/plugins/dns/thread.h
@@ -0,0 +1,11 @@
+#include <windows.h>
+
+typedef struct
+{
+	DWORD threadid;
+	int pipe_fd[2];
+	void *userdata;
+} thread;
+
+thread *thread_new (void);
+int thread_start (thread *th, void *(*start_routine)(void *), void *arg);
diff --git a/plugins/makefile.mak b/plugins/makefile.mak
index 07205ab4..19b3cb75 100644
--- a/plugins/makefile.mak
+++ b/plugins/makefile.mak
@@ -3,6 +3,8 @@ all:
 	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\gtkpref
 	@-$(MAKE) /nologo /s /f makefile.mak $@
+	@cd ..\dns
+	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\doat
 	@-$(MAKE) /nologo /s /f makefile.mak $@
 	@cd ..\exec
@@ -37,6 +39,8 @@ clean:
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\gtkpref
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
+	@cd ..\dns
+	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\doat
 	@-$(MAKE) /nologo /s /f makefile.mak clean $@
 	@cd ..\exec
diff --git a/win32/release-x64.bat b/win32/release-x64.bat
index 1b3c2586..8437f525 100644
--- a/win32/release-x64.bat
+++ b/win32/release-x64.bat
@@ -56,6 +56,7 @@ copy %DEPS_ROOT%\bin\cert.pem %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libenchant.dll %XCHAT_DEST%
 xcopy /q /s /i %DEPS_ROOT%\lib\enchant\libenchant_myspell.dll %XCHAT_DEST%\lib\enchant\
 xcopy /q /s /i ..\plugins\checksum\xcchecksum.dll %XCHAT_DEST%\plugins\
+copy ..\plugins\dns\xcdns.dll %XCHAT_DEST%\plugins
 copy ..\plugins\doat\xcdoat.dll %XCHAT_DEST%\plugins
 copy ..\plugins\exec\xcexec.dll %XCHAT_DEST%\plugins
 copy ..\plugins\fishlim\xcfishlim.dll %XCHAT_DEST%\plugins
diff --git a/win32/release-x86.bat b/win32/release-x86.bat
index 4583add6..dc022b75 100644
--- a/win32/release-x86.bat
+++ b/win32/release-x86.bat
@@ -58,6 +58,7 @@ copy %DEPS_ROOT%\bin\cert.pem %XCHAT_DEST%
 copy %DEPS_ROOT%\bin\libenchant.dll %XCHAT_DEST%
 xcopy /q /s /i %DEPS_ROOT%\lib\enchant\libenchant_myspell.dll %XCHAT_DEST%\lib\enchant\
 xcopy /q /s /i ..\plugins\checksum\xcchecksum.dll %XCHAT_DEST%\plugins\
+copy ..\plugins\dns\xcdns.dll %XCHAT_DEST%\plugins
 copy ..\plugins\doat\xcdoat.dll %XCHAT_DEST%\plugins
 copy ..\plugins\exec\xcexec.dll %XCHAT_DEST%\plugins
 copy ..\plugins\fishlim\xcfishlim.dll %XCHAT_DEST%\plugins
diff --git a/win32/xchat-wdk-x64.skel.iss b/win32/xchat-wdk-x64.skel.iss
index 955eeb42..1caf8198 100644
--- a/win32/xchat-wdk-x64.skel.iss
+++ b/win32/xchat-wdk-x64.skel.iss
@@ -35,6 +35,7 @@ Name: "translations"; Description: "Translations"; Types: normal full custom; Fl
 ;Name: "spelling"; Description: "Spelling Dictionaries"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins"; Description: "Plugins"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\checksum"; Description: "Checksum"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\dns"; Description: "DNS"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\doat"; Description: "Do At"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\exec"; Description: "Exec"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\fishlim"; Description: "FiSHLiM"; Types: full custom; Flags: disablenouninstallwarning
@@ -150,6 +151,7 @@ Source: "lib\gtk-2.0\modules\libgail.dll"; DestDir: "{app}\lib\gtk-2.0\modules";
 ;obs Source: "gtk2-prefs.exe"; DestDir: "{app}"; Flags: ignoreversion; Components: gtkengines
 
 Source: "plugins\xcchecksum.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\checksum
+Source: "plugins\xcdns.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\dns
 Source: "plugins\xcdoat.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\doat
 Source: "plugins\xcexec.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\exec
 Source: "plugins\xcfishlim.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\fishlim
diff --git a/win32/xchat-wdk-x86.skel.iss b/win32/xchat-wdk-x86.skel.iss
index dbc75f80..a53e7cfd 100644
--- a/win32/xchat-wdk-x86.skel.iss
+++ b/win32/xchat-wdk-x86.skel.iss
@@ -34,6 +34,7 @@ Name: "translations"; Description: "Translations"; Types: normal full custom; Fl
 ;Name: "spelling"; Description: "Spelling Dictionaries"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins"; Description: "Plugins"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\checksum"; Description: "Checksum"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\dns"; Description: "DNS"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\doat"; Description: "Do At"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\exec"; Description: "Exec"; Types: full custom; Flags: disablenouninstallwarning
 Name: "plugins\fishlim"; Description: "FiSHLiM"; Types: full custom; Flags: disablenouninstallwarning
@@ -151,6 +152,7 @@ Source: "lib\gtk-2.0\modules\libgail.dll"; DestDir: "{app}\lib\gtk-2.0\modules";
 ;obs Source: "gtk2-prefs.exe"; DestDir: "{app}"; Flags: ignoreversion; Components: gtkengines
 
 Source: "plugins\xcchecksum.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\checksum
+Source: "plugins\xcdns.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\dns
 Source: "plugins\xcdoat.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\doat
 Source: "plugins\xcexec.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\exec
 Source: "plugins\xcfishlim.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\fishlim
-- 
cgit 1.4.1


From 83b6f548adc704f7b122add1fd38b6879ba2ed8d Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Fri, 20 Jan 2012 18:02:55 +0100
Subject: update the checksum plugin to use the plugin config api

---
 plugins/checksum/checksum.c | 183 ++++++++++++--------------------------------
 1 file changed, 49 insertions(+), 134 deletions(-)

(limited to 'plugins')

diff --git a/plugins/checksum/checksum.c b/plugins/checksum/checksum.c
index 103a80ca..79f64982 100644
--- a/plugins/checksum/checksum.c
+++ b/plugins/checksum/checksum.c
@@ -1,5 +1,5 @@
 /* XChat-WDK
- * Copyright (c) 2010-2011 Berke Viktor.
+ * Copyright (c) 2010-2012 Berke Viktor.
  *
  * Permission is hereby granted, free of charge, to any person obtaining a copy
  * of this software and associated documentation files (the "Software"), to deal
@@ -31,8 +31,7 @@
 #include "xchat-plugin.h"
 
 #define BUFSIZE 32768
-#define DEFAULT_MAX_HASH_SIZE 268435456						/* default size is 256 MB */
-#define FILE_BUF_SIZE 512
+#define DEFAULT_LIMIT 256									/* default size is 256 MiB */
 
 #ifndef snprintf
 #define snprintf _snprintf
@@ -44,8 +43,7 @@
 static xchat_plugin *ph;									/* plugin handle */
 static const char name[] = "Checksum";
 static const char desc[] = "Calculate checksum for DCC file transfers";
-static const char version[] = "2.0";
-static int config_fail;										/* variable for config availability */
+static const char version[] = "3.0";
 
 /* Use of OpenSSL SHA256 interface: http://adamlamers.com/?p=5 */
 static void
@@ -114,135 +112,46 @@ sha256_file (char *path, char outputBuffer[65])
 }
 
 static void
-init ()
+set_limit (char* size)
 {
-	/* check whether the config file exists, if it doesn't, try to create it */
-	FILE * file_in;
-	FILE * file_out;
-	char buffer[FILE_BUF_SIZE];
+	int buffer = atoi (size);
 
-	config_fail = 0;
-	snprintf (buffer, sizeof (buffer), "%s/checksum.conf", xchat_get_info (ph, "xchatdirfs"));
-
-	if ((file_in = fopen (buffer, "r")) == NULL)
+	if (buffer > 0 && buffer < INT_MAX)
 	{
-		if ((file_out = fopen (buffer, "w")) == NULL)
+		if (xchat_pluginpref_set_int (ph, "limit", buffer))
 		{
-			config_fail = 1;
-		} else
+			xchat_printf (ph, "File size limit has successfully been set to: %d MiB\n", buffer);
+		}
+		else
 		{
-			fprintf (file_out, "%llu\n", (unsigned long long) DEFAULT_MAX_HASH_SIZE);
-			fclose (file_out);
+			xchat_printf (ph, "File access error while saving!\n");
 		}
-	} else
-	{
-		fclose (file_in);
-	}
-
-	/* nasty easter egg: if FILE_BUF_SIZE is set to 1024 and you build for x86, you can do fclose ()
-	   at the end of init (), which is plain wrong as it will only work if fopen () != 0. */
-}
-
-static unsigned long long
-get_max_hash_size ()
-{
-	FILE * file_in;
-	char buffer[FILE_BUF_SIZE];
-	unsigned long long max_hash_size;
-
-	if (config_fail)
-	{
-		return (unsigned long long) DEFAULT_MAX_HASH_SIZE;
-	} else
-	{
-		snprintf (buffer, sizeof (buffer), "%s/checksum.conf", xchat_get_info (ph, "xchatdirfs"));
-		file_in = fopen (buffer, "r");
-		fscanf (file_in, "%llu", &max_hash_size);
-
-		fclose (file_in);
-		return max_hash_size;
 	}
-}
-
-static void
-print_size ()
-{
-	unsigned long long size;
-	char suffix[3];
-	
-	size = get_max_hash_size ();
-	
-	if (size >= 1073741824)
-	{
-		size /= 1073741824;
-		snprintf (suffix, sizeof (suffix), "GB");
-	} else if (size >= 1048576)
-	{
-		size /= 1048576;
-		snprintf (suffix, sizeof (suffix), "MB");
-	} else if (size >= 1024)
+	else
 	{
-		size /= 1024;
-		snprintf (suffix, sizeof (suffix), "kB");
-	} else
-	{
-		snprintf (suffix, sizeof (suffix), "B");
+		xchat_printf (ph, "Invalid input!\n");
 	}
-	xchat_printf (ph, "File size limit for checksums: %llu %s\n", size, suffix);
 }
 
-static void
-increase_max_hash_size ()
+static int
+get_limit ()
 {
-	unsigned long long size;
-	FILE * file_out;
-	char buffer[FILE_BUF_SIZE];
+	int size = xchat_pluginpref_get_int (ph, "limit");
 
-	if (config_fail)
+	if (size <= -1 || size >= INT_MAX)
 	{
-		xchat_printf (ph, "Config file is unavailable, falling back to the default value\n");
-		print_size ();
-	} else
+		return DEFAULT_LIMIT;
+	}
+	else
 	{
-		size = get_max_hash_size ();
-		if (size <= ULLONG_MAX/2)
-		{
-			size *= 2;
-		}
-		
-		snprintf (buffer, sizeof (buffer), "%s/checksum.conf", xchat_get_info (ph, "xchatdirfs"));
-		file_out = fopen (buffer, "w");
-		fprintf (file_out, "%llu\n", size);
-		fclose (file_out);
-		print_size ();
+		return size;
 	}
 }
 
 static void
-decrease_max_hash_size ()
+print_limit ()
 {
-	unsigned long long size;
-	FILE * file_out;
-	char buffer[FILE_BUF_SIZE];
-
-	if (config_fail)
-	{
-		xchat_printf (ph, "Config file is unavailable, falling back to the default value\n");
-		print_size ();
-	} else
-	{
-		size = get_max_hash_size ();
-		if (size >= 2)
-		{
-			size /= 2;
-		}
-		
-		snprintf (buffer, sizeof (buffer), "%s/checksum.conf", xchat_get_info (ph, "xchatdirfs"));
-		file_out = fopen (buffer, "w");
-		fprintf (file_out, "%llu\n", size);
-		fclose (file_out);
-		print_size ();
-	}
+	xchat_printf (ph, "File size limit for checksums: %d MiB", get_limit ());
 }
 
 static int
@@ -255,20 +164,22 @@ dccrecv_cb (char *word[], void *userdata)
 	result = stat64 (word[2], &buffer);
 	if (result == 0)										/* stat returns 0 on success */
 	{
-		if (buffer.st_size <= get_max_hash_size ())
+		if (buffer.st_size <= (unsigned long long) get_limit () * 1048576)
 		{
 			sha256_file (word[2], sum);						/* word[2] is the full filename */
 			/* try to print the checksum in the privmsg tab of the sender */
 			xchat_set_context (ph, xchat_find_context (ph, NULL, word[3]));
 			xchat_printf (ph, "SHA-256 checksum for %s (local):  %s\n", word[1], sum);
-		} else
+		}
+		else
 		{
 			xchat_set_context (ph, xchat_find_context (ph, NULL, word[3]));
 			xchat_printf (ph, "SHA-256 checksum for %s (local):  (size limit reached, no checksum calculated, you can increase it with /CHECKSUM INC)\n", word[1]);
 		}
-	} else
+	}
+	else
 	{
-		xchat_printf (ph, "File access error\n");
+		xchat_printf (ph, "File access error!\n");
 	}
 
 	return XCHAT_EAT_NONE;
@@ -284,18 +195,20 @@ dccoffer_cb (char *word[], void *userdata)
 	result = stat64 (word[3], &buffer);
 	if (result == 0)										/* stat returns 0 on success */
 	{
-		if (buffer.st_size <= get_max_hash_size ())
+		if (buffer.st_size <= (unsigned long long) get_limit () * 1048576)
 		{
 			sha256_file (word[3], sum);						/* word[3] is the full filename */
 			xchat_commandf (ph, "quote PRIVMSG %s :SHA-256 checksum for %s (remote): %s", word[2], word[1], sum);
-		} else
+		}
+		else
 		{
 			xchat_set_context (ph, xchat_find_context (ph, NULL, word[3]));
 			xchat_printf (ph, "quote PRIVMSG %s :SHA-256 checksum for %s (remote): (size limit reached, no checksum calculated)", word[2], word[1]);
 		}
-	} else
+	}
+	else
 	{
-		xchat_printf (ph, "File access error\n");
+		xchat_printf (ph, "File access error!\n");
 	}
 
 	return XCHAT_EAT_NONE;
@@ -306,19 +219,17 @@ checksum (char *word[], void *userdata)
 {
 	if (!stricmp ("GET", word[2]))
 	{
-		print_size ();
-	} else if (!stricmp ("INC", word[2]))
-	{
-		increase_max_hash_size ();
-	} else if (!stricmp ("DEC", word[2]))
+		print_limit ();
+	}
+	else if (!stricmp ("SET", word[2]))
 	{
-		decrease_max_hash_size ();
-	} else
+		set_limit (word[3]);
+	}
+	else
 	{
 		xchat_printf (ph, "Usage: /CHECKSUM GET|INC|DEC\n");
-		xchat_printf (ph, "  GET - print the maximum file size to be hashed\n");
-		xchat_printf (ph, "  INC - double the maximum file size to be hashed\n");
-		xchat_printf (ph, "  DEC - halve the maximum file size to be hashed\n");
+		xchat_printf (ph, "  GET - print the maximum file size (in MiB) to be hashed\n");
+		xchat_printf (ph, "  SET <filesize> - set the maximum file size (in MiB) to be hashed\n");
 	}
 }
 
@@ -331,9 +242,13 @@ xchat_plugin_init (xchat_plugin *plugin_handle, char **plugin_name, char **plugi
 	*plugin_desc = desc;
 	*plugin_version = version;
 
-	init ();
+	/* this is required for the very first run */
+	if (xchat_pluginpref_get_int (ph, "limit") == -1)
+	{
+		xchat_pluginpref_set_int (ph, "limit", DEFAULT_LIMIT);
+	}
 
-	xchat_hook_command (ph, "CHECKSUM", XCHAT_PRI_NORM, checksum, "Usage: /CHECKSUM GET|INC|DEC", 0);
+	xchat_hook_command (ph, "CHECKSUM", XCHAT_PRI_NORM, checksum, "Usage: /CHECKSUM GET|SET", 0);
 	xchat_hook_print (ph, "DCC RECV Complete", XCHAT_PRI_NORM, dccrecv_cb, NULL);
 	xchat_hook_print (ph, "DCC Offer", XCHAT_PRI_NORM, dccoffer_cb, NULL);
 
-- 
cgit 1.4.1


From c73149cf44779965b76377526ffe6789dfef2131 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sat, 4 Feb 2012 17:41:02 +0100
Subject: fix update checking errors due to GC HTTP bug - manual IE tweaking's
 still required

---
 plugins/upd/upd.c | 74 ++++++++++++++++++++++++++++++++++++++++++++++++++++++-
 1 file changed, 73 insertions(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/upd/upd.c b/plugins/upd/upd.c
index 578da0d9..b85755cb 100644
--- a/plugins/upd/upd.c
+++ b/plugins/upd/upd.c
@@ -28,11 +28,21 @@
 static xchat_plugin *ph;   /* plugin handle */
 static const char name[] = "Update Checker";
 static const char desc[] = "Check for XChat-WDK updates automatically";
-static const char version[] = "2.0";
+static const char version[] = "2.1";
 
 static char*
 check_version ()
 {
+#if 0
+	/* Google Code's messing up with requests, use HTTP/1.0 as suggested. More info:
+
+	   http://code.google.com/p/support/issues/detail?id=6095
+
+	   Of course it would be still too simple, coz IE will override settings, so
+	   you have to disable HTTP/1.1 manually and globally. More info:
+
+	   http://support.microsoft.com/kb/258425
+	   */
 	HINTERNET hINet, hFile;
 	hINet = InternetOpen ("Update Checker", INTERNET_OPEN_TYPE_PRECONFIG, NULL, NULL, 0);
 	
@@ -62,6 +72,68 @@ check_version ()
 	
 	InternetCloseHandle (hINet);
 	return "Unknown";
+#endif
+
+	static char buffer[1024];
+	DWORD dwRead;
+	HINTERNET hOpen, hConnect, hResource;
+
+	hOpen = InternetOpen (TEXT("Update Checker"),
+						INTERNET_OPEN_TYPE_PRECONFIG,
+						NULL,
+						NULL,
+						0);
+	if (!hOpen)
+	{
+		return "Unknown";
+	}
+
+	hConnect = InternetConnect (hOpen,
+								TEXT("xchat-wdk.googlecode.com"),
+								INTERNET_INVALID_PORT_NUMBER,
+								NULL,
+								NULL,
+								INTERNET_SERVICE_HTTP,
+								0,
+								0);
+	if (!hConnect)
+	{
+		InternetCloseHandle (hOpen);
+		return "Unknown";
+	}
+
+	hResource = HttpOpenRequest (hConnect,
+								TEXT("GET"),
+								TEXT("/git/version.txt?r=wdk"),
+								TEXT("HTTP/1.0"),
+								NULL,
+								NULL,
+								INTERNET_FLAG_NO_CACHE_WRITE | INTERNET_FLAG_RELOAD | INTERNET_FLAG_NO_AUTH,
+								0);
+	if (!hResource)
+	{
+		InternetCloseHandle (hConnect);
+		InternetCloseHandle (hOpen);
+		return "Unknown";
+	}
+	else
+	{
+		HttpSendRequest (hResource, NULL, 0, NULL, 0);
+
+		while (InternetReadFile (hResource, buffer, 1023, &dwRead))
+		{
+			if (dwRead == 0)
+			{
+				break;
+			}
+			buffer[dwRead] = 0;
+		}
+
+		InternetCloseHandle (hResource);
+		InternetCloseHandle (hConnect);
+		InternetCloseHandle (hOpen);
+		return buffer;
+	}
 }
 
 static int
-- 
cgit 1.4.1


From 8849fb4c108f5f6341e341bcbf6db50bf6f84737 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sat, 4 Feb 2012 20:24:30 +0100
Subject: use old code since disabling HTTP/1.1 works with that too

---
 plugins/upd/upd.c | 39 ++++++++++++++++++++++++---------------
 1 file changed, 24 insertions(+), 15 deletions(-)

(limited to 'plugins')

diff --git a/plugins/upd/upd.c b/plugins/upd/upd.c
index b85755cb..baf5b85b 100644
--- a/plugins/upd/upd.c
+++ b/plugins/upd/upd.c
@@ -33,26 +33,20 @@ static const char version[] = "2.1";
 static char*
 check_version ()
 {
-#if 0
-	/* Google Code's messing up with requests, use HTTP/1.0 as suggested. More info:
-
-	   http://code.google.com/p/support/issues/detail?id=6095
-
-	   Of course it would be still too simple, coz IE will override settings, so
-	   you have to disable HTTP/1.1 manually and globally. More info:
-
-	   http://support.microsoft.com/kb/258425
-	   */
 	HINTERNET hINet, hFile;
 	hINet = InternetOpen ("Update Checker", INTERNET_OPEN_TYPE_PRECONFIG, NULL, NULL, 0);
-	
+
 	if (!hINet)
 	{
 		return "Unknown";
 	}
 
-	hFile = InternetOpenUrl (hINet, "http://xchat-wdk.googlecode.com/git/version.txt?r=wdk", NULL, 0, INTERNET_FLAG_NO_CACHE_WRITE | INTERNET_FLAG_RELOAD, 0);
-	
+	hFile = InternetOpenUrl (hINet,
+							"http://xchat-wdk.googlecode.com/git/version.txt?r=wdk",
+							NULL,
+							0,
+							INTERNET_FLAG_NO_CACHE_WRITE | INTERNET_FLAG_RELOAD,
+							0);
 	if (hFile)
 	{
 		static char buffer[1024];
@@ -67,12 +61,26 @@ check_version ()
 		}
 
 		InternetCloseHandle (hFile);
+		InternetCloseHandle (hINet);
 		return buffer;
 	}
-	
+
 	InternetCloseHandle (hINet);
 	return "Unknown";
-#endif
+
+#if 0
+	/* Google Code's messing up with requests, use HTTP/1.0 as suggested. More info:
+
+	   http://code.google.com/p/support/issues/detail?id=6095
+
+	   Of course it would be still too simple, coz IE will override settings, so
+	   you have to disable HTTP/1.1 manually and globally. More info:
+
+	   http://support.microsoft.com/kb/258425
+
+	   So this code's basically useless since disabling HTTP/1.1 will work with the
+	   above code too.
+	*/
 
 	static char buffer[1024];
 	DWORD dwRead;
@@ -134,6 +142,7 @@ check_version ()
 		InternetCloseHandle (hOpen);
 		return buffer;
 	}
+#endif
 }
 
 static int
-- 
cgit 1.4.1


From 067ee4fc5b71872a1fb2758e07fae960832022d9 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Wed, 8 Feb 2012 21:52:27 +0100
Subject: supposed workaround for disabling chunked encoding (snq-)

---
 plugins/upd/upd.c | 22 +++++++++++++---------
 1 file changed, 13 insertions(+), 9 deletions(-)

(limited to 'plugins')

diff --git a/plugins/upd/upd.c b/plugins/upd/upd.c
index baf5b85b..1659162c 100644
--- a/plugins/upd/upd.c
+++ b/plugins/upd/upd.c
@@ -33,6 +33,7 @@ static const char version[] = "2.1";
 static char*
 check_version ()
 {
+#if 0
 	HINTERNET hINet, hFile;
 	hINet = InternetOpen ("Update Checker", INTERNET_OPEN_TYPE_PRECONFIG, NULL, NULL, 0);
 
@@ -67,8 +68,8 @@ check_version ()
 
 	InternetCloseHandle (hINet);
 	return "Unknown";
+#endif
 
-#if 0
 	/* Google Code's messing up with requests, use HTTP/1.0 as suggested. More info:
 
 	   http://code.google.com/p/support/issues/detail?id=6095
@@ -80,13 +81,13 @@ check_version ()
 
 	   So this code's basically useless since disabling HTTP/1.1 will work with the
 	   above code too.
+
+	   Update: a Connection: close header seems to disable chunked encoding.
 	*/
 
-	static char buffer[1024];
-	DWORD dwRead;
 	HINTERNET hOpen, hConnect, hResource;
 
-	hOpen = InternetOpen (TEXT("Update Checker"),
+	hOpen = InternetOpen (TEXT ("Update Checker"),
 						INTERNET_OPEN_TYPE_PRECONFIG,
 						NULL,
 						NULL,
@@ -97,7 +98,7 @@ check_version ()
 	}
 
 	hConnect = InternetConnect (hOpen,
-								TEXT("xchat-wdk.googlecode.com"),
+								TEXT ("xchat-wdk.googlecode.com"),
 								INTERNET_INVALID_PORT_NUMBER,
 								NULL,
 								NULL,
@@ -111,9 +112,9 @@ check_version ()
 	}
 
 	hResource = HttpOpenRequest (hConnect,
-								TEXT("GET"),
-								TEXT("/git/version.txt?r=wdk"),
-								TEXT("HTTP/1.0"),
+								TEXT ("GET"),
+								TEXT ("/git/version.txt?r=wdk"),
+								TEXT ("HTTP/1.0"),
 								NULL,
 								NULL,
 								INTERNET_FLAG_NO_CACHE_WRITE | INTERNET_FLAG_RELOAD | INTERNET_FLAG_NO_AUTH,
@@ -126,6 +127,10 @@ check_version ()
 	}
 	else
 	{
+		static char buffer[1024];
+		DWORD dwRead;
+
+		HttpAddRequestHeaders (hResource, TEXT ("Connection: close\r\n"), -1L, HTTP_ADDREQ_FLAG_ADD);	/* workaround for GC bug */
 		HttpSendRequest (hResource, NULL, 0, NULL, 0);
 
 		while (InternetReadFile (hResource, buffer, 1023, &dwRead))
@@ -142,7 +147,6 @@ check_version ()
 		InternetCloseHandle (hOpen);
 		return buffer;
 	}
-#endif
 }
 
 static int
-- 
cgit 1.4.1


From bd72cce2d9c47e2a62d78eff11c8d2a8e6bd6bbc Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Thu, 16 Feb 2012 18:00:51 +0100
Subject: display WDK version number in X-Tray

---
 plugins/xtray/xtray.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/xtray/xtray.cpp b/plugins/xtray/xtray.cpp
index 33ce125f..ec5e34f8 100644
--- a/plugins/xtray/xtray.cpp
+++ b/plugins/xtray/xtray.cpp
@@ -116,7 +116,7 @@ int xchat_plugin_init(xchat_plugin *plugin_handle, char **plugin_name, char **pl
 	/************************* Add our icon to the tray ************************************************************************/
 	/***************************************************************************************************************************/
 	char szVersion[64];
-	_snprintf(szVersion, 64, "XChat-WDK [%s]", xchat_get_info(ph, "version"));
+	_snprintf(szVersion, 64, "XChat-WDK %s", xchat_get_info(ph, "wdk_version"));
 	AddIcon(g_hXchatWnd, 1, g_hIcons[0], szVersion, (NIF_ICON | NIF_MESSAGE | NIF_TIP), WM_TRAYMSG);
 
 	/***************************************************************************************************************************/
-- 
cgit 1.4.1


From 9d91db6be80b7b25fc6b3b89c8ec6b0163f217a1 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Fri, 16 Mar 2012 00:17:03 +0100
Subject: sync with fishlim head

---
 plugins/fishlim/plugin_xchat.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

(limited to 'plugins')

diff --git a/plugins/fishlim/plugin_xchat.c b/plugins/fishlim/plugin_xchat.c
index 01f5d747..8bbcf3e2 100644
--- a/plugins/fishlim/plugin_xchat.c
+++ b/plugins/fishlim/plugin_xchat.c
@@ -133,7 +133,7 @@ static int handle_incoming(char *word[], char *word_eol[], void *userdata) {
     // Look for encrypted data
     for (ew = w+1; ew < XCHAT_MAX_WORDS-1; ew++) {
         const char *s = (ew == w+1 ? word[ew]+1 : word[ew]);
-        if (strcmp(s, "+OK") == 0) goto has_encrypted_data;
+        if (strcmp(s, "+OK") == 0 || strcmp(s, "mcps") == 0) goto has_encrypted_data;
     }
     return XCHAT_EAT_NONE;
   has_encrypted_data: ;
-- 
cgit 1.4.1


From 21f1427cc6f6201444566ae20a92b7a9aa6b5eaa Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Fri, 4 May 2012 19:29:02 +0200
Subject: sync with fishlim head

---
 plugins/fishlim/LICENSE        | 2 +-
 plugins/fishlim/fish.c         | 2 +-
 plugins/fishlim/fish.h         | 2 +-
 plugins/fishlim/irc.c          | 2 +-
 plugins/fishlim/irc.h          | 2 +-
 plugins/fishlim/keystore.c     | 2 +-
 plugins/fishlim/keystore.h     | 2 +-
 plugins/fishlim/misc.c         | 2 +-
 plugins/fishlim/misc.h         | 2 +-
 plugins/fishlim/plugin_xchat.c | 2 +-
 plugins/fishlim/plugin_xchat.h | 2 +-
 plugins/fishlim/test.c         | 2 +-
 12 files changed, 12 insertions(+), 12 deletions(-)

(limited to 'plugins')

diff --git a/plugins/fishlim/LICENSE b/plugins/fishlim/LICENSE
index 427f2631..a3e0474a 100644
--- a/plugins/fishlim/LICENSE
+++ b/plugins/fishlim/LICENSE
@@ -1,5 +1,5 @@
 
-Copyright (c) 2010-2011 Samuel Lidén Borell <samuel@slbdata.se>
+Copyright (c) 2010-2011 Samuel Lidén Borell <samuel@kodafritt.se>
 
 Permission is hereby granted, free of charge, to any person obtaining a copy
 of this software and associated documentation files (the "Software"), to deal
diff --git a/plugins/fishlim/fish.c b/plugins/fishlim/fish.c
index cb977d7f..d4f7b118 100644
--- a/plugins/fishlim/fish.c
+++ b/plugins/fishlim/fish.c
@@ -1,6 +1,6 @@
 /*
 
-  Copyright (c) 2010 Samuel Lidén Borell <samuel@slbdata.se>
+  Copyright (c) 2010 Samuel Lidén Borell <samuel@kodafritt.se>
 
   Permission is hereby granted, free of charge, to any person obtaining a copy
   of this software and associated documentation files (the "Software"), to deal
diff --git a/plugins/fishlim/fish.h b/plugins/fishlim/fish.h
index d4057a7b..5a4e85d0 100644
--- a/plugins/fishlim/fish.h
+++ b/plugins/fishlim/fish.h
@@ -1,6 +1,6 @@
 /*
 
-  Copyright (c) 2010 Samuel Lidén Borell <samuel@slbdata.se>
+  Copyright (c) 2010 Samuel Lidén Borell <samuel@kodafritt.se>
 
   Permission is hereby granted, free of charge, to any person obtaining a copy
   of this software and associated documentation files (the "Software"), to deal
diff --git a/plugins/fishlim/irc.c b/plugins/fishlim/irc.c
index a96c4c91..3586921b 100644
--- a/plugins/fishlim/irc.c
+++ b/plugins/fishlim/irc.c
@@ -1,6 +1,6 @@
 /*
 
-  Copyright (c) 2010 Samuel Lidén Borell <samuel@slbdata.se>
+  Copyright (c) 2010 Samuel Lidén Borell <samuel@kodafritt.se>
 
   Permission is hereby granted, free of charge, to any person obtaining a copy
   of this software and associated documentation files (the "Software"), to deal
diff --git a/plugins/fishlim/irc.h b/plugins/fishlim/irc.h
index 0c1e7463..58a58c83 100644
--- a/plugins/fishlim/irc.h
+++ b/plugins/fishlim/irc.h
@@ -1,6 +1,6 @@
 /*
 
-  Copyright (c) 2010 Samuel Lidén Borell <samuel@slbdata.se>
+  Copyright (c) 2010 Samuel Lidén Borell <samuel@kodafritt.se>
 
   Permission is hereby granted, free of charge, to any person obtaining a copy
   of this software and associated documentation files (the "Software"), to deal
diff --git a/plugins/fishlim/keystore.c b/plugins/fishlim/keystore.c
index d97107fd..e628c289 100644
--- a/plugins/fishlim/keystore.c
+++ b/plugins/fishlim/keystore.c
@@ -1,6 +1,6 @@
 /*
 
-  Copyright (c) 2010 Samuel Lidén Borell <samuel@slbdata.se>
+  Copyright (c) 2010 Samuel Lidén Borell <samuel@kodafritt.se>
 
   Permission is hereby granted, free of charge, to any person obtaining a copy
   of this software and associated documentation files (the "Software"), to deal
diff --git a/plugins/fishlim/keystore.h b/plugins/fishlim/keystore.h
index b0c1c69c..edf54992 100644
--- a/plugins/fishlim/keystore.h
+++ b/plugins/fishlim/keystore.h
@@ -1,6 +1,6 @@
 /*
 
-  Copyright (c) 2010 Samuel Lidén Borell <samuel@slbdata.se>
+  Copyright (c) 2010 Samuel Lidén Borell <samuel@kodafritt.se>
 
   Permission is hereby granted, free of charge, to any person obtaining a copy
   of this software and associated documentation files (the "Software"), to deal
diff --git a/plugins/fishlim/misc.c b/plugins/fishlim/misc.c
index 32fe3595..2b78961d 100644
--- a/plugins/fishlim/misc.c
+++ b/plugins/fishlim/misc.c
@@ -1,6 +1,6 @@
 /*
 
-  Copyright (c) 2010 Samuel Lidén Borell <samuel@slbdata.se>
+  Copyright (c) 2010 Samuel Lidén Borell <samuel@kodafritt.se>
 
   Permission is hereby granted, free of charge, to any person obtaining a copy
   of this software and associated documentation files (the "Software"), to deal
diff --git a/plugins/fishlim/misc.h b/plugins/fishlim/misc.h
index 0adc928c..ee4fc5b8 100644
--- a/plugins/fishlim/misc.h
+++ b/plugins/fishlim/misc.h
@@ -1,6 +1,6 @@
 /*
 
-  Copyright (c) 2010 Samuel Lidén Borell <samuel@slbdata.se>
+  Copyright (c) 2010 Samuel Lidén Borell <samuel@kodafritt.se>
 
   Permission is hereby granted, free of charge, to any person obtaining a copy
   of this software and associated documentation files (the "Software"), to deal
diff --git a/plugins/fishlim/plugin_xchat.c b/plugins/fishlim/plugin_xchat.c
index 8bbcf3e2..80e6c8cd 100644
--- a/plugins/fishlim/plugin_xchat.c
+++ b/plugins/fishlim/plugin_xchat.c
@@ -1,6 +1,6 @@
 /*
 
-  Copyright (c) 2010-2011 Samuel Lidén Borell <samuel@slbdata.se>
+  Copyright (c) 2010-2011 Samuel Lidén Borell <samuel@kodafritt.se>
 
   Permission is hereby granted, free of charge, to any person obtaining a copy
   of this software and associated documentation files (the "Software"), to deal
diff --git a/plugins/fishlim/plugin_xchat.h b/plugins/fishlim/plugin_xchat.h
index 0243e81f..d606526d 100644
--- a/plugins/fishlim/plugin_xchat.h
+++ b/plugins/fishlim/plugin_xchat.h
@@ -1,6 +1,6 @@
 /*
 
-  Copyright (c) 2010 Samuel Lidén Borell <samuel@slbdata.se>
+  Copyright (c) 2010 Samuel Lidén Borell <samuel@kodafritt.se>
 
   Permission is hereby granted, free of charge, to any person obtaining a copy
   of this software and associated documentation files (the "Software"), to deal
diff --git a/plugins/fishlim/test.c b/plugins/fishlim/test.c
index 3511bbb1..9e6a1f5f 100644
--- a/plugins/fishlim/test.c
+++ b/plugins/fishlim/test.c
@@ -1,6 +1,6 @@
 /*
 
-  Copyright (c) 2010 Samuel Lidén Borell <samuel@slbdata.se>
+  Copyright (c) 2010 Samuel Lidén Borell <samuel@kodafritt.se>
 
   Permission is hereby granted, free of charge, to any person obtaining a copy
   of this software and associated documentation files (the "Software"), to deal
-- 
cgit 1.4.1


From 5a50da6f827f96f12739a50d8917d43e28191551 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sun, 13 May 2012 14:45:32 +0200
Subject: Sync with FiSHLiM HEAD

---
 plugins/fishlim/README         |  1 +
 plugins/fishlim/plugin_xchat.c | 10 ++++++++--
 2 files changed, 9 insertions(+), 2 deletions(-)

(limited to 'plugins')

diff --git a/plugins/fishlim/README b/plugins/fishlim/README
index 4f315b44..00d7f682 100644
--- a/plugins/fishlim/README
+++ b/plugins/fishlim/README
@@ -26,6 +26,7 @@ Not working:
   * Password-protected key storage
   * Topic encryption
   * Remote exploitation (hopefully!)
+  * Plaintext content that contain +OK is decrypted twice
 
 
 Commands
diff --git a/plugins/fishlim/plugin_xchat.c b/plugins/fishlim/plugin_xchat.c
index 80e6c8cd..5e261116 100644
--- a/plugins/fishlim/plugin_xchat.c
+++ b/plugins/fishlim/plugin_xchat.c
@@ -44,7 +44,7 @@
 
 static const char plugin_name[] = "FiSHLiM";
 static const char plugin_desc[] = "Encryption plugin for the FiSH protocol. Less is More!";
-static const char plugin_version[] = "0.0.15";
+static const char plugin_version[] = "0.0.16";
 
 static const char usage_setkey[] = "Usage: SETKEY [<nick or #channel>] <password>, sets the key for a channel or nick";
 static const char usage_delkey[] = "Usage: DELKEY <nick or #channel>, deletes the key for a channel or nick";
@@ -161,9 +161,15 @@ static int handle_incoming(char *word[], char *word_eol[], void *userdata) {
             // Add the encrypted data
             peice = decrypted;
             uw++; // Skip "OK+"
+            
+            if (ew == w+1) {
+                // Prefix with colon, which gets stripped out otherwise
+                if (!append(&message, &length, ":")) goto decrypt_error;
+            }
+            
         } else {
             // Add unencrypted data (for example, a prefix from a bouncer or bot)
-            peice = (uw == w+1 ? word[uw]+1 : word[uw]);
+            peice = word[uw];
         }
         
         if (!append(&message, &length, peice)) goto decrypt_error;
-- 
cgit 1.4.1


From 95aace51cca7c7a87107a52a5618bba2135ce025 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sun, 10 Jun 2012 12:49:17 +0200
Subject: More solution fixes and add language interfaces

---
 plugins/lua/lua.c                     |  2 +-
 plugins/lua/lua.def                   |  3 ++
 plugins/lua/lua.vcxproj               | 73 +++++++++++++++++++++++++++++++++++
 plugins/lua/lua.vcxproj.filters       | 23 +++++++++++
 plugins/perl/perl-512.vcxproj         | 71 ++++++++++++++++++++++++++++++++++
 plugins/perl/perl-512.vcxproj.filters | 23 +++++++++++
 plugins/perl/perl-514.vcxproj         | 71 ++++++++++++++++++++++++++++++++++
 plugins/perl/perl-514.vcxproj.filters | 23 +++++++++++
 plugins/perl/perl-516.vcxproj         | 71 ++++++++++++++++++++++++++++++++++
 plugins/perl/perl-516.vcxproj.filters | 23 +++++++++++
 plugins/perl/perl.c                   |  2 +-
 plugins/python/python.c               |  2 +-
 plugins/python/python.def             |  4 ++
 plugins/python/python.vcxproj         | 65 +++++++++++++++++++++++++++++++
 plugins/python/python.vcxproj.filters | 23 +++++++++++
 plugins/tcl/tcl.def                   |  4 ++
 plugins/tcl/tcl.vcxproj               | 69 +++++++++++++++++++++++++++++++++
 plugins/tcl/tcl.vcxproj.filters       | 35 +++++++++++++++++
 src/fe-gtk/fe-gtk.vcxproj             |  4 +-
 src/pixmaps/pixmaps.vcxproj           |  2 +-
 win32/xchat.props                     | 30 ++++++++++++--
 win32/xchat.sln                       | 52 +++++++++++++++++++++++++
 22 files changed, 666 insertions(+), 9 deletions(-)
 create mode 100644 plugins/lua/lua.def
 create mode 100644 plugins/lua/lua.vcxproj
 create mode 100644 plugins/lua/lua.vcxproj.filters
 create mode 100644 plugins/perl/perl-512.vcxproj
 create mode 100644 plugins/perl/perl-512.vcxproj.filters
 create mode 100644 plugins/perl/perl-514.vcxproj
 create mode 100644 plugins/perl/perl-514.vcxproj.filters
 create mode 100644 plugins/perl/perl-516.vcxproj
 create mode 100644 plugins/perl/perl-516.vcxproj.filters
 create mode 100644 plugins/python/python.def
 create mode 100644 plugins/python/python.vcxproj
 create mode 100644 plugins/python/python.vcxproj.filters
 create mode 100644 plugins/tcl/tcl.def
 create mode 100644 plugins/tcl/tcl.vcxproj
 create mode 100644 plugins/tcl/tcl.vcxproj.filters

(limited to 'plugins')

diff --git a/plugins/lua/lua.c b/plugins/lua/lua.c
index 9f29bf08..6ccddf2c 100644
--- a/plugins/lua/lua.c
+++ b/plugins/lua/lua.c
@@ -48,7 +48,7 @@
 
 #ifdef _WIN32
 #include <direct.h>	/* for getcwd */
-#include "../../src/common/dirent-win32.h"
+#include "../../src/dirent/dirent-win32.h"
 #endif
 
 #if !( defined(_WIN32) || defined(LXC_XCHAT_GETTEXT) )
diff --git a/plugins/lua/lua.def b/plugins/lua/lua.def
new file mode 100644
index 00000000..77670bf2
--- /dev/null
+++ b/plugins/lua/lua.def
@@ -0,0 +1,3 @@
+EXPORTS 
+xchat_plugin_init 
+xchat_plugin_deinit 
diff --git a/plugins/lua/lua.vcxproj b/plugins/lua/lua.vcxproj
new file mode 100644
index 00000000..d78a1e35
--- /dev/null
+++ b/plugins/lua/lua.vcxproj
@@ -0,0 +1,73 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup Label="ProjectConfigurations">
+    <ProjectConfiguration Include="Release|Win32">
+      <Configuration>Release</Configuration>
+      <Platform>Win32</Platform>
+    </ProjectConfiguration>
+  </ItemGroup>
+  <PropertyGroup Label="Globals">
+    <ProjectGuid>{646B4316-C8B8-4DB6-B6AE-E586929E5729}</ProjectGuid>
+    <Keyword>Win32Proj</Keyword>
+    <RootNamespace>lua</RootNamespace>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
+  <ImportGroup Label="ExtensionSettings">
+  </ImportGroup>
+  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
+  <PropertyGroup Label="UserMacros" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>$(LuaOutput)</TargetName>
+  </PropertyGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <ClCompile>
+      <WarningLevel>Level3</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;LUA_EXPORTS;$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <AdditionalIncludeDirectories>$(DepsRoot)\include;..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <AdditionalLibraryDirectories>$(DepsRoot)\lib;$(OutDir);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+      <AdditionalDependencies>"$(LuaLib).lib";;dirent-win32.lib;%(AdditionalDependencies)</AdditionalDependencies>
+    </Link>
+  </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <Link>
+      <AdditionalDependencies>"$(LuaLib).lib";$(DepLibs);dirent-win32.lib;%(AdditionalDependencies)</AdditionalDependencies>
+    </Link>
+  </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <ClCompile>
+      <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;$(OwnFlags);snprintf=g_snprintf;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+    </ClCompile>
+  </ItemDefinitionGroup>
+  <ItemGroup>
+    <None Include="lua.def" />
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="lua.c" />
+  </ItemGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
+  <ImportGroup Label="ExtensionTargets">
+  </ImportGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/lua/lua.vcxproj.filters b/plugins/lua/lua.vcxproj.filters
new file mode 100644
index 00000000..9c7e3d89
--- /dev/null
+++ b/plugins/lua/lua.vcxproj.filters
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup>
+    <Filter Include="Source Files">
+      <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
+      <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
+    </Filter>
+    <Filter Include="Resource Files">
+      <UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
+      <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
+    </Filter>
+  </ItemGroup>
+  <ItemGroup>
+    <None Include="lua.def">
+      <Filter>Resource Files</Filter>
+    </None>
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="lua.c">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+  </ItemGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/perl/perl-512.vcxproj b/plugins/perl/perl-512.vcxproj
new file mode 100644
index 00000000..440496f3
--- /dev/null
+++ b/plugins/perl/perl-512.vcxproj
@@ -0,0 +1,71 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup Label="ProjectConfigurations">
+    <ProjectConfiguration Include="Release|Win32">
+      <Configuration>Release</Configuration>
+      <Platform>Win32</Platform>
+    </ProjectConfiguration>
+  </ItemGroup>
+  <PropertyGroup Label="Globals">
+    <ProjectGuid>{987E9374-98A1-44BA-946F-D3472D7A7055}</ProjectGuid>
+    <Keyword>Win32Proj</Keyword>
+    <RootNamespace>perl512</RootNamespace>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
+  <ImportGroup Label="ExtensionSettings">
+  </ImportGroup>
+  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
+  <PropertyGroup Label="UserMacros" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>$(Perl512Output)</TargetName>
+  </PropertyGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;PERL512_EXPORTS;$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+      <AdditionalIncludeDirectories>$(Perl512Path)\perl\lib\CORE;..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <AdditionalLibraryDirectories>$(OutDir);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+      <AdditionalDependencies>$(Perl512Lib).lib;dirent-win32.lib;%(AdditionalDependencies)</AdditionalDependencies>
+      <ModuleDefinitionFile>perl.def</ModuleDefinitionFile>
+      <DelayLoadDLLs>$(Perl512Lib).dll;%(DelayLoadDLLs)</DelayLoadDLLs>
+    </Link>
+    <PreBuildEvent>
+      <Command>"$(GendefPath)\gendef" "$(Perl512Path)\perl\bin\$(Perl512Lib).dll"
+lib /nologo /machine:x86 "/def:$(Perl512Lib).def" "/out:$(OutputPath)\$(Perl512Lib).lib"
+"$(Perl512Path)\perl\bin\perl.exe" generate_header</Command>
+    </PreBuildEvent>
+  </ItemDefinitionGroup>
+  <ItemGroup>
+    <ClCompile Include="perl.c" />
+  </ItemGroup>
+  <ItemGroup>
+    <None Include="perl.def" />
+  </ItemGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
+  <ImportGroup Label="ExtensionTargets">
+  </ImportGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/perl/perl-512.vcxproj.filters b/plugins/perl/perl-512.vcxproj.filters
new file mode 100644
index 00000000..c6c78a57
--- /dev/null
+++ b/plugins/perl/perl-512.vcxproj.filters
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup>
+    <Filter Include="Source Files">
+      <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
+      <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
+    </Filter>
+    <Filter Include="Resource Files">
+      <UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
+      <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
+    </Filter>
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="perl.c">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+  </ItemGroup>
+  <ItemGroup>
+    <None Include="perl.def">
+      <Filter>Resource Files</Filter>
+    </None>
+  </ItemGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/perl/perl-514.vcxproj b/plugins/perl/perl-514.vcxproj
new file mode 100644
index 00000000..04865562
--- /dev/null
+++ b/plugins/perl/perl-514.vcxproj
@@ -0,0 +1,71 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup Label="ProjectConfigurations">
+    <ProjectConfiguration Include="Release|Win32">
+      <Configuration>Release</Configuration>
+      <Platform>Win32</Platform>
+    </ProjectConfiguration>
+  </ItemGroup>
+  <PropertyGroup Label="Globals">
+    <ProjectGuid>{C4C9FA6F-F990-4C7B-85F6-CD8F4F5728F0}</ProjectGuid>
+    <Keyword>Win32Proj</Keyword>
+    <RootNamespace>perl514</RootNamespace>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
+  <ImportGroup Label="ExtensionSettings">
+  </ImportGroup>
+  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
+  <PropertyGroup Label="UserMacros" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>$(Perl514Output)</TargetName>
+  </PropertyGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;PERL514_EXPORTS;$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <AdditionalIncludeDirectories>$(Perl514Path)\perl\lib\CORE;..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <AdditionalLibraryDirectories>$(OutDir);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+      <AdditionalDependencies>$(Perl514Lib).lib;dirent-win32.lib;%(AdditionalDependencies)</AdditionalDependencies>
+      <ModuleDefinitionFile>perl.def</ModuleDefinitionFile>
+      <DelayLoadDLLs>$(Perl514Lib).dll;%(DelayLoadDLLs)</DelayLoadDLLs>
+    </Link>
+    <PreBuildEvent>
+      <Command>"$(GendefPath)\gendef" "$(Perl514Path)\perl\bin\$(Perl514Lib).dll"
+lib /nologo /machine:x86 "/def:$(Perl514Lib).def" "/out:$(OutputPath)\$(Perl514Lib).lib"
+"$(Perl514Path)\perl\bin\perl.exe" generate_header</Command>
+    </PreBuildEvent>
+  </ItemDefinitionGroup>
+  <ItemGroup>
+    <ClCompile Include="perl.c" />
+  </ItemGroup>
+  <ItemGroup>
+    <None Include="perl.def" />
+  </ItemGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
+  <ImportGroup Label="ExtensionTargets">
+  </ImportGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/perl/perl-514.vcxproj.filters b/plugins/perl/perl-514.vcxproj.filters
new file mode 100644
index 00000000..c6c78a57
--- /dev/null
+++ b/plugins/perl/perl-514.vcxproj.filters
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup>
+    <Filter Include="Source Files">
+      <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
+      <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
+    </Filter>
+    <Filter Include="Resource Files">
+      <UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
+      <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
+    </Filter>
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="perl.c">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+  </ItemGroup>
+  <ItemGroup>
+    <None Include="perl.def">
+      <Filter>Resource Files</Filter>
+    </None>
+  </ItemGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/perl/perl-516.vcxproj b/plugins/perl/perl-516.vcxproj
new file mode 100644
index 00000000..5a3c620d
--- /dev/null
+++ b/plugins/perl/perl-516.vcxproj
@@ -0,0 +1,71 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup Label="ProjectConfigurations">
+    <ProjectConfiguration Include="Release|Win32">
+      <Configuration>Release</Configuration>
+      <Platform>Win32</Platform>
+    </ProjectConfiguration>
+  </ItemGroup>
+  <PropertyGroup Label="Globals">
+    <ProjectGuid>{58654438-F674-42F7-88FA-73EF90AD80B1}</ProjectGuid>
+    <Keyword>Win32Proj</Keyword>
+    <RootNamespace>perl516</RootNamespace>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
+  <ImportGroup Label="ExtensionSettings">
+  </ImportGroup>
+  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
+  <PropertyGroup Label="UserMacros" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>$(Perl516Output)</TargetName>
+  </PropertyGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;PERL516_EXPORTS;$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <AdditionalIncludeDirectories>$(Perl516Path)\perl\lib\CORE;..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <AdditionalLibraryDirectories>$(OutDir);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+      <AdditionalDependencies>$(Perl516Lib).lib;dirent-win32.lib;%(AdditionalDependencies)</AdditionalDependencies>
+      <ModuleDefinitionFile>perl.def</ModuleDefinitionFile>
+      <DelayLoadDLLs>$(Perl516Lib).dll;%(DelayLoadDLLs)</DelayLoadDLLs>
+    </Link>
+    <PreBuildEvent>
+      <Command>"$(GendefPath)\gendef" "$(Perl516Path)\perl\bin\$(Perl516Lib).dll"
+lib /nologo /machine:x86 "/def:$(Perl516Lib).def" "/out:$(OutputPath)\$(Perl516Lib).lib"
+"$(Perl516Path)\perl\bin\perl.exe" generate_header</Command>
+    </PreBuildEvent>
+  </ItemDefinitionGroup>
+  <ItemGroup>
+    <None Include="perl.def" />
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="perl.c" />
+  </ItemGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
+  <ImportGroup Label="ExtensionTargets">
+  </ImportGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/perl/perl-516.vcxproj.filters b/plugins/perl/perl-516.vcxproj.filters
new file mode 100644
index 00000000..f6d00b5c
--- /dev/null
+++ b/plugins/perl/perl-516.vcxproj.filters
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup>
+    <Filter Include="Source Files">
+      <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
+      <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
+    </Filter>
+    <Filter Include="Resource Files">
+      <UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
+      <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
+    </Filter>
+  </ItemGroup>
+  <ItemGroup>
+    <None Include="perl.def">
+      <Filter>Resource Files</Filter>
+    </None>
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="perl.c">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+  </ItemGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/perl/perl.c b/plugins/perl/perl.c
index 719ef292..b07aa651 100644
--- a/plugins/perl/perl.c
+++ b/plugins/perl/perl.c
@@ -28,7 +28,7 @@
 #ifdef WIN32
 #include <windows.h>
 #define  _INC_DIRENT /* disable inclusion of perl's dirent.h, we use an own version for win32 */
-#include "../../src/common/dirent-win32.h"
+#include "../../src/dirent/dirent-win32.h"
 #else
 #include <dirent.h>
 #endif
diff --git a/plugins/python/python.c b/plugins/python/python.c
index dcf4fc8f..74d07224 100644
--- a/plugins/python/python.c
+++ b/plugins/python/python.c
@@ -57,7 +57,7 @@
 #include <sys/types.h>
 
 #ifdef WIN32
-#include "../../src/common/dirent-win32.h"
+#include "../../src/dirent/dirent-win32.h"
 #include "../../config.h"
 #else
 #include <unistd.h>
diff --git a/plugins/python/python.def b/plugins/python/python.def
new file mode 100644
index 00000000..5797636b
--- /dev/null
+++ b/plugins/python/python.def
@@ -0,0 +1,4 @@
+EXPORTS 
+xchat_plugin_init 
+xchat_plugin_deinit 
+xchat_plugin_get_info 
diff --git a/plugins/python/python.vcxproj b/plugins/python/python.vcxproj
new file mode 100644
index 00000000..de0fadea
--- /dev/null
+++ b/plugins/python/python.vcxproj
@@ -0,0 +1,65 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup Label="ProjectConfigurations">
+    <ProjectConfiguration Include="Release|Win32">
+      <Configuration>Release</Configuration>
+      <Platform>Win32</Platform>
+    </ProjectConfiguration>
+  </ItemGroup>
+  <PropertyGroup Label="Globals">
+    <ProjectGuid>{19C52A0A-A790-409E-A28A-9745FF990F5C}</ProjectGuid>
+    <Keyword>Win32Proj</Keyword>
+    <RootNamespace>python</RootNamespace>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
+  <ImportGroup Label="ExtensionSettings">
+  </ImportGroup>
+  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
+  <PropertyGroup Label="UserMacros" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>$(PythonOutput)</TargetName>
+  </PropertyGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;PYTHON_EXPORTS;$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <AdditionalIncludeDirectories>$(Glib);$(PythonPath)\include;..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <ModuleDefinitionFile>python.def</ModuleDefinitionFile>
+      <AdditionalDependencies>"$(PythonLib).lib";$(DepLibs);dirent-win32.lib;%(AdditionalDependencies)</AdditionalDependencies>
+      <AdditionalLibraryDirectories>$(DepsRoot)\lib;$(OutDir);$(PythonPath)\libs;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+    </Link>
+  </ItemDefinitionGroup>
+  <ItemGroup>
+    <None Include="python.def" />
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="python.c" />
+  </ItemGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
+  <ImportGroup Label="ExtensionTargets">
+  </ImportGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/python/python.vcxproj.filters b/plugins/python/python.vcxproj.filters
new file mode 100644
index 00000000..d56e53b6
--- /dev/null
+++ b/plugins/python/python.vcxproj.filters
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup>
+    <Filter Include="Source Files">
+      <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
+      <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
+    </Filter>
+    <Filter Include="Resource Files">
+      <UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
+      <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
+    </Filter>
+  </ItemGroup>
+  <ItemGroup>
+    <None Include="python.def">
+      <Filter>Resource Files</Filter>
+    </None>
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="python.c">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+  </ItemGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/tcl/tcl.def b/plugins/tcl/tcl.def
new file mode 100644
index 00000000..5797636b
--- /dev/null
+++ b/plugins/tcl/tcl.def
@@ -0,0 +1,4 @@
+EXPORTS 
+xchat_plugin_init 
+xchat_plugin_deinit 
+xchat_plugin_get_info 
diff --git a/plugins/tcl/tcl.vcxproj b/plugins/tcl/tcl.vcxproj
new file mode 100644
index 00000000..fa69aa33
--- /dev/null
+++ b/plugins/tcl/tcl.vcxproj
@@ -0,0 +1,69 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup Label="ProjectConfigurations">
+    <ProjectConfiguration Include="Release|Win32">
+      <Configuration>Release</Configuration>
+      <Platform>Win32</Platform>
+    </ProjectConfiguration>
+  </ItemGroup>
+  <ItemGroup>
+    <ClInclude Include="printevents.h" />
+    <ClInclude Include="tclplugin.h" />
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="tclplugin.c" />
+  </ItemGroup>
+  <ItemGroup>
+    <None Include="tcl.def" />
+  </ItemGroup>
+  <PropertyGroup Label="Globals">
+    <ProjectGuid>{2773666A-8CFC-4533-A043-EAD59F16A1C7}</ProjectGuid>
+    <Keyword>Win32Proj</Keyword>
+    <RootNamespace>tcl</RootNamespace>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
+  <ImportGroup Label="ExtensionSettings">
+  </ImportGroup>
+  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
+  <PropertyGroup Label="UserMacros" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>$(TclOutput)</TargetName>
+  </PropertyGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>NotUsing</PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;TCL_EXPORTS;TCL_DLL="$(TclLib).dll";$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <AdditionalIncludeDirectories>$(TclPath)\include;..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <AdditionalLibraryDirectories>$(TclPath)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+      <AdditionalDependencies>"$(TclLib).lib";%(AdditionalDependencies)</AdditionalDependencies>
+      <ModuleDefinitionFile>tcl.def</ModuleDefinitionFile>
+      <DelayLoadDLLs>$(TclLib).dll;%(DelayLoadDLLs)</DelayLoadDLLs>
+    </Link>
+  </ItemDefinitionGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
+  <ImportGroup Label="ExtensionTargets">
+  </ImportGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/tcl/tcl.vcxproj.filters b/plugins/tcl/tcl.vcxproj.filters
new file mode 100644
index 00000000..43f63d84
--- /dev/null
+++ b/plugins/tcl/tcl.vcxproj.filters
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup>
+    <Filter Include="Source Files">
+      <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
+      <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
+    </Filter>
+    <Filter Include="Header Files">
+      <UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
+      <Extensions>h;hpp;hxx;hm;inl;inc;xsd</Extensions>
+    </Filter>
+    <Filter Include="Resource Files">
+      <UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
+      <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
+    </Filter>
+  </ItemGroup>
+  <ItemGroup>
+    <ClInclude Include="printevents.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="tclplugin.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="tclplugin.c">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+  </ItemGroup>
+  <ItemGroup>
+    <None Include="tcl.def">
+      <Filter>Resource Files</Filter>
+    </None>
+  </ItemGroup>
+</Project>
\ No newline at end of file
diff --git a/src/fe-gtk/fe-gtk.vcxproj b/src/fe-gtk/fe-gtk.vcxproj
index deb76c27..68390d03 100644
--- a/src/fe-gtk/fe-gtk.vcxproj
+++ b/src/fe-gtk/fe-gtk.vcxproj
@@ -48,8 +48,8 @@
       <GenerateDebugInformation>true</GenerateDebugInformation>
       <EnableCOMDATFolding>true</EnableCOMDATFolding>
       <OptimizeReferences>true</OptimizeReferences>
-      <AdditionalLibraryDirectories>$(DepsRoot)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
-      <AdditionalDependencies>$(DepLibs);"$(OutDir)\common.lib";"$(OutDir)\dirent-win32.lib";%(AdditionalDependencies)</AdditionalDependencies>
+      <AdditionalLibraryDirectories>$(DepsRoot)\lib;$(OutDir);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+      <AdditionalDependencies>$(DepLibs);common.lib;dirent-win32.lib;%(AdditionalDependencies)</AdditionalDependencies>
       <EntryPointSymbol>mainCRTStartup</EntryPointSymbol>
     </Link>
   </ItemDefinitionGroup>
diff --git a/src/pixmaps/pixmaps.vcxproj b/src/pixmaps/pixmaps.vcxproj
index 39151d5a..ba88104d 100644
--- a/src/pixmaps/pixmaps.vcxproj
+++ b/src/pixmaps/pixmaps.vcxproj
@@ -47,7 +47,7 @@
       <OptimizeReferences>true</OptimizeReferences>
     </Link>
     <PostBuildEvent>
-      <Command>"$(DepsRoot)\bin\gdk-pixbuf-csource" --build-list $(Pixmaps) &gt; "$(SolutionDir)\..\src\pixmaps\inline_pngs.h"</Command>
+      <Command>"$(DepsRoot)\bin\gdk-pixbuf-csource" --build-list $(Pixmaps) > "$(SolutionDir)\..\src\pixmaps\inline_pngs.h"</Command>
     </PostBuildEvent>
   </ItemDefinitionGroup>
   <ItemGroup>
diff --git a/win32/xchat.props b/win32/xchat.props
index 09f26df0..32ed807d 100644
--- a/win32/xchat.props
+++ b/win32/xchat.props
@@ -3,10 +3,34 @@
   <ImportGroup Label="PropertySheets" />
   <PropertyGroup Label="UserMacros">
     <!-- SPECIFY YOUR ROOT DEPENDENCY DIRECTORY ROOT HERE -->
-    <YourDepsFolder>c:\mozilla-build\deps root</YourDepsFolder>
+    <YourDepsPath>c:\mozilla-build\xchat deps</YourDepsPath>
+    <YourGendefPath>c:\mozilla-build\gendef path</YourGendefPath>
+    <YourTclPath>c:\mozilla-build\tcl path</YourTclPath>
+    <YourPerl512Path>c:\mozilla-build\perl512 path</YourPerl512Path>
+    <YourPerl514Path>c:\mozilla-build\perl514 path</YourPerl514Path>
+    <YourPerl516Path>c:\mozilla-build\perl516 path</YourPerl516Path>
+    <YourPythonPath>c:\mozilla-build\python path</YourPythonPath>
     <!-- YOU SHOULDN'T TOUCH ANYTHING BELOW -->
-    <OwnFlags>_CRT_SECURE_NO_WARNINGS;G_DISABLE_CAST_CHECKS;G_DISABLE_DEPRECATED;GDK_PIXBUF_DISABLE_DEPRECATED;GDK_DISABLE_DEPRECATED;HAVE_STRTOULL;strtoull=_strtoui64;strcasecmp=stricmp;strncasecmp=strnicmp</OwnFlags>
-    <DepsRoot>$(YourDepsFolder)\$(PlatformName)</DepsRoot>
+    <OwnFlags>G_DISABLE_CAST_CHECKS;G_DISABLE_DEPRECATED;GDK_PIXBUF_DISABLE_DEPRECATED;GDK_DISABLE_DEPRECATED;HAVE_STRTOULL;strtoull=_strtoui64;strcasecmp=stricmp;strncasecmp=strnicmp;__inline__=__inline;</OwnFlags>
+    <DepsRoot>$(YourDepsPath)\$(PlatformName)</DepsRoot>
+    <GendefPath>$(YourGendefPath)</GendefPath>
+    <LuaLib>lua51</LuaLib>
+    <LuaOutput>xclua</LuaOutput>
+    <TclPath>$(YourTclPath)\$(PlatformName)</TclPath>
+    <TclLib>tcl85</TclLib>
+    <TclOutput>xctcl</TclOutput>
+    <Perl512Path>$(YourPerl512Path)\$(PlatformName)</Perl512Path>
+    <Perl512Lib>perl512</Perl512Lib>
+    <Perl512Output>xcperl-512</Perl512Output>
+    <Perl514Path>$(YourPerl514Path)\$(PlatformName)</Perl514Path>
+    <Perl514Lib>perl514</Perl514Lib>
+    <Perl514Output>xcperl-514</Perl514Output>
+    <Perl516Path>$(YourPerl516Path)\$(PlatformName)</Perl516Path>
+    <Perl516Lib>perl516</Perl516Lib>
+    <Perl516Output>xcperl-516</Perl516Output>
+    <PythonPath>$(YourPythonPath)\$(PlatformName)</PythonPath>
+    <PythonLib>python27</PythonLib>
+    <PythonOutput>xcpython</PythonOutput>
     <Glib>$(DepsRoot)\include\glib-2.0;$(DepsRoot)\lib\glib-2.0\include;$(DepsRoot)\include\libxml2</Glib>
     <Gtk>$(DepsRoot)\include\gtk-2.0;$(DepsRoot)\lib\gtk-2.0\include;$(DepsRoot)\include\atk-1.0;$(DepsRoot)\include\cairo;$(DepsRoot)\include\pango-1.0;$(DepsRoot)\include\gdk-pixbuf-2.0</Gtk>
     <Pixmaps>bookpng "$(SolutionDir)\..\src\pixmaps\book.png" hoppng "$(SolutionDir)\..\src\pixmaps\hop.png" oppng "$(SolutionDir)\..\src\pixmaps\op.png" purplepng "$(SolutionDir)\..\src\pixmaps\purple.png" redpng "$(SolutionDir)\..\src\pixmaps\red.png" trayfilepng "$(SolutionDir)\..\src\pixmaps\fileoffer.png" trayhilightpng "$(SolutionDir)\..\src\pixmaps\highlight.png" traymsgpng "$(SolutionDir)\..\src\pixmaps\message.png" voicepng "$(SolutionDir)\..\src\pixmaps\voice.png" xchatpng "$(SolutionDir)\..\xchat.png"</Pixmaps>
diff --git a/win32/xchat.sln b/win32/xchat.sln
index 430e3d60..7aa6b029 100644
--- a/win32/xchat.sln
+++ b/win32/xchat.sln
@@ -23,6 +23,32 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "fe-text", "..\src\fe-text\f
 		{98B56DF9-E4F1-4696-A565-5F7823CF214D} = {98B56DF9-E4F1-4696-A565-5F7823CF214D}
 	EndProjectSection
 EndProject
+Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "xchat", "xchat", "{AAACEB12-9475-410E-AF5A-FDFF907E9043}"
+EndProject
+Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "plugins", "plugins", "{561126F4-FA18-45FC-A2BF-8F858F161D6D}"
+EndProject
+Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "scripting", "scripting", "{D237DA6B-BD5F-46C0-8BEA-50E9A1340240}"
+EndProject
+Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "common", "common", "{BB051F0F-A841-4A9A-BAF6-51DD9866D65A}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "tcl", "..\plugins\tcl\tcl.vcxproj", "{2773666A-8CFC-4533-A043-EAD59F16A1C7}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "perl-512", "..\plugins\perl\perl-512.vcxproj", "{987E9374-98A1-44BA-946F-D3472D7A7055}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "perl-514", "..\plugins\perl\perl-514.vcxproj", "{C4C9FA6F-F990-4C7B-85F6-CD8F4F5728F0}"
+	ProjectSection(ProjectDependencies) = postProject
+		{987E9374-98A1-44BA-946F-D3472D7A7055} = {987E9374-98A1-44BA-946F-D3472D7A7055}
+	EndProjectSection
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "perl-516", "..\plugins\perl\perl-516.vcxproj", "{58654438-F674-42F7-88FA-73EF90AD80B1}"
+	ProjectSection(ProjectDependencies) = postProject
+		{C4C9FA6F-F990-4C7B-85F6-CD8F4F5728F0} = {C4C9FA6F-F990-4C7B-85F6-CD8F4F5728F0}
+	EndProjectSection
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "python", "..\plugins\python\python.vcxproj", "{19C52A0A-A790-409E-A28A-9745FF990F5C}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "lua", "..\plugins\lua\lua.vcxproj", "{646B4316-C8B8-4DB6-B6AE-E586929E5729}"
+EndProject
 Global
 	GlobalSection(SolutionConfigurationPlatforms) = preSolution
 		Release|Win32 = Release|Win32
@@ -40,8 +66,34 @@ Global
 		{E4BDB4C8-2335-415A-ACEE-BA88B19BFE82}.Release|Win32.Build.0 = Release|Win32
 		{E93E1255-95D1-4B08-8FDF-B53CC6A21280}.Release|Win32.ActiveCfg = Release|Win32
 		{E93E1255-95D1-4B08-8FDF-B53CC6A21280}.Release|Win32.Build.0 = Release|Win32
+		{2773666A-8CFC-4533-A043-EAD59F16A1C7}.Release|Win32.ActiveCfg = Release|Win32
+		{2773666A-8CFC-4533-A043-EAD59F16A1C7}.Release|Win32.Build.0 = Release|Win32
+		{987E9374-98A1-44BA-946F-D3472D7A7055}.Release|Win32.ActiveCfg = Release|Win32
+		{987E9374-98A1-44BA-946F-D3472D7A7055}.Release|Win32.Build.0 = Release|Win32
+		{C4C9FA6F-F990-4C7B-85F6-CD8F4F5728F0}.Release|Win32.ActiveCfg = Release|Win32
+		{C4C9FA6F-F990-4C7B-85F6-CD8F4F5728F0}.Release|Win32.Build.0 = Release|Win32
+		{58654438-F674-42F7-88FA-73EF90AD80B1}.Release|Win32.ActiveCfg = Release|Win32
+		{58654438-F674-42F7-88FA-73EF90AD80B1}.Release|Win32.Build.0 = Release|Win32
+		{19C52A0A-A790-409E-A28A-9745FF990F5C}.Release|Win32.ActiveCfg = Release|Win32
+		{19C52A0A-A790-409E-A28A-9745FF990F5C}.Release|Win32.Build.0 = Release|Win32
+		{646B4316-C8B8-4DB6-B6AE-E586929E5729}.Release|Win32.ActiveCfg = Release|Win32
+		{646B4316-C8B8-4DB6-B6AE-E586929E5729}.Release|Win32.Build.0 = Release|Win32
 	EndGlobalSection
 	GlobalSection(SolutionProperties) = preSolution
 		HideSolutionNode = FALSE
 	EndGlobalSection
+	GlobalSection(NestedProjects) = preSolution
+		{626DA61C-FA8B-474C-B2F5-72AD9DFEE642} = {AAACEB12-9475-410E-AF5A-FDFF907E9043}
+		{E4BDB4C8-2335-415A-ACEE-BA88B19BFE82} = {AAACEB12-9475-410E-AF5A-FDFF907E9043}
+		{E93E1255-95D1-4B08-8FDF-B53CC6A21280} = {AAACEB12-9475-410E-AF5A-FDFF907E9043}
+		{87554B59-006C-4D94-9714-897B27067BA3} = {AAACEB12-9475-410E-AF5A-FDFF907E9043}
+		{6CD3647E-4541-4849-9DD7-C8816665AE42} = {BB051F0F-A841-4A9A-BAF6-51DD9866D65A}
+		{98B56DF9-E4F1-4696-A565-5F7823CF214D} = {BB051F0F-A841-4A9A-BAF6-51DD9866D65A}
+		{2773666A-8CFC-4533-A043-EAD59F16A1C7} = {D237DA6B-BD5F-46C0-8BEA-50E9A1340240}
+		{987E9374-98A1-44BA-946F-D3472D7A7055} = {D237DA6B-BD5F-46C0-8BEA-50E9A1340240}
+		{C4C9FA6F-F990-4C7B-85F6-CD8F4F5728F0} = {D237DA6B-BD5F-46C0-8BEA-50E9A1340240}
+		{58654438-F674-42F7-88FA-73EF90AD80B1} = {D237DA6B-BD5F-46C0-8BEA-50E9A1340240}
+		{19C52A0A-A790-409E-A28A-9745FF990F5C} = {D237DA6B-BD5F-46C0-8BEA-50E9A1340240}
+		{646B4316-C8B8-4DB6-B6AE-E586929E5729} = {D237DA6B-BD5F-46C0-8BEA-50E9A1340240}
+	EndGlobalSection
 EndGlobal
-- 
cgit 1.4.1


From a673109c495916f4198b216a0e52aa9d6b986a8f Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sun, 10 Jun 2012 14:19:40 +0200
Subject: Add all plugins to solution except WMPA

---
 plugins/checksum/checksum.def             |   3 +
 plugins/checksum/checksum.vcxproj         |  65 ++++++++++++++++++
 plugins/checksum/checksum.vcxproj.filters |  23 +++++++
 plugins/dns/dns.def                       |   3 +
 plugins/dns/dns.vcxproj                   |  69 +++++++++++++++++++
 plugins/dns/dns.vcxproj.filters           |  35 ++++++++++
 plugins/doat/doat.def                     |   3 +
 plugins/doat/doat.vcxproj                 |  63 +++++++++++++++++
 plugins/doat/doat.vcxproj.filters         |  23 +++++++
 plugins/exec/exec.def                     |   3 +
 plugins/exec/exec.vcxproj                 |  63 +++++++++++++++++
 plugins/exec/exec.vcxproj.filters         |  23 +++++++
 plugins/fishlim/fishlim.def               |   4 ++
 plugins/fishlim/fishlim.vcxproj           |  77 +++++++++++++++++++++
 plugins/fishlim/fishlim.vcxproj.filters   |  59 ++++++++++++++++
 plugins/lua/lua.vcxproj                   |   6 +-
 plugins/mpcinfo/mpcinfo.def               |   3 +
 plugins/mpcinfo/mpcinfo.vcxproj           |  63 +++++++++++++++++
 plugins/mpcinfo/mpcinfo.vcxproj.filters   |  23 +++++++
 plugins/upd/upd.def                       |   3 +
 plugins/upd/upd.vcxproj                   |  65 ++++++++++++++++++
 plugins/upd/upd.vcxproj.filters           |  23 +++++++
 plugins/winamp/winamp.def                 |   3 +
 plugins/winamp/winamp.vcxproj             |  63 +++++++++++++++++
 plugins/winamp/winamp.vcxproj.filters     |  23 +++++++
 plugins/winsys/winsys.def                 |   3 +
 plugins/winsys/winsys.vcxproj             |  66 ++++++++++++++++++
 plugins/winsys/winsys.vcxproj.filters     |  23 +++++++
 plugins/xsasl/xsasl.def                   |   3 +
 plugins/xsasl/xsasl.vcxproj               |  65 ++++++++++++++++++
 plugins/xsasl/xsasl.vcxproj.filters       |  23 +++++++
 plugins/xtray/xtray.def                   |   3 +
 plugins/xtray/xtray.vcxproj               |  91 +++++++++++++++++++++++++
 plugins/xtray/xtray.vcxproj.filters       | 109 ++++++++++++++++++++++++++++++
 src/version/version.vcxproj               |   3 +-
 win32/xchat.sln                           |  66 ++++++++++++++++++
 36 files changed, 1244 insertions(+), 2 deletions(-)
 create mode 100644 plugins/checksum/checksum.def
 create mode 100644 plugins/checksum/checksum.vcxproj
 create mode 100644 plugins/checksum/checksum.vcxproj.filters
 create mode 100644 plugins/dns/dns.def
 create mode 100644 plugins/dns/dns.vcxproj
 create mode 100644 plugins/dns/dns.vcxproj.filters
 create mode 100644 plugins/doat/doat.def
 create mode 100644 plugins/doat/doat.vcxproj
 create mode 100644 plugins/doat/doat.vcxproj.filters
 create mode 100644 plugins/exec/exec.def
 create mode 100644 plugins/exec/exec.vcxproj
 create mode 100644 plugins/exec/exec.vcxproj.filters
 create mode 100644 plugins/fishlim/fishlim.def
 create mode 100644 plugins/fishlim/fishlim.vcxproj
 create mode 100644 plugins/fishlim/fishlim.vcxproj.filters
 create mode 100644 plugins/mpcinfo/mpcinfo.def
 create mode 100644 plugins/mpcinfo/mpcinfo.vcxproj
 create mode 100644 plugins/mpcinfo/mpcinfo.vcxproj.filters
 create mode 100644 plugins/upd/upd.def
 create mode 100644 plugins/upd/upd.vcxproj
 create mode 100644 plugins/upd/upd.vcxproj.filters
 create mode 100644 plugins/winamp/winamp.def
 create mode 100644 plugins/winamp/winamp.vcxproj
 create mode 100644 plugins/winamp/winamp.vcxproj.filters
 create mode 100644 plugins/winsys/winsys.def
 create mode 100644 plugins/winsys/winsys.vcxproj
 create mode 100644 plugins/winsys/winsys.vcxproj.filters
 create mode 100644 plugins/xsasl/xsasl.def
 create mode 100644 plugins/xsasl/xsasl.vcxproj
 create mode 100644 plugins/xsasl/xsasl.vcxproj.filters
 create mode 100644 plugins/xtray/xtray.def
 create mode 100644 plugins/xtray/xtray.vcxproj
 create mode 100644 plugins/xtray/xtray.vcxproj.filters

(limited to 'plugins')

diff --git a/plugins/checksum/checksum.def b/plugins/checksum/checksum.def
new file mode 100644
index 00000000..77670bf2
--- /dev/null
+++ b/plugins/checksum/checksum.def
@@ -0,0 +1,3 @@
+EXPORTS 
+xchat_plugin_init 
+xchat_plugin_deinit 
diff --git a/plugins/checksum/checksum.vcxproj b/plugins/checksum/checksum.vcxproj
new file mode 100644
index 00000000..cbfa2a2d
--- /dev/null
+++ b/plugins/checksum/checksum.vcxproj
@@ -0,0 +1,65 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup Label="ProjectConfigurations">
+    <ProjectConfiguration Include="Release|Win32">
+      <Configuration>Release</Configuration>
+      <Platform>Win32</Platform>
+    </ProjectConfiguration>
+  </ItemGroup>
+  <PropertyGroup Label="Globals">
+    <ProjectGuid>{5EF7F47D-D09C-43C4-BF64-B28B11A0FF91}</ProjectGuid>
+    <Keyword>Win32Proj</Keyword>
+    <RootNamespace>checksum</RootNamespace>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
+  <ImportGroup Label="ExtensionSettings">
+  </ImportGroup>
+  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
+  <PropertyGroup Label="UserMacros" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xcchecksum</TargetName>
+  </PropertyGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;CHECKSUM_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <AdditionalIncludeDirectories>$(DepsRoot)\include;..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <ModuleDefinitionFile>checksum.def</ModuleDefinitionFile>
+      <AdditionalLibraryDirectories>$(DepsRoot)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+      <AdditionalDependencies>$(DepLibs);%(AdditionalDependencies)</AdditionalDependencies>
+    </Link>
+  </ItemDefinitionGroup>
+  <ItemGroup>
+    <ClCompile Include="checksum.c" />
+  </ItemGroup>
+  <ItemGroup>
+    <None Include="checksum.def" />
+  </ItemGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
+  <ImportGroup Label="ExtensionTargets">
+  </ImportGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/checksum/checksum.vcxproj.filters b/plugins/checksum/checksum.vcxproj.filters
new file mode 100644
index 00000000..e6ef5e81
--- /dev/null
+++ b/plugins/checksum/checksum.vcxproj.filters
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup>
+    <Filter Include="Source Files">
+      <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
+      <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
+    </Filter>
+    <Filter Include="Resource Files">
+      <UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
+      <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
+    </Filter>
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="checksum.c">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+  </ItemGroup>
+  <ItemGroup>
+    <None Include="checksum.def">
+      <Filter>Resource Files</Filter>
+    </None>
+  </ItemGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/dns/dns.def b/plugins/dns/dns.def
new file mode 100644
index 00000000..77670bf2
--- /dev/null
+++ b/plugins/dns/dns.def
@@ -0,0 +1,3 @@
+EXPORTS 
+xchat_plugin_init 
+xchat_plugin_deinit 
diff --git a/plugins/dns/dns.vcxproj b/plugins/dns/dns.vcxproj
new file mode 100644
index 00000000..b98c778f
--- /dev/null
+++ b/plugins/dns/dns.vcxproj
@@ -0,0 +1,69 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup Label="ProjectConfigurations">
+    <ProjectConfiguration Include="Release|Win32">
+      <Configuration>Release</Configuration>
+      <Platform>Win32</Platform>
+    </ProjectConfiguration>
+  </ItemGroup>
+  <PropertyGroup Label="Globals">
+    <ProjectGuid>{3786FA8C-3E76-45E3-984E-FCCFF44729C9}</ProjectGuid>
+    <Keyword>Win32Proj</Keyword>
+    <RootNamespace>dns</RootNamespace>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
+  <ImportGroup Label="ExtensionSettings">
+  </ImportGroup>
+  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
+  <PropertyGroup Label="UserMacros" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xcdns</TargetName>
+  </PropertyGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;DNS_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <AdditionalIncludeDirectories>..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <AdditionalLibraryDirectories>$(DepsRoot)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+      <AdditionalDependencies>$(DepLibs);%(AdditionalDependencies)</AdditionalDependencies>
+      <ModuleDefinitionFile>dns.def</ModuleDefinitionFile>
+    </Link>
+  </ItemDefinitionGroup>
+  <ItemGroup>
+    <None Include="dns.def" />
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="dns.c" />
+    <ClCompile Include="thread.c" />
+  </ItemGroup>
+  <ItemGroup>
+    <ClInclude Include="thread.h" />
+  </ItemGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
+  <ImportGroup Label="ExtensionTargets">
+  </ImportGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/dns/dns.vcxproj.filters b/plugins/dns/dns.vcxproj.filters
new file mode 100644
index 00000000..a49dc1e2
--- /dev/null
+++ b/plugins/dns/dns.vcxproj.filters
@@ -0,0 +1,35 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup>
+    <Filter Include="Source Files">
+      <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
+      <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
+    </Filter>
+    <Filter Include="Header Files">
+      <UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
+      <Extensions>h;hpp;hxx;hm;inl;inc;xsd</Extensions>
+    </Filter>
+    <Filter Include="Resource Files">
+      <UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
+      <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
+    </Filter>
+  </ItemGroup>
+  <ItemGroup>
+    <None Include="dns.def">
+      <Filter>Resource Files</Filter>
+    </None>
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="dns.c">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="thread.c">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+  </ItemGroup>
+  <ItemGroup>
+    <ClInclude Include="thread.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+  </ItemGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/doat/doat.def b/plugins/doat/doat.def
new file mode 100644
index 00000000..77670bf2
--- /dev/null
+++ b/plugins/doat/doat.def
@@ -0,0 +1,3 @@
+EXPORTS 
+xchat_plugin_init 
+xchat_plugin_deinit 
diff --git a/plugins/doat/doat.vcxproj b/plugins/doat/doat.vcxproj
new file mode 100644
index 00000000..f0168a6b
--- /dev/null
+++ b/plugins/doat/doat.vcxproj
@@ -0,0 +1,63 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup Label="ProjectConfigurations">
+    <ProjectConfiguration Include="Release|Win32">
+      <Configuration>Release</Configuration>
+      <Platform>Win32</Platform>
+    </ProjectConfiguration>
+  </ItemGroup>
+  <PropertyGroup Label="Globals">
+    <ProjectGuid>{4980AF24-9D42-427D-A8E6-0DF3B97C455D}</ProjectGuid>
+    <Keyword>Win32Proj</Keyword>
+    <RootNamespace>doat</RootNamespace>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
+  <ImportGroup Label="ExtensionSettings">
+  </ImportGroup>
+  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
+  <PropertyGroup Label="UserMacros" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xcdoat</TargetName>
+  </PropertyGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;DOAT_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <AdditionalIncludeDirectories>..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <ModuleDefinitionFile>doat.def</ModuleDefinitionFile>
+    </Link>
+  </ItemDefinitionGroup>
+  <ItemGroup>
+    <ClCompile Include="doat.c" />
+  </ItemGroup>
+  <ItemGroup>
+    <None Include="doat.def" />
+  </ItemGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
+  <ImportGroup Label="ExtensionTargets">
+  </ImportGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/doat/doat.vcxproj.filters b/plugins/doat/doat.vcxproj.filters
new file mode 100644
index 00000000..43ea8307
--- /dev/null
+++ b/plugins/doat/doat.vcxproj.filters
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup>
+    <Filter Include="Source Files">
+      <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
+      <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
+    </Filter>
+    <Filter Include="Resource Files">
+      <UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
+      <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
+    </Filter>
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="doat.c">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+  </ItemGroup>
+  <ItemGroup>
+    <None Include="doat.def">
+      <Filter>Resource Files</Filter>
+    </None>
+  </ItemGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/exec/exec.def b/plugins/exec/exec.def
new file mode 100644
index 00000000..77670bf2
--- /dev/null
+++ b/plugins/exec/exec.def
@@ -0,0 +1,3 @@
+EXPORTS 
+xchat_plugin_init 
+xchat_plugin_deinit 
diff --git a/plugins/exec/exec.vcxproj b/plugins/exec/exec.vcxproj
new file mode 100644
index 00000000..cef4049c
--- /dev/null
+++ b/plugins/exec/exec.vcxproj
@@ -0,0 +1,63 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup Label="ProjectConfigurations">
+    <ProjectConfiguration Include="Release|Win32">
+      <Configuration>Release</Configuration>
+      <Platform>Win32</Platform>
+    </ProjectConfiguration>
+  </ItemGroup>
+  <PropertyGroup Label="Globals">
+    <ProjectGuid>{17E4BE39-76F7-4A06-AD21-EFD0C5091F76}</ProjectGuid>
+    <Keyword>Win32Proj</Keyword>
+    <RootNamespace>exec</RootNamespace>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
+  <ImportGroup Label="ExtensionSettings">
+  </ImportGroup>
+  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
+  <PropertyGroup Label="UserMacros" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xcexec</TargetName>
+  </PropertyGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;EXEC_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+      <AdditionalIncludeDirectories>..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <ModuleDefinitionFile>exec.def</ModuleDefinitionFile>
+    </Link>
+  </ItemDefinitionGroup>
+  <ItemGroup>
+    <None Include="exec.def" />
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="exec.c" />
+  </ItemGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
+  <ImportGroup Label="ExtensionTargets">
+  </ImportGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/exec/exec.vcxproj.filters b/plugins/exec/exec.vcxproj.filters
new file mode 100644
index 00000000..f800df93
--- /dev/null
+++ b/plugins/exec/exec.vcxproj.filters
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup>
+    <Filter Include="Source Files">
+      <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
+      <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
+    </Filter>
+    <Filter Include="Resource Files">
+      <UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
+      <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
+    </Filter>
+  </ItemGroup>
+  <ItemGroup>
+    <None Include="exec.def">
+      <Filter>Resource Files</Filter>
+    </None>
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="exec.c">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+  </ItemGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/fishlim/fishlim.def b/plugins/fishlim/fishlim.def
new file mode 100644
index 00000000..5797636b
--- /dev/null
+++ b/plugins/fishlim/fishlim.def
@@ -0,0 +1,4 @@
+EXPORTS 
+xchat_plugin_init 
+xchat_plugin_deinit 
+xchat_plugin_get_info 
diff --git a/plugins/fishlim/fishlim.vcxproj b/plugins/fishlim/fishlim.vcxproj
new file mode 100644
index 00000000..1cf5293f
--- /dev/null
+++ b/plugins/fishlim/fishlim.vcxproj
@@ -0,0 +1,77 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup Label="ProjectConfigurations">
+    <ProjectConfiguration Include="Release|Win32">
+      <Configuration>Release</Configuration>
+      <Platform>Win32</Platform>
+    </ProjectConfiguration>
+  </ItemGroup>
+  <PropertyGroup Label="Globals">
+    <ProjectGuid>{3C4F42FC-292A-420B-B63D-C03DFBDD8E4E}</ProjectGuid>
+    <Keyword>Win32Proj</Keyword>
+    <RootNamespace>fishlim</RootNamespace>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
+  <ImportGroup Label="ExtensionSettings">
+  </ImportGroup>
+  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
+  <PropertyGroup Label="UserMacros" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xcfishlim</TargetName>
+  </PropertyGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;FISHLIM_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+      <AdditionalIncludeDirectories>$(DepsRoot)\include;$(Glib);..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <ModuleDefinitionFile>fishlim.def</ModuleDefinitionFile>
+      <AdditionalLibraryDirectories>$(DepsRoot)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+      <AdditionalDependencies>$(DepLibs);%(AdditionalDependencies)</AdditionalDependencies>
+    </Link>
+  </ItemDefinitionGroup>
+  <ItemGroup>
+    <None Include="fishlim.def" />
+  </ItemGroup>
+  <ItemGroup>
+    <ClInclude Include="bool.h" />
+    <ClInclude Include="fish.h" />
+    <ClInclude Include="irc.h" />
+    <ClInclude Include="keystore.h" />
+    <ClInclude Include="misc.h" />
+    <ClInclude Include="plugin_xchat.h" />
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="fish.c" />
+    <ClCompile Include="irc.c" />
+    <ClCompile Include="keystore.c" />
+    <ClCompile Include="misc.c" />
+    <ClCompile Include="plugin_xchat.c" />
+  </ItemGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
+  <ImportGroup Label="ExtensionTargets">
+  </ImportGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/fishlim/fishlim.vcxproj.filters b/plugins/fishlim/fishlim.vcxproj.filters
new file mode 100644
index 00000000..72e9f017
--- /dev/null
+++ b/plugins/fishlim/fishlim.vcxproj.filters
@@ -0,0 +1,59 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup>
+    <Filter Include="Source Files">
+      <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
+      <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
+    </Filter>
+    <Filter Include="Header Files">
+      <UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
+      <Extensions>h;hpp;hxx;hm;inl;inc;xsd</Extensions>
+    </Filter>
+    <Filter Include="Resource Files">
+      <UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
+      <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
+    </Filter>
+  </ItemGroup>
+  <ItemGroup>
+    <None Include="fishlim.def">
+      <Filter>Resource Files</Filter>
+    </None>
+  </ItemGroup>
+  <ItemGroup>
+    <ClInclude Include="bool.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="fish.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="irc.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="keystore.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="misc.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="plugin_xchat.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="fish.c">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="irc.c">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="keystore.c">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="misc.c">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="plugin_xchat.c">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+  </ItemGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/lua/lua.vcxproj b/plugins/lua/lua.vcxproj
index d78a1e35..69a8e4ea 100644
--- a/plugins/lua/lua.vcxproj
+++ b/plugins/lua/lua.vcxproj
@@ -33,7 +33,7 @@
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
-      <WarningLevel>Level3</WarningLevel>
+      <WarningLevel>Level1</WarningLevel>
       <PrecompiledHeader>
       </PrecompiledHeader>
       <Optimization>MaxSpeed</Optimization>
@@ -59,7 +59,11 @@
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;$(OwnFlags);snprintf=g_snprintf;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
     </ClCompile>
+    <Link>
+      <ModuleDefinitionFile>lua.def</ModuleDefinitionFile>
+    </Link>
   </ItemDefinitionGroup>
   <ItemGroup>
     <None Include="lua.def" />
diff --git a/plugins/mpcinfo/mpcinfo.def b/plugins/mpcinfo/mpcinfo.def
new file mode 100644
index 00000000..77670bf2
--- /dev/null
+++ b/plugins/mpcinfo/mpcinfo.def
@@ -0,0 +1,3 @@
+EXPORTS 
+xchat_plugin_init 
+xchat_plugin_deinit 
diff --git a/plugins/mpcinfo/mpcinfo.vcxproj b/plugins/mpcinfo/mpcinfo.vcxproj
new file mode 100644
index 00000000..04182d50
--- /dev/null
+++ b/plugins/mpcinfo/mpcinfo.vcxproj
@@ -0,0 +1,63 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup Label="ProjectConfigurations">
+    <ProjectConfiguration Include="Release|Win32">
+      <Configuration>Release</Configuration>
+      <Platform>Win32</Platform>
+    </ProjectConfiguration>
+  </ItemGroup>
+  <PropertyGroup Label="Globals">
+    <ProjectGuid>{B0E36D93-CA2A-49FE-9EB9-9C96C6016EEC}</ProjectGuid>
+    <Keyword>Win32Proj</Keyword>
+    <RootNamespace>mpcinfo</RootNamespace>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
+  <ImportGroup Label="ExtensionSettings">
+  </ImportGroup>
+  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
+  <PropertyGroup Label="UserMacros" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xcmpcinfo</TargetName>
+  </PropertyGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;MPCINFO_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+      <AdditionalIncludeDirectories>..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <ModuleDefinitionFile>mpcinfo.def</ModuleDefinitionFile>
+    </Link>
+  </ItemDefinitionGroup>
+  <ItemGroup>
+    <None Include="mpcinfo.def" />
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="mpcInfo.c" />
+  </ItemGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
+  <ImportGroup Label="ExtensionTargets">
+  </ImportGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/mpcinfo/mpcinfo.vcxproj.filters b/plugins/mpcinfo/mpcinfo.vcxproj.filters
new file mode 100644
index 00000000..7e22eb30
--- /dev/null
+++ b/plugins/mpcinfo/mpcinfo.vcxproj.filters
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup>
+    <Filter Include="Source Files">
+      <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
+      <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
+    </Filter>
+    <Filter Include="Resource Files">
+      <UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
+      <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
+    </Filter>
+  </ItemGroup>
+  <ItemGroup>
+    <None Include="mpcinfo.def">
+      <Filter>Resource Files</Filter>
+    </None>
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="mpcInfo.c">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+  </ItemGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/upd/upd.def b/plugins/upd/upd.def
new file mode 100644
index 00000000..77670bf2
--- /dev/null
+++ b/plugins/upd/upd.def
@@ -0,0 +1,3 @@
+EXPORTS 
+xchat_plugin_init 
+xchat_plugin_deinit 
diff --git a/plugins/upd/upd.vcxproj b/plugins/upd/upd.vcxproj
new file mode 100644
index 00000000..ee00dc1a
--- /dev/null
+++ b/plugins/upd/upd.vcxproj
@@ -0,0 +1,65 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup Label="ProjectConfigurations">
+    <ProjectConfiguration Include="Release|Win32">
+      <Configuration>Release</Configuration>
+      <Platform>Win32</Platform>
+    </ProjectConfiguration>
+  </ItemGroup>
+  <PropertyGroup Label="Globals">
+    <ProjectGuid>{461DC24A-A410-4171-8C02-CCDBF3702C2A}</ProjectGuid>
+    <Keyword>Win32Proj</Keyword>
+    <RootNamespace>upd</RootNamespace>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
+  <ImportGroup Label="ExtensionSettings">
+  </ImportGroup>
+  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
+  <PropertyGroup Label="UserMacros" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xcupd</TargetName>
+  </PropertyGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;UPD_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+      <AdditionalIncludeDirectories>..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <ModuleDefinitionFile>upd.def</ModuleDefinitionFile>
+      <AdditionalDependencies>$(DepLibs);%(AdditionalDependencies)</AdditionalDependencies>
+      <AdditionalLibraryDirectories>$(DepsRoot)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+    </Link>
+  </ItemDefinitionGroup>
+  <ItemGroup>
+    <None Include="upd.def" />
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="upd.c" />
+  </ItemGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
+  <ImportGroup Label="ExtensionTargets">
+  </ImportGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/upd/upd.vcxproj.filters b/plugins/upd/upd.vcxproj.filters
new file mode 100644
index 00000000..e3d7397e
--- /dev/null
+++ b/plugins/upd/upd.vcxproj.filters
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup>
+    <Filter Include="Source Files">
+      <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
+      <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
+    </Filter>
+    <Filter Include="Resource Files">
+      <UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
+      <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
+    </Filter>
+  </ItemGroup>
+  <ItemGroup>
+    <None Include="upd.def">
+      <Filter>Resource Files</Filter>
+    </None>
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="upd.c">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+  </ItemGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/winamp/winamp.def b/plugins/winamp/winamp.def
new file mode 100644
index 00000000..77670bf2
--- /dev/null
+++ b/plugins/winamp/winamp.def
@@ -0,0 +1,3 @@
+EXPORTS 
+xchat_plugin_init 
+xchat_plugin_deinit 
diff --git a/plugins/winamp/winamp.vcxproj b/plugins/winamp/winamp.vcxproj
new file mode 100644
index 00000000..3924b8b2
--- /dev/null
+++ b/plugins/winamp/winamp.vcxproj
@@ -0,0 +1,63 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup Label="ProjectConfigurations">
+    <ProjectConfiguration Include="Release|Win32">
+      <Configuration>Release</Configuration>
+      <Platform>Win32</Platform>
+    </ProjectConfiguration>
+  </ItemGroup>
+  <PropertyGroup Label="Globals">
+    <ProjectGuid>{E78C0D9A-798E-4BF6-B0CC-6FECB8CA2FCE}</ProjectGuid>
+    <Keyword>Win32Proj</Keyword>
+    <RootNamespace>winamp</RootNamespace>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
+  <ImportGroup Label="ExtensionSettings">
+  </ImportGroup>
+  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
+  <PropertyGroup Label="UserMacros" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xcwinamp</TargetName>
+  </PropertyGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;WINAMP_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+      <AdditionalIncludeDirectories>..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <ModuleDefinitionFile>winamp.def</ModuleDefinitionFile>
+    </Link>
+  </ItemDefinitionGroup>
+  <ItemGroup>
+    <None Include="winamp.def" />
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="winamp.c" />
+  </ItemGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
+  <ImportGroup Label="ExtensionTargets">
+  </ImportGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/winamp/winamp.vcxproj.filters b/plugins/winamp/winamp.vcxproj.filters
new file mode 100644
index 00000000..1a800a33
--- /dev/null
+++ b/plugins/winamp/winamp.vcxproj.filters
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup>
+    <Filter Include="Source Files">
+      <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
+      <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
+    </Filter>
+    <Filter Include="Resource Files">
+      <UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
+      <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
+    </Filter>
+  </ItemGroup>
+  <ItemGroup>
+    <None Include="winamp.def">
+      <Filter>Resource Files</Filter>
+    </None>
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="winamp.c">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+  </ItemGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/winsys/winsys.def b/plugins/winsys/winsys.def
new file mode 100644
index 00000000..77670bf2
--- /dev/null
+++ b/plugins/winsys/winsys.def
@@ -0,0 +1,3 @@
+EXPORTS 
+xchat_plugin_init 
+xchat_plugin_deinit 
diff --git a/plugins/winsys/winsys.vcxproj b/plugins/winsys/winsys.vcxproj
new file mode 100644
index 00000000..1466e8e7
--- /dev/null
+++ b/plugins/winsys/winsys.vcxproj
@@ -0,0 +1,66 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup Label="ProjectConfigurations">
+    <ProjectConfiguration Include="Release|Win32">
+      <Configuration>Release</Configuration>
+      <Platform>Win32</Platform>
+    </ProjectConfiguration>
+  </ItemGroup>
+  <PropertyGroup Label="Globals">
+    <ProjectGuid>{6C0CA980-97C5-427A-BE61-5BCECAFABBDA}</ProjectGuid>
+    <Keyword>Win32Proj</Keyword>
+    <RootNamespace>winsys</RootNamespace>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>Unicode</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
+  <ImportGroup Label="ExtensionSettings">
+  </ImportGroup>
+  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
+  <PropertyGroup Label="UserMacros" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xcwinsys</TargetName>
+  </PropertyGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;WINSYS_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <AdditionalIncludeDirectories>..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+      <TreatWChar_tAsBuiltInType>false</TreatWChar_tAsBuiltInType>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <ModuleDefinitionFile>winsys.def</ModuleDefinitionFile>
+      <AdditionalDependencies>wbemuuid.lib;vccomsup.lib;%(AdditionalDependencies)</AdditionalDependencies>
+      <IgnoreSpecificDefaultLibraries>comsupp.lib</IgnoreSpecificDefaultLibraries>
+    </Link>
+  </ItemDefinitionGroup>
+  <ItemGroup>
+    <None Include="winsys.def" />
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="winsys.cpp" />
+  </ItemGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
+  <ImportGroup Label="ExtensionTargets">
+  </ImportGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/winsys/winsys.vcxproj.filters b/plugins/winsys/winsys.vcxproj.filters
new file mode 100644
index 00000000..6e5b445c
--- /dev/null
+++ b/plugins/winsys/winsys.vcxproj.filters
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup>
+    <Filter Include="Source Files">
+      <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
+      <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
+    </Filter>
+    <Filter Include="Resource Files">
+      <UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
+      <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
+    </Filter>
+  </ItemGroup>
+  <ItemGroup>
+    <None Include="winsys.def">
+      <Filter>Resource Files</Filter>
+    </None>
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="winsys.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+  </ItemGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/xsasl/xsasl.def b/plugins/xsasl/xsasl.def
new file mode 100644
index 00000000..77670bf2
--- /dev/null
+++ b/plugins/xsasl/xsasl.def
@@ -0,0 +1,3 @@
+EXPORTS 
+xchat_plugin_init 
+xchat_plugin_deinit 
diff --git a/plugins/xsasl/xsasl.vcxproj b/plugins/xsasl/xsasl.vcxproj
new file mode 100644
index 00000000..9bb8fb24
--- /dev/null
+++ b/plugins/xsasl/xsasl.vcxproj
@@ -0,0 +1,65 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup Label="ProjectConfigurations">
+    <ProjectConfiguration Include="Release|Win32">
+      <Configuration>Release</Configuration>
+      <Platform>Win32</Platform>
+    </ProjectConfiguration>
+  </ItemGroup>
+  <PropertyGroup Label="Globals">
+    <ProjectGuid>{18871EBA-AC85-4652-8919-EB8064B9A714}</ProjectGuid>
+    <Keyword>Win32Proj</Keyword>
+    <RootNamespace>xsasl</RootNamespace>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
+  <ImportGroup Label="ExtensionSettings">
+  </ImportGroup>
+  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
+  <PropertyGroup Label="UserMacros" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xcxsasl</TargetName>
+  </PropertyGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;XSASL_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <AdditionalIncludeDirectories>$(Glib);..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <ModuleDefinitionFile>xsasl.def</ModuleDefinitionFile>
+      <AdditionalLibraryDirectories>$(DepsRoot)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+      <AdditionalDependencies>$(DepLibs);%(AdditionalDependencies)</AdditionalDependencies>
+    </Link>
+  </ItemDefinitionGroup>
+  <ItemGroup>
+    <None Include="xsasl.def" />
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="xsasl.c" />
+  </ItemGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
+  <ImportGroup Label="ExtensionTargets">
+  </ImportGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/xsasl/xsasl.vcxproj.filters b/plugins/xsasl/xsasl.vcxproj.filters
new file mode 100644
index 00000000..b01aa8eb
--- /dev/null
+++ b/plugins/xsasl/xsasl.vcxproj.filters
@@ -0,0 +1,23 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup>
+    <Filter Include="Source Files">
+      <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
+      <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
+    </Filter>
+    <Filter Include="Resource Files">
+      <UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
+      <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
+    </Filter>
+  </ItemGroup>
+  <ItemGroup>
+    <None Include="xsasl.def">
+      <Filter>Resource Files</Filter>
+    </None>
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="xsasl.c">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+  </ItemGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/xtray/xtray.def b/plugins/xtray/xtray.def
new file mode 100644
index 00000000..77670bf2
--- /dev/null
+++ b/plugins/xtray/xtray.def
@@ -0,0 +1,3 @@
+EXPORTS 
+xchat_plugin_init 
+xchat_plugin_deinit 
diff --git a/plugins/xtray/xtray.vcxproj b/plugins/xtray/xtray.vcxproj
new file mode 100644
index 00000000..1dc97f30
--- /dev/null
+++ b/plugins/xtray/xtray.vcxproj
@@ -0,0 +1,91 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup Label="ProjectConfigurations">
+    <ProjectConfiguration Include="Release|Win32">
+      <Configuration>Release</Configuration>
+      <Platform>Win32</Platform>
+    </ProjectConfiguration>
+  </ItemGroup>
+  <PropertyGroup Label="Globals">
+    <ProjectGuid>{3024CF36-85E5-4E00-9608-7002E2C7EF14}</ProjectGuid>
+    <Keyword>Win32Proj</Keyword>
+    <RootNamespace>xtray</RootNamespace>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>Unicode</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
+  <ImportGroup Label="ExtensionSettings">
+  </ImportGroup>
+  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
+  <PropertyGroup Label="UserMacros" />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <LinkIncremental>false</LinkIncremental>
+  </PropertyGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;XTRAY_EXPORTS;_STL70_;_STATIC_CPPLIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+      <AdditionalIncludeDirectories>..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <ModuleDefinitionFile>xtray.def</ModuleDefinitionFile>
+      <AdditionalDependencies>ntstc_msvcrt.lib;%(AdditionalDependencies)</AdditionalDependencies>
+    </Link>
+  </ItemDefinitionGroup>
+  <ItemGroup>
+    <None Include="bitmaps\sd.bmp" />
+    <None Include="icons\banned.ico" />
+    <None Include="icons\chan_msg.ico" />
+    <None Include="icons\disconnected.ico" />
+    <None Include="icons\highlight-1-3.ico" />
+    <None Include="icons\highlight.ico" />
+    <None Include="icons\kicked.ico" />
+    <None Include="icons\priv_msg-1-2-2.ico" />
+    <None Include="icons\sd.ico" />
+    <None Include="icons\server_notice.ico" />
+    <None Include="icons\xchat.ico" />
+    <None Include="xtray.def" />
+  </ItemGroup>
+  <ItemGroup>
+    <ResourceCompile Include="resource.rc" />
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="callbacks.cpp" />
+    <ClCompile Include="sdAlerts.cpp" />
+    <ClCompile Include="sdTray.cpp" />
+    <ClCompile Include="utility.cpp" />
+    <ClCompile Include="xchat.cpp" />
+    <ClCompile Include="xtray.cpp" />
+  </ItemGroup>
+  <ItemGroup>
+    <ClInclude Include="callbacks.h" />
+    <ClInclude Include="resource.h" />
+    <ClInclude Include="sdAlerts.h" />
+    <ClInclude Include="sdTray.h" />
+    <ClInclude Include="utility.h" />
+    <ClInclude Include="xchat.h" />
+    <ClInclude Include="xtray.h" />
+  </ItemGroup>
+  <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
+  <ImportGroup Label="ExtensionTargets">
+  </ImportGroup>
+</Project>
\ No newline at end of file
diff --git a/plugins/xtray/xtray.vcxproj.filters b/plugins/xtray/xtray.vcxproj.filters
new file mode 100644
index 00000000..3b909983
--- /dev/null
+++ b/plugins/xtray/xtray.vcxproj.filters
@@ -0,0 +1,109 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup>
+    <Filter Include="Source Files">
+      <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
+      <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
+    </Filter>
+    <Filter Include="Header Files">
+      <UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
+      <Extensions>h;hpp;hxx;hm;inl;inc;xsd</Extensions>
+    </Filter>
+    <Filter Include="Resource Files">
+      <UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
+      <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
+    </Filter>
+    <Filter Include="Resource Files\bitmaps">
+      <UniqueIdentifier>{448b49a5-e68b-451e-bfbc-0855da024b2e}</UniqueIdentifier>
+    </Filter>
+    <Filter Include="Resource Files\icons">
+      <UniqueIdentifier>{8345128a-0635-43d6-9115-a85ad9c77ee2}</UniqueIdentifier>
+    </Filter>
+  </ItemGroup>
+  <ItemGroup>
+    <None Include="xtray.def">
+      <Filter>Resource Files</Filter>
+    </None>
+    <None Include="bitmaps\sd.bmp">
+      <Filter>Resource Files\bitmaps</Filter>
+    </None>
+    <None Include="icons\banned.ico">
+      <Filter>Resource Files\icons</Filter>
+    </None>
+    <None Include="icons\chan_msg.ico">
+      <Filter>Resource Files\icons</Filter>
+    </None>
+    <None Include="icons\disconnected.ico">
+      <Filter>Resource Files\icons</Filter>
+    </None>
+    <None Include="icons\highlight.ico">
+      <Filter>Resource Files\icons</Filter>
+    </None>
+    <None Include="icons\highlight-1-3.ico">
+      <Filter>Resource Files\icons</Filter>
+    </None>
+    <None Include="icons\kicked.ico">
+      <Filter>Resource Files\icons</Filter>
+    </None>
+    <None Include="icons\priv_msg-1-2-2.ico">
+      <Filter>Resource Files\icons</Filter>
+    </None>
+    <None Include="icons\sd.ico">
+      <Filter>Resource Files\icons</Filter>
+    </None>
+    <None Include="icons\server_notice.ico">
+      <Filter>Resource Files\icons</Filter>
+    </None>
+    <None Include="icons\xchat.ico">
+      <Filter>Resource Files\icons</Filter>
+    </None>
+  </ItemGroup>
+  <ItemGroup>
+    <ResourceCompile Include="resource.rc">
+      <Filter>Resource Files</Filter>
+    </ResourceCompile>
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="callbacks.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="sdAlerts.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="sdTray.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="utility.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="xchat.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+    <ClCompile Include="xtray.cpp">
+      <Filter>Source Files</Filter>
+    </ClCompile>
+  </ItemGroup>
+  <ItemGroup>
+    <ClInclude Include="callbacks.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="resource.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="sdAlerts.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="sdTray.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="utility.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="xchat.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+    <ClInclude Include="xtray.h">
+      <Filter>Header Files</Filter>
+    </ClInclude>
+  </ItemGroup>
+</Project>
\ No newline at end of file
diff --git a/src/version/version.vcxproj b/src/version/version.vcxproj
index e6d510f8..26c13458 100644
--- a/src/version/version.vcxproj
+++ b/src/version/version.vcxproj
@@ -32,13 +32,14 @@
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
-      <WarningLevel>Level3</WarningLevel>
+      <WarningLevel>Level1</WarningLevel>
       <PrecompiledHeader>
       </PrecompiledHeader>
       <Optimization>MaxSpeed</Optimization>
       <FunctionLevelLinking>true</FunctionLevelLinking>
       <IntrinsicFunctions>true</IntrinsicFunctions>
       <PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
     </ClCompile>
     <Link>
       <SubSystem>Console</SubSystem>
diff --git a/win32/xchat.sln b/win32/xchat.sln
index 7aa6b029..ecb1f859 100644
--- a/win32/xchat.sln
+++ b/win32/xchat.sln
@@ -34,20 +34,53 @@ EndProject
 Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "tcl", "..\plugins\tcl\tcl.vcxproj", "{2773666A-8CFC-4533-A043-EAD59F16A1C7}"
 EndProject
 Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "perl-512", "..\plugins\perl\perl-512.vcxproj", "{987E9374-98A1-44BA-946F-D3472D7A7055}"
+	ProjectSection(ProjectDependencies) = postProject
+		{98B56DF9-E4F1-4696-A565-5F7823CF214D} = {98B56DF9-E4F1-4696-A565-5F7823CF214D}
+	EndProjectSection
 EndProject
 Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "perl-514", "..\plugins\perl\perl-514.vcxproj", "{C4C9FA6F-F990-4C7B-85F6-CD8F4F5728F0}"
 	ProjectSection(ProjectDependencies) = postProject
 		{987E9374-98A1-44BA-946F-D3472D7A7055} = {987E9374-98A1-44BA-946F-D3472D7A7055}
+		{98B56DF9-E4F1-4696-A565-5F7823CF214D} = {98B56DF9-E4F1-4696-A565-5F7823CF214D}
 	EndProjectSection
 EndProject
 Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "perl-516", "..\plugins\perl\perl-516.vcxproj", "{58654438-F674-42F7-88FA-73EF90AD80B1}"
 	ProjectSection(ProjectDependencies) = postProject
 		{C4C9FA6F-F990-4C7B-85F6-CD8F4F5728F0} = {C4C9FA6F-F990-4C7B-85F6-CD8F4F5728F0}
+		{98B56DF9-E4F1-4696-A565-5F7823CF214D} = {98B56DF9-E4F1-4696-A565-5F7823CF214D}
 	EndProjectSection
 EndProject
 Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "python", "..\plugins\python\python.vcxproj", "{19C52A0A-A790-409E-A28A-9745FF990F5C}"
+	ProjectSection(ProjectDependencies) = postProject
+		{98B56DF9-E4F1-4696-A565-5F7823CF214D} = {98B56DF9-E4F1-4696-A565-5F7823CF214D}
+	EndProjectSection
 EndProject
 Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "lua", "..\plugins\lua\lua.vcxproj", "{646B4316-C8B8-4DB6-B6AE-E586929E5729}"
+	ProjectSection(ProjectDependencies) = postProject
+		{98B56DF9-E4F1-4696-A565-5F7823CF214D} = {98B56DF9-E4F1-4696-A565-5F7823CF214D}
+	EndProjectSection
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "doat", "..\plugins\doat\doat.vcxproj", "{4980AF24-9D42-427D-A8E6-0DF3B97C455D}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "checksum", "..\plugins\checksum\checksum.vcxproj", "{5EF7F47D-D09C-43C4-BF64-B28B11A0FF91}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "dns", "..\plugins\dns\dns.vcxproj", "{3786FA8C-3E76-45E3-984E-FCCFF44729C9}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "exec", "..\plugins\exec\exec.vcxproj", "{17E4BE39-76F7-4A06-AD21-EFD0C5091F76}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "fishlim", "..\plugins\fishlim\fishlim.vcxproj", "{3C4F42FC-292A-420B-B63D-C03DFBDD8E4E}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "mpcinfo", "..\plugins\mpcinfo\mpcinfo.vcxproj", "{B0E36D93-CA2A-49FE-9EB9-9C96C6016EEC}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "upd", "..\plugins\upd\upd.vcxproj", "{461DC24A-A410-4171-8C02-CCDBF3702C2A}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "winamp", "..\plugins\winamp\winamp.vcxproj", "{E78C0D9A-798E-4BF6-B0CC-6FECB8CA2FCE}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "winsys", "..\plugins\winsys\winsys.vcxproj", "{6C0CA980-97C5-427A-BE61-5BCECAFABBDA}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "xsasl", "..\plugins\xsasl\xsasl.vcxproj", "{18871EBA-AC85-4652-8919-EB8064B9A714}"
+EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "xtray", "..\plugins\xtray\xtray.vcxproj", "{3024CF36-85E5-4E00-9608-7002E2C7EF14}"
 EndProject
 Global
 	GlobalSection(SolutionConfigurationPlatforms) = preSolution
@@ -78,6 +111,28 @@ Global
 		{19C52A0A-A790-409E-A28A-9745FF990F5C}.Release|Win32.Build.0 = Release|Win32
 		{646B4316-C8B8-4DB6-B6AE-E586929E5729}.Release|Win32.ActiveCfg = Release|Win32
 		{646B4316-C8B8-4DB6-B6AE-E586929E5729}.Release|Win32.Build.0 = Release|Win32
+		{4980AF24-9D42-427D-A8E6-0DF3B97C455D}.Release|Win32.ActiveCfg = Release|Win32
+		{4980AF24-9D42-427D-A8E6-0DF3B97C455D}.Release|Win32.Build.0 = Release|Win32
+		{5EF7F47D-D09C-43C4-BF64-B28B11A0FF91}.Release|Win32.ActiveCfg = Release|Win32
+		{5EF7F47D-D09C-43C4-BF64-B28B11A0FF91}.Release|Win32.Build.0 = Release|Win32
+		{3786FA8C-3E76-45E3-984E-FCCFF44729C9}.Release|Win32.ActiveCfg = Release|Win32
+		{3786FA8C-3E76-45E3-984E-FCCFF44729C9}.Release|Win32.Build.0 = Release|Win32
+		{17E4BE39-76F7-4A06-AD21-EFD0C5091F76}.Release|Win32.ActiveCfg = Release|Win32
+		{17E4BE39-76F7-4A06-AD21-EFD0C5091F76}.Release|Win32.Build.0 = Release|Win32
+		{3C4F42FC-292A-420B-B63D-C03DFBDD8E4E}.Release|Win32.ActiveCfg = Release|Win32
+		{3C4F42FC-292A-420B-B63D-C03DFBDD8E4E}.Release|Win32.Build.0 = Release|Win32
+		{B0E36D93-CA2A-49FE-9EB9-9C96C6016EEC}.Release|Win32.ActiveCfg = Release|Win32
+		{B0E36D93-CA2A-49FE-9EB9-9C96C6016EEC}.Release|Win32.Build.0 = Release|Win32
+		{461DC24A-A410-4171-8C02-CCDBF3702C2A}.Release|Win32.ActiveCfg = Release|Win32
+		{461DC24A-A410-4171-8C02-CCDBF3702C2A}.Release|Win32.Build.0 = Release|Win32
+		{E78C0D9A-798E-4BF6-B0CC-6FECB8CA2FCE}.Release|Win32.ActiveCfg = Release|Win32
+		{E78C0D9A-798E-4BF6-B0CC-6FECB8CA2FCE}.Release|Win32.Build.0 = Release|Win32
+		{6C0CA980-97C5-427A-BE61-5BCECAFABBDA}.Release|Win32.ActiveCfg = Release|Win32
+		{6C0CA980-97C5-427A-BE61-5BCECAFABBDA}.Release|Win32.Build.0 = Release|Win32
+		{18871EBA-AC85-4652-8919-EB8064B9A714}.Release|Win32.ActiveCfg = Release|Win32
+		{18871EBA-AC85-4652-8919-EB8064B9A714}.Release|Win32.Build.0 = Release|Win32
+		{3024CF36-85E5-4E00-9608-7002E2C7EF14}.Release|Win32.ActiveCfg = Release|Win32
+		{3024CF36-85E5-4E00-9608-7002E2C7EF14}.Release|Win32.Build.0 = Release|Win32
 	EndGlobalSection
 	GlobalSection(SolutionProperties) = preSolution
 		HideSolutionNode = FALSE
@@ -89,6 +144,17 @@ Global
 		{87554B59-006C-4D94-9714-897B27067BA3} = {AAACEB12-9475-410E-AF5A-FDFF907E9043}
 		{6CD3647E-4541-4849-9DD7-C8816665AE42} = {BB051F0F-A841-4A9A-BAF6-51DD9866D65A}
 		{98B56DF9-E4F1-4696-A565-5F7823CF214D} = {BB051F0F-A841-4A9A-BAF6-51DD9866D65A}
+		{4980AF24-9D42-427D-A8E6-0DF3B97C455D} = {561126F4-FA18-45FC-A2BF-8F858F161D6D}
+		{5EF7F47D-D09C-43C4-BF64-B28B11A0FF91} = {561126F4-FA18-45FC-A2BF-8F858F161D6D}
+		{3786FA8C-3E76-45E3-984E-FCCFF44729C9} = {561126F4-FA18-45FC-A2BF-8F858F161D6D}
+		{17E4BE39-76F7-4A06-AD21-EFD0C5091F76} = {561126F4-FA18-45FC-A2BF-8F858F161D6D}
+		{3C4F42FC-292A-420B-B63D-C03DFBDD8E4E} = {561126F4-FA18-45FC-A2BF-8F858F161D6D}
+		{B0E36D93-CA2A-49FE-9EB9-9C96C6016EEC} = {561126F4-FA18-45FC-A2BF-8F858F161D6D}
+		{461DC24A-A410-4171-8C02-CCDBF3702C2A} = {561126F4-FA18-45FC-A2BF-8F858F161D6D}
+		{E78C0D9A-798E-4BF6-B0CC-6FECB8CA2FCE} = {561126F4-FA18-45FC-A2BF-8F858F161D6D}
+		{6C0CA980-97C5-427A-BE61-5BCECAFABBDA} = {561126F4-FA18-45FC-A2BF-8F858F161D6D}
+		{18871EBA-AC85-4652-8919-EB8064B9A714} = {561126F4-FA18-45FC-A2BF-8F858F161D6D}
+		{3024CF36-85E5-4E00-9608-7002E2C7EF14} = {561126F4-FA18-45FC-A2BF-8F858F161D6D}
 		{2773666A-8CFC-4533-A043-EAD59F16A1C7} = {D237DA6B-BD5F-46C0-8BEA-50E9A1340240}
 		{987E9374-98A1-44BA-946F-D3472D7A7055} = {D237DA6B-BD5F-46C0-8BEA-50E9A1340240}
 		{C4C9FA6F-F990-4C7B-85F6-CD8F4F5728F0} = {D237DA6B-BD5F-46C0-8BEA-50E9A1340240}
-- 
cgit 1.4.1


From 9220ea591127820cdda5675cd86fbfef2ff34cce Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Sun, 10 Jun 2012 14:49:15 +0200
Subject: Add WMPA as well

---
 plugins/wmpa/wmpa.vcxproj         | 182 ++++++++------------------------------
 plugins/wmpa/wmpa.vcxproj.filters |  62 +++++++------
 win32/xchat.props                 |   4 +-
 win32/xchat.sln                   |   5 ++
 4 files changed, 77 insertions(+), 176 deletions(-)

(limited to 'plugins')

diff --git a/plugins/wmpa/wmpa.vcxproj b/plugins/wmpa/wmpa.vcxproj
index 919c2c00..b231d0b0 100644
--- a/plugins/wmpa/wmpa.vcxproj
+++ b/plugins/wmpa/wmpa.vcxproj
@@ -5,164 +5,58 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
-    <ProjectConfiguration Include="Release|x64">
-      <Configuration>Release</Configuration>
-      <Platform>x64</Platform>
-    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
-    <SccProjectName />
-    <SccLocalPath />
-    <Keyword>MFCProj</Keyword>
+    <ProjectGuid>{E7F4DB0A-510D-41EF-B284-6E1DE1CC450D}</ProjectGuid>
+    <Keyword>Win32Proj</Keyword>
+    <RootNamespace>wmpa</RootNamespace>
   </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
     <ConfigurationType>DynamicLibrary</ConfigurationType>
-    <UseOfMfc>Dynamic</UseOfMfc>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>false</WholeProgramOptimization>
     <CharacterSet>MultiByte</CharacterSet>
-  </PropertyGroup>
-  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
-    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <PlatformToolset>WDK7</PlatformToolset>
     <UseOfMfc>Dynamic</UseOfMfc>
-    <CharacterSet>MultiByte</CharacterSet>
   </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
-  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="PropertySheets">
-    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
-    <Import Project="$(VCTargetsPath)Microsoft.Cpp.UpgradeFromVC60.props" />
-  </ImportGroup>
-  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+  <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
-    <Import Project="$(VCTargetsPath)Microsoft.Cpp.UpgradeFromVC60.props" />
+    <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
-    <OutDir>.\Release\</OutDir>
-    <IntDir>.\Release\</IntDir>
-    <LinkIncremental>false</LinkIncremental>
-    <TargetName>xcwmpa</TargetName>
-  </PropertyGroup>
-  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
-    <OutDir>.\Release\</OutDir>
-    <IntDir>.\Release\</IntDir>
     <LinkIncremental>false</LinkIncremental>
     <TargetName>xcwmpa</TargetName>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
-      <RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
-      <InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
-      <StringPooling>true</StringPooling>
-      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>Create</PrecompiledHeader>
       <Optimization>MaxSpeed</Optimization>
-      <SuppressStartupBanner>true</SuppressStartupBanner>
-      <WarningLevel>Level3</WarningLevel>
-      <AdditionalIncludeDirectories>c:\WinDDK\7600.16385.1\inc\api;c:\WinDDK\7600.16385.1\inc\crt;c:\WinDDK\7600.16385.1\inc\mfc42;c:\WinDDK\7600.16385.1\inc\ddk;c:\WinDDK\7600.16385.1\inc\api\dao360</AdditionalIncludeDirectories>
-      <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_WINDLL;_USRDLL;_AFXDLL;_AFX_NO_DAO_SUPPORT</PreprocessorDefinitions>
-      <AssemblerListingLocation>.\Release\</AssemblerListingLocation>
-      <PrecompiledHeaderOutputFile>.\Release\wmpa.pch</PrecompiledHeaderOutputFile>
-      <PrecompiledHeader>Use</PrecompiledHeader>
-      <PrecompiledHeaderFile>stdafx.h</PrecompiledHeaderFile>
-      <ObjectFileName>.\Release\</ObjectFileName>
-      <ProgramDataBaseFileName>.\Release\</ProgramDataBaseFileName>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;WMPA_EXPORTS;_AFXDLL;_AFX_NO_DAO_SUPPORT;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <MultiProcessorCompilation>false</MultiProcessorCompilation>
     </ClCompile>
-    <Midl>
-      <SuppressStartupBanner>true</SuppressStartupBanner>
-      <PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
-      <TypeLibraryName>.\Release\wmpa.tlb</TypeLibraryName>
-      <MkTypLibCompatible>true</MkTypLibCompatible>
-      <TargetEnvironment>Win32</TargetEnvironment>
-    </Midl>
-    <ResourceCompile>
-      <Culture>0x0409</Culture>
-      <PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
-    </ResourceCompile>
-    <Bscmake>
-      <SuppressStartupBanner>true</SuppressStartupBanner>
-      <OutputFile>.\Release\wmpa.bsc</OutputFile>
-    </Bscmake>
     <Link>
-      <SuppressStartupBanner>true</SuppressStartupBanner>
-      <LinkDLL>true</LinkDLL>
       <SubSystem>Windows</SubSystem>
-      <OutputFile>.\Release\xcwmpa.dll</OutputFile>
-      <ImportLibrary>.\Release\wmpa.lib</ImportLibrary>
-      <ModuleDefinitionFile>.\wmpa.def</ModuleDefinitionFile>
-      <AdditionalLibraryDirectories>c:\WinDDK\7600.16385.1\lib\Crt\i386;c:\WinDDK\7600.16385.1\lib\wxp\i386;c:\WinDDK\7600.16385.1\lib\Mfc\i386;c:\WinDDK\7600.16385.1\lib\ATL\i386</AdditionalLibraryDirectories>
-      <AdditionalDependencies>msvcrt_winxp.obj</AdditionalDependencies>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <ModuleDefinitionFile>wmpa.def</ModuleDefinitionFile>
     </Link>
-    <CustomBuildStep>
-      <Command>
-      </Command>
-      <Outputs>
-      </Outputs>
-      <Message>
-      </Message>
-    </CustomBuildStep>
-  </ItemDefinitionGroup>
-  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
-    <ClCompile>
-      <RuntimeLibrary>MultiThreadedDLL</RuntimeLibrary>
-      <InlineFunctionExpansion>OnlyExplicitInline</InlineFunctionExpansion>
-      <StringPooling>true</StringPooling>
-      <FunctionLevelLinking>true</FunctionLevelLinking>
-      <Optimization>MaxSpeed</Optimization>
-      <SuppressStartupBanner>true</SuppressStartupBanner>
-      <WarningLevel>Level3</WarningLevel>
-      <AdditionalIncludeDirectories>c:\WinDDK\7600.16385.1\inc\api;c:\WinDDK\7600.16385.1\inc\crt;c:\WinDDK\7600.16385.1\inc\mfc42;c:\WinDDK\7600.16385.1\inc\ddk;c:\WinDDK\7600.16385.1\inc\api\dao360</AdditionalIncludeDirectories>
-      <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_WINDLL;_USRDLL;_AFXDLL;_AFX_NO_DAO_SUPPORT</PreprocessorDefinitions>
-      <AssemblerListingLocation>.\Release\</AssemblerListingLocation>
-      <PrecompiledHeaderOutputFile>.\Release\wmpa.pch</PrecompiledHeaderOutputFile>
-      <PrecompiledHeader>Use</PrecompiledHeader>
-      <PrecompiledHeaderFile>stdafx.h</PrecompiledHeaderFile>
-      <ObjectFileName>.\Release\</ObjectFileName>
-      <ProgramDataBaseFileName>.\Release\</ProgramDataBaseFileName>
-    </ClCompile>
     <Midl>
-      <SuppressStartupBanner>true</SuppressStartupBanner>
-      <PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
-      <TypeLibraryName>.\Release\wmpa.tlb</TypeLibraryName>
       <MkTypLibCompatible>true</MkTypLibCompatible>
-      <TargetEnvironment>X64</TargetEnvironment>
     </Midl>
-    <ResourceCompile>
-      <Culture>0x0409</Culture>
-      <PreprocessorDefinitions>NDEBUG;%(PreprocessorDefinitions)</PreprocessorDefinitions>
-    </ResourceCompile>
-    <Bscmake>
-      <SuppressStartupBanner>true</SuppressStartupBanner>
-      <OutputFile>.\Release\wmpa.bsc</OutputFile>
-    </Bscmake>
-    <Link>
-      <SuppressStartupBanner>true</SuppressStartupBanner>
-      <LinkDLL>true</LinkDLL>
-      <SubSystem>Windows</SubSystem>
-      <OutputFile>.\Release\xcwmpa.dll</OutputFile>
-      <ImportLibrary>.\Release\wmpa.lib</ImportLibrary>
-      <ModuleDefinitionFile>.\wmpa.def</ModuleDefinitionFile>
-      <AdditionalLibraryDirectories>c:\WinDDK\7600.16385.1\lib\Crt\amd64;c:\WinDDK\7600.16385.1\lib\wnet\amd64;c:\WinDDK\7600.16385.1\lib\Mfc\amd64;c:\WinDDK\7600.16385.1\lib\ATL\amd64</AdditionalLibraryDirectories>
-      <AdditionalDependencies>msvcrt_win2003.obj</AdditionalDependencies>
-    </Link>
-    <CustomBuildStep>
-      <Command>
-      </Command>
-      <Outputs>
-      </Outputs>
-      <Message>
-      </Message>
-    </CustomBuildStep>
   </ItemDefinitionGroup>
   <ItemGroup>
-    <ClCompile Include="StdAfx.cpp">
-      <PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
-      <PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|x64'">Create</PrecompiledHeader>
-      <PrecompiledHeaderFile Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">stdafx.h</PrecompiledHeaderFile>
-      <PrecompiledHeaderFile Condition="'$(Configuration)|$(Platform)'=='Release|x64'">stdafx.h</PrecompiledHeaderFile>
-    </ClCompile>
+    <ClCompile Include="StdAfx.cpp" />
     <ClCompile Include="wmpa.cpp" />
-    <ClCompile Include="WMPADialog.cpp" />
+    <ClCompile Include="wmpadialog.cpp" />
     <ClCompile Include="wmpcdrom.cpp" />
     <ClCompile Include="wmpcdromcollection.cpp" />
     <ClCompile Include="wmpclosedcaption.cpp" />
@@ -183,29 +77,10 @@
     <ClCompile Include="xchat-plugin.cpp" />
   </ItemGroup>
   <ItemGroup>
-    <CustomBuild Include="wmpa.def" />
-    <CustomBuild Include="res\wmpa.rc2">
-      <FileType>RC</FileType>
-    </CustomBuild>
-    <CustomBuild Include="wmpa.ico" />
-    <CustomBuild Include="ReadMe.txt" />
-  </ItemGroup>
-  <ItemGroup>
-    <Midl Include="wmpa.odl">
-      <TargetEnvironment Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Win32</TargetEnvironment>
-    </Midl>
-  </ItemGroup>
-  <ItemGroup>
-    <ResourceCompile Include="wmpa.rc">
-      <AdditionalIncludeDirectories Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">$(OUTDIR);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
-      <AdditionalIncludeDirectories Condition="'$(Configuration)|$(Platform)'=='Release|x64'">$(OUTDIR);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
-    </ResourceCompile>
-  </ItemGroup>
-  <ItemGroup>
-    <ClInclude Include="Resource.h" />
+    <ClInclude Include="resource.h" />
     <ClInclude Include="StdAfx.h" />
     <ClInclude Include="wmpa.h" />
-    <ClInclude Include="WMPADIALOG.h" />
+    <ClInclude Include="wmpadialog.h" />
     <ClInclude Include="wmpcdrom.h" />
     <ClInclude Include="wmpcdromcollection.h" />
     <ClInclude Include="wmpclosedcaption.h" />
@@ -225,6 +100,19 @@
     <ClInclude Include="wmpstringcollection.h" />
     <ClInclude Include="xchat-plugin.h" />
   </ItemGroup>
+  <ItemGroup>
+    <None Include="ReadMe.txt" />
+    <None Include="res\wmpa.rc2" />
+    <None Include="wmpa.aps" />
+    <None Include="wmpa.def" />
+    <None Include="wmpa.ico" />
+  </ItemGroup>
+  <ItemGroup>
+    <Midl Include="wmpa.odl" />
+  </ItemGroup>
+  <ItemGroup>
+    <ResourceCompile Include="wmpa.rc" />
+  </ItemGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
   <ImportGroup Label="ExtensionTargets">
   </ImportGroup>
diff --git a/plugins/wmpa/wmpa.vcxproj.filters b/plugins/wmpa/wmpa.vcxproj.filters
index 6962f46e..2be9d82f 100644
--- a/plugins/wmpa/wmpa.vcxproj.filters
+++ b/plugins/wmpa/wmpa.vcxproj.filters
@@ -2,16 +2,19 @@
 <Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
   <ItemGroup>
     <Filter Include="Source Files">
-      <UniqueIdentifier>{3206fd00-efdb-4bca-9740-9708bd405701}</UniqueIdentifier>
-      <Extensions>cpp;c;cxx;rc;def;r;odl;idl;hpj;bat</Extensions>
+      <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
+      <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
     </Filter>
     <Filter Include="Header Files">
-      <UniqueIdentifier>{17e13eb2-1243-4ff2-9532-1d6dab0bfef9}</UniqueIdentifier>
-      <Extensions>h;hpp;hxx;hm;inl</Extensions>
+      <UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
+      <Extensions>h;hpp;hxx;hm;inl;inc;xsd</Extensions>
     </Filter>
     <Filter Include="Resource Files">
-      <UniqueIdentifier>{a1d9cf8c-f0bb-4a19-bfff-5223276e650a}</UniqueIdentifier>
-      <Extensions>ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe</Extensions>
+      <UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
+      <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
+    </Filter>
+    <Filter Include="Resource Files\res">
+      <UniqueIdentifier>{c54ddc93-06ab-4a74-854a-9ec976b7bfd0}</UniqueIdentifier>
     </Filter>
   </ItemGroup>
   <ItemGroup>
@@ -21,7 +24,7 @@
     <ClCompile Include="wmpa.cpp">
       <Filter>Source Files</Filter>
     </ClCompile>
-    <ClCompile Include="WMPADialog.cpp">
+    <ClCompile Include="wmpadialog.cpp">
       <Filter>Source Files</Filter>
     </ClCompile>
     <ClCompile Include="wmpcdrom.cpp">
@@ -80,17 +83,7 @@
     </ClCompile>
   </ItemGroup>
   <ItemGroup>
-    <Midl Include="wmpa.odl">
-      <Filter>Source Files</Filter>
-    </Midl>
-  </ItemGroup>
-  <ItemGroup>
-    <ResourceCompile Include="wmpa.rc">
-      <Filter>Source Files</Filter>
-    </ResourceCompile>
-  </ItemGroup>
-  <ItemGroup>
-    <ClInclude Include="Resource.h">
+    <ClInclude Include="resource.h">
       <Filter>Header Files</Filter>
     </ClInclude>
     <ClInclude Include="StdAfx.h">
@@ -99,7 +92,7 @@
     <ClInclude Include="wmpa.h">
       <Filter>Header Files</Filter>
     </ClInclude>
-    <ClInclude Include="WMPADIALOG.h">
+    <ClInclude Include="wmpadialog.h">
       <Filter>Header Files</Filter>
     </ClInclude>
     <ClInclude Include="wmpcdrom.h">
@@ -158,15 +151,30 @@
     </ClInclude>
   </ItemGroup>
   <ItemGroup>
-    <CustomBuild Include="wmpa.def">
-      <Filter>Source Files</Filter>
-    </CustomBuild>
-    <CustomBuild Include="res\wmpa.rc2">
+    <None Include="wmpa.aps">
       <Filter>Resource Files</Filter>
-    </CustomBuild>
-    <CustomBuild Include="wmpa.ico">
+    </None>
+    <None Include="wmpa.def">
       <Filter>Resource Files</Filter>
-    </CustomBuild>
-    <CustomBuild Include="ReadMe.txt" />
+    </None>
+    <None Include="wmpa.ico">
+      <Filter>Resource Files</Filter>
+    </None>
+    <None Include="ReadMe.txt">
+      <Filter>Resource Files</Filter>
+    </None>
+    <None Include="res\wmpa.rc2">
+      <Filter>Resource Files\res</Filter>
+    </None>
+  </ItemGroup>
+  <ItemGroup>
+    <Midl Include="wmpa.odl">
+      <Filter>Resource Files</Filter>
+    </Midl>
+  </ItemGroup>
+  <ItemGroup>
+    <ResourceCompile Include="wmpa.rc">
+      <Filter>Resource Files</Filter>
+    </ResourceCompile>
   </ItemGroup>
 </Project>
\ No newline at end of file
diff --git a/win32/xchat.props b/win32/xchat.props
index 32ed807d..1611bc9e 100644
--- a/win32/xchat.props
+++ b/win32/xchat.props
@@ -2,8 +2,8 @@
 <Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
   <ImportGroup Label="PropertySheets" />
   <PropertyGroup Label="UserMacros">
-    <!-- SPECIFY YOUR ROOT DEPENDENCY DIRECTORY ROOT HERE -->
-    <YourDepsPath>c:\mozilla-build\xchat deps</YourDepsPath>
+    <!-- SPECIFY YOUR DEPENDENCY DIRECTORIES HERE -->
+    <YourDepsPath>c:\mozilla-build\deps path</YourDepsPath>
     <YourGendefPath>c:\mozilla-build\gendef path</YourGendefPath>
     <YourTclPath>c:\mozilla-build\tcl path</YourTclPath>
     <YourPerl512Path>c:\mozilla-build\perl512 path</YourPerl512Path>
diff --git a/win32/xchat.sln b/win32/xchat.sln
index ecb1f859..c6a84b42 100644
--- a/win32/xchat.sln
+++ b/win32/xchat.sln
@@ -82,6 +82,8 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "xsasl", "..\plugins\xsasl\x
 EndProject
 Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "xtray", "..\plugins\xtray\xtray.vcxproj", "{3024CF36-85E5-4E00-9608-7002E2C7EF14}"
 EndProject
+Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "wmpa", "..\plugins\wmpa\wmpa.vcxproj", "{E7F4DB0A-510D-41EF-B284-6E1DE1CC450D}"
+EndProject
 Global
 	GlobalSection(SolutionConfigurationPlatforms) = preSolution
 		Release|Win32 = Release|Win32
@@ -133,6 +135,8 @@ Global
 		{18871EBA-AC85-4652-8919-EB8064B9A714}.Release|Win32.Build.0 = Release|Win32
 		{3024CF36-85E5-4E00-9608-7002E2C7EF14}.Release|Win32.ActiveCfg = Release|Win32
 		{3024CF36-85E5-4E00-9608-7002E2C7EF14}.Release|Win32.Build.0 = Release|Win32
+		{E7F4DB0A-510D-41EF-B284-6E1DE1CC450D}.Release|Win32.ActiveCfg = Release|Win32
+		{E7F4DB0A-510D-41EF-B284-6E1DE1CC450D}.Release|Win32.Build.0 = Release|Win32
 	EndGlobalSection
 	GlobalSection(SolutionProperties) = preSolution
 		HideSolutionNode = FALSE
@@ -155,6 +159,7 @@ Global
 		{6C0CA980-97C5-427A-BE61-5BCECAFABBDA} = {561126F4-FA18-45FC-A2BF-8F858F161D6D}
 		{18871EBA-AC85-4652-8919-EB8064B9A714} = {561126F4-FA18-45FC-A2BF-8F858F161D6D}
 		{3024CF36-85E5-4E00-9608-7002E2C7EF14} = {561126F4-FA18-45FC-A2BF-8F858F161D6D}
+		{E7F4DB0A-510D-41EF-B284-6E1DE1CC450D} = {561126F4-FA18-45FC-A2BF-8F858F161D6D}
 		{2773666A-8CFC-4533-A043-EAD59F16A1C7} = {D237DA6B-BD5F-46C0-8BEA-50E9A1340240}
 		{987E9374-98A1-44BA-946F-D3472D7A7055} = {D237DA6B-BD5F-46C0-8BEA-50E9A1340240}
 		{C4C9FA6F-F990-4C7B-85F6-CD8F4F5728F0} = {D237DA6B-BD5F-46C0-8BEA-50E9A1340240}
-- 
cgit 1.4.1


From bf37bd37556fbf20dfa1a6b40c56453eb1fe8d01 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Tue, 12 Jun 2012 20:40:42 +0200
Subject: Update Do At plugin (Khisanth)

---
 plugins/doat/doat.c | 24 +++++++++++++++++++-----
 1 file changed, 19 insertions(+), 5 deletions(-)

(limited to 'plugins')

diff --git a/plugins/doat/doat.c b/plugins/doat/doat.c
index e03507f1..a0b5707a 100644
--- a/plugins/doat/doat.c
+++ b/plugins/doat/doat.c
@@ -31,15 +31,23 @@ parse_command( char *word[], char *word_eol[], void *userdata ) {
 				break;
 			}
 
-			channel = malloc( strlen( token ) + 1 );
-			strcpy( channel, token );
+			channel = strdup( token );
 				
 			delimiter = strchr( channel, '/' );
 
 			server = NULL;
 			if( delimiter != NULL ) {
 				*delimiter = '\0';
-				server = delimiter + 1;
+
+				if( strlen( delimiter + 1 ) > 0 ) {
+					server = strdup( delimiter + 1 );
+				}
+			}
+
+			/* /Network form */
+			if( strlen( channel ) == 0 ) {
+				free( channel );
+				channel = NULL;
 			}
 
 /*			printf( "channel[%s] server[%s]\n", channel, server );*/
@@ -50,7 +58,13 @@ parse_command( char *word[], char *word_eol[], void *userdata ) {
 				}
 			}
 
-			free( channel );
+			if( channel != NULL ) {
+				free( channel );
+			}
+
+			if( server != NULL ) {
+				free( server );
+			}
 		}
 	}
 	return XCHAT_EAT_XCHAT;
@@ -62,7 +76,7 @@ xchat_plugin_init( xchat_plugin * plugin_handle, char **plugin_name,
 
 	ph = plugin_handle;
 	*plugin_name = "Do At";
-	*plugin_version = "1.0";
+	*plugin_version = "1.0001";
 	*plugin_desc = "Perform an arbitrary command on multiple channels";
 
 	xchat_hook_command( ph, "doat", XCHAT_PRI_NORM, parse_command, "DOAT [channel,list,/network] [command], perform a command on multiple contexts", NULL );
-- 
cgit 1.4.1


From 593efa703b6914f963533da513576a26e744ead9 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Fri, 15 Jun 2012 21:37:48 +0200
Subject: LOTS of fixes to the VS solution

---
 plugins/checksum/checksum.vcxproj             |    2 +
 plugins/dns/dns.vcxproj                       |    2 +
 plugins/doat/doat.vcxproj                     |    2 +
 plugins/exec/exec.vcxproj                     |    2 +
 plugins/fishlim/fishlim.vcxproj               |    2 +
 plugins/lua/lua.vcxproj                       |    2 +
 plugins/mpcinfo/mpcinfo.vcxproj               |    2 +
 plugins/perl/perl-512.vcxproj                 |   11 +-
 plugins/perl/perl-514.vcxproj                 |   11 +-
 plugins/perl/perl-516.vcxproj                 |   11 +-
 plugins/python/python.vcxproj                 |    2 +
 plugins/tcl/tcl.vcxproj                       |    2 +
 plugins/upd/upd.vcxproj                       |    2 +
 plugins/winamp/winamp.vcxproj                 |    2 +
 plugins/winsys/winsys.vcxproj                 |    2 +
 plugins/wmpa/wmpa.vcxproj                     |    2 +
 plugins/xsasl/xsasl.vcxproj                   |    2 +
 plugins/xtray/xtray.vcxproj                   |    2 +
 src/common/common.vcxproj                     |    5 +-
 src/dirent/dirent.vcxproj                     |    2 +
 src/fe-gtk/fe-gtk.vcxproj                     |    2 +
 src/fe-text/fe-text.vcxproj                   |    2 +
 src/pixmaps/pixmaps.vcxproj                   |    4 +-
 src/version/version.c                         |   20 +-
 src/version/version.vcxproj                   |    4 +-
 win32/bitmaps/wizardimage.bmp                 |  Bin 52062 -> 0 bytes
 win32/bitmaps/wizardsmallimage.bmp            |  Bin 9798 -> 0 bytes
 win32/copy/copy.vcxproj                       |   21 +-
 win32/copy/copy.vcxproj.filters               |   46 +-
 win32/copy/etc/download.png                   |  Bin 0 -> 703 bytes
 win32/copy/etc/gtk-2.0/gtkrc                  |   71 +
 win32/copy/etc/gtkpref.png                    |  Bin 0 -> 323 bytes
 win32/copy/etc/music.png                      |  Bin 0 -> 3577 bytes
 win32/copy/etc/system.png                     |  Bin 0 -> 3578 bytes
 win32/copy/share/xml/iso-codes/iso_3166.xml   | 1703 +++++++++++++++++++
 win32/copy/share/xml/iso-codes/iso_639.xml    | 2169 +++++++++++++++++++++++++
 win32/etc/download.png                        |  Bin 703 -> 0 bytes
 win32/etc/gtk-2.0/gtkrc                       |   71 -
 win32/etc/gtkpref.png                         |  Bin 323 -> 0 bytes
 win32/etc/music.png                           |  Bin 3577 -> 0 bytes
 win32/etc/system.png                          |  Bin 3578 -> 0 bytes
 win32/installer/installer.vcxproj             |   32 +-
 win32/installer/installer.vcxproj.filters     |   28 +-
 win32/installer/watercolorlite-blue.cjstyles  |  Bin 0 -> 308224 bytes
 win32/installer/watercolorlite-green.cjstyles |  Bin 0 -> 308224 bytes
 win32/installer/wizardimage.bmp               |  Bin 0 -> 52062 bytes
 win32/installer/wizardsmallimage.bmp          |  Bin 0 -> 9798 bytes
 win32/installer/xchat-wdk-x64.skel.iss        |  279 ++++
 win32/installer/xchat-wdk-x86.skel.iss        |  282 ++++
 win32/isskin/watercolorlite-blue.cjstyles     |  Bin 308224 -> 0 bytes
 win32/isskin/watercolorlite-green.cjstyles    |  Bin 308224 -> 0 bytes
 win32/nls/nls.vcxproj                         |   13 +-
 win32/share/themes/Murrine/gtk-2.0/gtkrc      |    7 -
 win32/share/xml/iso-codes/iso_3166.xml        | 1703 -------------------
 win32/share/xml/iso-codes/iso_639.xml         | 2169 -------------------------
 win32/xchat-wdk-x64.skel.iss                  |  279 ----
 win32/xchat-wdk-x86.skel.iss                  |  282 ----
 win32/xchat.props                             |    2 +-
 win32/xchat.sln                               |   24 +-
 59 files changed, 4718 insertions(+), 4565 deletions(-)
 delete mode 100644 win32/bitmaps/wizardimage.bmp
 delete mode 100644 win32/bitmaps/wizardsmallimage.bmp
 create mode 100644 win32/copy/etc/download.png
 create mode 100644 win32/copy/etc/gtk-2.0/gtkrc
 create mode 100644 win32/copy/etc/gtkpref.png
 create mode 100644 win32/copy/etc/music.png
 create mode 100644 win32/copy/etc/system.png
 create mode 100644 win32/copy/share/xml/iso-codes/iso_3166.xml
 create mode 100644 win32/copy/share/xml/iso-codes/iso_639.xml
 delete mode 100644 win32/etc/download.png
 delete mode 100644 win32/etc/gtk-2.0/gtkrc
 delete mode 100644 win32/etc/gtkpref.png
 delete mode 100644 win32/etc/music.png
 delete mode 100644 win32/etc/system.png
 create mode 100644 win32/installer/watercolorlite-blue.cjstyles
 create mode 100644 win32/installer/watercolorlite-green.cjstyles
 create mode 100644 win32/installer/wizardimage.bmp
 create mode 100644 win32/installer/wizardsmallimage.bmp
 create mode 100644 win32/installer/xchat-wdk-x64.skel.iss
 create mode 100644 win32/installer/xchat-wdk-x86.skel.iss
 delete mode 100644 win32/isskin/watercolorlite-blue.cjstyles
 delete mode 100644 win32/isskin/watercolorlite-green.cjstyles
 delete mode 100644 win32/share/themes/Murrine/gtk-2.0/gtkrc
 delete mode 100644 win32/share/xml/iso-codes/iso_3166.xml
 delete mode 100644 win32/share/xml/iso-codes/iso_639.xml
 delete mode 100644 win32/xchat-wdk-x64.skel.iss
 delete mode 100644 win32/xchat-wdk-x86.skel.iss

(limited to 'plugins')

diff --git a/plugins/checksum/checksum.vcxproj b/plugins/checksum/checksum.vcxproj
index cbfa2a2d..c4090cd1 100644
--- a/plugins/checksum/checksum.vcxproj
+++ b/plugins/checksum/checksum.vcxproj
@@ -30,6 +30,8 @@
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
     <TargetName>xcchecksum</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
diff --git a/plugins/dns/dns.vcxproj b/plugins/dns/dns.vcxproj
index b98c778f..38f1634b 100644
--- a/plugins/dns/dns.vcxproj
+++ b/plugins/dns/dns.vcxproj
@@ -30,6 +30,8 @@
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
     <TargetName>xcdns</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
diff --git a/plugins/doat/doat.vcxproj b/plugins/doat/doat.vcxproj
index f0168a6b..c6901fe1 100644
--- a/plugins/doat/doat.vcxproj
+++ b/plugins/doat/doat.vcxproj
@@ -30,6 +30,8 @@
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
     <TargetName>xcdoat</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
diff --git a/plugins/exec/exec.vcxproj b/plugins/exec/exec.vcxproj
index cef4049c..15bf5ec5 100644
--- a/plugins/exec/exec.vcxproj
+++ b/plugins/exec/exec.vcxproj
@@ -30,6 +30,8 @@
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
     <TargetName>xcexec</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
diff --git a/plugins/fishlim/fishlim.vcxproj b/plugins/fishlim/fishlim.vcxproj
index 1cf5293f..0f6e1c38 100644
--- a/plugins/fishlim/fishlim.vcxproj
+++ b/plugins/fishlim/fishlim.vcxproj
@@ -30,6 +30,8 @@
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
     <TargetName>xcfishlim</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
diff --git a/plugins/lua/lua.vcxproj b/plugins/lua/lua.vcxproj
index 69a8e4ea..26d21856 100644
--- a/plugins/lua/lua.vcxproj
+++ b/plugins/lua/lua.vcxproj
@@ -30,6 +30,8 @@
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
     <TargetName>$(LuaOutput)</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
diff --git a/plugins/mpcinfo/mpcinfo.vcxproj b/plugins/mpcinfo/mpcinfo.vcxproj
index 04182d50..7f12822e 100644
--- a/plugins/mpcinfo/mpcinfo.vcxproj
+++ b/plugins/mpcinfo/mpcinfo.vcxproj
@@ -30,6 +30,8 @@
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
     <TargetName>xcmpcinfo</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
diff --git a/plugins/perl/perl-512.vcxproj b/plugins/perl/perl-512.vcxproj
index 440496f3..d924af48 100644
--- a/plugins/perl/perl-512.vcxproj
+++ b/plugins/perl/perl-512.vcxproj
@@ -30,6 +30,8 @@
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
     <TargetName>$(Perl512Output)</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
@@ -41,7 +43,7 @@
       <IntrinsicFunctions>true</IntrinsicFunctions>
       <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;PERL512_EXPORTS;$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
       <MultiProcessorCompilation>true</MultiProcessorCompilation>
-      <AdditionalIncludeDirectories>$(Perl512Path)\perl\lib\CORE;..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <AdditionalIncludeDirectories>$(Perl512Path)\perl\lib\CORE;$(IntDir);..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
     </ClCompile>
     <Link>
       <SubSystem>Windows</SubSystem>
@@ -55,8 +57,11 @@
     </Link>
     <PreBuildEvent>
       <Command>"$(GendefPath)\gendef" "$(Perl512Path)\perl\bin\$(Perl512Lib).dll"
-lib /nologo /machine:x86 "/def:$(Perl512Lib).def" "/out:$(OutputPath)\$(Perl512Lib).lib"
-"$(Perl512Path)\perl\bin\perl.exe" generate_header</Command>
+move $(Perl512Lib).def "$(IntDir)"
+lib /nologo /machine:x86 "/def:$(IntDir)$(Perl512Lib).def" "/out:$(OutDir)\$(Perl512Lib).lib"
+"$(Perl512Path)\perl\bin\perl.exe" generate_header
+move irc.pm.h "$(IntDir)"
+move xchat.pm.h "$(IntDir)"</Command>
     </PreBuildEvent>
   </ItemDefinitionGroup>
   <ItemGroup>
diff --git a/plugins/perl/perl-514.vcxproj b/plugins/perl/perl-514.vcxproj
index 04865562..58cc4f04 100644
--- a/plugins/perl/perl-514.vcxproj
+++ b/plugins/perl/perl-514.vcxproj
@@ -30,6 +30,8 @@
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
     <TargetName>$(Perl514Output)</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
@@ -40,7 +42,7 @@
       <FunctionLevelLinking>true</FunctionLevelLinking>
       <IntrinsicFunctions>true</IntrinsicFunctions>
       <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;PERL514_EXPORTS;$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
-      <AdditionalIncludeDirectories>$(Perl514Path)\perl\lib\CORE;..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <AdditionalIncludeDirectories>$(Perl514Path)\perl\lib\CORE;$(IntDir);..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
       <MultiProcessorCompilation>true</MultiProcessorCompilation>
     </ClCompile>
     <Link>
@@ -55,8 +57,11 @@
     </Link>
     <PreBuildEvent>
       <Command>"$(GendefPath)\gendef" "$(Perl514Path)\perl\bin\$(Perl514Lib).dll"
-lib /nologo /machine:x86 "/def:$(Perl514Lib).def" "/out:$(OutputPath)\$(Perl514Lib).lib"
-"$(Perl514Path)\perl\bin\perl.exe" generate_header</Command>
+move $(Perl514Lib).def "$(IntDir)"
+lib /nologo /machine:x86 "/def:$(IntDir)$(Perl514Lib).def" "/out:$(OutDir)\$(Perl514Lib).lib"
+"$(Perl514Path)\perl\bin\perl.exe" generate_header
+move irc.pm.h "$(IntDir)"
+move xchat.pm.h "$(IntDir)"</Command>
     </PreBuildEvent>
   </ItemDefinitionGroup>
   <ItemGroup>
diff --git a/plugins/perl/perl-516.vcxproj b/plugins/perl/perl-516.vcxproj
index 5a3c620d..516c1b80 100644
--- a/plugins/perl/perl-516.vcxproj
+++ b/plugins/perl/perl-516.vcxproj
@@ -30,6 +30,8 @@
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
     <TargetName>$(Perl516Output)</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
@@ -40,7 +42,7 @@
       <FunctionLevelLinking>true</FunctionLevelLinking>
       <IntrinsicFunctions>true</IntrinsicFunctions>
       <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;PERL516_EXPORTS;$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
-      <AdditionalIncludeDirectories>$(Perl516Path)\perl\lib\CORE;..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <AdditionalIncludeDirectories>$(Perl516Path)\perl\lib\CORE;$(IntDir);..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
       <MultiProcessorCompilation>true</MultiProcessorCompilation>
     </ClCompile>
     <Link>
@@ -55,8 +57,11 @@
     </Link>
     <PreBuildEvent>
       <Command>"$(GendefPath)\gendef" "$(Perl516Path)\perl\bin\$(Perl516Lib).dll"
-lib /nologo /machine:x86 "/def:$(Perl516Lib).def" "/out:$(OutputPath)\$(Perl516Lib).lib"
-"$(Perl516Path)\perl\bin\perl.exe" generate_header</Command>
+move $(Perl516Lib).def "$(IntDir)"
+lib /nologo /machine:x86 "/def:$(IntDir)$(Perl516Lib).def" "/out:$(OutDir)\$(Perl516Lib).lib"
+"$(Perl516Path)\perl\bin\perl.exe" generate_header
+move irc.pm.h "$(IntDir)"
+move xchat.pm.h "$(IntDir)"</Command>
     </PreBuildEvent>
   </ItemDefinitionGroup>
   <ItemGroup>
diff --git a/plugins/python/python.vcxproj b/plugins/python/python.vcxproj
index de0fadea..923eeb92 100644
--- a/plugins/python/python.vcxproj
+++ b/plugins/python/python.vcxproj
@@ -30,6 +30,8 @@
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
     <TargetName>$(PythonOutput)</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
diff --git a/plugins/tcl/tcl.vcxproj b/plugins/tcl/tcl.vcxproj
index fa69aa33..baa188f6 100644
--- a/plugins/tcl/tcl.vcxproj
+++ b/plugins/tcl/tcl.vcxproj
@@ -40,6 +40,8 @@
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
     <TargetName>$(TclOutput)</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
diff --git a/plugins/upd/upd.vcxproj b/plugins/upd/upd.vcxproj
index ee00dc1a..9cf7c017 100644
--- a/plugins/upd/upd.vcxproj
+++ b/plugins/upd/upd.vcxproj
@@ -30,6 +30,8 @@
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
     <TargetName>xcupd</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
diff --git a/plugins/winamp/winamp.vcxproj b/plugins/winamp/winamp.vcxproj
index 3924b8b2..0a1eb419 100644
--- a/plugins/winamp/winamp.vcxproj
+++ b/plugins/winamp/winamp.vcxproj
@@ -30,6 +30,8 @@
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
     <TargetName>xcwinamp</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
diff --git a/plugins/winsys/winsys.vcxproj b/plugins/winsys/winsys.vcxproj
index 1466e8e7..656f6ee9 100644
--- a/plugins/winsys/winsys.vcxproj
+++ b/plugins/winsys/winsys.vcxproj
@@ -30,6 +30,8 @@
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
     <TargetName>xcwinsys</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
diff --git a/plugins/wmpa/wmpa.vcxproj b/plugins/wmpa/wmpa.vcxproj
index b231d0b0..630cef4d 100644
--- a/plugins/wmpa/wmpa.vcxproj
+++ b/plugins/wmpa/wmpa.vcxproj
@@ -31,6 +31,8 @@
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
     <TargetName>xcwmpa</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
diff --git a/plugins/xsasl/xsasl.vcxproj b/plugins/xsasl/xsasl.vcxproj
index 9bb8fb24..7e0c41d7 100644
--- a/plugins/xsasl/xsasl.vcxproj
+++ b/plugins/xsasl/xsasl.vcxproj
@@ -30,6 +30,8 @@
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
     <TargetName>xcxsasl</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
diff --git a/plugins/xtray/xtray.vcxproj b/plugins/xtray/xtray.vcxproj
index 1dc97f30..1f7aa5cf 100644
--- a/plugins/xtray/xtray.vcxproj
+++ b/plugins/xtray/xtray.vcxproj
@@ -29,6 +29,8 @@
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
diff --git a/src/common/common.vcxproj b/src/common/common.vcxproj
index f0a730b7..b57b2ccf 100644
--- a/src/common/common.vcxproj
+++ b/src/common/common.vcxproj
@@ -90,7 +90,10 @@
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
   <PropertyGroup Label="UserMacros" />
-  <PropertyGroup />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level1</WarningLevel>
diff --git a/src/dirent/dirent.vcxproj b/src/dirent/dirent.vcxproj
index 65fa2fb0..8ac38f92 100644
--- a/src/dirent/dirent.vcxproj
+++ b/src/dirent/dirent.vcxproj
@@ -35,6 +35,8 @@
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <TargetName>$(ProjectName)-win32</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
diff --git a/src/fe-gtk/fe-gtk.vcxproj b/src/fe-gtk/fe-gtk.vcxproj
index 68390d03..fce8d3e6 100644
--- a/src/fe-gtk/fe-gtk.vcxproj
+++ b/src/fe-gtk/fe-gtk.vcxproj
@@ -30,6 +30,8 @@
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
     <TargetName>xchat</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
diff --git a/src/fe-text/fe-text.vcxproj b/src/fe-text/fe-text.vcxproj
index 389c7b5e..ac7068ec 100644
--- a/src/fe-text/fe-text.vcxproj
+++ b/src/fe-text/fe-text.vcxproj
@@ -30,6 +30,8 @@
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
     <TargetName>xchat-text</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
diff --git a/src/pixmaps/pixmaps.vcxproj b/src/pixmaps/pixmaps.vcxproj
index ba88104d..3fda0fef 100644
--- a/src/pixmaps/pixmaps.vcxproj
+++ b/src/pixmaps/pixmaps.vcxproj
@@ -29,6 +29,8 @@
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
@@ -47,7 +49,7 @@
       <OptimizeReferences>true</OptimizeReferences>
     </Link>
     <PostBuildEvent>
-      <Command>"$(DepsRoot)\bin\gdk-pixbuf-csource" --build-list $(Pixmaps) > "$(SolutionDir)\..\src\pixmaps\inline_pngs.h"</Command>
+      <Command>"$(DepsRoot)\bin\gdk-pixbuf-csource" --build-list $(Pixmaps) &gt; "$(SolutionDir)\..\src\pixmaps\inline_pngs.h"</Command>
     </PostBuildEvent>
   </ItemDefinitionGroup>
   <ItemGroup>
diff --git a/src/version/version.c b/src/version/version.c
index 14312a43..53af5675 100644
--- a/src/version/version.c
+++ b/src/version/version.c
@@ -76,13 +76,13 @@ main (int argc, char *argv[])
 		{
 			printf ("#define COMMA_VERSION %s\n", comma ());
 		}
-		else if (!strcmp (argv[1], "-a32"))	/* xchat-wdk.iss/AppVerName */
-		{
-			printf ("AppVerName=XChat-WDK %s (x86)\n", PACKAGE_VERSION);
-		}
-		else if (!strcmp (argv[1], "-a64"))	/* xchat-wdk.iss/AppVerName */
+		else if (!strcmp (argv[1], "-a"))	/* xchat-wdk.iss/AppVerName */
 		{
+#ifdef _WIN64
 			printf ("AppVerName=XChat-WDK %s (x64)\n", PACKAGE_VERSION);
+#else
+			printf ("AppVerName=XChat-WDK %s (x86)\n", PACKAGE_VERSION);
+#endif
 		}
 		else if (!strcmp (argv[1], "-v"))	/* xchat-wdk.iss/AppVersion */
 		{
@@ -92,13 +92,13 @@ main (int argc, char *argv[])
 		{
 			printf ("VersionInfoVersion=%s\n", point ());
 		}
-		else if (!strcmp (argv[1], "-o32"))	/* xchat-wdk.iss/OutputBaseFilename */
-		{
-			printf ("OutputBaseFilename=XChat-WDK %s x86\n", PACKAGE_VERSION);
-		}
-		else if (!strcmp (argv[1], "-o64"))	/* xchat-wdk.iss/OutputBaseFilename */
+		else if (!strcmp (argv[1], "-o"))	/* xchat-wdk.iss/OutputBaseFilename */
 		{
+#ifdef _WIN64
 			printf ("OutputBaseFilename=XChat-WDK %s x64\n", PACKAGE_VERSION);
+#else
+			printf ("OutputBaseFilename=XChat-WDK %s x86\n", PACKAGE_VERSION);
+#endif
 		}
 		else if (!strcmp (argv[1], "-v"))	/* version.txt */
 		{
diff --git a/src/version/version.vcxproj b/src/version/version.vcxproj
index 26c13458..b07b8e2a 100644
--- a/src/version/version.vcxproj
+++ b/src/version/version.vcxproj
@@ -29,6 +29,8 @@
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
@@ -48,7 +50,7 @@
       <OptimizeReferences>true</OptimizeReferences>
     </Link>
     <PostBuildEvent>
-      <Command>"$(OutputPath)\$(TargetName)$(TargetExt)" -r &gt; "$(SolutionDir)\..\resource.h"</Command>
+      <Command>"$(OutDir)\$(TargetName)$(TargetExt)" -r &gt; "$(SolutionDir)\..\resource.h"</Command>
     </PostBuildEvent>
   </ItemDefinitionGroup>
   <ItemGroup>
diff --git a/win32/bitmaps/wizardimage.bmp b/win32/bitmaps/wizardimage.bmp
deleted file mode 100644
index 9f5a4c90..00000000
Binary files a/win32/bitmaps/wizardimage.bmp and /dev/null differ
diff --git a/win32/bitmaps/wizardsmallimage.bmp b/win32/bitmaps/wizardsmallimage.bmp
deleted file mode 100644
index 1bb8b790..00000000
Binary files a/win32/bitmaps/wizardsmallimage.bmp and /dev/null differ
diff --git a/win32/copy/copy.vcxproj b/win32/copy/copy.vcxproj
index d7c6fda7..5b64ddc6 100644
--- a/win32/copy/copy.vcxproj
+++ b/win32/copy/copy.vcxproj
@@ -16,6 +16,7 @@
     <UseDebugLibraries>false</UseDebugLibraries>
     <WholeProgramOptimization>true</WholeProgramOptimization>
     <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
@@ -25,7 +26,10 @@
     <Import Project="..\xchat.props" />
   </ImportGroup>
   <PropertyGroup Label="UserMacros" />
-  <PropertyGroup />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level3</WarningLevel>
@@ -67,8 +71,8 @@ copy "$(DepsRoot)\bin\libpng14-14.dll" "$(XChatDest)"
 copy "$(DepsRoot)\bin\libxml2.dll" "$(XChatDest)"
 xcopy /q /s /i "$(DepsRoot)\lib\gtk-2.0\2.10.0\engines" "$(XChatDest)\lib\gtk-2.0\2.10.0\engines"
 xcopy /q /s /i "$(DepsRoot)\lib\gtk-2.0\modules\libgail.dll" "$(XChatDest)\lib\gtk-2.0\modules\"
-xcopy /q /s /i "..\etc" "$(XChatDest)\etc"
-xcopy /q /s /i "..\share" "$(XChatDest)\share"
+xcopy /q /s /i etc "$(XChatDest)\etc"
+xcopy /q /s /i share "$(XChatDest)\share"
 copy "..\..\COPYING" "$(XChatDest)"
 copy "$(DepsRoot)\LICENSE.OPENSSL" "$(XChatDest)"
 copy "$(DepsRoot)\LICENSE.ZLIB" "$(XChatDest)"
@@ -102,13 +106,20 @@ copy "$(OutDir)\xcwinamp.dll" "$(XChatDest)\plugins"
 copy "$(OutDir)\xcwinsys.dll" "$(XChatDest)\plugins"
 copy "$(OutDir)\xcwmpa.dll" "$(XChatDest)\plugins"
 copy "$(DepsRoot)\bin\lua51.dll" "$(XChatDest)"
-xcopy /q /s /i "..\..\po\locale" "$(XChatDest)\locale"
+xcopy /q /s /i "$(OutDir)\locale" "$(XChatDest)\locale"
 xcopy /q /s /i "$(DepsRoot)\share\locale" "$(XChatDest)\share\locale"
 copy "$(ProgramFiles)\Codejock Software\ISSkin\ISSkinU.dll" "$(XChatDest)"
-copy "..\isskin\watercolorlite-green.cjstyles" "$(XChatDest)"</Command>
+copy "..\installer\watercolorlite-green.cjstyles" "$(XChatDest)"</Command>
     </PreBuildEvent>
   </ItemDefinitionGroup>
   <ItemGroup>
+    <None Include="etc\download.png" />
+    <None Include="etc\gtk-2.0\gtkrc" />
+    <None Include="etc\gtkpref.png" />
+    <None Include="etc\music.png" />
+    <None Include="etc\system.png" />
+    <None Include="share\xml\iso-codes\iso_3166.xml" />
+    <None Include="share\xml\iso-codes\iso_639.xml" />
   </ItemGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
   <ImportGroup Label="ExtensionTargets">
diff --git a/win32/copy/copy.vcxproj.filters b/win32/copy/copy.vcxproj.filters
index ef1ebf58..f832474d 100644
--- a/win32/copy/copy.vcxproj.filters
+++ b/win32/copy/copy.vcxproj.filters
@@ -1,2 +1,46 @@
 <?xml version="1.0" encoding="utf-8"?>
-<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" />
\ No newline at end of file
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+  <ItemGroup>
+    <Filter Include="Resource Files">
+      <UniqueIdentifier>{e02a8c67-767c-4c6e-a854-81fae08cf4da}</UniqueIdentifier>
+    </Filter>
+    <Filter Include="Resource Files\etc">
+      <UniqueIdentifier>{503881c0-011d-443b-a373-4bfe125dcfa6}</UniqueIdentifier>
+    </Filter>
+    <Filter Include="Resource Files\share">
+      <UniqueIdentifier>{4316433a-2a8e-48f7-9020-e1f4de0d23d1}</UniqueIdentifier>
+    </Filter>
+    <Filter Include="Resource Files\etc\gtk-2.0">
+      <UniqueIdentifier>{832ebebc-ab71-4bf6-9f3a-02ec748f7c14}</UniqueIdentifier>
+    </Filter>
+    <Filter Include="Resource Files\share\xml">
+      <UniqueIdentifier>{9a881586-aed2-4f80-ba84-e521e6785566}</UniqueIdentifier>
+    </Filter>
+    <Filter Include="Resource Files\share\xml\iso-codes">
+      <UniqueIdentifier>{c825f724-0618-4160-97b7-12d6e0f2bc7b}</UniqueIdentifier>
+    </Filter>
+  </ItemGroup>
+  <ItemGroup>
+    <None Include="etc\download.png">
+      <Filter>Resource Files\etc</Filter>
+    </None>
+    <None Include="etc\gtkpref.png">
+      <Filter>Resource Files\etc</Filter>
+    </None>
+    <None Include="etc\music.png">
+      <Filter>Resource Files\etc</Filter>
+    </None>
+    <None Include="etc\system.png">
+      <Filter>Resource Files\etc</Filter>
+    </None>
+    <None Include="etc\gtk-2.0\gtkrc">
+      <Filter>Resource Files\etc\gtk-2.0</Filter>
+    </None>
+    <None Include="share\xml\iso-codes\iso_639.xml">
+      <Filter>Resource Files\share\xml\iso-codes</Filter>
+    </None>
+    <None Include="share\xml\iso-codes\iso_3166.xml">
+      <Filter>Resource Files\share\xml\iso-codes</Filter>
+    </None>
+  </ItemGroup>
+</Project>
\ No newline at end of file
diff --git a/win32/copy/etc/download.png b/win32/copy/etc/download.png
new file mode 100644
index 00000000..43253432
Binary files /dev/null and b/win32/copy/etc/download.png differ
diff --git a/win32/copy/etc/gtk-2.0/gtkrc b/win32/copy/etc/gtk-2.0/gtkrc
new file mode 100644
index 00000000..6ac7b76c
--- /dev/null
+++ b/win32/copy/etc/gtk-2.0/gtkrc
@@ -0,0 +1,71 @@
+gtk-font-name = "sans 8"
+
+gtk-icon-sizes = "gtk-menu=13,13:gtk-small-toolbar=16,16:gtk-large-toolbar=24,24:gtk-dnd=32,32"
+gtk-toolbar-icon-size = small-toolbar
+
+# disable images in buttons. i've only seen ugly delphi apps use this feature.
+gtk-button-images = 0
+
+# enable/disable images in menus. most "stock" microsoft apps don't use these, except sparingly.
+# the office apps use them heavily, though.
+gtk-menu-images = 1
+
+# use the win32 button ordering instead of the GNOME HIG one, where applicable
+gtk-alternative-button-order = 1
+
+# use the win32 sort indicators direction, as in Explorer
+gtk-alternative-sort-arrows = 1
+
+# Windows users don't expect the PC Speaker beeping at them when they backspace in an empty textview and stuff like that
+gtk-error-bell = 0
+
+# hide mnemonic underlines until the Alt key is pressed (requires gtk 2.18+)
+# gtk-auto-mnemonics = 1
+
+style "msw-default"
+{
+  GtkWidget::interior-focus = 1
+  GtkOptionMenu::indicator-size = { 9, 5 }
+  GtkOptionMenu::indicator-spacing = { 7, 5, 2, 2 }
+  GtkSpinButton::shadow-type = in
+
+  # Owen and I disagree that these should be themable
+  #GtkUIManager::add-tearoffs = 0
+  #GtkComboBox::add-tearoffs = 0
+
+  GtkComboBox::appears-as-list = 1
+  GtkComboBox::focus-on-click = 0
+
+  GOComboBox::add_tearoffs = 0
+
+  GtkTreeView::allow-rules = 0
+  GtkTreeView::expander-size = 12
+
+  GtkExpander::expander-size = 12
+
+  GtkScrolledWindow::scrollbar_spacing = 1
+
+  GtkSeparatorMenuItem::horizontal-padding = 2
+
+  engine "wimp"
+  {
+  }
+}
+class "*" style "msw-default"
+
+binding "ms-windows-tree-view"
+{
+  bind "Right" { "expand-collapse-cursor-row" (1,1,0) }
+  bind "Left" { "expand-collapse-cursor-row" (1,0,0) }
+}
+
+class "GtkTreeView" binding "ms-windows-tree-view"
+
+style "msw-combobox-thickness" = "msw-default"
+{
+  xthickness = 0
+  ythickness = 0
+}
+
+widget_class "*TreeView*ComboBox*" style "msw-combobox-thickness"
+widget_class "*ComboBox*GtkFrame*" style "msw-combobox-thickness"
diff --git a/win32/copy/etc/gtkpref.png b/win32/copy/etc/gtkpref.png
new file mode 100644
index 00000000..9a6c9cf9
Binary files /dev/null and b/win32/copy/etc/gtkpref.png differ
diff --git a/win32/copy/etc/music.png b/win32/copy/etc/music.png
new file mode 100644
index 00000000..3a72f118
Binary files /dev/null and b/win32/copy/etc/music.png differ
diff --git a/win32/copy/etc/system.png b/win32/copy/etc/system.png
new file mode 100644
index 00000000..fc4282c7
Binary files /dev/null and b/win32/copy/etc/system.png differ
diff --git a/win32/copy/share/xml/iso-codes/iso_3166.xml b/win32/copy/share/xml/iso-codes/iso_3166.xml
new file mode 100644
index 00000000..77c72eb2
--- /dev/null
+++ b/win32/copy/share/xml/iso-codes/iso_3166.xml
@@ -0,0 +1,1703 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+
+<!--
+This file gives a list of all countries in the ISO 3166
+standard, and is used to provide translations via gettext
+
+Copyright (C) 2002, 2004, 2006 Alastair McKinstry <mckinstry@computer.org>
+Copyright (C) 2004 Andreas Jochens <aj@andaco.de>
+Copyright (C) 2004, 2007 Christian Perrier <bubulle@debian.org>
+Copyright (C) 2005, 2006, 2007 Tobias Quathamer <toddy@debian.org>
+
+    This file is free software; you can redistribute it and/or
+    modify it under the terms of the GNU Lesser General Public
+    License as published by the Free Software Foundation; either
+    version 2.1 of the License, or (at your option) any later version.
+
+    This file is distributed in the hope that it will be useful,
+    but WITHOUT ANY WARRANTY; without even the implied warranty of
+    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+    Lesser General Public License for more details.
+
+    You should have received a copy of the GNU Lesser General Public
+    License along with this file; if not, write to the Free Software
+    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
+
+Source: <http://www.iso.org/iso/country_codes>
+-->
+
+<!DOCTYPE iso_3166_entries [
+	<!ELEMENT iso_3166_entries (iso_3166_entry+, iso_3166_3_entry*)>
+	<!ELEMENT iso_3166_entry EMPTY>
+	<!ATTLIST iso_3166_entry
+		alpha_2_code		CDATA	#REQUIRED
+		alpha_3_code		CDATA	#REQUIRED
+		numeric_code		CDATA	#REQUIRED
+		common_name		CDATA	#IMPLIED
+		name			CDATA	#REQUIRED
+		official_name		CDATA	#IMPLIED
+	>
+	<!ELEMENT iso_3166_3_entry EMPTY>
+	<!ATTLIST iso_3166_3_entry
+		alpha_4_code		CDATA	#REQUIRED
+		alpha_3_code		CDATA	#REQUIRED
+		numeric_code		CDATA	#IMPLIED
+		date_withdrawn		CDATA	#IMPLIED
+		names			CDATA	#REQUIRED
+		comment			CDATA	#IMPLIED
+	>
+]>
+
+<iso_3166_entries>
+	<iso_3166_entry
+		alpha_2_code="AF"
+		alpha_3_code="AFG"
+		numeric_code="004"
+		name="Afghanistan"
+		official_name="Islamic Republic of Afghanistan" />
+	<iso_3166_entry
+		alpha_2_code="AX"
+		alpha_3_code="ALA"
+		numeric_code="248"
+		name="Åland Islands" />
+	<iso_3166_entry
+		alpha_2_code="AL"
+		alpha_3_code="ALB"
+		numeric_code="008"
+		name="Albania"
+		official_name="Republic of Albania" />
+	<iso_3166_entry
+		alpha_2_code="DZ"
+		alpha_3_code="DZA"
+		numeric_code="012"
+		name="Algeria"
+		official_name="People's Democratic Republic of Algeria" />
+	<iso_3166_entry
+		alpha_2_code="AS"
+		alpha_3_code="ASM"
+		numeric_code="016"
+		name="American Samoa" />
+	<iso_3166_entry
+		alpha_2_code="AD"
+		alpha_3_code="AND"
+		numeric_code="020"
+		name="Andorra"
+		official_name="Principality of Andorra" />
+	<iso_3166_entry
+		alpha_2_code="AO"
+		alpha_3_code="AGO"
+		numeric_code="024"
+		name="Angola"
+		official_name="Republic of Angola" />
+	<iso_3166_entry
+		alpha_2_code="AI"
+		alpha_3_code="AIA"
+		numeric_code="660"
+		name="Anguilla" />
+	<iso_3166_entry
+		alpha_2_code="AQ"
+		alpha_3_code="ATA"
+		numeric_code="010"
+		name="Antarctica" />
+	<iso_3166_entry
+		alpha_2_code="AG"
+		alpha_3_code="ATG"
+		numeric_code="028"
+		name="Antigua and Barbuda" />
+	<iso_3166_entry
+		alpha_2_code="AR"
+		alpha_3_code="ARG"
+		numeric_code="032"
+		name="Argentina"
+		official_name="Argentine Republic" />
+	<iso_3166_entry
+		alpha_2_code="AM"
+		alpha_3_code="ARM"
+		numeric_code="051"
+		name="Armenia"
+		official_name="Republic of Armenia" />
+	<iso_3166_entry
+		alpha_2_code="AW"
+		alpha_3_code="ABW"
+		numeric_code="533"
+		name="Aruba" />
+	<iso_3166_entry
+		alpha_2_code="AU"
+		alpha_3_code="AUS"
+		numeric_code="036"
+		name="Australia" />
+	<iso_3166_entry
+		alpha_2_code="AT"
+		alpha_3_code="AUT"
+		numeric_code="040"
+		name="Austria"
+		official_name="Republic of Austria" />
+	<iso_3166_entry
+		alpha_2_code="AZ"
+		alpha_3_code="AZE"
+		numeric_code="031"
+		name="Azerbaijan"
+		official_name="Republic of Azerbaijan" />
+	<iso_3166_entry
+		alpha_2_code="BS"
+		alpha_3_code="BHS"
+		numeric_code="044"
+		name="Bahamas"
+		official_name="Commonwealth of the Bahamas" />
+	<iso_3166_entry
+		alpha_2_code="BH"
+		alpha_3_code="BHR"
+		numeric_code="048"
+		name="Bahrain"
+		official_name="Kingdom of Bahrain" />
+	<iso_3166_entry
+		alpha_2_code="BD"
+		alpha_3_code="BGD"
+		numeric_code="050"
+		name="Bangladesh"
+		official_name="People's Republic of Bangladesh" />
+	<iso_3166_entry
+		alpha_2_code="BB"
+		alpha_3_code="BRB"
+		numeric_code="052"
+		name="Barbados" />
+	<iso_3166_entry
+		alpha_2_code="BY"
+		alpha_3_code="BLR"
+		numeric_code="112"
+		name="Belarus"
+		official_name="Republic of Belarus" />
+	<iso_3166_entry
+		alpha_2_code="BE"
+		alpha_3_code="BEL"
+		numeric_code="056"
+		name="Belgium"
+		official_name="Kingdom of Belgium" />
+	<iso_3166_entry
+		alpha_2_code="BZ"
+		alpha_3_code="BLZ"
+		numeric_code="084"
+		name="Belize" />
+	<iso_3166_entry
+		alpha_2_code="BJ"
+		alpha_3_code="BEN"
+		numeric_code="204"
+		name="Benin"
+		official_name="Republic of Benin" />
+	<iso_3166_entry
+		alpha_2_code="BM"
+		alpha_3_code="BMU"
+		numeric_code="060"
+		name="Bermuda" />
+	<iso_3166_entry
+		alpha_2_code="BT"
+		alpha_3_code="BTN"
+		numeric_code="064"
+		name="Bhutan"
+		official_name="Kingdom of Bhutan" />
+	<iso_3166_entry
+		alpha_2_code="BO"
+		alpha_3_code="BOL"
+		numeric_code="068"
+		common_name="Bolivia"
+		name="Bolivia, Plurinational State of"
+		official_name="Plurinational State of Bolivia" />
+	<iso_3166_entry
+		alpha_2_code="BQ"
+		alpha_3_code="BES"
+		numeric_code="535"
+		name="Bonaire, Sint Eustatius and Saba"
+		official_name="Bonaire, Sint Eustatius and Saba" />
+	<iso_3166_entry
+		alpha_2_code="BA"
+		alpha_3_code="BIH"
+		numeric_code="070"
+		name="Bosnia and Herzegovina"
+		official_name="Republic of Bosnia and Herzegovina" />
+	<iso_3166_entry
+		alpha_2_code="BW"
+		alpha_3_code="BWA"
+		numeric_code="072"
+		name="Botswana"
+		official_name="Republic of Botswana" />
+	<iso_3166_entry
+		alpha_2_code="BV"
+		alpha_3_code="BVT"
+		numeric_code="074"
+		name="Bouvet Island" />
+	<iso_3166_entry
+		alpha_2_code="BR"
+		alpha_3_code="BRA"
+		numeric_code="076"
+		name="Brazil"
+		official_name="Federative Republic of Brazil" />
+	<iso_3166_entry
+		alpha_2_code="IO"
+		alpha_3_code="IOT"
+		numeric_code="086"
+		name="British Indian Ocean Territory" />
+	<iso_3166_entry
+		alpha_2_code="BN"
+		alpha_3_code="BRN"
+		numeric_code="096"
+		name="Brunei Darussalam" />
+	<iso_3166_entry
+		alpha_2_code="BG"
+		alpha_3_code="BGR"
+		numeric_code="100"
+		name="Bulgaria"
+		official_name="Republic of Bulgaria" />
+	<iso_3166_entry
+		alpha_2_code="BF"
+		alpha_3_code="BFA"
+		numeric_code="854"
+		name="Burkina Faso" />
+	<iso_3166_entry
+		alpha_2_code="BI"
+		alpha_3_code="BDI"
+		numeric_code="108"
+		name="Burundi"
+		official_name="Republic of Burundi" />
+	<iso_3166_entry
+		alpha_2_code="KH"
+		alpha_3_code="KHM"
+		numeric_code="116"
+		name="Cambodia"
+		official_name="Kingdom of Cambodia" />
+	<iso_3166_entry
+		alpha_2_code="CM"
+		alpha_3_code="CMR"
+		numeric_code="120"
+		name="Cameroon"
+		official_name="Republic of Cameroon" />
+	<iso_3166_entry
+		alpha_2_code="CA"
+		alpha_3_code="CAN"
+		numeric_code="124"
+		name="Canada" />
+	<iso_3166_entry
+		alpha_2_code="CV"
+		alpha_3_code="CPV"
+		numeric_code="132"
+		name="Cape Verde"
+		official_name="Republic of Cape Verde" />
+	<iso_3166_entry
+		alpha_2_code="KY"
+		alpha_3_code="CYM"
+		numeric_code="136"
+		name="Cayman Islands" />
+	<iso_3166_entry
+		alpha_2_code="CF"
+		alpha_3_code="CAF"
+		numeric_code="140"
+		name="Central African Republic" />
+	<iso_3166_entry
+		alpha_2_code="TD"
+		alpha_3_code="TCD"
+		numeric_code="148"
+		name="Chad"
+		official_name="Republic of Chad" />
+	<iso_3166_entry
+		alpha_2_code="CL"
+		alpha_3_code="CHL"
+		numeric_code="152"
+		name="Chile"
+		official_name="Republic of Chile" />
+	<iso_3166_entry
+		alpha_2_code="CN"
+		alpha_3_code="CHN"
+		numeric_code="156"
+		name="China"
+		official_name="People's Republic of China" />
+	<iso_3166_entry
+		alpha_2_code="CX"
+		alpha_3_code="CXR"
+		numeric_code="162"
+		name="Christmas Island" />
+	<iso_3166_entry
+		alpha_2_code="CC"
+		alpha_3_code="CCK"
+		numeric_code="166"
+		name="Cocos (Keeling) Islands" />
+	<iso_3166_entry
+		alpha_2_code="CO"
+		alpha_3_code="COL"
+		numeric_code="170"
+		name="Colombia"
+		official_name="Republic of Colombia" />
+	<iso_3166_entry
+		alpha_2_code="KM"
+		alpha_3_code="COM"
+		numeric_code="174"
+		name="Comoros"
+		official_name="Union of the Comoros" />
+	<iso_3166_entry
+		alpha_2_code="CG"
+		alpha_3_code="COG"
+		numeric_code="178"
+		name="Congo"
+		official_name="Republic of the Congo" />
+	<iso_3166_entry
+		alpha_2_code="CD"
+		alpha_3_code="COD"
+		numeric_code="180"
+		name="Congo, The Democratic Republic of the" />
+	<iso_3166_entry
+		alpha_2_code="CK"
+		alpha_3_code="COK"
+		numeric_code="184"
+		name="Cook Islands" />
+	<iso_3166_entry
+		alpha_2_code="CR"
+		alpha_3_code="CRI"
+		numeric_code="188"
+		name="Costa Rica"
+		official_name="Republic of Costa Rica" />
+	<iso_3166_entry
+		alpha_2_code="CI"
+		alpha_3_code="CIV"
+		numeric_code="384"
+		name="Côte d'Ivoire"
+		official_name="Republic of Côte d'Ivoire" />
+	<iso_3166_entry
+		alpha_2_code="HR"
+		alpha_3_code="HRV"
+		numeric_code="191"
+		name="Croatia"
+		official_name="Republic of Croatia" />
+	<iso_3166_entry
+		alpha_2_code="CU"
+		alpha_3_code="CUB"
+		numeric_code="192"
+		name="Cuba"
+		official_name="Republic of Cuba" />
+	<iso_3166_entry
+		alpha_2_code="CW"
+		alpha_3_code="CUW"
+		numeric_code="531"
+		name="Curaçao"
+		official_name="Curaçao" />
+	<iso_3166_entry
+		alpha_2_code="CY"
+		alpha_3_code="CYP"
+		numeric_code="196"
+		name="Cyprus"
+		official_name="Republic of Cyprus" />
+	<iso_3166_entry
+		alpha_2_code="CZ"
+		alpha_3_code="CZE"
+		numeric_code="203"
+		name="Czech Republic" />
+	<iso_3166_entry
+		alpha_2_code="DK"
+		alpha_3_code="DNK"
+		numeric_code="208"
+		name="Denmark"
+		official_name="Kingdom of Denmark" />
+	<iso_3166_entry
+		alpha_2_code="DJ"
+		alpha_3_code="DJI"
+		numeric_code="262"
+		name="Djibouti"
+		official_name="Republic of Djibouti" />
+	<iso_3166_entry
+		alpha_2_code="DM"
+		alpha_3_code="DMA"
+		numeric_code="212"
+		name="Dominica"
+		official_name="Commonwealth of Dominica" />
+	<iso_3166_entry
+		alpha_2_code="DO"
+		alpha_3_code="DOM"
+		numeric_code="214"
+		name="Dominican Republic" />
+	<iso_3166_entry
+		alpha_2_code="EC"
+		alpha_3_code="ECU"
+		numeric_code="218"
+		name="Ecuador"
+		official_name="Republic of Ecuador" />
+	<iso_3166_entry
+		alpha_2_code="EG"
+		alpha_3_code="EGY"
+		numeric_code="818"
+		name="Egypt"
+		official_name="Arab Republic of Egypt" />
+	<iso_3166_entry
+		alpha_2_code="SV"
+		alpha_3_code="SLV"
+		numeric_code="222"
+		name="El Salvador"
+		official_name="Republic of El Salvador" />
+	<iso_3166_entry
+		alpha_2_code="GQ"
+		alpha_3_code="GNQ"
+		numeric_code="226"
+		name="Equatorial Guinea"
+		official_name="Republic of Equatorial Guinea" />
+	<iso_3166_entry
+		alpha_2_code="ER"
+		alpha_3_code="ERI"
+		numeric_code="232"
+		name="Eritrea" />
+	<iso_3166_entry
+		alpha_2_code="EE"
+		alpha_3_code="EST"
+		numeric_code="233"
+		name="Estonia"
+		official_name="Republic of Estonia" />
+	<iso_3166_entry
+		alpha_2_code="ET"
+		alpha_3_code="ETH"
+		numeric_code="231"
+		name="Ethiopia"
+		official_name="Federal Democratic Republic of Ethiopia" />
+	<iso_3166_entry
+		alpha_2_code="FK"
+		alpha_3_code="FLK"
+		numeric_code="238"
+		name="Falkland Islands (Malvinas)" />
+	<iso_3166_entry
+		alpha_2_code="FO"
+		alpha_3_code="FRO"
+		numeric_code="234"
+		name="Faroe Islands" />
+	<iso_3166_entry
+		alpha_2_code="FJ"
+		alpha_3_code="FJI"
+		numeric_code="242"
+		name="Fiji"
+		official_name="Republic of Fiji" />
+	<iso_3166_entry
+		alpha_2_code="FI"
+		alpha_3_code="FIN"
+		numeric_code="246"
+		name="Finland"
+		official_name="Republic of Finland" />
+	<iso_3166_entry
+		alpha_2_code="FR"
+		alpha_3_code="FRA"
+		numeric_code="250"
+		name="France"
+		official_name="French Republic" />
+	<iso_3166_entry
+		alpha_2_code="GF"
+		alpha_3_code="GUF"
+		numeric_code="254"
+		name="French Guiana" />
+	<iso_3166_entry
+		alpha_2_code="PF"
+		alpha_3_code="PYF"
+		numeric_code="258"
+		name="French Polynesia" />
+	<iso_3166_entry
+		alpha_2_code="TF"
+		alpha_3_code="ATF"
+		numeric_code="260"
+		name="French Southern Territories" />
+	<iso_3166_entry
+		alpha_2_code="GA"
+		alpha_3_code="GAB"
+		numeric_code="266"
+		name="Gabon"
+		official_name="Gabonese Republic" />
+	<iso_3166_entry
+		alpha_2_code="GM"
+		alpha_3_code="GMB"
+		numeric_code="270"
+		name="Gambia"
+		official_name="Republic of the Gambia" />
+	<iso_3166_entry
+		alpha_2_code="GE"
+		alpha_3_code="GEO"
+		numeric_code="268"
+		name="Georgia" />
+	<iso_3166_entry
+		alpha_2_code="DE"
+		alpha_3_code="DEU"
+		numeric_code="276"
+		name="Germany"
+		official_name="Federal Republic of Germany" />
+	<iso_3166_entry
+		alpha_2_code="GH"
+		alpha_3_code="GHA"
+		numeric_code="288"
+		name="Ghana"
+		official_name="Republic of Ghana" />
+	<iso_3166_entry
+		alpha_2_code="GI"
+		alpha_3_code="GIB"
+		numeric_code="292"
+		name="Gibraltar" />
+	<iso_3166_entry
+		alpha_2_code="GR"
+		alpha_3_code="GRC"
+		numeric_code="300"
+		name="Greece"
+		official_name="Hellenic Republic" />
+	<iso_3166_entry
+		alpha_2_code="GL"
+		alpha_3_code="GRL"
+		numeric_code="304"
+		name="Greenland" />
+	<iso_3166_entry
+		alpha_2_code="GD"
+		alpha_3_code="GRD"
+		numeric_code="308"
+		name="Grenada" />
+	<iso_3166_entry
+		alpha_2_code="GP"
+		alpha_3_code="GLP"
+		numeric_code="312"
+		name="Guadeloupe" />
+	<iso_3166_entry
+		alpha_2_code="GU"
+		alpha_3_code="GUM"
+		numeric_code="316"
+		name="Guam" />
+	<iso_3166_entry
+		alpha_2_code="GT"
+		alpha_3_code="GTM"
+		numeric_code="320"
+		name="Guatemala"
+		official_name="Republic of Guatemala" />
+	<iso_3166_entry
+		alpha_2_code="GG"
+		alpha_3_code="GGY"
+		numeric_code="831"
+		name="Guernsey" />
+	<iso_3166_entry
+		alpha_2_code="GN"
+		alpha_3_code="GIN"
+		numeric_code="324"
+		name="Guinea"
+		official_name="Republic of Guinea" />
+	<iso_3166_entry
+		alpha_2_code="GW"
+		alpha_3_code="GNB"
+		numeric_code="624"
+		name="Guinea-Bissau"
+		official_name="Republic of Guinea-Bissau" />
+	<iso_3166_entry
+		alpha_2_code="GY"
+		alpha_3_code="GUY"
+		numeric_code="328"
+		name="Guyana"
+		official_name="Republic of Guyana" />
+	<iso_3166_entry
+		alpha_2_code="HT"
+		alpha_3_code="HTI"
+		numeric_code="332"
+		name="Haiti"
+		official_name="Republic of Haiti" />
+	<iso_3166_entry
+		alpha_2_code="HM"
+		alpha_3_code="HMD"
+		numeric_code="334"
+		name="Heard Island and McDonald Islands" />
+	<iso_3166_entry
+		alpha_2_code="VA"
+		alpha_3_code="VAT"
+		numeric_code="336"
+		name="Holy See (Vatican City State)" />
+	<iso_3166_entry
+		alpha_2_code="HN"
+		alpha_3_code="HND"
+		numeric_code="340"
+		name="Honduras"
+		official_name="Republic of Honduras" />
+	<iso_3166_entry
+		alpha_2_code="HK"
+		alpha_3_code="HKG"
+		numeric_code="344"
+		name="Hong Kong"
+		official_name="Hong Kong Special Administrative Region of China" />
+	<iso_3166_entry
+		alpha_2_code="HU"
+		alpha_3_code="HUN"
+		numeric_code="348"
+		name="Hungary"
+		official_name="Republic of Hungary" />
+	<iso_3166_entry
+		alpha_2_code="IS"
+		alpha_3_code="ISL"
+		numeric_code="352"
+		name="Iceland"
+		official_name="Republic of Iceland" />
+	<iso_3166_entry
+		alpha_2_code="IN"
+		alpha_3_code="IND"
+		numeric_code="356"
+		name="India"
+		official_name="Republic of India" />
+	<iso_3166_entry
+		alpha_2_code="ID"
+		alpha_3_code="IDN"
+		numeric_code="360"
+		name="Indonesia"
+		official_name="Republic of Indonesia" />
+	<iso_3166_entry
+		alpha_2_code="IR"
+		alpha_3_code="IRN"
+		numeric_code="364"
+		name="Iran, Islamic Republic of"
+		official_name="Islamic Republic of Iran" />
+	<iso_3166_entry
+		alpha_2_code="IQ"
+		alpha_3_code="IRQ"
+		numeric_code="368"
+		name="Iraq"
+		official_name="Republic of Iraq" />
+	<iso_3166_entry
+		alpha_2_code="IE"
+		alpha_3_code="IRL"
+		numeric_code="372"
+		name="Ireland" />
+	<iso_3166_entry
+		alpha_2_code="IM"
+		alpha_3_code="IMN"
+		numeric_code="833"
+		name="Isle of Man" />
+	<iso_3166_entry
+		alpha_2_code="IL"
+		alpha_3_code="ISR"
+		numeric_code="376"
+		name="Israel"
+		official_name="State of Israel" />
+	<iso_3166_entry
+		alpha_2_code="IT"
+		alpha_3_code="ITA"
+		numeric_code="380"
+		name="Italy"
+		official_name="Italian Republic" />
+	<iso_3166_entry
+		alpha_2_code="JM"
+		alpha_3_code="JAM"
+		numeric_code="388"
+		name="Jamaica" />
+	<iso_3166_entry
+		alpha_2_code="JP"
+		alpha_3_code="JPN"
+		numeric_code="392"
+		name="Japan" />
+	<iso_3166_entry
+		alpha_2_code="JE"
+		alpha_3_code="JEY"
+		numeric_code="832"
+		name="Jersey" />
+	<iso_3166_entry
+		alpha_2_code="JO"
+		alpha_3_code="JOR"
+		numeric_code="400"
+		name="Jordan"
+		official_name="Hashemite Kingdom of Jordan" />
+	<iso_3166_entry
+		alpha_2_code="KZ"
+		alpha_3_code="KAZ"
+		numeric_code="398"
+		name="Kazakhstan"
+		official_name="Republic of Kazakhstan" />
+	<iso_3166_entry
+		alpha_2_code="KE"
+		alpha_3_code="KEN"
+		numeric_code="404"
+		name="Kenya"
+		official_name="Republic of Kenya" />
+	<iso_3166_entry
+		alpha_2_code="KI"
+		alpha_3_code="KIR"
+		numeric_code="296"
+		name="Kiribati"
+		official_name="Republic of Kiribati" />
+	<iso_3166_entry
+		alpha_2_code="KP"
+		alpha_3_code="PRK"
+		numeric_code="408"
+		name="Korea, Democratic People's Republic of"
+		official_name="Democratic People's Republic of Korea" />
+	<iso_3166_entry
+		alpha_2_code="KR"
+		alpha_3_code="KOR"
+		numeric_code="410"
+		name="Korea, Republic of" />
+	<iso_3166_entry
+		alpha_2_code="KW"
+		alpha_3_code="KWT"
+		numeric_code="414"
+		name="Kuwait"
+		official_name="State of Kuwait" />
+	<iso_3166_entry
+		alpha_2_code="KG"
+		alpha_3_code="KGZ"
+		numeric_code="417"
+		name="Kyrgyzstan"
+		official_name="Kyrgyz Republic" />
+	<iso_3166_entry
+		alpha_2_code="LA"
+		alpha_3_code="LAO"
+		numeric_code="418"
+		name="Lao People's Democratic Republic" />
+	<iso_3166_entry
+		alpha_2_code="LV"
+		alpha_3_code="LVA"
+		numeric_code="428"
+		name="Latvia"
+		official_name="Republic of Latvia" />
+	<iso_3166_entry
+		alpha_2_code="LB"
+		alpha_3_code="LBN"
+		numeric_code="422"
+		name="Lebanon"
+		official_name="Lebanese Republic" />
+	<iso_3166_entry
+		alpha_2_code="LS"
+		alpha_3_code="LSO"
+		numeric_code="426"
+		name="Lesotho"
+		official_name="Kingdom of Lesotho" />
+	<iso_3166_entry
+		alpha_2_code="LR"
+		alpha_3_code="LBR"
+		numeric_code="430"
+		name="Liberia"
+		official_name="Republic of Liberia" />
+	<iso_3166_entry
+		alpha_2_code="LY"
+		alpha_3_code="LBY"
+		numeric_code="434"
+		common_name="Libya"
+		name="Libyan Arab Jamahiriya"
+		official_name="Socialist People's Libyan Arab Jamahiriya" />
+	<iso_3166_entry
+		alpha_2_code="LI"
+		alpha_3_code="LIE"
+		numeric_code="438"
+		name="Liechtenstein"
+		official_name="Principality of Liechtenstein" />
+	<iso_3166_entry
+		alpha_2_code="LT"
+		alpha_3_code="LTU"
+		numeric_code="440"
+		name="Lithuania"
+		official_name="Republic of Lithuania" />
+	<iso_3166_entry
+		alpha_2_code="LU"
+		alpha_3_code="LUX"
+		numeric_code="442"
+		name="Luxembourg"
+		official_name="Grand Duchy of Luxembourg" />
+	<iso_3166_entry
+		alpha_2_code="MO"
+		alpha_3_code="MAC"
+		numeric_code="446"
+		name="Macao"
+		official_name="Macao Special Administrative Region of China" />
+	<iso_3166_entry
+		alpha_2_code="MK"
+		alpha_3_code="MKD"
+		numeric_code="807"
+		name="Macedonia, Republic of"
+		official_name="The Former Yugoslav Republic of Macedonia" />
+	<iso_3166_entry
+		alpha_2_code="MG"
+		alpha_3_code="MDG"
+		numeric_code="450"
+		name="Madagascar"
+		official_name="Republic of Madagascar" />
+	<iso_3166_entry
+		alpha_2_code="MW"
+		alpha_3_code="MWI"
+		numeric_code="454"
+		name="Malawi"
+		official_name="Republic of Malawi" />
+	<iso_3166_entry
+		alpha_2_code="MY"
+		alpha_3_code="MYS"
+		numeric_code="458"
+		name="Malaysia" />
+	<iso_3166_entry
+		alpha_2_code="MV"
+		alpha_3_code="MDV"
+		numeric_code="462"
+		name="Maldives"
+		official_name="Republic of Maldives" />
+	<iso_3166_entry
+		alpha_2_code="ML"
+		alpha_3_code="MLI"
+		numeric_code="466"
+		name="Mali"
+		official_name="Republic of Mali" />
+	<iso_3166_entry
+		alpha_2_code="MT"
+		alpha_3_code="MLT"
+		numeric_code="470"
+		name="Malta"
+		official_name="Republic of Malta" />
+	<iso_3166_entry
+		alpha_2_code="MH"
+		alpha_3_code="MHL"
+		numeric_code="584"
+		name="Marshall Islands"
+		official_name="Republic of the Marshall Islands" />
+	<iso_3166_entry
+		alpha_2_code="MQ"
+		alpha_3_code="MTQ"
+		numeric_code="474"
+		name="Martinique" />
+	<iso_3166_entry
+		alpha_2_code="MR"
+		alpha_3_code="MRT"
+		numeric_code="478"
+		name="Mauritania"
+		official_name="Islamic Republic of Mauritania" />
+	<iso_3166_entry
+		alpha_2_code="MU"
+		alpha_3_code="MUS"
+		numeric_code="480"
+		name="Mauritius"
+		official_name="Republic of Mauritius" />
+	<iso_3166_entry
+		alpha_2_code="YT"
+		alpha_3_code="MYT"
+		numeric_code="175"
+		name="Mayotte" />
+	<iso_3166_entry
+		alpha_2_code="MX"
+		alpha_3_code="MEX"
+		numeric_code="484"
+		name="Mexico"
+		official_name="United Mexican States" />
+	<iso_3166_entry
+		alpha_2_code="FM"
+		alpha_3_code="FSM"
+		numeric_code="583"
+		name="Micronesia, Federated States of"
+		official_name="Federated States of Micronesia" />
+	<iso_3166_entry
+		alpha_2_code="MD"
+		alpha_3_code="MDA"
+		numeric_code="498"
+		common_name="Moldova"
+		name="Moldova, Republic of"
+		official_name="Republic of Moldova" />
+	<iso_3166_entry
+		alpha_2_code="MC"
+		alpha_3_code="MCO"
+		numeric_code="492"
+		name="Monaco"
+		official_name="Principality of Monaco" />
+	<iso_3166_entry
+		alpha_2_code="MN"
+		alpha_3_code="MNG"
+		numeric_code="496"
+		name="Mongolia" />
+	<iso_3166_entry
+		alpha_2_code="ME"
+		alpha_3_code="MNE"
+		numeric_code="499"
+		name="Montenegro"
+		official_name="Montenegro" />
+	<iso_3166_entry
+		alpha_2_code="MS"
+		alpha_3_code="MSR"
+		numeric_code="500"
+		name="Montserrat" />
+	<iso_3166_entry
+		alpha_2_code="MA"
+		alpha_3_code="MAR"
+		numeric_code="504"
+		name="Morocco"
+		official_name="Kingdom of Morocco" />
+	<iso_3166_entry
+		alpha_2_code="MZ"
+		alpha_3_code="MOZ"
+		numeric_code="508"
+		name="Mozambique"
+		official_name="Republic of Mozambique" />
+	<iso_3166_entry
+		alpha_2_code="MM"
+		alpha_3_code="MMR"
+		numeric_code="104"
+		name="Myanmar"
+		official_name="Republic of Myanmar" />
+	<iso_3166_entry
+		alpha_2_code="NA"
+		alpha_3_code="NAM"
+		numeric_code="516"
+		name="Namibia"
+		official_name="Republic of Namibia" />
+	<iso_3166_entry
+		alpha_2_code="NR"
+		alpha_3_code="NRU"
+		numeric_code="520"
+		name="Nauru"
+		official_name="Republic of Nauru" />
+	<iso_3166_entry
+		alpha_2_code="NP"
+		alpha_3_code="NPL"
+		numeric_code="524"
+		name="Nepal"
+		official_name="Federal Democratic Republic of Nepal" />
+	<iso_3166_entry
+		alpha_2_code="NL"
+		alpha_3_code="NLD"
+		numeric_code="528"
+		name="Netherlands"
+		official_name="Kingdom of the Netherlands" />
+	<iso_3166_entry
+		alpha_2_code="NC"
+		alpha_3_code="NCL"
+		numeric_code="540"
+		name="New Caledonia" />
+	<iso_3166_entry
+		alpha_2_code="NZ"
+		alpha_3_code="NZL"
+		numeric_code="554"
+		name="New Zealand" />
+	<iso_3166_entry
+		alpha_2_code="NI"
+		alpha_3_code="NIC"
+		numeric_code="558"
+		name="Nicaragua"
+		official_name="Republic of Nicaragua" />
+	<iso_3166_entry
+		alpha_2_code="NE"
+		alpha_3_code="NER"
+		numeric_code="562"
+		name="Niger"
+		official_name="Republic of the Niger" />
+	<iso_3166_entry
+		alpha_2_code="NG"
+		alpha_3_code="NGA"
+		numeric_code="566"
+		name="Nigeria"
+		official_name="Federal Republic of Nigeria" />
+	<iso_3166_entry
+		alpha_2_code="NU"
+		alpha_3_code="NIU"
+		numeric_code="570"
+		name="Niue"
+		official_name="Niue" />
+	<iso_3166_entry
+		alpha_2_code="NF"
+		alpha_3_code="NFK"
+		numeric_code="574"
+		name="Norfolk Island" />
+	<iso_3166_entry
+		alpha_2_code="MP"
+		alpha_3_code="MNP"
+		numeric_code="580"
+		name="Northern Mariana Islands"
+		official_name="Commonwealth of the Northern Mariana Islands" />
+	<iso_3166_entry
+		alpha_2_code="NO"
+		alpha_3_code="NOR"
+		numeric_code="578"
+		name="Norway"
+		official_name="Kingdom of Norway" />
+	<iso_3166_entry
+		alpha_2_code="OM"
+		alpha_3_code="OMN"
+		numeric_code="512"
+		name="Oman"
+		official_name="Sultanate of Oman" />
+	<iso_3166_entry
+		alpha_2_code="PK"
+		alpha_3_code="PAK"
+		numeric_code="586"
+		name="Pakistan"
+		official_name="Islamic Republic of Pakistan" />
+	<iso_3166_entry
+		alpha_2_code="PW"
+		alpha_3_code="PLW"
+		numeric_code="585"
+		name="Palau"
+		official_name="Republic of Palau" />
+	<iso_3166_entry
+		alpha_2_code="PS"
+		alpha_3_code="PSE"
+		numeric_code="275"
+		name="Palestinian Territory, Occupied"
+		official_name="Occupied Palestinian Territory" />
+	<iso_3166_entry
+		alpha_2_code="PA"
+		alpha_3_code="PAN"
+		numeric_code="591"
+		name="Panama"
+		official_name="Republic of Panama" />
+	<iso_3166_entry
+		alpha_2_code="PG"
+		alpha_3_code="PNG"
+		numeric_code="598"
+		name="Papua New Guinea" />
+	<iso_3166_entry
+		alpha_2_code="PY"
+		alpha_3_code="PRY"
+		numeric_code="600"
+		name="Paraguay"
+		official_name="Republic of Paraguay" />
+	<iso_3166_entry
+		alpha_2_code="PE"
+		alpha_3_code="PER"
+		numeric_code="604"
+		name="Peru"
+		official_name="Republic of Peru" />
+	<iso_3166_entry
+		alpha_2_code="PH"
+		alpha_3_code="PHL"
+		numeric_code="608"
+		name="Philippines"
+		official_name="Republic of the Philippines" />
+	<iso_3166_entry
+		alpha_2_code="PN"
+		alpha_3_code="PCN"
+		numeric_code="612"
+		name="Pitcairn" />
+	<iso_3166_entry
+		alpha_2_code="PL"
+		alpha_3_code="POL"
+		numeric_code="616"
+		name="Poland"
+		official_name="Republic of Poland" />
+	<iso_3166_entry
+		alpha_2_code="PT"
+		alpha_3_code="PRT"
+		numeric_code="620"
+		name="Portugal"
+		official_name="Portuguese Republic" />
+	<iso_3166_entry
+		alpha_2_code="PR"
+		alpha_3_code="PRI"
+		numeric_code="630"
+		name="Puerto Rico" />
+	<iso_3166_entry
+		alpha_2_code="QA"
+		alpha_3_code="QAT"
+		numeric_code="634"
+		name="Qatar"
+		official_name="State of Qatar" />
+	<iso_3166_entry
+		alpha_2_code="RE"
+		alpha_3_code="REU"
+		numeric_code="638"
+		name="Reunion" />
+	<iso_3166_entry
+		alpha_2_code="RO"
+		alpha_3_code="ROU"
+		numeric_code="642"
+		name="Romania" />
+	<iso_3166_entry
+		alpha_2_code="RU"
+		alpha_3_code="RUS"
+		numeric_code="643"
+		name="Russian Federation" />
+	<iso_3166_entry
+		alpha_2_code="RW"
+		alpha_3_code="RWA"
+		numeric_code="646"
+		name="Rwanda"
+		official_name="Rwandese Republic" />
+	<iso_3166_entry
+		alpha_2_code="BL"
+		alpha_3_code="BLM"
+		numeric_code="652"
+		name="Saint Barthélemy" />
+	<iso_3166_entry
+		alpha_2_code="SH"
+		alpha_3_code="SHN"
+		numeric_code="654"
+		name="Saint Helena, Ascension and Tristan da Cunha" />
+	<iso_3166_entry
+		alpha_2_code="KN"
+		alpha_3_code="KNA"
+		numeric_code="659"
+		name="Saint Kitts and Nevis" />
+	<iso_3166_entry
+		alpha_2_code="LC"
+		alpha_3_code="LCA"
+		numeric_code="662"
+		name="Saint Lucia" />
+	<iso_3166_entry
+		alpha_2_code="MF"
+		alpha_3_code="MAF"
+		numeric_code="663"
+		name="Saint Martin (French part)" />
+	<iso_3166_entry
+		alpha_2_code="PM"
+		alpha_3_code="SPM"
+		numeric_code="666"
+		name="Saint Pierre and Miquelon" />
+	<iso_3166_entry
+		alpha_2_code="VC"
+		alpha_3_code="VCT"
+		numeric_code="670"
+		name="Saint Vincent and the Grenadines" />
+	<iso_3166_entry
+		alpha_2_code="WS"
+		alpha_3_code="WSM"
+		numeric_code="882"
+		name="Samoa"
+		official_name="Independent State of Samoa" />
+	<iso_3166_entry
+		alpha_2_code="SM"
+		alpha_3_code="SMR"
+		numeric_code="674"
+		name="San Marino"
+		official_name="Republic of San Marino" />
+	<iso_3166_entry
+		alpha_2_code="ST"
+		alpha_3_code="STP"
+		numeric_code="678"
+		name="Sao Tome and Principe"
+		official_name="Democratic Republic of Sao Tome and Principe" />
+	<iso_3166_entry
+		alpha_2_code="SA"
+		alpha_3_code="SAU"
+		numeric_code="682"
+		name="Saudi Arabia"
+		official_name="Kingdom of Saudi Arabia" />
+	<iso_3166_entry
+		alpha_2_code="SN"
+		alpha_3_code="SEN"
+		numeric_code="686"
+		name="Senegal"
+		official_name="Republic of Senegal" />
+	<iso_3166_entry
+		alpha_2_code="RS"
+		alpha_3_code="SRB"
+		numeric_code="688"
+		name="Serbia"
+		official_name="Republic of Serbia" />
+	<iso_3166_entry
+		alpha_2_code="SC"
+		alpha_3_code="SYC"
+		numeric_code="690"
+		name="Seychelles"
+		official_name="Republic of Seychelles" />
+	<iso_3166_entry
+		alpha_2_code="SL"
+		alpha_3_code="SLE"
+		numeric_code="694"
+		name="Sierra Leone"
+		official_name="Republic of Sierra Leone" />
+	<iso_3166_entry
+		alpha_2_code="SG"
+		alpha_3_code="SGP"
+		numeric_code="702"
+		name="Singapore"
+		official_name="Republic of Singapore" />
+	<iso_3166_entry
+		alpha_2_code="SX"
+		alpha_3_code="SXM"
+		numeric_code="702"
+		name="Sint Maarten"
+		official_name="Sint Maarten (Dutch part)" />
+	<iso_3166_entry
+		alpha_2_code="SK"
+		alpha_3_code="SVK"
+		numeric_code="703"
+		name="Slovakia"
+		official_name="Slovak Republic" />
+	<iso_3166_entry
+		alpha_2_code="SI"
+		alpha_3_code="SVN"
+		numeric_code="705"
+		name="Slovenia"
+		official_name="Republic of Slovenia" />
+	<iso_3166_entry
+		alpha_2_code="SB"
+		alpha_3_code="SLB"
+		numeric_code="090"
+		name="Solomon Islands" />
+	<iso_3166_entry
+		alpha_2_code="SO"
+		alpha_3_code="SOM"
+		numeric_code="706"
+		name="Somalia"
+		official_name="Somali Republic" />
+	<iso_3166_entry
+		alpha_2_code="ZA"
+		alpha_3_code="ZAF"
+		numeric_code="710"
+		name="South Africa"
+		official_name="Republic of South Africa" />
+	<iso_3166_entry
+		alpha_2_code="GS"
+		alpha_3_code="SGS"
+		numeric_code="239"
+		name="South Georgia and the South Sandwich Islands" />
+	<iso_3166_entry
+		alpha_2_code="ES"
+		alpha_3_code="ESP"
+		numeric_code="724"
+		name="Spain"
+		official_name="Kingdom of Spain" />
+	<iso_3166_entry
+		alpha_2_code="LK"
+		alpha_3_code="LKA"
+		numeric_code="144"
+		name="Sri Lanka"
+		official_name="Democratic Socialist Republic of Sri Lanka" />
+	<iso_3166_entry
+		alpha_2_code="SD"
+		alpha_3_code="SDN"
+		numeric_code="736"
+		name="Sudan"
+		official_name="Republic of the Sudan" />
+	<iso_3166_entry
+		alpha_2_code="SR"
+		alpha_3_code="SUR"
+		numeric_code="740"
+		name="Suriname"
+		official_name="Republic of Suriname" />
+	<iso_3166_entry
+		alpha_2_code="SJ"
+		alpha_3_code="SJM"
+		numeric_code="744"
+		name="Svalbard and Jan Mayen" />
+	<iso_3166_entry
+		alpha_2_code="SZ"
+		alpha_3_code="SWZ"
+		numeric_code="748"
+		name="Swaziland"
+		official_name="Kingdom of Swaziland" />
+	<iso_3166_entry
+		alpha_2_code="SE"
+		alpha_3_code="SWE"
+		numeric_code="752"
+		name="Sweden"
+		official_name="Kingdom of Sweden" />
+	<iso_3166_entry
+		alpha_2_code="CH"
+		alpha_3_code="CHE"
+		numeric_code="756"
+		name="Switzerland"
+		official_name="Swiss Confederation" />
+	<iso_3166_entry
+		alpha_2_code="SY"
+		alpha_3_code="SYR"
+		numeric_code="760"
+		name="Syrian Arab Republic" />
+	<iso_3166_entry
+		alpha_2_code="TW"
+		alpha_3_code="TWN"
+		numeric_code="158"
+		common_name="Taiwan"
+		name="Taiwan, Province of China"
+		official_name="Taiwan, Province of China" />
+	<iso_3166_entry
+		alpha_2_code="TJ"
+		alpha_3_code="TJK"
+		numeric_code="762"
+		name="Tajikistan"
+		official_name="Republic of Tajikistan" />
+	<iso_3166_entry
+		alpha_2_code="TZ"
+		alpha_3_code="TZA"
+		numeric_code="834"
+		name="Tanzania, United Republic of"
+		official_name="United Republic of Tanzania" />
+	<iso_3166_entry
+		alpha_2_code="TH"
+		alpha_3_code="THA"
+		numeric_code="764"
+		name="Thailand"
+		official_name="Kingdom of Thailand" />
+	<iso_3166_entry
+		alpha_2_code="TL"
+		alpha_3_code="TLS"
+		numeric_code="626"
+		name="Timor-Leste"
+		official_name="Democratic Republic of Timor-Leste" />
+	<iso_3166_entry
+		alpha_2_code="TG"
+		alpha_3_code="TGO"
+		numeric_code="768"
+		name="Togo"
+		official_name="Togolese Republic" />
+	<iso_3166_entry
+		alpha_2_code="TK"
+		alpha_3_code="TKL"
+		numeric_code="772"
+		name="Tokelau" />
+	<iso_3166_entry
+		alpha_2_code="TO"
+		alpha_3_code="TON"
+		numeric_code="776"
+		name="Tonga"
+		official_name="Kingdom of Tonga" />
+	<iso_3166_entry
+		alpha_2_code="TT"
+		alpha_3_code="TTO"
+		numeric_code="780"
+		name="Trinidad and Tobago"
+		official_name="Republic of Trinidad and Tobago" />
+	<iso_3166_entry
+		alpha_2_code="TN"
+		alpha_3_code="TUN"
+		numeric_code="788"
+		name="Tunisia"
+		official_name="Republic of Tunisia" />
+	<iso_3166_entry
+		alpha_2_code="TR"
+		alpha_3_code="TUR"
+		numeric_code="792"
+		name="Turkey"
+		official_name="Republic of Turkey" />
+	<iso_3166_entry
+		alpha_2_code="TM"
+		alpha_3_code="TKM"
+		numeric_code="795"
+		name="Turkmenistan" />
+	<iso_3166_entry
+		alpha_2_code="TC"
+		alpha_3_code="TCA"
+		numeric_code="796"
+		name="Turks and Caicos Islands" />
+	<iso_3166_entry
+		alpha_2_code="TV"
+		alpha_3_code="TUV"
+		numeric_code="798"
+		name="Tuvalu" />
+	<iso_3166_entry
+		alpha_2_code="UG"
+		alpha_3_code="UGA"
+		numeric_code="800"
+		name="Uganda"
+		official_name="Republic of Uganda" />
+	<iso_3166_entry
+		alpha_2_code="UA"
+		alpha_3_code="UKR"
+		numeric_code="804"
+		name="Ukraine" />
+	<iso_3166_entry
+		alpha_2_code="AE"
+		alpha_3_code="ARE"
+		numeric_code="784"
+		name="United Arab Emirates" />
+	<iso_3166_entry
+		alpha_2_code="GB"
+		alpha_3_code="GBR"
+		numeric_code="826"
+		name="United Kingdom"
+		official_name="United Kingdom of Great Britain and Northern Ireland" />
+	<iso_3166_entry
+		alpha_2_code="US"
+		alpha_3_code="USA"
+		numeric_code="840"
+		name="United States"
+		official_name="United States of America" />
+	<iso_3166_entry
+		alpha_2_code="UM"
+		alpha_3_code="UMI"
+		numeric_code="581"
+		name="United States Minor Outlying Islands" />
+	<iso_3166_entry
+		alpha_2_code="UY"
+		alpha_3_code="URY"
+		numeric_code="858"
+		name="Uruguay"
+		official_name="Eastern Republic of Uruguay" />
+	<iso_3166_entry
+		alpha_2_code="UZ"
+		alpha_3_code="UZB"
+		numeric_code="860"
+		name="Uzbekistan"
+		official_name="Republic of Uzbekistan" />
+	<iso_3166_entry
+		alpha_2_code="VU"
+		alpha_3_code="VUT"
+		numeric_code="548"
+		name="Vanuatu"
+		official_name="Republic of Vanuatu" />
+	<iso_3166_entry
+		alpha_2_code="VE"
+		alpha_3_code="VEN"
+		numeric_code="862"
+		common_name="Venezuela"
+		name="Venezuela, Bolivarian republic of"
+		official_name="Bolivarian Republic of Venezuela" />
+	<iso_3166_entry
+		alpha_2_code="VN"
+		alpha_3_code="VNM"
+		numeric_code="704"
+		name="Viet Nam"
+		official_name="Socialist Republic of Viet Nam" />
+	<!-- FIXME CHECK OFFICIAL NAME -->
+	<iso_3166_entry
+		alpha_2_code="VG"
+		alpha_3_code="VGB"
+		numeric_code="092"
+		name="Virgin Islands, British"
+		official_name="British Virgin Islands" />
+	<iso_3166_entry
+		alpha_2_code="VI"
+		alpha_3_code="VIR"
+		numeric_code="850"
+		name="Virgin Islands, U.S."
+		official_name="Virgin Islands of the United States" />
+	<iso_3166_entry
+		alpha_2_code="WF"
+		alpha_3_code="WLF"
+		numeric_code="876"
+		name="Wallis and Futuna" />
+	<iso_3166_entry
+		alpha_2_code="EH"
+		alpha_3_code="ESH"
+		numeric_code="732"
+		name="Western Sahara" />
+	<iso_3166_entry
+		alpha_2_code="YE"
+		alpha_3_code="YEM"
+		numeric_code="887"
+		name="Yemen"
+		official_name="Republic of Yemen" />
+	<iso_3166_entry
+		alpha_2_code="ZM"
+		alpha_3_code="ZMB"
+		numeric_code="894"
+		name="Zambia"
+		official_name="Republic of Zambia" />
+	<iso_3166_entry
+		alpha_2_code="ZW"
+		alpha_3_code="ZWE"
+		numeric_code="716"
+		name="Zimbabwe"
+		official_name="Republic of Zimbabwe" />
+	<iso_3166_3_entry
+		alpha_4_code="BQAQ"
+		alpha_3_code="ATB"
+		date_withdrawn="1979"
+		names="British Antarctic Territory" />
+	<iso_3166_3_entry
+		alpha_4_code="BUMM"
+		alpha_3_code="BUR"
+		numeric_code="104"
+		date_withdrawn="1989-12-05"
+		names="Burma, Socialist Republic of the Union of" />
+	<iso_3166_3_entry
+		alpha_4_code="BYAA"
+		alpha_3_code="BYS"
+		numeric_code="112"
+		date_withdrawn="1992-06-15"
+		names="Byelorussian SSR Soviet Socialist Republic" />
+	<iso_3166_3_entry
+		alpha_4_code="CTKI"
+		alpha_3_code="CTE"
+		numeric_code="128"
+		date_withdrawn="1984"
+		names="Canton and Enderbury Islands" />
+	<iso_3166_3_entry
+		alpha_4_code="CSHH"
+		alpha_3_code="CSK"
+		numeric_code="200"
+		date_withdrawn="1993-06-15"
+		names="Czechoslovakia, Czechoslovak Socialist Republic" />
+	<iso_3166_3_entry
+		alpha_4_code="DYBJ"
+		alpha_3_code="DHY"
+		numeric_code="204"
+		date_withdrawn="1977"
+		names="Dahomey" />
+	<iso_3166_3_entry
+		alpha_4_code="NQAQ"
+		alpha_3_code="ATN"
+		numeric_code="216"
+		date_withdrawn="1983"
+		names="Dronning Maud Land" />
+	<iso_3166_3_entry
+		alpha_4_code="TPTL"
+		alpha_3_code="TMP"
+		numeric_code="626"
+		date_withdrawn="2002-05-20"
+		names="East Timor"
+		comment="was Portuguese Timor" />
+	<iso_3166_3_entry
+		alpha_4_code="ET"
+		alpha_3_code="ETH"
+		numeric_code="230"
+		date_withdrawn="1993-07-16"
+		names="Ethiopia" />
+	<iso_3166_3_entry
+		alpha_4_code="FXFR"
+		alpha_3_code="FXX"
+		numeric_code="249"
+		date_withdrawn="1997-07-14"
+		names="France, Metropolitan" />
+	<iso_3166_3_entry
+		alpha_4_code="AIDJ"
+		alpha_3_code="AFI"
+		numeric_code="262"
+		date_withdrawn="1977"
+		names="French Afars and Issas" />
+	<iso_3166_3_entry
+		alpha_4_code="FQHH"
+		alpha_3_code="ATF"
+		date_withdrawn="1979"
+		names="French Southern and Antarctic Territories"
+		comment="now split between AQ and TF" />
+	<iso_3166_3_entry
+		alpha_4_code="DDDE"
+		alpha_3_code="DDR"
+		numeric_code="278"
+		date_withdrawn="1990-10-30"
+		names="German Democratic Republic" />
+	<iso_3166_3_entry
+		alpha_4_code="DE"
+		alpha_3_code="DEU"
+		numeric_code="280"
+		date_withdrawn="1990-10-30"
+		names="Germany, Federal Republic of" />
+	<iso_3166_3_entry
+		alpha_4_code="GEHH"
+		alpha_3_code="GEL"
+		numeric_code="296"
+		date_withdrawn="1979"
+		names="Gilbert and Ellice Islands"
+		comment="now split into Kiribati and Tuvalu" />
+	<iso_3166_3_entry
+		alpha_4_code="JTUM"
+		alpha_3_code="JTN"
+		numeric_code="396"
+		date_withdrawn="1986"
+		names="Johnston Island" />
+	<iso_3166_3_entry
+		alpha_4_code="MIUM"
+		alpha_3_code="MID"
+		numeric_code="488"
+		date_withdrawn="1986"
+		names="Midway Islands" />
+	<iso_3166_3_entry
+		alpha_4_code="AN"
+		alpha_3_code="ANT"
+		numeric_code="532"
+		date_withdrawn="1993-07-12"
+		names="Netherlands Antilles" />
+	<iso_3166_3_entry
+		alpha_4_code="NTHH"
+		alpha_3_code="NTZ"
+		numeric_code="536"
+		date_withdrawn="1993-07-12"
+		names="Neutral Zone"
+		comment="formerly between Saudi Arabia and Iraq" />
+	<iso_3166_3_entry
+		alpha_4_code="NHVU"
+		alpha_3_code="NHB"
+		numeric_code="548"
+		date_withdrawn="1980"
+		names="New Hebrides" />
+	<iso_3166_3_entry
+		alpha_4_code="PCHH"
+		alpha_3_code="PCI"
+		numeric_code="582"
+		date_withdrawn="1986"
+		names="Pacific Islands (trust territory)"
+		comment="divided into FM, MH, MP, and PW" />
+	<iso_3166_3_entry
+		alpha_4_code="PA"
+		alpha_3_code="PAN"
+		numeric_code="590"
+		date_withdrawn="1993-07-22"
+		names="Panama, Republic of" />
+	<iso_3166_3_entry
+		alpha_4_code="PZPA"
+		alpha_3_code="PCZ"
+		date_withdrawn="1980"
+		names="Panama Canal Zone" />
+	<iso_3166_3_entry
+		alpha_4_code="RO"
+		alpha_3_code="ROM"
+		numeric_code="642"
+		date_withdrawn="2002-02-01"
+		names="Romania, Socialist Republic of" />
+	<iso_3166_3_entry
+		alpha_4_code="KN"
+		alpha_3_code="KNA"
+		numeric_code="658"
+		date_withdrawn="1988"
+		names="St. Kitts-Nevis-Anguilla"
+		comment="now St. Kitts and Nevis and Anguilla" />
+	<iso_3166_3_entry
+		alpha_4_code="CSXX"
+		alpha_3_code="SCG"
+		numeric_code="891"
+		date_withdrawn="2006-06-05"
+		names="Serbia and Montenegro" />
+	<iso_3166_3_entry
+		alpha_4_code="SKIN"
+		alpha_3_code="SKM"
+		date_withdrawn="1975"
+		names="Sikkim" />
+	<iso_3166_3_entry
+		alpha_4_code="RHZW"
+		alpha_3_code="RHO"
+		numeric_code="716"
+		date_withdrawn="1980"
+		names="Southern Rhodesia" />
+	<iso_3166_3_entry
+		alpha_4_code="EH"
+		alpha_3_code="ESH"
+		numeric_code="732"
+		date_withdrawn="1988"
+		names="Spanish Sahara"
+		comment="now Western Sahara" />
+	<iso_3166_3_entry
+		alpha_4_code="PUUM"
+		alpha_3_code="PUS"
+		numeric_code="849"
+		date_withdrawn="1986"
+		names="US Miscellaneous Pacific Islands" />
+	<iso_3166_3_entry
+		alpha_4_code="SUHH"
+		alpha_3_code="SUN"
+		numeric_code="810"
+		date_withdrawn="1992-08-30"
+		names="USSR, Union of Soviet Socialist Republics" />
+	<iso_3166_3_entry
+		alpha_4_code="HVBF"
+		alpha_3_code="HVO"
+		numeric_code="854"
+		date_withdrawn="1984"
+		names="Upper Volta, Republic of" />
+	<iso_3166_3_entry
+		alpha_4_code="VA"
+		alpha_3_code="VAT"
+		numeric_code="336"
+		date_withdrawn="1996-04-03"
+		names="Vatican City State (Holy See)" />
+	<iso_3166_3_entry
+		alpha_4_code="VDVN"
+		alpha_3_code="VDR"
+		date_withdrawn="1977"
+		names="Viet-Nam, Democratic Republic of" />
+	<iso_3166_3_entry
+		alpha_4_code="WKUM"
+		alpha_3_code="WAK"
+		numeric_code="872"
+		date_withdrawn="1986"
+		names="Wake Island" />
+	<iso_3166_3_entry
+		alpha_4_code="YDYE"
+		alpha_3_code="YMD"
+		numeric_code="720"
+		date_withdrawn="1990-08-14"
+		names="Yemen, Democratic, People's Democratic Republic of" />
+	<iso_3166_3_entry
+		alpha_4_code="YE"
+		alpha_3_code="YEM"
+		numeric_code="891"
+		date_withdrawn="1990-08-14"
+		names="Yemen, Yemen Arab Republic" />
+	<iso_3166_3_entry
+		alpha_4_code="YUCS"
+		alpha_3_code="YUG"
+		numeric_code="891"
+		date_withdrawn="1993-07-28"
+		names="Yugoslavia, Socialist Federal Republic of" />
+	<iso_3166_3_entry
+		alpha_4_code="ZRCD"
+		alpha_3_code="ZAR"
+		numeric_code="180"
+		date_withdrawn="1997-07-14"
+		names="Zaire, Republic of" />
+</iso_3166_entries>
diff --git a/win32/copy/share/xml/iso-codes/iso_639.xml b/win32/copy/share/xml/iso-codes/iso_639.xml
new file mode 100644
index 00000000..02fa01fb
--- /dev/null
+++ b/win32/copy/share/xml/iso-codes/iso_639.xml
@@ -0,0 +1,2169 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+
+<!--
+This file gives a list of all languages in the ISO 639
+standard, and is used to provide translations via gettext
+
+Copyright (C) 2004-2006 Alastair McKinstry <mckinstry@computer.org>
+Copyright (C) 2004-2009 Christian Perrier <bubulle@debian.org>
+Copyright (C) 2005-2008 Tobias Quathamer <toddy@debian.org>
+
+    This file is free software; you can redistribute it and/or
+    modify it under the terms of the GNU Lesser General Public
+    License as published by the Free Software Foundation; either
+    version 2.1 of the License, or (at your option) any later version.
+
+    This file is distributed in the hope that it will be useful,
+    but WITHOUT ANY WARRANTY; without even the implied warranty of
+    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+    Lesser General Public License for more details.
+
+    You should have received a copy of the GNU Lesser General Public
+    License along with this file; if not, write to the Free Software
+    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
+
+Source: <http://www.loc.gov/standards/iso639-2/>
+-->
+
+<!DOCTYPE iso_639_entries [
+	<!ELEMENT iso_639_entries (iso_639_entry+)>
+	<!ELEMENT iso_639_entry EMPTY>
+	<!ATTLIST iso_639_entry
+		iso_639_2B_code		CDATA	#REQUIRED
+		iso_639_2T_code		CDATA	#REQUIRED
+		iso_639_1_code		CDATA	#IMPLIED
+		name			CDATA	#REQUIRED
+	>
+]>
+
+<iso_639_entries>
+	<iso_639_entry
+		iso_639_2B_code="aar"
+		iso_639_2T_code="aar"
+		iso_639_1_code="aa"
+		name="Afar" />
+	<iso_639_entry
+		iso_639_2B_code="abk"
+		iso_639_2T_code="abk"
+		iso_639_1_code="ab"
+		name="Abkhazian" />
+	<iso_639_entry
+		iso_639_2B_code="ace"
+		iso_639_2T_code="ace"
+		name="Achinese" />
+	<iso_639_entry
+		iso_639_2B_code="ach"
+		iso_639_2T_code="ach"
+		name="Acoli" />
+	<iso_639_entry
+		iso_639_2B_code="ada"
+		iso_639_2T_code="ada"
+		name="Adangme" />
+	<iso_639_entry
+		iso_639_2B_code="ady"
+		iso_639_2T_code="ady"
+		name="Adyghe; Adygei" />
+	<iso_639_entry
+		iso_639_2B_code="afa"
+		iso_639_2T_code="afa"
+		name="Afro-Asiatic languages" />
+	<iso_639_entry
+		iso_639_2B_code="afh"
+		iso_639_2T_code="afh"
+		name="Afrihili" />
+	<iso_639_entry
+		iso_639_2B_code="afr"
+		iso_639_2T_code="afr"
+		iso_639_1_code="af"
+		name="Afrikaans" />
+	<iso_639_entry
+		iso_639_2B_code="ain"
+		iso_639_2T_code="ain"
+		name="Ainu" />
+	<iso_639_entry
+		iso_639_2B_code="aka"
+		iso_639_2T_code="aka"
+		iso_639_1_code="ak"
+		name="Akan" />
+	<iso_639_entry
+		iso_639_2B_code="akk"
+		iso_639_2T_code="akk"
+		name="Akkadian" />
+	<iso_639_entry
+		iso_639_2B_code="alb"
+		iso_639_2T_code="sqi"
+		iso_639_1_code="sq"
+		name="Albanian" />
+	<iso_639_entry
+		iso_639_2B_code="ale"
+		iso_639_2T_code="ale"
+		name="Aleut" />
+	<iso_639_entry
+		iso_639_2B_code="alg"
+		iso_639_2T_code="alg"
+		name="Algonquian languages" />
+	<iso_639_entry
+		iso_639_2B_code="alt"
+		iso_639_2T_code="alt"
+		name="Southern Altai" />
+	<iso_639_entry
+		iso_639_2B_code="amh"
+		iso_639_2T_code="amh"
+		iso_639_1_code="am"
+		name="Amharic" />
+	<iso_639_entry
+		iso_639_2B_code="ang"
+		iso_639_2T_code="ang"
+		name="English, Old (ca. 450-1100)" />
+	<iso_639_entry
+		iso_639_2B_code="anp"
+		iso_639_2T_code="anp"
+		name="Angika" />
+	<iso_639_entry
+		iso_639_2B_code="apa"
+		iso_639_2T_code="apa"
+		name="Apache languages" />
+	<iso_639_entry
+		iso_639_2B_code="ara"
+		iso_639_2T_code="ara"
+		iso_639_1_code="ar"
+		name="Arabic" />
+	<iso_639_entry
+		iso_639_2B_code="arc"
+		iso_639_2T_code="arc"
+		name="Official Aramaic (700-300 BCE); Imperial Aramaic (700-300 BCE)" />
+	<iso_639_entry
+		iso_639_2B_code="arg"
+		iso_639_2T_code="arg"
+		iso_639_1_code="an"
+		name="Aragonese" />
+	<iso_639_entry
+		iso_639_2B_code="arm"
+		iso_639_2T_code="hye"
+		iso_639_1_code="hy"
+		name="Armenian" />
+	<iso_639_entry
+		iso_639_2B_code="arn"
+		iso_639_2T_code="arn"
+		name="Mapudungun; Mapuche" />
+	<iso_639_entry
+		iso_639_2B_code="arp"
+		iso_639_2T_code="arp"
+		name="Arapaho" />
+	<iso_639_entry
+		iso_639_2B_code="art"
+		iso_639_2T_code="art"
+		name="Artificial languages" />
+	<iso_639_entry
+		iso_639_2B_code="arw"
+		iso_639_2T_code="arw"
+		name="Arawak" />
+	<iso_639_entry
+		iso_639_2B_code="asm"
+		iso_639_2T_code="asm"
+		iso_639_1_code="as"
+		name="Assamese" />
+	<iso_639_entry
+		iso_639_2B_code="ast"
+		iso_639_2T_code="ast"
+		name="Asturian; Bable; Leonese; Asturleonese" />
+	<iso_639_entry
+		iso_639_2B_code="ath"
+		iso_639_2T_code="ath"
+		name="Athapascan languages" />
+	<iso_639_entry
+		iso_639_2B_code="aus"
+		iso_639_2T_code="aus"
+		name="Australian languages" />
+	<iso_639_entry
+		iso_639_2B_code="ava"
+		iso_639_2T_code="ava"
+		iso_639_1_code="av"
+		name="Avaric" />
+	<iso_639_entry
+		iso_639_2B_code="ave"
+		iso_639_2T_code="ave"
+		iso_639_1_code="ae"
+		name="Avestan" />
+	<iso_639_entry
+		iso_639_2B_code="awa"
+		iso_639_2T_code="awa"
+		name="Awadhi" />
+	<iso_639_entry
+		iso_639_2B_code="aym"
+		iso_639_2T_code="aym"
+		iso_639_1_code="ay"
+		name="Aymara" />
+	<iso_639_entry
+		iso_639_2B_code="aze"
+		iso_639_2T_code="aze"
+		iso_639_1_code="az"
+		name="Azerbaijani" />
+	<iso_639_entry
+		iso_639_2B_code="bad"
+		iso_639_2T_code="bad"
+		name="Banda languages" />
+	<iso_639_entry
+		iso_639_2B_code="bai"
+		iso_639_2T_code="bai"
+		name="Bamileke languages" />
+	<iso_639_entry
+		iso_639_2B_code="bak"
+		iso_639_2T_code="bak"
+		iso_639_1_code="ba"
+		name="Bashkir" />
+	<iso_639_entry
+		iso_639_2B_code="bal"
+		iso_639_2T_code="bal"
+		name="Baluchi" />
+	<iso_639_entry
+		iso_639_2B_code="bam"
+		iso_639_2T_code="bam"
+		iso_639_1_code="bm"
+		name="Bambara" />
+	<iso_639_entry
+		iso_639_2B_code="ban"
+		iso_639_2T_code="ban"
+		name="Balinese" />
+	<iso_639_entry
+		iso_639_2B_code="baq"
+		iso_639_2T_code="eus"
+		iso_639_1_code="eu"
+		name="Basque" />
+	<iso_639_entry
+		iso_639_2B_code="bas"
+		iso_639_2T_code="bas"
+		name="Basa" />
+	<iso_639_entry
+		iso_639_2B_code="bat"
+		iso_639_2T_code="bat"
+		name="Baltic languages" />
+	<iso_639_entry
+		iso_639_2B_code="bej"
+		iso_639_2T_code="bej"
+		name="Beja; Bedawiyet" />
+	<iso_639_entry
+		iso_639_2B_code="bel"
+		iso_639_2T_code="bel"
+		iso_639_1_code="be"
+		name="Belarusian" />
+	<iso_639_entry
+		iso_639_2B_code="bem"
+		iso_639_2T_code="bem"
+		name="Bemba" />
+	<iso_639_entry
+		iso_639_2B_code="ben"
+		iso_639_2T_code="ben"
+		iso_639_1_code="bn"
+		name="Bengali" />
+	<iso_639_entry
+		iso_639_2B_code="ber"
+		iso_639_2T_code="ber"
+		name="Berber languages" />
+	<iso_639_entry
+		iso_639_2B_code="bho"
+		iso_639_2T_code="bho"
+		name="Bhojpuri" />
+	<iso_639_entry
+		iso_639_2B_code="bih"
+		iso_639_2T_code="bih"
+		iso_639_1_code="bh"
+		name="Bihari languages" />
+	<iso_639_entry
+		iso_639_2B_code="bik"
+		iso_639_2T_code="bik"
+		name="Bikol" />
+	<iso_639_entry
+		iso_639_2B_code="bin"
+		iso_639_2T_code="bin"
+		name="Bini; Edo" />
+	<iso_639_entry
+		iso_639_2B_code="bis"
+		iso_639_2T_code="bis"
+		iso_639_1_code="bi"
+		name="Bislama" />
+	<iso_639_entry
+		iso_639_2B_code="bla"
+		iso_639_2T_code="bla"
+		name="Siksika" />
+	<iso_639_entry
+		iso_639_2B_code="bnt"
+		iso_639_2T_code="bnt"
+		name="Bantu languages" />
+	<iso_639_entry
+		iso_639_2B_code="bos"
+		iso_639_2T_code="bos"
+		iso_639_1_code="bs"
+		name="Bosnian" />
+	<iso_639_entry
+		iso_639_2B_code="bra"
+		iso_639_2T_code="bra"
+		name="Braj" />
+	<iso_639_entry
+		iso_639_2B_code="bre"
+		iso_639_2T_code="bre"
+		iso_639_1_code="br"
+		name="Breton" />
+	<iso_639_entry
+		iso_639_2B_code="btk"
+		iso_639_2T_code="btk"
+		name="Batak languages" />
+	<iso_639_entry
+		iso_639_2B_code="bua"
+		iso_639_2T_code="bua"
+		name="Buriat" />
+	<iso_639_entry
+		iso_639_2B_code="bug"
+		iso_639_2T_code="bug"
+		name="Buginese" />
+	<iso_639_entry
+		iso_639_2B_code="bul"
+		iso_639_2T_code="bul"
+		iso_639_1_code="bg"
+		name="Bulgarian" />
+	<iso_639_entry
+		iso_639_2B_code="bur"
+		iso_639_2T_code="mya"
+		iso_639_1_code="my"
+		name="Burmese" />
+	<iso_639_entry
+		iso_639_2B_code="byn"
+		iso_639_2T_code="byn"
+		name="Blin; Bilin" />
+	<iso_639_entry
+		iso_639_2B_code="cad"
+		iso_639_2T_code="cad"
+		name="Caddo" />
+	<iso_639_entry
+		iso_639_2B_code="cai"
+		iso_639_2T_code="cai"
+		name="Central American Indian languages" />
+	<iso_639_entry
+		iso_639_2B_code="car"
+		iso_639_2T_code="car"
+		name="Galibi Carib" />
+	<iso_639_entry
+		iso_639_2B_code="cat"
+		iso_639_2T_code="cat"
+		iso_639_1_code="ca"
+		name="Catalan; Valencian" />
+	<iso_639_entry
+		iso_639_2B_code="cau"
+		iso_639_2T_code="cau"
+		name="Caucasian languages" />
+	<iso_639_entry
+		iso_639_2B_code="ceb"
+		iso_639_2T_code="ceb"
+		name="Cebuano" />
+	<iso_639_entry
+		iso_639_2B_code="cel"
+		iso_639_2T_code="cel"
+		name="Celtic languages" />
+	<iso_639_entry
+		iso_639_2B_code="cha"
+		iso_639_2T_code="cha"
+		iso_639_1_code="ch"
+		name="Chamorro" />
+	<iso_639_entry
+		iso_639_2B_code="chb"
+		iso_639_2T_code="chb"
+		name="Chibcha" />
+	<iso_639_entry
+		iso_639_2B_code="che"
+		iso_639_2T_code="che"
+		iso_639_1_code="ce"
+		name="Chechen" />
+	<iso_639_entry
+		iso_639_2B_code="chg"
+		iso_639_2T_code="chg"
+		name="Chagatai" />
+	<iso_639_entry
+		iso_639_2B_code="chi"
+		iso_639_2T_code="zho"
+		iso_639_1_code="zh"
+		name="Chinese" />
+	<iso_639_entry
+		iso_639_2B_code="chk"
+		iso_639_2T_code="chk"
+		name="Chuukese" />
+	<iso_639_entry
+		iso_639_2B_code="chm"
+		iso_639_2T_code="chm"
+		name="Mari" />
+	<iso_639_entry
+		iso_639_2B_code="chn"
+		iso_639_2T_code="chn"
+		name="Chinook jargon" />
+	<iso_639_entry
+		iso_639_2B_code="cho"
+		iso_639_2T_code="cho"
+		name="Choctaw" />
+	<iso_639_entry
+		iso_639_2B_code="chp"
+		iso_639_2T_code="chp"
+		name="Chipewyan; Dene Suline" />
+	<iso_639_entry
+		iso_639_2B_code="chr"
+		iso_639_2T_code="chr"
+		name="Cherokee" />
+	<iso_639_entry
+		iso_639_2B_code="chu"
+		iso_639_2T_code="chu"
+		iso_639_1_code="cu"
+		name="Church Slavic; Old Slavonic; Church Slavonic; Old Bulgarian; Old Church Slavonic" />
+	<iso_639_entry
+		iso_639_2B_code="chv"
+		iso_639_2T_code="chv"
+		iso_639_1_code="cv"
+		name="Chuvash" />
+	<iso_639_entry
+		iso_639_2B_code="chy"
+		iso_639_2T_code="chy"
+		name="Cheyenne" />
+	<iso_639_entry
+		iso_639_2B_code="cmc"
+		iso_639_2T_code="cmc"
+		name="Chamic languages" />
+	<iso_639_entry
+		iso_639_2B_code="cop"
+		iso_639_2T_code="cop"
+		name="Coptic" />
+	<iso_639_entry
+		iso_639_2B_code="cor"
+		iso_639_2T_code="cor"
+		iso_639_1_code="kw"
+		name="Cornish" />
+	<iso_639_entry
+		iso_639_2B_code="cos"
+		iso_639_2T_code="cos"
+		iso_639_1_code="co"
+		name="Corsican" />
+	<iso_639_entry
+		iso_639_2B_code="cpe"
+		iso_639_2T_code="cpe"
+		name="Creoles and pidgins, English based" />
+	<iso_639_entry
+		iso_639_2B_code="cpf"
+		iso_639_2T_code="cpf"
+		name="Creoles and pidgins, French-based" />
+	<iso_639_entry
+		iso_639_2B_code="cpp"
+		iso_639_2T_code="cpp"
+		name="Creoles and pidgins, Portuguese-based" />
+	<iso_639_entry
+		iso_639_2B_code="cre"
+		iso_639_2T_code="cre"
+		iso_639_1_code="cr"
+		name="Cree" />
+	<iso_639_entry
+		iso_639_2B_code="crh"
+		iso_639_2T_code="crh"
+		name="Crimean Tatar; Crimean Turkish" />
+	<iso_639_entry
+		iso_639_2B_code="crp"
+		iso_639_2T_code="crp"
+		name="Creoles and pidgins" />
+	<iso_639_entry
+		iso_639_2B_code="csb"
+		iso_639_2T_code="csb"
+		name="Kashubian" />
+	<iso_639_entry
+		iso_639_2B_code="cus"
+		iso_639_2T_code="cus"
+		name="Cushitic languages" />
+	<iso_639_entry
+		iso_639_2B_code="cze"
+		iso_639_2T_code="ces"
+		iso_639_1_code="cs"
+		name="Czech" />
+	<iso_639_entry
+		iso_639_2B_code="dak"
+		iso_639_2T_code="dak"
+		name="Dakota" />
+	<iso_639_entry
+		iso_639_2B_code="dan"
+		iso_639_2T_code="dan"
+		iso_639_1_code="da"
+		name="Danish" />
+	<iso_639_entry
+		iso_639_2B_code="dar"
+		iso_639_2T_code="dar"
+		name="Dargwa" />
+	<iso_639_entry
+		iso_639_2B_code="day"
+		iso_639_2T_code="day"
+		name="Land Dayak languages" />
+	<iso_639_entry
+		iso_639_2B_code="del"
+		iso_639_2T_code="del"
+		name="Delaware" />
+	<iso_639_entry
+		iso_639_2B_code="den"
+		iso_639_2T_code="den"
+		name="Slave (Athapascan)" />
+	<iso_639_entry
+		iso_639_2B_code="dgr"
+		iso_639_2T_code="dgr"
+		name="Dogrib" />
+	<iso_639_entry
+		iso_639_2B_code="din"
+		iso_639_2T_code="din"
+		name="Dinka" />
+	<iso_639_entry
+		iso_639_2B_code="div"
+		iso_639_2T_code="div"
+		iso_639_1_code="dv"
+		name="Divehi; Dhivehi; Maldivian" />
+	<iso_639_entry
+		iso_639_2B_code="doi"
+		iso_639_2T_code="doi"
+		name="Dogri" />
+	<iso_639_entry
+		iso_639_2B_code="dra"
+		iso_639_2T_code="dra"
+		name="Dravidian languages" />
+	<iso_639_entry
+		iso_639_2B_code="dsb"
+		iso_639_2T_code="dsb"
+		name="Lower Sorbian" />
+	<iso_639_entry
+		iso_639_2B_code="dua"
+		iso_639_2T_code="dua"
+		name="Duala" />
+	<iso_639_entry
+		iso_639_2B_code="dum"
+		iso_639_2T_code="dum"
+		name="Dutch, Middle (ca. 1050-1350)" />
+	<iso_639_entry
+		iso_639_2B_code="dut"
+		iso_639_2T_code="nld"
+		iso_639_1_code="nl"
+		name="Dutch; Flemish" />
+	<iso_639_entry
+		iso_639_2B_code="dyu"
+		iso_639_2T_code="dyu"
+		name="Dyula" />
+	<iso_639_entry
+		iso_639_2B_code="dzo"
+		iso_639_2T_code="dzo"
+		iso_639_1_code="dz"
+		name="Dzongkha" />
+	<iso_639_entry
+		iso_639_2B_code="efi"
+		iso_639_2T_code="efi"
+		name="Efik" />
+	<iso_639_entry
+		iso_639_2B_code="egy"
+		iso_639_2T_code="egy"
+		name="Egyptian (Ancient)" />
+	<iso_639_entry
+		iso_639_2B_code="eka"
+		iso_639_2T_code="eka"
+		name="Ekajuk" />
+	<iso_639_entry
+		iso_639_2B_code="elx"
+		iso_639_2T_code="elx"
+		name="Elamite" />
+	<iso_639_entry
+		iso_639_2B_code="eng"
+		iso_639_2T_code="eng"
+		iso_639_1_code="en"
+		name="English" />
+	<iso_639_entry
+		iso_639_2B_code="enm"
+		iso_639_2T_code="enm"
+		name="English, Middle (1100-1500)" />
+	<iso_639_entry
+		iso_639_2B_code="epo"
+		iso_639_2T_code="epo"
+		iso_639_1_code="eo"
+		name="Esperanto" />
+	<iso_639_entry
+		iso_639_2B_code="est"
+		iso_639_2T_code="est"
+		iso_639_1_code="et"
+		name="Estonian" />
+	<iso_639_entry
+		iso_639_2B_code="ewe"
+		iso_639_2T_code="ewe"
+		iso_639_1_code="ee"
+		name="Ewe" />
+	<iso_639_entry
+		iso_639_2B_code="ewo"
+		iso_639_2T_code="ewo"
+		name="Ewondo" />
+	<iso_639_entry
+		iso_639_2B_code="fan"
+		iso_639_2T_code="fan"
+		name="Fang" />
+	<iso_639_entry
+		iso_639_2B_code="fao"
+		iso_639_2T_code="fao"
+		iso_639_1_code="fo"
+		name="Faroese" />
+	<iso_639_entry
+		iso_639_2B_code="fat"
+		iso_639_2T_code="fat"
+		name="Fanti" />
+	<iso_639_entry
+		iso_639_2B_code="fij"
+		iso_639_2T_code="fij"
+		iso_639_1_code="fj"
+		name="Fijian" />
+	<iso_639_entry
+		iso_639_2B_code="fil"
+		iso_639_2T_code="fil"
+		name="Filipino; Pilipino" />
+	<iso_639_entry
+		iso_639_2B_code="fin"
+		iso_639_2T_code="fin"
+		iso_639_1_code="fi"
+		name="Finnish" />
+	<iso_639_entry
+		iso_639_2B_code="fiu"
+		iso_639_2T_code="fiu"
+		name="Finno-Ugrian languages" />
+	<iso_639_entry
+		iso_639_2B_code="fon"
+		iso_639_2T_code="fon"
+		name="Fon" />
+	<iso_639_entry
+		iso_639_2B_code="fre"
+		iso_639_2T_code="fra"
+		iso_639_1_code="fr"
+		name="French" />
+	<iso_639_entry
+		iso_639_2B_code="frm"
+		iso_639_2T_code="frm"
+		name="French, Middle (ca. 1400-1600)" />
+	<iso_639_entry
+		iso_639_2B_code="fro"
+		iso_639_2T_code="fro"
+		name="French, Old (842-ca. 1400)" />
+	<iso_639_entry
+		iso_639_2B_code="frr"
+		iso_639_2T_code="frr"
+		name="Northern Frisian" />
+	<iso_639_entry
+		iso_639_2B_code="frs"
+		iso_639_2T_code="frs"
+		name="Eastern Frisian" />
+	<iso_639_entry
+		iso_639_2B_code="fry"
+		iso_639_2T_code="fry"
+		iso_639_1_code="fy"
+		name="Western Frisian" />
+	<iso_639_entry
+		iso_639_2B_code="ful"
+		iso_639_2T_code="ful"
+		iso_639_1_code="ff"
+		name="Fulah" />
+	<iso_639_entry
+		iso_639_2B_code="fur"
+		iso_639_2T_code="fur"
+		name="Friulian" />
+	<iso_639_entry
+		iso_639_2B_code="gaa"
+		iso_639_2T_code="gaa"
+		name="Ga" />
+	<iso_639_entry
+		iso_639_2B_code="gay"
+		iso_639_2T_code="gay"
+		name="Gayo" />
+	<iso_639_entry
+		iso_639_2B_code="gba"
+		iso_639_2T_code="gba"
+		name="Gbaya" />
+	<iso_639_entry
+		iso_639_2B_code="gem"
+		iso_639_2T_code="gem"
+		name="Germanic languages" />
+	<iso_639_entry
+		iso_639_2B_code="geo"
+		iso_639_2T_code="kat"
+		iso_639_1_code="ka"
+		name="Georgian" />
+	<iso_639_entry
+		iso_639_2B_code="ger"
+		iso_639_2T_code="deu"
+		iso_639_1_code="de"
+		name="German" />
+	<iso_639_entry
+		iso_639_2B_code="gez"
+		iso_639_2T_code="gez"
+		name="Geez" />
+	<iso_639_entry
+		iso_639_2B_code="gil"
+		iso_639_2T_code="gil"
+		name="Gilbertese" />
+	<iso_639_entry
+		iso_639_2B_code="gla"
+		iso_639_2T_code="gla"
+		iso_639_1_code="gd"
+		name="Gaelic; Scottish Gaelic" />
+	<iso_639_entry
+		iso_639_2B_code="gle"
+		iso_639_2T_code="gle"
+		iso_639_1_code="ga"
+		name="Irish" />
+	<iso_639_entry
+		iso_639_2B_code="glg"
+		iso_639_2T_code="glg"
+		iso_639_1_code="gl"
+		name="Galician" />
+	<iso_639_entry
+		iso_639_2B_code="glv"
+		iso_639_2T_code="glv"
+		iso_639_1_code="gv"
+		name="Manx" />
+	<iso_639_entry
+		iso_639_2B_code="gmh"
+		iso_639_2T_code="gmh"
+		name="German, Middle High (ca. 1050-1500)" />
+	<iso_639_entry
+		iso_639_2B_code="goh"
+		iso_639_2T_code="goh"
+		name="German, Old High (ca. 750-1050)" />
+	<iso_639_entry
+		iso_639_2B_code="gon"
+		iso_639_2T_code="gon"
+		name="Gondi" />
+	<iso_639_entry
+		iso_639_2B_code="gor"
+		iso_639_2T_code="gor"
+		name="Gorontalo" />
+	<iso_639_entry
+		iso_639_2B_code="got"
+		iso_639_2T_code="got"
+		name="Gothic" />
+	<iso_639_entry
+		iso_639_2B_code="grb"
+		iso_639_2T_code="grb"
+		name="Grebo" />
+	<iso_639_entry
+		iso_639_2B_code="grc"
+		iso_639_2T_code="grc"
+		name="Greek, Ancient (to 1453)" />
+	<iso_639_entry
+		iso_639_2B_code="gre"
+		iso_639_2T_code="ell"
+		iso_639_1_code="el"
+		name="Greek, Modern (1453-)" />
+	<iso_639_entry
+		iso_639_2B_code="grn"
+		iso_639_2T_code="grn"
+		iso_639_1_code="gn"
+		name="Guarani" />
+	<iso_639_entry
+		iso_639_2B_code="gsw"
+		iso_639_2T_code="gsw"
+		name="Swiss German; Alemannic; Alsatian" />
+	<iso_639_entry
+		iso_639_2B_code="guj"
+		iso_639_2T_code="guj"
+		iso_639_1_code="gu"
+		name="Gujarati" />
+	<iso_639_entry
+		iso_639_2B_code="gwi"
+		iso_639_2T_code="gwi"
+		name="Gwich'in" />
+	<iso_639_entry
+		iso_639_2B_code="hai"
+		iso_639_2T_code="hai"
+		name="Haida" />
+	<iso_639_entry
+		iso_639_2B_code="hat"
+		iso_639_2T_code="hat"
+		iso_639_1_code="ht"
+		name="Haitian; Haitian Creole" />
+	<iso_639_entry
+		iso_639_2B_code="hau"
+		iso_639_2T_code="hau"
+		iso_639_1_code="ha"
+		name="Hausa" />
+	<iso_639_entry
+		iso_639_2B_code="haw"
+		iso_639_2T_code="haw"
+		name="Hawaiian" />
+	<iso_639_entry
+		iso_639_2B_code="heb"
+		iso_639_2T_code="heb"
+		iso_639_1_code="he"
+		name="Hebrew" />
+	<iso_639_entry
+		iso_639_2B_code="her"
+		iso_639_2T_code="her"
+		iso_639_1_code="hz"
+		name="Herero" />
+	<iso_639_entry
+		iso_639_2B_code="hil"
+		iso_639_2T_code="hil"
+		name="Hiligaynon" />
+	<iso_639_entry
+		iso_639_2B_code="him"
+		iso_639_2T_code="him"
+		name="Himachali languages; Western Pahari languages" />
+	<iso_639_entry
+		iso_639_2B_code="hin"
+		iso_639_2T_code="hin"
+		iso_639_1_code="hi"
+		name="Hindi" />
+	<iso_639_entry
+		iso_639_2B_code="hit"
+		iso_639_2T_code="hit"
+		name="Hittite" />
+	<iso_639_entry
+		iso_639_2B_code="hmn"
+		iso_639_2T_code="hmn"
+		name="Hmong; Mong" />
+	<iso_639_entry
+		iso_639_2B_code="hmo"
+		iso_639_2T_code="hmo"
+		iso_639_1_code="ho"
+		name="Hiri Motu" />
+	<iso_639_entry
+		iso_639_2B_code="hrv"
+		iso_639_2T_code="hrv"
+		iso_639_1_code="hr"
+		name="Croatian" />
+	<iso_639_entry
+		iso_639_2B_code="hsb"
+		iso_639_2T_code="hsb"
+		name="Upper Sorbian" />
+	<iso_639_entry
+		iso_639_2B_code="hun"
+		iso_639_2T_code="hun"
+		iso_639_1_code="hu"
+		name="Hungarian" />
+	<iso_639_entry
+		iso_639_2B_code="hup"
+		iso_639_2T_code="hup"
+		name="Hupa" />
+	<iso_639_entry
+		iso_639_2B_code="iba"
+		iso_639_2T_code="iba"
+		name="Iban" />
+	<iso_639_entry
+		iso_639_2B_code="ibo"
+		iso_639_2T_code="ibo"
+		iso_639_1_code="ig"
+		name="Igbo" />
+	<iso_639_entry
+		iso_639_2B_code="ice"
+		iso_639_2T_code="isl"
+		iso_639_1_code="is"
+		name="Icelandic" />
+	<iso_639_entry
+		iso_639_2B_code="ido"
+		iso_639_2T_code="ido"
+		iso_639_1_code="io"
+		name="Ido" />
+	<iso_639_entry
+		iso_639_2B_code="iii"
+		iso_639_2T_code="iii"
+		iso_639_1_code="ii"
+		name="Sichuan Yi; Nuosu" />
+	<iso_639_entry
+		iso_639_2B_code="ijo"
+		iso_639_2T_code="ijo"
+		name="Ijo languages" />
+	<iso_639_entry
+		iso_639_2B_code="iku"
+		iso_639_2T_code="iku"
+		iso_639_1_code="iu"
+		name="Inuktitut" />
+	<iso_639_entry
+		iso_639_2B_code="ile"
+		iso_639_2T_code="ile"
+		iso_639_1_code="ie"
+		name="Interlingue; Occidental" />
+	<iso_639_entry
+		iso_639_2B_code="ilo"
+		iso_639_2T_code="ilo"
+		name="Iloko" />
+	<iso_639_entry
+		iso_639_2B_code="ina"
+		iso_639_2T_code="ina"
+		iso_639_1_code="ia"
+		name="Interlingua (International Auxiliary Language Association)" />
+	<iso_639_entry
+		iso_639_2B_code="inc"
+		iso_639_2T_code="inc"
+		name="Indic languages" />
+	<iso_639_entry
+		iso_639_2B_code="ind"
+		iso_639_2T_code="ind"
+		iso_639_1_code="id"
+		name="Indonesian" />
+	<iso_639_entry
+		iso_639_2B_code="ine"
+		iso_639_2T_code="ine"
+		name="Indo-European languages" />
+	<iso_639_entry
+		iso_639_2B_code="inh"
+		iso_639_2T_code="inh"
+		name="Ingush" />
+	<iso_639_entry
+		iso_639_2B_code="ipk"
+		iso_639_2T_code="ipk"
+		iso_639_1_code="ik"
+		name="Inupiaq" />
+	<iso_639_entry
+		iso_639_2B_code="ira"
+		iso_639_2T_code="ira"
+		name="Iranian languages" />
+	<iso_639_entry
+		iso_639_2B_code="iro"
+		iso_639_2T_code="iro"
+		name="Iroquoian languages" />
+	<iso_639_entry
+		iso_639_2B_code="ita"
+		iso_639_2T_code="ita"
+		iso_639_1_code="it"
+		name="Italian" />
+	<iso_639_entry
+		iso_639_2B_code="jav"
+		iso_639_2T_code="jav"
+		iso_639_1_code="jv"
+		name="Javanese" />
+	<iso_639_entry
+		iso_639_2B_code="jbo"
+		iso_639_2T_code="jbo"
+		name="Lojban" />
+	<iso_639_entry
+		iso_639_2B_code="jpn"
+		iso_639_2T_code="jpn"
+		iso_639_1_code="ja"
+		name="Japanese" />
+	<iso_639_entry
+		iso_639_2B_code="jpr"
+		iso_639_2T_code="jpr"
+		name="Judeo-Persian" />
+	<iso_639_entry
+		iso_639_2B_code="jrb"
+		iso_639_2T_code="jrb"
+		name="Judeo-Arabic" />
+	<iso_639_entry
+		iso_639_2B_code="kaa"
+		iso_639_2T_code="kaa"
+		name="Kara-Kalpak" />
+	<iso_639_entry
+		iso_639_2B_code="kab"
+		iso_639_2T_code="kab"
+		name="Kabyle" />
+	<iso_639_entry
+		iso_639_2B_code="kac"
+		iso_639_2T_code="kac"
+		name="Kachin; Jingpho" />
+	<iso_639_entry
+		iso_639_2B_code="kal"
+		iso_639_2T_code="kal"
+		iso_639_1_code="kl"
+		name="Kalaallisut; Greenlandic" />
+	<iso_639_entry
+		iso_639_2B_code="kam"
+		iso_639_2T_code="kam"
+		name="Kamba" />
+	<iso_639_entry
+		iso_639_2B_code="kan"
+		iso_639_2T_code="kan"
+		iso_639_1_code="kn"
+		name="Kannada" />
+	<iso_639_entry
+		iso_639_2B_code="kar"
+		iso_639_2T_code="kar"
+		name="Karen languages" />
+	<iso_639_entry
+		iso_639_2B_code="kas"
+		iso_639_2T_code="kas"
+		iso_639_1_code="ks"
+		name="Kashmiri" />
+	<iso_639_entry
+		iso_639_2B_code="kau"
+		iso_639_2T_code="kau"
+		iso_639_1_code="kr"
+		name="Kanuri" />
+	<iso_639_entry
+		iso_639_2B_code="kaw"
+		iso_639_2T_code="kaw"
+		name="Kawi" />
+	<iso_639_entry
+		iso_639_2B_code="kaz"
+		iso_639_2T_code="kaz"
+		iso_639_1_code="kk"
+		name="Kazakh" />
+	<iso_639_entry
+		iso_639_2B_code="kbd"
+		iso_639_2T_code="kbd"
+		name="Kabardian" />
+	<iso_639_entry
+		iso_639_2B_code="kha"
+		iso_639_2T_code="kha"
+		name="Khasi" />
+	<iso_639_entry
+		iso_639_2B_code="khi"
+		iso_639_2T_code="khi"
+		name="Khoisan languages" />
+	<iso_639_entry
+		iso_639_2B_code="khm"
+		iso_639_2T_code="khm"
+		iso_639_1_code="km"
+		name="Central Khmer" />
+	<iso_639_entry
+		iso_639_2B_code="kho"
+		iso_639_2T_code="kho"
+		name="Khotanese;Sakan" />
+	<iso_639_entry
+		iso_639_2B_code="kik"
+		iso_639_2T_code="kik"
+		iso_639_1_code="ki"
+		name="Kikuyu; Gikuyu" />
+	<iso_639_entry
+		iso_639_2B_code="kin"
+		iso_639_2T_code="kin"
+		iso_639_1_code="rw"
+		name="Kinyarwanda" />
+	<iso_639_entry
+		iso_639_2B_code="kir"
+		iso_639_2T_code="kir"
+		iso_639_1_code="ky"
+		name="Kirghiz; Kyrgyz" />
+	<iso_639_entry
+		iso_639_2B_code="kmb"
+		iso_639_2T_code="kmb"
+		name="Kimbundu" />
+	<iso_639_entry
+		iso_639_2B_code="kok"
+		iso_639_2T_code="kok"
+		name="Konkani" />
+	<iso_639_entry
+		iso_639_2B_code="kom"
+		iso_639_2T_code="kom"
+		iso_639_1_code="kv"
+		name="Komi" />
+	<iso_639_entry
+		iso_639_2B_code="kon"
+		iso_639_2T_code="kon"
+		iso_639_1_code="kg"
+		name="Kongo" />
+	<iso_639_entry
+		iso_639_2B_code="kor"
+		iso_639_2T_code="kor"
+		iso_639_1_code="ko"
+		name="Korean" />
+	<iso_639_entry
+		iso_639_2B_code="kos"
+		iso_639_2T_code="kos"
+		name="Kosraean" />
+	<iso_639_entry
+		iso_639_2B_code="kpe"
+		iso_639_2T_code="kpe"
+		name="Kpelle" />
+	<iso_639_entry
+		iso_639_2B_code="krc"
+		iso_639_2T_code="krc"
+		name="Karachay-Balkar" />
+	<iso_639_entry
+		iso_639_2B_code="krl"
+		iso_639_2T_code="krl"
+		name="Karelian" />
+	<iso_639_entry
+		iso_639_2B_code="kro"
+		iso_639_2T_code="kro"
+		name="Kru languages" />
+	<iso_639_entry
+		iso_639_2B_code="kru"
+		iso_639_2T_code="kru"
+		name="Kurukh" />
+	<iso_639_entry
+		iso_639_2B_code="kua"
+		iso_639_2T_code="kua"
+		iso_639_1_code="kj"
+		name="Kuanyama; Kwanyama" />
+	<iso_639_entry
+		iso_639_2B_code="kum"
+		iso_639_2T_code="kum"
+		name="Kumyk" />
+	<iso_639_entry
+		iso_639_2B_code="kur"
+		iso_639_2T_code="kur"
+		iso_639_1_code="ku"
+		name="Kurdish" />
+	<iso_639_entry
+		iso_639_2B_code="kut"
+		iso_639_2T_code="kut"
+		name="Kutenai" />
+	<iso_639_entry
+		iso_639_2B_code="lad"
+		iso_639_2T_code="lad"
+		name="Ladino" />
+	<iso_639_entry
+		iso_639_2B_code="lah"
+		iso_639_2T_code="lah"
+		name="Lahnda" />
+	<iso_639_entry
+		iso_639_2B_code="lam"
+		iso_639_2T_code="lam"
+		name="Lamba" />
+	<iso_639_entry
+		iso_639_2B_code="lao"
+		iso_639_2T_code="lao"
+		iso_639_1_code="lo"
+		name="Lao" />
+	<iso_639_entry
+		iso_639_2B_code="lat"
+		iso_639_2T_code="lat"
+		iso_639_1_code="la"
+		name="Latin" />
+	<iso_639_entry
+		iso_639_2B_code="lav"
+		iso_639_2T_code="lav"
+		iso_639_1_code="lv"
+		name="Latvian" />
+	<iso_639_entry
+		iso_639_2B_code="lez"
+		iso_639_2T_code="lez"
+		name="Lezghian" />
+	<iso_639_entry
+		iso_639_2B_code="lim"
+		iso_639_2T_code="lim"
+		iso_639_1_code="li"
+		name="Limburgan; Limburger; Limburgish" />
+	<iso_639_entry
+		iso_639_2B_code="lin"
+		iso_639_2T_code="lin"
+		iso_639_1_code="ln"
+		name="Lingala" />
+	<iso_639_entry
+		iso_639_2B_code="lit"
+		iso_639_2T_code="lit"
+		iso_639_1_code="lt"
+		name="Lithuanian" />
+	<iso_639_entry
+		iso_639_2B_code="lol"
+		iso_639_2T_code="lol"
+		name="Mongo" />
+	<iso_639_entry
+		iso_639_2B_code="loz"
+		iso_639_2T_code="loz"
+		name="Lozi" />
+	<iso_639_entry
+		iso_639_2B_code="ltz"
+		iso_639_2T_code="ltz"
+		iso_639_1_code="lb"
+		name="Luxembourgish; Letzeburgesch" />
+	<iso_639_entry
+		iso_639_2B_code="lua"
+		iso_639_2T_code="lua"
+		name="Luba-Lulua" />
+	<iso_639_entry
+		iso_639_2B_code="lub"
+		iso_639_2T_code="lub"
+		iso_639_1_code="lu"
+		name="Luba-Katanga" />
+	<iso_639_entry
+		iso_639_2B_code="lug"
+		iso_639_2T_code="lug"
+		iso_639_1_code="lg"
+		name="Ganda" />
+	<iso_639_entry
+		iso_639_2B_code="lui"
+		iso_639_2T_code="lui"
+		name="Luiseno" />
+	<iso_639_entry
+		iso_639_2B_code="lun"
+		iso_639_2T_code="lun"
+		name="Lunda" />
+	<iso_639_entry
+		iso_639_2B_code="luo"
+		iso_639_2T_code="luo"
+		name="Luo (Kenya and Tanzania)" />
+	<iso_639_entry
+		iso_639_2B_code="lus"
+		iso_639_2T_code="lus"
+		name="Lushai" />
+	<iso_639_entry
+		iso_639_2B_code="mac"
+		iso_639_2T_code="mkd"
+		iso_639_1_code="mk"
+		name="Macedonian" />
+	<iso_639_entry
+		iso_639_2B_code="mad"
+		iso_639_2T_code="mad"
+		name="Madurese" />
+	<iso_639_entry
+		iso_639_2B_code="mag"
+		iso_639_2T_code="mag"
+		name="Magahi" />
+	<iso_639_entry
+		iso_639_2B_code="mah"
+		iso_639_2T_code="mah"
+		iso_639_1_code="mh"
+		name="Marshallese" />
+	<iso_639_entry
+		iso_639_2B_code="mai"
+		iso_639_2T_code="mai"
+		name="Maithili" />
+	<iso_639_entry
+		iso_639_2B_code="mak"
+		iso_639_2T_code="mak"
+		name="Makasar" />
+	<iso_639_entry
+		iso_639_2B_code="mal"
+		iso_639_2T_code="mal"
+		iso_639_1_code="ml"
+		name="Malayalam" />
+	<iso_639_entry
+		iso_639_2B_code="man"
+		iso_639_2T_code="man"
+		name="Mandingo" />
+	<iso_639_entry
+		iso_639_2B_code="mao"
+		iso_639_2T_code="mri"
+		iso_639_1_code="mi"
+		name="Maori" />
+	<iso_639_entry
+		iso_639_2B_code="map"
+		iso_639_2T_code="map"
+		name="Austronesian languages" />
+	<iso_639_entry
+		iso_639_2B_code="mar"
+		iso_639_2T_code="mar"
+		iso_639_1_code="mr"
+		name="Marathi" />
+	<iso_639_entry
+		iso_639_2B_code="mas"
+		iso_639_2T_code="mas"
+		name="Masai" />
+	<iso_639_entry
+		iso_639_2B_code="may"
+		iso_639_2T_code="msa"
+		iso_639_1_code="ms"
+		name="Malay" />
+	<iso_639_entry
+		iso_639_2B_code="mdf"
+		iso_639_2T_code="mdf"
+		name="Moksha" />
+	<iso_639_entry
+		iso_639_2B_code="mdr"
+		iso_639_2T_code="mdr"
+		name="Mandar" />
+	<iso_639_entry
+		iso_639_2B_code="men"
+		iso_639_2T_code="men"
+		name="Mende" />
+	<iso_639_entry
+		iso_639_2B_code="mga"
+		iso_639_2T_code="mga"
+		name="Irish, Middle (900-1200)" />
+	<iso_639_entry
+		iso_639_2B_code="mic"
+		iso_639_2T_code="mic"
+		name="Mi'kmaq; Micmac" />
+	<iso_639_entry
+		iso_639_2B_code="min"
+		iso_639_2T_code="min"
+		name="Minangkabau" />
+	<iso_639_entry
+		iso_639_2B_code="mis"
+		iso_639_2T_code="mis"
+		name="Uncoded languages" />
+	<iso_639_entry
+		iso_639_2B_code="mkh"
+		iso_639_2T_code="mkh"
+		name="Mon-Khmer languages" />
+	<iso_639_entry
+		iso_639_2B_code="mlg"
+		iso_639_2T_code="mlg"
+		iso_639_1_code="mg"
+		name="Malagasy" />
+	<iso_639_entry
+		iso_639_2B_code="mlt"
+		iso_639_2T_code="mlt"
+		iso_639_1_code="mt"
+		name="Maltese" />
+	<iso_639_entry
+		iso_639_2B_code="mnc"
+		iso_639_2T_code="mnc"
+		name="Manchu" />
+	<iso_639_entry
+		iso_639_2B_code="mni"
+		iso_639_2T_code="mni"
+		name="Manipuri" />
+	<iso_639_entry
+		iso_639_2B_code="mno"
+		iso_639_2T_code="mno"
+		name="Manobo languages" />
+	<iso_639_entry
+		iso_639_2B_code="moh"
+		iso_639_2T_code="moh"
+		name="Mohawk" />
+	<iso_639_entry
+		iso_639_2B_code="mol"
+		iso_639_2T_code="mol"
+		iso_639_1_code="mo"
+		name="Moldavian; Moldovan" />
+	<iso_639_entry
+		iso_639_2B_code="mon"
+		iso_639_2T_code="mon"
+		iso_639_1_code="mn"
+		name="Mongolian" />
+	<iso_639_entry
+		iso_639_2B_code="mos"
+		iso_639_2T_code="mos"
+		name="Mossi" />
+	<iso_639_entry
+		iso_639_2B_code="mul"
+		iso_639_2T_code="mul"
+		name="Multiple languages" />
+	<iso_639_entry
+		iso_639_2B_code="mun"
+		iso_639_2T_code="mun"
+		name="Munda languages" />
+	<iso_639_entry
+		iso_639_2B_code="mus"
+		iso_639_2T_code="mus"
+		name="Creek" />
+	<iso_639_entry
+		iso_639_2B_code="mwl"
+		iso_639_2T_code="mwl"
+		name="Mirandese" />
+	<iso_639_entry
+		iso_639_2B_code="mwr"
+		iso_639_2T_code="mwr"
+		name="Marwari" />
+	<iso_639_entry
+		iso_639_2B_code="myn"
+		iso_639_2T_code="myn"
+		name="Mayan languages" />
+	<iso_639_entry
+		iso_639_2B_code="myv"
+		iso_639_2T_code="myv"
+		name="Erzya" />
+	<iso_639_entry
+		iso_639_2B_code="nah"
+		iso_639_2T_code="nah"
+		name="Nahuatl languages" />
+	<iso_639_entry
+		iso_639_2B_code="nai"
+		iso_639_2T_code="nai"
+		name="North American Indian languages" />
+	<iso_639_entry
+		iso_639_2B_code="nap"
+		iso_639_2T_code="nap"
+		name="Neapolitan" />
+	<iso_639_entry
+		iso_639_2B_code="nau"
+		iso_639_2T_code="nau"
+		iso_639_1_code="na"
+		name="Nauru" />
+	<iso_639_entry
+		iso_639_2B_code="nav"
+		iso_639_2T_code="nav"
+		iso_639_1_code="nv"
+		name="Navajo; Navaho" />
+	<iso_639_entry
+		iso_639_2B_code="nbl"
+		iso_639_2T_code="nbl"
+		iso_639_1_code="nr"
+		name="Ndebele, South; South Ndebele" />
+	<iso_639_entry
+		iso_639_2B_code="nde"
+		iso_639_2T_code="nde"
+		iso_639_1_code="nd"
+		name="Ndebele, North; North Ndebele" />
+	<iso_639_entry
+		iso_639_2B_code="ndo"
+		iso_639_2T_code="ndo"
+		iso_639_1_code="ng"
+		name="Ndonga" />
+	<iso_639_entry
+		iso_639_2B_code="nds"
+		iso_639_2T_code="nds"
+		name="Low German; Low Saxon; German, Low; Saxon, Low" />
+	<iso_639_entry
+		iso_639_2B_code="nep"
+		iso_639_2T_code="nep"
+		iso_639_1_code="ne"
+		name="Nepali" />
+	<iso_639_entry
+		iso_639_2B_code="new"
+		iso_639_2T_code="new"
+		name="Nepal Bhasa; Newari" />
+	<iso_639_entry
+		iso_639_2B_code="nia"
+		iso_639_2T_code="nia"
+		name="Nias" />
+	<iso_639_entry
+		iso_639_2B_code="nic"
+		iso_639_2T_code="nic"
+		name="Niger-Kordofanian languages" />
+	<iso_639_entry
+		iso_639_2B_code="niu"
+		iso_639_2T_code="niu"
+		name="Niuean" />
+	<iso_639_entry
+		iso_639_2B_code="nno"
+		iso_639_2T_code="nno"
+		iso_639_1_code="nn"
+		name="Norwegian Nynorsk; Nynorsk, Norwegian" />
+	<iso_639_entry
+		iso_639_2B_code="nob"
+		iso_639_2T_code="nob"
+		iso_639_1_code="nb"
+		name="Bokmål, Norwegian; Norwegian Bokmål" />
+	<iso_639_entry
+		iso_639_2B_code="nog"
+		iso_639_2T_code="nog"
+		name="Nogai" />
+	<iso_639_entry
+		iso_639_2B_code="non"
+		iso_639_2T_code="non"
+		name="Norse, Old" />
+	<iso_639_entry
+		iso_639_2B_code="nor"
+		iso_639_2T_code="nor"
+		iso_639_1_code="no"
+		name="Norwegian" />
+	<iso_639_entry
+		iso_639_2B_code="nqo"
+		iso_639_2T_code="nqo"
+		name="N'Ko" />
+	<iso_639_entry
+		iso_639_2B_code="nso"
+		iso_639_2T_code="nso"
+		name="Pedi; Sepedi; Northern Sotho" />
+	<iso_639_entry
+		iso_639_2B_code="nub"
+		iso_639_2T_code="nub"
+		name="Nubian languages" />
+	<iso_639_entry
+		iso_639_2B_code="nwc"
+		iso_639_2T_code="nwc"
+		name="Classical Newari; Old Newari; Classical Nepal Bhasa" />
+	<iso_639_entry
+		iso_639_2B_code="nya"
+		iso_639_2T_code="nya"
+		iso_639_1_code="ny"
+		name="Chichewa; Chewa; Nyanja" />
+	<iso_639_entry
+		iso_639_2B_code="nym"
+		iso_639_2T_code="nym"
+		name="Nyamwezi" />
+	<iso_639_entry
+		iso_639_2B_code="nyn"
+		iso_639_2T_code="nyn"
+		name="Nyankole" />
+	<iso_639_entry
+		iso_639_2B_code="nyo"
+		iso_639_2T_code="nyo"
+		name="Nyoro" />
+	<iso_639_entry
+		iso_639_2B_code="nzi"
+		iso_639_2T_code="nzi"
+		name="Nzima" />
+	<iso_639_entry
+		iso_639_2B_code="oci"
+		iso_639_2T_code="oci"
+		iso_639_1_code="oc"
+		name="Occitan (post 1500)" />
+	<iso_639_entry
+		iso_639_2B_code="oji"
+		iso_639_2T_code="oji"
+		iso_639_1_code="oj"
+		name="Ojibwa" />
+	<iso_639_entry
+		iso_639_2B_code="ori"
+		iso_639_2T_code="ori"
+		iso_639_1_code="or"
+		name="Oriya" />
+	<iso_639_entry
+		iso_639_2B_code="orm"
+		iso_639_2T_code="orm"
+		iso_639_1_code="om"
+		name="Oromo" />
+	<iso_639_entry
+		iso_639_2B_code="osa"
+		iso_639_2T_code="osa"
+		name="Osage" />
+	<iso_639_entry
+		iso_639_2B_code="oss"
+		iso_639_2T_code="oss"
+		iso_639_1_code="os"
+		name="Ossetian; Ossetic" />
+	<iso_639_entry
+		iso_639_2B_code="ota"
+		iso_639_2T_code="ota"
+		name="Turkish, Ottoman (1500-1928)" />
+	<iso_639_entry
+		iso_639_2B_code="oto"
+		iso_639_2T_code="oto"
+		name="Otomian languages" />
+	<iso_639_entry
+		iso_639_2B_code="paa"
+		iso_639_2T_code="paa"
+		name="Papuan languages" />
+	<iso_639_entry
+		iso_639_2B_code="pag"
+		iso_639_2T_code="pag"
+		name="Pangasinan" />
+	<iso_639_entry
+		iso_639_2B_code="pal"
+		iso_639_2T_code="pal"
+		name="Pahlavi" />
+	<iso_639_entry
+		iso_639_2B_code="pam"
+		iso_639_2T_code="pam"
+		name="Pampanga; Kapampangan" />
+	<iso_639_entry
+		iso_639_2B_code="pan"
+		iso_639_2T_code="pan"
+		iso_639_1_code="pa"
+		name="Panjabi; Punjabi" />
+	<iso_639_entry
+		iso_639_2B_code="pap"
+		iso_639_2T_code="pap"
+		name="Papiamento" />
+	<iso_639_entry
+		iso_639_2B_code="pau"
+		iso_639_2T_code="pau"
+		name="Palauan" />
+	<iso_639_entry
+		iso_639_2B_code="peo"
+		iso_639_2T_code="peo"
+		name="Persian, Old (ca. 600-400 B.C.)" />
+	<iso_639_entry
+		iso_639_2B_code="per"
+		iso_639_2T_code="fas"
+		iso_639_1_code="fa"
+		name="Persian" />
+	<iso_639_entry
+		iso_639_2B_code="phi"
+		iso_639_2T_code="phi"
+		name="Philippine languages" />
+	<iso_639_entry
+		iso_639_2B_code="phn"
+		iso_639_2T_code="phn"
+		name="Phoenician" />
+	<iso_639_entry
+		iso_639_2B_code="pli"
+		iso_639_2T_code="pli"
+		iso_639_1_code="pi"
+		name="Pali" />
+	<iso_639_entry
+		iso_639_2B_code="pol"
+		iso_639_2T_code="pol"
+		iso_639_1_code="pl"
+		name="Polish" />
+	<iso_639_entry
+		iso_639_2B_code="pon"
+		iso_639_2T_code="pon"
+		name="Pohnpeian" />
+	<iso_639_entry
+		iso_639_2B_code="por"
+		iso_639_2T_code="por"
+		iso_639_1_code="pt"
+		name="Portuguese" />
+	<iso_639_entry
+		iso_639_2B_code="pra"
+		iso_639_2T_code="pra"
+		name="Prakrit languages" />
+	<iso_639_entry
+		iso_639_2B_code="pro"
+		iso_639_2T_code="pro"
+		name="Provençal, Old (to 1500); Occitan, Old (to 1500)" />
+	<iso_639_entry
+		iso_639_2B_code="pus"
+		iso_639_2T_code="pus"
+		iso_639_1_code="ps"
+		name="Pushto; Pashto" />
+	<iso_639_entry
+		iso_639_2B_code="qaa-qtz"
+		iso_639_2T_code="qaa-qtz"
+		name="Reserved for local use" />
+	<iso_639_entry
+		iso_639_2B_code="que"
+		iso_639_2T_code="que"
+		iso_639_1_code="qu"
+		name="Quechua" />
+	<iso_639_entry
+		iso_639_2B_code="raj"
+		iso_639_2T_code="raj"
+		name="Rajasthani" />
+	<iso_639_entry
+		iso_639_2B_code="rap"
+		iso_639_2T_code="rap"
+		name="Rapanui" />
+	<iso_639_entry
+		iso_639_2B_code="rar"
+		iso_639_2T_code="rar"
+		name="Rarotongan; Cook Islands Maori" />
+	<iso_639_entry
+		iso_639_2B_code="roa"
+		iso_639_2T_code="roa"
+		name="Romance languages" />
+	<iso_639_entry
+		iso_639_2B_code="roh"
+		iso_639_2T_code="roh"
+		iso_639_1_code="rm"
+		name="Romansh" />
+	<iso_639_entry
+		iso_639_2B_code="rom"
+		iso_639_2T_code="rom"
+		name="Romany" />
+	<iso_639_entry
+		iso_639_2B_code="rum"
+		iso_639_2T_code="ron"
+		iso_639_1_code="ro"
+		name="Romanian" />
+	<iso_639_entry
+		iso_639_2B_code="run"
+		iso_639_2T_code="run"
+		iso_639_1_code="rn"
+		name="Rundi" />
+	<iso_639_entry
+		iso_639_2B_code="rup"
+		iso_639_2T_code="rup"
+		name="Aromanian; Arumanian; Macedo-Romanian" />
+	<iso_639_entry
+		iso_639_2B_code="rus"
+		iso_639_2T_code="rus"
+		iso_639_1_code="ru"
+		name="Russian" />
+	<iso_639_entry
+		iso_639_2B_code="sad"
+		iso_639_2T_code="sad"
+		name="Sandawe" />
+	<iso_639_entry
+		iso_639_2B_code="sag"
+		iso_639_2T_code="sag"
+		iso_639_1_code="sg"
+		name="Sango" />
+	<iso_639_entry
+		iso_639_2B_code="sah"
+		iso_639_2T_code="sah"
+		name="Yakut" />
+	<iso_639_entry
+		iso_639_2B_code="sai"
+		iso_639_2T_code="sai"
+		name="South American Indian languages" />
+	<iso_639_entry
+		iso_639_2B_code="sal"
+		iso_639_2T_code="sal"
+		name="Salishan languages" />
+	<iso_639_entry
+		iso_639_2B_code="sam"
+		iso_639_2T_code="sam"
+		name="Samaritan Aramaic" />
+	<iso_639_entry
+		iso_639_2B_code="san"
+		iso_639_2T_code="san"
+		iso_639_1_code="sa"
+		name="Sanskrit" />
+	<iso_639_entry
+		iso_639_2B_code="sas"
+		iso_639_2T_code="sas"
+		name="Sasak" />
+	<iso_639_entry
+		iso_639_2B_code="sat"
+		iso_639_2T_code="sat"
+		name="Santali" />
+	<iso_639_entry
+		iso_639_2B_code="scn"
+		iso_639_2T_code="scn"
+		name="Sicilian" />
+	<iso_639_entry
+		iso_639_2B_code="sco"
+		iso_639_2T_code="sco"
+		name="Scots" />
+	<iso_639_entry
+		iso_639_2B_code="sel"
+		iso_639_2T_code="sel"
+		name="Selkup" />
+	<iso_639_entry
+		iso_639_2B_code="sem"
+		iso_639_2T_code="sem"
+		name="Semitic languages" />
+	<iso_639_entry
+		iso_639_2B_code="sga"
+		iso_639_2T_code="sga"
+		name="Irish, Old (to 900)" />
+	<iso_639_entry
+		iso_639_2B_code="sgn"
+		iso_639_2T_code="sgn"
+		name="Sign Languages" />
+	<iso_639_entry
+		iso_639_2B_code="shn"
+		iso_639_2T_code="shn"
+		name="Shan" />
+	<iso_639_entry
+		iso_639_2B_code="sid"
+		iso_639_2T_code="sid"
+		name="Sidamo" />
+	<iso_639_entry
+		iso_639_2B_code="sin"
+		iso_639_2T_code="sin"
+		iso_639_1_code="si"
+		name="Sinhala; Sinhalese" />
+	<iso_639_entry
+		iso_639_2B_code="sio"
+		iso_639_2T_code="sio"
+		name="Siouan languages" />
+	<iso_639_entry
+		iso_639_2B_code="sit"
+		iso_639_2T_code="sit"
+		name="Sino-Tibetan languages" />
+	<iso_639_entry
+		iso_639_2B_code="sla"
+		iso_639_2T_code="sla"
+		name="Slavic languages" />
+	<iso_639_entry
+		iso_639_2B_code="slo"
+		iso_639_2T_code="slk"
+		iso_639_1_code="sk"
+		name="Slovak" />
+	<iso_639_entry
+		iso_639_2B_code="slv"
+		iso_639_2T_code="slv"
+		iso_639_1_code="sl"
+		name="Slovenian" />
+	<iso_639_entry
+		iso_639_2B_code="sma"
+		iso_639_2T_code="sma"
+		name="Southern Sami" />
+	<iso_639_entry
+		iso_639_2B_code="sme"
+		iso_639_2T_code="sme"
+		iso_639_1_code="se"
+		name="Northern Sami" />
+	<iso_639_entry
+		iso_639_2B_code="smi"
+		iso_639_2T_code="smi"
+		name="Sami languages" />
+	<iso_639_entry
+		iso_639_2B_code="smj"
+		iso_639_2T_code="smj"
+		name="Lule Sami" />
+	<iso_639_entry
+		iso_639_2B_code="smn"
+		iso_639_2T_code="smn"
+		name="Inari Sami" />
+	<iso_639_entry
+		iso_639_2B_code="smo"
+		iso_639_2T_code="smo"
+		iso_639_1_code="sm"
+		name="Samoan" />
+	<iso_639_entry
+		iso_639_2B_code="sms"
+		iso_639_2T_code="sms"
+		name="Skolt Sami" />
+	<iso_639_entry
+		iso_639_2B_code="sna"
+		iso_639_2T_code="sna"
+		iso_639_1_code="sn"
+		name="Shona" />
+	<iso_639_entry
+		iso_639_2B_code="snd"
+		iso_639_2T_code="snd"
+		iso_639_1_code="sd"
+		name="Sindhi" />
+	<iso_639_entry
+		iso_639_2B_code="snk"
+		iso_639_2T_code="snk"
+		name="Soninke" />
+	<iso_639_entry
+		iso_639_2B_code="sog"
+		iso_639_2T_code="sog"
+		name="Sogdian" />
+	<iso_639_entry
+		iso_639_2B_code="som"
+		iso_639_2T_code="som"
+		iso_639_1_code="so"
+		name="Somali" />
+	<iso_639_entry
+		iso_639_2B_code="son"
+		iso_639_2T_code="son"
+		name="Songhai languages" />
+	<iso_639_entry
+		iso_639_2B_code="sot"
+		iso_639_2T_code="sot"
+		iso_639_1_code="st"
+		name="Sotho, Southern" />
+	<iso_639_entry
+		iso_639_2B_code="spa"
+		iso_639_2T_code="spa"
+		iso_639_1_code="es"
+		name="Spanish; Castilian" />
+	<iso_639_entry
+		iso_639_2B_code="srd"
+		iso_639_2T_code="srd"
+		iso_639_1_code="sc"
+		name="Sardinian" />
+	<iso_639_entry
+		iso_639_2B_code="srn"
+		iso_639_2T_code="srn"
+		name="Sranan Tongo" />
+	<iso_639_entry
+		iso_639_2B_code="srp"
+		iso_639_2T_code="srp"
+		iso_639_1_code="sr"
+		name="Serbian" />
+	<iso_639_entry
+		iso_639_2B_code="srr"
+		iso_639_2T_code="srr"
+		name="Serer" />
+	<iso_639_entry
+		iso_639_2B_code="ssa"
+		iso_639_2T_code="ssa"
+		name="Nilo-Saharan languages" />
+	<iso_639_entry
+		iso_639_2B_code="ssw"
+		iso_639_2T_code="ssw"
+		iso_639_1_code="ss"
+		name="Swati" />
+	<iso_639_entry
+		iso_639_2B_code="suk"
+		iso_639_2T_code="suk"
+		name="Sukuma" />
+	<iso_639_entry
+		iso_639_2B_code="sun"
+		iso_639_2T_code="sun"
+		iso_639_1_code="su"
+		name="Sundanese" />
+	<iso_639_entry
+		iso_639_2B_code="sus"
+		iso_639_2T_code="sus"
+		name="Susu" />
+	<iso_639_entry
+		iso_639_2B_code="sux"
+		iso_639_2T_code="sux"
+		name="Sumerian" />
+	<iso_639_entry
+		iso_639_2B_code="swa"
+		iso_639_2T_code="swa"
+		iso_639_1_code="sw"
+		name="Swahili" />
+	<iso_639_entry
+		iso_639_2B_code="swe"
+		iso_639_2T_code="swe"
+		iso_639_1_code="sv"
+		name="Swedish" />
+	<iso_639_entry
+		iso_639_2B_code="syc"
+		iso_639_2T_code="syc"
+		name="Classical Syriac" />
+	<iso_639_entry
+		iso_639_2B_code="syr"
+		iso_639_2T_code="syr"
+		name="Syriac" />
+	<iso_639_entry
+		iso_639_2B_code="tah"
+		iso_639_2T_code="tah"
+		iso_639_1_code="ty"
+		name="Tahitian" />
+	<iso_639_entry
+		iso_639_2B_code="tai"
+		iso_639_2T_code="tai"
+		name="Tai languages" />
+	<iso_639_entry
+		iso_639_2B_code="tam"
+		iso_639_2T_code="tam"
+		iso_639_1_code="ta"
+		name="Tamil" />
+	<iso_639_entry
+		iso_639_2B_code="tat"
+		iso_639_2T_code="tat"
+		iso_639_1_code="tt"
+		name="Tatar" />
+	<iso_639_entry
+		iso_639_2B_code="tel"
+		iso_639_2T_code="tel"
+		iso_639_1_code="te"
+		name="Telugu" />
+	<iso_639_entry
+		iso_639_2B_code="tem"
+		iso_639_2T_code="tem"
+		name="Timne" />
+	<iso_639_entry
+		iso_639_2B_code="ter"
+		iso_639_2T_code="ter"
+		name="Tereno" />
+	<iso_639_entry
+		iso_639_2B_code="tet"
+		iso_639_2T_code="tet"
+		name="Tetum" />
+	<iso_639_entry
+		iso_639_2B_code="tgk"
+		iso_639_2T_code="tgk"
+		iso_639_1_code="tg"
+		name="Tajik" />
+	<iso_639_entry
+		iso_639_2B_code="tgl"
+		iso_639_2T_code="tgl"
+		iso_639_1_code="tl"
+		name="Tagalog" />
+	<iso_639_entry
+		iso_639_2B_code="tha"
+		iso_639_2T_code="tha"
+		iso_639_1_code="th"
+		name="Thai" />
+	<iso_639_entry
+		iso_639_2B_code="tib"
+		iso_639_2T_code="bod"
+		iso_639_1_code="bo"
+		name="Tibetan" />
+	<iso_639_entry
+		iso_639_2B_code="tig"
+		iso_639_2T_code="tig"
+		name="Tigre" />
+	<iso_639_entry
+		iso_639_2B_code="tir"
+		iso_639_2T_code="tir"
+		iso_639_1_code="ti"
+		name="Tigrinya" />
+	<iso_639_entry
+		iso_639_2B_code="tiv"
+		iso_639_2T_code="tiv"
+		name="Tiv" />
+	<iso_639_entry
+		iso_639_2B_code="tkl"
+		iso_639_2T_code="tkl"
+		name="Tokelau" />
+	<iso_639_entry
+		iso_639_2B_code="tlh"
+		iso_639_2T_code="tlh"
+		name="Klingon; tlhIngan-Hol" />
+	<iso_639_entry
+		iso_639_2B_code="tli"
+		iso_639_2T_code="tli"
+		name="Tlingit" />
+	<iso_639_entry
+		iso_639_2B_code="tmh"
+		iso_639_2T_code="tmh"
+		name="Tamashek" />
+	<iso_639_entry
+		iso_639_2B_code="tog"
+		iso_639_2T_code="tog"
+		name="Tonga (Nyasa)" />
+	<iso_639_entry
+		iso_639_2B_code="ton"
+		iso_639_2T_code="ton"
+		iso_639_1_code="to"
+		name="Tonga (Tonga Islands)" />
+	<iso_639_entry
+		iso_639_2B_code="tpi"
+		iso_639_2T_code="tpi"
+		name="Tok Pisin" />
+	<iso_639_entry
+		iso_639_2B_code="tsi"
+		iso_639_2T_code="tsi"
+		name="Tsimshian" />
+	<iso_639_entry
+		iso_639_2B_code="tsn"
+		iso_639_2T_code="tsn"
+		iso_639_1_code="tn"
+		name="Tswana" />
+	<iso_639_entry
+		iso_639_2B_code="tso"
+		iso_639_2T_code="tso"
+		iso_639_1_code="ts"
+		name="Tsonga" />
+	<iso_639_entry
+		iso_639_2B_code="tuk"
+		iso_639_2T_code="tuk"
+		iso_639_1_code="tk"
+		name="Turkmen" />
+	<iso_639_entry
+		iso_639_2B_code="tum"
+		iso_639_2T_code="tum"
+		name="Tumbuka" />
+	<iso_639_entry
+		iso_639_2B_code="tup"
+		iso_639_2T_code="tup"
+		name="Tupi languages" />
+	<iso_639_entry
+		iso_639_2B_code="tur"
+		iso_639_2T_code="tur"
+		iso_639_1_code="tr"
+		name="Turkish" />
+	<iso_639_entry
+		iso_639_2B_code="tut"
+		iso_639_2T_code="tut"
+		name="Altaic languages" />
+	<iso_639_entry
+		iso_639_2B_code="tvl"
+		iso_639_2T_code="tvl"
+		name="Tuvalu" />
+	<iso_639_entry
+		iso_639_2B_code="twi"
+		iso_639_2T_code="twi"
+		iso_639_1_code="tw"
+		name="Twi" />
+	<iso_639_entry
+		iso_639_2B_code="tyv"
+		iso_639_2T_code="tyv"
+		name="Tuvinian" />
+	<iso_639_entry
+		iso_639_2B_code="udm"
+		iso_639_2T_code="udm"
+		name="Udmurt" />
+	<iso_639_entry
+		iso_639_2B_code="uga"
+		iso_639_2T_code="uga"
+		name="Ugaritic" />
+	<iso_639_entry
+		iso_639_2B_code="uig"
+		iso_639_2T_code="uig"
+		iso_639_1_code="ug"
+		name="Uighur; Uyghur" />
+	<iso_639_entry
+		iso_639_2B_code="ukr"
+		iso_639_2T_code="ukr"
+		iso_639_1_code="uk"
+		name="Ukrainian" />
+	<iso_639_entry
+		iso_639_2B_code="umb"
+		iso_639_2T_code="umb"
+		name="Umbundu" />
+	<iso_639_entry
+		iso_639_2B_code="und"
+		iso_639_2T_code="und"
+		name="Undetermined" />
+	<iso_639_entry
+		iso_639_2B_code="urd"
+		iso_639_2T_code="urd"
+		iso_639_1_code="ur"
+		name="Urdu" />
+	<iso_639_entry
+		iso_639_2B_code="uzb"
+		iso_639_2T_code="uzb"
+		iso_639_1_code="uz"
+		name="Uzbek" />
+	<iso_639_entry
+		iso_639_2B_code="vai"
+		iso_639_2T_code="vai"
+		name="Vai" />
+	<iso_639_entry
+		iso_639_2B_code="ven"
+		iso_639_2T_code="ven"
+		iso_639_1_code="ve"
+		name="Venda" />
+	<iso_639_entry
+		iso_639_2B_code="vie"
+		iso_639_2T_code="vie"
+		iso_639_1_code="vi"
+		name="Vietnamese" />
+	<iso_639_entry
+		iso_639_2B_code="vol"
+		iso_639_2T_code="vol"
+		iso_639_1_code="vo"
+		name="Volapük" />
+	<iso_639_entry
+		iso_639_2B_code="vot"
+		iso_639_2T_code="vot"
+		name="Votic" />
+	<iso_639_entry
+		iso_639_2B_code="wak"
+		iso_639_2T_code="wak"
+		name="Wakashan languages" />
+	<iso_639_entry
+		iso_639_2B_code="wal"
+		iso_639_2T_code="wal"
+		name="Wolaitta; Wolaytta" />
+	<iso_639_entry
+		iso_639_2B_code="war"
+		iso_639_2T_code="war"
+		name="Waray" />
+	<iso_639_entry
+		iso_639_2B_code="was"
+		iso_639_2T_code="was"
+		name="Washo" />
+	<iso_639_entry
+		iso_639_2B_code="wel"
+		iso_639_2T_code="cym"
+		iso_639_1_code="cy"
+		name="Welsh" />
+	<iso_639_entry
+		iso_639_2B_code="wen"
+		iso_639_2T_code="wen"
+		name="Sorbian languages" />
+	<iso_639_entry
+		iso_639_2B_code="wln"
+		iso_639_2T_code="wln"
+		iso_639_1_code="wa"
+		name="Walloon" />
+	<iso_639_entry
+		iso_639_2B_code="wol"
+		iso_639_2T_code="wol"
+		iso_639_1_code="wo"
+		name="Wolof" />
+	<iso_639_entry
+		iso_639_2B_code="xal"
+		iso_639_2T_code="xal"
+		name="Kalmyk; Oirat" />
+	<iso_639_entry
+		iso_639_2B_code="xho"
+		iso_639_2T_code="xho"
+		iso_639_1_code="xh"
+		name="Xhosa" />
+	<iso_639_entry
+		iso_639_2B_code="yao"
+		iso_639_2T_code="yao"
+		name="Yao" />
+	<iso_639_entry
+		iso_639_2B_code="yap"
+		iso_639_2T_code="yap"
+		name="Yapese" />
+	<iso_639_entry
+		iso_639_2B_code="yid"
+		iso_639_2T_code="yid"
+		iso_639_1_code="yi"
+		name="Yiddish" />
+	<iso_639_entry
+		iso_639_2B_code="yor"
+		iso_639_2T_code="yor"
+		iso_639_1_code="yo"
+		name="Yoruba" />
+	<iso_639_entry
+		iso_639_2B_code="ypk"
+		iso_639_2T_code="ypk"
+		name="Yupik languages" />
+	<iso_639_entry
+		iso_639_2B_code="zap"
+		iso_639_2T_code="zap"
+		name="Zapotec" />
+	<iso_639_entry
+		iso_639_2B_code="zbl"
+		iso_639_2T_code="zbl"
+		name="Blissymbols; Blissymbolics; Bliss" />
+	<iso_639_entry
+		iso_639_2B_code="zen"
+		iso_639_2T_code="zen"
+		name="Zenaga" />
+	<iso_639_entry
+		iso_639_2B_code="zha"
+		iso_639_2T_code="zha"
+		iso_639_1_code="za"
+		name="Zhuang; Chuang" />
+	<iso_639_entry
+		iso_639_2B_code="znd"
+		iso_639_2T_code="znd"
+		name="Zande languages" />
+	<iso_639_entry
+		iso_639_2B_code="zul"
+		iso_639_2T_code="zul"
+		iso_639_1_code="zu"
+		name="Zulu" />
+	<iso_639_entry
+		iso_639_2B_code="zun"
+		iso_639_2T_code="zun"
+		name="Zuni" />
+	<iso_639_entry
+		iso_639_2B_code="zxx"
+		iso_639_2T_code="zxx"
+		name="No linguistic content; Not applicable" />
+	<iso_639_entry
+		iso_639_2B_code="zza"
+		iso_639_2T_code="zza"
+		name="Zaza; Dimili; Dimli; Kirdki; Kirmanjki; Zazaki" />
+</iso_639_entries>
diff --git a/win32/etc/download.png b/win32/etc/download.png
deleted file mode 100644
index 43253432..00000000
Binary files a/win32/etc/download.png and /dev/null differ
diff --git a/win32/etc/gtk-2.0/gtkrc b/win32/etc/gtk-2.0/gtkrc
deleted file mode 100644
index 6ac7b76c..00000000
--- a/win32/etc/gtk-2.0/gtkrc
+++ /dev/null
@@ -1,71 +0,0 @@
-gtk-font-name = "sans 8"
-
-gtk-icon-sizes = "gtk-menu=13,13:gtk-small-toolbar=16,16:gtk-large-toolbar=24,24:gtk-dnd=32,32"
-gtk-toolbar-icon-size = small-toolbar
-
-# disable images in buttons. i've only seen ugly delphi apps use this feature.
-gtk-button-images = 0
-
-# enable/disable images in menus. most "stock" microsoft apps don't use these, except sparingly.
-# the office apps use them heavily, though.
-gtk-menu-images = 1
-
-# use the win32 button ordering instead of the GNOME HIG one, where applicable
-gtk-alternative-button-order = 1
-
-# use the win32 sort indicators direction, as in Explorer
-gtk-alternative-sort-arrows = 1
-
-# Windows users don't expect the PC Speaker beeping at them when they backspace in an empty textview and stuff like that
-gtk-error-bell = 0
-
-# hide mnemonic underlines until the Alt key is pressed (requires gtk 2.18+)
-# gtk-auto-mnemonics = 1
-
-style "msw-default"
-{
-  GtkWidget::interior-focus = 1
-  GtkOptionMenu::indicator-size = { 9, 5 }
-  GtkOptionMenu::indicator-spacing = { 7, 5, 2, 2 }
-  GtkSpinButton::shadow-type = in
-
-  # Owen and I disagree that these should be themable
-  #GtkUIManager::add-tearoffs = 0
-  #GtkComboBox::add-tearoffs = 0
-
-  GtkComboBox::appears-as-list = 1
-  GtkComboBox::focus-on-click = 0
-
-  GOComboBox::add_tearoffs = 0
-
-  GtkTreeView::allow-rules = 0
-  GtkTreeView::expander-size = 12
-
-  GtkExpander::expander-size = 12
-
-  GtkScrolledWindow::scrollbar_spacing = 1
-
-  GtkSeparatorMenuItem::horizontal-padding = 2
-
-  engine "wimp"
-  {
-  }
-}
-class "*" style "msw-default"
-
-binding "ms-windows-tree-view"
-{
-  bind "Right" { "expand-collapse-cursor-row" (1,1,0) }
-  bind "Left" { "expand-collapse-cursor-row" (1,0,0) }
-}
-
-class "GtkTreeView" binding "ms-windows-tree-view"
-
-style "msw-combobox-thickness" = "msw-default"
-{
-  xthickness = 0
-  ythickness = 0
-}
-
-widget_class "*TreeView*ComboBox*" style "msw-combobox-thickness"
-widget_class "*ComboBox*GtkFrame*" style "msw-combobox-thickness"
diff --git a/win32/etc/gtkpref.png b/win32/etc/gtkpref.png
deleted file mode 100644
index 9a6c9cf9..00000000
Binary files a/win32/etc/gtkpref.png and /dev/null differ
diff --git a/win32/etc/music.png b/win32/etc/music.png
deleted file mode 100644
index 3a72f118..00000000
Binary files a/win32/etc/music.png and /dev/null differ
diff --git a/win32/etc/system.png b/win32/etc/system.png
deleted file mode 100644
index fc4282c7..00000000
Binary files a/win32/etc/system.png and /dev/null differ
diff --git a/win32/installer/installer.vcxproj b/win32/installer/installer.vcxproj
index a8ca84fa..3cb84d56 100644
--- a/win32/installer/installer.vcxproj
+++ b/win32/installer/installer.vcxproj
@@ -16,6 +16,7 @@
     <UseDebugLibraries>false</UseDebugLibraries>
     <WholeProgramOptimization>true</WholeProgramOptimization>
     <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
@@ -25,7 +26,10 @@
     <Import Project="..\xchat.props" />
   </ImportGroup>
   <PropertyGroup Label="UserMacros" />
-  <PropertyGroup />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level3</WarningLevel>
@@ -39,19 +43,25 @@
       <OptimizeReferences>true</OptimizeReferences>
     </Link>
     <PreBuildEvent>
-      <Command>echo [Setup] &gt; "$(SolutionDir)\xchat-wdk-x86.iss"
-echo WizardImageFile="$(SolutionDir)\bitmaps\wizardimage.bmp" &gt;&gt; "$(SolutionDir)\xchat-wdk-x86.iss"
-echo WizardSmallImageFile="$(SolutionDir)\bitmaps\wizardsmallimage.bmp" &gt;&gt; "$(SolutionDir)\xchat-wdk-x86.iss"
-"$(OutDir)\version" -a32 &gt;&gt; "$(SolutionDir)\xchat-wdk-x86.iss"
-"$(OutDir)\version" -v &gt;&gt; "$(SolutionDir)\xchat-wdk-x86.iss"
-"$(OutDir)\version" -i &gt;&gt; "$(SolutionDir)\xchat-wdk-x86.iss"
-"$(OutDir)\version" -o32 &gt;&gt; "$(SolutionDir)\xchat-wdk-x86.iss"
-echo SetupIconFile="$(SolutionDir)\..\xchat.ico" &gt;&gt; "$(SolutionDir)\xchat-wdk-x86.iss"
-type "$(SolutionDir)\xchat-wdk-x86.skel.iss" &gt;&gt; "$(SolutionDir)\xchat-wdk-x86.iss"
-"$(ProgramFiles)\Inno Setup 5\compil32" /cc "$(SolutionDir)\xchat-wdk-x86.iss"</Command>
+      <Command>echo [Setup] &gt; "$(OutDir)\xchat-wdk-x86.iss"
+echo WizardImageFile="$(ProjectDir)\wizardimage.bmp" &gt;&gt; "$(OutDir)\xchat-wdk-x86.iss"
+echo WizardSmallImageFile="$(ProjectDir)\wizardsmallimage.bmp" &gt;&gt; "$(OutDir)\xchat-wdk-x86.iss"
+"$(OutDir)\version" -a &gt;&gt; "$(OutDir)\xchat-wdk-x86.iss"
+"$(OutDir)\version" -v &gt;&gt; "$(OutDir)\xchat-wdk-x86.iss"
+"$(OutDir)\version" -i &gt;&gt; "$(OutDir)\xchat-wdk-x86.iss"
+"$(OutDir)\version" -o &gt;&gt; "$(OutDir)\xchat-wdk-x86.iss"
+echo SetupIconFile="$(SolutionDir)\..\xchat.ico" &gt;&gt; "$(OutDir)\xchat-wdk-x86.iss"
+type xchat-wdk-x86.skel.iss &gt;&gt; "$(OutDir)\xchat-wdk-x86.iss"
+"$(ProgramFiles)\Inno Setup 5\compil32" /cc "$(OutDir)\xchat-wdk-x86.iss"</Command>
     </PreBuildEvent>
   </ItemDefinitionGroup>
   <ItemGroup>
+    <None Include="watercolorlite-blue.cjstyles" />
+    <None Include="watercolorlite-green.cjstyles" />
+    <None Include="wizardimage.bmp" />
+    <None Include="wizardsmallimage.bmp" />
+    <None Include="xchat-wdk-x64.skel.iss" />
+    <None Include="xchat-wdk-x86.skel.iss" />
   </ItemGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
   <ImportGroup Label="ExtensionTargets">
diff --git a/win32/installer/installer.vcxproj.filters b/win32/installer/installer.vcxproj.filters
index 47cfb34e..b18a6411 100644
--- a/win32/installer/installer.vcxproj.filters
+++ b/win32/installer/installer.vcxproj.filters
@@ -1,17 +1,29 @@
 <?xml version="1.0" encoding="utf-8"?>
 <Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
   <ItemGroup>
-    <Filter Include="Source Files">
-      <UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
-      <Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
-    </Filter>
-    <Filter Include="Header Files">
-      <UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
-      <Extensions>h;hpp;hxx;hm;inl;inc;xsd</Extensions>
-    </Filter>
     <Filter Include="Resource Files">
       <UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
       <Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
     </Filter>
   </ItemGroup>
+  <ItemGroup>
+    <None Include="xchat-wdk-x64.skel.iss">
+      <Filter>Resource Files</Filter>
+    </None>
+    <None Include="xchat-wdk-x86.skel.iss">
+      <Filter>Resource Files</Filter>
+    </None>
+    <None Include="watercolorlite-blue.cjstyles">
+      <Filter>Resource Files</Filter>
+    </None>
+    <None Include="watercolorlite-green.cjstyles">
+      <Filter>Resource Files</Filter>
+    </None>
+    <None Include="wizardimage.bmp">
+      <Filter>Resource Files</Filter>
+    </None>
+    <None Include="wizardsmallimage.bmp">
+      <Filter>Resource Files</Filter>
+    </None>
+  </ItemGroup>
 </Project>
\ No newline at end of file
diff --git a/win32/installer/watercolorlite-blue.cjstyles b/win32/installer/watercolorlite-blue.cjstyles
new file mode 100644
index 00000000..a457029b
Binary files /dev/null and b/win32/installer/watercolorlite-blue.cjstyles differ
diff --git a/win32/installer/watercolorlite-green.cjstyles b/win32/installer/watercolorlite-green.cjstyles
new file mode 100644
index 00000000..2b77026d
Binary files /dev/null and b/win32/installer/watercolorlite-green.cjstyles differ
diff --git a/win32/installer/wizardimage.bmp b/win32/installer/wizardimage.bmp
new file mode 100644
index 00000000..9f5a4c90
Binary files /dev/null and b/win32/installer/wizardimage.bmp differ
diff --git a/win32/installer/wizardsmallimage.bmp b/win32/installer/wizardsmallimage.bmp
new file mode 100644
index 00000000..1bb8b790
Binary files /dev/null and b/win32/installer/wizardsmallimage.bmp differ
diff --git a/win32/installer/xchat-wdk-x64.skel.iss b/win32/installer/xchat-wdk-x64.skel.iss
new file mode 100644
index 00000000..e0a804db
--- /dev/null
+++ b/win32/installer/xchat-wdk-x64.skel.iss
@@ -0,0 +1,279 @@
+AppName=XChat-WDK (x64)
+AppPublisher=XChat-WDK
+AppPublisherURL=http://www.xchat-wdk.org/
+AppCopyright=Copyright (C) 1998-2010 Peter Zelezny
+AppSupportURL=http://code.google.com/p/xchat-wdk/issues/list
+AppUpdatesURL=http://www.xchat-wdk.org/home/downloads
+LicenseFile=COPYING
+UninstallDisplayIcon={app}\xchat.exe
+UninstallDisplayName=XChat-WDK (x64)
+DefaultDirName={pf}\XChat-WDK
+DefaultGroupName=XChat-WDK
+DisableProgramGroupPage=yes
+SolidCompression=yes
+SourceDir=..\..\rel
+OutputDir=..\..
+FlatComponentsList=no
+PrivilegesRequired=none
+ShowComponentSizes=no
+CreateUninstallRegKey=not IsTaskSelected('portable')
+Uninstallable=not IsTaskSelected('portable')
+ArchitecturesAllowed=x64
+ArchitecturesInstallIn64BitMode=x64
+
+[Types]
+Name: "normal"; Description: "Normal Installation"
+Name: "full"; Description: "Full Installation"
+Name: "minimal"; Description: "Minimal Installation"
+Name: "custom"; Description: "Custom Installation"; Flags: iscustom
+
+[Components]
+Name: "libs"; Description: "XChat-WDK"; Types: normal full minimal custom; Flags: fixed
+Name: "xctext"; Description: "XChat-Text"; Types: full custom; Flags: disablenouninstallwarning
+Name: "translations"; Description: "Translations"; Types: normal full custom; Flags: disablenouninstallwarning
+;obs Name: "gtkengines"; Description: "GTK+ Engines"; Types: full custom; Flags: disablenouninstallwarning
+;Name: "spelling"; Description: "Spelling Dictionaries"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins"; Description: "Plugins"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\checksum"; Description: "Checksum"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\dns"; Description: "DNS"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\doat"; Description: "Do At"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\exec"; Description: "Exec"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\fishlim"; Description: "FiSHLiM"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\mpcinfo"; Description: "mpcInfo"; Types: full custom; Flags: disablenouninstallwarning
+;Name: "plugins\nonbmp"; Description: "Non-BMP"; Types: normal full custom; Flags: disablenouninstallwarning
+Name: "plugins\upd"; Description: "Update Checker"; Types: normal full custom; Flags: disablenouninstallwarning
+Name: "plugins\winamp"; Description: "Winamp"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\winsys"; Description: "WinSys"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\wmpa"; Description: "Windows Media Player Announcer"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\xsasl"; Description: "X-SASL"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\xtray"; Description: "X-Tray"; Types: full custom; Flags: disablenouninstallwarning
+Name: "langs"; Description: "Language Interfaces"; Types: full custom; Flags: disablenouninstallwarning
+Name: "langs\lua"; Description: "Lua"; Types: full custom; Flags: disablenouninstallwarning
+Name: "langs\lua\luawdk"; Description: "Lua-WDK"; Types: full custom; Flags: disablenouninstallwarning
+Name: "langs\perl"; Description: "Perl"; Types: full custom; Flags: disablenouninstallwarning
+Name: "langs\python"; Description: "Python"; Types: full custom; Flags: disablenouninstallwarning
+Name: "langs\tcl"; Description: "Tcl"; Types: full custom; Flags: disablenouninstallwarning
+
+[Tasks]
+Name: portable; Description: "Yes"; GroupDescription: "Portable Install (no Registry entries, no Start Menu icons, no uninstaller):"; Flags: unchecked
+
+Name: perl512; Description: "5.12"; GroupDescription: "Perl version:"; Flags: exclusive; Components: langs\perl
+Name: perl514; Description: "5.14"; GroupDescription: "Perl version:"; Flags: exclusive unchecked; Components: langs\perl
+
+[Registry]
+Root: HKCR; Subkey: "irc"; ValueType: none; ValueName: ""; ValueData: ""; Flags: deletekey uninsdeletekey; Tasks: not portable
+Root: HKCR; Subkey: "irc"; ValueType: string; ValueName: ""; ValueData: "URL:IRC Protocol"; Flags: uninsdeletevalue; Tasks: not portable
+Root: HKCR; Subkey: "irc"; ValueType: string; ValueName: "URL Protocol"; ValueData: ""; Flags: uninsdeletevalue; Tasks: not portable
+Root: HKCR; Subkey: "irc\DefaultIcon"; ValueType: string; ValueName: ""; ValueData: "{app}\xchat.exe,0"; Flags: uninsdeletevalue; Tasks: not portable
+Root: HKCR; Subkey: "irc\shell"; ValueType: string; ValueName: ""; ValueData: "open"; Flags: uninsdeletevalue; Tasks: not portable
+Root: HKCR; Subkey: "irc\shell\open\command"; ValueType: string; ValueName: ""; ValueData: "{app}\xchat.exe --url=""%1"""; Flags: uninsdeletevalue; Tasks: not portable
+
+[Run]
+Filename: "{app}\xchat.exe"; Description: "Run XChat-WDK after closing the Wizard"; Flags: nowait postinstall skipifsilent
+
+[Files]
+; Add the ISSkin DLL used for skinning Inno Setup installations.
+Source: ISSkinU.dll; DestDir: {app}; Flags: dontcopy
+
+; Add the Visual Style resource contains resources used for skinning,
+; you can also use Microsoft Visual Styles (*.msstyles) resources.
+Source: watercolorlite-blue.cjstyles; DestDir: {tmp}; Flags: dontcopy
+
+Source: "portable-mode"; DestDir: "{app}"; Tasks: portable
+
+Source: "cert.pem"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "COPYING"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "LICENSE.OPENSSL"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "LICENSE.ZLIB"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "LICENSE.GTK"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "LICENSE.CAIRO"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "LICENSE.LUA"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "LICENSE.ENCHANT"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "LICENSE.LIBXML"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "etc\gtk-2.0\gtkrc"; DestDir: "{app}\etc\gtk-2.0"; Flags: ignoreversion; Components: libs
+;Source: "etc\gtk-2.0\gtkrc"; DestDir: "{app}\etc\gtk-2.0"; Flags: ignoreversion; Components: libs and not gtkengines
+Source: "share\xml\*"; DestDir: "{app}\share\xml"; Flags: ignoreversion createallsubdirs recursesubdirs; Components: libs
+Source: "locale\*"; DestDir: "{app}\locale"; Flags: ignoreversion createallsubdirs recursesubdirs; Components: translations
+Source: "share\locale\*"; DestDir: "{app}\share\locale"; Flags: ignoreversion createallsubdirs recursesubdirs; Components: translations
+;Source: "share\myspell\*"; DestDir: "{app}\share\myspell"; Flags: ignoreversion createallsubdirs recursesubdirs; Components: spelling
+
+Source: "libatk-1.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libcairo-2.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libeay32.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libexpat-1.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+;obs Source: "libffi-5.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libfreetype-6.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libfontconfig-1.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libgdk_pixbuf-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libgdk-win32-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libgio-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libglib-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libgmodule-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libgobject-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libgthread-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libgtk-win32-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libintl-8.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+;obs Source: "libjasper-1.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+;obs Source: "libjpeg-8.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libpango-1.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libpangocairo-1.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libpangoft2-1.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libpangowin32-1.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+;obs Source: "libpixman-1-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+;obs Source: "libtiff-3.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libpng14-14.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+;obs Source: "libpng15-15.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "lua51.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "ssleay32.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "zlib1.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libxml2.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+;obs Source: "libxml2-2.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libenchant.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+
+Source: "lib\enchant\libenchant_myspell.dll"; DestDir: "{app}\lib\enchant"; Flags: ignoreversion; Components: libs
+
+Source: "lib\gtk-2.0\2.10.0\engines\libpixmap.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: libs
+Source: "lib\gtk-2.0\2.10.0\engines\libwimp.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: libs
+Source: "lib\gtk-2.0\modules\libgail.dll"; DestDir: "{app}\lib\gtk-2.0\modules"; Flags: ignoreversion; Components: libs
+
+;obs Source: "etc\gtkpref.png"; DestDir: "{app}\etc"; Flags: ignoreversion; Components: gtkengines
+;obs Source: "lib\gtk-2.0\2.10.0\engines\libclearlooks.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
+;obs Source: "lib\gtk-2.0\2.10.0\engines\libcrux-engine.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
+;obs Source: "lib\gtk-2.0\2.10.0\engines\libglide.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
+;obs Source: "lib\gtk-2.0\2.10.0\engines\libhcengine.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
+;obs Source: "lib\gtk-2.0\2.10.0\engines\libindustrial.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
+;obs Source: "lib\gtk-2.0\2.10.0\engines\libmist.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
+;obs Source: "lib\gtk-2.0\2.10.0\engines\libmurrine.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
+;obs Source: "lib\gtk-2.0\2.10.0\engines\libredmond95.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
+;obs Source: "lib\gtk-2.0\2.10.0\engines\libthinice.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
+;obs Source: "plugins\xcgtkpref.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: gtkengines
+;obs Source: "share\themes\*"; DestDir: "{app}\share\themes"; Flags: ignoreversion createallsubdirs recursesubdirs; Components: gtkengines
+;obs Source: "gtk2-prefs.exe"; DestDir: "{app}"; Flags: ignoreversion; Components: gtkengines
+
+Source: "plugins\xcchecksum.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\checksum
+Source: "plugins\xcdns.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\dns
+Source: "plugins\xcdoat.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\doat
+Source: "plugins\xcexec.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\exec
+Source: "plugins\xcfishlim.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\fishlim
+Source: "etc\music.png"; DestDir: "{app}\etc"; Flags: ignoreversion; Components: plugins\winamp or plugins\mpcinfo
+Source: "plugins\xcmpcinfo.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\mpcinfo
+;Source: "plugins\xcnonbmp.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\nonbmp
+Source: "etc\download.png"; DestDir: "{app}\etc"; Flags: ignoreversion; Components: plugins\upd
+Source: "plugins\xcupd.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\upd
+Source: "plugins\xcwinamp.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\winamp
+Source: "etc\system.png"; DestDir: "{app}\etc"; Flags: ignoreversion; Components: plugins\winsys
+Source: "plugins\xcwinsys.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\winsys
+Source: "plugins\xcxsasl.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\xsasl
+Source: "plugins\xtray.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\xtray
+Source: "plugins\xcwmpa.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\wmpa
+
+Source: "plugins\xclua.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: langs\lua
+Source: "plugins\xcpython.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: langs\python
+Source: "plugins\xctcl.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: langs\tcl
+
+Source: "plugins\xcperl-512.dll"; DestDir: "{app}\plugins"; DestName: "xcperl.dll"; Flags: ignoreversion; Components: langs\perl; Tasks: perl512
+Source: "plugins\xcperl-514.dll"; DestDir: "{app}\plugins"; DestName: "xcperl.dll"; Flags: ignoreversion; Components: langs\perl; Tasks: perl514
+
+Source: "xchat.exe"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "xchat-text.exe"; DestDir: "{app}"; Flags: ignoreversion; Components: xctext
+
+[Icons]
+Name: "{group}\XChat-WDK (x64)"; Filename: "{app}\xchat.exe"; Tasks: not portable
+Name: "{group}\XChat-Text (x64)"; Filename: "{app}\xchat-text.exe"; Components: xctext; Tasks: not portable
+Name: "{group}\Uninstall XChat-WDK (x64)"; Filename: "{uninstallexe}"; Tasks: not portable
+
+[Messages]
+BeveledLabel= XChat-WDK
+
+[Code]
+/////////////////////////////////////////////////////////////////////
+// these are required for x86->x64 or reverse upgrades
+/////////////////////////////////////////////////////////////////////
+function GetUninstallString(): String;
+var
+	sUnInstPath: String;
+	sUnInstallString: String;
+begin
+	sUnInstPath := ExpandConstant('Software\Microsoft\Windows\CurrentVersion\Uninstall\XChat-WDK (x64)_is1');
+	sUnInstallString := '';
+	if not RegQueryStringValue(HKLM, sUnInstPath, 'UninstallString', sUnInstallString) then
+		RegQueryStringValue(HKCU, sUnInstPath, 'UninstallString', sUnInstallString);
+	Result := sUnInstallString;
+end;
+
+
+/////////////////////////////////////////////////////////////////////
+function IsUpgrade(): Boolean;
+begin
+	Result := (GetUninstallString() <> '');
+end;
+
+
+/////////////////////////////////////////////////////////////////////
+function UnInstallOldVersion(): Integer;
+var
+	sUnInstallString: String;
+	iResultCode: Integer;
+begin
+// Return Values:
+// 1 - uninstall string is empty
+// 2 - error executing the UnInstallString
+// 3 - successfully executed the UnInstallString
+
+	// default return value
+	Result := 0;
+
+	// get the uninstall string of the old app
+	sUnInstallString := GetUninstallString();
+	if sUnInstallString <> '' then begin
+		sUnInstallString := RemoveQuotes(sUnInstallString);
+		if Exec(sUnInstallString, '/SILENT /NORESTART /SUPPRESSMSGBOXES','', SW_HIDE, ewWaitUntilTerminated, iResultCode) then
+			Result := 3
+		else
+			Result := 2;
+	end else
+		Result := 1;
+end;
+
+/////////////////////////////////////////////////////////////////////
+procedure CurStepChanged(CurStep: TSetupStep);
+begin
+	if not (IsTaskSelected('portable')) then
+	begin
+		if (CurStep=ssInstall) then
+		begin
+			if (IsUpgrade()) then
+			begin
+				UnInstallOldVersion();
+			end;
+		end;
+	end;
+end;
+
+/////////////////////////////////////////////////////////////////////
+// Importing LoadSkin API from ISSkin.DLL
+procedure LoadSkin(lpszPath: String; lpszIniFileName: String);
+external 'LoadSkin@files:isskinu.dll stdcall';
+
+// Importing UnloadSkin API from ISSkin.DLL
+procedure UnloadSkin();
+external 'UnloadSkin@files:isskinu.dll stdcall';
+
+// Importing ShowWindow Windows API from User32.DLL
+function ShowWindow(hWnd: Integer; uType: Integer): Integer;
+external 'ShowWindow@user32.dll stdcall';
+
+function InitializeSetup(): Boolean;
+begin
+  ExtractTemporaryFile('watercolorlite-blue.cjstyles');
+  LoadSkin(ExpandConstant('{tmp}\watercolorlite-blue.cjstyles'), '');
+  Result := True;
+end;
+
+procedure DeinitializeSetup();
+begin
+  // Hide Window before unloading skin so user does not get
+  // a glimpse of an unskinned window before it is closed.
+  ShowWindow(StrToInt(ExpandConstant('{wizardhwnd}')), 0);
+  UnloadSkin();
+end;
diff --git a/win32/installer/xchat-wdk-x86.skel.iss b/win32/installer/xchat-wdk-x86.skel.iss
new file mode 100644
index 00000000..748c2b19
--- /dev/null
+++ b/win32/installer/xchat-wdk-x86.skel.iss
@@ -0,0 +1,282 @@
+AppName=XChat-WDK (x86)
+AppPublisher=XChat-WDK
+AppPublisherURL=http://www.xchat-wdk.org/
+AppCopyright=Copyright (C) 1998-2010 Peter Zelezny
+AppSupportURL=http://code.google.com/p/xchat-wdk/issues/list
+AppUpdatesURL=http://www.xchat-wdk.org/home/downloads
+LicenseFile=COPYING
+UninstallDisplayIcon={app}\xchat.exe
+UninstallDisplayName=XChat-WDK (x86)
+DefaultDirName={pf}\XChat-WDK
+DefaultGroupName=XChat-WDK
+DisableProgramGroupPage=yes
+SolidCompression=yes
+SourceDir=..\rel
+OutputDir=..
+FlatComponentsList=no
+PrivilegesRequired=none
+ShowComponentSizes=no
+CreateUninstallRegKey=not IsTaskSelected('portable')
+Uninstallable=not IsTaskSelected('portable')
+ArchitecturesAllowed=x86 x64
+
+[Types]
+Name: "normal"; Description: "Normal Installation"
+Name: "full"; Description: "Full Installation"
+Name: "minimal"; Description: "Minimal Installation"
+Name: "custom"; Description: "Custom Installation"; Flags: iscustom
+
+[Components]
+Name: "libs"; Description: "XChat-WDK"; Types: normal full minimal custom; Flags: fixed
+Name: "xctext"; Description: "XChat-Text"; Types: full custom; Flags: disablenouninstallwarning
+Name: "translations"; Description: "Translations"; Types: normal full custom; Flags: disablenouninstallwarning
+;obs Name: "gtkengines"; Description: "GTK+ Engines"; Types: full custom; Flags: disablenouninstallwarning
+;Name: "spelling"; Description: "Spelling Dictionaries"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins"; Description: "Plugins"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\checksum"; Description: "Checksum"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\dns"; Description: "DNS"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\doat"; Description: "Do At"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\exec"; Description: "Exec"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\fishlim"; Description: "FiSHLiM"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\mpcinfo"; Description: "mpcInfo"; Types: full custom; Flags: disablenouninstallwarning
+;Name: "plugins\nonbmp"; Description: "Non-BMP"; Types: normal full custom; Flags: disablenouninstallwarning
+Name: "plugins\upd"; Description: "Update Checker"; Types: normal full custom; Flags: disablenouninstallwarning
+Name: "plugins\winamp"; Description: "Winamp"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\winsys"; Description: "WinSys"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\wmpa"; Description: "Windows Media Player Announcer"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\xsasl"; Description: "X-SASL"; Types: full custom; Flags: disablenouninstallwarning
+Name: "plugins\xtray"; Description: "X-Tray"; Types: full custom; Flags: disablenouninstallwarning
+Name: "langs"; Description: "Language Interfaces"; Types: full custom; Flags: disablenouninstallwarning
+Name: "langs\lua"; Description: "Lua"; Types: full custom; Flags: disablenouninstallwarning
+Name: "langs\lua\luawdk"; Description: "Lua-WDK"; Types: full custom; Flags: disablenouninstallwarning
+Name: "langs\perl"; Description: "Perl"; Types: full custom; Flags: disablenouninstallwarning
+Name: "langs\python"; Description: "Python"; Types: full custom; Flags: disablenouninstallwarning
+Name: "langs\tcl"; Description: "Tcl"; Types: full custom; Flags: disablenouninstallwarning
+
+[Tasks]
+Name: portable; Description: "Yes"; GroupDescription: "Portable Install (no Registry entries, no Start Menu icons, no uninstaller):"; Flags: unchecked
+
+Name: perl512; Description: "5.12"; GroupDescription: "Perl version:"; Flags: exclusive; Components: langs\perl
+Name: perl514; Description: "5.14"; GroupDescription: "Perl version:"; Flags: exclusive unchecked; Components: langs\perl
+Name: perl516; Description: "5.16"; GroupDescription: "Perl version:"; Flags: exclusive unchecked; Components: langs\perl
+
+[Registry]
+Root: HKCR; Subkey: "irc"; ValueType: none; ValueName: ""; ValueData: ""; Flags: deletekey uninsdeletekey; Tasks: not portable
+Root: HKCR; Subkey: "irc"; ValueType: string; ValueName: ""; ValueData: "URL:IRC Protocol"; Flags: uninsdeletevalue; Tasks: not portable
+Root: HKCR; Subkey: "irc"; ValueType: string; ValueName: "URL Protocol"; ValueData: ""; Flags: uninsdeletevalue; Tasks: not portable
+Root: HKCR; Subkey: "irc\DefaultIcon"; ValueType: string; ValueName: ""; ValueData: "{app}\xchat.exe,0"; Flags: uninsdeletevalue; Tasks: not portable
+Root: HKCR; Subkey: "irc\shell"; ValueType: string; ValueName: ""; ValueData: "open"; Flags: uninsdeletevalue; Tasks: not portable
+Root: HKCR; Subkey: "irc\shell\open\command"; ValueType: string; ValueName: ""; ValueData: "{app}\xchat.exe --url=""%1"""; Flags: uninsdeletevalue; Tasks: not portable
+
+[Run]
+Filename: "{app}\xchat.exe"; Description: "Run XChat-WDK after closing the Wizard"; Flags: nowait postinstall skipifsilent
+
+[Files]
+; Add the ISSkin DLL used for skinning Inno Setup installations.
+Source: ISSkinU.dll; DestDir: {app}; Flags: dontcopy
+
+; Add the Visual Style resource contains resources used for skinning,
+; you can also use Microsoft Visual Styles (*.msstyles) resources.
+Source: watercolorlite-green.cjstyles; DestDir: {tmp}; Flags: dontcopy
+
+Source: "portable-mode"; DestDir: "{app}"; Tasks: portable
+
+Source: "cert.pem"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "COPYING"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "LICENSE.OPENSSL"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "LICENSE.ZLIB"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "LICENSE.GTK"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "LICENSE.CAIRO"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "LICENSE.LUA"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "LICENSE.ENCHANT"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "LICENSE.LIBXML"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "etc\gtk-2.0\gtkrc"; DestDir: "{app}\etc\gtk-2.0"; Flags: ignoreversion; Components: libs
+;Source: "etc\gtk-2.0\gtkrc"; DestDir: "{app}\etc\gtk-2.0"; Flags: ignoreversion; Components: libs and not gtkengines
+Source: "share\xml\*"; DestDir: "{app}\share\xml"; Flags: ignoreversion createallsubdirs recursesubdirs; Components: libs
+Source: "locale\*"; DestDir: "{app}\locale"; Flags: ignoreversion createallsubdirs recursesubdirs; Components: translations
+Source: "share\locale\*"; DestDir: "{app}\share\locale"; Flags: ignoreversion createallsubdirs recursesubdirs; Components: translations
+;Source: "share\myspell\*"; DestDir: "{app}\share\myspell"; Flags: ignoreversion createallsubdirs recursesubdirs; Components: spelling
+
+Source: "libatk-1.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libcairo-2.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libeay32.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libexpat-1.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+;obs Source: "libffi-5.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "freetype6.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+;obs Source: "libfreetype-6.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libfontconfig-1.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libgdk_pixbuf-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libgdk-win32-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libgio-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libglib-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libgmodule-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libgobject-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libgthread-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libgtk-win32-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "intl.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+;obs Source: "libintl-8.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+;obs Source: "libjasper-1.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+;obs Source: "libjpeg-8.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libpango-1.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libpangocairo-1.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libpangoft2-1.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libpangowin32-1.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+;obs Source: "libpixman-1-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+;obs Source: "libtiff-3.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libpng14-14.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+;obs Source: "libpng15-15.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "lua51.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "ssleay32.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "zlib1.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libxml2.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+;obs Source: "libxml2-2.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "libenchant.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+
+Source: "lib\enchant\libenchant_myspell.dll"; DestDir: "{app}\lib\enchant"; Flags: ignoreversion; Components: libs
+
+Source: "lib\gtk-2.0\2.10.0\engines\libpixmap.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: libs
+Source: "lib\gtk-2.0\2.10.0\engines\libwimp.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: libs
+Source: "lib\gtk-2.0\modules\libgail.dll"; DestDir: "{app}\lib\gtk-2.0\modules"; Flags: ignoreversion; Components: libs
+
+;obs Source: "etc\gtkpref.png"; DestDir: "{app}\etc"; Flags: ignoreversion; Components: gtkengines
+;obs Source: "lib\gtk-2.0\2.10.0\engines\libclearlooks.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
+;obs Source: "lib\gtk-2.0\2.10.0\engines\libcrux-engine.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
+;obs Source: "lib\gtk-2.0\2.10.0\engines\libglide.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
+;obs Source: "lib\gtk-2.0\2.10.0\engines\libhcengine.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
+;obs Source: "lib\gtk-2.0\2.10.0\engines\libindustrial.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
+;obs Source: "lib\gtk-2.0\2.10.0\engines\libmist.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
+;obs Source: "lib\gtk-2.0\2.10.0\engines\libmurrine.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
+;obs Source: "lib\gtk-2.0\2.10.0\engines\libredmond95.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
+;obs Source: "lib\gtk-2.0\2.10.0\engines\libthinice.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
+;obs Source: "plugins\xcgtkpref.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: gtkengines
+;obs Source: "share\themes\*"; DestDir: "{app}\share\themes"; Flags: ignoreversion createallsubdirs recursesubdirs; Components: gtkengines
+;obs Source: "gtk2-prefs.exe"; DestDir: "{app}"; Flags: ignoreversion; Components: gtkengines
+
+Source: "plugins\xcchecksum.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\checksum
+Source: "plugins\xcdns.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\dns
+Source: "plugins\xcdoat.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\doat
+Source: "plugins\xcexec.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\exec
+Source: "plugins\xcfishlim.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\fishlim
+Source: "etc\music.png"; DestDir: "{app}\etc"; Flags: ignoreversion; Components: plugins\winamp or plugins\mpcinfo
+Source: "plugins\xcmpcinfo.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\mpcinfo
+;Source: "plugins\xcnonbmp.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\nonbmp
+Source: "etc\download.png"; DestDir: "{app}\etc"; Flags: ignoreversion; Components: plugins\upd
+Source: "plugins\xcupd.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\upd
+Source: "plugins\xcwinamp.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\winamp
+Source: "etc\system.png"; DestDir: "{app}\etc"; Flags: ignoreversion; Components: plugins\winsys
+Source: "plugins\xcwinsys.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\winsys
+Source: "plugins\xcxsasl.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\xsasl
+Source: "plugins\xtray.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\xtray
+Source: "plugins\xcwmpa.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\wmpa
+
+Source: "plugins\xclua.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: langs\lua
+Source: "plugins\xcpython.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: langs\python
+Source: "plugins\xctcl.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: langs\tcl
+
+Source: "plugins\xcperl-512.dll"; DestDir: "{app}\plugins"; DestName: "xcperl.dll"; Flags: ignoreversion; Components: langs\perl; Tasks: perl512
+Source: "plugins\xcperl-514.dll"; DestDir: "{app}\plugins"; DestName: "xcperl.dll"; Flags: ignoreversion; Components: langs\perl; Tasks: perl514
+Source: "plugins\xcperl-516.dll"; DestDir: "{app}\plugins"; DestName: "xcperl.dll"; Flags: ignoreversion; Components: langs\perl; Tasks: perl516
+
+Source: "xchat.exe"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
+Source: "xchat-text.exe"; DestDir: "{app}"; Flags: ignoreversion; Components: xctext
+
+[Icons]
+Name: "{group}\XChat-WDK (x86)"; Filename: "{app}\xchat.exe"; Tasks: not portable
+Name: "{group}\XChat-Text (x86)"; Filename: "{app}\xchat-text.exe"; Components: xctext; Tasks: not portable
+Name: "{group}\Uninstall XChat-WDK (x86)"; Filename: "{uninstallexe}"; Tasks: not portable
+
+[Messages]
+BeveledLabel= XChat-WDK
+
+[Code]
+/////////////////////////////////////////////////////////////////////
+// these are required for x86->x64 or reverse upgrades
+/////////////////////////////////////////////////////////////////////
+function GetUninstallString(): String;
+var
+	sUnInstPath: String;
+	sUnInstallString: String;
+begin
+	sUnInstPath := ExpandConstant('Software\Microsoft\Windows\CurrentVersion\Uninstall\XChat-WDK (x86)_is1');
+	sUnInstallString := '';
+	if not RegQueryStringValue(HKLM, sUnInstPath, 'UninstallString', sUnInstallString) then
+		RegQueryStringValue(HKCU, sUnInstPath, 'UninstallString', sUnInstallString);
+	Result := sUnInstallString;
+end;
+
+
+/////////////////////////////////////////////////////////////////////
+function IsUpgrade(): Boolean;
+begin
+	Result := (GetUninstallString() <> '');
+end;
+
+
+/////////////////////////////////////////////////////////////////////
+function UnInstallOldVersion(): Integer;
+var
+	sUnInstallString: String;
+	iResultCode: Integer;
+begin
+// Return Values:
+// 1 - uninstall string is empty
+// 2 - error executing the UnInstallString
+// 3 - successfully executed the UnInstallString
+
+	// default return value
+	Result := 0;
+
+	// get the uninstall string of the old app
+	sUnInstallString := GetUninstallString();
+	if sUnInstallString <> '' then begin
+		sUnInstallString := RemoveQuotes(sUnInstallString);
+		if Exec(sUnInstallString, '/SILENT /NORESTART /SUPPRESSMSGBOXES','', SW_HIDE, ewWaitUntilTerminated, iResultCode) then
+			Result := 3
+		else
+			Result := 2;
+	end else
+		Result := 1;
+end;
+
+/////////////////////////////////////////////////////////////////////
+procedure CurStepChanged(CurStep: TSetupStep);
+begin
+	if not (IsTaskSelected('portable')) then
+	begin
+		if (CurStep=ssInstall) then
+		begin
+			if (IsUpgrade()) then
+			begin
+				UnInstallOldVersion();
+			end;
+		end;
+	end;
+end;
+
+/////////////////////////////////////////////////////////////////////
+// Importing LoadSkin API from ISSkin.DLL
+procedure LoadSkin(lpszPath: String; lpszIniFileName: String);
+external 'LoadSkin@files:isskinu.dll stdcall';
+
+// Importing UnloadSkin API from ISSkin.DLL
+procedure UnloadSkin();
+external 'UnloadSkin@files:isskinu.dll stdcall';
+
+// Importing ShowWindow Windows API from User32.DLL
+function ShowWindow(hWnd: Integer; uType: Integer): Integer;
+external 'ShowWindow@user32.dll stdcall';
+
+function InitializeSetup(): Boolean;
+begin
+  ExtractTemporaryFile('watercolorlite-green.cjstyles');
+  LoadSkin(ExpandConstant('{tmp}\watercolorlite-green.cjstyles'), '');
+  Result := True;
+end;
+
+procedure DeinitializeSetup();
+begin
+  // Hide Window before unloading skin so user does not get
+  // a glimpse of an unskinned window before it is closed.
+  ShowWindow(StrToInt(ExpandConstant('{wizardhwnd}')), 0);
+  UnloadSkin();
+end;
diff --git a/win32/isskin/watercolorlite-blue.cjstyles b/win32/isskin/watercolorlite-blue.cjstyles
deleted file mode 100644
index a457029b..00000000
Binary files a/win32/isskin/watercolorlite-blue.cjstyles and /dev/null differ
diff --git a/win32/isskin/watercolorlite-green.cjstyles b/win32/isskin/watercolorlite-green.cjstyles
deleted file mode 100644
index 2b77026d..00000000
Binary files a/win32/isskin/watercolorlite-green.cjstyles and /dev/null differ
diff --git a/win32/nls/nls.vcxproj b/win32/nls/nls.vcxproj
index a9fa71bf..10e53bd8 100644
--- a/win32/nls/nls.vcxproj
+++ b/win32/nls/nls.vcxproj
@@ -26,7 +26,10 @@
     <Import Project="..\xchat.props" />
   </ImportGroup>
   <PropertyGroup Label="UserMacros" />
-  <PropertyGroup />
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level3</WarningLevel>
@@ -45,11 +48,11 @@
     </PostBuildEvent>
     <PreBuildEvent>
       <Command>cd ..\..\po
-rmdir /q /s locale
-mkdir locale
+rmdir /q /s "$(OutDir)\locale"
+mkdir "$(OutDir)\locale"
 for %%A in (*.po) do (
-mkdir locale\%%~nA\LC_MESSAGES
-"$(DepsRoot)\bin\msgfmt" -co locale\%%~nA\LC_MESSAGES\xchat.mo %%A
+mkdir "$(OutDir)\locale\%%~nA\LC_MESSAGES"
+"$(DepsRoot)\bin\msgfmt" -co "$(OutDir)\locale\%%~nA\LC_MESSAGES\xchat.mo" %%A
 )</Command>
     </PreBuildEvent>
   </ItemDefinitionGroup>
diff --git a/win32/share/themes/Murrine/gtk-2.0/gtkrc b/win32/share/themes/Murrine/gtk-2.0/gtkrc
deleted file mode 100644
index b9d95848..00000000
--- a/win32/share/themes/Murrine/gtk-2.0/gtkrc
+++ /dev/null
@@ -1,7 +0,0 @@
-style "default"
-{
-  engine "murrine" 
-  {
-  }
-}
-class "*" style "default"
diff --git a/win32/share/xml/iso-codes/iso_3166.xml b/win32/share/xml/iso-codes/iso_3166.xml
deleted file mode 100644
index 77c72eb2..00000000
--- a/win32/share/xml/iso-codes/iso_3166.xml
+++ /dev/null
@@ -1,1703 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-
-<!--
-This file gives a list of all countries in the ISO 3166
-standard, and is used to provide translations via gettext
-
-Copyright (C) 2002, 2004, 2006 Alastair McKinstry <mckinstry@computer.org>
-Copyright (C) 2004 Andreas Jochens <aj@andaco.de>
-Copyright (C) 2004, 2007 Christian Perrier <bubulle@debian.org>
-Copyright (C) 2005, 2006, 2007 Tobias Quathamer <toddy@debian.org>
-
-    This file is free software; you can redistribute it and/or
-    modify it under the terms of the GNU Lesser General Public
-    License as published by the Free Software Foundation; either
-    version 2.1 of the License, or (at your option) any later version.
-
-    This file is distributed in the hope that it will be useful,
-    but WITHOUT ANY WARRANTY; without even the implied warranty of
-    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-    Lesser General Public License for more details.
-
-    You should have received a copy of the GNU Lesser General Public
-    License along with this file; if not, write to the Free Software
-    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
-
-Source: <http://www.iso.org/iso/country_codes>
--->
-
-<!DOCTYPE iso_3166_entries [
-	<!ELEMENT iso_3166_entries (iso_3166_entry+, iso_3166_3_entry*)>
-	<!ELEMENT iso_3166_entry EMPTY>
-	<!ATTLIST iso_3166_entry
-		alpha_2_code		CDATA	#REQUIRED
-		alpha_3_code		CDATA	#REQUIRED
-		numeric_code		CDATA	#REQUIRED
-		common_name		CDATA	#IMPLIED
-		name			CDATA	#REQUIRED
-		official_name		CDATA	#IMPLIED
-	>
-	<!ELEMENT iso_3166_3_entry EMPTY>
-	<!ATTLIST iso_3166_3_entry
-		alpha_4_code		CDATA	#REQUIRED
-		alpha_3_code		CDATA	#REQUIRED
-		numeric_code		CDATA	#IMPLIED
-		date_withdrawn		CDATA	#IMPLIED
-		names			CDATA	#REQUIRED
-		comment			CDATA	#IMPLIED
-	>
-]>
-
-<iso_3166_entries>
-	<iso_3166_entry
-		alpha_2_code="AF"
-		alpha_3_code="AFG"
-		numeric_code="004"
-		name="Afghanistan"
-		official_name="Islamic Republic of Afghanistan" />
-	<iso_3166_entry
-		alpha_2_code="AX"
-		alpha_3_code="ALA"
-		numeric_code="248"
-		name="Åland Islands" />
-	<iso_3166_entry
-		alpha_2_code="AL"
-		alpha_3_code="ALB"
-		numeric_code="008"
-		name="Albania"
-		official_name="Republic of Albania" />
-	<iso_3166_entry
-		alpha_2_code="DZ"
-		alpha_3_code="DZA"
-		numeric_code="012"
-		name="Algeria"
-		official_name="People's Democratic Republic of Algeria" />
-	<iso_3166_entry
-		alpha_2_code="AS"
-		alpha_3_code="ASM"
-		numeric_code="016"
-		name="American Samoa" />
-	<iso_3166_entry
-		alpha_2_code="AD"
-		alpha_3_code="AND"
-		numeric_code="020"
-		name="Andorra"
-		official_name="Principality of Andorra" />
-	<iso_3166_entry
-		alpha_2_code="AO"
-		alpha_3_code="AGO"
-		numeric_code="024"
-		name="Angola"
-		official_name="Republic of Angola" />
-	<iso_3166_entry
-		alpha_2_code="AI"
-		alpha_3_code="AIA"
-		numeric_code="660"
-		name="Anguilla" />
-	<iso_3166_entry
-		alpha_2_code="AQ"
-		alpha_3_code="ATA"
-		numeric_code="010"
-		name="Antarctica" />
-	<iso_3166_entry
-		alpha_2_code="AG"
-		alpha_3_code="ATG"
-		numeric_code="028"
-		name="Antigua and Barbuda" />
-	<iso_3166_entry
-		alpha_2_code="AR"
-		alpha_3_code="ARG"
-		numeric_code="032"
-		name="Argentina"
-		official_name="Argentine Republic" />
-	<iso_3166_entry
-		alpha_2_code="AM"
-		alpha_3_code="ARM"
-		numeric_code="051"
-		name="Armenia"
-		official_name="Republic of Armenia" />
-	<iso_3166_entry
-		alpha_2_code="AW"
-		alpha_3_code="ABW"
-		numeric_code="533"
-		name="Aruba" />
-	<iso_3166_entry
-		alpha_2_code="AU"
-		alpha_3_code="AUS"
-		numeric_code="036"
-		name="Australia" />
-	<iso_3166_entry
-		alpha_2_code="AT"
-		alpha_3_code="AUT"
-		numeric_code="040"
-		name="Austria"
-		official_name="Republic of Austria" />
-	<iso_3166_entry
-		alpha_2_code="AZ"
-		alpha_3_code="AZE"
-		numeric_code="031"
-		name="Azerbaijan"
-		official_name="Republic of Azerbaijan" />
-	<iso_3166_entry
-		alpha_2_code="BS"
-		alpha_3_code="BHS"
-		numeric_code="044"
-		name="Bahamas"
-		official_name="Commonwealth of the Bahamas" />
-	<iso_3166_entry
-		alpha_2_code="BH"
-		alpha_3_code="BHR"
-		numeric_code="048"
-		name="Bahrain"
-		official_name="Kingdom of Bahrain" />
-	<iso_3166_entry
-		alpha_2_code="BD"
-		alpha_3_code="BGD"
-		numeric_code="050"
-		name="Bangladesh"
-		official_name="People's Republic of Bangladesh" />
-	<iso_3166_entry
-		alpha_2_code="BB"
-		alpha_3_code="BRB"
-		numeric_code="052"
-		name="Barbados" />
-	<iso_3166_entry
-		alpha_2_code="BY"
-		alpha_3_code="BLR"
-		numeric_code="112"
-		name="Belarus"
-		official_name="Republic of Belarus" />
-	<iso_3166_entry
-		alpha_2_code="BE"
-		alpha_3_code="BEL"
-		numeric_code="056"
-		name="Belgium"
-		official_name="Kingdom of Belgium" />
-	<iso_3166_entry
-		alpha_2_code="BZ"
-		alpha_3_code="BLZ"
-		numeric_code="084"
-		name="Belize" />
-	<iso_3166_entry
-		alpha_2_code="BJ"
-		alpha_3_code="BEN"
-		numeric_code="204"
-		name="Benin"
-		official_name="Republic of Benin" />
-	<iso_3166_entry
-		alpha_2_code="BM"
-		alpha_3_code="BMU"
-		numeric_code="060"
-		name="Bermuda" />
-	<iso_3166_entry
-		alpha_2_code="BT"
-		alpha_3_code="BTN"
-		numeric_code="064"
-		name="Bhutan"
-		official_name="Kingdom of Bhutan" />
-	<iso_3166_entry
-		alpha_2_code="BO"
-		alpha_3_code="BOL"
-		numeric_code="068"
-		common_name="Bolivia"
-		name="Bolivia, Plurinational State of"
-		official_name="Plurinational State of Bolivia" />
-	<iso_3166_entry
-		alpha_2_code="BQ"
-		alpha_3_code="BES"
-		numeric_code="535"
-		name="Bonaire, Sint Eustatius and Saba"
-		official_name="Bonaire, Sint Eustatius and Saba" />
-	<iso_3166_entry
-		alpha_2_code="BA"
-		alpha_3_code="BIH"
-		numeric_code="070"
-		name="Bosnia and Herzegovina"
-		official_name="Republic of Bosnia and Herzegovina" />
-	<iso_3166_entry
-		alpha_2_code="BW"
-		alpha_3_code="BWA"
-		numeric_code="072"
-		name="Botswana"
-		official_name="Republic of Botswana" />
-	<iso_3166_entry
-		alpha_2_code="BV"
-		alpha_3_code="BVT"
-		numeric_code="074"
-		name="Bouvet Island" />
-	<iso_3166_entry
-		alpha_2_code="BR"
-		alpha_3_code="BRA"
-		numeric_code="076"
-		name="Brazil"
-		official_name="Federative Republic of Brazil" />
-	<iso_3166_entry
-		alpha_2_code="IO"
-		alpha_3_code="IOT"
-		numeric_code="086"
-		name="British Indian Ocean Territory" />
-	<iso_3166_entry
-		alpha_2_code="BN"
-		alpha_3_code="BRN"
-		numeric_code="096"
-		name="Brunei Darussalam" />
-	<iso_3166_entry
-		alpha_2_code="BG"
-		alpha_3_code="BGR"
-		numeric_code="100"
-		name="Bulgaria"
-		official_name="Republic of Bulgaria" />
-	<iso_3166_entry
-		alpha_2_code="BF"
-		alpha_3_code="BFA"
-		numeric_code="854"
-		name="Burkina Faso" />
-	<iso_3166_entry
-		alpha_2_code="BI"
-		alpha_3_code="BDI"
-		numeric_code="108"
-		name="Burundi"
-		official_name="Republic of Burundi" />
-	<iso_3166_entry
-		alpha_2_code="KH"
-		alpha_3_code="KHM"
-		numeric_code="116"
-		name="Cambodia"
-		official_name="Kingdom of Cambodia" />
-	<iso_3166_entry
-		alpha_2_code="CM"
-		alpha_3_code="CMR"
-		numeric_code="120"
-		name="Cameroon"
-		official_name="Republic of Cameroon" />
-	<iso_3166_entry
-		alpha_2_code="CA"
-		alpha_3_code="CAN"
-		numeric_code="124"
-		name="Canada" />
-	<iso_3166_entry
-		alpha_2_code="CV"
-		alpha_3_code="CPV"
-		numeric_code="132"
-		name="Cape Verde"
-		official_name="Republic of Cape Verde" />
-	<iso_3166_entry
-		alpha_2_code="KY"
-		alpha_3_code="CYM"
-		numeric_code="136"
-		name="Cayman Islands" />
-	<iso_3166_entry
-		alpha_2_code="CF"
-		alpha_3_code="CAF"
-		numeric_code="140"
-		name="Central African Republic" />
-	<iso_3166_entry
-		alpha_2_code="TD"
-		alpha_3_code="TCD"
-		numeric_code="148"
-		name="Chad"
-		official_name="Republic of Chad" />
-	<iso_3166_entry
-		alpha_2_code="CL"
-		alpha_3_code="CHL"
-		numeric_code="152"
-		name="Chile"
-		official_name="Republic of Chile" />
-	<iso_3166_entry
-		alpha_2_code="CN"
-		alpha_3_code="CHN"
-		numeric_code="156"
-		name="China"
-		official_name="People's Republic of China" />
-	<iso_3166_entry
-		alpha_2_code="CX"
-		alpha_3_code="CXR"
-		numeric_code="162"
-		name="Christmas Island" />
-	<iso_3166_entry
-		alpha_2_code="CC"
-		alpha_3_code="CCK"
-		numeric_code="166"
-		name="Cocos (Keeling) Islands" />
-	<iso_3166_entry
-		alpha_2_code="CO"
-		alpha_3_code="COL"
-		numeric_code="170"
-		name="Colombia"
-		official_name="Republic of Colombia" />
-	<iso_3166_entry
-		alpha_2_code="KM"
-		alpha_3_code="COM"
-		numeric_code="174"
-		name="Comoros"
-		official_name="Union of the Comoros" />
-	<iso_3166_entry
-		alpha_2_code="CG"
-		alpha_3_code="COG"
-		numeric_code="178"
-		name="Congo"
-		official_name="Republic of the Congo" />
-	<iso_3166_entry
-		alpha_2_code="CD"
-		alpha_3_code="COD"
-		numeric_code="180"
-		name="Congo, The Democratic Republic of the" />
-	<iso_3166_entry
-		alpha_2_code="CK"
-		alpha_3_code="COK"
-		numeric_code="184"
-		name="Cook Islands" />
-	<iso_3166_entry
-		alpha_2_code="CR"
-		alpha_3_code="CRI"
-		numeric_code="188"
-		name="Costa Rica"
-		official_name="Republic of Costa Rica" />
-	<iso_3166_entry
-		alpha_2_code="CI"
-		alpha_3_code="CIV"
-		numeric_code="384"
-		name="Côte d'Ivoire"
-		official_name="Republic of Côte d'Ivoire" />
-	<iso_3166_entry
-		alpha_2_code="HR"
-		alpha_3_code="HRV"
-		numeric_code="191"
-		name="Croatia"
-		official_name="Republic of Croatia" />
-	<iso_3166_entry
-		alpha_2_code="CU"
-		alpha_3_code="CUB"
-		numeric_code="192"
-		name="Cuba"
-		official_name="Republic of Cuba" />
-	<iso_3166_entry
-		alpha_2_code="CW"
-		alpha_3_code="CUW"
-		numeric_code="531"
-		name="Curaçao"
-		official_name="Curaçao" />
-	<iso_3166_entry
-		alpha_2_code="CY"
-		alpha_3_code="CYP"
-		numeric_code="196"
-		name="Cyprus"
-		official_name="Republic of Cyprus" />
-	<iso_3166_entry
-		alpha_2_code="CZ"
-		alpha_3_code="CZE"
-		numeric_code="203"
-		name="Czech Republic" />
-	<iso_3166_entry
-		alpha_2_code="DK"
-		alpha_3_code="DNK"
-		numeric_code="208"
-		name="Denmark"
-		official_name="Kingdom of Denmark" />
-	<iso_3166_entry
-		alpha_2_code="DJ"
-		alpha_3_code="DJI"
-		numeric_code="262"
-		name="Djibouti"
-		official_name="Republic of Djibouti" />
-	<iso_3166_entry
-		alpha_2_code="DM"
-		alpha_3_code="DMA"
-		numeric_code="212"
-		name="Dominica"
-		official_name="Commonwealth of Dominica" />
-	<iso_3166_entry
-		alpha_2_code="DO"
-		alpha_3_code="DOM"
-		numeric_code="214"
-		name="Dominican Republic" />
-	<iso_3166_entry
-		alpha_2_code="EC"
-		alpha_3_code="ECU"
-		numeric_code="218"
-		name="Ecuador"
-		official_name="Republic of Ecuador" />
-	<iso_3166_entry
-		alpha_2_code="EG"
-		alpha_3_code="EGY"
-		numeric_code="818"
-		name="Egypt"
-		official_name="Arab Republic of Egypt" />
-	<iso_3166_entry
-		alpha_2_code="SV"
-		alpha_3_code="SLV"
-		numeric_code="222"
-		name="El Salvador"
-		official_name="Republic of El Salvador" />
-	<iso_3166_entry
-		alpha_2_code="GQ"
-		alpha_3_code="GNQ"
-		numeric_code="226"
-		name="Equatorial Guinea"
-		official_name="Republic of Equatorial Guinea" />
-	<iso_3166_entry
-		alpha_2_code="ER"
-		alpha_3_code="ERI"
-		numeric_code="232"
-		name="Eritrea" />
-	<iso_3166_entry
-		alpha_2_code="EE"
-		alpha_3_code="EST"
-		numeric_code="233"
-		name="Estonia"
-		official_name="Republic of Estonia" />
-	<iso_3166_entry
-		alpha_2_code="ET"
-		alpha_3_code="ETH"
-		numeric_code="231"
-		name="Ethiopia"
-		official_name="Federal Democratic Republic of Ethiopia" />
-	<iso_3166_entry
-		alpha_2_code="FK"
-		alpha_3_code="FLK"
-		numeric_code="238"
-		name="Falkland Islands (Malvinas)" />
-	<iso_3166_entry
-		alpha_2_code="FO"
-		alpha_3_code="FRO"
-		numeric_code="234"
-		name="Faroe Islands" />
-	<iso_3166_entry
-		alpha_2_code="FJ"
-		alpha_3_code="FJI"
-		numeric_code="242"
-		name="Fiji"
-		official_name="Republic of Fiji" />
-	<iso_3166_entry
-		alpha_2_code="FI"
-		alpha_3_code="FIN"
-		numeric_code="246"
-		name="Finland"
-		official_name="Republic of Finland" />
-	<iso_3166_entry
-		alpha_2_code="FR"
-		alpha_3_code="FRA"
-		numeric_code="250"
-		name="France"
-		official_name="French Republic" />
-	<iso_3166_entry
-		alpha_2_code="GF"
-		alpha_3_code="GUF"
-		numeric_code="254"
-		name="French Guiana" />
-	<iso_3166_entry
-		alpha_2_code="PF"
-		alpha_3_code="PYF"
-		numeric_code="258"
-		name="French Polynesia" />
-	<iso_3166_entry
-		alpha_2_code="TF"
-		alpha_3_code="ATF"
-		numeric_code="260"
-		name="French Southern Territories" />
-	<iso_3166_entry
-		alpha_2_code="GA"
-		alpha_3_code="GAB"
-		numeric_code="266"
-		name="Gabon"
-		official_name="Gabonese Republic" />
-	<iso_3166_entry
-		alpha_2_code="GM"
-		alpha_3_code="GMB"
-		numeric_code="270"
-		name="Gambia"
-		official_name="Republic of the Gambia" />
-	<iso_3166_entry
-		alpha_2_code="GE"
-		alpha_3_code="GEO"
-		numeric_code="268"
-		name="Georgia" />
-	<iso_3166_entry
-		alpha_2_code="DE"
-		alpha_3_code="DEU"
-		numeric_code="276"
-		name="Germany"
-		official_name="Federal Republic of Germany" />
-	<iso_3166_entry
-		alpha_2_code="GH"
-		alpha_3_code="GHA"
-		numeric_code="288"
-		name="Ghana"
-		official_name="Republic of Ghana" />
-	<iso_3166_entry
-		alpha_2_code="GI"
-		alpha_3_code="GIB"
-		numeric_code="292"
-		name="Gibraltar" />
-	<iso_3166_entry
-		alpha_2_code="GR"
-		alpha_3_code="GRC"
-		numeric_code="300"
-		name="Greece"
-		official_name="Hellenic Republic" />
-	<iso_3166_entry
-		alpha_2_code="GL"
-		alpha_3_code="GRL"
-		numeric_code="304"
-		name="Greenland" />
-	<iso_3166_entry
-		alpha_2_code="GD"
-		alpha_3_code="GRD"
-		numeric_code="308"
-		name="Grenada" />
-	<iso_3166_entry
-		alpha_2_code="GP"
-		alpha_3_code="GLP"
-		numeric_code="312"
-		name="Guadeloupe" />
-	<iso_3166_entry
-		alpha_2_code="GU"
-		alpha_3_code="GUM"
-		numeric_code="316"
-		name="Guam" />
-	<iso_3166_entry
-		alpha_2_code="GT"
-		alpha_3_code="GTM"
-		numeric_code="320"
-		name="Guatemala"
-		official_name="Republic of Guatemala" />
-	<iso_3166_entry
-		alpha_2_code="GG"
-		alpha_3_code="GGY"
-		numeric_code="831"
-		name="Guernsey" />
-	<iso_3166_entry
-		alpha_2_code="GN"
-		alpha_3_code="GIN"
-		numeric_code="324"
-		name="Guinea"
-		official_name="Republic of Guinea" />
-	<iso_3166_entry
-		alpha_2_code="GW"
-		alpha_3_code="GNB"
-		numeric_code="624"
-		name="Guinea-Bissau"
-		official_name="Republic of Guinea-Bissau" />
-	<iso_3166_entry
-		alpha_2_code="GY"
-		alpha_3_code="GUY"
-		numeric_code="328"
-		name="Guyana"
-		official_name="Republic of Guyana" />
-	<iso_3166_entry
-		alpha_2_code="HT"
-		alpha_3_code="HTI"
-		numeric_code="332"
-		name="Haiti"
-		official_name="Republic of Haiti" />
-	<iso_3166_entry
-		alpha_2_code="HM"
-		alpha_3_code="HMD"
-		numeric_code="334"
-		name="Heard Island and McDonald Islands" />
-	<iso_3166_entry
-		alpha_2_code="VA"
-		alpha_3_code="VAT"
-		numeric_code="336"
-		name="Holy See (Vatican City State)" />
-	<iso_3166_entry
-		alpha_2_code="HN"
-		alpha_3_code="HND"
-		numeric_code="340"
-		name="Honduras"
-		official_name="Republic of Honduras" />
-	<iso_3166_entry
-		alpha_2_code="HK"
-		alpha_3_code="HKG"
-		numeric_code="344"
-		name="Hong Kong"
-		official_name="Hong Kong Special Administrative Region of China" />
-	<iso_3166_entry
-		alpha_2_code="HU"
-		alpha_3_code="HUN"
-		numeric_code="348"
-		name="Hungary"
-		official_name="Republic of Hungary" />
-	<iso_3166_entry
-		alpha_2_code="IS"
-		alpha_3_code="ISL"
-		numeric_code="352"
-		name="Iceland"
-		official_name="Republic of Iceland" />
-	<iso_3166_entry
-		alpha_2_code="IN"
-		alpha_3_code="IND"
-		numeric_code="356"
-		name="India"
-		official_name="Republic of India" />
-	<iso_3166_entry
-		alpha_2_code="ID"
-		alpha_3_code="IDN"
-		numeric_code="360"
-		name="Indonesia"
-		official_name="Republic of Indonesia" />
-	<iso_3166_entry
-		alpha_2_code="IR"
-		alpha_3_code="IRN"
-		numeric_code="364"
-		name="Iran, Islamic Republic of"
-		official_name="Islamic Republic of Iran" />
-	<iso_3166_entry
-		alpha_2_code="IQ"
-		alpha_3_code="IRQ"
-		numeric_code="368"
-		name="Iraq"
-		official_name="Republic of Iraq" />
-	<iso_3166_entry
-		alpha_2_code="IE"
-		alpha_3_code="IRL"
-		numeric_code="372"
-		name="Ireland" />
-	<iso_3166_entry
-		alpha_2_code="IM"
-		alpha_3_code="IMN"
-		numeric_code="833"
-		name="Isle of Man" />
-	<iso_3166_entry
-		alpha_2_code="IL"
-		alpha_3_code="ISR"
-		numeric_code="376"
-		name="Israel"
-		official_name="State of Israel" />
-	<iso_3166_entry
-		alpha_2_code="IT"
-		alpha_3_code="ITA"
-		numeric_code="380"
-		name="Italy"
-		official_name="Italian Republic" />
-	<iso_3166_entry
-		alpha_2_code="JM"
-		alpha_3_code="JAM"
-		numeric_code="388"
-		name="Jamaica" />
-	<iso_3166_entry
-		alpha_2_code="JP"
-		alpha_3_code="JPN"
-		numeric_code="392"
-		name="Japan" />
-	<iso_3166_entry
-		alpha_2_code="JE"
-		alpha_3_code="JEY"
-		numeric_code="832"
-		name="Jersey" />
-	<iso_3166_entry
-		alpha_2_code="JO"
-		alpha_3_code="JOR"
-		numeric_code="400"
-		name="Jordan"
-		official_name="Hashemite Kingdom of Jordan" />
-	<iso_3166_entry
-		alpha_2_code="KZ"
-		alpha_3_code="KAZ"
-		numeric_code="398"
-		name="Kazakhstan"
-		official_name="Republic of Kazakhstan" />
-	<iso_3166_entry
-		alpha_2_code="KE"
-		alpha_3_code="KEN"
-		numeric_code="404"
-		name="Kenya"
-		official_name="Republic of Kenya" />
-	<iso_3166_entry
-		alpha_2_code="KI"
-		alpha_3_code="KIR"
-		numeric_code="296"
-		name="Kiribati"
-		official_name="Republic of Kiribati" />
-	<iso_3166_entry
-		alpha_2_code="KP"
-		alpha_3_code="PRK"
-		numeric_code="408"
-		name="Korea, Democratic People's Republic of"
-		official_name="Democratic People's Republic of Korea" />
-	<iso_3166_entry
-		alpha_2_code="KR"
-		alpha_3_code="KOR"
-		numeric_code="410"
-		name="Korea, Republic of" />
-	<iso_3166_entry
-		alpha_2_code="KW"
-		alpha_3_code="KWT"
-		numeric_code="414"
-		name="Kuwait"
-		official_name="State of Kuwait" />
-	<iso_3166_entry
-		alpha_2_code="KG"
-		alpha_3_code="KGZ"
-		numeric_code="417"
-		name="Kyrgyzstan"
-		official_name="Kyrgyz Republic" />
-	<iso_3166_entry
-		alpha_2_code="LA"
-		alpha_3_code="LAO"
-		numeric_code="418"
-		name="Lao People's Democratic Republic" />
-	<iso_3166_entry
-		alpha_2_code="LV"
-		alpha_3_code="LVA"
-		numeric_code="428"
-		name="Latvia"
-		official_name="Republic of Latvia" />
-	<iso_3166_entry
-		alpha_2_code="LB"
-		alpha_3_code="LBN"
-		numeric_code="422"
-		name="Lebanon"
-		official_name="Lebanese Republic" />
-	<iso_3166_entry
-		alpha_2_code="LS"
-		alpha_3_code="LSO"
-		numeric_code="426"
-		name="Lesotho"
-		official_name="Kingdom of Lesotho" />
-	<iso_3166_entry
-		alpha_2_code="LR"
-		alpha_3_code="LBR"
-		numeric_code="430"
-		name="Liberia"
-		official_name="Republic of Liberia" />
-	<iso_3166_entry
-		alpha_2_code="LY"
-		alpha_3_code="LBY"
-		numeric_code="434"
-		common_name="Libya"
-		name="Libyan Arab Jamahiriya"
-		official_name="Socialist People's Libyan Arab Jamahiriya" />
-	<iso_3166_entry
-		alpha_2_code="LI"
-		alpha_3_code="LIE"
-		numeric_code="438"
-		name="Liechtenstein"
-		official_name="Principality of Liechtenstein" />
-	<iso_3166_entry
-		alpha_2_code="LT"
-		alpha_3_code="LTU"
-		numeric_code="440"
-		name="Lithuania"
-		official_name="Republic of Lithuania" />
-	<iso_3166_entry
-		alpha_2_code="LU"
-		alpha_3_code="LUX"
-		numeric_code="442"
-		name="Luxembourg"
-		official_name="Grand Duchy of Luxembourg" />
-	<iso_3166_entry
-		alpha_2_code="MO"
-		alpha_3_code="MAC"
-		numeric_code="446"
-		name="Macao"
-		official_name="Macao Special Administrative Region of China" />
-	<iso_3166_entry
-		alpha_2_code="MK"
-		alpha_3_code="MKD"
-		numeric_code="807"
-		name="Macedonia, Republic of"
-		official_name="The Former Yugoslav Republic of Macedonia" />
-	<iso_3166_entry
-		alpha_2_code="MG"
-		alpha_3_code="MDG"
-		numeric_code="450"
-		name="Madagascar"
-		official_name="Republic of Madagascar" />
-	<iso_3166_entry
-		alpha_2_code="MW"
-		alpha_3_code="MWI"
-		numeric_code="454"
-		name="Malawi"
-		official_name="Republic of Malawi" />
-	<iso_3166_entry
-		alpha_2_code="MY"
-		alpha_3_code="MYS"
-		numeric_code="458"
-		name="Malaysia" />
-	<iso_3166_entry
-		alpha_2_code="MV"
-		alpha_3_code="MDV"
-		numeric_code="462"
-		name="Maldives"
-		official_name="Republic of Maldives" />
-	<iso_3166_entry
-		alpha_2_code="ML"
-		alpha_3_code="MLI"
-		numeric_code="466"
-		name="Mali"
-		official_name="Republic of Mali" />
-	<iso_3166_entry
-		alpha_2_code="MT"
-		alpha_3_code="MLT"
-		numeric_code="470"
-		name="Malta"
-		official_name="Republic of Malta" />
-	<iso_3166_entry
-		alpha_2_code="MH"
-		alpha_3_code="MHL"
-		numeric_code="584"
-		name="Marshall Islands"
-		official_name="Republic of the Marshall Islands" />
-	<iso_3166_entry
-		alpha_2_code="MQ"
-		alpha_3_code="MTQ"
-		numeric_code="474"
-		name="Martinique" />
-	<iso_3166_entry
-		alpha_2_code="MR"
-		alpha_3_code="MRT"
-		numeric_code="478"
-		name="Mauritania"
-		official_name="Islamic Republic of Mauritania" />
-	<iso_3166_entry
-		alpha_2_code="MU"
-		alpha_3_code="MUS"
-		numeric_code="480"
-		name="Mauritius"
-		official_name="Republic of Mauritius" />
-	<iso_3166_entry
-		alpha_2_code="YT"
-		alpha_3_code="MYT"
-		numeric_code="175"
-		name="Mayotte" />
-	<iso_3166_entry
-		alpha_2_code="MX"
-		alpha_3_code="MEX"
-		numeric_code="484"
-		name="Mexico"
-		official_name="United Mexican States" />
-	<iso_3166_entry
-		alpha_2_code="FM"
-		alpha_3_code="FSM"
-		numeric_code="583"
-		name="Micronesia, Federated States of"
-		official_name="Federated States of Micronesia" />
-	<iso_3166_entry
-		alpha_2_code="MD"
-		alpha_3_code="MDA"
-		numeric_code="498"
-		common_name="Moldova"
-		name="Moldova, Republic of"
-		official_name="Republic of Moldova" />
-	<iso_3166_entry
-		alpha_2_code="MC"
-		alpha_3_code="MCO"
-		numeric_code="492"
-		name="Monaco"
-		official_name="Principality of Monaco" />
-	<iso_3166_entry
-		alpha_2_code="MN"
-		alpha_3_code="MNG"
-		numeric_code="496"
-		name="Mongolia" />
-	<iso_3166_entry
-		alpha_2_code="ME"
-		alpha_3_code="MNE"
-		numeric_code="499"
-		name="Montenegro"
-		official_name="Montenegro" />
-	<iso_3166_entry
-		alpha_2_code="MS"
-		alpha_3_code="MSR"
-		numeric_code="500"
-		name="Montserrat" />
-	<iso_3166_entry
-		alpha_2_code="MA"
-		alpha_3_code="MAR"
-		numeric_code="504"
-		name="Morocco"
-		official_name="Kingdom of Morocco" />
-	<iso_3166_entry
-		alpha_2_code="MZ"
-		alpha_3_code="MOZ"
-		numeric_code="508"
-		name="Mozambique"
-		official_name="Republic of Mozambique" />
-	<iso_3166_entry
-		alpha_2_code="MM"
-		alpha_3_code="MMR"
-		numeric_code="104"
-		name="Myanmar"
-		official_name="Republic of Myanmar" />
-	<iso_3166_entry
-		alpha_2_code="NA"
-		alpha_3_code="NAM"
-		numeric_code="516"
-		name="Namibia"
-		official_name="Republic of Namibia" />
-	<iso_3166_entry
-		alpha_2_code="NR"
-		alpha_3_code="NRU"
-		numeric_code="520"
-		name="Nauru"
-		official_name="Republic of Nauru" />
-	<iso_3166_entry
-		alpha_2_code="NP"
-		alpha_3_code="NPL"
-		numeric_code="524"
-		name="Nepal"
-		official_name="Federal Democratic Republic of Nepal" />
-	<iso_3166_entry
-		alpha_2_code="NL"
-		alpha_3_code="NLD"
-		numeric_code="528"
-		name="Netherlands"
-		official_name="Kingdom of the Netherlands" />
-	<iso_3166_entry
-		alpha_2_code="NC"
-		alpha_3_code="NCL"
-		numeric_code="540"
-		name="New Caledonia" />
-	<iso_3166_entry
-		alpha_2_code="NZ"
-		alpha_3_code="NZL"
-		numeric_code="554"
-		name="New Zealand" />
-	<iso_3166_entry
-		alpha_2_code="NI"
-		alpha_3_code="NIC"
-		numeric_code="558"
-		name="Nicaragua"
-		official_name="Republic of Nicaragua" />
-	<iso_3166_entry
-		alpha_2_code="NE"
-		alpha_3_code="NER"
-		numeric_code="562"
-		name="Niger"
-		official_name="Republic of the Niger" />
-	<iso_3166_entry
-		alpha_2_code="NG"
-		alpha_3_code="NGA"
-		numeric_code="566"
-		name="Nigeria"
-		official_name="Federal Republic of Nigeria" />
-	<iso_3166_entry
-		alpha_2_code="NU"
-		alpha_3_code="NIU"
-		numeric_code="570"
-		name="Niue"
-		official_name="Niue" />
-	<iso_3166_entry
-		alpha_2_code="NF"
-		alpha_3_code="NFK"
-		numeric_code="574"
-		name="Norfolk Island" />
-	<iso_3166_entry
-		alpha_2_code="MP"
-		alpha_3_code="MNP"
-		numeric_code="580"
-		name="Northern Mariana Islands"
-		official_name="Commonwealth of the Northern Mariana Islands" />
-	<iso_3166_entry
-		alpha_2_code="NO"
-		alpha_3_code="NOR"
-		numeric_code="578"
-		name="Norway"
-		official_name="Kingdom of Norway" />
-	<iso_3166_entry
-		alpha_2_code="OM"
-		alpha_3_code="OMN"
-		numeric_code="512"
-		name="Oman"
-		official_name="Sultanate of Oman" />
-	<iso_3166_entry
-		alpha_2_code="PK"
-		alpha_3_code="PAK"
-		numeric_code="586"
-		name="Pakistan"
-		official_name="Islamic Republic of Pakistan" />
-	<iso_3166_entry
-		alpha_2_code="PW"
-		alpha_3_code="PLW"
-		numeric_code="585"
-		name="Palau"
-		official_name="Republic of Palau" />
-	<iso_3166_entry
-		alpha_2_code="PS"
-		alpha_3_code="PSE"
-		numeric_code="275"
-		name="Palestinian Territory, Occupied"
-		official_name="Occupied Palestinian Territory" />
-	<iso_3166_entry
-		alpha_2_code="PA"
-		alpha_3_code="PAN"
-		numeric_code="591"
-		name="Panama"
-		official_name="Republic of Panama" />
-	<iso_3166_entry
-		alpha_2_code="PG"
-		alpha_3_code="PNG"
-		numeric_code="598"
-		name="Papua New Guinea" />
-	<iso_3166_entry
-		alpha_2_code="PY"
-		alpha_3_code="PRY"
-		numeric_code="600"
-		name="Paraguay"
-		official_name="Republic of Paraguay" />
-	<iso_3166_entry
-		alpha_2_code="PE"
-		alpha_3_code="PER"
-		numeric_code="604"
-		name="Peru"
-		official_name="Republic of Peru" />
-	<iso_3166_entry
-		alpha_2_code="PH"
-		alpha_3_code="PHL"
-		numeric_code="608"
-		name="Philippines"
-		official_name="Republic of the Philippines" />
-	<iso_3166_entry
-		alpha_2_code="PN"
-		alpha_3_code="PCN"
-		numeric_code="612"
-		name="Pitcairn" />
-	<iso_3166_entry
-		alpha_2_code="PL"
-		alpha_3_code="POL"
-		numeric_code="616"
-		name="Poland"
-		official_name="Republic of Poland" />
-	<iso_3166_entry
-		alpha_2_code="PT"
-		alpha_3_code="PRT"
-		numeric_code="620"
-		name="Portugal"
-		official_name="Portuguese Republic" />
-	<iso_3166_entry
-		alpha_2_code="PR"
-		alpha_3_code="PRI"
-		numeric_code="630"
-		name="Puerto Rico" />
-	<iso_3166_entry
-		alpha_2_code="QA"
-		alpha_3_code="QAT"
-		numeric_code="634"
-		name="Qatar"
-		official_name="State of Qatar" />
-	<iso_3166_entry
-		alpha_2_code="RE"
-		alpha_3_code="REU"
-		numeric_code="638"
-		name="Reunion" />
-	<iso_3166_entry
-		alpha_2_code="RO"
-		alpha_3_code="ROU"
-		numeric_code="642"
-		name="Romania" />
-	<iso_3166_entry
-		alpha_2_code="RU"
-		alpha_3_code="RUS"
-		numeric_code="643"
-		name="Russian Federation" />
-	<iso_3166_entry
-		alpha_2_code="RW"
-		alpha_3_code="RWA"
-		numeric_code="646"
-		name="Rwanda"
-		official_name="Rwandese Republic" />
-	<iso_3166_entry
-		alpha_2_code="BL"
-		alpha_3_code="BLM"
-		numeric_code="652"
-		name="Saint Barthélemy" />
-	<iso_3166_entry
-		alpha_2_code="SH"
-		alpha_3_code="SHN"
-		numeric_code="654"
-		name="Saint Helena, Ascension and Tristan da Cunha" />
-	<iso_3166_entry
-		alpha_2_code="KN"
-		alpha_3_code="KNA"
-		numeric_code="659"
-		name="Saint Kitts and Nevis" />
-	<iso_3166_entry
-		alpha_2_code="LC"
-		alpha_3_code="LCA"
-		numeric_code="662"
-		name="Saint Lucia" />
-	<iso_3166_entry
-		alpha_2_code="MF"
-		alpha_3_code="MAF"
-		numeric_code="663"
-		name="Saint Martin (French part)" />
-	<iso_3166_entry
-		alpha_2_code="PM"
-		alpha_3_code="SPM"
-		numeric_code="666"
-		name="Saint Pierre and Miquelon" />
-	<iso_3166_entry
-		alpha_2_code="VC"
-		alpha_3_code="VCT"
-		numeric_code="670"
-		name="Saint Vincent and the Grenadines" />
-	<iso_3166_entry
-		alpha_2_code="WS"
-		alpha_3_code="WSM"
-		numeric_code="882"
-		name="Samoa"
-		official_name="Independent State of Samoa" />
-	<iso_3166_entry
-		alpha_2_code="SM"
-		alpha_3_code="SMR"
-		numeric_code="674"
-		name="San Marino"
-		official_name="Republic of San Marino" />
-	<iso_3166_entry
-		alpha_2_code="ST"
-		alpha_3_code="STP"
-		numeric_code="678"
-		name="Sao Tome and Principe"
-		official_name="Democratic Republic of Sao Tome and Principe" />
-	<iso_3166_entry
-		alpha_2_code="SA"
-		alpha_3_code="SAU"
-		numeric_code="682"
-		name="Saudi Arabia"
-		official_name="Kingdom of Saudi Arabia" />
-	<iso_3166_entry
-		alpha_2_code="SN"
-		alpha_3_code="SEN"
-		numeric_code="686"
-		name="Senegal"
-		official_name="Republic of Senegal" />
-	<iso_3166_entry
-		alpha_2_code="RS"
-		alpha_3_code="SRB"
-		numeric_code="688"
-		name="Serbia"
-		official_name="Republic of Serbia" />
-	<iso_3166_entry
-		alpha_2_code="SC"
-		alpha_3_code="SYC"
-		numeric_code="690"
-		name="Seychelles"
-		official_name="Republic of Seychelles" />
-	<iso_3166_entry
-		alpha_2_code="SL"
-		alpha_3_code="SLE"
-		numeric_code="694"
-		name="Sierra Leone"
-		official_name="Republic of Sierra Leone" />
-	<iso_3166_entry
-		alpha_2_code="SG"
-		alpha_3_code="SGP"
-		numeric_code="702"
-		name="Singapore"
-		official_name="Republic of Singapore" />
-	<iso_3166_entry
-		alpha_2_code="SX"
-		alpha_3_code="SXM"
-		numeric_code="702"
-		name="Sint Maarten"
-		official_name="Sint Maarten (Dutch part)" />
-	<iso_3166_entry
-		alpha_2_code="SK"
-		alpha_3_code="SVK"
-		numeric_code="703"
-		name="Slovakia"
-		official_name="Slovak Republic" />
-	<iso_3166_entry
-		alpha_2_code="SI"
-		alpha_3_code="SVN"
-		numeric_code="705"
-		name="Slovenia"
-		official_name="Republic of Slovenia" />
-	<iso_3166_entry
-		alpha_2_code="SB"
-		alpha_3_code="SLB"
-		numeric_code="090"
-		name="Solomon Islands" />
-	<iso_3166_entry
-		alpha_2_code="SO"
-		alpha_3_code="SOM"
-		numeric_code="706"
-		name="Somalia"
-		official_name="Somali Republic" />
-	<iso_3166_entry
-		alpha_2_code="ZA"
-		alpha_3_code="ZAF"
-		numeric_code="710"
-		name="South Africa"
-		official_name="Republic of South Africa" />
-	<iso_3166_entry
-		alpha_2_code="GS"
-		alpha_3_code="SGS"
-		numeric_code="239"
-		name="South Georgia and the South Sandwich Islands" />
-	<iso_3166_entry
-		alpha_2_code="ES"
-		alpha_3_code="ESP"
-		numeric_code="724"
-		name="Spain"
-		official_name="Kingdom of Spain" />
-	<iso_3166_entry
-		alpha_2_code="LK"
-		alpha_3_code="LKA"
-		numeric_code="144"
-		name="Sri Lanka"
-		official_name="Democratic Socialist Republic of Sri Lanka" />
-	<iso_3166_entry
-		alpha_2_code="SD"
-		alpha_3_code="SDN"
-		numeric_code="736"
-		name="Sudan"
-		official_name="Republic of the Sudan" />
-	<iso_3166_entry
-		alpha_2_code="SR"
-		alpha_3_code="SUR"
-		numeric_code="740"
-		name="Suriname"
-		official_name="Republic of Suriname" />
-	<iso_3166_entry
-		alpha_2_code="SJ"
-		alpha_3_code="SJM"
-		numeric_code="744"
-		name="Svalbard and Jan Mayen" />
-	<iso_3166_entry
-		alpha_2_code="SZ"
-		alpha_3_code="SWZ"
-		numeric_code="748"
-		name="Swaziland"
-		official_name="Kingdom of Swaziland" />
-	<iso_3166_entry
-		alpha_2_code="SE"
-		alpha_3_code="SWE"
-		numeric_code="752"
-		name="Sweden"
-		official_name="Kingdom of Sweden" />
-	<iso_3166_entry
-		alpha_2_code="CH"
-		alpha_3_code="CHE"
-		numeric_code="756"
-		name="Switzerland"
-		official_name="Swiss Confederation" />
-	<iso_3166_entry
-		alpha_2_code="SY"
-		alpha_3_code="SYR"
-		numeric_code="760"
-		name="Syrian Arab Republic" />
-	<iso_3166_entry
-		alpha_2_code="TW"
-		alpha_3_code="TWN"
-		numeric_code="158"
-		common_name="Taiwan"
-		name="Taiwan, Province of China"
-		official_name="Taiwan, Province of China" />
-	<iso_3166_entry
-		alpha_2_code="TJ"
-		alpha_3_code="TJK"
-		numeric_code="762"
-		name="Tajikistan"
-		official_name="Republic of Tajikistan" />
-	<iso_3166_entry
-		alpha_2_code="TZ"
-		alpha_3_code="TZA"
-		numeric_code="834"
-		name="Tanzania, United Republic of"
-		official_name="United Republic of Tanzania" />
-	<iso_3166_entry
-		alpha_2_code="TH"
-		alpha_3_code="THA"
-		numeric_code="764"
-		name="Thailand"
-		official_name="Kingdom of Thailand" />
-	<iso_3166_entry
-		alpha_2_code="TL"
-		alpha_3_code="TLS"
-		numeric_code="626"
-		name="Timor-Leste"
-		official_name="Democratic Republic of Timor-Leste" />
-	<iso_3166_entry
-		alpha_2_code="TG"
-		alpha_3_code="TGO"
-		numeric_code="768"
-		name="Togo"
-		official_name="Togolese Republic" />
-	<iso_3166_entry
-		alpha_2_code="TK"
-		alpha_3_code="TKL"
-		numeric_code="772"
-		name="Tokelau" />
-	<iso_3166_entry
-		alpha_2_code="TO"
-		alpha_3_code="TON"
-		numeric_code="776"
-		name="Tonga"
-		official_name="Kingdom of Tonga" />
-	<iso_3166_entry
-		alpha_2_code="TT"
-		alpha_3_code="TTO"
-		numeric_code="780"
-		name="Trinidad and Tobago"
-		official_name="Republic of Trinidad and Tobago" />
-	<iso_3166_entry
-		alpha_2_code="TN"
-		alpha_3_code="TUN"
-		numeric_code="788"
-		name="Tunisia"
-		official_name="Republic of Tunisia" />
-	<iso_3166_entry
-		alpha_2_code="TR"
-		alpha_3_code="TUR"
-		numeric_code="792"
-		name="Turkey"
-		official_name="Republic of Turkey" />
-	<iso_3166_entry
-		alpha_2_code="TM"
-		alpha_3_code="TKM"
-		numeric_code="795"
-		name="Turkmenistan" />
-	<iso_3166_entry
-		alpha_2_code="TC"
-		alpha_3_code="TCA"
-		numeric_code="796"
-		name="Turks and Caicos Islands" />
-	<iso_3166_entry
-		alpha_2_code="TV"
-		alpha_3_code="TUV"
-		numeric_code="798"
-		name="Tuvalu" />
-	<iso_3166_entry
-		alpha_2_code="UG"
-		alpha_3_code="UGA"
-		numeric_code="800"
-		name="Uganda"
-		official_name="Republic of Uganda" />
-	<iso_3166_entry
-		alpha_2_code="UA"
-		alpha_3_code="UKR"
-		numeric_code="804"
-		name="Ukraine" />
-	<iso_3166_entry
-		alpha_2_code="AE"
-		alpha_3_code="ARE"
-		numeric_code="784"
-		name="United Arab Emirates" />
-	<iso_3166_entry
-		alpha_2_code="GB"
-		alpha_3_code="GBR"
-		numeric_code="826"
-		name="United Kingdom"
-		official_name="United Kingdom of Great Britain and Northern Ireland" />
-	<iso_3166_entry
-		alpha_2_code="US"
-		alpha_3_code="USA"
-		numeric_code="840"
-		name="United States"
-		official_name="United States of America" />
-	<iso_3166_entry
-		alpha_2_code="UM"
-		alpha_3_code="UMI"
-		numeric_code="581"
-		name="United States Minor Outlying Islands" />
-	<iso_3166_entry
-		alpha_2_code="UY"
-		alpha_3_code="URY"
-		numeric_code="858"
-		name="Uruguay"
-		official_name="Eastern Republic of Uruguay" />
-	<iso_3166_entry
-		alpha_2_code="UZ"
-		alpha_3_code="UZB"
-		numeric_code="860"
-		name="Uzbekistan"
-		official_name="Republic of Uzbekistan" />
-	<iso_3166_entry
-		alpha_2_code="VU"
-		alpha_3_code="VUT"
-		numeric_code="548"
-		name="Vanuatu"
-		official_name="Republic of Vanuatu" />
-	<iso_3166_entry
-		alpha_2_code="VE"
-		alpha_3_code="VEN"
-		numeric_code="862"
-		common_name="Venezuela"
-		name="Venezuela, Bolivarian republic of"
-		official_name="Bolivarian Republic of Venezuela" />
-	<iso_3166_entry
-		alpha_2_code="VN"
-		alpha_3_code="VNM"
-		numeric_code="704"
-		name="Viet Nam"
-		official_name="Socialist Republic of Viet Nam" />
-	<!-- FIXME CHECK OFFICIAL NAME -->
-	<iso_3166_entry
-		alpha_2_code="VG"
-		alpha_3_code="VGB"
-		numeric_code="092"
-		name="Virgin Islands, British"
-		official_name="British Virgin Islands" />
-	<iso_3166_entry
-		alpha_2_code="VI"
-		alpha_3_code="VIR"
-		numeric_code="850"
-		name="Virgin Islands, U.S."
-		official_name="Virgin Islands of the United States" />
-	<iso_3166_entry
-		alpha_2_code="WF"
-		alpha_3_code="WLF"
-		numeric_code="876"
-		name="Wallis and Futuna" />
-	<iso_3166_entry
-		alpha_2_code="EH"
-		alpha_3_code="ESH"
-		numeric_code="732"
-		name="Western Sahara" />
-	<iso_3166_entry
-		alpha_2_code="YE"
-		alpha_3_code="YEM"
-		numeric_code="887"
-		name="Yemen"
-		official_name="Republic of Yemen" />
-	<iso_3166_entry
-		alpha_2_code="ZM"
-		alpha_3_code="ZMB"
-		numeric_code="894"
-		name="Zambia"
-		official_name="Republic of Zambia" />
-	<iso_3166_entry
-		alpha_2_code="ZW"
-		alpha_3_code="ZWE"
-		numeric_code="716"
-		name="Zimbabwe"
-		official_name="Republic of Zimbabwe" />
-	<iso_3166_3_entry
-		alpha_4_code="BQAQ"
-		alpha_3_code="ATB"
-		date_withdrawn="1979"
-		names="British Antarctic Territory" />
-	<iso_3166_3_entry
-		alpha_4_code="BUMM"
-		alpha_3_code="BUR"
-		numeric_code="104"
-		date_withdrawn="1989-12-05"
-		names="Burma, Socialist Republic of the Union of" />
-	<iso_3166_3_entry
-		alpha_4_code="BYAA"
-		alpha_3_code="BYS"
-		numeric_code="112"
-		date_withdrawn="1992-06-15"
-		names="Byelorussian SSR Soviet Socialist Republic" />
-	<iso_3166_3_entry
-		alpha_4_code="CTKI"
-		alpha_3_code="CTE"
-		numeric_code="128"
-		date_withdrawn="1984"
-		names="Canton and Enderbury Islands" />
-	<iso_3166_3_entry
-		alpha_4_code="CSHH"
-		alpha_3_code="CSK"
-		numeric_code="200"
-		date_withdrawn="1993-06-15"
-		names="Czechoslovakia, Czechoslovak Socialist Republic" />
-	<iso_3166_3_entry
-		alpha_4_code="DYBJ"
-		alpha_3_code="DHY"
-		numeric_code="204"
-		date_withdrawn="1977"
-		names="Dahomey" />
-	<iso_3166_3_entry
-		alpha_4_code="NQAQ"
-		alpha_3_code="ATN"
-		numeric_code="216"
-		date_withdrawn="1983"
-		names="Dronning Maud Land" />
-	<iso_3166_3_entry
-		alpha_4_code="TPTL"
-		alpha_3_code="TMP"
-		numeric_code="626"
-		date_withdrawn="2002-05-20"
-		names="East Timor"
-		comment="was Portuguese Timor" />
-	<iso_3166_3_entry
-		alpha_4_code="ET"
-		alpha_3_code="ETH"
-		numeric_code="230"
-		date_withdrawn="1993-07-16"
-		names="Ethiopia" />
-	<iso_3166_3_entry
-		alpha_4_code="FXFR"
-		alpha_3_code="FXX"
-		numeric_code="249"
-		date_withdrawn="1997-07-14"
-		names="France, Metropolitan" />
-	<iso_3166_3_entry
-		alpha_4_code="AIDJ"
-		alpha_3_code="AFI"
-		numeric_code="262"
-		date_withdrawn="1977"
-		names="French Afars and Issas" />
-	<iso_3166_3_entry
-		alpha_4_code="FQHH"
-		alpha_3_code="ATF"
-		date_withdrawn="1979"
-		names="French Southern and Antarctic Territories"
-		comment="now split between AQ and TF" />
-	<iso_3166_3_entry
-		alpha_4_code="DDDE"
-		alpha_3_code="DDR"
-		numeric_code="278"
-		date_withdrawn="1990-10-30"
-		names="German Democratic Republic" />
-	<iso_3166_3_entry
-		alpha_4_code="DE"
-		alpha_3_code="DEU"
-		numeric_code="280"
-		date_withdrawn="1990-10-30"
-		names="Germany, Federal Republic of" />
-	<iso_3166_3_entry
-		alpha_4_code="GEHH"
-		alpha_3_code="GEL"
-		numeric_code="296"
-		date_withdrawn="1979"
-		names="Gilbert and Ellice Islands"
-		comment="now split into Kiribati and Tuvalu" />
-	<iso_3166_3_entry
-		alpha_4_code="JTUM"
-		alpha_3_code="JTN"
-		numeric_code="396"
-		date_withdrawn="1986"
-		names="Johnston Island" />
-	<iso_3166_3_entry
-		alpha_4_code="MIUM"
-		alpha_3_code="MID"
-		numeric_code="488"
-		date_withdrawn="1986"
-		names="Midway Islands" />
-	<iso_3166_3_entry
-		alpha_4_code="AN"
-		alpha_3_code="ANT"
-		numeric_code="532"
-		date_withdrawn="1993-07-12"
-		names="Netherlands Antilles" />
-	<iso_3166_3_entry
-		alpha_4_code="NTHH"
-		alpha_3_code="NTZ"
-		numeric_code="536"
-		date_withdrawn="1993-07-12"
-		names="Neutral Zone"
-		comment="formerly between Saudi Arabia and Iraq" />
-	<iso_3166_3_entry
-		alpha_4_code="NHVU"
-		alpha_3_code="NHB"
-		numeric_code="548"
-		date_withdrawn="1980"
-		names="New Hebrides" />
-	<iso_3166_3_entry
-		alpha_4_code="PCHH"
-		alpha_3_code="PCI"
-		numeric_code="582"
-		date_withdrawn="1986"
-		names="Pacific Islands (trust territory)"
-		comment="divided into FM, MH, MP, and PW" />
-	<iso_3166_3_entry
-		alpha_4_code="PA"
-		alpha_3_code="PAN"
-		numeric_code="590"
-		date_withdrawn="1993-07-22"
-		names="Panama, Republic of" />
-	<iso_3166_3_entry
-		alpha_4_code="PZPA"
-		alpha_3_code="PCZ"
-		date_withdrawn="1980"
-		names="Panama Canal Zone" />
-	<iso_3166_3_entry
-		alpha_4_code="RO"
-		alpha_3_code="ROM"
-		numeric_code="642"
-		date_withdrawn="2002-02-01"
-		names="Romania, Socialist Republic of" />
-	<iso_3166_3_entry
-		alpha_4_code="KN"
-		alpha_3_code="KNA"
-		numeric_code="658"
-		date_withdrawn="1988"
-		names="St. Kitts-Nevis-Anguilla"
-		comment="now St. Kitts and Nevis and Anguilla" />
-	<iso_3166_3_entry
-		alpha_4_code="CSXX"
-		alpha_3_code="SCG"
-		numeric_code="891"
-		date_withdrawn="2006-06-05"
-		names="Serbia and Montenegro" />
-	<iso_3166_3_entry
-		alpha_4_code="SKIN"
-		alpha_3_code="SKM"
-		date_withdrawn="1975"
-		names="Sikkim" />
-	<iso_3166_3_entry
-		alpha_4_code="RHZW"
-		alpha_3_code="RHO"
-		numeric_code="716"
-		date_withdrawn="1980"
-		names="Southern Rhodesia" />
-	<iso_3166_3_entry
-		alpha_4_code="EH"
-		alpha_3_code="ESH"
-		numeric_code="732"
-		date_withdrawn="1988"
-		names="Spanish Sahara"
-		comment="now Western Sahara" />
-	<iso_3166_3_entry
-		alpha_4_code="PUUM"
-		alpha_3_code="PUS"
-		numeric_code="849"
-		date_withdrawn="1986"
-		names="US Miscellaneous Pacific Islands" />
-	<iso_3166_3_entry
-		alpha_4_code="SUHH"
-		alpha_3_code="SUN"
-		numeric_code="810"
-		date_withdrawn="1992-08-30"
-		names="USSR, Union of Soviet Socialist Republics" />
-	<iso_3166_3_entry
-		alpha_4_code="HVBF"
-		alpha_3_code="HVO"
-		numeric_code="854"
-		date_withdrawn="1984"
-		names="Upper Volta, Republic of" />
-	<iso_3166_3_entry
-		alpha_4_code="VA"
-		alpha_3_code="VAT"
-		numeric_code="336"
-		date_withdrawn="1996-04-03"
-		names="Vatican City State (Holy See)" />
-	<iso_3166_3_entry
-		alpha_4_code="VDVN"
-		alpha_3_code="VDR"
-		date_withdrawn="1977"
-		names="Viet-Nam, Democratic Republic of" />
-	<iso_3166_3_entry
-		alpha_4_code="WKUM"
-		alpha_3_code="WAK"
-		numeric_code="872"
-		date_withdrawn="1986"
-		names="Wake Island" />
-	<iso_3166_3_entry
-		alpha_4_code="YDYE"
-		alpha_3_code="YMD"
-		numeric_code="720"
-		date_withdrawn="1990-08-14"
-		names="Yemen, Democratic, People's Democratic Republic of" />
-	<iso_3166_3_entry
-		alpha_4_code="YE"
-		alpha_3_code="YEM"
-		numeric_code="891"
-		date_withdrawn="1990-08-14"
-		names="Yemen, Yemen Arab Republic" />
-	<iso_3166_3_entry
-		alpha_4_code="YUCS"
-		alpha_3_code="YUG"
-		numeric_code="891"
-		date_withdrawn="1993-07-28"
-		names="Yugoslavia, Socialist Federal Republic of" />
-	<iso_3166_3_entry
-		alpha_4_code="ZRCD"
-		alpha_3_code="ZAR"
-		numeric_code="180"
-		date_withdrawn="1997-07-14"
-		names="Zaire, Republic of" />
-</iso_3166_entries>
diff --git a/win32/share/xml/iso-codes/iso_639.xml b/win32/share/xml/iso-codes/iso_639.xml
deleted file mode 100644
index 02fa01fb..00000000
--- a/win32/share/xml/iso-codes/iso_639.xml
+++ /dev/null
@@ -1,2169 +0,0 @@
-<?xml version="1.0" encoding="UTF-8" ?>
-
-<!--
-This file gives a list of all languages in the ISO 639
-standard, and is used to provide translations via gettext
-
-Copyright (C) 2004-2006 Alastair McKinstry <mckinstry@computer.org>
-Copyright (C) 2004-2009 Christian Perrier <bubulle@debian.org>
-Copyright (C) 2005-2008 Tobias Quathamer <toddy@debian.org>
-
-    This file is free software; you can redistribute it and/or
-    modify it under the terms of the GNU Lesser General Public
-    License as published by the Free Software Foundation; either
-    version 2.1 of the License, or (at your option) any later version.
-
-    This file is distributed in the hope that it will be useful,
-    but WITHOUT ANY WARRANTY; without even the implied warranty of
-    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-    Lesser General Public License for more details.
-
-    You should have received a copy of the GNU Lesser General Public
-    License along with this file; if not, write to the Free Software
-    Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
-
-Source: <http://www.loc.gov/standards/iso639-2/>
--->
-
-<!DOCTYPE iso_639_entries [
-	<!ELEMENT iso_639_entries (iso_639_entry+)>
-	<!ELEMENT iso_639_entry EMPTY>
-	<!ATTLIST iso_639_entry
-		iso_639_2B_code		CDATA	#REQUIRED
-		iso_639_2T_code		CDATA	#REQUIRED
-		iso_639_1_code		CDATA	#IMPLIED
-		name			CDATA	#REQUIRED
-	>
-]>
-
-<iso_639_entries>
-	<iso_639_entry
-		iso_639_2B_code="aar"
-		iso_639_2T_code="aar"
-		iso_639_1_code="aa"
-		name="Afar" />
-	<iso_639_entry
-		iso_639_2B_code="abk"
-		iso_639_2T_code="abk"
-		iso_639_1_code="ab"
-		name="Abkhazian" />
-	<iso_639_entry
-		iso_639_2B_code="ace"
-		iso_639_2T_code="ace"
-		name="Achinese" />
-	<iso_639_entry
-		iso_639_2B_code="ach"
-		iso_639_2T_code="ach"
-		name="Acoli" />
-	<iso_639_entry
-		iso_639_2B_code="ada"
-		iso_639_2T_code="ada"
-		name="Adangme" />
-	<iso_639_entry
-		iso_639_2B_code="ady"
-		iso_639_2T_code="ady"
-		name="Adyghe; Adygei" />
-	<iso_639_entry
-		iso_639_2B_code="afa"
-		iso_639_2T_code="afa"
-		name="Afro-Asiatic languages" />
-	<iso_639_entry
-		iso_639_2B_code="afh"
-		iso_639_2T_code="afh"
-		name="Afrihili" />
-	<iso_639_entry
-		iso_639_2B_code="afr"
-		iso_639_2T_code="afr"
-		iso_639_1_code="af"
-		name="Afrikaans" />
-	<iso_639_entry
-		iso_639_2B_code="ain"
-		iso_639_2T_code="ain"
-		name="Ainu" />
-	<iso_639_entry
-		iso_639_2B_code="aka"
-		iso_639_2T_code="aka"
-		iso_639_1_code="ak"
-		name="Akan" />
-	<iso_639_entry
-		iso_639_2B_code="akk"
-		iso_639_2T_code="akk"
-		name="Akkadian" />
-	<iso_639_entry
-		iso_639_2B_code="alb"
-		iso_639_2T_code="sqi"
-		iso_639_1_code="sq"
-		name="Albanian" />
-	<iso_639_entry
-		iso_639_2B_code="ale"
-		iso_639_2T_code="ale"
-		name="Aleut" />
-	<iso_639_entry
-		iso_639_2B_code="alg"
-		iso_639_2T_code="alg"
-		name="Algonquian languages" />
-	<iso_639_entry
-		iso_639_2B_code="alt"
-		iso_639_2T_code="alt"
-		name="Southern Altai" />
-	<iso_639_entry
-		iso_639_2B_code="amh"
-		iso_639_2T_code="amh"
-		iso_639_1_code="am"
-		name="Amharic" />
-	<iso_639_entry
-		iso_639_2B_code="ang"
-		iso_639_2T_code="ang"
-		name="English, Old (ca. 450-1100)" />
-	<iso_639_entry
-		iso_639_2B_code="anp"
-		iso_639_2T_code="anp"
-		name="Angika" />
-	<iso_639_entry
-		iso_639_2B_code="apa"
-		iso_639_2T_code="apa"
-		name="Apache languages" />
-	<iso_639_entry
-		iso_639_2B_code="ara"
-		iso_639_2T_code="ara"
-		iso_639_1_code="ar"
-		name="Arabic" />
-	<iso_639_entry
-		iso_639_2B_code="arc"
-		iso_639_2T_code="arc"
-		name="Official Aramaic (700-300 BCE); Imperial Aramaic (700-300 BCE)" />
-	<iso_639_entry
-		iso_639_2B_code="arg"
-		iso_639_2T_code="arg"
-		iso_639_1_code="an"
-		name="Aragonese" />
-	<iso_639_entry
-		iso_639_2B_code="arm"
-		iso_639_2T_code="hye"
-		iso_639_1_code="hy"
-		name="Armenian" />
-	<iso_639_entry
-		iso_639_2B_code="arn"
-		iso_639_2T_code="arn"
-		name="Mapudungun; Mapuche" />
-	<iso_639_entry
-		iso_639_2B_code="arp"
-		iso_639_2T_code="arp"
-		name="Arapaho" />
-	<iso_639_entry
-		iso_639_2B_code="art"
-		iso_639_2T_code="art"
-		name="Artificial languages" />
-	<iso_639_entry
-		iso_639_2B_code="arw"
-		iso_639_2T_code="arw"
-		name="Arawak" />
-	<iso_639_entry
-		iso_639_2B_code="asm"
-		iso_639_2T_code="asm"
-		iso_639_1_code="as"
-		name="Assamese" />
-	<iso_639_entry
-		iso_639_2B_code="ast"
-		iso_639_2T_code="ast"
-		name="Asturian; Bable; Leonese; Asturleonese" />
-	<iso_639_entry
-		iso_639_2B_code="ath"
-		iso_639_2T_code="ath"
-		name="Athapascan languages" />
-	<iso_639_entry
-		iso_639_2B_code="aus"
-		iso_639_2T_code="aus"
-		name="Australian languages" />
-	<iso_639_entry
-		iso_639_2B_code="ava"
-		iso_639_2T_code="ava"
-		iso_639_1_code="av"
-		name="Avaric" />
-	<iso_639_entry
-		iso_639_2B_code="ave"
-		iso_639_2T_code="ave"
-		iso_639_1_code="ae"
-		name="Avestan" />
-	<iso_639_entry
-		iso_639_2B_code="awa"
-		iso_639_2T_code="awa"
-		name="Awadhi" />
-	<iso_639_entry
-		iso_639_2B_code="aym"
-		iso_639_2T_code="aym"
-		iso_639_1_code="ay"
-		name="Aymara" />
-	<iso_639_entry
-		iso_639_2B_code="aze"
-		iso_639_2T_code="aze"
-		iso_639_1_code="az"
-		name="Azerbaijani" />
-	<iso_639_entry
-		iso_639_2B_code="bad"
-		iso_639_2T_code="bad"
-		name="Banda languages" />
-	<iso_639_entry
-		iso_639_2B_code="bai"
-		iso_639_2T_code="bai"
-		name="Bamileke languages" />
-	<iso_639_entry
-		iso_639_2B_code="bak"
-		iso_639_2T_code="bak"
-		iso_639_1_code="ba"
-		name="Bashkir" />
-	<iso_639_entry
-		iso_639_2B_code="bal"
-		iso_639_2T_code="bal"
-		name="Baluchi" />
-	<iso_639_entry
-		iso_639_2B_code="bam"
-		iso_639_2T_code="bam"
-		iso_639_1_code="bm"
-		name="Bambara" />
-	<iso_639_entry
-		iso_639_2B_code="ban"
-		iso_639_2T_code="ban"
-		name="Balinese" />
-	<iso_639_entry
-		iso_639_2B_code="baq"
-		iso_639_2T_code="eus"
-		iso_639_1_code="eu"
-		name="Basque" />
-	<iso_639_entry
-		iso_639_2B_code="bas"
-		iso_639_2T_code="bas"
-		name="Basa" />
-	<iso_639_entry
-		iso_639_2B_code="bat"
-		iso_639_2T_code="bat"
-		name="Baltic languages" />
-	<iso_639_entry
-		iso_639_2B_code="bej"
-		iso_639_2T_code="bej"
-		name="Beja; Bedawiyet" />
-	<iso_639_entry
-		iso_639_2B_code="bel"
-		iso_639_2T_code="bel"
-		iso_639_1_code="be"
-		name="Belarusian" />
-	<iso_639_entry
-		iso_639_2B_code="bem"
-		iso_639_2T_code="bem"
-		name="Bemba" />
-	<iso_639_entry
-		iso_639_2B_code="ben"
-		iso_639_2T_code="ben"
-		iso_639_1_code="bn"
-		name="Bengali" />
-	<iso_639_entry
-		iso_639_2B_code="ber"
-		iso_639_2T_code="ber"
-		name="Berber languages" />
-	<iso_639_entry
-		iso_639_2B_code="bho"
-		iso_639_2T_code="bho"
-		name="Bhojpuri" />
-	<iso_639_entry
-		iso_639_2B_code="bih"
-		iso_639_2T_code="bih"
-		iso_639_1_code="bh"
-		name="Bihari languages" />
-	<iso_639_entry
-		iso_639_2B_code="bik"
-		iso_639_2T_code="bik"
-		name="Bikol" />
-	<iso_639_entry
-		iso_639_2B_code="bin"
-		iso_639_2T_code="bin"
-		name="Bini; Edo" />
-	<iso_639_entry
-		iso_639_2B_code="bis"
-		iso_639_2T_code="bis"
-		iso_639_1_code="bi"
-		name="Bislama" />
-	<iso_639_entry
-		iso_639_2B_code="bla"
-		iso_639_2T_code="bla"
-		name="Siksika" />
-	<iso_639_entry
-		iso_639_2B_code="bnt"
-		iso_639_2T_code="bnt"
-		name="Bantu languages" />
-	<iso_639_entry
-		iso_639_2B_code="bos"
-		iso_639_2T_code="bos"
-		iso_639_1_code="bs"
-		name="Bosnian" />
-	<iso_639_entry
-		iso_639_2B_code="bra"
-		iso_639_2T_code="bra"
-		name="Braj" />
-	<iso_639_entry
-		iso_639_2B_code="bre"
-		iso_639_2T_code="bre"
-		iso_639_1_code="br"
-		name="Breton" />
-	<iso_639_entry
-		iso_639_2B_code="btk"
-		iso_639_2T_code="btk"
-		name="Batak languages" />
-	<iso_639_entry
-		iso_639_2B_code="bua"
-		iso_639_2T_code="bua"
-		name="Buriat" />
-	<iso_639_entry
-		iso_639_2B_code="bug"
-		iso_639_2T_code="bug"
-		name="Buginese" />
-	<iso_639_entry
-		iso_639_2B_code="bul"
-		iso_639_2T_code="bul"
-		iso_639_1_code="bg"
-		name="Bulgarian" />
-	<iso_639_entry
-		iso_639_2B_code="bur"
-		iso_639_2T_code="mya"
-		iso_639_1_code="my"
-		name="Burmese" />
-	<iso_639_entry
-		iso_639_2B_code="byn"
-		iso_639_2T_code="byn"
-		name="Blin; Bilin" />
-	<iso_639_entry
-		iso_639_2B_code="cad"
-		iso_639_2T_code="cad"
-		name="Caddo" />
-	<iso_639_entry
-		iso_639_2B_code="cai"
-		iso_639_2T_code="cai"
-		name="Central American Indian languages" />
-	<iso_639_entry
-		iso_639_2B_code="car"
-		iso_639_2T_code="car"
-		name="Galibi Carib" />
-	<iso_639_entry
-		iso_639_2B_code="cat"
-		iso_639_2T_code="cat"
-		iso_639_1_code="ca"
-		name="Catalan; Valencian" />
-	<iso_639_entry
-		iso_639_2B_code="cau"
-		iso_639_2T_code="cau"
-		name="Caucasian languages" />
-	<iso_639_entry
-		iso_639_2B_code="ceb"
-		iso_639_2T_code="ceb"
-		name="Cebuano" />
-	<iso_639_entry
-		iso_639_2B_code="cel"
-		iso_639_2T_code="cel"
-		name="Celtic languages" />
-	<iso_639_entry
-		iso_639_2B_code="cha"
-		iso_639_2T_code="cha"
-		iso_639_1_code="ch"
-		name="Chamorro" />
-	<iso_639_entry
-		iso_639_2B_code="chb"
-		iso_639_2T_code="chb"
-		name="Chibcha" />
-	<iso_639_entry
-		iso_639_2B_code="che"
-		iso_639_2T_code="che"
-		iso_639_1_code="ce"
-		name="Chechen" />
-	<iso_639_entry
-		iso_639_2B_code="chg"
-		iso_639_2T_code="chg"
-		name="Chagatai" />
-	<iso_639_entry
-		iso_639_2B_code="chi"
-		iso_639_2T_code="zho"
-		iso_639_1_code="zh"
-		name="Chinese" />
-	<iso_639_entry
-		iso_639_2B_code="chk"
-		iso_639_2T_code="chk"
-		name="Chuukese" />
-	<iso_639_entry
-		iso_639_2B_code="chm"
-		iso_639_2T_code="chm"
-		name="Mari" />
-	<iso_639_entry
-		iso_639_2B_code="chn"
-		iso_639_2T_code="chn"
-		name="Chinook jargon" />
-	<iso_639_entry
-		iso_639_2B_code="cho"
-		iso_639_2T_code="cho"
-		name="Choctaw" />
-	<iso_639_entry
-		iso_639_2B_code="chp"
-		iso_639_2T_code="chp"
-		name="Chipewyan; Dene Suline" />
-	<iso_639_entry
-		iso_639_2B_code="chr"
-		iso_639_2T_code="chr"
-		name="Cherokee" />
-	<iso_639_entry
-		iso_639_2B_code="chu"
-		iso_639_2T_code="chu"
-		iso_639_1_code="cu"
-		name="Church Slavic; Old Slavonic; Church Slavonic; Old Bulgarian; Old Church Slavonic" />
-	<iso_639_entry
-		iso_639_2B_code="chv"
-		iso_639_2T_code="chv"
-		iso_639_1_code="cv"
-		name="Chuvash" />
-	<iso_639_entry
-		iso_639_2B_code="chy"
-		iso_639_2T_code="chy"
-		name="Cheyenne" />
-	<iso_639_entry
-		iso_639_2B_code="cmc"
-		iso_639_2T_code="cmc"
-		name="Chamic languages" />
-	<iso_639_entry
-		iso_639_2B_code="cop"
-		iso_639_2T_code="cop"
-		name="Coptic" />
-	<iso_639_entry
-		iso_639_2B_code="cor"
-		iso_639_2T_code="cor"
-		iso_639_1_code="kw"
-		name="Cornish" />
-	<iso_639_entry
-		iso_639_2B_code="cos"
-		iso_639_2T_code="cos"
-		iso_639_1_code="co"
-		name="Corsican" />
-	<iso_639_entry
-		iso_639_2B_code="cpe"
-		iso_639_2T_code="cpe"
-		name="Creoles and pidgins, English based" />
-	<iso_639_entry
-		iso_639_2B_code="cpf"
-		iso_639_2T_code="cpf"
-		name="Creoles and pidgins, French-based" />
-	<iso_639_entry
-		iso_639_2B_code="cpp"
-		iso_639_2T_code="cpp"
-		name="Creoles and pidgins, Portuguese-based" />
-	<iso_639_entry
-		iso_639_2B_code="cre"
-		iso_639_2T_code="cre"
-		iso_639_1_code="cr"
-		name="Cree" />
-	<iso_639_entry
-		iso_639_2B_code="crh"
-		iso_639_2T_code="crh"
-		name="Crimean Tatar; Crimean Turkish" />
-	<iso_639_entry
-		iso_639_2B_code="crp"
-		iso_639_2T_code="crp"
-		name="Creoles and pidgins" />
-	<iso_639_entry
-		iso_639_2B_code="csb"
-		iso_639_2T_code="csb"
-		name="Kashubian" />
-	<iso_639_entry
-		iso_639_2B_code="cus"
-		iso_639_2T_code="cus"
-		name="Cushitic languages" />
-	<iso_639_entry
-		iso_639_2B_code="cze"
-		iso_639_2T_code="ces"
-		iso_639_1_code="cs"
-		name="Czech" />
-	<iso_639_entry
-		iso_639_2B_code="dak"
-		iso_639_2T_code="dak"
-		name="Dakota" />
-	<iso_639_entry
-		iso_639_2B_code="dan"
-		iso_639_2T_code="dan"
-		iso_639_1_code="da"
-		name="Danish" />
-	<iso_639_entry
-		iso_639_2B_code="dar"
-		iso_639_2T_code="dar"
-		name="Dargwa" />
-	<iso_639_entry
-		iso_639_2B_code="day"
-		iso_639_2T_code="day"
-		name="Land Dayak languages" />
-	<iso_639_entry
-		iso_639_2B_code="del"
-		iso_639_2T_code="del"
-		name="Delaware" />
-	<iso_639_entry
-		iso_639_2B_code="den"
-		iso_639_2T_code="den"
-		name="Slave (Athapascan)" />
-	<iso_639_entry
-		iso_639_2B_code="dgr"
-		iso_639_2T_code="dgr"
-		name="Dogrib" />
-	<iso_639_entry
-		iso_639_2B_code="din"
-		iso_639_2T_code="din"
-		name="Dinka" />
-	<iso_639_entry
-		iso_639_2B_code="div"
-		iso_639_2T_code="div"
-		iso_639_1_code="dv"
-		name="Divehi; Dhivehi; Maldivian" />
-	<iso_639_entry
-		iso_639_2B_code="doi"
-		iso_639_2T_code="doi"
-		name="Dogri" />
-	<iso_639_entry
-		iso_639_2B_code="dra"
-		iso_639_2T_code="dra"
-		name="Dravidian languages" />
-	<iso_639_entry
-		iso_639_2B_code="dsb"
-		iso_639_2T_code="dsb"
-		name="Lower Sorbian" />
-	<iso_639_entry
-		iso_639_2B_code="dua"
-		iso_639_2T_code="dua"
-		name="Duala" />
-	<iso_639_entry
-		iso_639_2B_code="dum"
-		iso_639_2T_code="dum"
-		name="Dutch, Middle (ca. 1050-1350)" />
-	<iso_639_entry
-		iso_639_2B_code="dut"
-		iso_639_2T_code="nld"
-		iso_639_1_code="nl"
-		name="Dutch; Flemish" />
-	<iso_639_entry
-		iso_639_2B_code="dyu"
-		iso_639_2T_code="dyu"
-		name="Dyula" />
-	<iso_639_entry
-		iso_639_2B_code="dzo"
-		iso_639_2T_code="dzo"
-		iso_639_1_code="dz"
-		name="Dzongkha" />
-	<iso_639_entry
-		iso_639_2B_code="efi"
-		iso_639_2T_code="efi"
-		name="Efik" />
-	<iso_639_entry
-		iso_639_2B_code="egy"
-		iso_639_2T_code="egy"
-		name="Egyptian (Ancient)" />
-	<iso_639_entry
-		iso_639_2B_code="eka"
-		iso_639_2T_code="eka"
-		name="Ekajuk" />
-	<iso_639_entry
-		iso_639_2B_code="elx"
-		iso_639_2T_code="elx"
-		name="Elamite" />
-	<iso_639_entry
-		iso_639_2B_code="eng"
-		iso_639_2T_code="eng"
-		iso_639_1_code="en"
-		name="English" />
-	<iso_639_entry
-		iso_639_2B_code="enm"
-		iso_639_2T_code="enm"
-		name="English, Middle (1100-1500)" />
-	<iso_639_entry
-		iso_639_2B_code="epo"
-		iso_639_2T_code="epo"
-		iso_639_1_code="eo"
-		name="Esperanto" />
-	<iso_639_entry
-		iso_639_2B_code="est"
-		iso_639_2T_code="est"
-		iso_639_1_code="et"
-		name="Estonian" />
-	<iso_639_entry
-		iso_639_2B_code="ewe"
-		iso_639_2T_code="ewe"
-		iso_639_1_code="ee"
-		name="Ewe" />
-	<iso_639_entry
-		iso_639_2B_code="ewo"
-		iso_639_2T_code="ewo"
-		name="Ewondo" />
-	<iso_639_entry
-		iso_639_2B_code="fan"
-		iso_639_2T_code="fan"
-		name="Fang" />
-	<iso_639_entry
-		iso_639_2B_code="fao"
-		iso_639_2T_code="fao"
-		iso_639_1_code="fo"
-		name="Faroese" />
-	<iso_639_entry
-		iso_639_2B_code="fat"
-		iso_639_2T_code="fat"
-		name="Fanti" />
-	<iso_639_entry
-		iso_639_2B_code="fij"
-		iso_639_2T_code="fij"
-		iso_639_1_code="fj"
-		name="Fijian" />
-	<iso_639_entry
-		iso_639_2B_code="fil"
-		iso_639_2T_code="fil"
-		name="Filipino; Pilipino" />
-	<iso_639_entry
-		iso_639_2B_code="fin"
-		iso_639_2T_code="fin"
-		iso_639_1_code="fi"
-		name="Finnish" />
-	<iso_639_entry
-		iso_639_2B_code="fiu"
-		iso_639_2T_code="fiu"
-		name="Finno-Ugrian languages" />
-	<iso_639_entry
-		iso_639_2B_code="fon"
-		iso_639_2T_code="fon"
-		name="Fon" />
-	<iso_639_entry
-		iso_639_2B_code="fre"
-		iso_639_2T_code="fra"
-		iso_639_1_code="fr"
-		name="French" />
-	<iso_639_entry
-		iso_639_2B_code="frm"
-		iso_639_2T_code="frm"
-		name="French, Middle (ca. 1400-1600)" />
-	<iso_639_entry
-		iso_639_2B_code="fro"
-		iso_639_2T_code="fro"
-		name="French, Old (842-ca. 1400)" />
-	<iso_639_entry
-		iso_639_2B_code="frr"
-		iso_639_2T_code="frr"
-		name="Northern Frisian" />
-	<iso_639_entry
-		iso_639_2B_code="frs"
-		iso_639_2T_code="frs"
-		name="Eastern Frisian" />
-	<iso_639_entry
-		iso_639_2B_code="fry"
-		iso_639_2T_code="fry"
-		iso_639_1_code="fy"
-		name="Western Frisian" />
-	<iso_639_entry
-		iso_639_2B_code="ful"
-		iso_639_2T_code="ful"
-		iso_639_1_code="ff"
-		name="Fulah" />
-	<iso_639_entry
-		iso_639_2B_code="fur"
-		iso_639_2T_code="fur"
-		name="Friulian" />
-	<iso_639_entry
-		iso_639_2B_code="gaa"
-		iso_639_2T_code="gaa"
-		name="Ga" />
-	<iso_639_entry
-		iso_639_2B_code="gay"
-		iso_639_2T_code="gay"
-		name="Gayo" />
-	<iso_639_entry
-		iso_639_2B_code="gba"
-		iso_639_2T_code="gba"
-		name="Gbaya" />
-	<iso_639_entry
-		iso_639_2B_code="gem"
-		iso_639_2T_code="gem"
-		name="Germanic languages" />
-	<iso_639_entry
-		iso_639_2B_code="geo"
-		iso_639_2T_code="kat"
-		iso_639_1_code="ka"
-		name="Georgian" />
-	<iso_639_entry
-		iso_639_2B_code="ger"
-		iso_639_2T_code="deu"
-		iso_639_1_code="de"
-		name="German" />
-	<iso_639_entry
-		iso_639_2B_code="gez"
-		iso_639_2T_code="gez"
-		name="Geez" />
-	<iso_639_entry
-		iso_639_2B_code="gil"
-		iso_639_2T_code="gil"
-		name="Gilbertese" />
-	<iso_639_entry
-		iso_639_2B_code="gla"
-		iso_639_2T_code="gla"
-		iso_639_1_code="gd"
-		name="Gaelic; Scottish Gaelic" />
-	<iso_639_entry
-		iso_639_2B_code="gle"
-		iso_639_2T_code="gle"
-		iso_639_1_code="ga"
-		name="Irish" />
-	<iso_639_entry
-		iso_639_2B_code="glg"
-		iso_639_2T_code="glg"
-		iso_639_1_code="gl"
-		name="Galician" />
-	<iso_639_entry
-		iso_639_2B_code="glv"
-		iso_639_2T_code="glv"
-		iso_639_1_code="gv"
-		name="Manx" />
-	<iso_639_entry
-		iso_639_2B_code="gmh"
-		iso_639_2T_code="gmh"
-		name="German, Middle High (ca. 1050-1500)" />
-	<iso_639_entry
-		iso_639_2B_code="goh"
-		iso_639_2T_code="goh"
-		name="German, Old High (ca. 750-1050)" />
-	<iso_639_entry
-		iso_639_2B_code="gon"
-		iso_639_2T_code="gon"
-		name="Gondi" />
-	<iso_639_entry
-		iso_639_2B_code="gor"
-		iso_639_2T_code="gor"
-		name="Gorontalo" />
-	<iso_639_entry
-		iso_639_2B_code="got"
-		iso_639_2T_code="got"
-		name="Gothic" />
-	<iso_639_entry
-		iso_639_2B_code="grb"
-		iso_639_2T_code="grb"
-		name="Grebo" />
-	<iso_639_entry
-		iso_639_2B_code="grc"
-		iso_639_2T_code="grc"
-		name="Greek, Ancient (to 1453)" />
-	<iso_639_entry
-		iso_639_2B_code="gre"
-		iso_639_2T_code="ell"
-		iso_639_1_code="el"
-		name="Greek, Modern (1453-)" />
-	<iso_639_entry
-		iso_639_2B_code="grn"
-		iso_639_2T_code="grn"
-		iso_639_1_code="gn"
-		name="Guarani" />
-	<iso_639_entry
-		iso_639_2B_code="gsw"
-		iso_639_2T_code="gsw"
-		name="Swiss German; Alemannic; Alsatian" />
-	<iso_639_entry
-		iso_639_2B_code="guj"
-		iso_639_2T_code="guj"
-		iso_639_1_code="gu"
-		name="Gujarati" />
-	<iso_639_entry
-		iso_639_2B_code="gwi"
-		iso_639_2T_code="gwi"
-		name="Gwich'in" />
-	<iso_639_entry
-		iso_639_2B_code="hai"
-		iso_639_2T_code="hai"
-		name="Haida" />
-	<iso_639_entry
-		iso_639_2B_code="hat"
-		iso_639_2T_code="hat"
-		iso_639_1_code="ht"
-		name="Haitian; Haitian Creole" />
-	<iso_639_entry
-		iso_639_2B_code="hau"
-		iso_639_2T_code="hau"
-		iso_639_1_code="ha"
-		name="Hausa" />
-	<iso_639_entry
-		iso_639_2B_code="haw"
-		iso_639_2T_code="haw"
-		name="Hawaiian" />
-	<iso_639_entry
-		iso_639_2B_code="heb"
-		iso_639_2T_code="heb"
-		iso_639_1_code="he"
-		name="Hebrew" />
-	<iso_639_entry
-		iso_639_2B_code="her"
-		iso_639_2T_code="her"
-		iso_639_1_code="hz"
-		name="Herero" />
-	<iso_639_entry
-		iso_639_2B_code="hil"
-		iso_639_2T_code="hil"
-		name="Hiligaynon" />
-	<iso_639_entry
-		iso_639_2B_code="him"
-		iso_639_2T_code="him"
-		name="Himachali languages; Western Pahari languages" />
-	<iso_639_entry
-		iso_639_2B_code="hin"
-		iso_639_2T_code="hin"
-		iso_639_1_code="hi"
-		name="Hindi" />
-	<iso_639_entry
-		iso_639_2B_code="hit"
-		iso_639_2T_code="hit"
-		name="Hittite" />
-	<iso_639_entry
-		iso_639_2B_code="hmn"
-		iso_639_2T_code="hmn"
-		name="Hmong; Mong" />
-	<iso_639_entry
-		iso_639_2B_code="hmo"
-		iso_639_2T_code="hmo"
-		iso_639_1_code="ho"
-		name="Hiri Motu" />
-	<iso_639_entry
-		iso_639_2B_code="hrv"
-		iso_639_2T_code="hrv"
-		iso_639_1_code="hr"
-		name="Croatian" />
-	<iso_639_entry
-		iso_639_2B_code="hsb"
-		iso_639_2T_code="hsb"
-		name="Upper Sorbian" />
-	<iso_639_entry
-		iso_639_2B_code="hun"
-		iso_639_2T_code="hun"
-		iso_639_1_code="hu"
-		name="Hungarian" />
-	<iso_639_entry
-		iso_639_2B_code="hup"
-		iso_639_2T_code="hup"
-		name="Hupa" />
-	<iso_639_entry
-		iso_639_2B_code="iba"
-		iso_639_2T_code="iba"
-		name="Iban" />
-	<iso_639_entry
-		iso_639_2B_code="ibo"
-		iso_639_2T_code="ibo"
-		iso_639_1_code="ig"
-		name="Igbo" />
-	<iso_639_entry
-		iso_639_2B_code="ice"
-		iso_639_2T_code="isl"
-		iso_639_1_code="is"
-		name="Icelandic" />
-	<iso_639_entry
-		iso_639_2B_code="ido"
-		iso_639_2T_code="ido"
-		iso_639_1_code="io"
-		name="Ido" />
-	<iso_639_entry
-		iso_639_2B_code="iii"
-		iso_639_2T_code="iii"
-		iso_639_1_code="ii"
-		name="Sichuan Yi; Nuosu" />
-	<iso_639_entry
-		iso_639_2B_code="ijo"
-		iso_639_2T_code="ijo"
-		name="Ijo languages" />
-	<iso_639_entry
-		iso_639_2B_code="iku"
-		iso_639_2T_code="iku"
-		iso_639_1_code="iu"
-		name="Inuktitut" />
-	<iso_639_entry
-		iso_639_2B_code="ile"
-		iso_639_2T_code="ile"
-		iso_639_1_code="ie"
-		name="Interlingue; Occidental" />
-	<iso_639_entry
-		iso_639_2B_code="ilo"
-		iso_639_2T_code="ilo"
-		name="Iloko" />
-	<iso_639_entry
-		iso_639_2B_code="ina"
-		iso_639_2T_code="ina"
-		iso_639_1_code="ia"
-		name="Interlingua (International Auxiliary Language Association)" />
-	<iso_639_entry
-		iso_639_2B_code="inc"
-		iso_639_2T_code="inc"
-		name="Indic languages" />
-	<iso_639_entry
-		iso_639_2B_code="ind"
-		iso_639_2T_code="ind"
-		iso_639_1_code="id"
-		name="Indonesian" />
-	<iso_639_entry
-		iso_639_2B_code="ine"
-		iso_639_2T_code="ine"
-		name="Indo-European languages" />
-	<iso_639_entry
-		iso_639_2B_code="inh"
-		iso_639_2T_code="inh"
-		name="Ingush" />
-	<iso_639_entry
-		iso_639_2B_code="ipk"
-		iso_639_2T_code="ipk"
-		iso_639_1_code="ik"
-		name="Inupiaq" />
-	<iso_639_entry
-		iso_639_2B_code="ira"
-		iso_639_2T_code="ira"
-		name="Iranian languages" />
-	<iso_639_entry
-		iso_639_2B_code="iro"
-		iso_639_2T_code="iro"
-		name="Iroquoian languages" />
-	<iso_639_entry
-		iso_639_2B_code="ita"
-		iso_639_2T_code="ita"
-		iso_639_1_code="it"
-		name="Italian" />
-	<iso_639_entry
-		iso_639_2B_code="jav"
-		iso_639_2T_code="jav"
-		iso_639_1_code="jv"
-		name="Javanese" />
-	<iso_639_entry
-		iso_639_2B_code="jbo"
-		iso_639_2T_code="jbo"
-		name="Lojban" />
-	<iso_639_entry
-		iso_639_2B_code="jpn"
-		iso_639_2T_code="jpn"
-		iso_639_1_code="ja"
-		name="Japanese" />
-	<iso_639_entry
-		iso_639_2B_code="jpr"
-		iso_639_2T_code="jpr"
-		name="Judeo-Persian" />
-	<iso_639_entry
-		iso_639_2B_code="jrb"
-		iso_639_2T_code="jrb"
-		name="Judeo-Arabic" />
-	<iso_639_entry
-		iso_639_2B_code="kaa"
-		iso_639_2T_code="kaa"
-		name="Kara-Kalpak" />
-	<iso_639_entry
-		iso_639_2B_code="kab"
-		iso_639_2T_code="kab"
-		name="Kabyle" />
-	<iso_639_entry
-		iso_639_2B_code="kac"
-		iso_639_2T_code="kac"
-		name="Kachin; Jingpho" />
-	<iso_639_entry
-		iso_639_2B_code="kal"
-		iso_639_2T_code="kal"
-		iso_639_1_code="kl"
-		name="Kalaallisut; Greenlandic" />
-	<iso_639_entry
-		iso_639_2B_code="kam"
-		iso_639_2T_code="kam"
-		name="Kamba" />
-	<iso_639_entry
-		iso_639_2B_code="kan"
-		iso_639_2T_code="kan"
-		iso_639_1_code="kn"
-		name="Kannada" />
-	<iso_639_entry
-		iso_639_2B_code="kar"
-		iso_639_2T_code="kar"
-		name="Karen languages" />
-	<iso_639_entry
-		iso_639_2B_code="kas"
-		iso_639_2T_code="kas"
-		iso_639_1_code="ks"
-		name="Kashmiri" />
-	<iso_639_entry
-		iso_639_2B_code="kau"
-		iso_639_2T_code="kau"
-		iso_639_1_code="kr"
-		name="Kanuri" />
-	<iso_639_entry
-		iso_639_2B_code="kaw"
-		iso_639_2T_code="kaw"
-		name="Kawi" />
-	<iso_639_entry
-		iso_639_2B_code="kaz"
-		iso_639_2T_code="kaz"
-		iso_639_1_code="kk"
-		name="Kazakh" />
-	<iso_639_entry
-		iso_639_2B_code="kbd"
-		iso_639_2T_code="kbd"
-		name="Kabardian" />
-	<iso_639_entry
-		iso_639_2B_code="kha"
-		iso_639_2T_code="kha"
-		name="Khasi" />
-	<iso_639_entry
-		iso_639_2B_code="khi"
-		iso_639_2T_code="khi"
-		name="Khoisan languages" />
-	<iso_639_entry
-		iso_639_2B_code="khm"
-		iso_639_2T_code="khm"
-		iso_639_1_code="km"
-		name="Central Khmer" />
-	<iso_639_entry
-		iso_639_2B_code="kho"
-		iso_639_2T_code="kho"
-		name="Khotanese;Sakan" />
-	<iso_639_entry
-		iso_639_2B_code="kik"
-		iso_639_2T_code="kik"
-		iso_639_1_code="ki"
-		name="Kikuyu; Gikuyu" />
-	<iso_639_entry
-		iso_639_2B_code="kin"
-		iso_639_2T_code="kin"
-		iso_639_1_code="rw"
-		name="Kinyarwanda" />
-	<iso_639_entry
-		iso_639_2B_code="kir"
-		iso_639_2T_code="kir"
-		iso_639_1_code="ky"
-		name="Kirghiz; Kyrgyz" />
-	<iso_639_entry
-		iso_639_2B_code="kmb"
-		iso_639_2T_code="kmb"
-		name="Kimbundu" />
-	<iso_639_entry
-		iso_639_2B_code="kok"
-		iso_639_2T_code="kok"
-		name="Konkani" />
-	<iso_639_entry
-		iso_639_2B_code="kom"
-		iso_639_2T_code="kom"
-		iso_639_1_code="kv"
-		name="Komi" />
-	<iso_639_entry
-		iso_639_2B_code="kon"
-		iso_639_2T_code="kon"
-		iso_639_1_code="kg"
-		name="Kongo" />
-	<iso_639_entry
-		iso_639_2B_code="kor"
-		iso_639_2T_code="kor"
-		iso_639_1_code="ko"
-		name="Korean" />
-	<iso_639_entry
-		iso_639_2B_code="kos"
-		iso_639_2T_code="kos"
-		name="Kosraean" />
-	<iso_639_entry
-		iso_639_2B_code="kpe"
-		iso_639_2T_code="kpe"
-		name="Kpelle" />
-	<iso_639_entry
-		iso_639_2B_code="krc"
-		iso_639_2T_code="krc"
-		name="Karachay-Balkar" />
-	<iso_639_entry
-		iso_639_2B_code="krl"
-		iso_639_2T_code="krl"
-		name="Karelian" />
-	<iso_639_entry
-		iso_639_2B_code="kro"
-		iso_639_2T_code="kro"
-		name="Kru languages" />
-	<iso_639_entry
-		iso_639_2B_code="kru"
-		iso_639_2T_code="kru"
-		name="Kurukh" />
-	<iso_639_entry
-		iso_639_2B_code="kua"
-		iso_639_2T_code="kua"
-		iso_639_1_code="kj"
-		name="Kuanyama; Kwanyama" />
-	<iso_639_entry
-		iso_639_2B_code="kum"
-		iso_639_2T_code="kum"
-		name="Kumyk" />
-	<iso_639_entry
-		iso_639_2B_code="kur"
-		iso_639_2T_code="kur"
-		iso_639_1_code="ku"
-		name="Kurdish" />
-	<iso_639_entry
-		iso_639_2B_code="kut"
-		iso_639_2T_code="kut"
-		name="Kutenai" />
-	<iso_639_entry
-		iso_639_2B_code="lad"
-		iso_639_2T_code="lad"
-		name="Ladino" />
-	<iso_639_entry
-		iso_639_2B_code="lah"
-		iso_639_2T_code="lah"
-		name="Lahnda" />
-	<iso_639_entry
-		iso_639_2B_code="lam"
-		iso_639_2T_code="lam"
-		name="Lamba" />
-	<iso_639_entry
-		iso_639_2B_code="lao"
-		iso_639_2T_code="lao"
-		iso_639_1_code="lo"
-		name="Lao" />
-	<iso_639_entry
-		iso_639_2B_code="lat"
-		iso_639_2T_code="lat"
-		iso_639_1_code="la"
-		name="Latin" />
-	<iso_639_entry
-		iso_639_2B_code="lav"
-		iso_639_2T_code="lav"
-		iso_639_1_code="lv"
-		name="Latvian" />
-	<iso_639_entry
-		iso_639_2B_code="lez"
-		iso_639_2T_code="lez"
-		name="Lezghian" />
-	<iso_639_entry
-		iso_639_2B_code="lim"
-		iso_639_2T_code="lim"
-		iso_639_1_code="li"
-		name="Limburgan; Limburger; Limburgish" />
-	<iso_639_entry
-		iso_639_2B_code="lin"
-		iso_639_2T_code="lin"
-		iso_639_1_code="ln"
-		name="Lingala" />
-	<iso_639_entry
-		iso_639_2B_code="lit"
-		iso_639_2T_code="lit"
-		iso_639_1_code="lt"
-		name="Lithuanian" />
-	<iso_639_entry
-		iso_639_2B_code="lol"
-		iso_639_2T_code="lol"
-		name="Mongo" />
-	<iso_639_entry
-		iso_639_2B_code="loz"
-		iso_639_2T_code="loz"
-		name="Lozi" />
-	<iso_639_entry
-		iso_639_2B_code="ltz"
-		iso_639_2T_code="ltz"
-		iso_639_1_code="lb"
-		name="Luxembourgish; Letzeburgesch" />
-	<iso_639_entry
-		iso_639_2B_code="lua"
-		iso_639_2T_code="lua"
-		name="Luba-Lulua" />
-	<iso_639_entry
-		iso_639_2B_code="lub"
-		iso_639_2T_code="lub"
-		iso_639_1_code="lu"
-		name="Luba-Katanga" />
-	<iso_639_entry
-		iso_639_2B_code="lug"
-		iso_639_2T_code="lug"
-		iso_639_1_code="lg"
-		name="Ganda" />
-	<iso_639_entry
-		iso_639_2B_code="lui"
-		iso_639_2T_code="lui"
-		name="Luiseno" />
-	<iso_639_entry
-		iso_639_2B_code="lun"
-		iso_639_2T_code="lun"
-		name="Lunda" />
-	<iso_639_entry
-		iso_639_2B_code="luo"
-		iso_639_2T_code="luo"
-		name="Luo (Kenya and Tanzania)" />
-	<iso_639_entry
-		iso_639_2B_code="lus"
-		iso_639_2T_code="lus"
-		name="Lushai" />
-	<iso_639_entry
-		iso_639_2B_code="mac"
-		iso_639_2T_code="mkd"
-		iso_639_1_code="mk"
-		name="Macedonian" />
-	<iso_639_entry
-		iso_639_2B_code="mad"
-		iso_639_2T_code="mad"
-		name="Madurese" />
-	<iso_639_entry
-		iso_639_2B_code="mag"
-		iso_639_2T_code="mag"
-		name="Magahi" />
-	<iso_639_entry
-		iso_639_2B_code="mah"
-		iso_639_2T_code="mah"
-		iso_639_1_code="mh"
-		name="Marshallese" />
-	<iso_639_entry
-		iso_639_2B_code="mai"
-		iso_639_2T_code="mai"
-		name="Maithili" />
-	<iso_639_entry
-		iso_639_2B_code="mak"
-		iso_639_2T_code="mak"
-		name="Makasar" />
-	<iso_639_entry
-		iso_639_2B_code="mal"
-		iso_639_2T_code="mal"
-		iso_639_1_code="ml"
-		name="Malayalam" />
-	<iso_639_entry
-		iso_639_2B_code="man"
-		iso_639_2T_code="man"
-		name="Mandingo" />
-	<iso_639_entry
-		iso_639_2B_code="mao"
-		iso_639_2T_code="mri"
-		iso_639_1_code="mi"
-		name="Maori" />
-	<iso_639_entry
-		iso_639_2B_code="map"
-		iso_639_2T_code="map"
-		name="Austronesian languages" />
-	<iso_639_entry
-		iso_639_2B_code="mar"
-		iso_639_2T_code="mar"
-		iso_639_1_code="mr"
-		name="Marathi" />
-	<iso_639_entry
-		iso_639_2B_code="mas"
-		iso_639_2T_code="mas"
-		name="Masai" />
-	<iso_639_entry
-		iso_639_2B_code="may"
-		iso_639_2T_code="msa"
-		iso_639_1_code="ms"
-		name="Malay" />
-	<iso_639_entry
-		iso_639_2B_code="mdf"
-		iso_639_2T_code="mdf"
-		name="Moksha" />
-	<iso_639_entry
-		iso_639_2B_code="mdr"
-		iso_639_2T_code="mdr"
-		name="Mandar" />
-	<iso_639_entry
-		iso_639_2B_code="men"
-		iso_639_2T_code="men"
-		name="Mende" />
-	<iso_639_entry
-		iso_639_2B_code="mga"
-		iso_639_2T_code="mga"
-		name="Irish, Middle (900-1200)" />
-	<iso_639_entry
-		iso_639_2B_code="mic"
-		iso_639_2T_code="mic"
-		name="Mi'kmaq; Micmac" />
-	<iso_639_entry
-		iso_639_2B_code="min"
-		iso_639_2T_code="min"
-		name="Minangkabau" />
-	<iso_639_entry
-		iso_639_2B_code="mis"
-		iso_639_2T_code="mis"
-		name="Uncoded languages" />
-	<iso_639_entry
-		iso_639_2B_code="mkh"
-		iso_639_2T_code="mkh"
-		name="Mon-Khmer languages" />
-	<iso_639_entry
-		iso_639_2B_code="mlg"
-		iso_639_2T_code="mlg"
-		iso_639_1_code="mg"
-		name="Malagasy" />
-	<iso_639_entry
-		iso_639_2B_code="mlt"
-		iso_639_2T_code="mlt"
-		iso_639_1_code="mt"
-		name="Maltese" />
-	<iso_639_entry
-		iso_639_2B_code="mnc"
-		iso_639_2T_code="mnc"
-		name="Manchu" />
-	<iso_639_entry
-		iso_639_2B_code="mni"
-		iso_639_2T_code="mni"
-		name="Manipuri" />
-	<iso_639_entry
-		iso_639_2B_code="mno"
-		iso_639_2T_code="mno"
-		name="Manobo languages" />
-	<iso_639_entry
-		iso_639_2B_code="moh"
-		iso_639_2T_code="moh"
-		name="Mohawk" />
-	<iso_639_entry
-		iso_639_2B_code="mol"
-		iso_639_2T_code="mol"
-		iso_639_1_code="mo"
-		name="Moldavian; Moldovan" />
-	<iso_639_entry
-		iso_639_2B_code="mon"
-		iso_639_2T_code="mon"
-		iso_639_1_code="mn"
-		name="Mongolian" />
-	<iso_639_entry
-		iso_639_2B_code="mos"
-		iso_639_2T_code="mos"
-		name="Mossi" />
-	<iso_639_entry
-		iso_639_2B_code="mul"
-		iso_639_2T_code="mul"
-		name="Multiple languages" />
-	<iso_639_entry
-		iso_639_2B_code="mun"
-		iso_639_2T_code="mun"
-		name="Munda languages" />
-	<iso_639_entry
-		iso_639_2B_code="mus"
-		iso_639_2T_code="mus"
-		name="Creek" />
-	<iso_639_entry
-		iso_639_2B_code="mwl"
-		iso_639_2T_code="mwl"
-		name="Mirandese" />
-	<iso_639_entry
-		iso_639_2B_code="mwr"
-		iso_639_2T_code="mwr"
-		name="Marwari" />
-	<iso_639_entry
-		iso_639_2B_code="myn"
-		iso_639_2T_code="myn"
-		name="Mayan languages" />
-	<iso_639_entry
-		iso_639_2B_code="myv"
-		iso_639_2T_code="myv"
-		name="Erzya" />
-	<iso_639_entry
-		iso_639_2B_code="nah"
-		iso_639_2T_code="nah"
-		name="Nahuatl languages" />
-	<iso_639_entry
-		iso_639_2B_code="nai"
-		iso_639_2T_code="nai"
-		name="North American Indian languages" />
-	<iso_639_entry
-		iso_639_2B_code="nap"
-		iso_639_2T_code="nap"
-		name="Neapolitan" />
-	<iso_639_entry
-		iso_639_2B_code="nau"
-		iso_639_2T_code="nau"
-		iso_639_1_code="na"
-		name="Nauru" />
-	<iso_639_entry
-		iso_639_2B_code="nav"
-		iso_639_2T_code="nav"
-		iso_639_1_code="nv"
-		name="Navajo; Navaho" />
-	<iso_639_entry
-		iso_639_2B_code="nbl"
-		iso_639_2T_code="nbl"
-		iso_639_1_code="nr"
-		name="Ndebele, South; South Ndebele" />
-	<iso_639_entry
-		iso_639_2B_code="nde"
-		iso_639_2T_code="nde"
-		iso_639_1_code="nd"
-		name="Ndebele, North; North Ndebele" />
-	<iso_639_entry
-		iso_639_2B_code="ndo"
-		iso_639_2T_code="ndo"
-		iso_639_1_code="ng"
-		name="Ndonga" />
-	<iso_639_entry
-		iso_639_2B_code="nds"
-		iso_639_2T_code="nds"
-		name="Low German; Low Saxon; German, Low; Saxon, Low" />
-	<iso_639_entry
-		iso_639_2B_code="nep"
-		iso_639_2T_code="nep"
-		iso_639_1_code="ne"
-		name="Nepali" />
-	<iso_639_entry
-		iso_639_2B_code="new"
-		iso_639_2T_code="new"
-		name="Nepal Bhasa; Newari" />
-	<iso_639_entry
-		iso_639_2B_code="nia"
-		iso_639_2T_code="nia"
-		name="Nias" />
-	<iso_639_entry
-		iso_639_2B_code="nic"
-		iso_639_2T_code="nic"
-		name="Niger-Kordofanian languages" />
-	<iso_639_entry
-		iso_639_2B_code="niu"
-		iso_639_2T_code="niu"
-		name="Niuean" />
-	<iso_639_entry
-		iso_639_2B_code="nno"
-		iso_639_2T_code="nno"
-		iso_639_1_code="nn"
-		name="Norwegian Nynorsk; Nynorsk, Norwegian" />
-	<iso_639_entry
-		iso_639_2B_code="nob"
-		iso_639_2T_code="nob"
-		iso_639_1_code="nb"
-		name="Bokmål, Norwegian; Norwegian Bokmål" />
-	<iso_639_entry
-		iso_639_2B_code="nog"
-		iso_639_2T_code="nog"
-		name="Nogai" />
-	<iso_639_entry
-		iso_639_2B_code="non"
-		iso_639_2T_code="non"
-		name="Norse, Old" />
-	<iso_639_entry
-		iso_639_2B_code="nor"
-		iso_639_2T_code="nor"
-		iso_639_1_code="no"
-		name="Norwegian" />
-	<iso_639_entry
-		iso_639_2B_code="nqo"
-		iso_639_2T_code="nqo"
-		name="N'Ko" />
-	<iso_639_entry
-		iso_639_2B_code="nso"
-		iso_639_2T_code="nso"
-		name="Pedi; Sepedi; Northern Sotho" />
-	<iso_639_entry
-		iso_639_2B_code="nub"
-		iso_639_2T_code="nub"
-		name="Nubian languages" />
-	<iso_639_entry
-		iso_639_2B_code="nwc"
-		iso_639_2T_code="nwc"
-		name="Classical Newari; Old Newari; Classical Nepal Bhasa" />
-	<iso_639_entry
-		iso_639_2B_code="nya"
-		iso_639_2T_code="nya"
-		iso_639_1_code="ny"
-		name="Chichewa; Chewa; Nyanja" />
-	<iso_639_entry
-		iso_639_2B_code="nym"
-		iso_639_2T_code="nym"
-		name="Nyamwezi" />
-	<iso_639_entry
-		iso_639_2B_code="nyn"
-		iso_639_2T_code="nyn"
-		name="Nyankole" />
-	<iso_639_entry
-		iso_639_2B_code="nyo"
-		iso_639_2T_code="nyo"
-		name="Nyoro" />
-	<iso_639_entry
-		iso_639_2B_code="nzi"
-		iso_639_2T_code="nzi"
-		name="Nzima" />
-	<iso_639_entry
-		iso_639_2B_code="oci"
-		iso_639_2T_code="oci"
-		iso_639_1_code="oc"
-		name="Occitan (post 1500)" />
-	<iso_639_entry
-		iso_639_2B_code="oji"
-		iso_639_2T_code="oji"
-		iso_639_1_code="oj"
-		name="Ojibwa" />
-	<iso_639_entry
-		iso_639_2B_code="ori"
-		iso_639_2T_code="ori"
-		iso_639_1_code="or"
-		name="Oriya" />
-	<iso_639_entry
-		iso_639_2B_code="orm"
-		iso_639_2T_code="orm"
-		iso_639_1_code="om"
-		name="Oromo" />
-	<iso_639_entry
-		iso_639_2B_code="osa"
-		iso_639_2T_code="osa"
-		name="Osage" />
-	<iso_639_entry
-		iso_639_2B_code="oss"
-		iso_639_2T_code="oss"
-		iso_639_1_code="os"
-		name="Ossetian; Ossetic" />
-	<iso_639_entry
-		iso_639_2B_code="ota"
-		iso_639_2T_code="ota"
-		name="Turkish, Ottoman (1500-1928)" />
-	<iso_639_entry
-		iso_639_2B_code="oto"
-		iso_639_2T_code="oto"
-		name="Otomian languages" />
-	<iso_639_entry
-		iso_639_2B_code="paa"
-		iso_639_2T_code="paa"
-		name="Papuan languages" />
-	<iso_639_entry
-		iso_639_2B_code="pag"
-		iso_639_2T_code="pag"
-		name="Pangasinan" />
-	<iso_639_entry
-		iso_639_2B_code="pal"
-		iso_639_2T_code="pal"
-		name="Pahlavi" />
-	<iso_639_entry
-		iso_639_2B_code="pam"
-		iso_639_2T_code="pam"
-		name="Pampanga; Kapampangan" />
-	<iso_639_entry
-		iso_639_2B_code="pan"
-		iso_639_2T_code="pan"
-		iso_639_1_code="pa"
-		name="Panjabi; Punjabi" />
-	<iso_639_entry
-		iso_639_2B_code="pap"
-		iso_639_2T_code="pap"
-		name="Papiamento" />
-	<iso_639_entry
-		iso_639_2B_code="pau"
-		iso_639_2T_code="pau"
-		name="Palauan" />
-	<iso_639_entry
-		iso_639_2B_code="peo"
-		iso_639_2T_code="peo"
-		name="Persian, Old (ca. 600-400 B.C.)" />
-	<iso_639_entry
-		iso_639_2B_code="per"
-		iso_639_2T_code="fas"
-		iso_639_1_code="fa"
-		name="Persian" />
-	<iso_639_entry
-		iso_639_2B_code="phi"
-		iso_639_2T_code="phi"
-		name="Philippine languages" />
-	<iso_639_entry
-		iso_639_2B_code="phn"
-		iso_639_2T_code="phn"
-		name="Phoenician" />
-	<iso_639_entry
-		iso_639_2B_code="pli"
-		iso_639_2T_code="pli"
-		iso_639_1_code="pi"
-		name="Pali" />
-	<iso_639_entry
-		iso_639_2B_code="pol"
-		iso_639_2T_code="pol"
-		iso_639_1_code="pl"
-		name="Polish" />
-	<iso_639_entry
-		iso_639_2B_code="pon"
-		iso_639_2T_code="pon"
-		name="Pohnpeian" />
-	<iso_639_entry
-		iso_639_2B_code="por"
-		iso_639_2T_code="por"
-		iso_639_1_code="pt"
-		name="Portuguese" />
-	<iso_639_entry
-		iso_639_2B_code="pra"
-		iso_639_2T_code="pra"
-		name="Prakrit languages" />
-	<iso_639_entry
-		iso_639_2B_code="pro"
-		iso_639_2T_code="pro"
-		name="Provençal, Old (to 1500); Occitan, Old (to 1500)" />
-	<iso_639_entry
-		iso_639_2B_code="pus"
-		iso_639_2T_code="pus"
-		iso_639_1_code="ps"
-		name="Pushto; Pashto" />
-	<iso_639_entry
-		iso_639_2B_code="qaa-qtz"
-		iso_639_2T_code="qaa-qtz"
-		name="Reserved for local use" />
-	<iso_639_entry
-		iso_639_2B_code="que"
-		iso_639_2T_code="que"
-		iso_639_1_code="qu"
-		name="Quechua" />
-	<iso_639_entry
-		iso_639_2B_code="raj"
-		iso_639_2T_code="raj"
-		name="Rajasthani" />
-	<iso_639_entry
-		iso_639_2B_code="rap"
-		iso_639_2T_code="rap"
-		name="Rapanui" />
-	<iso_639_entry
-		iso_639_2B_code="rar"
-		iso_639_2T_code="rar"
-		name="Rarotongan; Cook Islands Maori" />
-	<iso_639_entry
-		iso_639_2B_code="roa"
-		iso_639_2T_code="roa"
-		name="Romance languages" />
-	<iso_639_entry
-		iso_639_2B_code="roh"
-		iso_639_2T_code="roh"
-		iso_639_1_code="rm"
-		name="Romansh" />
-	<iso_639_entry
-		iso_639_2B_code="rom"
-		iso_639_2T_code="rom"
-		name="Romany" />
-	<iso_639_entry
-		iso_639_2B_code="rum"
-		iso_639_2T_code="ron"
-		iso_639_1_code="ro"
-		name="Romanian" />
-	<iso_639_entry
-		iso_639_2B_code="run"
-		iso_639_2T_code="run"
-		iso_639_1_code="rn"
-		name="Rundi" />
-	<iso_639_entry
-		iso_639_2B_code="rup"
-		iso_639_2T_code="rup"
-		name="Aromanian; Arumanian; Macedo-Romanian" />
-	<iso_639_entry
-		iso_639_2B_code="rus"
-		iso_639_2T_code="rus"
-		iso_639_1_code="ru"
-		name="Russian" />
-	<iso_639_entry
-		iso_639_2B_code="sad"
-		iso_639_2T_code="sad"
-		name="Sandawe" />
-	<iso_639_entry
-		iso_639_2B_code="sag"
-		iso_639_2T_code="sag"
-		iso_639_1_code="sg"
-		name="Sango" />
-	<iso_639_entry
-		iso_639_2B_code="sah"
-		iso_639_2T_code="sah"
-		name="Yakut" />
-	<iso_639_entry
-		iso_639_2B_code="sai"
-		iso_639_2T_code="sai"
-		name="South American Indian languages" />
-	<iso_639_entry
-		iso_639_2B_code="sal"
-		iso_639_2T_code="sal"
-		name="Salishan languages" />
-	<iso_639_entry
-		iso_639_2B_code="sam"
-		iso_639_2T_code="sam"
-		name="Samaritan Aramaic" />
-	<iso_639_entry
-		iso_639_2B_code="san"
-		iso_639_2T_code="san"
-		iso_639_1_code="sa"
-		name="Sanskrit" />
-	<iso_639_entry
-		iso_639_2B_code="sas"
-		iso_639_2T_code="sas"
-		name="Sasak" />
-	<iso_639_entry
-		iso_639_2B_code="sat"
-		iso_639_2T_code="sat"
-		name="Santali" />
-	<iso_639_entry
-		iso_639_2B_code="scn"
-		iso_639_2T_code="scn"
-		name="Sicilian" />
-	<iso_639_entry
-		iso_639_2B_code="sco"
-		iso_639_2T_code="sco"
-		name="Scots" />
-	<iso_639_entry
-		iso_639_2B_code="sel"
-		iso_639_2T_code="sel"
-		name="Selkup" />
-	<iso_639_entry
-		iso_639_2B_code="sem"
-		iso_639_2T_code="sem"
-		name="Semitic languages" />
-	<iso_639_entry
-		iso_639_2B_code="sga"
-		iso_639_2T_code="sga"
-		name="Irish, Old (to 900)" />
-	<iso_639_entry
-		iso_639_2B_code="sgn"
-		iso_639_2T_code="sgn"
-		name="Sign Languages" />
-	<iso_639_entry
-		iso_639_2B_code="shn"
-		iso_639_2T_code="shn"
-		name="Shan" />
-	<iso_639_entry
-		iso_639_2B_code="sid"
-		iso_639_2T_code="sid"
-		name="Sidamo" />
-	<iso_639_entry
-		iso_639_2B_code="sin"
-		iso_639_2T_code="sin"
-		iso_639_1_code="si"
-		name="Sinhala; Sinhalese" />
-	<iso_639_entry
-		iso_639_2B_code="sio"
-		iso_639_2T_code="sio"
-		name="Siouan languages" />
-	<iso_639_entry
-		iso_639_2B_code="sit"
-		iso_639_2T_code="sit"
-		name="Sino-Tibetan languages" />
-	<iso_639_entry
-		iso_639_2B_code="sla"
-		iso_639_2T_code="sla"
-		name="Slavic languages" />
-	<iso_639_entry
-		iso_639_2B_code="slo"
-		iso_639_2T_code="slk"
-		iso_639_1_code="sk"
-		name="Slovak" />
-	<iso_639_entry
-		iso_639_2B_code="slv"
-		iso_639_2T_code="slv"
-		iso_639_1_code="sl"
-		name="Slovenian" />
-	<iso_639_entry
-		iso_639_2B_code="sma"
-		iso_639_2T_code="sma"
-		name="Southern Sami" />
-	<iso_639_entry
-		iso_639_2B_code="sme"
-		iso_639_2T_code="sme"
-		iso_639_1_code="se"
-		name="Northern Sami" />
-	<iso_639_entry
-		iso_639_2B_code="smi"
-		iso_639_2T_code="smi"
-		name="Sami languages" />
-	<iso_639_entry
-		iso_639_2B_code="smj"
-		iso_639_2T_code="smj"
-		name="Lule Sami" />
-	<iso_639_entry
-		iso_639_2B_code="smn"
-		iso_639_2T_code="smn"
-		name="Inari Sami" />
-	<iso_639_entry
-		iso_639_2B_code="smo"
-		iso_639_2T_code="smo"
-		iso_639_1_code="sm"
-		name="Samoan" />
-	<iso_639_entry
-		iso_639_2B_code="sms"
-		iso_639_2T_code="sms"
-		name="Skolt Sami" />
-	<iso_639_entry
-		iso_639_2B_code="sna"
-		iso_639_2T_code="sna"
-		iso_639_1_code="sn"
-		name="Shona" />
-	<iso_639_entry
-		iso_639_2B_code="snd"
-		iso_639_2T_code="snd"
-		iso_639_1_code="sd"
-		name="Sindhi" />
-	<iso_639_entry
-		iso_639_2B_code="snk"
-		iso_639_2T_code="snk"
-		name="Soninke" />
-	<iso_639_entry
-		iso_639_2B_code="sog"
-		iso_639_2T_code="sog"
-		name="Sogdian" />
-	<iso_639_entry
-		iso_639_2B_code="som"
-		iso_639_2T_code="som"
-		iso_639_1_code="so"
-		name="Somali" />
-	<iso_639_entry
-		iso_639_2B_code="son"
-		iso_639_2T_code="son"
-		name="Songhai languages" />
-	<iso_639_entry
-		iso_639_2B_code="sot"
-		iso_639_2T_code="sot"
-		iso_639_1_code="st"
-		name="Sotho, Southern" />
-	<iso_639_entry
-		iso_639_2B_code="spa"
-		iso_639_2T_code="spa"
-		iso_639_1_code="es"
-		name="Spanish; Castilian" />
-	<iso_639_entry
-		iso_639_2B_code="srd"
-		iso_639_2T_code="srd"
-		iso_639_1_code="sc"
-		name="Sardinian" />
-	<iso_639_entry
-		iso_639_2B_code="srn"
-		iso_639_2T_code="srn"
-		name="Sranan Tongo" />
-	<iso_639_entry
-		iso_639_2B_code="srp"
-		iso_639_2T_code="srp"
-		iso_639_1_code="sr"
-		name="Serbian" />
-	<iso_639_entry
-		iso_639_2B_code="srr"
-		iso_639_2T_code="srr"
-		name="Serer" />
-	<iso_639_entry
-		iso_639_2B_code="ssa"
-		iso_639_2T_code="ssa"
-		name="Nilo-Saharan languages" />
-	<iso_639_entry
-		iso_639_2B_code="ssw"
-		iso_639_2T_code="ssw"
-		iso_639_1_code="ss"
-		name="Swati" />
-	<iso_639_entry
-		iso_639_2B_code="suk"
-		iso_639_2T_code="suk"
-		name="Sukuma" />
-	<iso_639_entry
-		iso_639_2B_code="sun"
-		iso_639_2T_code="sun"
-		iso_639_1_code="su"
-		name="Sundanese" />
-	<iso_639_entry
-		iso_639_2B_code="sus"
-		iso_639_2T_code="sus"
-		name="Susu" />
-	<iso_639_entry
-		iso_639_2B_code="sux"
-		iso_639_2T_code="sux"
-		name="Sumerian" />
-	<iso_639_entry
-		iso_639_2B_code="swa"
-		iso_639_2T_code="swa"
-		iso_639_1_code="sw"
-		name="Swahili" />
-	<iso_639_entry
-		iso_639_2B_code="swe"
-		iso_639_2T_code="swe"
-		iso_639_1_code="sv"
-		name="Swedish" />
-	<iso_639_entry
-		iso_639_2B_code="syc"
-		iso_639_2T_code="syc"
-		name="Classical Syriac" />
-	<iso_639_entry
-		iso_639_2B_code="syr"
-		iso_639_2T_code="syr"
-		name="Syriac" />
-	<iso_639_entry
-		iso_639_2B_code="tah"
-		iso_639_2T_code="tah"
-		iso_639_1_code="ty"
-		name="Tahitian" />
-	<iso_639_entry
-		iso_639_2B_code="tai"
-		iso_639_2T_code="tai"
-		name="Tai languages" />
-	<iso_639_entry
-		iso_639_2B_code="tam"
-		iso_639_2T_code="tam"
-		iso_639_1_code="ta"
-		name="Tamil" />
-	<iso_639_entry
-		iso_639_2B_code="tat"
-		iso_639_2T_code="tat"
-		iso_639_1_code="tt"
-		name="Tatar" />
-	<iso_639_entry
-		iso_639_2B_code="tel"
-		iso_639_2T_code="tel"
-		iso_639_1_code="te"
-		name="Telugu" />
-	<iso_639_entry
-		iso_639_2B_code="tem"
-		iso_639_2T_code="tem"
-		name="Timne" />
-	<iso_639_entry
-		iso_639_2B_code="ter"
-		iso_639_2T_code="ter"
-		name="Tereno" />
-	<iso_639_entry
-		iso_639_2B_code="tet"
-		iso_639_2T_code="tet"
-		name="Tetum" />
-	<iso_639_entry
-		iso_639_2B_code="tgk"
-		iso_639_2T_code="tgk"
-		iso_639_1_code="tg"
-		name="Tajik" />
-	<iso_639_entry
-		iso_639_2B_code="tgl"
-		iso_639_2T_code="tgl"
-		iso_639_1_code="tl"
-		name="Tagalog" />
-	<iso_639_entry
-		iso_639_2B_code="tha"
-		iso_639_2T_code="tha"
-		iso_639_1_code="th"
-		name="Thai" />
-	<iso_639_entry
-		iso_639_2B_code="tib"
-		iso_639_2T_code="bod"
-		iso_639_1_code="bo"
-		name="Tibetan" />
-	<iso_639_entry
-		iso_639_2B_code="tig"
-		iso_639_2T_code="tig"
-		name="Tigre" />
-	<iso_639_entry
-		iso_639_2B_code="tir"
-		iso_639_2T_code="tir"
-		iso_639_1_code="ti"
-		name="Tigrinya" />
-	<iso_639_entry
-		iso_639_2B_code="tiv"
-		iso_639_2T_code="tiv"
-		name="Tiv" />
-	<iso_639_entry
-		iso_639_2B_code="tkl"
-		iso_639_2T_code="tkl"
-		name="Tokelau" />
-	<iso_639_entry
-		iso_639_2B_code="tlh"
-		iso_639_2T_code="tlh"
-		name="Klingon; tlhIngan-Hol" />
-	<iso_639_entry
-		iso_639_2B_code="tli"
-		iso_639_2T_code="tli"
-		name="Tlingit" />
-	<iso_639_entry
-		iso_639_2B_code="tmh"
-		iso_639_2T_code="tmh"
-		name="Tamashek" />
-	<iso_639_entry
-		iso_639_2B_code="tog"
-		iso_639_2T_code="tog"
-		name="Tonga (Nyasa)" />
-	<iso_639_entry
-		iso_639_2B_code="ton"
-		iso_639_2T_code="ton"
-		iso_639_1_code="to"
-		name="Tonga (Tonga Islands)" />
-	<iso_639_entry
-		iso_639_2B_code="tpi"
-		iso_639_2T_code="tpi"
-		name="Tok Pisin" />
-	<iso_639_entry
-		iso_639_2B_code="tsi"
-		iso_639_2T_code="tsi"
-		name="Tsimshian" />
-	<iso_639_entry
-		iso_639_2B_code="tsn"
-		iso_639_2T_code="tsn"
-		iso_639_1_code="tn"
-		name="Tswana" />
-	<iso_639_entry
-		iso_639_2B_code="tso"
-		iso_639_2T_code="tso"
-		iso_639_1_code="ts"
-		name="Tsonga" />
-	<iso_639_entry
-		iso_639_2B_code="tuk"
-		iso_639_2T_code="tuk"
-		iso_639_1_code="tk"
-		name="Turkmen" />
-	<iso_639_entry
-		iso_639_2B_code="tum"
-		iso_639_2T_code="tum"
-		name="Tumbuka" />
-	<iso_639_entry
-		iso_639_2B_code="tup"
-		iso_639_2T_code="tup"
-		name="Tupi languages" />
-	<iso_639_entry
-		iso_639_2B_code="tur"
-		iso_639_2T_code="tur"
-		iso_639_1_code="tr"
-		name="Turkish" />
-	<iso_639_entry
-		iso_639_2B_code="tut"
-		iso_639_2T_code="tut"
-		name="Altaic languages" />
-	<iso_639_entry
-		iso_639_2B_code="tvl"
-		iso_639_2T_code="tvl"
-		name="Tuvalu" />
-	<iso_639_entry
-		iso_639_2B_code="twi"
-		iso_639_2T_code="twi"
-		iso_639_1_code="tw"
-		name="Twi" />
-	<iso_639_entry
-		iso_639_2B_code="tyv"
-		iso_639_2T_code="tyv"
-		name="Tuvinian" />
-	<iso_639_entry
-		iso_639_2B_code="udm"
-		iso_639_2T_code="udm"
-		name="Udmurt" />
-	<iso_639_entry
-		iso_639_2B_code="uga"
-		iso_639_2T_code="uga"
-		name="Ugaritic" />
-	<iso_639_entry
-		iso_639_2B_code="uig"
-		iso_639_2T_code="uig"
-		iso_639_1_code="ug"
-		name="Uighur; Uyghur" />
-	<iso_639_entry
-		iso_639_2B_code="ukr"
-		iso_639_2T_code="ukr"
-		iso_639_1_code="uk"
-		name="Ukrainian" />
-	<iso_639_entry
-		iso_639_2B_code="umb"
-		iso_639_2T_code="umb"
-		name="Umbundu" />
-	<iso_639_entry
-		iso_639_2B_code="und"
-		iso_639_2T_code="und"
-		name="Undetermined" />
-	<iso_639_entry
-		iso_639_2B_code="urd"
-		iso_639_2T_code="urd"
-		iso_639_1_code="ur"
-		name="Urdu" />
-	<iso_639_entry
-		iso_639_2B_code="uzb"
-		iso_639_2T_code="uzb"
-		iso_639_1_code="uz"
-		name="Uzbek" />
-	<iso_639_entry
-		iso_639_2B_code="vai"
-		iso_639_2T_code="vai"
-		name="Vai" />
-	<iso_639_entry
-		iso_639_2B_code="ven"
-		iso_639_2T_code="ven"
-		iso_639_1_code="ve"
-		name="Venda" />
-	<iso_639_entry
-		iso_639_2B_code="vie"
-		iso_639_2T_code="vie"
-		iso_639_1_code="vi"
-		name="Vietnamese" />
-	<iso_639_entry
-		iso_639_2B_code="vol"
-		iso_639_2T_code="vol"
-		iso_639_1_code="vo"
-		name="Volapük" />
-	<iso_639_entry
-		iso_639_2B_code="vot"
-		iso_639_2T_code="vot"
-		name="Votic" />
-	<iso_639_entry
-		iso_639_2B_code="wak"
-		iso_639_2T_code="wak"
-		name="Wakashan languages" />
-	<iso_639_entry
-		iso_639_2B_code="wal"
-		iso_639_2T_code="wal"
-		name="Wolaitta; Wolaytta" />
-	<iso_639_entry
-		iso_639_2B_code="war"
-		iso_639_2T_code="war"
-		name="Waray" />
-	<iso_639_entry
-		iso_639_2B_code="was"
-		iso_639_2T_code="was"
-		name="Washo" />
-	<iso_639_entry
-		iso_639_2B_code="wel"
-		iso_639_2T_code="cym"
-		iso_639_1_code="cy"
-		name="Welsh" />
-	<iso_639_entry
-		iso_639_2B_code="wen"
-		iso_639_2T_code="wen"
-		name="Sorbian languages" />
-	<iso_639_entry
-		iso_639_2B_code="wln"
-		iso_639_2T_code="wln"
-		iso_639_1_code="wa"
-		name="Walloon" />
-	<iso_639_entry
-		iso_639_2B_code="wol"
-		iso_639_2T_code="wol"
-		iso_639_1_code="wo"
-		name="Wolof" />
-	<iso_639_entry
-		iso_639_2B_code="xal"
-		iso_639_2T_code="xal"
-		name="Kalmyk; Oirat" />
-	<iso_639_entry
-		iso_639_2B_code="xho"
-		iso_639_2T_code="xho"
-		iso_639_1_code="xh"
-		name="Xhosa" />
-	<iso_639_entry
-		iso_639_2B_code="yao"
-		iso_639_2T_code="yao"
-		name="Yao" />
-	<iso_639_entry
-		iso_639_2B_code="yap"
-		iso_639_2T_code="yap"
-		name="Yapese" />
-	<iso_639_entry
-		iso_639_2B_code="yid"
-		iso_639_2T_code="yid"
-		iso_639_1_code="yi"
-		name="Yiddish" />
-	<iso_639_entry
-		iso_639_2B_code="yor"
-		iso_639_2T_code="yor"
-		iso_639_1_code="yo"
-		name="Yoruba" />
-	<iso_639_entry
-		iso_639_2B_code="ypk"
-		iso_639_2T_code="ypk"
-		name="Yupik languages" />
-	<iso_639_entry
-		iso_639_2B_code="zap"
-		iso_639_2T_code="zap"
-		name="Zapotec" />
-	<iso_639_entry
-		iso_639_2B_code="zbl"
-		iso_639_2T_code="zbl"
-		name="Blissymbols; Blissymbolics; Bliss" />
-	<iso_639_entry
-		iso_639_2B_code="zen"
-		iso_639_2T_code="zen"
-		name="Zenaga" />
-	<iso_639_entry
-		iso_639_2B_code="zha"
-		iso_639_2T_code="zha"
-		iso_639_1_code="za"
-		name="Zhuang; Chuang" />
-	<iso_639_entry
-		iso_639_2B_code="znd"
-		iso_639_2T_code="znd"
-		name="Zande languages" />
-	<iso_639_entry
-		iso_639_2B_code="zul"
-		iso_639_2T_code="zul"
-		iso_639_1_code="zu"
-		name="Zulu" />
-	<iso_639_entry
-		iso_639_2B_code="zun"
-		iso_639_2T_code="zun"
-		name="Zuni" />
-	<iso_639_entry
-		iso_639_2B_code="zxx"
-		iso_639_2T_code="zxx"
-		name="No linguistic content; Not applicable" />
-	<iso_639_entry
-		iso_639_2B_code="zza"
-		iso_639_2T_code="zza"
-		name="Zaza; Dimili; Dimli; Kirdki; Kirmanjki; Zazaki" />
-</iso_639_entries>
diff --git a/win32/xchat-wdk-x64.skel.iss b/win32/xchat-wdk-x64.skel.iss
deleted file mode 100644
index 1caf8198..00000000
--- a/win32/xchat-wdk-x64.skel.iss
+++ /dev/null
@@ -1,279 +0,0 @@
-AppName=XChat-WDK (x64)
-AppPublisher=XChat-WDK
-AppPublisherURL=http://www.xchat-wdk.org/
-AppCopyright=Copyright (C) 1998-2010 Peter Zelezny
-AppSupportURL=http://code.google.com/p/xchat-wdk/issues/list
-AppUpdatesURL=http://www.xchat-wdk.org/home/downloads
-LicenseFile=COPYING
-UninstallDisplayIcon={app}\xchat.exe
-UninstallDisplayName=XChat-WDK (x64)
-DefaultDirName={pf}\XChat-WDK
-DefaultGroupName=XChat-WDK
-DisableProgramGroupPage=yes
-SolidCompression=yes
-SourceDir=dist-x64
-OutputDir=..\
-FlatComponentsList=no
-PrivilegesRequired=none
-ShowComponentSizes=no
-CreateUninstallRegKey=not IsTaskSelected('portable')
-Uninstallable=not IsTaskSelected('portable')
-ArchitecturesAllowed=x64
-ArchitecturesInstallIn64BitMode=x64
-
-[Types]
-Name: "normal"; Description: "Normal Installation"
-Name: "full"; Description: "Full Installation"
-Name: "minimal"; Description: "Minimal Installation"
-Name: "custom"; Description: "Custom Installation"; Flags: iscustom
-
-[Components]
-Name: "libs"; Description: "XChat-WDK"; Types: normal full minimal custom; Flags: fixed
-Name: "xctext"; Description: "XChat-Text"; Types: full custom; Flags: disablenouninstallwarning
-Name: "translations"; Description: "Translations"; Types: normal full custom; Flags: disablenouninstallwarning
-;obs Name: "gtkengines"; Description: "GTK+ Engines"; Types: full custom; Flags: disablenouninstallwarning
-;Name: "spelling"; Description: "Spelling Dictionaries"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins"; Description: "Plugins"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\checksum"; Description: "Checksum"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\dns"; Description: "DNS"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\doat"; Description: "Do At"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\exec"; Description: "Exec"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\fishlim"; Description: "FiSHLiM"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\mpcinfo"; Description: "mpcInfo"; Types: full custom; Flags: disablenouninstallwarning
-;Name: "plugins\nonbmp"; Description: "Non-BMP"; Types: normal full custom; Flags: disablenouninstallwarning
-Name: "plugins\upd"; Description: "Update Checker"; Types: normal full custom; Flags: disablenouninstallwarning
-Name: "plugins\winamp"; Description: "Winamp"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\winsys"; Description: "WinSys"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\wmpa"; Description: "Windows Media Player Announcer"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\xsasl"; Description: "X-SASL"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\xtray"; Description: "X-Tray"; Types: full custom; Flags: disablenouninstallwarning
-Name: "langs"; Description: "Language Interfaces"; Types: full custom; Flags: disablenouninstallwarning
-Name: "langs\lua"; Description: "Lua"; Types: full custom; Flags: disablenouninstallwarning
-Name: "langs\lua\luawdk"; Description: "Lua-WDK"; Types: full custom; Flags: disablenouninstallwarning
-Name: "langs\perl"; Description: "Perl"; Types: full custom; Flags: disablenouninstallwarning
-Name: "langs\python"; Description: "Python"; Types: full custom; Flags: disablenouninstallwarning
-Name: "langs\tcl"; Description: "Tcl"; Types: full custom; Flags: disablenouninstallwarning
-
-[Tasks]
-Name: portable; Description: "Yes"; GroupDescription: "Portable Install (no Registry entries, no Start Menu icons, no uninstaller):"; Flags: unchecked
-
-Name: perl512; Description: "5.12"; GroupDescription: "Perl version:"; Flags: exclusive; Components: langs\perl
-Name: perl514; Description: "5.14"; GroupDescription: "Perl version:"; Flags: exclusive unchecked; Components: langs\perl
-
-[Registry]
-Root: HKCR; Subkey: "irc"; ValueType: none; ValueName: ""; ValueData: ""; Flags: deletekey uninsdeletekey; Tasks: not portable
-Root: HKCR; Subkey: "irc"; ValueType: string; ValueName: ""; ValueData: "URL:IRC Protocol"; Flags: uninsdeletevalue; Tasks: not portable
-Root: HKCR; Subkey: "irc"; ValueType: string; ValueName: "URL Protocol"; ValueData: ""; Flags: uninsdeletevalue; Tasks: not portable
-Root: HKCR; Subkey: "irc\DefaultIcon"; ValueType: string; ValueName: ""; ValueData: "{app}\xchat.exe,0"; Flags: uninsdeletevalue; Tasks: not portable
-Root: HKCR; Subkey: "irc\shell"; ValueType: string; ValueName: ""; ValueData: "open"; Flags: uninsdeletevalue; Tasks: not portable
-Root: HKCR; Subkey: "irc\shell\open\command"; ValueType: string; ValueName: ""; ValueData: "{app}\xchat.exe --url=""%1"""; Flags: uninsdeletevalue; Tasks: not portable
-
-[Run]
-Filename: "{app}\xchat.exe"; Description: "Run XChat-WDK after closing the Wizard"; Flags: nowait postinstall skipifsilent
-
-[Files]
-; Add the ISSkin DLL used for skinning Inno Setup installations.
-Source: ISSkinU.dll; DestDir: {app}; Flags: dontcopy
-
-; Add the Visual Style resource contains resources used for skinning,
-; you can also use Microsoft Visual Styles (*.msstyles) resources.
-Source: watercolorlite-blue.cjstyles; DestDir: {tmp}; Flags: dontcopy
-
-Source: "portable-mode"; DestDir: "{app}"; Tasks: portable
-
-Source: "cert.pem"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "COPYING"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "LICENSE.OPENSSL"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "LICENSE.ZLIB"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "LICENSE.GTK"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "LICENSE.CAIRO"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "LICENSE.LUA"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "LICENSE.ENCHANT"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "LICENSE.LIBXML"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "etc\gtk-2.0\gtkrc"; DestDir: "{app}\etc\gtk-2.0"; Flags: ignoreversion; Components: libs
-;Source: "etc\gtk-2.0\gtkrc"; DestDir: "{app}\etc\gtk-2.0"; Flags: ignoreversion; Components: libs and not gtkengines
-Source: "share\xml\*"; DestDir: "{app}\share\xml"; Flags: ignoreversion createallsubdirs recursesubdirs; Components: libs
-Source: "locale\*"; DestDir: "{app}\locale"; Flags: ignoreversion createallsubdirs recursesubdirs; Components: translations
-Source: "share\locale\*"; DestDir: "{app}\share\locale"; Flags: ignoreversion createallsubdirs recursesubdirs; Components: translations
-;Source: "share\myspell\*"; DestDir: "{app}\share\myspell"; Flags: ignoreversion createallsubdirs recursesubdirs; Components: spelling
-
-Source: "libatk-1.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libcairo-2.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libeay32.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libexpat-1.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-;obs Source: "libffi-5.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libfreetype-6.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libfontconfig-1.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libgdk_pixbuf-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libgdk-win32-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libgio-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libglib-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libgmodule-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libgobject-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libgthread-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libgtk-win32-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libintl-8.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-;obs Source: "libjasper-1.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-;obs Source: "libjpeg-8.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libpango-1.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libpangocairo-1.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libpangoft2-1.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libpangowin32-1.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-;obs Source: "libpixman-1-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-;obs Source: "libtiff-3.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libpng14-14.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-;obs Source: "libpng15-15.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "lua51.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "ssleay32.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "zlib1.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libxml2.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-;obs Source: "libxml2-2.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libenchant.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-
-Source: "lib\enchant\libenchant_myspell.dll"; DestDir: "{app}\lib\enchant"; Flags: ignoreversion; Components: libs
-
-Source: "lib\gtk-2.0\2.10.0\engines\libpixmap.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: libs
-Source: "lib\gtk-2.0\2.10.0\engines\libwimp.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: libs
-Source: "lib\gtk-2.0\modules\libgail.dll"; DestDir: "{app}\lib\gtk-2.0\modules"; Flags: ignoreversion; Components: libs
-
-;obs Source: "etc\gtkpref.png"; DestDir: "{app}\etc"; Flags: ignoreversion; Components: gtkengines
-;obs Source: "lib\gtk-2.0\2.10.0\engines\libclearlooks.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
-;obs Source: "lib\gtk-2.0\2.10.0\engines\libcrux-engine.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
-;obs Source: "lib\gtk-2.0\2.10.0\engines\libglide.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
-;obs Source: "lib\gtk-2.0\2.10.0\engines\libhcengine.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
-;obs Source: "lib\gtk-2.0\2.10.0\engines\libindustrial.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
-;obs Source: "lib\gtk-2.0\2.10.0\engines\libmist.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
-;obs Source: "lib\gtk-2.0\2.10.0\engines\libmurrine.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
-;obs Source: "lib\gtk-2.0\2.10.0\engines\libredmond95.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
-;obs Source: "lib\gtk-2.0\2.10.0\engines\libthinice.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
-;obs Source: "plugins\xcgtkpref.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: gtkengines
-;obs Source: "share\themes\*"; DestDir: "{app}\share\themes"; Flags: ignoreversion createallsubdirs recursesubdirs; Components: gtkengines
-;obs Source: "gtk2-prefs.exe"; DestDir: "{app}"; Flags: ignoreversion; Components: gtkengines
-
-Source: "plugins\xcchecksum.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\checksum
-Source: "plugins\xcdns.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\dns
-Source: "plugins\xcdoat.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\doat
-Source: "plugins\xcexec.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\exec
-Source: "plugins\xcfishlim.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\fishlim
-Source: "etc\music.png"; DestDir: "{app}\etc"; Flags: ignoreversion; Components: plugins\winamp or plugins\mpcinfo
-Source: "plugins\xcmpcinfo.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\mpcinfo
-;Source: "plugins\xcnonbmp.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\nonbmp
-Source: "etc\download.png"; DestDir: "{app}\etc"; Flags: ignoreversion; Components: plugins\upd
-Source: "plugins\xcupd.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\upd
-Source: "plugins\xcwinamp.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\winamp
-Source: "etc\system.png"; DestDir: "{app}\etc"; Flags: ignoreversion; Components: plugins\winsys
-Source: "plugins\xcwinsys.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\winsys
-Source: "plugins\xcxsasl.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\xsasl
-Source: "plugins\xtray.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\xtray
-Source: "plugins\xcwmpa.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\wmpa
-
-Source: "plugins\xclua.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: langs\lua
-Source: "plugins\xcpython.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: langs\python
-Source: "plugins\xctcl.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: langs\tcl
-
-Source: "plugins\xcperl-512.dll"; DestDir: "{app}\plugins"; DestName: "xcperl.dll"; Flags: ignoreversion; Components: langs\perl; Tasks: perl512
-Source: "plugins\xcperl-514.dll"; DestDir: "{app}\plugins"; DestName: "xcperl.dll"; Flags: ignoreversion; Components: langs\perl; Tasks: perl514
-
-Source: "xchat.exe"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "xchat-text.exe"; DestDir: "{app}"; Flags: ignoreversion; Components: xctext
-
-[Icons]
-Name: "{group}\XChat-WDK (x64)"; Filename: "{app}\xchat.exe"; Tasks: not portable
-Name: "{group}\XChat-Text (x64)"; Filename: "{app}\xchat-text.exe"; Components: xctext; Tasks: not portable
-Name: "{group}\Uninstall XChat-WDK (x64)"; Filename: "{uninstallexe}"; Tasks: not portable
-
-[Messages]
-BeveledLabel= XChat-WDK
-
-[Code]
-/////////////////////////////////////////////////////////////////////
-// these are required for x86->x64 or reverse upgrades
-/////////////////////////////////////////////////////////////////////
-function GetUninstallString(): String;
-var
-	sUnInstPath: String;
-	sUnInstallString: String;
-begin
-	sUnInstPath := ExpandConstant('Software\Microsoft\Windows\CurrentVersion\Uninstall\XChat-WDK (x64)_is1');
-	sUnInstallString := '';
-	if not RegQueryStringValue(HKLM, sUnInstPath, 'UninstallString', sUnInstallString) then
-		RegQueryStringValue(HKCU, sUnInstPath, 'UninstallString', sUnInstallString);
-	Result := sUnInstallString;
-end;
-
-
-/////////////////////////////////////////////////////////////////////
-function IsUpgrade(): Boolean;
-begin
-	Result := (GetUninstallString() <> '');
-end;
-
-
-/////////////////////////////////////////////////////////////////////
-function UnInstallOldVersion(): Integer;
-var
-	sUnInstallString: String;
-	iResultCode: Integer;
-begin
-// Return Values:
-// 1 - uninstall string is empty
-// 2 - error executing the UnInstallString
-// 3 - successfully executed the UnInstallString
-
-	// default return value
-	Result := 0;
-
-	// get the uninstall string of the old app
-	sUnInstallString := GetUninstallString();
-	if sUnInstallString <> '' then begin
-		sUnInstallString := RemoveQuotes(sUnInstallString);
-		if Exec(sUnInstallString, '/SILENT /NORESTART /SUPPRESSMSGBOXES','', SW_HIDE, ewWaitUntilTerminated, iResultCode) then
-			Result := 3
-		else
-			Result := 2;
-	end else
-		Result := 1;
-end;
-
-/////////////////////////////////////////////////////////////////////
-procedure CurStepChanged(CurStep: TSetupStep);
-begin
-	if not (IsTaskSelected('portable')) then
-	begin
-		if (CurStep=ssInstall) then
-		begin
-			if (IsUpgrade()) then
-			begin
-				UnInstallOldVersion();
-			end;
-		end;
-	end;
-end;
-
-/////////////////////////////////////////////////////////////////////
-// Importing LoadSkin API from ISSkin.DLL
-procedure LoadSkin(lpszPath: String; lpszIniFileName: String);
-external 'LoadSkin@files:isskinu.dll stdcall';
-
-// Importing UnloadSkin API from ISSkin.DLL
-procedure UnloadSkin();
-external 'UnloadSkin@files:isskinu.dll stdcall';
-
-// Importing ShowWindow Windows API from User32.DLL
-function ShowWindow(hWnd: Integer; uType: Integer): Integer;
-external 'ShowWindow@user32.dll stdcall';
-
-function InitializeSetup(): Boolean;
-begin
-  ExtractTemporaryFile('watercolorlite-blue.cjstyles');
-  LoadSkin(ExpandConstant('{tmp}\watercolorlite-blue.cjstyles'), '');
-  Result := True;
-end;
-
-procedure DeinitializeSetup();
-begin
-  // Hide Window before unloading skin so user does not get
-  // a glimpse of an unskinned window before it is closed.
-  ShowWindow(StrToInt(ExpandConstant('{wizardhwnd}')), 0);
-  UnloadSkin();
-end;
diff --git a/win32/xchat-wdk-x86.skel.iss b/win32/xchat-wdk-x86.skel.iss
deleted file mode 100644
index 511a29f8..00000000
--- a/win32/xchat-wdk-x86.skel.iss
+++ /dev/null
@@ -1,282 +0,0 @@
-AppName=XChat-WDK (x86)
-AppPublisher=XChat-WDK
-AppPublisherURL=http://www.xchat-wdk.org/
-AppCopyright=Copyright (C) 1998-2010 Peter Zelezny
-AppSupportURL=http://code.google.com/p/xchat-wdk/issues/list
-AppUpdatesURL=http://www.xchat-wdk.org/home/downloads
-LicenseFile=COPYING
-UninstallDisplayIcon={app}\xchat.exe
-UninstallDisplayName=XChat-WDK (x86)
-DefaultDirName={pf}\XChat-WDK
-DefaultGroupName=XChat-WDK
-DisableProgramGroupPage=yes
-SolidCompression=yes
-SourceDir=dist\Win32
-OutputDir=..\
-FlatComponentsList=no
-PrivilegesRequired=none
-ShowComponentSizes=no
-CreateUninstallRegKey=not IsTaskSelected('portable')
-Uninstallable=not IsTaskSelected('portable')
-ArchitecturesAllowed=x86 x64
-
-[Types]
-Name: "normal"; Description: "Normal Installation"
-Name: "full"; Description: "Full Installation"
-Name: "minimal"; Description: "Minimal Installation"
-Name: "custom"; Description: "Custom Installation"; Flags: iscustom
-
-[Components]
-Name: "libs"; Description: "XChat-WDK"; Types: normal full minimal custom; Flags: fixed
-Name: "xctext"; Description: "XChat-Text"; Types: full custom; Flags: disablenouninstallwarning
-Name: "translations"; Description: "Translations"; Types: normal full custom; Flags: disablenouninstallwarning
-;obs Name: "gtkengines"; Description: "GTK+ Engines"; Types: full custom; Flags: disablenouninstallwarning
-;Name: "spelling"; Description: "Spelling Dictionaries"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins"; Description: "Plugins"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\checksum"; Description: "Checksum"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\dns"; Description: "DNS"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\doat"; Description: "Do At"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\exec"; Description: "Exec"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\fishlim"; Description: "FiSHLiM"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\mpcinfo"; Description: "mpcInfo"; Types: full custom; Flags: disablenouninstallwarning
-;Name: "plugins\nonbmp"; Description: "Non-BMP"; Types: normal full custom; Flags: disablenouninstallwarning
-Name: "plugins\upd"; Description: "Update Checker"; Types: normal full custom; Flags: disablenouninstallwarning
-Name: "plugins\winamp"; Description: "Winamp"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\winsys"; Description: "WinSys"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\wmpa"; Description: "Windows Media Player Announcer"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\xsasl"; Description: "X-SASL"; Types: full custom; Flags: disablenouninstallwarning
-Name: "plugins\xtray"; Description: "X-Tray"; Types: full custom; Flags: disablenouninstallwarning
-Name: "langs"; Description: "Language Interfaces"; Types: full custom; Flags: disablenouninstallwarning
-Name: "langs\lua"; Description: "Lua"; Types: full custom; Flags: disablenouninstallwarning
-Name: "langs\lua\luawdk"; Description: "Lua-WDK"; Types: full custom; Flags: disablenouninstallwarning
-Name: "langs\perl"; Description: "Perl"; Types: full custom; Flags: disablenouninstallwarning
-Name: "langs\python"; Description: "Python"; Types: full custom; Flags: disablenouninstallwarning
-Name: "langs\tcl"; Description: "Tcl"; Types: full custom; Flags: disablenouninstallwarning
-
-[Tasks]
-Name: portable; Description: "Yes"; GroupDescription: "Portable Install (no Registry entries, no Start Menu icons, no uninstaller):"; Flags: unchecked
-
-Name: perl512; Description: "5.12"; GroupDescription: "Perl version:"; Flags: exclusive; Components: langs\perl
-Name: perl514; Description: "5.14"; GroupDescription: "Perl version:"; Flags: exclusive unchecked; Components: langs\perl
-Name: perl516; Description: "5.16"; GroupDescription: "Perl version:"; Flags: exclusive unchecked; Components: langs\perl
-
-[Registry]
-Root: HKCR; Subkey: "irc"; ValueType: none; ValueName: ""; ValueData: ""; Flags: deletekey uninsdeletekey; Tasks: not portable
-Root: HKCR; Subkey: "irc"; ValueType: string; ValueName: ""; ValueData: "URL:IRC Protocol"; Flags: uninsdeletevalue; Tasks: not portable
-Root: HKCR; Subkey: "irc"; ValueType: string; ValueName: "URL Protocol"; ValueData: ""; Flags: uninsdeletevalue; Tasks: not portable
-Root: HKCR; Subkey: "irc\DefaultIcon"; ValueType: string; ValueName: ""; ValueData: "{app}\xchat.exe,0"; Flags: uninsdeletevalue; Tasks: not portable
-Root: HKCR; Subkey: "irc\shell"; ValueType: string; ValueName: ""; ValueData: "open"; Flags: uninsdeletevalue; Tasks: not portable
-Root: HKCR; Subkey: "irc\shell\open\command"; ValueType: string; ValueName: ""; ValueData: "{app}\xchat.exe --url=""%1"""; Flags: uninsdeletevalue; Tasks: not portable
-
-[Run]
-Filename: "{app}\xchat.exe"; Description: "Run XChat-WDK after closing the Wizard"; Flags: nowait postinstall skipifsilent
-
-[Files]
-; Add the ISSkin DLL used for skinning Inno Setup installations.
-Source: ISSkinU.dll; DestDir: {app}; Flags: dontcopy
-
-; Add the Visual Style resource contains resources used for skinning,
-; you can also use Microsoft Visual Styles (*.msstyles) resources.
-Source: watercolorlite-green.cjstyles; DestDir: {tmp}; Flags: dontcopy
-
-Source: "portable-mode"; DestDir: "{app}"; Tasks: portable
-
-Source: "cert.pem"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "COPYING"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "LICENSE.OPENSSL"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "LICENSE.ZLIB"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "LICENSE.GTK"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "LICENSE.CAIRO"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "LICENSE.LUA"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "LICENSE.ENCHANT"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "LICENSE.LIBXML"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "etc\gtk-2.0\gtkrc"; DestDir: "{app}\etc\gtk-2.0"; Flags: ignoreversion; Components: libs
-;Source: "etc\gtk-2.0\gtkrc"; DestDir: "{app}\etc\gtk-2.0"; Flags: ignoreversion; Components: libs and not gtkengines
-Source: "share\xml\*"; DestDir: "{app}\share\xml"; Flags: ignoreversion createallsubdirs recursesubdirs; Components: libs
-Source: "locale\*"; DestDir: "{app}\locale"; Flags: ignoreversion createallsubdirs recursesubdirs; Components: translations
-Source: "share\locale\*"; DestDir: "{app}\share\locale"; Flags: ignoreversion createallsubdirs recursesubdirs; Components: translations
-;Source: "share\myspell\*"; DestDir: "{app}\share\myspell"; Flags: ignoreversion createallsubdirs recursesubdirs; Components: spelling
-
-Source: "libatk-1.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libcairo-2.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libeay32.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libexpat-1.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-;obs Source: "libffi-5.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "freetype6.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-;obs Source: "libfreetype-6.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libfontconfig-1.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libgdk_pixbuf-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libgdk-win32-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libgio-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libglib-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libgmodule-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libgobject-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libgthread-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libgtk-win32-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "intl.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-;obs Source: "libintl-8.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-;obs Source: "libjasper-1.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-;obs Source: "libjpeg-8.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libpango-1.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libpangocairo-1.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libpangoft2-1.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libpangowin32-1.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-;obs Source: "libpixman-1-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-;obs Source: "libtiff-3.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libpng14-14.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-;obs Source: "libpng15-15.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "lua51.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "ssleay32.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "zlib1.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libxml2.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-;obs Source: "libxml2-2.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "libenchant.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-
-Source: "lib\enchant\libenchant_myspell.dll"; DestDir: "{app}\lib\enchant"; Flags: ignoreversion; Components: libs
-
-Source: "lib\gtk-2.0\2.10.0\engines\libpixmap.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: libs
-Source: "lib\gtk-2.0\2.10.0\engines\libwimp.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: libs
-Source: "lib\gtk-2.0\modules\libgail.dll"; DestDir: "{app}\lib\gtk-2.0\modules"; Flags: ignoreversion; Components: libs
-
-;obs Source: "etc\gtkpref.png"; DestDir: "{app}\etc"; Flags: ignoreversion; Components: gtkengines
-;obs Source: "lib\gtk-2.0\2.10.0\engines\libclearlooks.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
-;obs Source: "lib\gtk-2.0\2.10.0\engines\libcrux-engine.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
-;obs Source: "lib\gtk-2.0\2.10.0\engines\libglide.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
-;obs Source: "lib\gtk-2.0\2.10.0\engines\libhcengine.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
-;obs Source: "lib\gtk-2.0\2.10.0\engines\libindustrial.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
-;obs Source: "lib\gtk-2.0\2.10.0\engines\libmist.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
-;obs Source: "lib\gtk-2.0\2.10.0\engines\libmurrine.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
-;obs Source: "lib\gtk-2.0\2.10.0\engines\libredmond95.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
-;obs Source: "lib\gtk-2.0\2.10.0\engines\libthinice.dll"; DestDir: "{app}\lib\gtk-2.0\2.10.0\engines"; Flags: ignoreversion; Components: gtkengines
-;obs Source: "plugins\xcgtkpref.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: gtkengines
-;obs Source: "share\themes\*"; DestDir: "{app}\share\themes"; Flags: ignoreversion createallsubdirs recursesubdirs; Components: gtkengines
-;obs Source: "gtk2-prefs.exe"; DestDir: "{app}"; Flags: ignoreversion; Components: gtkengines
-
-Source: "plugins\xcchecksum.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\checksum
-Source: "plugins\xcdns.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\dns
-Source: "plugins\xcdoat.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\doat
-Source: "plugins\xcexec.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\exec
-Source: "plugins\xcfishlim.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\fishlim
-Source: "etc\music.png"; DestDir: "{app}\etc"; Flags: ignoreversion; Components: plugins\winamp or plugins\mpcinfo
-Source: "plugins\xcmpcinfo.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\mpcinfo
-;Source: "plugins\xcnonbmp.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\nonbmp
-Source: "etc\download.png"; DestDir: "{app}\etc"; Flags: ignoreversion; Components: plugins\upd
-Source: "plugins\xcupd.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\upd
-Source: "plugins\xcwinamp.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\winamp
-Source: "etc\system.png"; DestDir: "{app}\etc"; Flags: ignoreversion; Components: plugins\winsys
-Source: "plugins\xcwinsys.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\winsys
-Source: "plugins\xcxsasl.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\xsasl
-Source: "plugins\xtray.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\xtray
-Source: "plugins\xcwmpa.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: plugins\wmpa
-
-Source: "plugins\xclua.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: langs\lua
-Source: "plugins\xcpython.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: langs\python
-Source: "plugins\xctcl.dll"; DestDir: "{app}\plugins"; Flags: ignoreversion; Components: langs\tcl
-
-Source: "plugins\xcperl-512.dll"; DestDir: "{app}\plugins"; DestName: "xcperl.dll"; Flags: ignoreversion; Components: langs\perl; Tasks: perl512
-Source: "plugins\xcperl-514.dll"; DestDir: "{app}\plugins"; DestName: "xcperl.dll"; Flags: ignoreversion; Components: langs\perl; Tasks: perl514
-Source: "plugins\xcperl-516.dll"; DestDir: "{app}\plugins"; DestName: "xcperl.dll"; Flags: ignoreversion; Components: langs\perl; Tasks: perl516
-
-Source: "xchat.exe"; DestDir: "{app}"; Flags: ignoreversion; Components: libs
-Source: "xchat-text.exe"; DestDir: "{app}"; Flags: ignoreversion; Components: xctext
-
-[Icons]
-Name: "{group}\XChat-WDK (x86)"; Filename: "{app}\xchat.exe"; Tasks: not portable
-Name: "{group}\XChat-Text (x86)"; Filename: "{app}\xchat-text.exe"; Components: xctext; Tasks: not portable
-Name: "{group}\Uninstall XChat-WDK (x86)"; Filename: "{uninstallexe}"; Tasks: not portable
-
-[Messages]
-BeveledLabel= XChat-WDK
-
-[Code]
-/////////////////////////////////////////////////////////////////////
-// these are required for x86->x64 or reverse upgrades
-/////////////////////////////////////////////////////////////////////
-function GetUninstallString(): String;
-var
-	sUnInstPath: String;
-	sUnInstallString: String;
-begin
-	sUnInstPath := ExpandConstant('Software\Microsoft\Windows\CurrentVersion\Uninstall\XChat-WDK (x86)_is1');
-	sUnInstallString := '';
-	if not RegQueryStringValue(HKLM, sUnInstPath, 'UninstallString', sUnInstallString) then
-		RegQueryStringValue(HKCU, sUnInstPath, 'UninstallString', sUnInstallString);
-	Result := sUnInstallString;
-end;
-
-
-/////////////////////////////////////////////////////////////////////
-function IsUpgrade(): Boolean;
-begin
-	Result := (GetUninstallString() <> '');
-end;
-
-
-/////////////////////////////////////////////////////////////////////
-function UnInstallOldVersion(): Integer;
-var
-	sUnInstallString: String;
-	iResultCode: Integer;
-begin
-// Return Values:
-// 1 - uninstall string is empty
-// 2 - error executing the UnInstallString
-// 3 - successfully executed the UnInstallString
-
-	// default return value
-	Result := 0;
-
-	// get the uninstall string of the old app
-	sUnInstallString := GetUninstallString();
-	if sUnInstallString <> '' then begin
-		sUnInstallString := RemoveQuotes(sUnInstallString);
-		if Exec(sUnInstallString, '/SILENT /NORESTART /SUPPRESSMSGBOXES','', SW_HIDE, ewWaitUntilTerminated, iResultCode) then
-			Result := 3
-		else
-			Result := 2;
-	end else
-		Result := 1;
-end;
-
-/////////////////////////////////////////////////////////////////////
-procedure CurStepChanged(CurStep: TSetupStep);
-begin
-	if not (IsTaskSelected('portable')) then
-	begin
-		if (CurStep=ssInstall) then
-		begin
-			if (IsUpgrade()) then
-			begin
-				UnInstallOldVersion();
-			end;
-		end;
-	end;
-end;
-
-/////////////////////////////////////////////////////////////////////
-// Importing LoadSkin API from ISSkin.DLL
-procedure LoadSkin(lpszPath: String; lpszIniFileName: String);
-external 'LoadSkin@files:isskinu.dll stdcall';
-
-// Importing UnloadSkin API from ISSkin.DLL
-procedure UnloadSkin();
-external 'UnloadSkin@files:isskinu.dll stdcall';
-
-// Importing ShowWindow Windows API from User32.DLL
-function ShowWindow(hWnd: Integer; uType: Integer): Integer;
-external 'ShowWindow@user32.dll stdcall';
-
-function InitializeSetup(): Boolean;
-begin
-  ExtractTemporaryFile('watercolorlite-green.cjstyles');
-  LoadSkin(ExpandConstant('{tmp}\watercolorlite-green.cjstyles'), '');
-  Result := True;
-end;
-
-procedure DeinitializeSetup();
-begin
-  // Hide Window before unloading skin so user does not get
-  // a glimpse of an unskinned window before it is closed.
-  ShowWindow(StrToInt(ExpandConstant('{wizardhwnd}')), 0);
-  UnloadSkin();
-end;
diff --git a/win32/xchat.props b/win32/xchat.props
index e0aa21c8..3038fb04 100644
--- a/win32/xchat.props
+++ b/win32/xchat.props
@@ -35,7 +35,7 @@
     <Gtk>$(DepsRoot)\include\gtk-2.0;$(DepsRoot)\lib\gtk-2.0\include;$(DepsRoot)\include\atk-1.0;$(DepsRoot)\include\cairo;$(DepsRoot)\include\pango-1.0;$(DepsRoot)\include\gdk-pixbuf-2.0</Gtk>
     <Pixmaps>bookpng "$(SolutionDir)\..\src\pixmaps\book.png" hoppng "$(SolutionDir)\..\src\pixmaps\hop.png" oppng "$(SolutionDir)\..\src\pixmaps\op.png" purplepng "$(SolutionDir)\..\src\pixmaps\purple.png" redpng "$(SolutionDir)\..\src\pixmaps\red.png" trayfilepng "$(SolutionDir)\..\src\pixmaps\fileoffer.png" trayhilightpng "$(SolutionDir)\..\src\pixmaps\highlight.png" traymsgpng "$(SolutionDir)\..\src\pixmaps\message.png" voicepng "$(SolutionDir)\..\src\pixmaps\voice.png" xchatpng "$(SolutionDir)\..\xchat.png"</Pixmaps>
     <DepLibs>gtk-win32-2.0.lib;gdk-win32-2.0.lib;atk-1.0.lib;gio-2.0.lib;gdk_pixbuf-2.0.lib;pangowin32-1.0.lib;pangocairo-1.0.lib;pango-1.0.lib;cairo.lib;gobject-2.0.lib;gmodule-2.0.lib;glib-2.0.lib;intl.lib;libxml2.lib;libeay32.lib;ssleay32.lib;wininet.lib;winmm.lib;ws2_32.lib</DepLibs>
-    <XChatDest>$(SolutionDir)\dist\$(PlatformName)</XChatDest>
+    <XChatDest>$(SolutionDir)build\$(PlatformName)\rel</XChatDest>
   </PropertyGroup>
   <ItemDefinitionGroup />
   <ItemGroup />
diff --git a/win32/xchat.sln b/win32/xchat.sln
index 050313eb..84e1190e 100644
--- a/win32/xchat.sln
+++ b/win32/xchat.sln
@@ -89,10 +89,32 @@ EndProject
 Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "nls", "nls\nls.vcxproj", "{B10A2C41-344C-43E0-A32D-B9587C198D8B}"
 EndProject
 Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "copy", "copy\copy.vcxproj", "{C9B735E4-75BC-45AC-A5E3-39A6D076F912}"
+	ProjectSection(ProjectDependencies) = postProject
+		{19C52A0A-A790-409E-A28A-9745FF990F5C} = {19C52A0A-A790-409E-A28A-9745FF990F5C}
+		{E7F4DB0A-510D-41EF-B284-6E1DE1CC450D} = {E7F4DB0A-510D-41EF-B284-6E1DE1CC450D}
+		{646B4316-C8B8-4DB6-B6AE-E586929E5729} = {646B4316-C8B8-4DB6-B6AE-E586929E5729}
+		{4980AF24-9D42-427D-A8E6-0DF3B97C455D} = {4980AF24-9D42-427D-A8E6-0DF3B97C455D}
+		{3024CF36-85E5-4E00-9608-7002E2C7EF14} = {3024CF36-85E5-4E00-9608-7002E2C7EF14}
+		{58654438-F674-42F7-88FA-73EF90AD80B1} = {58654438-F674-42F7-88FA-73EF90AD80B1}
+		{17E4BE39-76F7-4A06-AD21-EFD0C5091F76} = {17E4BE39-76F7-4A06-AD21-EFD0C5091F76}
+		{B10A2C41-344C-43E0-A32D-B9587C198D8B} = {B10A2C41-344C-43E0-A32D-B9587C198D8B}
+		{461DC24A-A410-4171-8C02-CCDBF3702C2A} = {461DC24A-A410-4171-8C02-CCDBF3702C2A}
+		{E93E1255-95D1-4B08-8FDF-B53CC6A21280} = {E93E1255-95D1-4B08-8FDF-B53CC6A21280}
+		{2773666A-8CFC-4533-A043-EAD59F16A1C7} = {2773666A-8CFC-4533-A043-EAD59F16A1C7}
+		{C4C9FA6F-F990-4C7B-85F6-CD8F4F5728F0} = {C4C9FA6F-F990-4C7B-85F6-CD8F4F5728F0}
+		{987E9374-98A1-44BA-946F-D3472D7A7055} = {987E9374-98A1-44BA-946F-D3472D7A7055}
+		{5EF7F47D-D09C-43C4-BF64-B28B11A0FF91} = {5EF7F47D-D09C-43C4-BF64-B28B11A0FF91}
+		{6C0CA980-97C5-427A-BE61-5BCECAFABBDA} = {6C0CA980-97C5-427A-BE61-5BCECAFABBDA}
+		{3786FA8C-3E76-45E3-984E-FCCFF44729C9} = {3786FA8C-3E76-45E3-984E-FCCFF44729C9}
+		{B0E36D93-CA2A-49FE-9EB9-9C96C6016EEC} = {B0E36D93-CA2A-49FE-9EB9-9C96C6016EEC}
+		{E78C0D9A-798E-4BF6-B0CC-6FECB8CA2FCE} = {E78C0D9A-798E-4BF6-B0CC-6FECB8CA2FCE}
+		{18871EBA-AC85-4652-8919-EB8064B9A714} = {18871EBA-AC85-4652-8919-EB8064B9A714}
+		{E4BDB4C8-2335-415A-ACEE-BA88B19BFE82} = {E4BDB4C8-2335-415A-ACEE-BA88B19BFE82}
+		{3C4F42FC-292A-420B-B63D-C03DFBDD8E4E} = {3C4F42FC-292A-420B-B63D-C03DFBDD8E4E}
+	EndProjectSection
 EndProject
 Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "installer", "installer\installer.vcxproj", "{5A0F4962-E670-4DA2-9E45-52CC47F26E2F}"
 	ProjectSection(ProjectDependencies) = postProject
-		{B10A2C41-344C-43E0-A32D-B9587C198D8B} = {B10A2C41-344C-43E0-A32D-B9587C198D8B}
 		{C9B735E4-75BC-45AC-A5E3-39A6D076F912} = {C9B735E4-75BC-45AC-A5E3-39A6D076F912}
 	EndProjectSection
 EndProject
-- 
cgit 1.4.1


From ad59c4a586711f488b31f83072ebdc9ac595366e Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Fri, 15 Jun 2012 22:36:29 +0200
Subject: Add x64 support to the VS solution

---
 plugins/checksum/checksum.vcxproj |  43 ++++++++++++++++
 plugins/dns/dns.vcxproj           |  43 ++++++++++++++++
 plugins/doat/doat.vcxproj         |  41 ++++++++++++++++
 plugins/exec/exec.vcxproj         |  41 ++++++++++++++++
 plugins/fishlim/fishlim.vcxproj   |  43 ++++++++++++++++
 plugins/lua/lua.vcxproj           |  55 +++++++++++++++++++++
 plugins/mpcinfo/mpcinfo.vcxproj   |  41 ++++++++++++++++
 plugins/perl/perl-512.vcxproj     |  52 ++++++++++++++++++++
 plugins/perl/perl-514.vcxproj     |  52 ++++++++++++++++++++
 plugins/perl/perl-516.vcxproj     |  52 ++++++++++++++++++++
 plugins/python/python.vcxproj     |  43 ++++++++++++++++
 plugins/tcl/tcl.vcxproj           |  43 ++++++++++++++++
 plugins/upd/upd.vcxproj           |  43 ++++++++++++++++
 plugins/winamp/winamp.vcxproj     |  41 ++++++++++++++++
 plugins/winsys/winsys.vcxproj     |  44 +++++++++++++++++
 plugins/wmpa/wmpa.vcxproj         |  43 ++++++++++++++++
 plugins/xsasl/xsasl.vcxproj       |  43 ++++++++++++++++
 plugins/xtray/xtray.vcxproj       |  41 ++++++++++++++++
 src/common/common.vcxproj         |  38 ++++++++++++++
 src/dirent/dirent.vcxproj         |  38 ++++++++++++++
 src/fe-gtk/fe-gtk.vcxproj         |  43 ++++++++++++++++
 src/fe-text/fe-text.vcxproj       |  42 ++++++++++++++++
 src/pixmaps/pixmaps.vcxproj       |  40 +++++++++++++++
 src/version/version.vcxproj       |  41 ++++++++++++++++
 win32/copy/copy.vcxproj           | 101 ++++++++++++++++++++++++++++++++++++++
 win32/installer/installer.vcxproj |  44 +++++++++++++++++
 win32/nls/nls.vcxproj             |  45 +++++++++++++++++
 win32/xchat.sln                   |  55 +++++++++++++++++++++
 28 files changed, 1291 insertions(+)

(limited to 'plugins')

diff --git a/plugins/checksum/checksum.vcxproj b/plugins/checksum/checksum.vcxproj
index c4090cd1..753ca10e 100644
--- a/plugins/checksum/checksum.vcxproj
+++ b/plugins/checksum/checksum.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{5EF7F47D-D09C-43C4-BF64-B28B11A0FF91}</ProjectGuid>
@@ -19,6 +23,13 @@
     <CharacterSet>MultiByte</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -26,6 +37,10 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
@@ -33,6 +48,12 @@
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xcchecksum</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level1</WarningLevel>
@@ -55,6 +76,28 @@
       <AdditionalDependencies>$(DepLibs);%(AdditionalDependencies)</AdditionalDependencies>
     </Link>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;_WIN64;NDEBUG;_WINDOWS;_USRDLL;CHECKSUM_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <AdditionalIncludeDirectories>$(DepsRoot)\include;..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <ModuleDefinitionFile>checksum.def</ModuleDefinitionFile>
+      <AdditionalLibraryDirectories>$(DepsRoot)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+      <AdditionalDependencies>$(DepLibs);%(AdditionalDependencies)</AdditionalDependencies>
+    </Link>
+  </ItemDefinitionGroup>
   <ItemGroup>
     <ClCompile Include="checksum.c" />
   </ItemGroup>
diff --git a/plugins/dns/dns.vcxproj b/plugins/dns/dns.vcxproj
index 38f1634b..64df391d 100644
--- a/plugins/dns/dns.vcxproj
+++ b/plugins/dns/dns.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{3786FA8C-3E76-45E3-984E-FCCFF44729C9}</ProjectGuid>
@@ -19,6 +23,13 @@
     <CharacterSet>MultiByte</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -26,6 +37,10 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
@@ -33,6 +48,12 @@
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xcdns</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level1</WarningLevel>
@@ -55,6 +76,28 @@
       <ModuleDefinitionFile>dns.def</ModuleDefinitionFile>
     </Link>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;_WIN64;NDEBUG;_WINDOWS;_USRDLL;DNS_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <AdditionalIncludeDirectories>..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <AdditionalLibraryDirectories>$(DepsRoot)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+      <AdditionalDependencies>$(DepLibs);%(AdditionalDependencies)</AdditionalDependencies>
+      <ModuleDefinitionFile>dns.def</ModuleDefinitionFile>
+    </Link>
+  </ItemDefinitionGroup>
   <ItemGroup>
     <None Include="dns.def" />
   </ItemGroup>
diff --git a/plugins/doat/doat.vcxproj b/plugins/doat/doat.vcxproj
index c6901fe1..33969fc3 100644
--- a/plugins/doat/doat.vcxproj
+++ b/plugins/doat/doat.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{4980AF24-9D42-427D-A8E6-0DF3B97C455D}</ProjectGuid>
@@ -19,6 +23,13 @@
     <CharacterSet>MultiByte</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -26,6 +37,10 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
@@ -33,6 +48,12 @@
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xcdoat</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level1</WarningLevel>
@@ -53,6 +74,26 @@
       <ModuleDefinitionFile>doat.def</ModuleDefinitionFile>
     </Link>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;_WIN64;NDEBUG;_WINDOWS;_USRDLL;DOAT_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <AdditionalIncludeDirectories>..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <ModuleDefinitionFile>doat.def</ModuleDefinitionFile>
+    </Link>
+  </ItemDefinitionGroup>
   <ItemGroup>
     <ClCompile Include="doat.c" />
   </ItemGroup>
diff --git a/plugins/exec/exec.vcxproj b/plugins/exec/exec.vcxproj
index 15bf5ec5..22e6200a 100644
--- a/plugins/exec/exec.vcxproj
+++ b/plugins/exec/exec.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{17E4BE39-76F7-4A06-AD21-EFD0C5091F76}</ProjectGuid>
@@ -19,6 +23,13 @@
     <CharacterSet>MultiByte</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -26,6 +37,10 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
@@ -33,6 +48,12 @@
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xcexec</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level1</WarningLevel>
@@ -53,6 +74,26 @@
       <ModuleDefinitionFile>exec.def</ModuleDefinitionFile>
     </Link>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;_WIN64;NDEBUG;_WINDOWS;_USRDLL;EXEC_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+      <AdditionalIncludeDirectories>..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <ModuleDefinitionFile>exec.def</ModuleDefinitionFile>
+    </Link>
+  </ItemDefinitionGroup>
   <ItemGroup>
     <None Include="exec.def" />
   </ItemGroup>
diff --git a/plugins/fishlim/fishlim.vcxproj b/plugins/fishlim/fishlim.vcxproj
index 0f6e1c38..6b5dcc07 100644
--- a/plugins/fishlim/fishlim.vcxproj
+++ b/plugins/fishlim/fishlim.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{3C4F42FC-292A-420B-B63D-C03DFBDD8E4E}</ProjectGuid>
@@ -19,6 +23,13 @@
     <CharacterSet>MultiByte</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -26,6 +37,10 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
@@ -33,6 +48,12 @@
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xcfishlim</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level1</WarningLevel>
@@ -55,6 +76,28 @@
       <AdditionalDependencies>$(DepLibs);%(AdditionalDependencies)</AdditionalDependencies>
     </Link>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;_WIN64;NDEBUG;_WINDOWS;_USRDLL;FISHLIM_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+      <AdditionalIncludeDirectories>$(DepsRoot)\include;$(Glib);..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <ModuleDefinitionFile>fishlim.def</ModuleDefinitionFile>
+      <AdditionalLibraryDirectories>$(DepsRoot)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+      <AdditionalDependencies>$(DepLibs);%(AdditionalDependencies)</AdditionalDependencies>
+    </Link>
+  </ItemDefinitionGroup>
   <ItemGroup>
     <None Include="fishlim.def" />
   </ItemGroup>
diff --git a/plugins/lua/lua.vcxproj b/plugins/lua/lua.vcxproj
index 26d21856..cbb3c444 100644
--- a/plugins/lua/lua.vcxproj
+++ b/plugins/lua/lua.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{646B4316-C8B8-4DB6-B6AE-E586929E5729}</ProjectGuid>
@@ -19,6 +23,13 @@
     <CharacterSet>MultiByte</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -26,6 +37,10 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
@@ -33,6 +48,12 @@
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>$(LuaOutput)</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level1</WarningLevel>
@@ -53,11 +74,36 @@
       <AdditionalDependencies>"$(LuaLib).lib";;dirent-win32.lib;%(AdditionalDependencies)</AdditionalDependencies>
     </Link>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;LUA_EXPORTS;$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <AdditionalIncludeDirectories>$(DepsRoot)\include;..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <AdditionalLibraryDirectories>$(DepsRoot)\lib;$(OutDir);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+      <AdditionalDependencies>"$(LuaLib).lib";;dirent-win32.lib;%(AdditionalDependencies)</AdditionalDependencies>
+    </Link>
+  </ItemDefinitionGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <Link>
       <AdditionalDependencies>"$(LuaLib).lib";$(DepLibs);dirent-win32.lib;%(AdditionalDependencies)</AdditionalDependencies>
     </Link>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <Link>
+      <AdditionalDependencies>"$(LuaLib).lib";$(DepLibs);dirent-win32.lib;%(AdditionalDependencies)</AdditionalDependencies>
+    </Link>
+  </ItemDefinitionGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <PreprocessorDefinitions>WIN32;NDEBUG;_WINDOWS;_USRDLL;$(OwnFlags);snprintf=g_snprintf;%(PreprocessorDefinitions)</PreprocessorDefinitions>
@@ -67,6 +113,15 @@
       <ModuleDefinitionFile>lua.def</ModuleDefinitionFile>
     </Link>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <PreprocessorDefinitions>WIN32;_WIN64;NDEBUG;_WINDOWS;_USRDLL;$(OwnFlags);snprintf=g_snprintf;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+    </ClCompile>
+    <Link>
+      <ModuleDefinitionFile>lua.def</ModuleDefinitionFile>
+    </Link>
+  </ItemDefinitionGroup>
   <ItemGroup>
     <None Include="lua.def" />
   </ItemGroup>
diff --git a/plugins/mpcinfo/mpcinfo.vcxproj b/plugins/mpcinfo/mpcinfo.vcxproj
index 7f12822e..6746ce15 100644
--- a/plugins/mpcinfo/mpcinfo.vcxproj
+++ b/plugins/mpcinfo/mpcinfo.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{B0E36D93-CA2A-49FE-9EB9-9C96C6016EEC}</ProjectGuid>
@@ -19,6 +23,13 @@
     <CharacterSet>MultiByte</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -26,6 +37,10 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
@@ -33,6 +48,12 @@
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xcmpcinfo</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level1</WarningLevel>
@@ -53,6 +74,26 @@
       <ModuleDefinitionFile>mpcinfo.def</ModuleDefinitionFile>
     </Link>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;_WIN64;NDEBUG;_WINDOWS;_USRDLL;MPCINFO_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+      <AdditionalIncludeDirectories>..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <ModuleDefinitionFile>mpcinfo.def</ModuleDefinitionFile>
+    </Link>
+  </ItemDefinitionGroup>
   <ItemGroup>
     <None Include="mpcinfo.def" />
   </ItemGroup>
diff --git a/plugins/perl/perl-512.vcxproj b/plugins/perl/perl-512.vcxproj
index d924af48..313014b9 100644
--- a/plugins/perl/perl-512.vcxproj
+++ b/plugins/perl/perl-512.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{987E9374-98A1-44BA-946F-D3472D7A7055}</ProjectGuid>
@@ -19,6 +23,13 @@
     <CharacterSet>MultiByte</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -26,6 +37,10 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
@@ -33,6 +48,12 @@
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>$(Perl512Output)</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level1</WarningLevel>
@@ -61,6 +82,37 @@ move $(Perl512Lib).def "$(IntDir)"
 lib /nologo /machine:x86 "/def:$(IntDir)$(Perl512Lib).def" "/out:$(OutDir)\$(Perl512Lib).lib"
 "$(Perl512Path)\perl\bin\perl.exe" generate_header
 move irc.pm.h "$(IntDir)"
+move xchat.pm.h "$(IntDir)"</Command>
+    </PreBuildEvent>
+  </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;_WIN64;NDEBUG;_WINDOWS;_USRDLL;PERL512_EXPORTS;$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+      <AdditionalIncludeDirectories>$(Perl512Path)\perl\lib\CORE;$(IntDir);..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <AdditionalLibraryDirectories>$(OutDir);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+      <AdditionalDependencies>$(Perl512Lib).lib;dirent-win32.lib;%(AdditionalDependencies)</AdditionalDependencies>
+      <ModuleDefinitionFile>perl.def</ModuleDefinitionFile>
+      <DelayLoadDLLs>$(Perl512Lib).dll;%(DelayLoadDLLs)</DelayLoadDLLs>
+    </Link>
+    <PreBuildEvent>
+      <Command>"$(GendefPath)\gendef" "$(Perl512Path)\perl\bin\$(Perl512Lib).dll"
+move $(Perl512Lib).def "$(IntDir)"
+lib /nologo /machine:x64 "/def:$(IntDir)$(Perl512Lib).def" "/out:$(OutDir)\$(Perl512Lib).lib"
+"$(Perl512Path)\perl\bin\perl.exe" generate_header
+move irc.pm.h "$(IntDir)"
 move xchat.pm.h "$(IntDir)"</Command>
     </PreBuildEvent>
   </ItemDefinitionGroup>
diff --git a/plugins/perl/perl-514.vcxproj b/plugins/perl/perl-514.vcxproj
index 58cc4f04..6e469944 100644
--- a/plugins/perl/perl-514.vcxproj
+++ b/plugins/perl/perl-514.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{C4C9FA6F-F990-4C7B-85F6-CD8F4F5728F0}</ProjectGuid>
@@ -19,6 +23,13 @@
     <CharacterSet>MultiByte</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -26,6 +37,10 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
@@ -33,6 +48,12 @@
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>$(Perl514Output)</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level1</WarningLevel>
@@ -61,6 +82,37 @@ move $(Perl514Lib).def "$(IntDir)"
 lib /nologo /machine:x86 "/def:$(IntDir)$(Perl514Lib).def" "/out:$(OutDir)\$(Perl514Lib).lib"
 "$(Perl514Path)\perl\bin\perl.exe" generate_header
 move irc.pm.h "$(IntDir)"
+move xchat.pm.h "$(IntDir)"</Command>
+    </PreBuildEvent>
+  </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;_WIN64;NDEBUG;_WINDOWS;_USRDLL;PERL514_EXPORTS;$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <AdditionalIncludeDirectories>$(Perl514Path)\perl\lib\CORE;$(IntDir);..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <AdditionalLibraryDirectories>$(OutDir);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+      <AdditionalDependencies>$(Perl514Lib).lib;dirent-win32.lib;%(AdditionalDependencies)</AdditionalDependencies>
+      <ModuleDefinitionFile>perl.def</ModuleDefinitionFile>
+      <DelayLoadDLLs>$(Perl514Lib).dll;%(DelayLoadDLLs)</DelayLoadDLLs>
+    </Link>
+    <PreBuildEvent>
+      <Command>"$(GendefPath)\gendef" "$(Perl514Path)\perl\bin\$(Perl514Lib).dll"
+move $(Perl514Lib).def "$(IntDir)"
+lib /nologo /machine:x64 "/def:$(IntDir)$(Perl514Lib).def" "/out:$(OutDir)\$(Perl514Lib).lib"
+"$(Perl514Path)\perl\bin\perl.exe" generate_header
+move irc.pm.h "$(IntDir)"
 move xchat.pm.h "$(IntDir)"</Command>
     </PreBuildEvent>
   </ItemDefinitionGroup>
diff --git a/plugins/perl/perl-516.vcxproj b/plugins/perl/perl-516.vcxproj
index 516c1b80..06bf2fbd 100644
--- a/plugins/perl/perl-516.vcxproj
+++ b/plugins/perl/perl-516.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{58654438-F674-42F7-88FA-73EF90AD80B1}</ProjectGuid>
@@ -19,6 +23,13 @@
     <CharacterSet>MultiByte</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -26,6 +37,10 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
@@ -33,6 +48,12 @@
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>$(Perl516Output)</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level1</WarningLevel>
@@ -61,6 +82,37 @@ move $(Perl516Lib).def "$(IntDir)"
 lib /nologo /machine:x86 "/def:$(IntDir)$(Perl516Lib).def" "/out:$(OutDir)\$(Perl516Lib).lib"
 "$(Perl516Path)\perl\bin\perl.exe" generate_header
 move irc.pm.h "$(IntDir)"
+move xchat.pm.h "$(IntDir)"</Command>
+    </PreBuildEvent>
+  </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;_WIN64;NDEBUG;_WINDOWS;_USRDLL;PERL516_EXPORTS;$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <AdditionalIncludeDirectories>$(Perl516Path)\perl\lib\CORE;$(IntDir);..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <AdditionalLibraryDirectories>$(OutDir);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+      <AdditionalDependencies>$(Perl516Lib).lib;dirent-win32.lib;%(AdditionalDependencies)</AdditionalDependencies>
+      <ModuleDefinitionFile>perl.def</ModuleDefinitionFile>
+      <DelayLoadDLLs>$(Perl516Lib).dll;%(DelayLoadDLLs)</DelayLoadDLLs>
+    </Link>
+    <PreBuildEvent>
+      <Command>"$(GendefPath)\gendef" "$(Perl516Path)\perl\bin\$(Perl516Lib).dll"
+move $(Perl516Lib).def "$(IntDir)"
+lib /nologo /machine:x64 "/def:$(IntDir)$(Perl516Lib).def" "/out:$(OutDir)\$(Perl516Lib).lib"
+"$(Perl516Path)\perl\bin\perl.exe" generate_header
+move irc.pm.h "$(IntDir)"
 move xchat.pm.h "$(IntDir)"</Command>
     </PreBuildEvent>
   </ItemDefinitionGroup>
diff --git a/plugins/python/python.vcxproj b/plugins/python/python.vcxproj
index 923eeb92..ef50ee42 100644
--- a/plugins/python/python.vcxproj
+++ b/plugins/python/python.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{19C52A0A-A790-409E-A28A-9745FF990F5C}</ProjectGuid>
@@ -19,6 +23,13 @@
     <CharacterSet>MultiByte</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -26,6 +37,10 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
@@ -33,6 +48,12 @@
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>$(PythonOutput)</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level1</WarningLevel>
@@ -55,6 +76,28 @@
       <AdditionalLibraryDirectories>$(DepsRoot)\lib;$(OutDir);$(PythonPath)\libs;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
     </Link>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;_WIN64;NDEBUG;_WINDOWS;_USRDLL;PYTHON_EXPORTS;$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <AdditionalIncludeDirectories>$(Glib);$(PythonPath)\include;..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <ModuleDefinitionFile>python.def</ModuleDefinitionFile>
+      <AdditionalDependencies>"$(PythonLib).lib";$(DepLibs);dirent-win32.lib;%(AdditionalDependencies)</AdditionalDependencies>
+      <AdditionalLibraryDirectories>$(DepsRoot)\lib;$(OutDir);$(PythonPath)\libs;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+    </Link>
+  </ItemDefinitionGroup>
   <ItemGroup>
     <None Include="python.def" />
   </ItemGroup>
diff --git a/plugins/tcl/tcl.vcxproj b/plugins/tcl/tcl.vcxproj
index baa188f6..8820742d 100644
--- a/plugins/tcl/tcl.vcxproj
+++ b/plugins/tcl/tcl.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <ItemGroup>
     <ClInclude Include="printevents.h" />
@@ -29,6 +33,13 @@
     <CharacterSet>MultiByte</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -36,6 +47,10 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
@@ -43,6 +58,12 @@
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>$(TclOutput)</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level1</WarningLevel>
@@ -65,6 +86,28 @@
       <DelayLoadDLLs>$(TclLib).dll;%(DelayLoadDLLs)</DelayLoadDLLs>
     </Link>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>NotUsing</PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;_WIN64;NDEBUG;_WINDOWS;_USRDLL;TCL_EXPORTS;TCL_DLL="$(TclLib).dll";$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <AdditionalIncludeDirectories>$(TclPath)\include;..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <AdditionalLibraryDirectories>$(TclPath)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+      <AdditionalDependencies>"$(TclLib).lib";%(AdditionalDependencies)</AdditionalDependencies>
+      <ModuleDefinitionFile>tcl.def</ModuleDefinitionFile>
+      <DelayLoadDLLs>$(TclLib).dll;%(DelayLoadDLLs)</DelayLoadDLLs>
+    </Link>
+  </ItemDefinitionGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
   <ImportGroup Label="ExtensionTargets">
   </ImportGroup>
diff --git a/plugins/upd/upd.vcxproj b/plugins/upd/upd.vcxproj
index 9cf7c017..dc853ff8 100644
--- a/plugins/upd/upd.vcxproj
+++ b/plugins/upd/upd.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{461DC24A-A410-4171-8C02-CCDBF3702C2A}</ProjectGuid>
@@ -19,6 +23,13 @@
     <CharacterSet>MultiByte</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -26,6 +37,10 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
@@ -33,6 +48,12 @@
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xcupd</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level1</WarningLevel>
@@ -55,6 +76,28 @@
       <AdditionalLibraryDirectories>$(DepsRoot)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
     </Link>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;_WIN64;NDEBUG;_WINDOWS;_USRDLL;UPD_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+      <AdditionalIncludeDirectories>..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <ModuleDefinitionFile>upd.def</ModuleDefinitionFile>
+      <AdditionalDependencies>$(DepLibs);%(AdditionalDependencies)</AdditionalDependencies>
+      <AdditionalLibraryDirectories>$(DepsRoot)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+    </Link>
+  </ItemDefinitionGroup>
   <ItemGroup>
     <None Include="upd.def" />
   </ItemGroup>
diff --git a/plugins/winamp/winamp.vcxproj b/plugins/winamp/winamp.vcxproj
index 0a1eb419..2b5f3633 100644
--- a/plugins/winamp/winamp.vcxproj
+++ b/plugins/winamp/winamp.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{E78C0D9A-798E-4BF6-B0CC-6FECB8CA2FCE}</ProjectGuid>
@@ -19,6 +23,13 @@
     <CharacterSet>MultiByte</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -26,6 +37,10 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
@@ -33,6 +48,12 @@
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xcwinamp</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level1</WarningLevel>
@@ -53,6 +74,26 @@
       <ModuleDefinitionFile>winamp.def</ModuleDefinitionFile>
     </Link>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;_WIN64;NDEBUG;_WINDOWS;_USRDLL;WINAMP_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+      <AdditionalIncludeDirectories>..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <ModuleDefinitionFile>winamp.def</ModuleDefinitionFile>
+    </Link>
+  </ItemDefinitionGroup>
   <ItemGroup>
     <None Include="winamp.def" />
   </ItemGroup>
diff --git a/plugins/winsys/winsys.vcxproj b/plugins/winsys/winsys.vcxproj
index 656f6ee9..bacb5db4 100644
--- a/plugins/winsys/winsys.vcxproj
+++ b/plugins/winsys/winsys.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{6C0CA980-97C5-427A-BE61-5BCECAFABBDA}</ProjectGuid>
@@ -19,6 +23,13 @@
     <CharacterSet>Unicode</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>Unicode</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -26,6 +37,10 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
@@ -33,6 +48,12 @@
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xcwinsys</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level1</WarningLevel>
@@ -56,6 +77,29 @@
       <IgnoreSpecificDefaultLibraries>comsupp.lib</IgnoreSpecificDefaultLibraries>
     </Link>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;_WIN64;NDEBUG;_WINDOWS;_USRDLL;WINSYS_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <AdditionalIncludeDirectories>..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+      <TreatWChar_tAsBuiltInType>false</TreatWChar_tAsBuiltInType>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <ModuleDefinitionFile>winsys.def</ModuleDefinitionFile>
+      <AdditionalDependencies>wbemuuid.lib;vccomsup.lib;%(AdditionalDependencies)</AdditionalDependencies>
+      <IgnoreSpecificDefaultLibraries>comsupp.lib</IgnoreSpecificDefaultLibraries>
+    </Link>
+  </ItemDefinitionGroup>
   <ItemGroup>
     <None Include="winsys.def" />
   </ItemGroup>
diff --git a/plugins/wmpa/wmpa.vcxproj b/plugins/wmpa/wmpa.vcxproj
index 630cef4d..92364dc4 100644
--- a/plugins/wmpa/wmpa.vcxproj
+++ b/plugins/wmpa/wmpa.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{E7F4DB0A-510D-41EF-B284-6E1DE1CC450D}</ProjectGuid>
@@ -20,6 +24,14 @@
     <PlatformToolset>WDK7</PlatformToolset>
     <UseOfMfc>Dynamic</UseOfMfc>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>false</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+    <UseOfMfc>Dynamic</UseOfMfc>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -27,6 +39,10 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
@@ -34,6 +50,12 @@
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xcwmpa</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level1</WarningLevel>
@@ -55,6 +77,27 @@
       <MkTypLibCompatible>true</MkTypLibCompatible>
     </Midl>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>Create</PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;_WIN64;NDEBUG;_WINDOWS;_USRDLL;WMPA_EXPORTS;_AFXDLL;_AFX_NO_DAO_SUPPORT;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <MultiProcessorCompilation>false</MultiProcessorCompilation>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <ModuleDefinitionFile>wmpa.def</ModuleDefinitionFile>
+    </Link>
+    <Midl>
+      <MkTypLibCompatible>true</MkTypLibCompatible>
+    </Midl>
+  </ItemDefinitionGroup>
   <ItemGroup>
     <ClCompile Include="StdAfx.cpp" />
     <ClCompile Include="wmpa.cpp" />
diff --git a/plugins/xsasl/xsasl.vcxproj b/plugins/xsasl/xsasl.vcxproj
index 7e0c41d7..bec3da94 100644
--- a/plugins/xsasl/xsasl.vcxproj
+++ b/plugins/xsasl/xsasl.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{18871EBA-AC85-4652-8919-EB8064B9A714}</ProjectGuid>
@@ -19,6 +23,13 @@
     <CharacterSet>MultiByte</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -26,6 +37,10 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
@@ -33,6 +48,12 @@
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xcxsasl</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level1</WarningLevel>
@@ -55,6 +76,28 @@
       <AdditionalDependencies>$(DepLibs);%(AdditionalDependencies)</AdditionalDependencies>
     </Link>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;_WIN64;NDEBUG;_WINDOWS;_USRDLL;XSASL_EXPORTS;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <AdditionalIncludeDirectories>$(Glib);..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <ModuleDefinitionFile>xsasl.def</ModuleDefinitionFile>
+      <AdditionalLibraryDirectories>$(DepsRoot)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+      <AdditionalDependencies>$(DepLibs);%(AdditionalDependencies)</AdditionalDependencies>
+    </Link>
+  </ItemDefinitionGroup>
   <ItemGroup>
     <None Include="xsasl.def" />
   </ItemGroup>
diff --git a/plugins/xtray/xtray.vcxproj b/plugins/xtray/xtray.vcxproj
index 1f7aa5cf..aa455a8f 100644
--- a/plugins/xtray/xtray.vcxproj
+++ b/plugins/xtray/xtray.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{3024CF36-85E5-4E00-9608-7002E2C7EF14}</ProjectGuid>
@@ -19,6 +23,13 @@
     <CharacterSet>Unicode</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>DynamicLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>Unicode</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -26,12 +37,21 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <LinkIncremental>false</LinkIncremental>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level1</WarningLevel>
@@ -53,6 +73,27 @@
       <AdditionalDependencies>ntstc_msvcrt.lib;%(AdditionalDependencies)</AdditionalDependencies>
     </Link>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;_WIN64;NDEBUG;_WINDOWS;_USRDLL;XTRAY_EXPORTS;_STL70_;_STATIC_CPPLIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+      <AdditionalIncludeDirectories>..;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <ModuleDefinitionFile>xtray.def</ModuleDefinitionFile>
+      <AdditionalDependencies>ntstc_msvcrt.lib;%(AdditionalDependencies)</AdditionalDependencies>
+    </Link>
+  </ItemDefinitionGroup>
   <ItemGroup>
     <None Include="bitmaps\sd.bmp" />
     <None Include="icons\banned.ico" />
diff --git a/src/common/common.vcxproj b/src/common/common.vcxproj
index b57b2ccf..4e95c929 100644
--- a/src/common/common.vcxproj
+++ b/src/common/common.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <ItemGroup>
     <ClInclude Include="..\..\config.h" />
@@ -82,6 +86,13 @@
     <CharacterSet>MultiByte</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>StaticLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -89,11 +100,19 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level1</WarningLevel>
@@ -113,6 +132,25 @@
       <OptimizeReferences>true</OptimizeReferences>
     </Link>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;_WIN64;NDEBUG;_LIB;$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <AdditionalIncludeDirectories>$(DepsRoot)\include;$(Glib);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+    </Link>
+  </ItemDefinitionGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
   <ImportGroup Label="ExtensionTargets">
   </ImportGroup>
diff --git a/src/dirent/dirent.vcxproj b/src/dirent/dirent.vcxproj
index 8ac38f92..5ae75f57 100644
--- a/src/dirent/dirent.vcxproj
+++ b/src/dirent/dirent.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <ItemGroup>
     <ClInclude Include="dirent-win32.h" />
@@ -25,6 +29,13 @@
     <CharacterSet>MultiByte</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>StaticLibrary</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -32,12 +43,21 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <TargetName>$(ProjectName)-win32</TargetName>
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <TargetName>$(ProjectName)-win32</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level1</WarningLevel>
@@ -56,6 +76,24 @@
       <OptimizeReferences>true</OptimizeReferences>
     </Link>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;_WIN64;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+    </Link>
+  </ItemDefinitionGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
   <ImportGroup Label="ExtensionTargets">
   </ImportGroup>
diff --git a/src/fe-gtk/fe-gtk.vcxproj b/src/fe-gtk/fe-gtk.vcxproj
index fce8d3e6..cb102012 100644
--- a/src/fe-gtk/fe-gtk.vcxproj
+++ b/src/fe-gtk/fe-gtk.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{E4BDB4C8-2335-415A-ACEE-BA88B19BFE82}</ProjectGuid>
@@ -19,6 +23,13 @@
     <CharacterSet>MultiByte</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>Application</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -26,6 +37,10 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
@@ -33,6 +48,12 @@
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xchat</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level1</WarningLevel>
@@ -55,6 +76,28 @@
       <EntryPointSymbol>mainCRTStartup</EntryPointSymbol>
     </Link>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;_WIN64;NDEBUG;_WINDOWS;$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <AdditionalIncludeDirectories>$(DepsRoot)\include;$(Glib);$(Gtk);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+    </ClCompile>
+    <Link>
+      <SubSystem>Windows</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <AdditionalLibraryDirectories>$(DepsRoot)\lib;$(OutDir);%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+      <AdditionalDependencies>$(DepLibs);common.lib;dirent-win32.lib;%(AdditionalDependencies)</AdditionalDependencies>
+      <EntryPointSymbol>mainCRTStartup</EntryPointSymbol>
+    </Link>
+  </ItemDefinitionGroup>
   <ItemGroup>
     <ClInclude Include="about.h" />
     <ClInclude Include="ascii.h" />
diff --git a/src/fe-text/fe-text.vcxproj b/src/fe-text/fe-text.vcxproj
index ac7068ec..e8ed04b0 100644
--- a/src/fe-text/fe-text.vcxproj
+++ b/src/fe-text/fe-text.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{E93E1255-95D1-4B08-8FDF-B53CC6A21280}</ProjectGuid>
@@ -19,6 +23,13 @@
     <CharacterSet>MultiByte</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>Application</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -26,6 +37,10 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
@@ -33,6 +48,12 @@
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <LinkIncremental>false</LinkIncremental>
+    <TargetName>xchat-text</TargetName>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level1</WarningLevel>
@@ -54,6 +75,27 @@
       <AdditionalLibraryDirectories>$(DepsRoot)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
     </Link>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;_WIN64;NDEBUG;_CONSOLE;$(OwnFlags);%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <AdditionalIncludeDirectories>$(DepsRoot)\include;$(Glib);%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+    </ClCompile>
+    <Link>
+      <SubSystem>Console</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+      <AdditionalDependencies>$(DepLibs);"$(OutDir)\common.lib";"$(OutDir)\dirent-win32.lib";%(AdditionalDependencies)</AdditionalDependencies>
+      <AdditionalLibraryDirectories>$(DepsRoot)\lib;%(AdditionalLibraryDirectories)</AdditionalLibraryDirectories>
+    </Link>
+  </ItemDefinitionGroup>
   <ItemGroup>
     <ClInclude Include="fe-text.h" />
   </ItemGroup>
diff --git a/src/pixmaps/pixmaps.vcxproj b/src/pixmaps/pixmaps.vcxproj
index 3fda0fef..ec33a49b 100644
--- a/src/pixmaps/pixmaps.vcxproj
+++ b/src/pixmaps/pixmaps.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{626DA61C-FA8B-474C-B2F5-72AD9DFEE642}</ProjectGuid>
@@ -19,6 +23,13 @@
     <CharacterSet>MultiByte</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>Application</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -26,12 +37,21 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <LinkIncremental>false</LinkIncremental>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level3</WarningLevel>
@@ -52,6 +72,26 @@
       <Command>"$(DepsRoot)\bin\gdk-pixbuf-csource" --build-list $(Pixmaps) &gt; "$(SolutionDir)\..\src\pixmaps\inline_pngs.h"</Command>
     </PostBuildEvent>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level3</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+    </ClCompile>
+    <Link>
+      <SubSystem>Console</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+    </Link>
+    <PostBuildEvent>
+      <Command>"$(DepsRoot)\bin\gdk-pixbuf-csource" --build-list $(Pixmaps) &gt; "$(SolutionDir)\..\src\pixmaps\inline_pngs.h"</Command>
+    </PostBuildEvent>
+  </ItemDefinitionGroup>
   <ItemGroup>
     <None Include="..\..\xchat.png" />
     <None Include="book.png" />
diff --git a/src/version/version.vcxproj b/src/version/version.vcxproj
index b07b8e2a..5a4fe5cc 100644
--- a/src/version/version.vcxproj
+++ b/src/version/version.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{6CD3647E-4541-4849-9DD7-C8816665AE42}</ProjectGuid>
@@ -19,6 +23,13 @@
     <CharacterSet>MultiByte</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>Application</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -26,12 +37,21 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\..\win32\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\..\win32\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <LinkIncremental>false</LinkIncremental>
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <LinkIncremental>false</LinkIncremental>
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level1</WarningLevel>
@@ -53,6 +73,27 @@
       <Command>"$(OutDir)\$(TargetName)$(TargetExt)" -r &gt; "$(SolutionDir)\..\resource.h"</Command>
     </PostBuildEvent>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level1</WarningLevel>
+      <PrecompiledHeader>
+      </PrecompiledHeader>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+      <PreprocessorDefinitions>WIN32;_WIN64;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions>
+      <MultiProcessorCompilation>true</MultiProcessorCompilation>
+    </ClCompile>
+    <Link>
+      <SubSystem>Console</SubSystem>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+    </Link>
+    <PostBuildEvent>
+      <Command>"$(OutDir)\$(TargetName)$(TargetExt)" -r &gt; "$(SolutionDir)\..\resource.h"</Command>
+    </PostBuildEvent>
+  </ItemDefinitionGroup>
   <ItemGroup>
     <ClCompile Include="version.c" />
   </ItemGroup>
diff --git a/win32/copy/copy.vcxproj b/win32/copy/copy.vcxproj
index 5b64ddc6..a68df4a0 100644
--- a/win32/copy/copy.vcxproj
+++ b/win32/copy/copy.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{C9B735E4-75BC-45AC-A5E3-39A6D076F912}</ProjectGuid>
@@ -18,6 +22,13 @@
     <CharacterSet>MultiByte</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>Application</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -25,11 +36,19 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level3</WarningLevel>
@@ -112,6 +131,88 @@ copy "$(ProgramFiles)\Codejock Software\ISSkin\ISSkinU.dll" "$(XChatDest)"
 copy "..\installer\watercolorlite-green.cjstyles" "$(XChatDest)"</Command>
     </PreBuildEvent>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level3</WarningLevel>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+    </ClCompile>
+    <Link>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+    </Link>
+    <PreBuildEvent>
+      <Command>rmdir /q /s "$(XChatDest)"
+mkdir "$(XChatDest)"
+echo 2&gt; portable-mode
+move portable-mode "$(XChatDest)"
+copy "$(OutDir)\xchat.exe" "$(XChatDest)"
+copy "$(OutDir)\xchat-text.exe" "$(XChatDest)"
+copy "$(DepsRoot)\bin\libatk-1.0-0.dll" "$(XChatDest)"
+copy "$(DepsRoot)\bin\libcairo-2.dll" "$(XChatDest)"
+copy "$(DepsRoot)\bin\libexpat-1.dll" "$(XChatDest)"
+copy "$(DepsRoot)\bin\libfontconfig-1.dll" "$(XChatDest)"
+copy "$(DepsRoot)\bin\libfreetype-6.dll" "$(XChatDest)"
+copy "$(DepsRoot)\bin\libgdk_pixbuf-2.0-0.dll" "$(XChatDest)"
+copy "$(DepsRoot)\bin\libgdk-win32-2.0-0.dll" "$(XChatDest)"
+copy "$(DepsRoot)\bin\libgio-2.0-0.dll" "$(XChatDest)"
+copy "$(DepsRoot)\bin\libglib-2.0-0.dll" "$(XChatDest)"
+copy "$(DepsRoot)\bin\libgmodule-2.0-0.dll" "$(XChatDest)"
+copy "$(DepsRoot)\bin\libgobject-2.0-0.dll" "$(XChatDest)
+copy "$(DepsRoot)\bin\libgthread-2.0-0.dll" "$(XChatDest)"
+copy "$(DepsRoot)\bin\libgtk-win32-2.0-0.dll" "$(XChatDest)"
+copy "$(DepsRoot)\bin\libintl-8.dll" "$(XChatDest)"
+copy "$(DepsRoot)\bin\libpango-1.0-0.dll" "$(XChatDest)"
+copy "$(DepsRoot)\bin\libpangocairo-1.0-0.dll" "$(XChatDest)"
+copy "$(DepsRoot)\bin\libpangoft2-1.0-0.dll" "$(XChatDest)"
+copy "$(DepsRoot)\bin\libpangowin32-1.0-0.dll" "$(XChatDest)"
+copy "$(DepsRoot)\bin\libpng14-14.dll" "$(XChatDest)"
+copy "$(DepsRoot)\bin\libxml2.dll" "$(XChatDest)"
+xcopy /q /s /i "$(DepsRoot)\lib\gtk-2.0\2.10.0\engines" "$(XChatDest)\lib\gtk-2.0\2.10.0\engines"
+xcopy /q /s /i "$(DepsRoot)\lib\gtk-2.0\modules\libgail.dll" "$(XChatDest)\lib\gtk-2.0\modules\"
+xcopy /q /s /i etc "$(XChatDest)\etc"
+xcopy /q /s /i share "$(XChatDest)\share"
+copy "..\..\COPYING" "$(XChatDest)"
+copy "$(DepsRoot)\LICENSE.OPENSSL" "$(XChatDest)"
+copy "$(DepsRoot)\LICENSE.ZLIB" "$(XChatDest)"
+copy "$(DepsRoot)\share\gettext\intl\COPYING.LIB-2.0" "$(XChatDest)\LICENSE.GTK"
+copy "$(DepsRoot)\share\gettext\intl\COPYING.LIB-2.1" "$(XChatDest)\LICENSE.CAIRO"
+copy "$(DepsRoot)\LICENSE.LUA" "$(XChatDest)"
+copy "$(DepsRoot)\LICENSE.ENCHANT" "$(XChatDest)"
+copy "$(DepsRoot)\LICENSE.LIBXML" "$(XChatDest)"
+copy "$(DepsRoot)\bin\libeay32.dll" "$(XChatDest)"
+copy "$(DepsRoot)\bin\ssleay32.dll" "$(XChatDest)"
+copy "$(DepsRoot)\bin\zlib1.dll" "$(XChatDest)"
+copy "$(DepsRoot)\bin\cert.pem" "$(XChatDest)"
+copy "$(DepsRoot)\bin\libenchant.dll" "$(XChatDest)"
+xcopy /q /s /i "$(DepsRoot)\lib\enchant\libenchant_myspell.dll" "$(XChatDest)\lib\enchant\"
+xcopy /q /s /i "$(OutDir)xcchecksum.dll" "$(XChatDest)\plugins\"
+copy "$(OutDir)\xcdns.dll" "$(XChatDest)\plugins"
+copy "$(OutDir)\xcdoat.dll" "$(XChatDest)\plugins"
+copy "$(OutDir)\xcexec.dll" "$(XChatDest)\plugins"
+copy "$(OutDir)\xcfishlim.dll" "$(XChatDest)\plugins"
+copy "$(OutDir)\xclua.dll" "$(XChatDest)\plugins"
+copy "$(OutDir)\xcmpcinfo.dll" "$(XChatDest)\plugins"
+copy "$(OutDir)\xcperl-512.dll" "$(XChatDest)\plugins"
+copy "$(OutDir)\xcperl-514.dll" "$(XChatDest)\plugins"
+copy "$(OutDir)\xcperl-516.dll" "$(XChatDest)\plugins"
+copy "$(OutDir)\xcpython.dll" "$(XChatDest)\plugins"
+copy "$(OutDir)\xctcl.dll" "$(XChatDest)\plugins"
+copy "$(OutDir)\xcupd.dll" "$(XChatDest)\plugins"
+copy "$(OutDir)\xcxsasl.dll" "$(XChatDest)\plugins"
+copy "$(OutDir)\xtray.dll" "$(XChatDest)\plugins"
+copy "$(OutDir)\xcwinamp.dll" "$(XChatDest)\plugins"
+copy "$(OutDir)\xcwinsys.dll" "$(XChatDest)\plugins"
+copy "$(OutDir)\xcwmpa.dll" "$(XChatDest)\plugins"
+copy "$(DepsRoot)\bin\lua51.dll" "$(XChatDest)"
+xcopy /q /s /i "$(OutDir)\locale" "$(XChatDest)\locale"
+xcopy /q /s /i "$(DepsRoot)\share\locale" "$(XChatDest)\share\locale"
+copy "$(ProgramFiles)\Codejock Software\ISSkin\ISSkinU.dll" "$(XChatDest)"
+copy "..\installer\watercolorlite-blue.cjstyles" "$(XChatDest)"</Command>
+    </PreBuildEvent>
+  </ItemDefinitionGroup>
   <ItemGroup>
     <None Include="etc\download.png" />
     <None Include="etc\gtk-2.0\gtkrc" />
diff --git a/win32/installer/installer.vcxproj b/win32/installer/installer.vcxproj
index 3cb84d56..0fcba484 100644
--- a/win32/installer/installer.vcxproj
+++ b/win32/installer/installer.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{5A0F4962-E670-4DA2-9E45-52CC47F26E2F}</ProjectGuid>
@@ -18,6 +22,13 @@
     <CharacterSet>MultiByte</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>Application</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -25,11 +36,19 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level3</WarningLevel>
@@ -55,6 +74,31 @@ type xchat-wdk-x86.skel.iss &gt;&gt; "$(OutDir)\xchat-wdk-x86.iss"
 "$(ProgramFiles)\Inno Setup 5\compil32" /cc "$(OutDir)\xchat-wdk-x86.iss"</Command>
     </PreBuildEvent>
   </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level3</WarningLevel>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+    </ClCompile>
+    <Link>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+    </Link>
+    <PreBuildEvent>
+      <Command>echo [Setup] &gt; "$(OutDir)\xchat-wdk-x64.iss"
+echo WizardImageFile="$(ProjectDir)\wizardimage.bmp" &gt;&gt; "$(OutDir)\xchat-wdk-x64.iss"
+echo WizardSmallImageFile="$(ProjectDir)\wizardsmallimage.bmp" &gt;&gt; "$(OutDir)\xchat-wdk-x64.iss"
+"$(OutDir)\version" -a &gt;&gt; "$(OutDir)\xchat-wdk-x64.iss"
+"$(OutDir)\version" -v &gt;&gt; "$(OutDir)\xchat-wdk-x64.iss"
+"$(OutDir)\version" -i &gt;&gt; "$(OutDir)\xchat-wdk-x64.iss"
+"$(OutDir)\version" -o &gt;&gt; "$(OutDir)\xchat-wdk-x64.iss"
+echo SetupIconFile="$(SolutionDir)\..\xchat.ico" &gt;&gt; "$(OutDir)\xchat-wdk-x64.iss"
+type xchat-wdk-x64.skel.iss &gt;&gt; "$(OutDir)\xchat-wdk-x64.iss"
+"$(ProgramFiles)\Inno Setup 5\compil32" /cc "$(OutDir)\xchat-wdk-x64.iss"</Command>
+    </PreBuildEvent>
+  </ItemDefinitionGroup>
   <ItemGroup>
     <None Include="watercolorlite-blue.cjstyles" />
     <None Include="watercolorlite-green.cjstyles" />
diff --git a/win32/nls/nls.vcxproj b/win32/nls/nls.vcxproj
index 10e53bd8..9c0ecff4 100644
--- a/win32/nls/nls.vcxproj
+++ b/win32/nls/nls.vcxproj
@@ -5,6 +5,10 @@
       <Configuration>Release</Configuration>
       <Platform>Win32</Platform>
     </ProjectConfiguration>
+    <ProjectConfiguration Include="Release|x64">
+      <Configuration>Release</Configuration>
+      <Platform>x64</Platform>
+    </ProjectConfiguration>
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{B10A2C41-344C-43E0-A32D-B9587C198D8B}</ProjectGuid>
@@ -18,6 +22,13 @@
     <CharacterSet>MultiByte</CharacterSet>
     <PlatformToolset>WDK7</PlatformToolset>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
+    <ConfigurationType>Application</ConfigurationType>
+    <UseDebugLibraries>false</UseDebugLibraries>
+    <WholeProgramOptimization>true</WholeProgramOptimization>
+    <CharacterSet>MultiByte</CharacterSet>
+    <PlatformToolset>WDK7</PlatformToolset>
+  </PropertyGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
   <ImportGroup Label="ExtensionSettings">
   </ImportGroup>
@@ -25,11 +36,19 @@
     <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
     <Import Project="..\xchat.props" />
   </ImportGroup>
+  <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
+    <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
+    <Import Project="..\xchat.props" />
+  </ImportGroup>
   <PropertyGroup Label="UserMacros" />
   <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
     <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
   </PropertyGroup>
+  <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <OutDir>$(SolutionDir)build\$(PlatformName)\bin</OutDir>
+    <IntDir>$(SolutionDir)build\$(PlatformName)\obj\$(ProjectName)</IntDir>
+  </PropertyGroup>
   <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
     <ClCompile>
       <WarningLevel>Level3</WarningLevel>
@@ -53,6 +72,32 @@ mkdir "$(OutDir)\locale"
 for %%A in (*.po) do (
 mkdir "$(OutDir)\locale\%%~nA\LC_MESSAGES"
 "$(DepsRoot)\bin\msgfmt" -co "$(OutDir)\locale\%%~nA\LC_MESSAGES\xchat.mo" %%A
+)</Command>
+    </PreBuildEvent>
+  </ItemDefinitionGroup>
+  <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
+    <ClCompile>
+      <WarningLevel>Level3</WarningLevel>
+      <Optimization>MaxSpeed</Optimization>
+      <FunctionLevelLinking>true</FunctionLevelLinking>
+      <IntrinsicFunctions>true</IntrinsicFunctions>
+    </ClCompile>
+    <Link>
+      <GenerateDebugInformation>true</GenerateDebugInformation>
+      <EnableCOMDATFolding>true</EnableCOMDATFolding>
+      <OptimizeReferences>true</OptimizeReferences>
+    </Link>
+    <PostBuildEvent>
+      <Command>
+      </Command>
+    </PostBuildEvent>
+    <PreBuildEvent>
+      <Command>cd ..\..\po
+rmdir /q /s "$(OutDir)\locale"
+mkdir "$(OutDir)\locale"
+for %%A in (*.po) do (
+mkdir "$(OutDir)\locale\%%~nA\LC_MESSAGES"
+"$(DepsRoot)\bin\msgfmt" -co "$(OutDir)\locale\%%~nA\LC_MESSAGES\xchat.mo" %%A
 )</Command>
     </PreBuildEvent>
   </ItemDefinitionGroup>
diff --git a/win32/xchat.sln b/win32/xchat.sln
index 84e1190e..ef7a3000 100644
--- a/win32/xchat.sln
+++ b/win32/xchat.sln
@@ -121,62 +121,117 @@ EndProject
 Global
 	GlobalSection(SolutionConfigurationPlatforms) = preSolution
 		Release|Win32 = Release|Win32
+		Release|x64 = Release|x64
 	EndGlobalSection
 	GlobalSection(ProjectConfigurationPlatforms) = postSolution
 		{87554B59-006C-4D94-9714-897B27067BA3}.Release|Win32.ActiveCfg = Release|Win32
 		{87554B59-006C-4D94-9714-897B27067BA3}.Release|Win32.Build.0 = Release|Win32
+		{87554B59-006C-4D94-9714-897B27067BA3}.Release|x64.ActiveCfg = Release|x64
+		{87554B59-006C-4D94-9714-897B27067BA3}.Release|x64.Build.0 = Release|x64
 		{98B56DF9-E4F1-4696-A565-5F7823CF214D}.Release|Win32.ActiveCfg = Release|Win32
 		{98B56DF9-E4F1-4696-A565-5F7823CF214D}.Release|Win32.Build.0 = Release|Win32
+		{98B56DF9-E4F1-4696-A565-5F7823CF214D}.Release|x64.ActiveCfg = Release|x64
+		{98B56DF9-E4F1-4696-A565-5F7823CF214D}.Release|x64.Build.0 = Release|x64
 		{626DA61C-FA8B-474C-B2F5-72AD9DFEE642}.Release|Win32.ActiveCfg = Release|Win32
 		{626DA61C-FA8B-474C-B2F5-72AD9DFEE642}.Release|Win32.Build.0 = Release|Win32
+		{626DA61C-FA8B-474C-B2F5-72AD9DFEE642}.Release|x64.ActiveCfg = Release|x64
+		{626DA61C-FA8B-474C-B2F5-72AD9DFEE642}.Release|x64.Build.0 = Release|x64
 		{6CD3647E-4541-4849-9DD7-C8816665AE42}.Release|Win32.ActiveCfg = Release|Win32
 		{6CD3647E-4541-4849-9DD7-C8816665AE42}.Release|Win32.Build.0 = Release|Win32
+		{6CD3647E-4541-4849-9DD7-C8816665AE42}.Release|x64.ActiveCfg = Release|x64
+		{6CD3647E-4541-4849-9DD7-C8816665AE42}.Release|x64.Build.0 = Release|x64
 		{E4BDB4C8-2335-415A-ACEE-BA88B19BFE82}.Release|Win32.ActiveCfg = Release|Win32
 		{E4BDB4C8-2335-415A-ACEE-BA88B19BFE82}.Release|Win32.Build.0 = Release|Win32
+		{E4BDB4C8-2335-415A-ACEE-BA88B19BFE82}.Release|x64.ActiveCfg = Release|x64
+		{E4BDB4C8-2335-415A-ACEE-BA88B19BFE82}.Release|x64.Build.0 = Release|x64
 		{E93E1255-95D1-4B08-8FDF-B53CC6A21280}.Release|Win32.ActiveCfg = Release|Win32
 		{E93E1255-95D1-4B08-8FDF-B53CC6A21280}.Release|Win32.Build.0 = Release|Win32
+		{E93E1255-95D1-4B08-8FDF-B53CC6A21280}.Release|x64.ActiveCfg = Release|x64
+		{E93E1255-95D1-4B08-8FDF-B53CC6A21280}.Release|x64.Build.0 = Release|x64
 		{2773666A-8CFC-4533-A043-EAD59F16A1C7}.Release|Win32.ActiveCfg = Release|Win32
 		{2773666A-8CFC-4533-A043-EAD59F16A1C7}.Release|Win32.Build.0 = Release|Win32
+		{2773666A-8CFC-4533-A043-EAD59F16A1C7}.Release|x64.ActiveCfg = Release|x64
+		{2773666A-8CFC-4533-A043-EAD59F16A1C7}.Release|x64.Build.0 = Release|x64
 		{987E9374-98A1-44BA-946F-D3472D7A7055}.Release|Win32.ActiveCfg = Release|Win32
 		{987E9374-98A1-44BA-946F-D3472D7A7055}.Release|Win32.Build.0 = Release|Win32
+		{987E9374-98A1-44BA-946F-D3472D7A7055}.Release|x64.ActiveCfg = Release|x64
+		{987E9374-98A1-44BA-946F-D3472D7A7055}.Release|x64.Build.0 = Release|x64
 		{C4C9FA6F-F990-4C7B-85F6-CD8F4F5728F0}.Release|Win32.ActiveCfg = Release|Win32
 		{C4C9FA6F-F990-4C7B-85F6-CD8F4F5728F0}.Release|Win32.Build.0 = Release|Win32
+		{C4C9FA6F-F990-4C7B-85F6-CD8F4F5728F0}.Release|x64.ActiveCfg = Release|x64
+		{C4C9FA6F-F990-4C7B-85F6-CD8F4F5728F0}.Release|x64.Build.0 = Release|x64
 		{58654438-F674-42F7-88FA-73EF90AD80B1}.Release|Win32.ActiveCfg = Release|Win32
 		{58654438-F674-42F7-88FA-73EF90AD80B1}.Release|Win32.Build.0 = Release|Win32
+		{58654438-F674-42F7-88FA-73EF90AD80B1}.Release|x64.ActiveCfg = Release|x64
+		{58654438-F674-42F7-88FA-73EF90AD80B1}.Release|x64.Build.0 = Release|x64
 		{19C52A0A-A790-409E-A28A-9745FF990F5C}.Release|Win32.ActiveCfg = Release|Win32
 		{19C52A0A-A790-409E-A28A-9745FF990F5C}.Release|Win32.Build.0 = Release|Win32
+		{19C52A0A-A790-409E-A28A-9745FF990F5C}.Release|x64.ActiveCfg = Release|x64
+		{19C52A0A-A790-409E-A28A-9745FF990F5C}.Release|x64.Build.0 = Release|x64
 		{646B4316-C8B8-4DB6-B6AE-E586929E5729}.Release|Win32.ActiveCfg = Release|Win32
 		{646B4316-C8B8-4DB6-B6AE-E586929E5729}.Release|Win32.Build.0 = Release|Win32
+		{646B4316-C8B8-4DB6-B6AE-E586929E5729}.Release|x64.ActiveCfg = Release|x64
+		{646B4316-C8B8-4DB6-B6AE-E586929E5729}.Release|x64.Build.0 = Release|x64
 		{4980AF24-9D42-427D-A8E6-0DF3B97C455D}.Release|Win32.ActiveCfg = Release|Win32
 		{4980AF24-9D42-427D-A8E6-0DF3B97C455D}.Release|Win32.Build.0 = Release|Win32
+		{4980AF24-9D42-427D-A8E6-0DF3B97C455D}.Release|x64.ActiveCfg = Release|x64
+		{4980AF24-9D42-427D-A8E6-0DF3B97C455D}.Release|x64.Build.0 = Release|x64
 		{5EF7F47D-D09C-43C4-BF64-B28B11A0FF91}.Release|Win32.ActiveCfg = Release|Win32
 		{5EF7F47D-D09C-43C4-BF64-B28B11A0FF91}.Release|Win32.Build.0 = Release|Win32
+		{5EF7F47D-D09C-43C4-BF64-B28B11A0FF91}.Release|x64.ActiveCfg = Release|x64
+		{5EF7F47D-D09C-43C4-BF64-B28B11A0FF91}.Release|x64.Build.0 = Release|x64
 		{3786FA8C-3E76-45E3-984E-FCCFF44729C9}.Release|Win32.ActiveCfg = Release|Win32
 		{3786FA8C-3E76-45E3-984E-FCCFF44729C9}.Release|Win32.Build.0 = Release|Win32
+		{3786FA8C-3E76-45E3-984E-FCCFF44729C9}.Release|x64.ActiveCfg = Release|x64
+		{3786FA8C-3E76-45E3-984E-FCCFF44729C9}.Release|x64.Build.0 = Release|x64
 		{17E4BE39-76F7-4A06-AD21-EFD0C5091F76}.Release|Win32.ActiveCfg = Release|Win32
 		{17E4BE39-76F7-4A06-AD21-EFD0C5091F76}.Release|Win32.Build.0 = Release|Win32
+		{17E4BE39-76F7-4A06-AD21-EFD0C5091F76}.Release|x64.ActiveCfg = Release|x64
+		{17E4BE39-76F7-4A06-AD21-EFD0C5091F76}.Release|x64.Build.0 = Release|x64
 		{3C4F42FC-292A-420B-B63D-C03DFBDD8E4E}.Release|Win32.ActiveCfg = Release|Win32
 		{3C4F42FC-292A-420B-B63D-C03DFBDD8E4E}.Release|Win32.Build.0 = Release|Win32
+		{3C4F42FC-292A-420B-B63D-C03DFBDD8E4E}.Release|x64.ActiveCfg = Release|x64
+		{3C4F42FC-292A-420B-B63D-C03DFBDD8E4E}.Release|x64.Build.0 = Release|x64
 		{B0E36D93-CA2A-49FE-9EB9-9C96C6016EEC}.Release|Win32.ActiveCfg = Release|Win32
 		{B0E36D93-CA2A-49FE-9EB9-9C96C6016EEC}.Release|Win32.Build.0 = Release|Win32
+		{B0E36D93-CA2A-49FE-9EB9-9C96C6016EEC}.Release|x64.ActiveCfg = Release|x64
+		{B0E36D93-CA2A-49FE-9EB9-9C96C6016EEC}.Release|x64.Build.0 = Release|x64
 		{461DC24A-A410-4171-8C02-CCDBF3702C2A}.Release|Win32.ActiveCfg = Release|Win32
 		{461DC24A-A410-4171-8C02-CCDBF3702C2A}.Release|Win32.Build.0 = Release|Win32
+		{461DC24A-A410-4171-8C02-CCDBF3702C2A}.Release|x64.ActiveCfg = Release|x64
+		{461DC24A-A410-4171-8C02-CCDBF3702C2A}.Release|x64.Build.0 = Release|x64
 		{E78C0D9A-798E-4BF6-B0CC-6FECB8CA2FCE}.Release|Win32.ActiveCfg = Release|Win32
 		{E78C0D9A-798E-4BF6-B0CC-6FECB8CA2FCE}.Release|Win32.Build.0 = Release|Win32
+		{E78C0D9A-798E-4BF6-B0CC-6FECB8CA2FCE}.Release|x64.ActiveCfg = Release|x64
+		{E78C0D9A-798E-4BF6-B0CC-6FECB8CA2FCE}.Release|x64.Build.0 = Release|x64
 		{6C0CA980-97C5-427A-BE61-5BCECAFABBDA}.Release|Win32.ActiveCfg = Release|Win32
 		{6C0CA980-97C5-427A-BE61-5BCECAFABBDA}.Release|Win32.Build.0 = Release|Win32
+		{6C0CA980-97C5-427A-BE61-5BCECAFABBDA}.Release|x64.ActiveCfg = Release|x64
+		{6C0CA980-97C5-427A-BE61-5BCECAFABBDA}.Release|x64.Build.0 = Release|x64
 		{18871EBA-AC85-4652-8919-EB8064B9A714}.Release|Win32.ActiveCfg = Release|Win32
 		{18871EBA-AC85-4652-8919-EB8064B9A714}.Release|Win32.Build.0 = Release|Win32
+		{18871EBA-AC85-4652-8919-EB8064B9A714}.Release|x64.ActiveCfg = Release|x64
+		{18871EBA-AC85-4652-8919-EB8064B9A714}.Release|x64.Build.0 = Release|x64
 		{3024CF36-85E5-4E00-9608-7002E2C7EF14}.Release|Win32.ActiveCfg = Release|Win32
 		{3024CF36-85E5-4E00-9608-7002E2C7EF14}.Release|Win32.Build.0 = Release|Win32
+		{3024CF36-85E5-4E00-9608-7002E2C7EF14}.Release|x64.ActiveCfg = Release|x64
+		{3024CF36-85E5-4E00-9608-7002E2C7EF14}.Release|x64.Build.0 = Release|x64
 		{E7F4DB0A-510D-41EF-B284-6E1DE1CC450D}.Release|Win32.ActiveCfg = Release|Win32
 		{E7F4DB0A-510D-41EF-B284-6E1DE1CC450D}.Release|Win32.Build.0 = Release|Win32
+		{E7F4DB0A-510D-41EF-B284-6E1DE1CC450D}.Release|x64.ActiveCfg = Release|x64
+		{E7F4DB0A-510D-41EF-B284-6E1DE1CC450D}.Release|x64.Build.0 = Release|x64
 		{B10A2C41-344C-43E0-A32D-B9587C198D8B}.Release|Win32.ActiveCfg = Release|Win32
 		{B10A2C41-344C-43E0-A32D-B9587C198D8B}.Release|Win32.Build.0 = Release|Win32
+		{B10A2C41-344C-43E0-A32D-B9587C198D8B}.Release|x64.ActiveCfg = Release|x64
+		{B10A2C41-344C-43E0-A32D-B9587C198D8B}.Release|x64.Build.0 = Release|x64
 		{C9B735E4-75BC-45AC-A5E3-39A6D076F912}.Release|Win32.ActiveCfg = Release|Win32
 		{C9B735E4-75BC-45AC-A5E3-39A6D076F912}.Release|Win32.Build.0 = Release|Win32
+		{C9B735E4-75BC-45AC-A5E3-39A6D076F912}.Release|x64.ActiveCfg = Release|x64
+		{C9B735E4-75BC-45AC-A5E3-39A6D076F912}.Release|x64.Build.0 = Release|x64
 		{5A0F4962-E670-4DA2-9E45-52CC47F26E2F}.Release|Win32.ActiveCfg = Release|Win32
 		{5A0F4962-E670-4DA2-9E45-52CC47F26E2F}.Release|Win32.Build.0 = Release|Win32
+		{5A0F4962-E670-4DA2-9E45-52CC47F26E2F}.Release|x64.ActiveCfg = Release|x64
+		{5A0F4962-E670-4DA2-9E45-52CC47F26E2F}.Release|x64.Build.0 = Release|x64
 	EndGlobalSection
 	GlobalSection(SolutionProperties) = preSolution
 		HideSolutionNode = FALSE
-- 
cgit 1.4.1


From c1ed097b46d2679929edc5d35f848c30a6286992 Mon Sep 17 00:00:00 2001
From: Berke Viktor <berkeviktor@aol.com>
Date: Fri, 15 Jun 2012 22:48:18 +0200
Subject: Add .user files and .gitignore

---
 .gitignore                             | 5 +++++
 plugins/checksum/checksum.vcxproj.user | 3 +++
 plugins/dns/dns.vcxproj.user           | 3 +++
 plugins/doat/doat.vcxproj.user         | 3 +++
 plugins/exec/exec.vcxproj.user         | 3 +++
 plugins/fishlim/fishlim.vcxproj.user   | 3 +++
 plugins/lua/lua.vcxproj.user           | 3 +++
 plugins/mpcinfo/mpcinfo.vcxproj.user   | 3 +++
 plugins/perl/perl-512.vcxproj.user     | 3 +++
 plugins/perl/perl-514.vcxproj.user     | 3 +++
 plugins/perl/perl-516.vcxproj.user     | 3 +++
 plugins/python/python.vcxproj.user     | 3 +++
 plugins/tcl/tcl.vcxproj.user           | 3 +++
 plugins/upd/upd.vcxproj.user           | 3 +++
 plugins/winamp/winamp.vcxproj.user     | 3 +++
 plugins/winsys/winsys.vcxproj.user     | 3 +++
 plugins/wmpa/wmpa.vcxproj.user         | 3 +++
 plugins/xsasl/xsasl.vcxproj.user       | 3 +++
 plugins/xtray/xtray.vcxproj.user       | 3 +++
 src/common/common.vcxproj.user         | 3 +++
 src/dirent/dirent.vcxproj.user         | 3 +++
 src/fe-gtk/fe-gtk.vcxproj.user         | 3 +++
 src/fe-text/fe-text.vcxproj.user       | 3 +++
 src/pixmaps/pixmaps.vcxproj.user       | 3 +++
 src/version/version.vcxproj.user       | 3 +++
 win32/copy/copy.vcxproj.user           | 3 +++
 win32/installer/installer.vcxproj.user | 3 +++
 win32/nls/nls.vcxproj.user             | 3 +++
 28 files changed, 86 insertions(+)
 create mode 100644 .gitignore
 create mode 100644 plugins/checksum/checksum.vcxproj.user
 create mode 100644 plugins/dns/dns.vcxproj.user
 create mode 100644 plugins/doat/doat.vcxproj.user
 create mode 100644 plugins/exec/exec.vcxproj.user
 create mode 100644 plugins/fishlim/fishlim.vcxproj.user
 create mode 100644 plugins/lua/lua.vcxproj.user
 create mode 100644 plugins/mpcinfo/mpcinfo.vcxproj.user
 create mode 100644 plugins/perl/perl-512.vcxproj.user
 create mode 100644 plugins/perl/perl-514.vcxproj.user
 create mode 100644 plugins/perl/perl-516.vcxproj.user
 create mode 100644 plugins/python/python.vcxproj.user
 create mode 100644 plugins/tcl/tcl.vcxproj.user
 create mode 100644 plugins/upd/upd.vcxproj.user
 create mode 100644 plugins/winamp/winamp.vcxproj.user
 create mode 100644 plugins/winsys/winsys.vcxproj.user
 create mode 100644 plugins/wmpa/wmpa.vcxproj.user
 create mode 100644 plugins/xsasl/xsasl.vcxproj.user
 create mode 100644 plugins/xtray/xtray.vcxproj.user
 create mode 100644 src/common/common.vcxproj.user
 create mode 100644 src/dirent/dirent.vcxproj.user
 create mode 100644 src/fe-gtk/fe-gtk.vcxproj.user
 create mode 100644 src/fe-text/fe-text.vcxproj.user
 create mode 100644 src/pixmaps/pixmaps.vcxproj.user
 create mode 100644 src/version/version.vcxproj.user
 create mode 100644 win32/copy/copy.vcxproj.user
 create mode 100644 win32/installer/installer.vcxproj.user
 create mode 100644 win32/nls/nls.vcxproj.user

(limited to 'plugins')

diff --git a/.gitignore b/.gitignore
new file mode 100644
index 00000000..83f00b41
--- /dev/null
+++ b/.gitignore
@@ -0,0 +1,5 @@
+# git ignore file
+win32/xchat.opensdf
+win32/xchat.sdf
+win32/xchat.suo
+src/pixmaps/inline_pngs.h
diff --git a/plugins/checksum/checksum.vcxproj.user b/plugins/checksum/checksum.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/plugins/checksum/checksum.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/plugins/dns/dns.vcxproj.user b/plugins/dns/dns.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/plugins/dns/dns.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/plugins/doat/doat.vcxproj.user b/plugins/doat/doat.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/plugins/doat/doat.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/plugins/exec/exec.vcxproj.user b/plugins/exec/exec.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/plugins/exec/exec.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/plugins/fishlim/fishlim.vcxproj.user b/plugins/fishlim/fishlim.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/plugins/fishlim/fishlim.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/plugins/lua/lua.vcxproj.user b/plugins/lua/lua.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/plugins/lua/lua.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/plugins/mpcinfo/mpcinfo.vcxproj.user b/plugins/mpcinfo/mpcinfo.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/plugins/mpcinfo/mpcinfo.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/plugins/perl/perl-512.vcxproj.user b/plugins/perl/perl-512.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/plugins/perl/perl-512.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/plugins/perl/perl-514.vcxproj.user b/plugins/perl/perl-514.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/plugins/perl/perl-514.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/plugins/perl/perl-516.vcxproj.user b/plugins/perl/perl-516.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/plugins/perl/perl-516.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/plugins/python/python.vcxproj.user b/plugins/python/python.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/plugins/python/python.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/plugins/tcl/tcl.vcxproj.user b/plugins/tcl/tcl.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/plugins/tcl/tcl.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/plugins/upd/upd.vcxproj.user b/plugins/upd/upd.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/plugins/upd/upd.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/plugins/winamp/winamp.vcxproj.user b/plugins/winamp/winamp.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/plugins/winamp/winamp.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/plugins/winsys/winsys.vcxproj.user b/plugins/winsys/winsys.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/plugins/winsys/winsys.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/plugins/wmpa/wmpa.vcxproj.user b/plugins/wmpa/wmpa.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/plugins/wmpa/wmpa.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/plugins/xsasl/xsasl.vcxproj.user b/plugins/xsasl/xsasl.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/plugins/xsasl/xsasl.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/plugins/xtray/xtray.vcxproj.user b/plugins/xtray/xtray.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/plugins/xtray/xtray.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/src/common/common.vcxproj.user b/src/common/common.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/src/common/common.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/src/dirent/dirent.vcxproj.user b/src/dirent/dirent.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/src/dirent/dirent.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/src/fe-gtk/fe-gtk.vcxproj.user b/src/fe-gtk/fe-gtk.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/src/fe-gtk/fe-gtk.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/src/fe-text/fe-text.vcxproj.user b/src/fe-text/fe-text.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/src/fe-text/fe-text.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/src/pixmaps/pixmaps.vcxproj.user b/src/pixmaps/pixmaps.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/src/pixmaps/pixmaps.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/src/version/version.vcxproj.user b/src/version/version.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/src/version/version.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/win32/copy/copy.vcxproj.user b/win32/copy/copy.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/win32/copy/copy.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/win32/installer/installer.vcxproj.user b/win32/installer/installer.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/win32/installer/installer.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
diff --git a/win32/nls/nls.vcxproj.user b/win32/nls/nls.vcxproj.user
new file mode 100644
index 00000000..695b5c78
--- /dev/null
+++ b/win32/nls/nls.vcxproj.user
@@ -0,0 +1,3 @@
+<?xml version="1.0" encoding="utf-8"?>
+<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
+</Project>
\ No newline at end of file
-- 
cgit 1.4.1