We are essentially compiling 2 separate sets of binary files and these two isets have to always be separated.
Otherwise, you may get:
/home/jpmugaas/exp/mingw-w64-pdcurses/src/PDCurses-4.1.0/wingui-shared /home/jpmugaas/exp/mingw-w64-pdcurses/src/PDCurses-4.1.0
/mingw32/bin/gcc -c -O4 -Wall -pedantic -I.. -DPDC_WIDE -DPDC_FORCE_UTF8 -DPDC_DLL_BUILD ../pdcurses/terminfo.c
/mingw32/bin/gcc -Wl,--out-implib,libpdcurses.dll.a -shared -o libpdcurses.dll terminfo.o -lgdi32 -lcomdlg32
terminfo.o:terminfo.c:(.text+0xb): undefined reference to `LINES'
terminfo.o:terminfo.c:(.text+0x17): undefined reference to `COLS'
terminfo.o:terminfo.c:(.text+0x2d): undefined reference to `PDC_gotoyx'
terminfo.o:terminfo.c:(.text+0x32): undefined reference to `SP'
collect2.exe: error: ld returned 1 exit status
make: *** [Makefile.mng:141: libpdcurses.dll] Error 1
if the build dirs are cleaned beforehand. But we might NOT want to clean because we may need to examine the files aftwards.