

	Configuring, building and running the Willows Twin software.

Overview	

	Building the twin libraries
		step 1.	run ./configure with appropriate flags
		step 2. run make depend (and optionally make clean)
		step 3. run make (to build libraries and xwin emulator)

	Running the twin software
		step 1.   make sure libraries in ld.so search path, or
		          include the path to twin libraries in LD_LIBRARY_PATH
			  (optionally make sure PATH includes the path to
			  the twin windows emulator)
		step 2.   use twinrc template to create ~/.twinrc file
		step 2.1  set windows to where windows directory will be
			  (this is where .ini files will be found/created)	
		step 2.2  set openpath to where windows .exe files live
			  (this is a : separated list of directories)
		step 3.   run xwin32 [app | app.exe | /path/to/app ]
			  xwin32 will prompt for file if not given as input 

Building the twin libraries

Step 1. Configure the software
	
	The software is configurable for different platforms by using the
	configure script.  (This script is built using the GNU autoconf
	utility and the configure.in input file)

	The script understands the following options:

	--enable-optimization	build optimized version of libraries
				DEFAULT is to build debugging version		
	--enable-win16          build win16 version of libraries
				DEFAULT is to build win32 support
	--enable-debugger       enable internal debugger
				DEFAULT is not to build DEBUGGER library
	--enable-bin32          enable win32 binary support libraries
				DEFAULT is NOT to build win32 binary support

	This script will create three files that will be included by the
	various makefiles.

	./Makefile.config		  contains options set by configure
	./makeinclude/Makefile.rules	  definitions of CC, LD, etc.
	./makeinclude/Makeinclude.config  contains options used by utilities

Step 2.	Make makefile dependencies, and build clean environment

	After running/re-running configure, verify dependencies by running
	
		make depend

	After running/re-running configure, remove old object files by running
	
		make clean

	To recreate the original clean source tree, run
	
		make clobber
 
Step 3.	Make the twin libraries and xwin utility

	To build all the build tools, shared libraries and windows 
	emulator, xwin or xwin32, run 

		make
	
	The component libraries that are built are:
		libtwin.so		functions for USER, KERNEL and GDI
		libcommdlg.so		all functions from COMMDLG.DLL
		libcommctrl.so		all functions from COMMCTRL.DLL
		libshell.so		all functions from SHELL.DLL
		libwinsock.so		all functions from WINSOCK.DLL
		libmmsystem.so		all functions from MMSYSTEM.DLL
		libkeyboard.so		all functions from KEYBOARD.DLL
		libsound.so		all functions from SOUND.DLL
		libddeml.so		all functions from DDEML.DLL
		liblzexpand.so		all functions from LZEXPAND.DLL
		libdebug32.so		the debugging library
		libpe32.so		the win32 binary loader

	To build the source samples, you can type

		make world

Configuring the run-time software

Step 1.	Make sure ld.so, the system dynamic linker has access to the
	twin shared libraries.
	

Step 2. Build a ~/.twinrc, run-time configuration file

	See the file ./template/readme.twinrc for more information about
	configuring the software, and file ./template/sample.twinrc for 
	an sample ~/.twinrc configuration file.

	The following is a minimal example of the ~/.twinrc file:

		[boot]
		control=1
		windows=/willows/twin/windows
		openpath=/willows/bin/win:/willows/bin/demo

	This file is a standard windows .ini file, with 1 required section,
	the [boot] section.  This section allows you to set the following:

		control		This variable controls certain runtime
				configuration switches.  The low four bits
				enable various runtime verbose output, the
				other control advanced run-time features
				that are described in the readme.twinrc file.

		windows		This variable points to where the microsoft
				WINDOWS directory is located, this is the
				same as the C:\WINDOWS directory.  This is
				where we will search for .ini files.  This
				directory will contain the windows SYSTEM
				directory containing windows dll's.

		openpath	This colon separated list is equivalent to
				the PATH variable under windows and unix.
				This path is where we should search to find 
				applications that are not given fully 
				qualified pathname.

Step 3. Running the twin windows binary emulaltor

	Assuming that xwin32 is in your PATH environment variable

	xwin32		will bring up the common file dialog asking for
			what windows executable to run.

	Examples of running a specific windows application	
		1) xwin32 sol 
		2) xwin32 sol.exe 
		3) xwin32 /willows/windows/sol.exe 
		4) xwin32 C:\\willows\\windows\\sol.exe

	Option 1,2 assumes that sol.exe is in the openpath list, a .exe
	suffix is assumed if not given.  Option 3 provides an explicit
	unix pathname to the windows executable, while option 4 provides
	a DOS pathname to the executable, (see the documentation on the
	twinrc run-time configuration file to see how to set additional
	drive letters, other than the default C:\ mapping to /.
