Just one remark about the Wine compilation on Solaris.
I compiled and ran successfully Wine 2.15 on Solaris 11.3, using the GNU C compiler available on the Solaris official package repository (the old GNU GCC 3.4.3).
I had to remove some code in "dlls/ntdll/virtual.c" to avoid undefined variable error as presented below. The removed code is in comments:
void virtual_get_system_info( SYSTEM_BASIC_INFORMATION *info )
{
/*
#ifdef HAVE_SYSINFO
struct sysinfo sinfo;
#endif
*/
info->unknown = 0;
info->KeMaximumIncrement = 0; /* FIXME */
info->PageSize = page_size;
info->MmLowestPhysicalPage = 1;
info->MmHighestPhysicalPage = 0x7fffffff / page_size;
/*
#ifdef HAVE_SYSINFO
if (!sysinfo(&sinfo))
{
ULONG64 total = (ULONG64)sinfo.totalram * sinfo.mem_unit;
info->MmHighestPhysicalPage = max(1, total / page_size);
}
#endif
*/
info->MmNumberOfPhysicalPages = info->MmHighestPhysicalPage - info->MmLowestPhysicalPage;
info->AllocationGranularity = get_mask(0) + 1;
info->LowestUserAddress = (void *)0x10000;
info->HighestUserAddress = (char *)user_space_limit - 1;
info->ActiveProcessorsAffinityMask = get_system_affinity_mask();
info->NumberOfProcessors = NtCurrentTeb()->Peb->NumberOfProcessors;
}
The compilation error was:
virtual.c: In function `virtual_get_system_info':
virtual.c
virtual.c
virtual.c
*** Error code 1
make: Fatal error: Command failed for target `virtual.o'
I did not have any other compilation errors.
(additional note: as indicated in https://bugs.winehq.org/show_bug.cgi?id=37135, it is needed to run Wine like this: LD_PRELOAD=libumem.so UMEM_OPTIONS=backend=mmap wine )