I feel I am making things way too complicated. I have a Makefile, which is building a static library [1] in both 32 and 64 bit. The current issue is it creates a static lib (.a file) and installs both the 32 and 64 to /usr/lib/, which is not working because the 64 and 32 bit lib overwrite each other.
I found the following gcc queries give me the correct target install dir on cygwin64 [2]: $ gcc -m64 -print-search-dirs | grep ^libraries | sed 's/^libraries: =//; s/:/\n/g;' | grep -v ^/usr/lib/gcc | grep -v "^/usr/lib/$(gcc -dumpmachine)/" | head -n 1 /usr/lib/../lib/ $ gcc -m32 -print-search-dirs | grep ^libraries | sed 's/^libraries: =//; s/:/\n/g;' | grep -v ^/usr/lib/gcc | grep -v "^/usr/lib/$(gcc -dumpmachine)/" | head -n 1 /usr/lib/../lib32/ My Google fu has failed to identify a more simple method for identifying the "32 bit" lib dir with regards to the 64 bit gcc. For now I am going to hard code the /usr/lib32/ in the Makefile on target ia32 for cygwin64. Obviously the ability for compiling 64 bin on cygwin 32 bit is a non-issue because of the following gcc [3] error: "sorry, unimplemented: 64-bit mode not compiled in" Thanks! Jason Pyeron 1: GNU EFI - https://github.com/pdinc-oss/gnu-efi/tree/cygwin-fixes 2: $ cygcheck -cd | egrep '^(Cygwin|Package|cygwin |gcc-core)' Cygwin Package Information Package Version cygwin 2.5.1-1 gcc-core 5.3.0-5 3: $ cygcheck -cd | egrep '^(Cygwin|Package|cygwin |gcc-core)' Cygwin Package Information Package Version cygwin 2.4.1-1 gcc-core 4.9.3-1 -- 410-424-5524 Jason Pyeron PMC Member CipherShed www.ciphershed.org -- Problem reports: http://cygwin.com/problems.html FAQ: http://cygwin.com/faq/ Documentation: http://cygwin.com/docs.html Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple