#!/usr/local/bin/pike

inherit "lib.pike";

int main(int argc, string *argv)
{
  if(sscanf(argv[-1],"%*[a-zA-Z]:%*s")==2)
  {
    argv[0]="copy";
    if(argv[1]=="-c") argv=argv[..0]+argv[2..];
    if(file_stat(argv[1]+".exe")) argv[1]+=".exe";
    exit(do_cmd( Array.map(argv,fixpath)));
  }else{
    argv[0]="install-sh";
    if(getenv("NT_DEBUG"))
      werror("%O\n",argv);
    Process.exec(@argv);
    exit(69);
  }
}
