From c01f13c84be31d12f250722d1b71be7b95ce9fe3 Mon Sep 17 00:00:00 2001 From: Bobbyperson Date: Fri, 12 Dec 2025 16:28:30 -0500 Subject: [PATCH 1/2] Does this work --- src/Dockerfile | 10 ++-------- src/nswrap/nswrap.c | 20 -------------------- src/wine/APKBUILD | 1 - 3 files changed, 2 insertions(+), 29 deletions(-) diff --git a/src/Dockerfile b/src/Dockerfile index 8fe59a0..5d5099d 100644 --- a/src/Dockerfile +++ b/src/Dockerfile @@ -1,6 +1,6 @@ # syntax=docker/dockerfile:1.2 -FROM alpine:3.15.4 AS base +FROM alpine:3.23.0 AS base FROM base AS build RUN apk update && apk add alpine-sdk sudo @@ -12,10 +12,6 @@ USER nsbuild RUN mkdir -p /nsbuild/src/main /nsbuild/packages/main && \ abuild-keygen -ain -FROM build AS build-wine -COPY --chown=nsbuild:nsbuild ./wine/ /nsbuild/src/main/wine/ -RUN ulimit -n 1024; cd /nsbuild/src/main/wine && abuild -r - FROM build AS build-northstar COPY --chown=nsbuild:nsbuild ./northstar/ /nsbuild/src/main/northstar/ RUN ulimit -n 1024; cd /nsbuild/src/main/northstar && abuild -r @@ -29,9 +25,7 @@ COPY --chown=nsbuild:nsbuild ./entrypoint/ /nsbuild/src/main/entrypoint/ RUN ulimit -n 1024; cd /nsbuild/src/main/entrypoint && abuild -r FROM base -RUN apk add --no-cache gnutls tzdata ca-certificates sudo -RUN --mount=from=build-wine,source=/nsbuild/packages/main/x86_64,target=/nsbuild/wine \ - apk add --no-cache --allow-untrusted /nsbuild/wine/northstar-dedicated-wine-[0-9]*-r*.apk xvfb +RUN apk add --no-cache wine gnutls tzdata ca-certificates sudo xvfb RUN --mount=from=build-northstar,source=/nsbuild/packages/main/x86_64,target=/nsbuild/northstar \ apk add --no-cache --allow-untrusted /nsbuild/northstar/*.apk RUN --mount=from=build-nswrap,source=/nsbuild/packages/main/x86_64,target=/nsbuild/nswrap \ diff --git a/src/nswrap/nswrap.c b/src/nswrap/nswrap.c index c1e9a3e..8f1d109 100644 --- a/src/nswrap/nswrap.c +++ b/src/nswrap/nswrap.c @@ -903,26 +903,6 @@ int main(int argc, char **argv) { return 1; } - // init setproctitle and attempt to ensure there is a placeholder arg consisting of spaces - for (const char *x = argv[argc - 1]; *x; x++) { - if (*x != ' ') { - char **nargv = alloca(argc + 2*sizeof(char*)); - for (int i = 0; i < argc; i++) { - nargv[i] = argv[i]; - } - nargv[argc] = " "; - nargv[argc+1] = NULL; - if (execve("/proc/self/exe", nargv, environ) == -1) { - ns_perror("warning: self-exec with additional space in argv for process title failed: execve"); - argc++; - } - break; - } - } - argc--; - setproctitle(argv, NULL); - argv[argc] = NULL; - if (chdir(argv[1])) { ns_perror("error: chdir '%s'", argv[1]); return 1; diff --git a/src/wine/APKBUILD b/src/wine/APKBUILD index d5af5f8..01a0941 100644 --- a/src/wine/APKBUILD +++ b/src/wine/APKBUILD @@ -55,7 +55,6 @@ build() { --without-gssapi \ --without-gstreamer \ --without-inotify \ - --without-krb5 \ --without-ldap \ --with-mingw \ --without-netapi \ From 63b8bfc2010a13f8303e2d7558eef7e0bee79059 Mon Sep 17 00:00:00 2001 From: Bobbyperson Date: Fri, 12 Dec 2025 16:32:56 -0500 Subject: [PATCH 2/2] delete wine folder --- src/wine/APKBUILD | 306 ------------------------ src/wine/createwindow.patch | 31 --- src/wine/rpath.patch | 57 ----- src/wine/wine-mr-1034.patch | 374 ------------------------------ src/wine/winemenubuilder.patch | 49 ---- src/wine/ws2siobacklogquery.patch | 22 -- 6 files changed, 839 deletions(-) delete mode 100644 src/wine/APKBUILD delete mode 100644 src/wine/createwindow.patch delete mode 100644 src/wine/rpath.patch delete mode 100644 src/wine/wine-mr-1034.patch delete mode 100644 src/wine/winemenubuilder.patch delete mode 100644 src/wine/ws2siobacklogquery.patch diff --git a/src/wine/APKBUILD b/src/wine/APKBUILD deleted file mode 100644 index 01a0941..0000000 --- a/src/wine/APKBUILD +++ /dev/null @@ -1,306 +0,0 @@ -# Maintainer: pg9182 <96569817+pg9182@users.noreply.github.com> -pkgname=northstar-dedicated-wine -pkgver=7.0 -pkgrel=0 -pkgdesc="Patched Wine build for the Northstar dedicated server" - -url="https://www.winehq.org" -license="LGPL-2.0-or-later" - -arch="x86_64" -provides="wine=${pkgver}" -subpackages="$pkgname-dev $pkgname-doc" -depends_dev="$pkgname perl" -makedepends="autoconf automake bison flex gnutls-dev libxi-dev mingw-w64-gcc mingw-w64-binutils linux-headers" - -# note: I've disabled the CreateWindow patch (which was to remove the need for -# X11 to run the dedicated server) since it seems to cause time to slow down -# in-game (possibly caused by the 6+ repeated calls to PeekMessage for the -# window handle in-between ticks). This will need more debugging later. - -options="textrels !check" -source="https://dl.winehq.org/wine/source/7.0/wine-$pkgver.tar.xz - rpath.patch - winemenubuilder.patch - ws2siobacklogquery.patch - wine-mr-1034.patch - " -# createwindow.patch - -builddir="$srcdir/wine-$pkgver" - -build() { - local _win64 _no_pie - case "$CARCH" in - x86_64) _win64=--enable-win64;; - x86) _no_pie="-no-pie";; - esac - ./configure \ - --build=$CBUILD \ - --host=$CHOST \ - --prefix=/usr \ - --libdir=/usr/lib \ - --sysconfdir=/etc \ - --localstatedir=/var \ - --without-alsa \ - --without-capi \ - --without-coreaudio \ - --without-cups \ - --without-dbus \ - --without-fontconfig \ - --without-freetype \ - --without-gettext \ - --with-gnutls \ - --without-gphoto \ - --without-gssapi \ - --without-gstreamer \ - --without-inotify \ - --without-ldap \ - --with-mingw \ - --without-netapi \ - --without-openal \ - --without-opencl \ - --without-opengl \ - --without-osmesa \ - --without-oss \ - --without-pcap \ - --without-pulse \ - --without-sane \ - --without-sdl \ - --without-udev \ - --without-usb \ - --without-v4l2 \ - --without-vkd3d \ - --without-vulkan \ - --with-x \ - --without-xcomposite \ - --without-xcursor \ - --without-xfixes \ - --without-xinerama \ - --without-xinput \ - --with-xinput2 \ - --without-xrandr \ - --without-xrender \ - --without-xshape \ - --without-xshm \ - --without-xxf86vm \ - $_win64 \ - \ - --disable-tests --disable-notepad --disable-msxml --disable-msxml2 --disable-msxml3 --disable-msxml4 \ - --disable-msxml5 --disable-msxml6 --disable-msado15 --disable-msadp32 --disable-msdaps --disable-msdasql \ - --disable-quartz --disable-sapi --disable-scsiport --disable-usbd --disable-wineps_drv --disable-winspool_drv \ - --disable-mp3dmod --disable-l3codeca --disable-winedbg \ - \ - --without-xml --without-xslt \ - --disable-xml2 --disable-xslt \ - \ - --disable-arp --disable-aspnet_regiis --disable-attrib --disable-cabarc --disable-cacls --disable-chcp_com --disable-clock --disable-control \ - --disable-cscript --disable-dism --disable-dplaysvr --disable-dpnsvr --disable-dpvsetup --disable-dxdiag --disable-eject --disable-expand \ - --disable-extrac32 --disable-fc --disable-find --disable-findstr --disable-fsutil --disable-hostname --disable-icacls --disable-icinfo \ - --disable-iexplore --disable-ipconfig --disable-lodctr --disable-mshta --disable-msidb --disable-msiexec --disable-msinfo32 --disable-net \ - --disable-netsh --disable-netstat --disable-ngen --disable-oleview --disable-ping --disable-powershell --disable-presentationfontcache \ - --disable-progman --disable-robocopy --disable-sc --disable-schtasks --disable-sdbinst --disable-secedit --disable-servicemodelreg --disable-shutdown \ - --disable-spoolsv --disable-subst --disable-systeminfo --disable-taskmgr --disable-termsv --disable-uninstaller --disable-unlodctr --disable-view \ - --disable-wevtutil --disable-where --disable-whoami --disable-winebrowser --disable-wineconsole --disable-winefile --disable-winemenubuilder \ - --disable-winemine --disable-winemsibuilder --disable-winetest --disable-winhlp32 --disable-winmgmt --disable-winver --disable-wmplayer \ - --disable-wordpad --disable-write --disable-wscript --disable-wuauserv --disable-wusa --disable-xcopy --disable-acledit --disable-aclui \ - --disable-adsldp --disable-adsldpc --disable-amsi --disable-amstream --disable-api_ms_win_appmodel_identity_l1_1_0 \ - --disable-api_ms_win_appmodel_runtime_l1_1_0 --disable-api_ms_win_appmodel_runtime_l1_1_1 --disable-api_ms_win_appmodel_runtime_l1_1_2 \ - --disable-api_ms_win_crt_conio_l1_1_0 --disable-api_ms_win_crt_multibyte_l1_1_0 --disable-api_ms_win_crt_private_l1_1_0 \ - --disable-api_ms_win_crt_process_l1_1_0 --disable-api_ms_win_devices_config_l1_1_0 --disable-api_ms_win_devices_config_l1_1_1 \ - --disable-api_ms_win_devices_query_l1_1_1 --disable-api_ms_win_downlevel_advapi32_l1_1_0 --disable-api_ms_win_downlevel_advapi32_l2_1_0 \ - --disable-api_ms_win_downlevel_kernel32_l2_1_0 --disable-api_ms_win_downlevel_normaliz_l1_1_0 --disable-api_ms_win_downlevel_ole32_l1_1_0 \ - --disable-api_ms_win_downlevel_shell32_l1_1_0 --disable-api_ms_win_downlevel_shlwapi_l1_1_0 --disable-api_ms_win_downlevel_shlwapi_l2_1_0 \ - --disable-api_ms_win_downlevel_user32_l1_1_0 --disable-api_ms_win_downlevel_version_l1_1_0 --disable-api_ms_win_dx_d3dkmt_l1_1_0 \ - --disable-api_ms_win_eventing_classicprovider_l1_1_0 --disable-api_ms_win_eventing_consumer_l1_1_0 --disable-api_ms_win_eventing_controller_l1_1_0 \ - --disable-api_ms_win_eventing_legacy_l1_1_0 --disable-api_ms_win_eventing_provider_l1_1_0 --disable-api_ms_win_eventlog_legacy_l1_1_0 \ - --disable-api_ms_win_gaming_tcui_l1_1_0 --disable-api_ms_win_gdi_dpiinfo_l1_1_0 --disable-api_ms_win_mm_joystick_l1_1_0 \ - --disable-api_ms_win_mm_misc_l1_1_1 --disable-api_ms_win_mm_mme_l1_1_0 --disable-api_ms_win_mm_time_l1_1_0 \ - --disable-api_ms_win_ntuser_dc_access_l1_1_0 --disable-api_ms_win_ntuser_rectangle_l1_1_0 --disable-api_ms_win_ntuser_sysparams_l1_1_0 \ - --disable-api_ms_win_perf_legacy_l1_1_0 --disable-api_ms_win_power_base_l1_1_0 --disable-api_ms_win_power_setting_l1_1_0 \ - --disable-api_ms_win_rtcore_ntuser_draw_l1_1_0 --disable-api_ms_win_rtcore_ntuser_private_l1_1_0 --disable-api_ms_win_rtcore_ntuser_private_l1_1_4 \ - --disable-api_ms_win_rtcore_ntuser_window_l1_1_0 --disable-api_ms_win_rtcore_ntuser_winevent_l1_1_0 \ - --disable-api_ms_win_rtcore_ntuser_wmpointer_l1_1_0 --disable-api_ms_win_rtcore_ntuser_wmpointer_l1_1_3 \ - --disable-api_ms_win_security_activedirectoryclient_l1_1_0 --disable-api_ms_win_security_audit_l1_1_1 --disable-api_ms_win_security_base_l1_1_0 \ - --disable-api_ms_win_security_base_l1_2_0 --disable-api_ms_win_security_base_private_l1_1_1 --disable-api_ms_win_security_credentials_l1_1_0 \ - --disable-api_ms_win_security_cryptoapi_l1_1_0 --disable-api_ms_win_security_grouppolicy_l1_1_0 --disable-api_ms_win_security_lsalookup_l1_1_0 \ - --disable-api_ms_win_security_lsalookup_l1_1_1 --disable-api_ms_win_security_lsalookup_l2_1_0 --disable-api_ms_win_security_lsalookup_l2_1_1 \ - --disable-api_ms_win_security_lsapolicy_l1_1_0 --disable-api_ms_win_security_provider_l1_1_0 --disable-api_ms_win_security_sddl_l1_1_0 \ - --disable-api_ms_win_security_systemfunctions_l1_1_0 --disable-api_ms_win_service_core_l1_1_0 --disable-api_ms_win_service_core_l1_1_1 \ - --disable-api_ms_win_service_management_l1_1_0 --disable-api_ms_win_service_management_l2_1_0 --disable-api_ms_win_service_private_l1_1_1 \ - --disable-api_ms_win_service_winsvc_l1_1_0 --disable-api_ms_win_service_winsvc_l1_2_0 --disable-api_ms_win_shcore_obsolete_l1_1_0 \ - --disable-api_ms_win_shcore_scaling_l1_1_0 --disable-api_ms_win_shcore_scaling_l1_1_1 --disable-api_ms_win_shcore_stream_l1_1_0 \ - --disable-api_ms_win_shcore_stream_winrt_l1_1_0 --disable-api_ms_win_shcore_thread_l1_1_0 --disable-api_ms_win_shell_shellcom_l1_1_0 \ - --disable-api_ms_win_shell_shellfolders_l1_1_0 --disable-apphelp --disable-appwiz_cpl --disable-atl --disable-atl110 --disable-atl80 --disable-atl90 \ - --disable-atlthunk --disable-atmlib --disable-authz --disable-avrt --disable-bluetoothapis --disable-browseui --disable-bthprops_cpl \ - --disable-cabinet --disable-capi2032 --disable-cards --disable-cdosys --disable-cfgmgr32 --disable-clusapi --disable-comcat --disable-compstui \ - --disable-comsvcs --disable-connect --disable-credui --disable-crtdll --disable-cryptdll --disable-cryptext --disable-cryptsp --disable-ctapi32 \ - --disable-ctl3d32 --disable-d2d1 --disable-d3d10 --disable-d3d10_1 --disable-d3d10core --disable-d3d11 --disable-d3d12 --disable-d3d8 \ - --disable-d3d8thk --disable-d3d9 --disable-d3dcompiler_33 --disable-d3dcompiler_34 --disable-d3dcompiler_35 --disable-d3dcompiler_36 \ - --disable-d3dcompiler_37 --disable-d3dcompiler_38 --disable-d3dcompiler_39 --disable-d3dcompiler_40 --disable-d3dcompiler_41 --disable-d3dcompiler_42 \ - --disable-d3dcompiler_43 --disable-d3dcompiler_46 --disable-d3dcompiler_47 --disable-d3dim --disable-d3dim700 --disable-d3drm --disable-d3dx10_33 \ - --disable-d3dx10_34 --disable-d3dx10_35 --disable-d3dx10_36 --disable-d3dx10_37 --disable-d3dx10_38 --disable-d3dx10_39 --disable-d3dx10_40 \ - --disable-d3dx10_41 --disable-d3dx10_42 --disable-d3dx10_43 --disable-d3dx11_42 --disable-d3dx11_43 --disable-d3dx9_24 --disable-d3dx9_25 \ - --disable-d3dx9_26 --disable-d3dx9_27 --disable-d3dx9_28 --disable-d3dx9_29 --disable-d3dx9_30 --disable-d3dx9_31 --disable-d3dx9_32 \ - --disable-d3dx9_33 --disable-d3dx9_34 --disable-d3dx9_35 --disable-d3dx9_36 --disable-d3dx9_37 --disable-d3dx9_38 --disable-d3dx9_39 \ - --disable-d3dx9_40 --disable-d3dx9_41 --disable-d3dx9_42 --disable-d3dx9_43 --disable-d3dxof --disable-davclnt --disable-dbgeng --disable-dciman32 \ - --disable-dcomp --disable-ddraw --disable-ddrawex --disable-dhcpcsvc --disable-dhcpcsvc6 --disable-dhtmled_ocx --disable-difxapi --disable-dinput \ - --disable-dinput8 --disable-directmanipulation --disable-dispex --disable-dmband --disable-dmcompos --disable-dmime --disable-dmloader \ - --disable-dmscript --disable-dmstyle --disable-dmsynth --disable-dmusic --disable-dmusic32 --disable-dplay --disable-dplayx --disable-dpnaddr \ - --disable-dpnet --disable-dpnhpast --disable-dpnhupnp --disable-dpnlobby --disable-dpvoice --disable-dpwsockx --disable-drmclien --disable-dsdmo \ - --disable-dsquery --disable-dssenh --disable-dsuiext --disable-dswave --disable-dwmapi --disable-dwrite --disable-dx8vb --disable-dxdiagn \ - --disable-dxgi --disable-dxtrans --disable-dxva2 --disable-esent --disable-evr --disable-ext_ms_win_authz_context_l1_1_0 \ - --disable-ext_ms_win_domainjoin_netjoin_l1_1_0 --disable-ext_ms_win_dwmapi_ext_l1_1_0 --disable-ext_ms_win_gdi_dc_create_l1_1_0 \ - --disable-ext_ms_win_gdi_dc_create_l1_1_1 --disable-ext_ms_win_gdi_dc_l1_2_0 --disable-ext_ms_win_gdi_devcaps_l1_1_0 \ - --disable-ext_ms_win_gdi_draw_l1_1_0 --disable-ext_ms_win_gdi_draw_l1_1_1 --disable-ext_ms_win_gdi_font_l1_1_0 --disable-ext_ms_win_gdi_font_l1_1_1 \ - --disable-ext_ms_win_gdi_render_l1_1_0 --disable-ext_ms_win_kernel32_package_current_l1_1_0 --disable-ext_ms_win_kernel32_package_l1_1_1 \ - --disable-ext_ms_win_ntuser_dialogbox_l1_1_0 --disable-ext_ms_win_ntuser_draw_l1_1_0 --disable-ext_ms_win_ntuser_gui_l1_1_0 \ - --disable-ext_ms_win_ntuser_gui_l1_3_0 --disable-ext_ms_win_ntuser_keyboard_l1_3_0 --disable-ext_ms_win_ntuser_message_l1_1_0 \ - --disable-ext_ms_win_ntuser_message_l1_1_1 --disable-ext_ms_win_ntuser_misc_l1_1_0 --disable-ext_ms_win_ntuser_misc_l1_2_0 \ - --disable-ext_ms_win_ntuser_misc_l1_5_1 --disable-ext_ms_win_ntuser_mouse_l1_1_0 --disable-ext_ms_win_ntuser_private_l1_1_1 \ - --disable-ext_ms_win_ntuser_private_l1_3_1 --disable-ext_ms_win_ntuser_rectangle_ext_l1_1_0 --disable-ext_ms_win_ntuser_uicontext_ext_l1_1_0 \ - --disable-ext_ms_win_ntuser_windowclass_l1_1_0 --disable-ext_ms_win_ntuser_windowclass_l1_1_1 --disable-ext_ms_win_ntuser_window_l1_1_0 \ - --disable-ext_ms_win_ntuser_window_l1_1_1 --disable-ext_ms_win_ntuser_window_l1_1_4 --disable-ext_ms_win_oleacc_l1_1_0 \ - --disable-ext_ms_win_ras_rasapi32_l1_1_0 --disable-ext_ms_win_rtcore_gdi_devcaps_l1_1_0 --disable-ext_ms_win_rtcore_gdi_object_l1_1_0 \ - --disable-ext_ms_win_rtcore_gdi_rgn_l1_1_0 --disable-ext_ms_win_rtcore_ntuser_cursor_l1_1_0 --disable-ext_ms_win_rtcore_ntuser_dc_access_l1_1_0 \ - --disable-ext_ms_win_rtcore_ntuser_dpi_l1_1_0 --disable-ext_ms_win_rtcore_ntuser_dpi_l1_2_0 --disable-ext_ms_win_rtcore_ntuser_rawinput_l1_1_0 \ - --disable-ext_ms_win_rtcore_ntuser_syscolors_l1_1_0 --disable-ext_ms_win_rtcore_ntuser_sysparams_l1_1_0 --disable-ext_ms_win_security_credui_l1_1_0 \ - --disable-ext_ms_win_security_cryptui_l1_1_0 --disable-ext_ms_win_shell_comctl32_init_l1_1_0 --disable-ext_ms_win_shell_comdlg32_l1_1_0 \ - --disable-ext_ms_win_shell_shell32_l1_2_0 --disable-ext_ms_win_uxtheme_themes_l1_1_0 --disable-faultrep --disable-feclient --disable-fltlib \ - --disable-fntcache --disable-fontsub --disable-fusion --disable-fwpuclnt --disable-gameux --disable-gamingtcui --disable-gdiplus --disable-glu32 \ - --disable-gphoto2_ds --disable-gpkcsp --disable-hal --disable-hlink --disable-hnetcfg --disable-iccvid --disable-icmp --disable-ieframe \ - --disable-ieproxy --disable-imagehlp --disable-inetcomm --disable-inetcpl_cpl --disable-inetmib1 --disable-infosoft --disable-initpki \ - --disable-inkobj --disable-inseng --disable-iprop --disable-irprops_cpl --disable-itircl --disable-itss --disable-joy_cpl --disable-jscript \ - --disable-jsproxy --disable-ksproxy_ax --disable-ksuser --disable-ktmw32 --disable-loadperf --disable-localspl --disable-localui --disable-lz32 \ - --disable-mapi32 --disable-mapistub --disable-mciavi32 --disable-mcicda --disable-mciqtz32 --disable-mciseq --disable-mciwave --disable-mf \ - --disable-mf3216 --disable-mferror --disable-mfmediaengine --disable-mfplat --disable-mfplay --disable-mfreadwrite --disable-mgmtapi \ - --disable-midimap --disable-mmcndmgr --disable-msasn1 --disable-mscat32 --disable-mscms --disable-mscoree --disable-mscorwks --disable-msctf \ - --disable-msctfmonitor --disable-msctfp --disable-msdelta --disable-msdrm --disable-msftedit --disable-mshtml --disable-mshtml_tlb --disable-msi \ - --disable-msident --disable-msimg32 --disable-msimsg --disable-msimtf --disable-msisys_ocx --disable-msls31 --disable-msnet32 --disable-mspatcha \ - --disable-msports --disable-msrle32 --disable-msscript_ocx --disable-mssign32 --disable-mssip32 --disable-mstask --disable-msvcirt --disable-msvcm80 \ - --disable-msvcm90 --disable-msvcp100 --disable-msvcp120 --disable-msvcp120_app --disable-msvcp60 --disable-msvcp70 --disable-msvcp71 \ - --disable-msvcp80 --disable-msvcp90 --disable-msvcp_win --disable-msvcr100 --disable-msvcr120 --disable-msvcr120_app --disable-msvcr70 \ - --disable-msvcr71 --disable-msvcr80 --disable-msvcr90 --disable-msvidc32 --disable-mswsock --disable-mtxdm --disable-ncrypt --disable-nddeapi \ - --disable-netcfgx --disable-netprofm --disable-netutils --disable-ninput --disable-npmshtml --disable-npptools --disable-ntdsapi --disable-ntprint \ - --disable-objsel --disable-odbc32 --disable-odbcbcp --disable-odbccp32 --disable-odbccu32 --disable-oleacc --disable-olecli32 --disable-oledlg \ - --disable-olepro32 --disable-olesvr32 --disable-olethk32 --disable-opcservices --disable-openal32 --disable-opencl --disable-packager --disable-pdh \ - --disable-photometadatahandler --disable-pidgen --disable-powrprof --disable-printui --disable-prntvpt --disable-pstorec --disable-pwrshplugin \ - --disable-qasf --disable-qdvd --disable-qmgr --disable-qmgrprxy --disable-query --disable-qwave --disable-rasapi32 --disable-rasdlg \ - --disable-resutils --disable-riched20 --disable-riched32 --disable-rsabase --disable-rstrtmgr --disable-rtutils --disable-rtworkq --disable-samlib \ - --disable-sane_ds --disable-sas --disable-scarddlg --disable-sccbase --disable-schedsvc --disable-scrobj --disable-scrrun --disable-security \ - --disable-sensapi --disable-serialui --disable-sfc --disable-sfc_os --disable-shdoclc --disable-shfolder --disable-slbcsp --disable-slc \ - --disable-snmpapi --disable-softpub --disable-spoolss --disable-sppc --disable-srclient --disable-srvcli --disable-sspicli --disable-stdole2_tlb \ - --disable-stdole32_tlb --disable-sti --disable-strmdll --disable-svrapi --disable-sxs --disable-t2embed --disable-tapi32 --disable-taskschd \ - --disable-tbs --disable-tdh --disable-traffic --disable-twain_32 --disable-uianimation --disable-uiautomationcore --disable-uiribbon \ - --disable-unicows --disable-updspapi --disable-url --disable-usp10 --disable-utildll --disable-vbscript --disable-vcomp --disable-vcomp100 \ - --disable-vcomp110 --disable-vcomp120 --disable-vcomp140 --disable-vcomp90 --disable-vdmdbg --disable-vga --disable-virtdisk --disable-vssapi \ - --disable-vulkan_1 --disable-wdscore --disable-webservices --disable-websocket --disable-wer --disable-wevtapi --disable-wiaservc --disable-wimgapi \ - --disable-winealsa_drv --disable-wineandroid_drv --disable-winecoreaudio_drv --disable-wined3d --disable-winegstreamer --disable-winemac_drv \ - --disable-winemapi --disable-wineoss_drv --disable-winepulse_drv --disable-wineusb_sys --disable-wing32 --disable-winhttp --disable-winnls32 \ - --disable-winscard --disable-winsta --disable-wintab32 --disable-winusb --disable-wlanapi --disable-wlanui --disable-wmasf --disable-wmi \ - --disable-wmp --disable-wmphoto --disable-wmvcore --disable-wnaspi32 --disable-wow64 --disable-wow64cpu --disable-wow64win --disable-wpc \ - --disable-wpcap --disable-wsdapi --disable-wshom_ocx --disable-wsnmp32 --disable-wtsapi32 --disable-wuapi --disable-wuaueng --disable-x3daudio1_0 \ - --disable-x3daudio1_1 --disable-x3daudio1_2 --disable-x3daudio1_3 --disable-x3daudio1_4 --disable-x3daudio1_5 --disable-x3daudio1_6 \ - --disable-x3daudio1_7 --disable-xactengine2_0 --disable-xactengine2_4 --disable-xactengine2_7 --disable-xactengine2_9 --disable-xactengine3_0 \ - --disable-xactengine3_1 --disable-xactengine3_2 --disable-xactengine3_3 --disable-xactengine3_4 --disable-xactengine3_5 --disable-xactengine3_6 \ - --disable-xactengine3_7 --disable-xapofx1_1 --disable-xapofx1_2 --disable-xapofx1_3 --disable-xapofx1_4 --disable-xapofx1_5 --disable-xaudio2_0 \ - --disable-xaudio2_1 --disable-xaudio2_2 --disable-xaudio2_3 --disable-xaudio2_4 --disable-xaudio2_5 --disable-xaudio2_6 --disable-xaudio2_7 \ - --disable-xaudio2_8 --disable-xaudio2_9 --disable-xinput1_1 --disable-xinput1_2 --disable-xinput1_4 --disable-xmllite --disable-xolehlp \ - --disable-xpsprint --disable-xpssvcs - # - ## note: first iteration was done with ghcr.io/pg9182/northstar-dedicated:1.20220116.gite7a0ed9-tf2.0.11.0-ns1.4.0 (i.e. a mostly vanilla wine 6.23 build) - ## libs_wineprefix=activeds advapi32 advpack atl100 avicap32 bcrypt cng combase comctl32 comdlg32 conhost crypt32 cryptdlg cryptnet cryptui devenum dnsapi dsound explorer fltmgr gdi32 hh hidclass hidparse http ieframe iexplore imaadp32 imm32 iphlpapi kernel32 kernelbase ksecdd l3codeca light mlang mofcomp mountmgr mp3dmod mpr msacm32 msado15 msadp32 msdaps msdasql msdmo msg711 msgsm32 msisip msvcrt msvfw32 msxml msxml2 msxml3 msxml4 msxml6 ndis netio newdev notepad nsi nsiproxy ntdll ntoskrnl ole32 oleaut32 oledb32 powershell propsys qcap qedit quartz reg regedit rpcrt4 rsaenh rundll32 sapi scsiport sechost services setupapi shcore shdocvw shell32 shlwapi start tdi tzres ucrtbase urlmon usbd user32 userenv uxtheme version wbemdisp wbemprox win32u windows windowscodecs wineboot winebus winedevice winehid winemenubuilder wineps winevulkan winex11 winexinput wininet winmm winspool wintrust wmic wmiutils wmplayer wordpad ws2_32 - ## libs_nsdedi=actxprxy advapi32 api-ms-win-crt-convert-l1-1-0 api-ms-win-crt-environment-l1-1-0 api-ms-win-crt-filesystem-l1-1-0 api-ms-win-crt-heap-l1-1-0 api-ms-win-crt-locale-l1-1-0 api-ms-win-crt-math-l1-1-0 api-ms-win-crt-runtime-l1-1-0 api-ms-win-crt-stdio-l1-1-0 api-ms-win-crt-string-l1-1-0 api-ms-win-crt-time-l1-1-0 api-ms-win-crt-utility-l1-1-0 avifil32 bcrypt combase comctl32 concrt140 conhost crypt32 dbghelp dnsapi dsound explorer gdi32 hid hidclass hidparse imm32 iphlpapi kerberos kernel32 kernelbase mmdevapi mountmgr msacm32 msv1_0 msvcp110 msvcp140 msvcr110 msvcrt msvfw32 ndis netapi32 normaliz nsi nsiproxy ntdll ntoskrnl ole32 oleaut32 opengl32 plugplay propsys psapi rpcrt4 rpcss rsaenh schannel sechost secur32 services setupapi shcore shell32 shlwapi svchost tzres ucrtbase user32 userenv uxtheme vcruntime140 vcruntime140_1 version wevtsvc win32u windowscodecs wineboot winebus winedevice winehid winemenubuilder winex11 winmm wldap32 ws2_32 wsock32 xinput1_3 - ## https://gist.github.com/pg9182/f4d66fe9fb1b0fa3f1c0a903268979f4 - ## the additional disables were mostly based on removing obviously unused programs - # - ## current iteration is on ghcr.io/pg9182/northstar-dedicated:1.20220117.git5ce2886-tf2.0.11.0-ns1.4.0 (which has the reduced libs based on the stuff above; see the commits after that one) - ## libs_wineprefix=activeds advapi32 advpack atl100 avicap32 bcrypt cng combase comctl32 comdlg32 crypt32 cryptdlg cryptnet cryptui devenum dnsapi dsound explorer fltmgr gdi32 hh hidclass hidparse http imaadp32 imm32 iphlpapi kernel32 kernelbase ksecdd l3codeca light mlang mofcomp mountmgr mp3dmod mpr msacm32 msado15 msadp32 msdaps msdasql msdmo msg711 msgsm32 msisip msvcrt msvfw32 msxml msxml2 msxml3 msxml4 msxml6 ndis netio newdev notepad nsi nsiproxy ntdll ntoskrnl ole32 oleaut32 oledb32 propsys qcap qedit quartz reg regedit rpcrt4 rsaenh rundll32 sapi scsiport sechost services setupapi shcore shdocvw shell32 shlwapi start tdi tzres ucrtbase urlmon usbd user32 userenv uxtheme version wbemdisp wbemprox win32u windows windowscodecs wineboot winebus winedevice winehid wineps winevulkan winex11 winexinput wininet winmm winspool wintrust wmic wmiutils ws2_32 - ## libs_nsdedi=actxprxy advapi32 api-ms-win-crt-convert-l1-1-0 api-ms-win-crt-environment-l1-1-0 api-ms-win-crt-filesystem-l1-1-0 api-ms-win-crt-heap-l1-1-0 api-ms-win-crt-locale-l1-1-0 api-ms-win-crt-math-l1-1-0 api-ms-win-crt-runtime-l1-1-0 api-ms-win-crt-stdio-l1-1-0 api-ms-win-crt-string-l1-1-0 api-ms-win-crt-time-l1-1-0 api-ms-win-crt-utility-l1-1-0 avifil32 bcrypt combase comctl32 concrt140 conhost crypt32 dbghelp dnsapi dsound explorer gdi32 hid hidclass hidparse imm32 iphlpapi kerberos kernel32 kernelbase mmdevapi mountmgr msacm32 msv1_0 msvcp110 msvcp140 msvcr110 msvcrt msvfw32 ndis netapi32 normaliz nsi nsiproxy ntdll ntoskrnl ole32 oleaut32 opengl32 plugplay psapi rpcrt4 rpcss rsaenh schannel sechost secur32 services setupapi shcore shell32 shlwapi svchost tzres ucrtbase user32 userenv uxtheme vcruntime140 vcruntime140_1 version wevtsvc win32u wineboot winebus winedevice winehid winex11 winmm wldap32 ws2_32 wsock32 xinput1_3 - ## https://gist.github.com/pg9182/9cdc3e8fe52aafc137d7f114b99fa420 - ## the additional disables were based on manual inspection of dlls only loaded twice during wineprefix setup and by manually checking for thirdparty libs not referenced anymore due to the removals (I'm keeping those --without flags separate since they only work if we're disabling some of the dlls) - # - ## 2022/10/03 (ns > 1.9.6) - add back xinput_9_1_0 for the xinput aslr fixes - # - # ctr="$(docker run --detach --tty --rm -e NS_SERVER_NAME=test ... --entrypoint /bin/ash ghcr.io/pg9182/northstar-dedicated:1.20220117.git5ce2886-tf2.0.11.0-ns1.4.0)" - # docker exec "$ctr" sudo apk add inotify-tools - # docker exec "$ctr" rm -rf /home/northstar/.wine - # docker exec "$ctr" inotifywait -mr /usr/lib/wine/ > inotify.wineprefix.log & - # docker exec "$ctr" /usr/libexec/nsdedi __wineprefix__ - # docker exec "$ctr" killall inotifywait - # docker exec "$ctr" inotifywait -mr /usr/lib/wine/ > inotify.nsdedi.log & - # docker exec -it "$ctr" /usr/libexec/nsdedi " " # ctrl-c it after it finishes loading and registering to the master server - # docker exec "$ctr" killall inotifywait - # docker kill "$ctr" - # - # libs_wineprefix="$(cat inotify.wineprefix.log | grep "^/usr/lib/wine/x86_64-windows/" | grep " CLOSE_NOWRITE,CLOSE " | cut -d " " -f3 | cut -d. -f1 | sort | uniq -c | grep -v "\s1 " | rev | cut -d " " -f1 | rev | xargs echo)" - # libs_nsdedi="$(cat inotify.nsdedi.log | grep "^/usr/lib/wine/x86_64-windows/" | grep " CLOSE_NOWRITE,CLOSE " | cut -d " " -f3 | cut -d. -f1 | sort | uniq | xargs echo)" - # - # pushd src/wine - # for x in programs/* dlls/*; do - # needed=no - # for lib in winecrt0 $libs_wineprefix $libs_nsdedi winedbg cmd winecfg winepath taskkill tasklist mscvr api-ms-win-core-; do - # if [[ $x == *"/$lib"* ]]; then - # needed=yes - # fi - # done - # if [[ $needed == "no" ]]; then - # echo $x - # fi - # done | - # xargs -i@ grep -F "wine_fn_config_makefile @ enable_" configure | grep -Fv enable_win16 | sed 's/^.*enable_/--disable-/' | - # xargs echo | fold -sw150 | sed 's/$/\\/g' - # popd - # - make LDFLAGS="$LDFLAGS $_no_pie" \ - tools/widl/widl \ - tools/winebuild/winebuild \ - tools/widl/widl \ - tools/winebuild/winebuild \ - tools/winegcc/winegcc \ - tools/wrc/wrc - make -} - -package() { - make DESTDIR="$pkgdir" install - - install -Dm755 tools/wineapploader \ - "$pkgdir"/usr/bin/wineapploader - - local file - for file in msiexec notepad regedit regsvr32 wineboot \ - winecfg wineconsole winefile winemine winepath - do - if rm "$pkgdir"/usr/bin/$file; then - ln -sf /usr/bin/wineapploader "$pkgdir"/usr/bin/$file - fi - done -} - -dev() { - default_dev - - install -d "$subpkgdir"/usr/bin - - local file - for file in widl wmc wrc winebuild winedump function_grep.pl \ - winedbg winemaker winegcc winecpp wineg++ - do - mv "$pkgdir"/usr/bin/$file "$subpkgdir"/usr/bin/ || true - done -} - -doc() { - default_doc - rm -fr "$subpkgdir"/usr/share/man/*.UTF-8 -} - -sha512sums=" -eec17b046ed5447eb540f421c9b2748d9419ce087496c2743a9914fd27bbe5ff9da0cfe47d3cd76fa97323bd1188a1d82b1eef4968d86ed1957dc1a95e28529c wine-7.0.tar.xz -1f023ec35610d7f39eee5ee8e53abf8905509dd37513a1ec00f498e5e28890c60555d43daeae28b806879050b3422575f3552fa338177e923b0471c89418a607 rpath.patch -eaaa991510d6de7f33ea8d81954737ab4a18f40675f3fa5822367fe40e439880246209d913f646e80e1120d59fcedaf97d069cf1b203c0d7d032bc8b07faa29d winemenubuilder.patch -bf1630e4f8aab6b220eb95beafe2891549bb6d7be17aed9bbd1269409fd589f05fc9b68c123d58cdfc5eff60d53518b232c59b6c4648b7c6e36a2416f4913d33 ws2siobacklogquery.patch -caa47044e6caa5edb3f55596bfcc96c0e6166a7d84bc66e13813a1665e27b15524ac4db3bc354d89491d0ba2e8356075141fc21e21662d1469843699e9088da1 wine-mr-1034.patch -" -#996a6fcf19875b170eb51ccd6f4e5ec32f77326a7ab8c6227c0fa4e3acacf9330efeafdb77de17a176e73d1ec7f58cac3293302833284ce805b6b5e751f9615e createwindow.patch diff --git a/src/wine/createwindow.patch b/src/wine/createwindow.patch deleted file mode 100644 index 80949b0..0000000 --- a/src/wine/createwindow.patch +++ /dev/null @@ -1,31 +0,0 @@ -diff --git a/dlls/user32/driver.c b/dlls/user32/driver.c -index 73f4ee67257..f914333b534 100644 ---- a/dlls/user32/driver.c -+++ b/dlls/user32/driver.c -@@ -161,16 +161,7 @@ static void CDECL nulldrv_UpdateClipboard(void) - - static BOOL CDECL nodrv_CreateWindow( HWND hwnd ) - { -- static int warned; -- HWND parent = GetAncestor( hwnd, GA_PARENT ); -- -- /* HWND_MESSAGE windows don't need a graphics driver */ -- if (!parent || parent == get_user_thread_info()->msg_window) return TRUE; -- if (warned++) return FALSE; -- -- ERR_(winediag)( "Application tried to create a window, but no driver could be loaded.\n" ); -- if (driver_load_error[0]) ERR_(winediag)( "%s\n", driver_load_error ); -- return FALSE; -+ return TRUE; - } - - static BOOL CDECL nulldrv_CreateDesktopWindow( HWND hwnd ) -@@ -242,7 +233,7 @@ static void CDECL nulldrv_SetWindowText( HWND hwnd, LPCWSTR text ) - - static UINT CDECL nulldrv_ShowWindow( HWND hwnd, INT cmd, RECT *rect, UINT swp ) - { -- return ~0; /* use default implementation */ -+ return 0; - } - - static LRESULT CDECL nulldrv_SysCommand( HWND hwnd, WPARAM wparam, LPARAM lparam ) diff --git a/src/wine/rpath.patch b/src/wine/rpath.patch deleted file mode 100644 index 465105a..0000000 --- a/src/wine/rpath.patch +++ /dev/null @@ -1,57 +0,0 @@ -diff --git a/configure b/configure -index dcce2e8644e..b0a060e5961 100755 ---- a/configure -+++ b/configure -@@ -10858,6 +10858,38 @@ fi - LIBWINE_DEPENDS="wine.map" - - TOP_INSTALL_LIB="$TOP_INSTALL_LIB libs/wine/libwine.so.$libwine_version libs/wine/libwine.so.$libwine_soversion" -+ -+ # do this at the end because it needs double dollar for makefile -+ as_ac_var=`printf "%s\n" "ac_cv_cflags_-Wl,-rpath,\\\\\\$ORIGIN" | $as_tr_sh` -+{ printf "%s\n" "$as_me:${as_lineno-$LINENO}: checking whether the compiler supports -Wl,-rpath,\\\$ORIGIN" >&5 -+printf %s "checking whether the compiler supports -Wl,-rpath,\\\$ORIGIN... " >&6; } -+if eval test \${$as_ac_var+y} -+then : -+ printf %s "(cached) " >&6 -+else $as_nop -+ ac_wine_try_cflags_saved=$CFLAGS -+CFLAGS="$CFLAGS -Wl,-rpath,\\\$ORIGIN" -+cat confdefs.h - <<_ACEOF >conftest.$ac_ext -+/* end confdefs.h. */ -+int main(int argc, char **argv) { return 0; } -+_ACEOF -+if ac_fn_c_try_link "$LINENO" -+then : -+ eval "$as_ac_var=yes" -+else $as_nop -+ eval "$as_ac_var=no" -+fi -+rm -f core conftest.err conftest.$ac_objext conftest.beam \ -+ conftest$ac_exeext conftest.$ac_ext -+CFLAGS=$ac_wine_try_cflags_saved -+fi -+eval ac_res=\$$as_ac_var -+ { printf "%s\n" "$as_me:${as_lineno-$LINENO}: result: $ac_res" >&5 -+printf "%s\n" "$ac_res" >&6; } -+if eval test \"x\$"$as_ac_var"\" = x"yes" -+then : -+ UNIXLDFLAGS="$UNIXLDFLAGS '-Wl,-rpath,\$\$ORIGIN'" -+fi - ;; - esac - -diff --git a/configure.ac b/configure.ac -index b42cb8a5346..c9c929ca911 100644 ---- a/configure.ac -+++ b/configure.ac -@@ -859,6 +859,9 @@ case $host_os in - AC_SUBST(LIBWINE_SHAREDLIB,"libwine.so.$libwine_version") - AC_SUBST(LIBWINE_DEPENDS,"wine.map") - TOP_INSTALL_LIB="$TOP_INSTALL_LIB libs/wine/libwine.so.$libwine_version libs/wine/libwine.so.$libwine_soversion" -+ -+ # do this at the end because it needs double dollar for makefile -+ WINE_TRY_CFLAGS([-Wl,-rpath,\\\$ORIGIN],[UNIXLDFLAGS="$UNIXLDFLAGS '-Wl,-rpath,\$\$ORIGIN'"]) - ;; - esac - diff --git a/src/wine/wine-mr-1034.patch b/src/wine/wine-mr-1034.patch deleted file mode 100644 index fb8f919..0000000 --- a/src/wine/wine-mr-1034.patch +++ /dev/null @@ -1,374 +0,0 @@ -diff --git a/dlls/msvcp140/msvcp140.spec b/dlls/msvcp140/msvcp140.spec -index 3945a4bfbd4..631bdeb9bb6 100644 ---- a/dlls/msvcp140/msvcp140.spec -+++ b/dlls/msvcp140/msvcp140.spec -@@ -1689,26 +1689,26 @@ - @ stub ?_Xregex_error@std@@YAXW4error_type@regex_constants@1@@Z - @ cdecl -arch=win32 ?_Xruntime_error@std@@YAXPBD@Z(str) _Xruntime_error - @ cdecl -arch=win64 ?_Xruntime_error@std@@YAXPEBD@Z(str) _Xruntime_error --@ cdecl -arch=win32 ?__ExceptionPtrAssign@@YAXPAXPBX@Z(ptr ptr) msvcr120.?__ExceptionPtrAssign@@YAXPAXPBX@Z --@ cdecl -arch=win64 ?__ExceptionPtrAssign@@YAXPEAXPEBX@Z(ptr ptr) msvcr120.?__ExceptionPtrAssign@@YAXPEAXPEBX@Z --@ cdecl -arch=win32 ?__ExceptionPtrCompare@@YA_NPBX0@Z(ptr ptr) msvcr120.?__ExceptionPtrCompare@@YA_NPBX0@Z --@ cdecl -arch=win64 ?__ExceptionPtrCompare@@YA_NPEBX0@Z(ptr ptr) msvcr120.?__ExceptionPtrCompare@@YA_NPEBX0@Z --@ cdecl -arch=win32 ?__ExceptionPtrCopy@@YAXPAXPBX@Z(ptr ptr) msvcr120.?__ExceptionPtrCopy@@YAXPAXPBX@Z --@ cdecl -arch=win64 ?__ExceptionPtrCopy@@YAXPEAXPEBX@Z(ptr ptr) msvcr120.?__ExceptionPtrCopy@@YAXPEAXPEBX@Z --@ cdecl -arch=win32 ?__ExceptionPtrCopyException@@YAXPAXPBX1@Z(ptr ptr ptr) msvcr120.?__ExceptionPtrCopyException@@YAXPAXPBX1@Z --@ cdecl -arch=win64 ?__ExceptionPtrCopyException@@YAXPEAXPEBX1@Z(ptr ptr ptr) msvcr120.?__ExceptionPtrCopyException@@YAXPEAXPEBX1@Z -+@ cdecl -arch=win32 ?__ExceptionPtrAssign@@YAXPAXPBX@Z(ptr ptr) __ExceptionPtrAssign -+@ cdecl -arch=win64 ?__ExceptionPtrAssign@@YAXPEAXPEBX@Z(ptr ptr) __ExceptionPtrAssign -+@ cdecl -arch=win32 ?__ExceptionPtrCompare@@YA_NPBX0@Z(ptr ptr) __ExceptionPtrCompare -+@ cdecl -arch=win64 ?__ExceptionPtrCompare@@YA_NPEBX0@Z(ptr ptr) __ExceptionPtrCompare -+@ cdecl -arch=win32 ?__ExceptionPtrCopy@@YAXPAXPBX@Z(ptr ptr) __ExceptionPtrCopy -+@ cdecl -arch=win64 ?__ExceptionPtrCopy@@YAXPEAXPEBX@Z(ptr ptr) __ExceptionPtrCopy -+@ cdecl -arch=win32 ?__ExceptionPtrCopyException@@YAXPAXPBX1@Z(ptr ptr ptr) __ExceptionPtrCopyException -+@ cdecl -arch=win64 ?__ExceptionPtrCopyException@@YAXPEAXPEBX1@Z(ptr ptr ptr) __ExceptionPtrCopyException - @ cdecl -arch=win32 ?__ExceptionPtrCreate@@YAXPAX@Z(ptr) __ExceptionPtrCreate - @ cdecl -arch=win64 ?__ExceptionPtrCreate@@YAXPEAX@Z(ptr) __ExceptionPtrCreate --@ cdecl -arch=win32 ?__ExceptionPtrCurrentException@@YAXPAX@Z(ptr) msvcr120.?__ExceptionPtrCurrentException@@YAXPAX@Z --@ cdecl -arch=win64 ?__ExceptionPtrCurrentException@@YAXPEAX@Z(ptr) msvcr120.?__ExceptionPtrCurrentException@@YAXPEAX@Z -+@ cdecl -arch=win32 ?__ExceptionPtrCurrentException@@YAXPAX@Z(ptr) __ExceptionPtrCurrentException -+@ cdecl -arch=win64 ?__ExceptionPtrCurrentException@@YAXPEAX@Z(ptr) __ExceptionPtrCurrentException - @ cdecl -arch=win32 ?__ExceptionPtrDestroy@@YAXPAX@Z(ptr) __ExceptionPtrDestroy - @ cdecl -arch=win64 ?__ExceptionPtrDestroy@@YAXPEAX@Z(ptr) __ExceptionPtrDestroy --@ cdecl -arch=win32 ?__ExceptionPtrRethrow@@YAXPBX@Z(ptr) msvcr120.?__ExceptionPtrRethrow@@YAXPBX@Z --@ cdecl -arch=win64 ?__ExceptionPtrRethrow@@YAXPEBX@Z(ptr) msvcr120.?__ExceptionPtrRethrow@@YAXPEBX@Z -+@ cdecl -arch=win32 ?__ExceptionPtrRethrow@@YAXPBX@Z(ptr) __ExceptionPtrRethrow -+@ cdecl -arch=win64 ?__ExceptionPtrRethrow@@YAXPEBX@Z(ptr) __ExceptionPtrRethrow - @ stub -arch=win32 ?__ExceptionPtrSwap@@YAXPAX0@Z - @ stub -arch=win64 ?__ExceptionPtrSwap@@YAXPEAX0@Z --@ cdecl -arch=win32 ?__ExceptionPtrToBool@@YA_NPBX@Z(ptr) msvcr120.?__ExceptionPtrToBool@@YA_NPBX@Z --@ cdecl -arch=win64 ?__ExceptionPtrToBool@@YA_NPEBX@Z(ptr) msvcr120.?__ExceptionPtrToBool@@YA_NPEBX@Z -+@ cdecl -arch=win32 ?__ExceptionPtrToBool@@YA_NPBX@Z(ptr) __ExceptionPtrToBool -+@ cdecl -arch=win64 ?__ExceptionPtrToBool@@YA_NPEBX@Z(ptr) __ExceptionPtrToBool - @ cdecl -arch=arm ?always_noconv@codecvt_base@std@@QBA_NXZ(ptr) codecvt_base_always_noconv - @ thiscall -arch=i386 ?always_noconv@codecvt_base@std@@QBE_NXZ(ptr) codecvt_base_always_noconv - @ cdecl -arch=win64 ?always_noconv@codecvt_base@std@@QEBA_NXZ(ptr) codecvt_base_always_noconv -diff --git a/dlls/msvcp90/exception.c b/dlls/msvcp90/exception.c -index e5b6018fe31..f128d4478eb 100644 ---- a/dlls/msvcp90/exception.c -+++ b/dlls/msvcp90/exception.c -@@ -26,6 +26,8 @@ - - WINE_DEFAULT_DEBUG_CHANNEL(msvcp); - -+#define CXX_FRAME_MAGIC_VC6 0x19930520 -+ - CREATE_TYPE_INFO_VTABLE - - #define CLASS_IS_SIMPLE_TYPE 1 -@@ -946,6 +948,55 @@ bool __cdecl MSVCP__uncaught_exception(void) - } - - #if _MSVCP_VER >= 140 -+void** CDECL __current_exception(void); -+ -+/* compute the this pointer for a base class of a given type */ -+static inline void *get_this_pointer( const this_ptr_offsets *off, void *object ) -+{ -+ if (!object) return NULL; -+ -+ if (off->vbase_descr >= 0) -+ { -+ int *offset_ptr; -+ -+ /* move this ptr to vbase descriptor */ -+ object = (char *)object + off->vbase_descr; -+ /* and fetch additional offset from vbase descriptor */ -+ offset_ptr = (int *)(*(char **)object + off->vbase_offset); -+ object = (char *)object + *offset_ptr; -+ } -+ -+ object = (char *)object + off->this_offset; -+ return object; -+} -+ -+#ifdef __i386__ -+extern void call_copy_ctor( void *func, void *this, void *src, int has_vbase ); -+__ASM_GLOBAL_FUNC( call_copy_ctor, -+ "pushl %ebp\n\t" -+ __ASM_CFI(".cfi_adjust_cfa_offset 4\n\t") -+ __ASM_CFI(".cfi_rel_offset %ebp,0\n\t") -+ "movl %esp, %ebp\n\t" -+ __ASM_CFI(".cfi_def_cfa_register %ebp\n\t") -+ "pushl $1\n\t" -+ "movl 12(%ebp), %ecx\n\t" -+ "pushl 16(%ebp)\n\t" -+ "call *8(%ebp)\n\t" -+ "leave\n" -+ __ASM_CFI(".cfi_def_cfa %esp,4\n\t") -+ __ASM_CFI(".cfi_same_value %ebp\n\t") -+ "ret" ); -+#else -+static inline void call_copy_ctor( void *func, void *this, void *src, int has_vbase ) -+{ -+ TRACE( "calling copy ctor %p object %p src %p\n", func, this, src ); -+ if (has_vbase) -+ ((void (__cdecl*)(void*, void*, BOOL))func)(this, src, 1); -+ else -+ ((void (__cdecl*)(void*, void*))func)(this, src); -+} -+#endif -+ - int __cdecl __uncaught_exceptions(void) - { - return *__processing_throw(); -@@ -1013,6 +1064,259 @@ void __cdecl __ExceptionPtrDestroy(exception_ptr *ep) - HeapFree(GetProcessHeap(), 0, ep->ref); - } - } -+ -+/********************************************************************* -+ * ?__ExceptionPtrCopy@@YAXPAXPBX@Z -+ * ?__ExceptionPtrCopy@@YAXPEAXPEBX@Z -+ */ -+void __cdecl __ExceptionPtrCopy(exception_ptr *ep, const exception_ptr *copy) -+{ -+ TRACE("(%p %p)\n", ep, copy); -+ -+ /* don't destroy object stored in ep */ -+ *ep = *copy; -+ if (ep->ref) -+ InterlockedIncrement(copy->ref); -+} -+ -+/********************************************************************* -+ * ?__ExceptionPtrAssign@@YAXPAXPBX@Z -+ * ?__ExceptionPtrAssign@@YAXPEAXPEBX@Z -+ */ -+void __cdecl __ExceptionPtrAssign(exception_ptr *ep, const exception_ptr *assign) -+{ -+ TRACE("(%p %p)\n", ep, assign); -+ -+ /* don't destroy object stored in ep */ -+ if (ep->ref) -+ InterlockedDecrement(ep->ref); -+ -+ *ep = *assign; -+ if (ep->ref) -+ InterlockedIncrement(ep->ref); -+} -+ -+/********************************************************************* -+ * ?__ExceptionPtrRethrow@@YAXPBX@Z -+ * ?__ExceptionPtrRethrow@@YAXPEBX@Z -+ */ -+void __cdecl __ExceptionPtrRethrow(const exception_ptr *ep) -+{ -+ TRACE("(%p)\n", ep); -+ -+ if (!ep->rec) -+ { -+ static const char *exception_msg = "bad exception"; -+ exception e; -+ -+ MSVCP_exception_ctor(&e, &exception_msg); -+ _CxxThrowException(&e, &exception_cxx_type); -+ return; -+ } -+ -+ RaiseException(ep->rec->ExceptionCode, ep->rec->ExceptionFlags & (~EH_UNWINDING), -+ ep->rec->NumberParameters, ep->rec->ExceptionInformation); -+} -+ -+/********************************************************************* -+ * ?__ExceptionPtrCurrentException@@YAXPAX@Z -+ * ?__ExceptionPtrCurrentException@@YAXPEAX@Z -+ */ -+#ifndef __x86_64__ -+void __cdecl __ExceptionPtrCurrentException(exception_ptr *ep) -+{ -+ void **current_exception = __current_exception(); -+ EXCEPTION_RECORD *rec = current_exception ? *current_exception : NULL; -+ -+ TRACE("(%p)\n", ep); -+ -+ if (!rec) -+ { -+ ep->rec = NULL; -+ ep->ref = NULL; -+ return; -+ } -+ -+ ep->rec = HeapAlloc(GetProcessHeap(), 0, sizeof(EXCEPTION_RECORD)); -+ ep->ref = HeapAlloc(GetProcessHeap(), 0, sizeof(int)); -+ -+ *ep->rec = *rec; -+ *ep->ref = 1; -+ -+ if (ep->rec->ExceptionCode == CXX_EXCEPTION) -+ { -+ const cxx_exception_type *et = (void*)ep->rec->ExceptionInformation[2]; -+ const cxx_type_info *ti; -+ void **data, *obj; -+ -+ ti = et->type_info_table->info[0]; -+ data = HeapAlloc(GetProcessHeap(), 0, ti->size); -+ -+ obj = (void*)ep->rec->ExceptionInformation[1]; -+ if (ti->flags & CLASS_IS_SIMPLE_TYPE) -+ { -+ memcpy(data, obj, ti->size); -+ if (ti->size == sizeof(void *)) *data = get_this_pointer(&ti->offsets, *data); -+ } -+ else if (ti->copy_ctor) -+ { -+ call_copy_ctor(ti->copy_ctor, data, get_this_pointer(&ti->offsets, obj), -+ ti->flags & CLASS_HAS_VIRTUAL_BASE_CLASS); -+ } -+ else -+ memcpy(data, get_this_pointer(&ti->offsets, obj), ti->size); -+ ep->rec->ExceptionInformation[1] = (ULONG_PTR)data; -+ } -+ return; -+} -+#else -+void __cdecl __ExceptionPtrCurrentException(exception_ptr *ep) -+{ -+ void **current_exception = __current_exception(); -+ EXCEPTION_RECORD *rec = current_exception ? *current_exception : NULL; -+ -+ TRACE("(%p)\n", ep); -+ -+ if (!rec) -+ { -+ ep->rec = NULL; -+ ep->ref = NULL; -+ return; -+ } -+ -+ ep->rec = HeapAlloc(GetProcessHeap(), 0, sizeof(EXCEPTION_RECORD)); -+ ep->ref = HeapAlloc(GetProcessHeap(), 0, sizeof(int)); -+ -+ *ep->rec = *rec; -+ *ep->ref = 1; -+ -+ if (ep->rec->ExceptionCode == CXX_EXCEPTION) -+ { -+ const cxx_exception_type *et = (void*)ep->rec->ExceptionInformation[2]; -+ const cxx_type_info *ti; -+ void **data, *obj; -+ char *base = RtlPcToFileHeader((void*)et, (void**)&base); -+ -+ ti = (const cxx_type_info*)(base + ((const cxx_type_info_table*)(base + et->type_info_table))->info[0]); -+ data = HeapAlloc(GetProcessHeap(), 0, ti->size); -+ -+ obj = (void*)ep->rec->ExceptionInformation[1]; -+ if (ti->flags & CLASS_IS_SIMPLE_TYPE) -+ { -+ memcpy(data, obj, ti->size); -+ if (ti->size == sizeof(void *)) *data = get_this_pointer(&ti->offsets, *data); -+ } -+ else if (ti->copy_ctor) -+ { -+ call_copy_ctor(base + ti->copy_ctor, data, get_this_pointer(&ti->offsets, obj), -+ ti->flags & CLASS_HAS_VIRTUAL_BASE_CLASS); -+ } -+ else -+ memcpy(data, get_this_pointer(&ti->offsets, obj), ti->size); -+ ep->rec->ExceptionInformation[1] = (ULONG_PTR)data; -+ } -+ return; -+} -+#endif -+ -+/********************************************************************* -+ * ?__ExceptionPtrToBool@@YA_NPBX@Z -+ * ?__ExceptionPtrToBool@@YA_NPEBX@Z -+ */ -+bool __cdecl __ExceptionPtrToBool(exception_ptr *ep) -+{ -+ return !!ep->rec; -+} -+ -+/********************************************************************* -+ * ?__ExceptionPtrCopyException@@YAXPAXPBX1@Z -+ * ?__ExceptionPtrCopyException@@YAXPEAXPEBX1@Z -+ */ -+#ifndef __x86_64__ -+void __cdecl __ExceptionPtrCopyException(exception_ptr *ep, -+ exception *object, const cxx_exception_type *type) -+{ -+ const cxx_type_info *ti; -+ void **data; -+ -+ __ExceptionPtrDestroy(ep); -+ -+ ep->rec = HeapAlloc(GetProcessHeap(), 0, sizeof(EXCEPTION_RECORD)); -+ ep->ref = HeapAlloc(GetProcessHeap(), 0, sizeof(int)); -+ *ep->ref = 1; -+ -+ memset(ep->rec, 0, sizeof(EXCEPTION_RECORD)); -+ ep->rec->ExceptionCode = CXX_EXCEPTION; -+ ep->rec->ExceptionFlags = EH_NONCONTINUABLE; -+ ep->rec->NumberParameters = 3; -+ ep->rec->ExceptionInformation[0] = CXX_FRAME_MAGIC_VC6; -+ ep->rec->ExceptionInformation[2] = (ULONG_PTR)type; -+ -+ ti = type->type_info_table->info[0]; -+ data = HeapAlloc(GetProcessHeap(), 0, ti->size); -+ if (ti->flags & CLASS_IS_SIMPLE_TYPE) -+ { -+ memcpy(data, object, ti->size); -+ if (ti->size == sizeof(void *)) *data = get_this_pointer(&ti->offsets, *data); -+ } -+ else if (ti->copy_ctor) -+ { -+ call_copy_ctor(ti->copy_ctor, data, get_this_pointer(&ti->offsets, object), -+ ti->flags & CLASS_HAS_VIRTUAL_BASE_CLASS); -+ } -+ else -+ memcpy(data, get_this_pointer(&ti->offsets, object), ti->size); -+ ep->rec->ExceptionInformation[1] = (ULONG_PTR)data; -+} -+#else -+void __cdecl __ExceptionPtrCopyException(exception_ptr *ep, -+ exception *object, const cxx_exception_type *type) -+{ -+ const cxx_type_info *ti; -+ void **data; -+ char *base; -+ -+ RtlPcToFileHeader((void*)type, (void**)&base); -+ __ExceptionPtrDestroy(ep); -+ -+ ep->rec = HeapAlloc(GetProcessHeap(), 0, sizeof(EXCEPTION_RECORD)); -+ ep->ref = HeapAlloc(GetProcessHeap(), 0, sizeof(int)); -+ *ep->ref = 1; -+ -+ memset(ep->rec, 0, sizeof(EXCEPTION_RECORD)); -+ ep->rec->ExceptionCode = CXX_EXCEPTION; -+ ep->rec->ExceptionFlags = EH_NONCONTINUABLE; -+ ep->rec->NumberParameters = 4; -+ ep->rec->ExceptionInformation[0] = CXX_FRAME_MAGIC_VC6; -+ ep->rec->ExceptionInformation[2] = (ULONG_PTR)type; -+ ep->rec->ExceptionInformation[3] = (ULONG_PTR)base; -+ -+ ti = (const cxx_type_info*)(base + ((const cxx_type_info_table*)(base + type->type_info_table))->info[0]); -+ data = HeapAlloc(GetProcessHeap(), 0, ti->size); -+ if (ti->flags & CLASS_IS_SIMPLE_TYPE) -+ { -+ memcpy(data, object, ti->size); -+ if (ti->size == sizeof(void *)) *data = get_this_pointer(&ti->offsets, *data); -+ } -+ else if (ti->copy_ctor) -+ { -+ call_copy_ctor(base + ti->copy_ctor, data, get_this_pointer(&ti->offsets, object), -+ ti->flags & CLASS_HAS_VIRTUAL_BASE_CLASS); -+ } -+ else -+ memcpy(data, get_this_pointer(&ti->offsets, object), ti->size); -+ ep->rec->ExceptionInformation[1] = (ULONG_PTR)data; -+} -+#endif -+ -+/********************************************************************* -+ * ?__ExceptionPtrCompare@@YA_NPBX0@Z -+ * ?__ExceptionPtrCompare@@YA_NPEBX0@Z -+ */ -+bool __cdecl __ExceptionPtrCompare(const exception_ptr *ep1, const exception_ptr *ep2) -+{ -+ return ep1->rec == ep2->rec; -+} - #endif - - #if _MSVCP_VER >= 70 || defined(_MSVCIRT) diff --git a/src/wine/winemenubuilder.patch b/src/wine/winemenubuilder.patch deleted file mode 100644 index 97d2b78..0000000 --- a/src/wine/winemenubuilder.patch +++ /dev/null @@ -1,49 +0,0 @@ -diff --git a/dlls/shell32/shelllink.c b/dlls/shell32/shelllink.c -index 656357bf0a9..1e8c8de7920 100644 ---- a/dlls/shell32/shelllink.c -+++ b/dlls/shell32/shelllink.c -@@ -299,43 +299,7 @@ static HRESULT WINAPI IPersistFile_fnLoad(IPersistFile* iface, LPCOLESTR pszFile - - BOOL run_winemenubuilder( const WCHAR *args ) - { -- LONG len; -- LPWSTR buffer; -- STARTUPINFOW si; -- PROCESS_INFORMATION pi; -- BOOL ret; -- WCHAR app[MAX_PATH]; -- void *redir; -- -- GetSystemDirectoryW( app, MAX_PATH ); -- lstrcatW( app, L"\\winemenubuilder.exe" ); -- -- len = (lstrlenW( app ) + lstrlenW( args ) + 1) * sizeof(WCHAR); -- buffer = heap_alloc( len ); -- if( !buffer ) -- return FALSE; -- -- lstrcpyW( buffer, app ); -- lstrcatW( buffer, args ); -- -- TRACE("starting %s\n",debugstr_w(buffer)); -- -- memset(&si, 0, sizeof(si)); -- si.cb = sizeof(si); -- -- Wow64DisableWow64FsRedirection( &redir ); -- ret = CreateProcessW( app, buffer, NULL, NULL, FALSE, DETACHED_PROCESS, NULL, NULL, &si, &pi ); -- Wow64RevertWow64FsRedirection( redir ); -- -- heap_free( buffer ); -- -- if (ret) -- { -- CloseHandle( pi.hProcess ); -- CloseHandle( pi.hThread ); -- } -- -- return ret; -+ return TRUE; - } - - static BOOL StartLinkProcessor( LPCOLESTR szLink ) diff --git a/src/wine/ws2siobacklogquery.patch b/src/wine/ws2siobacklogquery.patch deleted file mode 100644 index 02878ae..0000000 --- a/src/wine/ws2siobacklogquery.patch +++ /dev/null @@ -1,22 +0,0 @@ -diff --git a/dlls/ws2_32/socket.c b/dlls/ws2_32/socket.c -index fe7e4fb3464..ef1449a4300 100644 ---- a/dlls/ws2_32/socket.c -+++ b/dlls/ws2_32/socket.c -@@ -1947,7 +1947,7 @@ static DWORD server_ioctl_sock( SOCKET s, DWORD code, LPVOID in_buff, DWORD in_s - return -1; - status = piosb->u.Status; - } -- if (status == STATUS_NOT_SUPPORTED) -+ if (status == STATUS_NOT_SUPPORTED && ((code >> 2) & 0xfff) != 0xd2) - { - FIXME("Unsupported ioctl %x (device=%x access=%x func=%x method=%x)\n", - code, code >> 16, (code >> 14) & 3, (code >> 2) & 0xfff, code & 3); -@@ -2270,6 +2270,8 @@ INT WINAPI WSAIoctl(SOCKET s, DWORD code, LPVOID in_buff, DWORD in_size, LPVOID - default: - FIXME( "unimplemented ioctl %s\n", debugstr_wsaioctl( code ) ); - /* fall through */ -+ case SIO_IDEAL_SEND_BACKLOG_QUERY: -+ /* fall through */ - case LOWORD(FIONBIO): /* Netscape tries to use this */ - case SIO_SET_COMPATIBILITY_MODE: - {