When .so module initialization was moved from ntdll to winecrt0 with commit bef09697227c29f53bb0ad95232399cbba5c9c6b we lost a number of include files.
This broke FreeBSD-specific code that used BOOL, TRUE, and FALSE. Fix that by using poor man's int, 1, and 0 instead.
From: Gerald Pfeifer gerald@pfeifer.com
When .so module initialization was moved from ntdll to winecrt0 with commit bef09697227c29f53bb0ad95232399cbba5c9c6b we lost a number of include files.
This broke FreeBSD-specific code that used BOOL, TRUE, and FALSE. Fix that by using poor man's int, 1, and 0 instead. --- dlls/winecrt0/dll_soinit.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-)
diff --git a/dlls/winecrt0/dll_soinit.c b/dlls/winecrt0/dll_soinit.c index e0ed9a1be1e..fbb94ba1a74 100644 --- a/dlls/winecrt0/dll_soinit.c +++ b/dlls/winecrt0/dll_soinit.c @@ -46,8 +46,10 @@ * starts at the beginning of the ELF file. By parsing the file, we can * find that first PT_LOAD segment, from which we can find the base * address it wanted, and knowing mapbase where the binary was actually - * loaded, use them to work out the relocbase offset. */ -static BOOL get_relocbase(caddr_t mapbase, caddr_t *relocbase) + * loaded, use them to work out the relocbase offset. + * + * Return 1 if we were successful, 0 otherwise. */ +static int get_relocbase(caddr_t mapbase, caddr_t *relocbase) { Elf_Half i; #ifdef _WIN64 @@ -63,11 +65,11 @@ static BOOL get_relocbase(caddr_t mapbase, caddr_t *relocbase) { caddr_t desired_base = (caddr_t)((prog_header->p_vaddr / prog_header->p_align) * prog_header->p_align); *relocbase = (caddr_t) (mapbase - desired_base); - return TRUE; + return 1; } prog_header++; } - return FALSE; + return 0; } #endif