llvm.org GIT mirror llvm / da071bf
Merge in hack from Chris that discards libg. git-svn-id: https://llvm.org/svn/llvm-project/llvm/branches/release_16@24166 91177308-0d34-0410-b5e6-96231b3b80d8 John Criswell 13 years ago
1 changed file(s) with 4 addition(s) and 1 deletion(s). Raw diff Collapse all Expand all
422422
423423 // Add in the libraries to link.
424424 for (unsigned index = 0; index < Libraries.size(); index++)
425 if (Libraries[index] != "crtend") {
425 // HACK: If this is libg, discard it. This gets added by the compiler
426 // driver when doing: 'llvm-gcc main.c -Wl,-native -o a.out -g'. Note that
427 // this should really be fixed by changing the llvm-gcc compiler driver.
428 if (Libraries[index] != "crtend" && Libraries[index] != "g") {
426429 std::string Tmp = "-l"+Libraries[index];
427430 StringsToDelete.push_back(strdup(Tmp.c_str()));
428431 args.push_back(StringsToDelete.back());