title: How do I load .gdbinit on gdb startup?
body: <p>This is a seemly trivial question but I can't find a simple way to accomplish this.</p>
  
  <p>I have my <code>.gdbinit</code> file defined in the same directory as where gdb.exe exist -- that is inside my compiler's bin directory. However, when I run gdb I get this:</p>
  
  <pre><code>GNU gdb (GDB) 7.5.50.20120804-cvs
  Copyright (C) 2012 Free Software Foundation, Inc.
  License GPLv3+: GNU GPL version 3 or later &lt;http://gnu.org/licenses/gpl.html&gt;
  This is free software: you are free to change and redistribute it.
  There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
  and "show warranty" for details.
  This GDB was configured as "i686-w64-mingw32".
  For bug reporting instructions, please see:
  &lt;http://www.gnu.org/software/gdb/bugs/&gt;.
  warning: File "g:\Mingw32-4.6.3\bin\.gdbinit" auto-loading has been declined by
  your `auto-load safe-path' set to "$debugdir:$datadir/auto-load".
  </code></pre>
  
  <p>I looked up the manual about auto-loading <a href="http://sourceware.org/gdb/onlinedocs/gdb/Auto_002dloading-safe-path.html" rel="noreferrer">here</a> but it has nothing about keeping that new safe-path I added saved! Exiting gdb and starting it up again and the safe-paths I added are gone.</p>
  
  <p>My <code>.gdbinit</code> contains settings that I always want loaded upon startup. Loading <code>.gdbinit</code> is probably environment agnostic but what's the simplest way to do this under Windows? There is an addition constraint that <code>.gdbinit</code> cannot reside in my home directory -- it must be in the same path as the <code>gdb.exe</code> executable.</p>