2 .TH WINEMAKER 1 "February 2009" "@PACKAGE_STRING@" "Wine Developers Manual"
4 winemaker \- generate a build infrastructure for compiling Windows programs on Unix
8 .IR "--nobanner " "] [ " "--backup " "| " "--nobackup " "] [ "--nosource-fix "
12 .IR "--lower-none " "| " "--lower-all " "| " "--lower-uppercase "
16 .IR "--lower-include " "| " "--nolower-include " ] [ " "--mfc " "| " "--nomfc "
20 .IR "--guiexe " "| " "--windows " "| " "--cuiexe " "| " "--console " "| " "--dll " "| " "--nodlls "
24 .IR "-Dmacro[=defn] " "] [ " "-Idir " "] [ " "-Pdir " "] [ " "-idll" "] [ " "-Ldir " "] [ " "-llibrary "
28 .IR "--interactive " "] [ " "--single-target name "
32 .IR "--generated-files " "] [ " "--nogenerated-files " "]
34 .IR "work_directory" "| " "project_file" "| " "workspace_file"
39 is a perl script designed to help you bootstrap the
40 process of converting your Windows sources to Winelib programs.
42 In order to do this winemaker can perform the following operations:
44 - rename your source files and directories to lowercase in the event they
45 got all uppercased during the transfer.
47 - perform Dos to Unix (CRLF to LF) conversions.
49 - scan the include statements and resource file references to replace the
50 backslashes with forward slashes.
52 - during the above step winemaker will also perform a case insensitive search
53 of the referenced file in the include path and rewrite the include statement
54 with the right case if necessary.
56 - winemaker will also check other more exotic issues like '#pragma pack'
57 usage, use of "afxres.h" in non MFC projects, and more. Whenever it
58 encounters something out of the ordinary, winemaker will warn you about it.
60 - winemaker can also scan a complete directory tree at once, guess what are
61 the executables and libraries you are trying to build, match them with
62 source files, and generate the corresponding Makefile.in files.
64 - finally winemaker will generate a global Makefile for normal use.
66 - winemaker knows about MFC-based project and will generate customized files.
68 - winemaker can read existing Projectfiles. It supports dsp, dsw, vcproj and sln files.
73 Disables the printing of the banner.
76 Directs winemaker to perform a backup of all the source files in which it
77 makes changes. This is the default.
80 Tells winemaker not to backup modified source files.
83 Directs winemaker not to try fixing the source files (e.g. Dos to Unix
84 conversion). This prevents complaints if the files are readonly.
87 Tells winemaker to rename all files and directories to lowercase.
90 Tells winemaker to only rename files and directories that have an all
92 So "HELLO.C" would be renamed but not "World.c".
95 Tells winemaker not to rename files and directories to lower case. Note
96 that this does not prevent the renaming of a file if its extension cannot
97 be handled as is, e.g. ".Cxx". This is the default.
100 Tells winemaker that if it does not find the file corresponding to an
101 include statement (or other form of file reference for resource files),
102 then it should convert that filename to lowercase. This is the default.
104 .I "--nolower-include "
105 Tells winemaker not to modify the include statement if it cannot find the
108 .IR "--guiexe " "| " "--windows"
109 Specifies that whenever winemaker finds an executable target, or a target of
110 unknown type, it should assume that it is a graphical application.
113 .IR "--cuiexe " "| " "--console"
114 Specifies that whenever winemaker finds an executable target, or a target of
115 unknown type, it should assume that it is a console application.
118 This option tells winemaker that whenever it finds a target of unknown type,
119 i.e. for which it does not know whether it is an executable or a library,
120 it should assume it is a library.
123 This option tells winemaker not to use the standard set of winelib libraries
124 for imports. That is, any DLL your code uses must be explicitly passed to
125 winemaker with -i options.
126 The standard set of libraries is: advapi32.dll, comdlg32.dll, gdi32.dll,
127 kernel32.dll, odbc32.dll, ole32.dll, oleaut32.dll, shell32.dll, user32.dll,
131 Specifies that the targets are MFC based. In such a case winemaker the include
132 and library paths accordingly, and links the target with the MFC library.
135 Specifies that targets are not MFC-based. This option disables use of MFC libraries
136 even if winemaker encounters files "stdafx.cpp" or "stdafx.h" that would cause it
137 to enable MFC automatically if neither --nomfc nor --mfc was specified.
140 Adds the specified macro definition to the global list of macro definitions.
143 Appends the specified directory to the global include path.
146 Appends the specified directory to the global dll path.
149 Adds the Winelib library to the global list of Winelib libraries to import.
152 Appends the specified directory to the global library path.
155 Adds the specified library to the global list of libraries to link with.
158 Puts winemaker in interactive mode. In this mode winemaker will ask you to
159 confirm each directory's list of targets, and then to provide directory and
160 target specific options.
162 .I --single-target name
163 Specifies that there is only one target, and that it is called "name".
166 Tells winemaker to generate the build the Makefile. This is the default.
168 .I --nogenerated-files
169 Tells winemaker not to generate the Makefile.
173 Here is a typical winemaker use:
175 $ winemaker --lower-uppercase -DSTRICT .
177 The above tells winemaker to scan the current directory and its
178 subdirectories for source files. Whenever if finds a file or directory which
179 name is all uppercase, it should rename it to lowercase. It should then fix
180 all these source files for compilation with Winelib and generate Makefiles.
181 The '-DSTRICT' specifies that the STRICT macro must be set when compiling
182 these sources. Finally winemaker will create a Makefile.
184 The next step would be:
188 If at this point you get compilation errors (which is quite likely for a
189 reasonably sized project) then you should consult the Winelib User Guide to
190 find tips on how to resolve them.
192 For an MFC-based project you would have to run the following commands instead:
194 $ winemaker --lower-uppercase --mfc .
198 For an existing project-file you would have to run the following commands:
200 $ winemaker --lower-all myproject.dsp
207 In some cases you will have to edit the Makefile or sourcefiles by yourself.
209 Assuming that the windows executable/library is available, we could
210 use a pedump-like tool to determine what kind of executable it is (graphical
211 or console), which libraries it is linked with, and which functions it
212 exports (for libraries). We could then restore all these settings for the
213 corresponding Winelib target. The problem is that we should have such a tool
214 available under the Wine license first.
216 Furthermore it is not very good at finding the library containing the
217 executable: it must either be in the current directory or in the
218 .IR LD_LIBRARY_PATH .
220 Winemaker does not support message files and the message compiler yet.
225 The Winelib User Guide:
227 http://www.winehq.org/docs/winelib-guide/index
233 Francois Gouget <fgouget@codeweavers.com> for CodeWeavers