PB 5.0 B8, zlib.lib extrn crc32, reserved symbol error, x64

Bare metal programming in PureBasic, for experienced users
User avatar
Rescator
Addict
Addict
Posts: 1769
Joined: Sat Feb 19, 2005 5:05 pm
Location: Norway

PB 5.0 B8, zlib.lib extrn crc32, reserved symbol error, x64

Post by Rescator »

Trying to do a ImportC "zlib.lib" fails if trying to import crc32().
AFAIK crc32 is a x64 instruction, so there could be a conflict there.

---------------------------
PureBasic - Assembler error
---------------------------
PureBasic.asm [xxx]:
extrn crc32
error: reserved word used as symbol.

Compiling zlib.lib with the -DZ_PREFIX flag might be one solution.
Fred
Administrator
Administrator
Posts: 16690
Joined: Fri May 17, 2002 4:39 pm
Location: France
Contact:

Re: PB 5.0 B8, zlib.lib extrn crc32, reserved symbol error,

Post by Fred »

That's not a PB bug, you can't import a function with the same name than an asm token. If you really need it, you should recompile the zlib with Z_PREFIX and use it.
Post Reply