Draft of rebuild-elftc.sh for Windows MinGW.
Current state of run it:
+ cd common
+ bmake -B 'COPTS=-m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup' 'LD=ld -melf_i386' MKPIC=yes all
+ cd libelf
+ bmake -B 'COPTS=-m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup' 'LD=ld -melf_i386' MKPIC=yes libelf_pic.a
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf.d -MT elf.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf.c -o elf.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_begin.d -MT elf_begin.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_begin.c -o elf_begin.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_cntl.d -MT elf_cntl.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_cntl.c -o elf_cntl.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_end.d -MT elf_end.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_end.c -o elf_end.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_errmsg.d -MT elf_errmsg.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_errmsg.c -o elf_errmsg.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_errno.d -MT elf_errno.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_errno.c -o elf_errno.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_data.d -MT elf_data.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_data.c -o elf_data.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_fill.d -MT elf_fill.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_fill.c -o elf_fill.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_flag.d -MT elf_flag.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_flag.c -o elf_flag.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_getarhdr.d -MT elf_getarhdr.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_getarhdr.c -o elf_getarhdr.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_getarsym.d -MT elf_getarsym.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_getarsym.c -o elf_getarsym.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_getbase.d -MT elf_getbase.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_getbase.c -o elf_getbase.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_getident.d -MT elf_getident.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_getident.c -o elf_getident.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_hash.d -MT elf_hash.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_hash.c -o elf_hash.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_kind.d -MT elf_kind.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_kind.c -o elf_kind.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_memory.d -MT elf_memory.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_memory.c -o elf_memory.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_next.d -MT elf_next.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_next.c -o elf_next.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_open.d -MT elf_open.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_open.c -o elf_open.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_rand.d -MT elf_rand.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_rand.c -o elf_rand.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_rawfile.d -MT elf_rawfile.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_rawfile.c -o elf_rawfile.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_phnum.d -MT elf_phnum.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_phnum.c -o elf_phnum.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_shnum.d -MT elf_shnum.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_shnum.c -o elf_shnum.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_shstrndx.d -MT elf_shstrndx.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_shstrndx.c -o elf_shstrndx.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_scn.d -MT elf_scn.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_scn.c -o elf_scn.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_strptr.d -MT elf_strptr.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_strptr.c -o elf_strptr.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_update.d -MT elf_update.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_update.c -o elf_update.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF elf_version.d -MT elf_version.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC elf_version.c -o elf_version.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF gelf_cap.d -MT gelf_cap.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC gelf_cap.c -o gelf_cap.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF gelf_checksum.d -MT gelf_checksum.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC gelf_checksum.c -o gelf_checksum.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF gelf_dyn.d -MT gelf_dyn.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC gelf_dyn.c -o gelf_dyn.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF gelf_ehdr.d -MT gelf_ehdr.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC gelf_ehdr.c -o gelf_ehdr.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF gelf_getclass.d -MT gelf_getclass.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC gelf_getclass.c -o gelf_getclass.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF gelf_fsize.d -MT gelf_fsize.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC gelf_fsize.c -o gelf_fsize.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF gelf_move.d -MT gelf_move.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC gelf_move.c -o gelf_move.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF gelf_phdr.d -MT gelf_phdr.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC gelf_phdr.c -o gelf_phdr.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF gelf_rel.d -MT gelf_rel.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC gelf_rel.c -o gelf_rel.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF gelf_rela.d -MT gelf_rela.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC gelf_rela.c -o gelf_rela.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF gelf_shdr.d -MT gelf_shdr.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC gelf_shdr.c -o gelf_shdr.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF gelf_sym.d -MT gelf_sym.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC gelf_sym.c -o gelf_sym.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF gelf_syminfo.d -MT gelf_syminfo.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC gelf_syminfo.c -o gelf_syminfo.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF gelf_symshndx.d -MT gelf_symshndx.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC gelf_symshndx.c -o gelf_symshndx.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF gelf_xlate.d -MT gelf_xlate.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC gelf_xlate.c -o gelf_xlate.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF libelf_align.d -MT libelf_align.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC libelf_align.c -o libelf_align.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF libelf_allocate.d -MT libelf_allocate.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC libelf_allocate.c -o libelf_allocate.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF libelf_ar.d -MT libelf_ar.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC libelf_ar.c -o libelf_ar.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF libelf_ar_util.d -MT libelf_ar_util.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC libelf_ar_util.c -o libelf_ar_util.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF libelf_checksum.d -MT libelf_checksum.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC libelf_checksum.c -o libelf_checksum.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF libelf_data.d -MT libelf_data.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC libelf_data.c -o libelf_data.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF libelf_ehdr.d -MT libelf_ehdr.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC libelf_ehdr.c -o libelf_ehdr.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF libelf_extended.d -MT libelf_extended.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC libelf_extended.c -o libelf_extended.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF libelf_memory.d -MT libelf_memory.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC libelf_memory.c -o libelf_memory.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF libelf_open.d -MT libelf_open.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC libelf_open.c -o libelf_open.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF libelf_phdr.d -MT libelf_phdr.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC libelf_phdr.c -o libelf_phdr.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF libelf_shdr.d -MT libelf_shdr.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC libelf_shdr.c -o libelf_shdr.pico
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF libelf_xlate.d -MT libelf_xlate.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC libelf_xlate.c -o libelf_xlate.pico
m4 -D SRCDIR=/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf libelf_fsize.m4 > libelf_fsize.c
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF libelf_fsize.d -MT libelf_fsize.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC libelf_fsize.c -o libelf_fsize.pico
m4 -D SRCDIR=/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf libelf_msize.m4 > libelf_msize.c
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF libelf_msize.d -MT libelf_msize.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC libelf_msize.c -o libelf_msize.pico
m4 -D SRCDIR=/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf libelf_convert.m4 > libelf_convert.c
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF libelf_convert.d -MT libelf_convert.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/../common -c -fpic -DPIC libelf_convert.c -o libelf_convert.pico
building shared object elf library
ranlib libelf_pic.a
+ cd libdwarf
+ bmake -B 'COPTS=-m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup' 'LD=ld -melf_i386' MKPIC=yes libdwarf_pic.a
gcc -pipe -O -g -m32 -O2 -g -Dmalloc=__wrap_malloc -Dcalloc=__wrap_calloc -Drealloc=__wrap_realloc -Dfree=__wrap_free -Dstrdup=__wrap_strdup -MD -MF dwarf_abbrev.d -MT dwarf_abbrev.o -I. -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libdwarf -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libdwarf/../common -I/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libdwarf/../libelf -c -fpic -DPIC dwarf_abbrev.c -o dwarf_abbrev.pico
In file included from _libdwarf.h:50,
from dwarf_abbrev.c:27:
libdwarf.h:35:9: error: unknown type name 'INT_PTR'
35 | typedef INT_PTR off_t;
| ^~~~~~~
libdwarf.h:35:17: error: conflicting types for 'off_t'
35 | typedef INT_PTR off_t;
| ^~~~~
In file included from C:/msys64/mingw64/x86_64-w64-mingw32/include/sys/types.h:81,
from C:/msys64/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/common/windows-mingw/sys_param.h:10,
from _libdwarf.h:36,
from dwarf_abbrev.c:27:
C:/msys64/mingw64/x86_64-w64-mingw32/include/_mingw_off_t.h:26:17: note: previous declaration of 'off_t' was here
26 | typedef off32_t off_t;
| ^~~~~
In file included from _libdwarf.h:50,
from dwarf_abbrev.c:27:
libdwarf.h:43:14: error: conflicting types for 'int8_t'
43 | typedef char int8_t;
| ^~~~~~
In file included from C:/msys64/mingw64/lib/gcc/x86_64-w64-mingw32/10.2.0/include/stdint.h:9,
from C:/msys64/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/common/elfdefinitions.h:43,
from C:/msys64/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/libelf.h:54,
from C:/msys64/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libelf/gelf.h:32,
from _libdwarf.h:48,
from dwarf_abbrev.c:27:
C:/msys64/mingw64/x86_64-w64-mingw32/include/stdint.h:35:21: note: previous declaration of 'int8_t' was here
35 | typedef signed char int8_t;
| ^~~~~~
*** Error code 1
Stop.
bmake.exe[1]: stopped in C:/msys64/home/ofry/dynamorio/ext/drsyms/libelftc/windows-lib64/libdwarf
All changes should not harm on *nix. Could you help me to finish this?