Wine/hu
Wine (Wine Is Not an Emulator) egy Microsoft Windows szoftverek futtatását Linuxon és más POSIX-kompatibilis operációs rendszereken lehetővé tévő alkalmazás-kompatibilitási réteg. Ez a cikk a Wine általános célú környezetének telepítésével, beállításával és karbantartásával foglalkozik a Gentoo operációs rendszeren.
Wine is not a sandboxed environment, and doesn't provide system resources and file isolation. Executing malware in Wine could result in data loss, information leakage, and/or system malfunction. Reference to FAQ: Is Wine malware-compatible from upstream for more information.
Wine változatai
- app-emulation/wine-vanilla: Alapvető Wine külső javítócsomagok nélkül.
- app-emulation/wine-staging: Wine a Wine Staging javítócsomaggal.
- app-emulation/wine-proton: Wine a Valve Software javítócsomaggal, amelyet a Steam Linux verziója is használ.
Változat kiválasztása
További javítócsomagok olyan hibákat is bevezethetnek, amelyek az alapvető Wine-ban nem léteznek, ugyanakkor kijavíthatnak más, meglévő problémákat is.
The app-emulation/wine-proton variant is only the Wine fork which is used to build Proton, and is not a stand-alone version of Proton which comes with Steam. If there are any issues with running applications with it, it would be best to test if the issues can be seen with a build of the upstream Wine as well, and then file a report to the upstream Wine project if none exists.
Telepítés
USE jelölőzászlók
USE flags for virtual/wine Virtual to depend on any app-emulation/wine-* variant
USE flags for app-emulation/wine-vanilla Free implementation of Windows(tm) on Unix, without external patchsets
+X
|
Add support for X11 |
+alsa
|
Add support for media-libs/alsa-lib (Advanced Linux Sound Architecture) |
+dbus
|
Enable dbus support for anything that needs it (gpsd, gnomemeeting, etc) |
+fontconfig
|
Support for configuring and customizing font access via media-libs/fontconfig |
+gecko
|
Enable mshtml support using app-emulation/wine-gecko |
+gstreamer
|
Add support for media-libs/gstreamer (Streaming media) |
+mingw
|
Build PE files using dev-util/mingw64-toolchain (more tested) rather than llvm-core/clang (newer) |
+mono
|
Enable .NET support using app-emulation/wine-mono |
+opengl
|
Add support for OpenGL (3D graphics) |
+sdl
|
Enable gamepad support using media-libs/libsdl2 |
+ssl
|
Add support for SSL/TLS connections (Secure Socket Layer / Transport Layer Security) |
+strip
|
Allow symbol stripping to be performed by the ebuild for special files |
+truetype
|
Add support for FreeType and/or FreeType2 fonts |
+unwind
|
Add support for call stack unwinding and function name resolution |
+vulkan
|
Add support for 3D graphics and computing via the Vulkan cross-platform API |
+wow64
|
Enable the "new" wow64 mode that allows running 32bit applications without 32bit ELF multilib by mapping to 64bit calls. Generally works well with wine-11.0 or newer, but may or may not have a small perforamce impact or other issues. If USE=mingw is set, still need the default abi_x86_32 set on dev-util/mingw64-toolchain but that can be done even with /no-multilib/ profiles. This can also be enabled on arm64 to allow running x86 applications via binary translation. |
+xcomposite
|
Enable support for the Xorg composite extension |
arm64ec
|
Enable support for running x86_64 applications on arm64 via binary translation |
bluetooth
|
Enable Bluetooth Support |
crossdev-mingw
|
Use sys-devel/crossdev for the toolchain rather than dev-util/mingw64-toolchain (requires manual setting up and is mostly unsupported, try disabling if have issues) |
cups
|
Add support for CUPS (Common Unix Printing System) |
custom-cflags
|
Build with user-specified CFLAGS (unsupported) |
dos
|
Pull in games-emulation/dosbox to run DOS applications |
ffmpeg
|
Enable ffmpeg/libav-based audio/video codec support |
gphoto2
|
Add digital camera support |
kerberos
|
Add kerberos support |
llvm-libunwind
|
Use llvm-runtimes/libunwind instead of sys-libs/libunwind |
netapi
|
Enable support for configuring remote shares using net-fs/samba |
nls
|
Add Native Language Support (using gettext - GNU locale utilities) |
odbc
|
Add ODBC Support (Open DataBase Connectivity) |
opencl
|
Enable OpenCL support (computation on GPU) |
pcap
|
Support packet capture software (e.g. wireshark) |
perl
|
Install helpers that require perl (winedump/winemaker) |
pulseaudio
|
Add sound server support via media-libs/libpulse (may be PulseAudio or PipeWire) |
samba
|
Pull in net-fs/samba with winbind for NTLM auth support |
scanner
|
Add support for scanner hardware (e.g. build the sane frontend in kdegraphics) |
selinux
|
!!internal use only!! Security Enhanced Linux support, this must be set by the selinux profile or breakage will occur |
smartcard
|
Enable smartcard support |
udev
|
Enable virtual/udev integration (device discovery, power and storage device support, etc) |
usb
|
Add USB support to applications that have optional USB support (e.g. cups) |
v4l
|
Enable support for video4linux (using linux-headers or userspace libv4l libraries) |
vaapi
|
Enable Video Acceleration API for hardware decoding |
wayland
|
Enable dev-libs/wayland backend |
xinerama
|
Add support for querying multi-monitor screen geometry through the Xinerama API |
USE flags for app-emulation/wine-staging Free implementation of Windows(tm) on Unix, with Wine-Staging patchset
+X
|
Add support for X11 |
+alsa
|
Add support for media-libs/alsa-lib (Advanced Linux Sound Architecture) |
+dbus
|
Enable dbus support for anything that needs it (gpsd, gnomemeeting, etc) |
+fontconfig
|
Support for configuring and customizing font access via media-libs/fontconfig |
+gecko
|
Enable mshtml support using app-emulation/wine-gecko |
+gstreamer
|
Add support for media-libs/gstreamer (Streaming media) |
+mingw
|
Build PE files using dev-util/mingw64-toolchain (more tested) rather than llvm-core/clang (newer) |
+mono
|
Enable .NET support using app-emulation/wine-mono |
+opengl
|
Add support for OpenGL (3D graphics) |
+sdl
|
Enable gamepad support using media-libs/libsdl2 |
+ssl
|
Add support for SSL/TLS connections (Secure Socket Layer / Transport Layer Security) |
+strip
|
Allow symbol stripping to be performed by the ebuild for special files |
+truetype
|
Add support for FreeType and/or FreeType2 fonts |
+unwind
|
Add support for call stack unwinding and function name resolution |
+vulkan
|
Add support for 3D graphics and computing via the Vulkan cross-platform API |
+wow64
|
Enable the "new" wow64 mode that allows running 32bit applications without 32bit ELF multilib by mapping to 64bit calls. Generally works well with wine-11.0 or newer, but may or may not have a small perforamce impact or other issues. If USE=mingw is set, still need the default abi_x86_32 set on dev-util/mingw64-toolchain but that can be done even with /no-multilib/ profiles. This can also be enabled on arm64 to allow running x86 applications via binary translation. |
arm64ec
|
Enable support for running x86_64 applications on arm64 via binary translation |
bluetooth
|
Enable Bluetooth Support |
crossdev-mingw
|
Use sys-devel/crossdev for the toolchain rather than dev-util/mingw64-toolchain (requires manual setting up and is mostly unsupported, try disabling if have issues) |
cups
|
Add support for CUPS (Common Unix Printing System) |
custom-cflags
|
Build with user-specified CFLAGS (unsupported) |
dos
|
Pull in games-emulation/dosbox to run DOS applications |
ffmpeg
|
Enable ffmpeg/libav-based audio/video codec support |
gphoto2
|
Add digital camera support |
kerberos
|
Add kerberos support |
llvm-libunwind
|
Use llvm-runtimes/libunwind instead of sys-libs/libunwind |
netapi
|
Enable support for configuring remote shares using net-fs/samba |
nls
|
Add Native Language Support (using gettext - GNU locale utilities) |
odbc
|
Add ODBC Support (Open DataBase Connectivity) |
opencl
|
Enable OpenCL support (computation on GPU) |
pcap
|
Support packet capture software (e.g. wireshark) |
perl
|
Install helpers that require perl (winedump/winemaker) |
pulseaudio
|
Add sound server support via media-libs/libpulse (may be PulseAudio or PipeWire) |
samba
|
Pull in net-fs/samba with winbind for NTLM auth support |
scanner
|
Add support for scanner hardware (e.g. build the sane frontend in kdegraphics) |
selinux
|
!!internal use only!! Security Enhanced Linux support, this must be set by the selinux profile or breakage will occur |
smartcard
|
Enable smartcard support |
udev
|
Enable virtual/udev integration (device discovery, power and storage device support, etc) |
usb
|
Add USB support to applications that have optional USB support (e.g. cups) |
v4l
|
Enable support for video4linux (using linux-headers or userspace libv4l libraries) |
vaapi
|
Enable Video Acceleration API for hardware decoding |
wayland
|
Enable dev-libs/wayland backend |
xinerama
|
Add support for querying multi-monitor screen geometry through the Xinerama API |
USE flags for app-emulation/wine-proton Valve Software's fork of Wine
+X
|
Add support for X11 |
+alsa
|
Add support for media-libs/alsa-lib (Advanced Linux Sound Architecture) |
+dbus
|
Enable dbus support for anything that needs it (gpsd, gnomemeeting, etc) |
+fontconfig
|
Support for configuring and customizing font access via media-libs/fontconfig |
+gecko
|
Enable mshtml support using app-emulation/wine-gecko |
+gstreamer
|
Add support for media-libs/gstreamer (Streaming media) |
+mingw
|
Build PE files using dev-util/mingw64-toolchain (more tested) rather than llvm-core/clang (newer) |
+mono
|
Enable .NET support using app-emulation/wine-mono |
+sdl
|
Enable gamepad support using media-libs/libsdl2 |
+ssl
|
Add support for SSL/TLS connections (Secure Socket Layer / Transport Layer Security) |
+strip
|
Allow symbol stripping to be performed by the ebuild for special files |
+unwind
|
Add support for call stack unwinding and function name resolution |
+wow64
|
Enable the "new" wow64 mode that allows running 32bit applications without 32bit ELF multilib by mapping to 64bit calls. Generally works well with wine-11.0 or newer, but may or may not have a small perforamce impact or other issues. If USE=mingw is set, still need the default abi_x86_32 set on dev-util/mingw64-toolchain but that can be done even with /no-multilib/ profiles. This can also be enabled on arm64 to allow running x86 applications via binary translation. |
+xcomposite
|
Enable support for the Xorg composite extension |
arm64ec
|
Enable support for running x86_64 applications on arm64 via binary translation |
crossdev-mingw
|
Use sys-devel/crossdev for the toolchain rather than dev-util/mingw64-toolchain (requires manual setting up and is mostly unsupported, try disabling if have issues) |
custom-cflags
|
Build with user-specified CFLAGS (unsupported) |
ffmpeg
|
Enable ffmpeg/libav-based audio/video codec support |
llvm-libunwind
|
Use llvm-runtimes/libunwind instead of sys-libs/libunwind |
nls
|
Add Native Language Support (using gettext - GNU locale utilities) |
perl
|
Install helpers that require perl (winedump/winemaker) |
pulseaudio
|
Add sound server support via media-libs/libpulse (may be PulseAudio or PipeWire) |
selinux
|
!!internal use only!! Security Enhanced Linux support, this must be set by the selinux profile or breakage will occur |
udev
|
Enable virtual/udev integration (device discovery, power and storage device support, etc) |
usb
|
Add USB support to applications that have optional USB support (e.g. cups) |
v4l
|
Enable support for video4linux (using linux-headers or userspace libv4l libraries) |
wayland
|
Enable dev-libs/wayland backend |
xinerama
|
Add support for querying multi-monitor screen geometry through the Xinerama API |
32-bit kontra 64-bit
When compiling Wine with the
wow64 USE-flag on a no-multilib system, the kernel config option CONFIG_IA32_EMULATION is required for the 32bit support to function.Gyakran előfordul, hogy a Windows alkalmazások 32 bites támogatást igényelnek. Ez igaz lehet még 64 bites alkalmazások esetén is, mivel ezek továbbra is használhatnak 32 bites telepítőt.
Ez azt jelenti, hogy a Wine számos függősége szintén 32 bites támogatást igényel. Ha ez nincs globálisan engedélyezve az összes csomaghoz, akkor az autounmask opció használata az emerge segédprogrammal hasznos lehet a lista felépítésében.
Below is an example /etc/portage/package.use/wine file which includes some packages that will need their abi_x86_32 USE flag enabled for 32-bit support:
/etc/portage/package.use/winedev-lang/orc abi_x86_32
media-libs/a52dec abi_x86_32
media-libs/faad2 abi_x86_32
media-libs/graphene abi_x86_32
media-libs/gst-plugins-bad abi_x86_32
media-libs/gst-plugins-base abi_x86_32
media-libs/gst-plugins-good abi_x86_32
media-libs/gst-plugins-ugly abi_x86_32
media-libs/gstreamer abi_x86_32
media-libs/libdca abi_x86_32
media-libs/libmpeg2 abi_x86_32
media-libs/vulkan-loader abi_x86_32
media-libs/x264 abi_x86_32
media-plugins/gst-plugins-a52dec abi_x86_32
media-plugins/gst-plugins-dts abi_x86_32
media-plugins/gst-plugins-dvdread abi_x86_32
media-plugins/gst-plugins-faad abi_x86_32
media-plugins/gst-plugins-flac abi_x86_32
media-plugins/gst-plugins-meta abi_x86_32
media-plugins/gst-plugins-mpeg2dec abi_x86_32
media-plugins/gst-plugins-mpg123 abi_x86_32
media-plugins/gst-plugins-pulse abi_x86_32
media-plugins/gst-plugins-x264 abi_x86_32
sys-libs/libunwind abi_x86_32
x11-libs/libXv abi_x86_32
A Wine lefordítása engedélyezett wow64 USE jelölőzászlóval lehetővé teszi a 32 bites alkalmazások futtatását anélkül, hogy a Wine szoftvert és annak függőségeit 32 bites támogatással kellene létrehozni. Ez azonban (ezen angol nyelvű cikk írásának időpontjában) többé-kevésbé kísérleti jellegű. Számos alkalmazásnál nagyon jól működik, de más alkalmazásoknál használhatatlan.
Until Wine 11.0, upstream considered this feature as experimental, and many applications might still be unusable after this point in Wine, but a lot of applications might also perform perfectly fine.
Some problems may be worked around via use of Vulkan, meaning hardware not capable of supporting Vulkan may suffer from more issues.
It is possible to test this by setting the WINEARCH variable to wow64 when creating a new Wine prefix, while still building with the USE-flag disabled.
Vegye figyelembe, hogy a Wine bizonyos függőségeihez a kernelbeállításban a CONFIG_COMPAT_32BIT_TIME beállítása szükséges a működéshez. Ennek elmulasztása olyan hibaüzeneteket generálhat, mint például: "The futex facility returned an unexpected error code." a kódfordítás során vagy a binárisra lefordított kód futásának idején. Az érintett szoftvercsomagok például a dev-libs/icu[1] és a sys-devel/llvm.
Kódfordítás közbeni környezeti változók
A live (9999) ebuild-ek támogatják a tároló-ág, commit, commit dátum és tároló beállítását a következő környezeti változók segítségével:
- EGIT_OVERRIDE_BRANCH
- EGIT_OVERRIDE_COMMIT
- EGIT_OVERRIDE_COMMIT_DATE
- EGIT_OVERRIDE_REPO
Példaként kiválaszthatja a WineHQ "wine-2.0-rc5" címkét a 2.0 RC 5 verzió emerge-vel történő előállításához:
root #EGIT_OVERRIDE_COMMIT_WINE_WINE="wine-2.0-rc5" emerge -a '=app-emulation/wine-vanilla-9999'Ezenkívül a Wine Staging is rögzíthető ugyanahhoz a kiadáshoz a megfelelő "v2.0-rc5" címke megtalálásával, és kiegészíti az előző parancs a következőképpen:
root #EGIT_OVERRIDE_COMMIT_WINE_WINE="wine-2.0-rc5" EGIT_OVERRIDE_COMMIT_WINE_WINE_STAGING="v2.0-rc5" emerge -a '=app-emulation/wine-staging-9999'A Wine szoftverre futásidőben ható egyéb változóiról lentebb esik szó.
Emerge
Engedélyezze az Ön által választott USE jelölőzászlókat először a virtuális szoftvercsomagon, majd a kiválasztott variánson (amelyet automatikusan a virtuális szoftvercsomag vagy manuálisan Ön választ ki), és emerge parancs segítségével hozza létre a szoftvercsomagot:
root #emerge --ask virtual/winevagy
root #emerge --ask app-emulation/wine-${VARIANT}Csak az upstream által "stabilnak" minősített verziók kerülnek stabilizálásra a Gentoo-ban, és kizárólag a app-emulation/wine-vanilla variánsként, mivel a külső javítócsomagokat nem tekintik stabilnak. Egyes felhasználók dönthetnek úgy, hogy hozzáadják a Wine variánsokat a package.accept_keywords fájlhoz, hogy lehetővé tegyék a Wine fejlesztői verzióinak telepítését.
Beállítás
Kernel
Device Drivers --->
Misc devices --->
<M> NT synchronization primitive emulation Search for <code>CONFIG_NTSYNC</code> to find this item.
Futásidejű környezeti változók
Az a shell környezeti változók, amelyből a wine elindul, elérhetővé válnak a Windows/DOS folyamatok számára. Néhány nagyon hasznos, kifejezetten a Wine szoftverre vonatkozó változó többek között a WINEPREFIX, a WINEARCH és a WINEDEBUG.
Tekintse meg a man wine és a man wineserver súgókat a Wine környezeti változóival kapcsolatos részletesebb információkért.
WINEPREFIX
A prefix könyvtár (alapértelmezetten $HOME/.wine) létrejön, amikor a Wine bármilyen módon elindul (például a
winecfg futtatásával). Ez azt is jelenti, hogy ha root felhasználóként hajtják végre (részletek a WineHQ GYIK - Should I Run Wine as Root leírásban), akkor a Wine prefix (alapértelmezés szerint) a /root/.wine helyen lesz létrehozva.Futtassa a következő parancsot az egyedi helyen (~/.wine helyett) történő Wine prefix létrehozásához anélkül, hogy az alapértelmezettet befolyásolná:
user $WINEPREFIX="$HOME/.wine-someprefix" winebootA fenti megoldás létrehozna egy Wine prefix -et a következő helyen: /home/<user>/.wine-someprefix.
Miután egy prefix létrejött, az 'architektúra' (arch) nem változtatható meg. Ennek megfelelően, ha a felhasználó felül szeretné írni az alapértelmezést, akkor a WINEARCH értékét az prefix létrehozásakor kell meghatározni. A WINEARCH az prefix létrehozásán túl értelmetlen.
WINEARCH
32 bites telepítés létrehozása az alapértelmezett 64 bites helyett:
user $WINEARCH="win32" WINEPREFIX="$HOME/.wine-someprefix" winebootA 32-bit only prefix can not be created with the
wow64 USE-flag enabled.To create a prefix supporting both, 32-bit and 64-bit applications using the new style of WOW64, which can be done with USE="-wow64" builds as well:
user $WINEARCH="wow64" WINEPREFIX="$HOME/.wine-someprefix" winebootA használt Wine végrehajtható fájl bármely olyan fájl lehet, amely a Wineszoftvert futtatja, például a winecfg, amely gyakran hasznos egy tiszta, új prefix létrehozásakor.
A WINEARCH értékének használatához a Wine szoftvert a megfelelő abi_x86 jelölőzászlókkal kell felépíteni.
WINEDEBUG
Alapvető fontosságú annak kiderítéséhez, hogy egy alkalmazás miért működik hibásan, amikor az alapvető terminál kimenet vagy az üzenetablakok nem elegendőek. Példaként tekintse meg a https://wiki.winehq.org/Debug_Channels leírást.
Beállítást segítő eszközök
Az alábbi eszközök grafikus és parancssori felületeket tartalmaznak a Wine prefix-ek kezeléséhez:
- app-emulation/q4wine – Qt5 grafikus felhasználói felülettel rendelkező beállítást segítő eszköz a Wine számára.
- app-emulation/winetricks – Egyszerű módszer a Wine problémáinak megoldásához, például amikor a szükséges DLL fájlokat kell telepíteni.
Grafikus illesztőprogramok
Grafikus rendszerleíró adatbázis értéke vesszővel elválasztott karakterlánc és REG_SZ típusú.
| Illesztőprogram | Leírás |
|---|---|
| x11 | X11 illesztőprogramot használ. |
| wayland | Wayland illesztőprogramot használ. |
| mac | Natív quartz meghajtót használ. (Alapértelmezett macOS). |
| null | Null eszközmeghajtót használ. (Egy virtuális képernyő létrejön, de nem jelenik meg. Elérhető a Wine 5.2 verziója óta). |
| Driver | Description |
|---|---|
| x11 | Use the X11 driver |
| wayland | Use the Wayland driver |
| mac | Use the native quartz driver (default on macOS) |
| null | Use the null driver (a virtual screen will be created, but not displayed; available since Wine 5.2) |
Alapértelmezett (Linux rendszeren)
user $wine cmd /c "reg add HKEY_CURRENT_USER\\Software\\Wine\\Drivers /v Graphics /t REG_SZ /d x11 /f"Kísérleti wayland eszközmeghajtó engedélyezéséhez:
user $wine cmd /c "reg add HKEY_CURRENT_USER\\Software\\Wine\\Drivers /v Graphics /t REG_SZ /d wayland /f"Easy Anti Cheat Support
Mivel a DT_HASH alapértelmezés szerint nincs engedélyezve a glibc 2.36 óta, ezért a következő lépéseket kell alkalmazni az EAC (Easy Anti-Cheat) játékok működéséhez:
/etc/portage/package.use/glibcsys-libs/glibc hash-sysv-compat
root #emerge --ask --oneshot sys-libs/glibcUpstream GYIK
Néhány upstream GYIK bejegyzés, amit a felhasználók hasznosnak találhatnak:
- How to uninstall individual applications
- How to remove a Wine prefix
- How to prevent Wine from creating menu items
Hibaelhárítás
Ha egy felhasználó problémát tapasztal egy alkalmazással, akkor érdemes kipróbálni a legújabb fejlesztői verziót, hogy lássa, a nem kívánt viselkedés továbbra is fennáll-e. Ha a Wine szoftver olyan opciókkal lett létrehozva, mint a -fomit-frame-pointer vagy a --hash-style=both, akkor a Wine fejlesztők valószínűleg nem tudnak segíteni a problémában, és az ilyen build-ek kimenetét tartalmazó jelentéseket nem szabad beküldeni a Wine Bugzilla weboldalra.
A strip USE jelölőzászlót le kell tiltani a MinGW build-ek hibakereséséhez.
Hibák bejelentésével kapcsolatos további útmutatásért tekintse meg a Bugzilla and Bugs részt a wiki.winehq oldalon.
Applications Crashing
Some applications such as games may crash on startup giving errors such as "page fault on read access". To mitigate this inside your wine scripts make sure you change directory to inside the game folder instead of running the game by specifying the path for it.
# Environment variables
game_dir="/path/to/game/dir/"
WINEPREFIX="${game_dir}/wineprefix/"
cd ${game_dir}
wine "game.exe"
Támogatás
A felhasználók további támogatást találhatnak a #gentoo-wine (webchat) csatornán a Libera.Chat weboldalon.
További olvasnivaló a témában
- DOSEMU — an application compatibility layer for MS-DOS geared more towards running MS-DOS applications than running games.
- Játékemulátorok — Gentoo által csomagolt játékemulátorok listája.
- Lutris — an open source gaming platform for Linux.
- Steam — egy videójáték digitális terjesztési szolgáltatás a Valve által.
- Winetricks — an easy way to work around problems in Wine.
Külső források
- Gentoo bugtracker: known bugs – Wine related bugs.
- Wine Application Database – Search for the game or program to install here to see if it is stable.
- Wine Staging at GitHub
- WineHQ Wiki
Hivatkozások
- ↑ Can't emerge dev-libs/icu[abi_x86_32], futex error? [SOLVED], Gentoo Forums. Elérve 2020. október 17-én.
- ↑ https://www.phoronix.com/news/Linux-NTSYNC-Driver-v7