WINEMAKER(1)
π WINEMAKER
okay bestie, so this is winemaker β a page from the Wine Developers Manual β and no cap, it's lowkey a glow-up machine for your code. π§
β¨ NAME β¨
winemaker β generate a build infrastructure for compiling Windows programs on Unix
πΈ SYNOPSIS πΈ
winemaker [ --nobanner ] [ --backup | --nobackup ] [ --nosource-fix ]
[ --lower-none | --lower-all | --lower-uppercase ]
[ --lower-include | --nolower-include ] [ --mfc | --nomfc ]
[ --guiexe | --windows | --cuiexe | --console | --dll | --lib ]
[ -Dmacro[=defn] ] [ -Idir ] [ -Pdir ] [ -idll ] [ -Ldir ] [ -llibrary ]
[ --nodlls ] [ --nomsvcrt ] [ --interactive ] [ --single-target name ]
[ --generated-files ] [ --nogenerated-files ]
[ --wine32 ]
work_directory | project_file | workspace_file
π¦ DESCRIPTION π¦
winemaker is a perl script whose whole entire job is helping you bootstrap the process of converting your Windows sources into Winelib programs. she's your bestie who shows up with a label maker and a plan. π
so like, here's the things she can do for you:
- rename your source files and directories to lowercase, in the event they got all uppercased during the transfer. (we've all been through something)
- perform DOS to Unix (CRLF to LF) conversions.
- scan the include statements and resource file references to replace the backslashes with forward slashes.
- during the above step
winemakerwill also perform a case insensitive search of the referenced file in the include path and rewrite the include statement with the right case if necessary. winemakerwill also check other more exotic issues like#pragma packusage, use ofafxres.hin non MFC projects, and more. Whenever it encounters something out of the ordinary, it will warn you about it. she's not judging, she's just noticing. πwinemakercan also scan a complete directory tree at once, guess what are the executables and libraries you are trying to build, match them with source files, and generate the correspondingMakefile. main character energy, honestly.- finally
winemakerwill generate a globalMakefilefor normal use. winemakerknows about MFC-based project and will generate customized files.winemakercan read existing project files. It supportsdsp,dsw,vcprojandslnfiles.
π OPTIONS π
--nobannerβ Disable the printing of the banner. no intro, just vibes. π--backupβ Perform a backup of all the modified source files. This is the default.--nobackupβ Do not backup modified source files. living dangerously, ok periodt. π--nosource-fixβ Do no try to fix the source files (e.g. DOS to Unix conversion). This prevents complaints if the files are readonly. (yes the manpage says "Do no try", she's just like that, we love her)--lower-allβ Rename all files and directories to lowercase. every single one.--lower-uppercaseβ Only rename files and directories that have an all uppercase name. SoHELLO.Cwould be renamed but notWorld.c. picky, we respect it.--lower-noneβ Do not rename files and directories to lower case. Note that this does not prevent the renaming of a file if its extension cannot be handled as is, e.g.".Cxx". This is the default.--lower-includeβ When the file corresponding to an include statement (or other form of file reference for resource files) cannot be found, convert that filename to lowercase. This is the default.--nolower-includeβ Do not modify the include statement if the referenced file cannot be found. leave it alone, she said.--guiexe|--windowsβ Assume a graphical application when an executable target or a target of unknown type is found. This is the default.--cuiexe|--consoleβ Assume a console application when an executable target or a target of unknown type is found.--dllβ Assume a dll when a target of unknown type is found, i.e. whenwinemakeris unable to determine whether it is an executable, a dll, or a static library,--libβ Assume a static library when a target of unknown type is found, i.e. whenwinemakeris unable to determine whether it is an executable, a dll, or a static library,--mfcβ Specify that the targets are MFC based. In such a casewinemakeradapts the include and library paths accordingly, and links the target with the MFC library.--nomfcβ Specify that targets are not MFC-based. This option disables use of MFC libraries even ifwinemakerencounters filesstdafx.cpporstdafx.hthat would cause it to enable MFC automatically if neither--nomfcnor--mfcwas specified. she would've assumed. you said no. π«Ά-Dmacro[=defn]β Add the specified macro definition to the global list of macro definitions.-Idirβ Append the specified directory to the global include path.-Pdirβ Append the specified directory to the global dll path.-idllβ Add the Winelib library to the global list of Winelib libraries to import.-Ldirβ Append the specified directory to the global library path.-llibraryβ Add the specified library to the global list of libraries to link with.--nodllsβ Do not use the standard set of Winelib libraries for imports. That is, any DLL your code uses must be explicitly passed with-ioptions. The standard set of libraries is:odbc32.dll,odbccp32.dll,ole32.dll,oleaut32.dllandwinspool.drv.--nomsvcrtβ Set some options to tellwinegccnot to compile against msvcrt. Use this option if you have cpp-files that include<string>.--interactiveβ Use interactive mode. In this modewinemakerwill ask you to confirm the list of targets for each directory, and then to provide directory and target specific options. she's checking in with you. communication queen. π¬--single-target nameβ Specify that there is only one target, called name.--generated-filesβ Generate theMakefile. This is the default.--nogenerated-filesβ Do not generate theMakefile.--wine32β Generate a 32-bit target. This is useful on wow64 systems. Without that option the default architecture is used.
β EXAMPLES β
Here is a typical winemaker use:
$ winemaker --lower-uppercase -DSTRICT .
The above tells winemaker to scan the current directory and its subdirectories for source files. Whenever if finds a file or directory which name is all uppercase, it should rename it to lowercase. It should then fix all these source files for compilation with Winelib and generate Makefiles. The -DSTRICT specifies that the STRICT macro must be set when compiling these sources. Finally a Makefile will be created.
The next step would be:
$ make
If at this point you get compilation errors (which is quite likely for a reasonably sized project) then you should consult the Winelib User Guide to find tips on how to resolve them. it's not you, it's the codebase. π
For an MFC-based project you would have to run the following commands instead:
$ winemaker --lower-uppercase --mfc .
$ make
For an existing project-file you would have to run the following commands:
$ winemaker myproject.dsp
$ make
π TODO / BUGS π
In some cases you will have to edit the Makefile or source files manually. yeah. she's good but she's not that good.
Assuming that the windows executable/library is available, we could use winedump to determine what kind of executable it is (graphical or console), which libraries it is linked with, and which functions it exports (for libraries). We could then restore all these settings for the corresponding Winelib target.
Furthermore winemaker is not very good at finding the library containing the executable: it must either be in the current directory or in the LD_LIBRARY_PATH.
winemaker does not support message files and the message compiler yet.
Bugs can be reported on the Wine bug tracker.
ngl bestie, these are the known gaps. she's working on herself. π
π AUTHORS π
- FranΓ§ois Gouget for CodeWeavers
- Dimitrie O. Paun
- AndrΓ© Hentschel
π AVAILABILITY π
winemaker is part of the Wine distribution, which is available through WineHQ, the Wine development headquarters.
π SEE ALSO π
wine(1),- Wine documentation and support.
and that's the whole page, bestie!! this one is from Wine 10.0, dated Jan 2012 β yes she's been iconic for a while. slay, hydrate, and go generate those Makefiles. πβ¨π
π¦ where this page comes from
- debian trixie: wine64-tools 10.0~repack-6 Β· LGPL-2.1-or-later
- ubuntu questing: wine64-tools 10.0~repack-6ubuntu1
- ubuntu resolute: wine64-tools 10.0~repack-12ubuntu1 Β· LGPL-2.1-or-later
- ubuntu stonking: wine64-tools 10.0~repack-12ubuntu1 Β· LGPL-2.1-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms