MiKTeX can be built on Windows. A subset of MiKTeX, called MiKTeX Tools, can be built on GNU/Linux. For more information, see the Readme file:
You can download MiKTeX source code here:
Source code is also available through Subversion. To check out the sources of the 2.9 development branch with a command-line Subversion client, type:
svn co https://miktex.svn.sf.net/svnroot/miktex/miktex/branches/2.9 miktex-2.9
To check out the latest (not necessarily stable) development sources, type:
svn co https://miktex.svn.sf.net/svnroot/miktex/miktex/trunk miktex-latest