Ticket #3528 (closed defect: fixed)
Building on x64 Windows
|Reported by:||ripleybd||Owned by:||warmerdam|
I needed to make some changes to build for x64 Windows. I used the cross-compilers from x86_64 Linux from the MinGW-w64 project (as used for R: these reports all come from helping Roger Bivand with the R binding for GDAL).
'ar' is hardcoded in frmts/pcidsk/sdk/Makefile: it should be $(AR).
There is a fairly pervasive design error that a pointer can be fitted into an unsigned long: this is not so on x64 Windows where long is 32 bit. The modern solution is to use uintptr_t, and that is what I have used in the attached patch. That is C99, but as you are using it for C++ I suggest that for portability it needs to be tested for in configure and otherwise typedef-ed suitably (unsigned long or unsigned long long, although the latter is not portable and rejected by g++ -pedantic).