 diff -Naur vim72/src/os_beos.h vim72.haiku/src/os_beos.h
 --- vim72/src/os_beos.h	2009-04-19 20:52:33.000000000 +0000
 +++ vim72.haiku/src/os_beos.h	2009-04-18 09:16:37.000000000 +0000
-@@ -22,4 +22,4 @@
- 
+@@ -20,6 +20,11 @@
+ #undef	BEOS_DR8
+ #define	BEOS_PR_OR_BETTER
+ 
++#define USR_VIMRC_FILE "$BE_USER_SETTINGS/vim/vimrc"
++#define USR_GVIMRC_FILE "$BE_USER_SETTINGS/vim/gvimrc"
++
++#define VIMINFO_FILE "$BE_USER_SETTINGS/vim/viminfo"
++
  /* select emulation */
  
 -#include <net/socket.h>		/* for typedefs and #defines only */

 #include <termios.h>
 #include <kernel/OS.h>
 #include "vim.h"
+#include "os_beos.h"
 
 #if USE_THREAD_FOR_INPUT_WITH_TIMEOUT
 

+typedef struct VimScrollBar VimScrollBar;
+
+#endif
diff -Naur vim72/src/misc1.c vim72.haiku/src/misc1.c
--- vim72/src/misc1.c	2008-07-12 19:20:53.065536000 +0000
+++ vim72.haiku/src/misc1.c	2010-05-04 21:02:55.588251136 +0000
@@ -14,6 +14,10 @@
 #include "vim.h"
 #include "version.h"
 
+#if defined(__HAIKU__)
+#include <storage/FindDirectory.h>
+#endif
+
 static char_u *vim_version_dir __ARGS((char_u *vimdir));
 static char_u *remove_tail __ARGS((char_u *p, char_u *pend, char_u *name));
 static int copy_indent __ARGS((int size, char_u	*src));
@@ -3875,7 +3879,18 @@
 
     vimruntime = (STRCMP(name, "VIMRUNTIME") == 0);
     if (!vimruntime && STRCMP(name, "VIM") != 0)
-	return NULL;
+#if defined(__HAIKU__)
+		// special handling for user settings directory...
+		if(STRCMP(name, "BE_USER_SETTINGS") == 0) {
+			static char userSettingsPath[MAXPATHL] = {0};
+			if(B_OK == find_directory(B_USER_SETTINGS_DIRECTORY, 0, 
+										false, userSettingsPath, MAXPATHL)) 
+			{
+				return userSettingsPath;
+			}
+		} else 
+#endif
+		return NULL;
 
     /*
      * When expanding $VIMRUNTIME fails, try using $VIM/vim<version> or $VIM.
diff -Naur vim72/src/normal.c vim72.haiku/src/normal.c
--- vim72/src/normal.c	2009-04-19 20:53:33.000000000 +0000
+++ vim72.haiku/src/normal.c	2009-04-18 09:16:31.000000000 +0000
