Index: .bzrignore
===================================================================
--- .bzrignore	(revision bf02a679c61b0f030ee8f2f01698699a7775f7d5)
+++ .bzrignore	(revision bd69a219c0a618354fd80a98dd0d9a04fee755e0)
@@ -2,4 +2,13 @@
 config.h
 bitlbee
+Debug
+Debugx
+deps
+admin/Debug
+admin/admin.plg
+bitlbee.plg
+*.plg
+*.aps
+*.clw
 user-guide.txt
 user-guide.html
Index: Makefile
===================================================================
--- Makefile	(revision bf02a679c61b0f030ee8f2f01698699a7775f7d5)
+++ Makefile	(revision bd69a219c0a618354fd80a98dd0d9a04fee755e0)
@@ -10,6 +10,12 @@
 
 # Program variables
-objects = account.o bitlbee.o commands.o conf.o crypting.o help.o ini.o irc.o log.o nick.o query.o set.o unix.o url.o user.o storage_text.o storage.o
+objects = account.o bitlbee.o commands.o crypting.o help.o ini.o irc.o log.o nick.o query.o set.o url.o user.o storage_text.o storage.o
 subdirs = protocols
+
+ifeq ($(ARCH),Windows)
+objects += win32.o
+else
+objects += unix.o conf.o
+endif
 
 # Expansion of variables
Index: bitlbee.c
===================================================================
--- bitlbee.c	(revision bf02a679c61b0f030ee8f2f01698699a7775f7d5)
+++ bitlbee.c	(revision bd69a219c0a618354fd80a98dd0d9a04fee755e0)
@@ -54,7 +54,4 @@
 	GIOChannel *ch;
 	
-	log_link( LOGLVL_ERROR, LOGOUTPUT_SYSLOG );
-	log_link( LOGLVL_WARNING, LOGOUTPUT_SYSLOG );
-	
 	global.listen_socket = socket( AF_INET, SOCK_STREAM, 0 );
 	if( global.listen_socket == -1 )
@@ -109,7 +106,4 @@
 	if( !irc_new( 0 ) )
 		return( 1 );
-	
-	log_link( LOGLVL_ERROR, LOGOUTPUT_IRC );
-	log_link( LOGLVL_WARNING, LOGOUTPUT_IRC );
 	
 	return( 0 );
Index: doc/BUILD.win32
===================================================================
--- doc/BUILD.win32	(revision bd69a219c0a618354fd80a98dd0d9a04fee755e0)
+++ doc/BUILD.win32	(revision bd69a219c0a618354fd80a98dd0d9a04fee755e0)
@@ -0,0 +1,32 @@
+Instructions for building BitlBee on Windows 
+================================================
+
+1. Download the latest version using bzr (http://www.bazaar-ng.org/):
+
+   H:\> bzr branch http://win32.bitlbee.org/bzr bitlbee-win32
+   ...
+
+2. Download and install the required development files: 
+    from ftp://ftp.gtk.org/pub/gtk/v2.8/win32/
+    - glib
+    - glib-dev
+    - libiconv (in dependencies/)
+    - gettext (in dependencies/)
+    from http://ftp.mozilla.org/pub/mozilla.org/
+    - nss (in security/nss/)
+    - nspr (in nspr/)
+
+3. Set the following variables in Makefile.settings, if you don't have the 
+   libraries above installed in the default directories searched by MSVC:
+
+   - GLIB_DIR
+   - NSS_DIR
+   - NSPR_DIR
+
+4. Build:
+
+	H:\BitlBee> nmake /f win32.mk
+	...
+
+5. To build setup files, compile the bitlbee.iss file using the Inno Setup 
+   program (available from www.jrsoftware.org).
Index: protocols/nogaim.h
===================================================================
--- protocols/nogaim.h	(revision bf02a679c61b0f030ee8f2f01698699a7775f7d5)
+++ protocols/nogaim.h	(revision bd69a219c0a618354fd80a98dd0d9a04fee755e0)
@@ -159,4 +159,23 @@
 	irc_t *irc;
 };
+
+struct ft 
+{
+	const char *filename;
+	
+	/* Total number of bytes in file */
+	size_t total_bytes;
+	
+	/* Current number of bytes received */
+	size_t cur_bytes;
+};
+
+struct ft_request 
+{
+	const char *filename;
+	struct gaim_connection *gc;
+};
+
+typedef void (*ft_recv_handler) (struct ft *, void *data, size_t len);
 
 struct prpl {
@@ -215,4 +234,9 @@
 	void (* group_buddy)	(struct gaim_connection *, char *who, char *old_group, char *new_group);
 
+	/* file transfers */
+	struct ft_send_req *(* req_send_file) (struct gaim_connection *, const char *file);
+	void (* send_file_part) (struct gaim_connection *, struct ft*, void *data, size_t length);
+	void (* accept_recv_file) (struct gaim_connection *, struct ft*, ft_recv_handler);
+
 	void (* buddy_free)	(struct buddy *);
 
Index: unix.c
===================================================================
--- unix.c	(revision bf02a679c61b0f030ee8f2f01698699a7775f7d5)
+++ unix.c	(revision bd69a219c0a618354fd80a98dd0d9a04fee755e0)
@@ -61,4 +61,7 @@
 	if( global.conf->runmode == RUNMODE_INETD )
 	{
+		log_link( LOGLVL_ERROR, LOGOUTPUT_IRC );
+		log_link( LOGLVL_WARNING, LOGOUTPUT_IRC );
+	
 		i = bitlbee_inetd_init();
 		log_message( LOGLVL_INFO, "Bitlbee %s starting in inetd mode.", BITLBEE_VERSION );
@@ -67,4 +70,7 @@
 	else if( global.conf->runmode == RUNMODE_DAEMON )
 	{
+		log_link( LOGLVL_ERROR, LOGOUTPUT_SYSLOG );
+		log_link( LOGLVL_WARNING, LOGOUTPUT_SYSLOG );
+
 		i = bitlbee_daemon_init();
 		log_message( LOGLVL_INFO, "Bitlbee %s starting in daemon mode.", BITLBEE_VERSION );
Index: win32.c
===================================================================
--- win32.c	(revision bd69a219c0a618354fd80a98dd0d9a04fee755e0)
+++ win32.c	(revision bd69a219c0a618354fd80a98dd0d9a04fee755e0)
@@ -0,0 +1,315 @@
+  /********************************************************************\
+  * BitlBee -- An IRC to other IM-networks gateway                     *
+  *                                                                    *
+  * Copyright 2002-2004 Wilmer van der Gaast and others                *
+  \********************************************************************/
+
+/* Main file (Windows specific part)                                   */
+
+/*
+  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 with
+  the Debian GNU/Linux distribution in /usr/share/common-licenses/GPL;
+  if not, write to the Free Software Foundation, Inc., 59 Temple Place,
+  Suite 330, Boston, MA  02111-1307  USA
+*/
+
+#define BITLBEE_CORE
+#include "bitlbee.h"
+#include "commands.h"
+#include "crypting.h"
+#include "protocols/nogaim.h"
+#include "help.h"
+#include <signal.h>
+#include <windows.h>
+
+global_t global;	/* Against global namespace pollution */
+
+static void WINAPI service_ctrl (DWORD dwControl)
+{
+	switch (dwControl)
+	{
+        case SERVICE_CONTROL_STOP:
+			/* FIXME */
+            break;
+
+        case SERVICE_CONTROL_INTERROGATE:
+            break;
+
+        default:
+            break;
+
+    }
+}
+
+static void bitlbee_init(int argc, char **argv)
+{
+	int i = -1;
+	memset( &global, 0, sizeof( global_t ) );
+	
+	global.loop = g_main_new( FALSE );
+	
+	global.conf = conf_load( argc, argv );
+	if( global.conf == NULL )
+		return;
+	
+	if( global.conf->runmode == RUNMODE_INETD )
+	{
+		i = bitlbee_inetd_init();
+		log_message( LOGLVL_INFO, "Bitlbee %s starting in inetd mode.", BITLBEE_VERSION );
+
+	}
+	else if( global.conf->runmode == RUNMODE_DAEMON )
+	{
+		i = bitlbee_daemon_init();
+		log_message( LOGLVL_INFO, "Bitlbee %s starting in daemon mode.", BITLBEE_VERSION );
+	} 
+	else 
+	{
+		log_message( LOGLVL_INFO, "No bitlbee mode specified...");
+	}
+	
+	if( i != 0 )
+		return;
+ 	
+	if( access( global.conf->configdir, F_OK ) != 0 )
+		log_message( LOGLVL_WARNING, "The configuration directory %s does not exist. Configuration won't be saved.", global.conf->configdir );
+	else if( access( global.conf->configdir, 06 ) != 0 )
+		log_message( LOGLVL_WARNING, "Permission problem: Can't read/write from/to %s.", global.conf->configdir );
+	if( help_init( &(global.help) ) == NULL )
+		log_message( LOGLVL_WARNING, "Error opening helpfile %s.", global.helpfile );
+}
+
+void service_main (DWORD argc, LPTSTR *argv)
+{
+	SERVICE_STATUS_HANDLE handle;
+	SERVICE_STATUS status;
+
+    handle = RegisterServiceCtrlHandler("bitlbee", service_ctrl);
+
+    if (!handle)
+		return;
+
+    status.dwServiceType = SERVICE_WIN32_OWN_PROCESS;
+    status.dwServiceSpecificExitCode = 0;
+
+	bitlbee_init(argc, argv);
+
+	SetServiceStatus(handle, &status);
+	
+	g_main_run( global.loop );
+}
+
+SERVICE_TABLE_ENTRY dispatch_table[] =
+{
+   { TEXT("bitlbee"), (LPSERVICE_MAIN_FUNCTION)service_main },
+   { NULL, NULL }
+};
+
+static int debug = 0;
+
+static void usage()
+{
+	printf("Options:\n");
+	printf("-h   Show this help message\n");
+	printf("-d   Debug mode (simple console program)\n");
+}
+
+int main( int argc, char **argv)
+{    
+	int i;
+	WSADATA WSAData;
+
+	nogaim_init( );
+
+	for (i = 1; i < argc; i++) {
+		if (!strcmp(argv[i], "-d")) debug = 1;
+		if (!strcmp(argv[i], "-h")) {
+			usage();
+			return 0;
+		}
+	}
+
+    WSAStartup(MAKEWORD(1,1), &WSAData);
+
+	if (!debug) {
+		if (!StartServiceCtrlDispatcher(dispatch_table))
+			log_message( LOGLVL_ERROR, "StartServiceCtrlDispatcher failed.");
+	} else {
+			bitlbee_init(argc, argv);
+ 			g_main_run( global.loop );
+	}
+	
+	return 0;
+}
+
+double gettime()
+{
+	return (GetTickCount() / 1000);
+}
+
+void conf_get_string(HKEY section, const char *name, const char *def, char **dest)
+{
+	char buf[4096];
+	long x;
+	if (RegQueryValue(section, name, buf, &x) == ERROR_SUCCESS) {
+		*dest = g_strdup(buf);
+	} else if (!def) {
+		*dest = NULL;
+	} else {
+		*dest = g_strdup(def);
+	}
+}
+
+
+void conf_get_int(HKEY section, const char *name, int def, int *dest)
+{
+	char buf[20];
+	long x;
+	DWORD y;
+	if (RegQueryValue(section, name, buf, &x) == ERROR_SUCCESS) {
+		memcpy(&y, buf, sizeof(DWORD));
+		*dest = y;
+	} else {
+		*dest = def;
+	}
+}
+
+conf_t *conf_load( int argc, char *argv[] ) 
+{
+	conf_t *conf;
+	HKEY key, key_main, key_proxy;
+	char *tmp;
+
+	RegOpenKey(HKEY_CURRENT_USER, "SOFTWARE\\Bitlbee", &key);
+	RegOpenKey(key, "main", &key_main);
+	RegOpenKey(key, "proxy", &key_proxy);
+	
+	memset( &global, 0, sizeof( global_t ) );
+	global.loop = g_main_new(FALSE);
+
+	conf = g_new0( conf_t,1 );
+	global.conf = conf;
+	conf_get_string(key_main, "interface", "0.0.0.0", &global.conf->iface);
+	conf_get_int(key_main, "port", 6667, &global.conf->port);
+	conf_get_int(key_main, "verbose", 0, &global.conf->verbose);
+	conf_get_string(key_main, "password", "", &global.conf->password);
+	conf_get_int(key_main, "ping_interval_timeout", 60, &global.conf->ping_interval);
+	conf_get_string(key_main, "hostname", "localhost", &global.conf->hostname);
+	conf_get_string(key_main, "configdir", NULL, &global.conf->configdir);
+	conf_get_string(key_main, "motdfile", NULL, &global.conf->motdfile);
+	conf_get_string(key_main, "helpfile", NULL, &global.helpfile);
+	global.conf->runmode = RUNMODE_DAEMON;
+	conf_get_int(key_main, "AuthMode", AUTHMODE_OPEN, &global.conf->authmode);
+	conf_get_string(key_proxy, "host", "", &tmp); strcpy(proxyhost, tmp);
+	conf_get_string(key_proxy, "user", "", &tmp); strcpy(proxyuser, tmp);
+	conf_get_string(key_proxy, "password", "", &tmp); strcpy(proxypass, tmp);
+	conf_get_int(key_proxy, "type", PROXY_NONE, &proxytype);
+	conf_get_int(key_proxy, "port", 3128, &proxyport);
+
+	RegCloseKey(key);
+	RegCloseKey(key_main);
+	RegCloseKey(key_proxy);
+
+	return conf;
+}
+
+void conf_loaddefaults( irc_t *irc )
+{
+	HKEY key_defaults;
+	int i;
+	char name[4096], data[4096];
+	DWORD namelen = sizeof(name), datalen = sizeof(data);
+	DWORD type;
+	if (RegOpenKey(HKEY_LOCAL_MACHINE, "SOFTWARE\\Bitlbee\\defaults", &key_defaults) != ERROR_SUCCESS) {
+		return;
+	}
+
+	for (i = 0; RegEnumValue(key_defaults, i, name, &namelen, NULL, &type, data, &datalen) == ERROR_SUCCESS; i++) {
+		set_t *s = set_find( irc, name );
+			
+		if( s )
+		{
+			if( s->def ) g_free( s->def );
+			s->def = g_strdup( data );
+		}
+
+		namelen = sizeof(name);
+		datalen = sizeof(data);
+	}
+
+	RegCloseKey(key_defaults);
+}
+
+#ifndef INADDR_NONE
+#define INADDR_NONE 0xffffffff
+#endif
+
+int
+inet_aton(const char *cp, struct in_addr *addr)
+{
+  addr->s_addr = inet_addr(cp);
+  return (addr->s_addr == INADDR_NONE) ? 0 : 1;
+}
+
+void log_error(char *msg)
+{
+	log_message(LOGLVL_ERROR, "%s", msg);
+}
+
+void log_message(int level, char *message, ...)
+{
+    HANDLE  hEventSource;
+    LPTSTR  lpszStrings[2];
+	WORD elevel;
+    va_list ap;
+
+    va_start(ap, message);
+
+	if (debug) {
+		vprintf(message, ap);
+		putchar('\n');
+		va_end(ap);
+		return;
+	}
+
+    hEventSource = RegisterEventSource(NULL, TEXT("bitlbee"));
+
+    lpszStrings[0] = TEXT("bitlbee");
+    lpszStrings[1] = g_strdup_vprintf(message, ap);
+    va_end(ap);
+
+	switch (level) {
+	case LOGLVL_ERROR: elevel = EVENTLOG_ERROR_TYPE; break;
+	case LOGLVL_WARNING: elevel = EVENTLOG_WARNING_TYPE; break;
+	case LOGLVL_INFO: elevel = EVENTLOG_INFORMATION_TYPE; break;
+#ifdef DEBUG
+	case LOGLVL_DEBUG: elevel = EVENTLOG_AUDIT_SUCCESS; break;
+#endif
+	}
+
+    if (hEventSource != NULL) {
+        ReportEvent(hEventSource, 
+        elevel,
+        0,                    
+        0,                    
+        NULL,                 
+        2,                    
+        0,                    
+        lpszStrings,          
+        NULL);                
+
+        DeregisterEventSource(hEventSource);
+    }
+
+	g_free(lpszStrings[1]);
+}
Index: win32.mk
===================================================================
--- win32.mk	(revision bd69a219c0a618354fd80a98dd0d9a04fee755e0)
+++ win32.mk	(revision bd69a219c0a618354fd80a98dd0d9a04fee755e0)
@@ -0,0 +1,136 @@
+!INCLUDE Makefile.settings
+
+GLIB_CFLAGS = /I "$(GLIB_DIR)\include" \
+	      /I "$(GLIB_DIR)\include\glib-2.0" \
+	      /I "$(GLIB_DIR)\lib\glib-2.0\include"
+
+GLIB_LFLAGS = /libpath:"$(GLIB_DIR)\lib" 
+
+NSS_CFLAGS = /I "$(NSS_DIR)\include" /I "$(NSPR_DIR)\include"
+NSS_LFLAGS = /libpath:"$(NSS_DIR)\lib" /libpath:"$(NSPR_DIR)\lib" 
+NSS_LIBS = nss3.lib ssl3.lib libnspr4.lib
+
+COMMON_LIBS = kernel32.lib user32.lib advapi32.lib shell32.lib iconv.lib \
+			glib-2.0.lib gmodule-2.0.lib wsock32.lib advapi32.lib 
+
+
+MAIN_OBJS = account.obj bitlbee.obj commands.obj crypting.obj \
+	help.obj irc.obj protocols\md5.obj protocols\nogaim.obj \
+	protocols\sha.obj protocols\proxy.obj query.obj nick.obj set.obj \
+	user.obj protocols\util.obj win32.obj 
+
+MAIN_LIBS = $(COMMON_LIBS)
+
+SSL_OBJS = protocols\ssl_nss.obj
+SSL_LIBS = $(NSS_LFLAGS) $(NSS_LIBS)
+
+MSN_OBJS = \
+	protocols\msn\msn.obj \
+	protocols\msn\msn_util.obj \
+	protocols\msn\ns.obj \
+	protocols\msn\passport.obj \
+	protocols\msn\sb.obj \
+	protocols\msn\tables.obj \
+	$(SSL_OBJS)
+
+MSN_LIBS = $(COMMON_LIBS) $(SSL_LIBS)
+
+OSCAR_OBJS = \
+	protocols\oscar\admin.obj \
+	protocols\oscar\auth.obj \
+	protocols\oscar\bos.obj \
+	protocols\oscar\buddylist.obj \
+	protocols\oscar\chat.obj \
+	protocols\oscar\chatnav.obj \
+	protocols\oscar\conn.obj \
+	protocols\oscar\icq.obj \
+	protocols\oscar\im.obj \
+	protocols\oscar\info.obj \
+	protocols\oscar\misc.obj \
+	protocols\oscar\msgcookie.obj \
+	protocols\oscar\oscar.obj \
+	protocols\oscar\oscar_util.obj \
+	protocols\oscar\rxhandlers.obj \
+	protocols\oscar\rxqueue.obj \
+	protocols\oscar\search.obj \
+	protocols\oscar\service.obj \
+	protocols\oscar\snac.obj \
+	protocols\oscar\ssi.obj \
+	protocols\oscar\stats.obj \
+	protocols\oscar\tlv.obj \
+	protocols\oscar\txqueue.obj
+
+OSCAR_LIBS = $(COMMON_LIBS)
+
+JABBER_OBJS = \
+	protocols\jabber\expat.obj \
+	protocols\jabber\genhash.obj \
+	protocols\jabber\hashtable.obj \
+	protocols\jabber\jabber.obj \
+	protocols\jabber\jconn.obj \
+	protocols\jabber\jid.obj \
+	protocols\jabber\jpacket.obj \
+	protocols\jabber\jutil.obj \
+	protocols\jabber\karma.obj \
+	protocols\jabber\log.obj \
+	protocols\jabber\pool.obj \
+	protocols\jabber\pproxy.obj \
+	protocols\jabber\rate.obj \
+	protocols\jabber\str.obj \
+	protocols\jabber\xhash.obj \
+	protocols\jabber\xmlnode.obj \
+	protocols\jabber\xmlparse.obj \
+	protocols\jabber\xmlrole.obj \
+	protocols\jabber\xmltok.obj \
+	protocols\jabber\xstream.obj \
+	$(SSL_OBJS)
+
+JABBER_LIBS = $(COMMON_LIBS) $(SSL_LIBS)
+
+YAHOO_OBJS = \
+	protocols\yahoo\crypt.obj \
+	protocols\yahoo\libyahoo2.obj \
+	protocols\yahoo\vc50.idb \
+	protocols\yahoo\yahoo.obj \
+	protocols\yahoo\yahoo_fn.obj \
+	protocols\yahoo\yahoo_httplib.obj \
+	protocols\yahoo\yahoo_list.obj \
+	protocols\yahoo\yahoo_util.obj
+
+YAHOO_LIBS = $(COMMON_LIBS)
+
+CC=cl.exe
+CFLAGS=$(GLIB_CFLAGS) $(NSS_CFLAGS) /D NDEBUG /D WIN32 /D _WINDOWS \
+       /I . /I protocols /I protocols\oscar /nologo \
+       /D GLIB2 /D ARCH="\"Windows\"" /D CPU="\"x86\"" \
+       /D PLUGINDIR="plugins"
+
+.c.obj:
+	$(CC) $(CFLAGS) /c /Fo$@ $<
+
+ALL: bitlbee.exe libmsn.dll liboscar.dll libjabber.dll libyahoo.dll
+	
+LINK32=link.exe
+LINK32_FLAGS=/nologo $(GLIB_LFLAGS)
+
+bitlbee.exe: $(DEF_FILE) $(MAIN_OBJS)
+    $(LINK32) $(MAIN_LIBS) $(LINK32_FLAGS) /out:bitlbee.exe $(MAIN_OBJS)
+
+libmsn.dll: $(MSN_OBJS) 
+	$(LINK32) /DLL /SUBSYSTEM:WINDOWS /ENTRY:msn_init $(MSN_LIBS) $(LINK32_FLAGS) /out:libmsn.dll $(MSN_OBJS)
+
+libyahoo.dll: $(YAHOO_OBJS)
+	$(LINK32) /DLL /SUBSYSTEM:WINDOWS /ENTRY:yahoo_init $(YAHOO_LIBS) $(LINK32_FLAGS) /out:libyahoo.dll $(YAHOO_OBJS)
+
+liboscar.dll: $(OSCAR_OBJS)
+	$(LINK32) /DLL /SUBSYSTEM:WINDOWS /ENTRY:oscar_init $(OSCAR_LIBS) $(LINK32_FLAGS) /out:liboscar.dll $(OSCAR_OBJS)
+
+libjabber.dll: $(JABBER_OBJS)
+	$(LINK32) /DLL /SUBSYSTEM:WINDOWS /ENTRY:jabber_init $(JABBER_LIBS) $(LINK32_FLAGS) /out:libjabber.dll $(JABBER_OBJS)
+
+clean:
+	@-erase $(MAIN_OBJS)
+	@-erase $(MSN_OBJS)
+	@-erase $(JABBER_OBJS)
+	@-erase $(OSCAR_OBJS)
+	@-erase $(YAHOO_OBJS)
Index: win32/bitlbee.iss
===================================================================
--- win32/bitlbee.iss	(revision bd69a219c0a618354fd80a98dd0d9a04fee755e0)
+++ win32/bitlbee.iss	(revision bd69a219c0a618354fd80a98dd0d9a04fee755e0)
@@ -0,0 +1,73 @@
+; Inno setup script for Bitlbee
+; (C) 2004-2005 Jelmer Vernooij <jelmer@samba.org>
+
+[Setup]
+AppName=BitlBee
+AppPublisher=The BitlBee Team
+AppPublisherURL=http://www.bitlbee.org/
+AppSupportURL=http://win32.bitlbee.org/
+AppUpdatesURL=http://win32.bitlbee.org/
+AppCopyright=Copyright © 2002-2005 The BitlBee Team
+DefaultDirName={pf}\Bitlbee
+DefaultGroupName=Bitlbee
+LicenseFile=..\COPYING
+InfoAfterFile=README.TXT
+OutputDir=.
+AppVerName=Bitlbee-20050516
+OutputBaseFileName="BitlBee-setup"
+
+[Components]
+Name: main; Description: Main executable and files; Types: full compact custom; Flags: fixed;
+Name: "yahoo"; Description: Yahoo! Messenger support; Types: full;
+Name: "oscar"; Description: AIM/ICQ support; Types: full;
+Name: ssl; Description: SSL Support; Types: full;
+Name: "ssl\msn"; Description: MSN messenger support; Types: full;
+Name: "ssl\jabber"; Description: Jabber support; Types: full;
+Name: docs; Description: Documentation; Types: full;
+
+[Tasks]
+Name: startupicon; Description: "&Automatically start when the computer boots"; GroupDescription: "Other tasks:"; Flags: unchecked
+
+[Files]
+Source: "Release\bitlbee.exe"; DestDir: "{app}"; Flags: ignoreversion; Components: main;
+Source: "Release\libmsn.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: "ssl\msn"
+Source: "Deps\lib\ssl3.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: "ssl"
+Source: "Deps\lib\nss3.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: "ssl"
+Source: "Deps\lib\nssckbi.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: "ssl"
+Source: "Deps\lib\smime3.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: "ssl"
+Source: "Deps\lib\softokn3.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: "ssl"
+Source: "Deps\lib\libplc4.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: "ssl"
+Source: "Deps\lib\libnspr4.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: "ssl"
+Source: "Release\libjabber.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: "ssl\jabber"
+Source: "Release\bitlbee_ssl.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: "ssl"
+Source: "Deps\bin\libglib-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: main;
+Source: "Deps\bin\libgmodule-2.0-0.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: main;
+Source: "Release\liboscar.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: "oscar"
+Source: "Deps\bin\intl.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: main;
+Source: "Deps\bin\iconv.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: main;
+Source: "Release\libyahoo.dll"; DestDir: "{app}"; Flags: ignoreversion; Components: "yahoo"
+Source: "..\motd.txt"; DestDir: "{app}"; Flags: ignoreversion; Components: main;
+Source: "..\doc\help.txt"; DestDir: "{app}"; Flags: ignoreversion; Components: main;
+Source: "..\COPYING"; DestDir: "{app}"; Flags: ignoreversion; Components: main;
+Source: "..\doc\TODO"; DestDir: "{app}"; Flags: ignoreversion; Components: main;
+Source: "..\doc\README"; DestDir: "{app}"; Flags: ignoreversion; Components: main;
+Source: "..\doc\FAQ"; DestDir: "{app}"; Flags: ignoreversion; Components: docs;
+Source: "..\doc\CREDITS"; DestDir: "{app}"; Flags: ignoreversion; Components: main;
+; Source: "..\doc\user-guide.pdf"; DestDir: "{app}"; Flags: ignoreversion; Components: docs;
+Source: "..\doc\CHANGES"; DestDir: "{app}"; Flags: ignoreversion; Components: main;
+Source: "..\doc\AUTHORS"; DestDir: "{app}"; Flags: ignoreversion; Components: main;
+; NOTE: Don't use "Flags: ignoreversion" on any shared system files
+
+[Icons]
+Name: "{group}\Bitlbee"; Filename: "{app}\bitlbee.exe"
+Name: "{commonstartup}\Bitlbee"; Filename: "{app}\bitlbee.exe"; Tasks: startupicon
+
+
+[Run]
+; NOTE: The following entry contains an English phrase ("Launch"). You are free to translate it into another language if required.
+Filename: "{app}\bitlbee.exe"; Description: "Launch Bitlbee"; Flags: nowait postinstall skipifsilent
+
+[Registry]
+Root: HKLM; Subkey: "SOFTWARE\Bitlbee"; ValueType: string; ValueName: "helpfile"; ValueData: "{app}\help.txt"
+Root: HKLM; Subkey: "SOFTWARE\Bitlbee"; ValueType: string; ValueName: "motdfile"; ValueData: "{app}\motd.txt"
+Root: HKLM; Subkey: "SOFTWARE\Bitlbee"; ValueType: string; ValueName: "configdir"; ValueData: "{userappdata}\Bitlbee"
