Skip to content

Commit

Permalink
Merge branch 'bleeding-edge' into y5-cutscenes-fix
Browse files Browse the repository at this point in the history
  • Loading branch information
NishiyamaPedro authored Jan 22, 2024
2 parents 9e95935 + acbb48e commit 6204e7b
Show file tree
Hide file tree
Showing 695 changed files with 106,424 additions and 31,532 deletions.
7 changes: 6 additions & 1 deletion MAINTAINERS
Original file line number Diff line number Diff line change
Expand Up @@ -181,8 +181,12 @@ F: dlls/win32u/rawinput.c
F: server/queue.c

Input methods
M: Aric Stewart <[email protected]>
M: Rémi Bernon <[email protected]>
P: Aric Stewart <[email protected]>
F: dlls/imm32/
F: dlls/win32u/imm.c
F: dlls/winemac.drv/ime.c
F: dlls/winex11.drv/ime.c

JavaScript
M: Jacek Caban <[email protected]>
Expand Down Expand Up @@ -214,6 +218,7 @@ F: dlls/winegstreamer/h264_decoder.c
F: dlls/winegstreamer/resampler.c
F: dlls/winegstreamer/video_decoder.c
F: dlls/winegstreamer/video_processor.c
F: dlls/winegstreamer/wg_source.c
F: dlls/winegstreamer/wg_sample.c
F: dlls/winegstreamer/wg_transform.c
F: dlls/winegstreamer/wma_decoder.c
Expand Down
40 changes: 32 additions & 8 deletions configure.ac
Original file line number Diff line number Diff line change
Expand Up @@ -60,6 +60,7 @@ AC_ARG_WITH(udev, AS_HELP_STRING([--without-udev],[do not use udev (plug an
AC_ARG_WITH(unwind, AS_HELP_STRING([--without-unwind],[do not use the libunwind library (exception handling)]))
AC_ARG_WITH(usb, AS_HELP_STRING([--without-usb],[do not use the libusb library]))
AC_ARG_WITH(v4l2, AS_HELP_STRING([--without-v4l2],[do not use v4l2 (video capture)]))
AC_ARG_WITH(vosk, AS_HELP_STRING([--without-vosk],[do not use Vosk]))
AC_ARG_WITH(vulkan, AS_HELP_STRING([--without-vulkan],[do not use Vulkan]))
AC_ARG_WITH(xcomposite,AS_HELP_STRING([--without-xcomposite],[do not use the Xcomposite extension]),
[if test "x$withval" = "xno"; then ac_cv_header_X11_extensions_Xcomposite_h=no; fi])
Expand Down Expand Up @@ -488,7 +489,8 @@ AC_CHECK_HEADERS(\
syscall.h \
utime.h \
valgrind/memcheck.h \
valgrind/valgrind.h
valgrind/valgrind.h \
vosk_api.h
)
WINE_HEADER_MAJOR()
AC_HEADER_STAT()
Expand Down Expand Up @@ -1027,6 +1029,15 @@ then
WINE_NOTICE([FAudio ${notice_platform}MinGW development files not found (or too old); using bundled version.])
fi

WINE_MINGW_PACKAGE_FLAGS(FLUIDSYNTH,[fluidsynth],[-lfluidsynth],
[WINE_CHECK_MINGW_HEADER(fluidsynth.h,
[WINE_CHECK_MINGW_LIB(fluidsynth,new_fluid_synth,[:],[FLUIDSYNTH_PE_CFLAGS=""; FLUIDSYNTH_PE_LIBS=""],[$FLUIDSYNTH_PE_LIBS])],
[FLUIDSYNTH_PE_CFLAGS=""; FLUIDSYNTH_PE_LIBS=""])])
if test "x$FLUIDSYNTH_PE_LIBS" = "x"
then
WINE_NOTICE([Fluidsynth ${notice_platform}MinGW development files not found (or too old); using bundled version.])
fi

WINE_MINGW_PACKAGE_FLAGS(JPEG,[libjpeg],,
[WINE_CHECK_MINGW_HEADER(jpeglib.h,
[WINE_CHECK_MINGW_LIB(jpeg,jpeg_start_decompress,[:],[JPEG_PE_CFLAGS=""; JPEG_PE_LIBS=""],[$JPEG_PE_LIBS])],
Expand Down Expand Up @@ -1137,6 +1148,7 @@ then
fi

WINE_EXTLIB_FLAGS(FAUDIO, faudio, "faudio mfplat mfreadwrite mfuuid propsys", "-I\$(top_srcdir)/libs/faudio/include")
WINE_EXTLIB_FLAGS(FLUIDSYNTH, fluidsynth, "fluidsynth", "-I\$(top_srcdir)/libs/fluidsynth/include")
WINE_EXTLIB_FLAGS(GSM, gsm, gsm, "-I\$(top_srcdir)/libs/gsm/inc")
WINE_EXTLIB_FLAGS(JPEG, jpeg, jpeg, "-I\$(top_srcdir)/libs/jpeg")
WINE_EXTLIB_FLAGS(JXR, jxr, jxr, "-I\$(top_srcdir)/libs/jxr/jxrgluelib -I\$(top_srcdir)/libs/jxr/image/sys")
Expand Down Expand Up @@ -1196,13 +1208,6 @@ then
# include <X11/Xutil.h>
#endif])

dnl *** Check for X keyboard extension
if test "$ac_cv_header_X11_XKBlib_h" = "yes"
then
AC_CHECK_LIB(X11, XkbQueryExtension,
AC_DEFINE(HAVE_XKB, 1, [Define if you have the XKB extension]),,[$X_LIBS $X_EXTRA_LIBS])
fi

dnl *** Check for X cursor
if test "$ac_cv_header_X11_Xcursor_Xcursor_h" = "yes"
then
Expand Down Expand Up @@ -1429,6 +1434,15 @@ then
[WINE_CHECK_SONAME(gmp,__gmpz_init,,[GMP_CFLAGS=""],[$GMP_LIBS],[[libgmp-*]])])])
fi

dnl **** Check for libdrm ****
WINE_PACKAGE_FLAGS(DRM,[libdrm],,,,
[AC_CHECK_HEADERS([xf86drm.h],
[WINE_CHECK_SONAME(drm,drmOpen,,,[$DRM_LIBS])])])

WINE_PACKAGE_FLAGS(DRMAMDGPU,[libdrm_amdgpu],,,,
[AC_CHECK_HEADERS([amdgpu_drm.h],
[WINE_CHECK_SONAME(drm_amdgpu,amdgpu_query_info,,,[$DRMAMDGPU_LIBS])])])

dnl **** Check for SANE ****
if test "x$with_sane" != "xno"
then
Expand Down Expand Up @@ -1800,6 +1814,14 @@ then
WINE_WARNING([No sound system was found. Windows applications will be silent.])
fi

dnl **** Check for Vosk ****
if test x$with_vosk != xno
then
WINE_CHECK_SONAME(vosk,vosk_recognizer_new)
fi
WINE_NOTICE_WITH(vosk,[test x$ac_cv_lib_soname_vosk = x],
[libvosk ${notice_platform}development files not found, speech recognition won't be supported.])

dnl *** Check for Vulkan ***
if test "x$with_vulkan" != "xno"
then
Expand Down Expand Up @@ -2429,6 +2451,7 @@ WINE_CONFIG_MAKEFILE(dlls/avifile.dll16,enable_win16)
WINE_CONFIG_MAKEFILE(dlls/avrt)
WINE_CONFIG_MAKEFILE(dlls/bcrypt)
WINE_CONFIG_MAKEFILE(dlls/bcrypt/tests)
WINE_CONFIG_MAKEFILE(dlls/bcryptprimitives)
WINE_CONFIG_MAKEFILE(dlls/bluetoothapis)
WINE_CONFIG_MAKEFILE(dlls/browseui)
WINE_CONFIG_MAKEFILE(dlls/browseui/tests)
Expand Down Expand Up @@ -3324,6 +3347,7 @@ WINE_CONFIG_MAKEFILE(libs/dxerr8)
WINE_CONFIG_MAKEFILE(libs/dxerr9)
WINE_CONFIG_MAKEFILE(libs/dxguid)
WINE_CONFIG_MAKEFILE(libs/faudio)
WINE_CONFIG_MAKEFILE(libs/fluidsynth)
WINE_CONFIG_MAKEFILE(libs/gsm)
WINE_CONFIG_MAKEFILE(libs/jpeg)
WINE_CONFIG_MAKEFILE(libs/jxr)
Expand Down
2 changes: 1 addition & 1 deletion dlls/advapi32/crypt.c
Original file line number Diff line number Diff line change
Expand Up @@ -2400,7 +2400,7 @@ static CRITICAL_SECTION_DEBUG random_debug =
};
static CRITICAL_SECTION random_cs = { &random_debug, -1, 0, 0, 0, 0 };

#define MAX_CPUS 128
#define MAX_CPUS 256
static char random_buf[sizeof(SYSTEM_INTERRUPT_INFORMATION) * MAX_CPUS];
static ULONG random_len;
static ULONG random_pos;
Expand Down
65 changes: 65 additions & 0 deletions dlls/advapi32/tests/security.c
Original file line number Diff line number Diff line change
Expand Up @@ -786,6 +786,9 @@ static void test_lookupPrivilegeValue(void)
}
}

static TOKEN_OWNER *get_alloc_token_owner( HANDLE token );
static TOKEN_PRIMARY_GROUP *get_alloc_token_primary_group( HANDLE token );

static void test_FileSecurity(void)
{
char wintmpdir [MAX_PATH];
Expand All @@ -800,6 +803,16 @@ static void test_FileSecurity(void)
const SECURITY_INFORMATION request = OWNER_SECURITY_INFORMATION
| GROUP_SECURITY_INFORMATION
| DACL_SECURITY_INFORMATION;
TOKEN_OWNER *owner;
PSID owner_sid;
BOOL defaulted, present;
TOKEN_PRIMARY_GROUP *group;
SECURITY_ATTRIBUTES sa;
PACL dacl;
ACL_SIZE_INFORMATION acl_size;
ACCESS_ALLOWED_ACE *ace;
static SID owner_rights_sid = { SID_REVISION, 1, { SECURITY_CREATOR_SID_AUTHORITY }, { SECURITY_CREATOR_OWNER_RIGHTS_RID } };
const WCHAR sd_onwer_rights_str[] = L"D:(A;;FA;;;S-1-3-4)";

if (!pSetFileSecurityA) {
win_skip ("SetFileSecurity is not available\n");
Expand Down Expand Up @@ -902,6 +915,58 @@ static void test_FileSecurity(void)
ok (GetLastError() == ERROR_FILE_NOT_FOUND,
"last error ERROR_FILE_NOT_FOUND expected, got %ld\n", GetLastError());

sa.nLength = sizeof(sa);
sa.bInheritHandle = FALSE;
rc = ConvertStringSecurityDescriptorToSecurityDescriptorW(sd_onwer_rights_str, SDDL_REVISION_1, &sa.lpSecurityDescriptor, NULL);
ok(rc, "got error %lu.\n", GetLastError());

DeleteFileA(file);
fh = CreateFileA(file, GENERIC_READ, 0, &sa, CREATE_ALWAYS, 0, NULL);
ok (fh != INVALID_HANDLE_VALUE, "error %lu\n", GetLastError());
LocalFree(sa.lpSecurityDescriptor);

rc = GetFileSecurityA (file, OWNER_SECURITY_INFORMATION, NULL, 0, &retSize);
ok (!rc && GetLastError() == ERROR_INSUFFICIENT_BUFFER, "got %ld, error %lu.\n", rc, GetLastError());
sd = HeapAlloc (GetProcessHeap (), 0, sdSize);
rc = GetFileSecurityA (file, OWNER_SECURITY_INFORMATION, sd, retSize, &retSize);
ok(rc, "got error %lu.\n", GetLastError());
rc = GetSecurityDescriptorOwner(sd, &owner_sid, &defaulted);
ok(rc, "got error %lu.\n", GetLastError());
ok(!defaulted, "got %d.\n", defaulted);
owner = get_alloc_token_owner(GetCurrentProcessToken());
todo_wine ok(EqualSid(owner_sid, owner->Owner), "Owner SIDs are not equal %s != %s\n", debugstr_sid(owner_sid), debugstr_sid(owner->Owner));
HeapFree (GetProcessHeap (), 0, owner);
HeapFree (GetProcessHeap (), 0, sd);

group = get_alloc_token_primary_group(GetCurrentProcessToken());
test_group_equal(fh, group->PrimaryGroup, __LINE__);
HeapFree (GetProcessHeap (), 0, group);

CloseHandle(fh);

fh = CreateFileA(file, GENERIC_READ, 0, NULL, OPEN_EXISTING, 0, NULL);
ok (fh != INVALID_HANDLE_VALUE, "error %lu\n", GetLastError());
if (fh != INVALID_HANDLE_VALUE)
{
rc = GetFileSecurityA (file, DACL_SECURITY_INFORMATION, NULL, 0, &retSize);
ok (!rc && GetLastError() == ERROR_INSUFFICIENT_BUFFER, "got %ld, error %lu.\n", rc, GetLastError());
sd = HeapAlloc (GetProcessHeap (), 0, sdSize);
rc = GetFileSecurityA (file, DACL_SECURITY_INFORMATION, sd, retSize, &retSize);
ok(rc, "got error %lu.\n", GetLastError());
rc = GetSecurityDescriptorDacl(sd, &present, &dacl, &defaulted);
ok(rc, "got error %lu.\n", GetLastError());
ok(present, "got %d.\n", present);
ok(!defaulted, "got %d.\n", defaulted);
rc = GetAclInformation(dacl, &acl_size, sizeof(acl_size), AclSizeInformation);
ok(rc, "got error %lu.\n", GetLastError());
ok(acl_size.AceCount == 1, "got %lu.\n", acl_size.AceCount);
rc = GetAce(dacl, 0, (VOID **)&ace);
ok(rc, "got error %lu.\n", GetLastError());
ok(EqualSid(&ace->SidStart, &owner_rights_sid), "Owner SIDs are not equal %s != %s\n", debugstr_sid(&ace->SidStart), debugstr_sid(&owner_rights_sid));
CloseHandle(fh);
HeapFree (GetProcessHeap (), 0, sd);
}

cleanup:
/* Remove temporary file and directory */
DeleteFileA(file);
Expand Down
6 changes: 5 additions & 1 deletion dlls/amd_ags_x64/Makefile.in
Original file line number Diff line number Diff line change
@@ -1,12 +1,16 @@
EXTRADEFS = -DWINE_NO_LONG_TYPES
MODULE = amd_ags_x64.dll
UNIXLIB = amd_ags_x64.so
UNIX_CFLAGS = $(DRM_CFLAGS)
UNIX_LIBS = $(DRM_LIBS) $(DRMAMDGPU_LIBS)
IMPORTS = version vulkan-1 user32
IMPORTLIB = amd_ags_x64

EXTRADLLFLAGS = -mno-cygwin -Wb,--prefer-native

C_SRCS = \
amd_ags_x64_main.c
amd_ags_x64_main.c \
unixlib.c

IDL_SRCS = \
dxvk_interfaces.idl
14 changes: 8 additions & 6 deletions dlls/amd_ags_x64/amd_ags.h
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,8 @@ typedef enum AGSReturnCode
AGS_NO_AMD_DRIVER_INSTALLED, ///< Returned if the AMD GPU driver does not appear to be installed
AGS_EXTENSION_NOT_SUPPORTED, ///< Returned if the driver does not support the requested driver extension
AGS_ADL_FAILURE, ///< Failure in ADL (the AMD Display Library)
AGS_DX_FAILURE ///< Failure from DirectX runtime
AGS_DX_FAILURE, ///< Failure from DirectX runtime
AGS_D3DDEVICE_NOT_CREATED, ///< Failure due to not creating the D3D device successfully via AGS.
} AGSReturnCode;

/// The DirectX11 extension support bits
Expand Down Expand Up @@ -268,7 +269,7 @@ typedef enum AGSDriverExtensionDX12
} AGSDriverExtensionDX12;

/// The space id for DirectX12 intrinsic support
const unsigned int AGS_DX12_SHADER_INSTRINSICS_SPACE_ID = 0x7FFF0ADE; // 2147420894
const unsigned int AGS_DX12_SHADER_INTRINSICS_SPACE_ID = 0x7FFF0ADE; // 2147420894

/// The display flags describing various properties of the display.
typedef enum AGSDisplayFlags
Expand Down Expand Up @@ -942,7 +943,8 @@ typedef struct AGSDX12ReturnedParams
unsigned int floatConversion : 1; ///< Supported in Radeon Software Version 20.5.1 onwards.
unsigned int readLaneAt : 1; ///< Supported in Radeon Software Version 20.11.2 onwards.
unsigned int rayHitToken : 1; ///< Supported in Radeon Software Version 20.11.2 onwards.
unsigned int padding : 20; ///< Reserved
unsigned int shaderClock : 1; ///< Supported in Radeon Software Version 23.1.1 onwards.
unsigned int padding : 19; ///< Reserved
} ExtensionsSupported;
ExtensionsSupported extensionsSupported; ///< List of supported extensions
*/
Expand All @@ -960,16 +962,16 @@ typedef struct AGSDX12ReturnedParams
/// * The intrinsic instructions require a 5.1 shader model.
/// * The Root Signature will need to reserve an extra UAV resource slot. This is not a real resource that requires allocating, it is just used to encode the intrinsic instructions.
///
/// The easiest way to set up the reserved UAV slot is to specify it at u0. The register space id will automatically be assumed to be \ref AGS_DX12_SHADER_INSTRINSICS_SPACE_ID.
/// The easiest way to set up the reserved UAV slot is to specify it at u0. The register space id will automatically be assumed to be \ref AGS_DX12_SHADER_INTRINSICS_SPACE_ID.
/// The HLSL expects this as default and the set up code would look similar to this:
/// \code{.cpp}
/// CD3DX12_DESCRIPTOR_RANGE range[];
/// ...
/// range[ 0 ].Init( D3D12_DESCRIPTOR_RANGE_TYPE_UAV, 1, 0, AGS_DX12_SHADER_INSTRINSICS_SPACE_ID ); // u0 at driver-reserved space id
/// range[ 0 ].Init( D3D12_DESCRIPTOR_RANGE_TYPE_UAV, 1, 0, AGS_DX12_SHADER_INTRINSICS_SPACE_ID ); // u0 at driver-reserved space id
/// \endcode
///
/// Newer drivers also support a user-specified slot in which case the register space id is assumed to be 0. It is important that the \ref AGSDX12ReturnedParams::ExtensionsSupported::UAVBindSlot bit is set.
/// to ensure the driver can support this. If not, then u0 and \ref AGS_DX12_SHADER_INSTRINSICS_SPACE_ID must be used.
/// to ensure the driver can support this. If not, then u0 and \ref AGS_DX12_SHADER_INTRINSICS_SPACE_ID must be used.
/// If the driver does support this feature and a non zero slot is required, then the HLSL must also define AMD_EXT_SHADER_INTRINSIC_UAV_OVERRIDE as the matching slot value.
///
/// \param [in] context Pointer to a context. This is generated by \ref agsInitialize
Expand Down
2 changes: 1 addition & 1 deletion dlls/amd_ags_x64/amd_ags_x64.spec
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
@ stub agsDriverExtensionsDX11_CreateTexture1D
@ stub agsDriverExtensionsDX11_CreateTexture2D
@ stub agsDriverExtensionsDX11_CreateTexture3D
@ stub agsDriverExtensionsDX11_DeInit
@ stdcall agsDriverExtensionsDX11_DeInit(ptr)
@ stub agsDriverExtensionsDX11_Destroy
@ stdcall -norelay -arch=win64 agsDriverExtensionsDX11_DestroyDevice()
@ stdcall -norelay -arch=win64 agsDriverExtensionsDX11_EndUAVOverlap() DX11_EndUAVOverlap_impl
Expand Down
Loading

0 comments on commit 6204e7b

Please sign in to comment.