  
          if not os.path.exists(pathbinlk[side]):
              os.makedirs(pathbinlk[side])
-@@ -1338,7 +1345,7 @@
+ 
+         # HINT: We create the list of source directories based on the list of packages
+         # on windows we just pass wildcards, otherwise we pass the full file list
+-        if self.osname == 'win':
++        if self.osname == 'win' and False == True: #FML: Disable for windows we write to file now
+             all_files = False
+             append_pattern = True
+         else:
+             all_files = True
+             append_pattern = False
+         pkglist = filterdirs(pathsrclk[side], '*.java', append_pattern=append_pattern, all_files=all_files)
++        from tempfile import NamedTemporaryFile
+         if self.cmdrecompscala: # Compile scala before java as scala scans java files, but not vice-versa
+             pkglistscala = pkglist[:]
+             pkglistscala.extend(filterdirs(pathsrclk[side], '*.scala', append_pattern=append_pattern, all_files=all_files))
+-            dirs = ' '.join(pkglistscala)
++            f = NamedTemporaryFile(mode='wb', suffix='.txt', prefix ='scala_src_path_', delete=False) #FML: We write to a temporary file just in case the command is to long
++            for line in pkglistscala:
++                f.write('%s\n' % os.path.abspath(line))
++            f.close()
++            dirs = '@"%s"' % f.name
+             classpath = os.pathsep.join(cplk[side])
+             forkcmd = self.cmdrecompscala.format(classpath=classpath, sourcepath=pathsrclk[side], outpath=pathbinlk[side], pkgs=dirs)
+             try:
+@@ -1317,7 +1329,12 @@
+                 self.logger.error('================================')
+                 self.logger.error('')
+                 raise
+-        dirs = ' '.join(pkglist)
++            os.unlink(f.name)
++        f = NamedTemporaryFile(mode='wb', suffix='.txt', prefix ='java_src_path_', delete=False) #FML: We write to a temporary file just in case the command is to long
++        for line in pkglist:
++            f.write('%s\n' % os.path.abspath(line))
++        f.close()
++        dirs = '@"%s"' % f.name
+         classpath = os.pathsep.join(cplk[side])
+         forkcmd = self.cmdrecomp.format(classpath=classpath, sourcepath=pathsrclk[side], outpath=pathbinlk[side],
+                                         pkgs=dirs)
+@@ -1338,7 +1355,7 @@
              raise
  
      def startserver(self, mainclass, extraargs):

             if entry[3] == 'U':
                 self.logger.info('Retrieving file from server : %s', entry[0])
                 cur_file = os.path.normpath(entry[0])
@@ -1910,6 +1923,9 @@
         md5reoblk = {CLIENT: self.md5reobfclient, SERVER: self.md5reobfserver}
         outpathlk = {CLIENT: self.srcmodclient, SERVER: self.srcmodserver}
         src = {CLIENT: self.srcclient, SERVER: self.srcserver}

         if not os.path.exists(os.path.join(binlk[side], os.path.normpath(testlk[side] + '.class'))):
             return False
         return True
@@ -1281,23 +1285,31 @@
         pathbinlk = {CLIENT: self.binclient, SERVER: self.binserver}
         pathsrclk = {CLIENT: self.srcclient, SERVER: self.srcserver}
         pathlog = {CLIENT: self.clientrecomplog, SERVER: self.serverrecomplog}
