/[jscoverage]/trunk/instrument.c
ViewVC logotype

Diff of /trunk/instrument.c

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 387 by siliconforks, Sun Oct 26 05:28:03 2008 UTC revision 388 by siliconforks, Thu Oct 30 03:14:32 2008 UTC
# Line 184  Line 184 
184      fatal("cannot stat directory: %s", destination);      fatal("cannot stat directory: %s", destination);
185    }    }
186    
187      /* copy the resources */
188      if (jscoverage_mozilla) {
189        char * chrome_directory = make_path(destination, "chrome");
190        char * jscoverage_chrome_directory = make_path(chrome_directory, "jscoverage");
191        mkdirs(jscoverage_chrome_directory);
192        copy_resource("jscoverage.manifest", chrome_directory);
193        copy_resource("jscoverage.html", jscoverage_chrome_directory);
194        copy_resource("jscoverage.css", jscoverage_chrome_directory);
195        copy_resource("jscoverage.js", jscoverage_chrome_directory);
196        copy_resource("jscoverage-throbber.gif", jscoverage_chrome_directory);
197        copy_resource("jscoverage-highlight.css", jscoverage_chrome_directory);
198        copy_resource("jscoverage.xul", jscoverage_chrome_directory);
199        copy_resource("jscoverage-overlay.js", jscoverage_chrome_directory);
200        free(jscoverage_chrome_directory);
201        free(chrome_directory);
202    
203        char * modules_directory = make_path(destination, "modules");
204        mkdirs(modules_directory);
205        copy_resource("jscoverage.jsm", modules_directory);
206        free(modules_directory);
207      }
208      else {
209        jscoverage_copy_resources(destination);
210      }
211    
212    /* finally: copy the directory */    /* finally: copy the directory */
213    struct DirListEntry * list = make_recursive_dir_list(source);    struct DirListEntry * list = make_recursive_dir_list(source);
214    for (struct DirListEntry * p = list; p != NULL; p = p->next) {    for (struct DirListEntry * p = list; p != NULL; p = p->next) {
# Line 222  Line 247 
247      free(d);      free(d);
248    }    }
249    
   /* copy the resources */  
   if (jscoverage_mozilla) {  
     char * chrome_directory = make_path(destination, "chrome");  
     char * jscoverage_chrome_directory = make_path(chrome_directory, "jscoverage");  
     mkdir_if_necessary(jscoverage_chrome_directory);  
     copy_resource("jscoverage.manifest", chrome_directory);  
     copy_resource("jscoverage.html", jscoverage_chrome_directory);  
     copy_resource("jscoverage.css", jscoverage_chrome_directory);  
     copy_resource("jscoverage.js", jscoverage_chrome_directory);  
     copy_resource("jscoverage-throbber.gif", jscoverage_chrome_directory);  
     copy_resource("jscoverage-highlight.css", jscoverage_chrome_directory);  
     copy_resource("jscoverage.xul", jscoverage_chrome_directory);  
     copy_resource("jscoverage-overlay.js", jscoverage_chrome_directory);  
     free(jscoverage_chrome_directory);  
     free(chrome_directory);  
   
     char * modules_directory = make_path(destination, "modules");  
     copy_resource("jscoverage.jsm", modules_directory);  
     free(modules_directory);  
   }  
   else {  
     jscoverage_copy_resources(destination);  
   }  
   
250    free_dir_list(list);    free_dir_list(list);
251  }  }

Legend:
Removed from v.387  
changed lines
  Added in v.388

  ViewVC Help
Powered by ViewVC 1.1.24