Difference between revisions of "Winelib"

From WineHQ Wiki
Jump to: navigation, search
(Initial import)
 
(Suggested, No Active Worker: fix link)
 
(5 intermediate revisions by the same user not shown)
Line 3: Line 3:
  
 
= Introduction =
 
= Introduction =
Theoretically, any Win32 app should be compilable out of the box under Wine. This, of course, is not the case. We have incompatible headers, and a bunch  of other problems described in [http://www.winehq.org/docs/winelib-guide/index Winelib User's Guide]. A good way to fix these is to try to compile applications for which we have the source under Winelib.
+
Theoretically, any Win32 app should be compilable out of the box under Wine. This, of course, is not the case. We have incompatible headers, and a bunch  of other problems described in [[Winelib User's Guide]]. A good way to fix these is to try to compile applications for which we have the source under Winelib.
  
 
== Why ==
 
== Why ==
Line 10: Line 10:
 
* Document our experience on porting these applications to Winelib
 
* Document our experience on porting these applications to Winelib
 
* Improve Winelib based on the above such that the porting process becomes very simple
 
* Improve Winelib based on the above such that the porting process becomes very simple
* Update the [http://www.winehq.org/docs/winelib-guide/index Winelib User's Guide] to the latest porting process
+
* Update the [[Winelib User's Guide]] to the latest porting process
 
* Fixing header and library problems in the process.
 
* Fixing header and library problems in the process.
  
 
== Where ==
 
== Where ==
There are many such apps around, and a lot of them are hosted at [http://sourceforge.net/ SourceForge]. There are over [http://sourceforge.net/softwaremap/trove_list.php?form_cat=216 10,000 apps] listed as running under Windows OS, and over [http://sourceforge.net/softwaremap/trove_list.php?form_cat=230 7,000] of them are listed as running under the Win32 environment. All of the above have publicly available source code, and most are decent candidates for this project.
+
There are many such apps around, and a lot of them are hosted at [http://sourceforge.net/ SourceForge]. There are over [http://sourceforge.net/directory/os:windows/ 10,000 apps] listed as running under Windows OS. All of the above have publicly available source code, and most are decent candidates for this project.
  
 
Obviously, we cannot start porting all these applications. We have to pick a few important ones, and work with those.
 
Obviously, we cannot start porting all these applications. We have to pick a few important ones, and work with those.
Line 40: Line 40:
 
* CD-DA X-Tractor at [http://xtractor.sourceforge.net/]
 
* CD-DA X-Tractor at [http://xtractor.sourceforge.net/]
 
* CDex at [http://cdexos.sourceforge.net/]
 
* CDex at [http://cdexos.sourceforge.net/]
* DX SDK Examples at [http://msdn.microsoft.com/library/default.asp?url=/downloads/list/directx.asp]
+
* DX SDK Examples at [https://github.com/walbourn/directx-sdk-samples]
 
* Easy Code at [http://www.easycode.cat/English/index.htm]
 
* Easy Code at [http://www.easycode.cat/English/index.htm]
* Gimp at [http://www.gimp.org/~tml/gimp/win32/]
+
* Gimp at [http://www.gimp.org/]
 
* LibreOffice at [https://www.libreoffice.org/]
 
* LibreOffice at [https://www.libreoffice.org/]
 
* Ultimate++ at [http://upp.sourceforge.net/]
 
* Ultimate++ at [http://upp.sourceforge.net/]

Latest revision as of 14:59, 24 February 2016

Winelib

Motto: The journey of a thousand miles starts with a single step.

Introduction

Theoretically, any Win32 app should be compilable out of the box under Wine. This, of course, is not the case. We have incompatible headers, and a bunch of other problems described in Winelib User's Guide. A good way to fix these is to try to compile applications for which we have the source under Winelib.

Why

But what do we hope to achieve? Well, the purpose of this project is four-fold:

  • Document our experience on porting these applications to Winelib
  • Improve Winelib based on the above such that the porting process becomes very simple
  • Update the Winelib User's Guide to the latest porting process
  • Fixing header and library problems in the process.

Where

There are many such apps around, and a lot of them are hosted at SourceForge. There are over 10,000 apps listed as running under Windows OS. All of the above have publicly available source code, and most are decent candidates for this project.

Obviously, we cannot start porting all these applications. We have to pick a few important ones, and work with those.

How

Compiling apps under Winelib should theoretically involve only makefile changes. In practice, you will encounter header problems, and the likes -- for these it is much better (and faster) to submit a patch, rather than document them. So for the remainder of the section, let's assume the Wine headers are good enough for the application in question.

We are now faced with adapting the build process to Wine's needs. As things stand today, we have to make another assumption: you aim at compiling the application using the GNU toolchain (gmake, gcc, ld, etc.). In theory, it should be possible to accomplish this with other tools, but at this point this is a rather unexplored territory. That being said, we now distinguish two large application classes:

Non-GNU tools build process

For these, winemaker does a decent job of generating a build system. I will not cover this type of applications here, for the time being. Please refer to the winemaker documentation for more information.

GNU tools based build process

Fortunately, most OSS applications have a build system based around the MinGW tool chain. Sometimes they have alternative build systems for the Borland and/or Microsoft tools, but more often than not they have to support the MinGW tools out of necessity.

What

If you know of an application that could be listed here, please add it.

Suggestions & Successes

Here is a list of programs that have been suggested for porting or already ported with Winelib

Suggested, No Active Worker

  • CD-DA X-Tractor at [1]
  • CDex at [2]
  • DX SDK Examples at [3]
  • Easy Code at [4]
  • Gimp at [5]
  • LibreOffice at [6]
  • Ultimate++ at [7]
  • VirtualDub at [8]

In Progress

  • ATL
  • Firefox at [9]
  • TeXnicCenter at [10]
  • WinAMP at [11]

Mostly Works

Done

  • Petzold's Examples at [16]
  • PuTTY at [17]
  • Visual MinGW at [18]