Get Cygwin:
32-Bit: https://cygwin.com/setup-x86.exe
64-Bit: https://cygwin.com/setup-x86_64.exe
Note: You can compile for 64-bit in a 32-bit environment.
Click on setup-*.exe and install the following packages:
git, make, clang, gcc-core, gcc-objc, gcc-g++,
patch, wget, libuuid-devel, openssl and pkg-config
For LTO support you will also need:
libllvm-devel, libllvm, libedit and libffi
The Cygwin package of libLLVM lacks the LTO library, but you can create that dll by issuing the following command:
./tools/gen_cyglto_dll.sh
Open the Cygwin shell:
Clone the OSXCross repository:
Get the Mac OS X SDK and move it into
C:\Cygwin*\home\<User>\osxcross\tarballs.
Please see README for more.
Build OSXCross:
Add the printed target/bin path to your ~/.bashrc:
Restart the Cygwin shell:
Verify target/bin is in PATH:
All done!
Please see README.COMPILER-RT for more.
Build Compiler-RT:
Execute the printed commands:
Verify Compiler-RT works:
Please see README.MACPORTS for more.
Change the deployment target to >= 10.7:
Restart the Cygwin shell:
Let's install libgeoip:
Write a simple test program:
Compile the test program:
... or the xcrun way:
















