Wine Developer's Guide

Uwe Bonnes

Jonathan Buzzard

Zoran Dzelajlija

Klaas van Gend

Francois Gouget

Jon Griffiths

Albert den Haan

Mike Hearn

Ove Kaaven

Tony Lambregts

Marcus Meissner

Gerard Patel

Dimitrie Paun

Michele Petrovski

Eric Pouech

Douglas Ridgway

John Sheets

Lionel Ulmer

Ulrich Weigand

Morten Welinder


Table of Contents
I. Developing Wine
1. Debugging Wine
1.1. Introduction
1.2. WineDbg's modes of invocation
1.3. Using the Wine Debugger
1.4. Useful memory addresses
1.5. Configuration
1.6. WineDbg Expressions and Variables
1.7. WineDbg Command Reference
1.8. Other debuggers
1.9. Limitations
2. Documenting Wine
2.1. An Overview Of Wine Documentation
2.2. Writing Wine API Documentation
2.3. The Wine DocBook System
3. Submitting Patches
3.1. Patch Format
3.2. Some notes about style
3.3. Quality Assurance
4. Writing Conformance tests
4.1. Introduction
4.2. What to test for?
4.3. Running the tests in Wine
4.4. Cross-compiling the tests with MinGW
4.5. Building and running the tests on Windows
4.6. Inside a test
4.7. Writing good error messages
4.8. Handling platform issues
5. Internationalization
5.1. Adding New Languages
II. Wine Architecture
6. Overview
6.1. Wine Overview
6.2. Standard Windows Architectures
6.3. Wine architecture
6.4. Module Overview
6.5. Wine/Windows DLLs
7. The Wine initialization process
7.1. First Steps
7.2. Starting the emulator
8. Debug Logging
8.1. Debugging classes
8.2. Debugging channels
8.3. Are we debugging?
8.4. Helper functions
8.5. Controlling the debugging output
8.6. Compiling Out Debugging Messages
8.7. A Few Notes on Style
9. COM/OLE in Wine
9.1. Writing OLE Components for Wine
10. Wine and OpenGL
10.1. What is needed to have OpenGL support in Wine
10.2. How it all works
10.3. Known problems
11. Outline of DirectDraw Architecture
11.1. DirectDraw inheritance tree
11.2. DirectDrawSurface inheritance tree
11.3. Interface Thunks
11.4. Logical Object Layout
11.5. Creating Objects
12. Wine and Multimedia
12.1. Overview
12.2. Low level layers
12.3. Mid level drivers (MCI)
12.4. High level layers
12.5. Multimedia configuration
12.6. Multimedia architecture
12.7. MS ACM Dlls
13. Multi-threading in Wine
13.1. Threading support in Win32
13.2. SysLevels
13.3. POSIX threading vs kernel threading
13.4. The Win32 thread environment
III. Advanced Topics
14. Low-level Implementation
14.1. Keyboard
14.2. Undocumented APIs
14.3. Accelerators
14.4. Doing A Hardware Trace
15. Porting Wine to new Platforms
15.1. Porting Wine to new Platforms
16. Consoles in Wine
17. Address space management
17.1. Laying out the address space
18. How to do regression testing using CVS
List of Tables
1-1. WineDbg's misc. commands
1-2. WineDbg's flow control commands
1-3. WineDbg's break & watch points
1-4. WineDbg's stack manipulation
1-5. WineDbg's directory & source file manipulation
1-6. WineDbg's list command examples
1-7. WineDbg's displays
1-8. WineDbg's dissassembly
1-9. WineDbg's memory management
1-10. WineDbg's Win32 objects management
1-11. WineDbg's debug channels' management
1-12. WineDbg's debug channels' management
1-13. Debuggers comparison
6-1. Wine executables
6-2. Memory layout (Windows and Wine)
16-1. Function consoles implementation comparison