changes to thread code (directly use boost::thread)

- removes our NewThread() function an replaces remaining calls with
  boost::thread with our TraceThread template
- remove ExitThread() function
- fix THREAD_PRIORITY_ABOVE_NORMAL for non Windows OSes

Conflicts:
	src/net.cpp
Dump addresses every 15 minutes instead of 10 seconds

Conflicts:
	src/net.cpp
Add ThreadGetMyExternalIP to net thread group

Fixes #3372 -- crash at shutdown.
Bitcoin-Qt: prevent stuck/unusable debug window on exit

- when closing the client with an open debug window, that window could
  become stuck/unsuable (it was still shown wherea the main window was
  hidden already)
- fix this by hiding the debug window, when quitting the the client
build: split the non-gui startup routines into a new file

This will allow each to have its own main(), meaning that we can build a common
base client and simply link in the correct startup object to create the
appropriate binary.
Conflicts:
	src/init.cpp
	src/makefile.bsd
	src/makefile.linux-mingw
	src/makefile.mingw
	src/makefile.osx
	src/makefile.unix