title: NullPointerException during gradle build on Windows
body: <p>I am currently using <strong>gradle</strong> to build dependencies and I have added below statement in my <strong>build.gradle</strong> :</p>
  
  <pre><code>compile group: 'org.apache.pig', name:'pig', version:'0.12.0-cdh5.1.0'
  testCompile group: 'org.apache.pig', name: 'pigunit', version:'0.12.0-cdh5.1.0'
  </code></pre>
  
  <p>Code is as below :</p>
  
  <pre><code>PigServer pigServer = new PigServer(ExecType.LOCAL);
  final Map&lt;String, String&gt; paramMap = new HashMap&lt;String, String&gt;(HASH_MAP_SIZE);
  paramMap.put("input_path", args[0]);
  paramMap.put("output_path", args[1]);
  pigServer.setBatchOn();
  InputStream is = PigExecutor.class.getClassLoader().getResourceAsStream(args[0]);
  pigServer.registerScript(is, paramMap);
  </code></pre>
  
  <p>while executing above code I am getting below issue :</p>
  
  <pre><code>org.apache.hadoop.mapreduce.lib.jobcontrol.ControlledJob - PigLatin:DefaultJobName got an error while submitting 
  java.lang.NullPointerException
      at java.lang.ProcessBuilder.start(ProcessBuilder.java:1010)
      at org.apache.hadoop.util.Shell.runCommand(Shell.java:451)
      at org.apache.hadoop.util.Shell.run(Shell.java:424)
      at org.apache.hadoop.util.Shell$ShellCommandExecutor.execute(Shell.java:656)
      at org.apache.hadoop.util.Shell.execCommand(Shell.java:745)
      at org.apache.hadoop.util.Shell.execCommand(Shell.java:728)
      at org.apache.hadoop.fs.RawLocalFileSystem.setPermission(RawLocalFileSystem.java:633)
      at org.apache.hadoop.fs.RawLocalFileSystem.mkdirs(RawLocalFileSystem.java:421)
      at org.apache.hadoop.fs.FilterFileSystem.mkdirs(FilterFileSystem.java:281)
      at org.apache.hadoop.mapreduce.JobSubmissionFiles.getStagingDir(JobSubmissionFiles.java:125)
      at org.apache.hadoop.mapreduce.JobSubmitter.submitJobInternal(JobSubmitter.java:348)
      at org.apache.hadoop.mapreduce.Job$10.run(Job.java:1295)
      at org.apache.hadoop.mapreduce.Job$10.run(Job.java:1292)
      at java.security.AccessController.doPrivileged(Native Method)
      at javax.security.auth.Subject.doAs(Subject.java:415)
      at org.apache.hadoop.security.UserGroupInformation.doAs(UserGroupInformation.java:1554)
      at org.apache.hadoop.mapreduce.Job.submit(Job.java:1292)
      at org.apache.hadoop.mapreduce.lib.jobcontrol.ControlledJob.submit(ControlledJob.java:335)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:606)
      at org.apache.pig.backend.hadoop23.PigJobControl.submit(PigJobControl.java:128)
      at org.apache.pig.backend.hadoop23.PigJobControl.run(PigJobControl.java:191)
      at java.lang.Thread.run(Thread.java:745)
      at org.apache.pig.backend.hadoop.executionengine.mapReduceLayer.MapReduceLauncher$1.run(MapReduceLauncher.java:270)
  </code></pre>
  
  <p>Could someone provide me solution for this.</p>