* Fix build for ming-w64

This commit is contained in:
pancake 2011-07-12 19:42:20 +02:00
parent 0d43c5422a
commit 1e3739f902
3 changed files with 22 additions and 1 deletions

View File

@ -31,6 +31,10 @@ Crosscompilation
make w32dist
Windows x86-64
==============
./configure --without-gmp --with-compiler=x86_64-w64-mingw32-gcc --with-ostype=windows --host=x86_64-unknown-windows --without-magic --without-ssl
Python bindings:
================

View File

@ -24,7 +24,7 @@ extern int errno;
static int debug_os_read_at(RIOW32Dbg *dbg, void *buf, int len, ut64 addr) {
DWORD ret;
ReadProcessMemory (dbg->pi.hProcess, (PCVOID)(ULONG)addr, buf, len, &ret);
ReadProcessMemory (dbg->pi.hProcess, (void*)(size_t)addr, buf, len, &ret);
// if (len != ret)
// eprintf ("Cannot read 0x%08llx\n", addr);
return len; // XXX: Handle read correctly and not break r2 shell

View File

@ -0,0 +1,17 @@
CC=x86_64-w64-mingw32-gcc
RANLIB=x86_64-w64-mingw32-ranlib
ONELIB=0
OSTYPE=windows
LINK=
CC_AR=echo ar -r ${LIBAR}
PICFLAGS=
CFLAGS+=${PICFLAGS} -MD -D__WINDOWS__=1
CC_LIB=${CC} -shared -o
CFLAGS_INCLUDE=-I
LDFLAGS_LINK=-l
LDFLAGS_LINKPATH=-L
CFLAGS_OPT0=-O0
CFLAGS_OPT1=-O1
CFLAGS_OPT2=-O2
CFLAGS_OPT3=-O3
CFLAGS_DEBUG=-g