Mercurial > projects > ldc
comparison gen/linker.cpp @ 681:ca4a816f2440
Another link order fix.
author | Christian Kamm <kamm incasoftware de> |
---|---|
date | Sat, 11 Oct 2008 22:14:16 +0200 |
parents | 075c1272a01d |
children | 855e0ef78fa2 |
comparison
equal
deleted
inserted
replaced
680:703d9b4505f9 | 681:ca4a816f2440 |
---|---|
215 std::vector<const char*> args; | 215 std::vector<const char*> args; |
216 | 216 |
217 // first the program name ?? | 217 // first the program name ?? |
218 args.push_back("gcc"); | 218 args.push_back("gcc"); |
219 | 219 |
220 // object files | |
221 for (int i = 0; i < global.params.objfiles->dim; i++) | |
222 { | |
223 char *p = (char *)global.params.objfiles->data[i]; | |
224 args.push_back(p); | |
225 } | |
226 | |
220 // output filename | 227 // output filename |
221 std::string exestr; | 228 std::string exestr; |
222 if (global.params.exefile) | 229 if (global.params.exefile) |
223 { // explicit | 230 { // explicit |
224 exestr = global.params.exefile; | 231 exestr = global.params.exefile; |
281 case OSWindows: | 288 case OSWindows: |
282 // FIXME: I'd assume kernel32 etc | 289 // FIXME: I'd assume kernel32 etc |
283 break; | 290 break; |
284 } | 291 } |
285 | 292 |
286 // object files | |
287 for (int i = 0; i < global.params.objfiles->dim; i++) | |
288 { | |
289 char *p = (char *)global.params.objfiles->data[i]; | |
290 args.push_back(p); | |
291 } | |
292 | |
293 // print link command? | 293 // print link command? |
294 if (!global.params.quiet || global.params.verbose) | 294 if (!global.params.quiet || global.params.verbose) |
295 { | 295 { |
296 // Print it | 296 // Print it |
297 for (int i = 0; i < args.size(); i++) | 297 for (int i = 0; i < args.size(); i++) |