Skip to content

Commit 14776cf

Browse files
committed
Add driver support for Ubuntu 9.10.
llvm-svn: 119137
1 parent aac9fa7 commit 14776cf

File tree

1 file changed

+10
-4
lines changed

1 file changed

+10
-4
lines changed

clang/lib/Driver/ToolChains.cpp

Lines changed: 10 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1203,6 +1203,7 @@ enum LinuxDistro {
12031203
Fedora14,
12041204
OpenSuse11_3,
12051205
UbuntuJaunty,
1206+
UbuntuKarmic,
12061207
UbuntuLucid,
12071208
UbuntuMaverick,
12081209
UnknownDistro
@@ -1221,7 +1222,8 @@ static bool IsDebian(enum LinuxDistro Distro) {
12211222
}
12221223

12231224
static bool IsUbuntu(enum LinuxDistro Distro) {
1224-
return Distro == UbuntuLucid || Distro == UbuntuMaverick || Distro == UbuntuJaunty;
1225+
return Distro == UbuntuLucid || Distro == UbuntuMaverick ||
1226+
Distro == UbuntuJaunty || Distro == UbuntuKarmic;
12251227
}
12261228

12271229
static bool IsDebianBased(enum LinuxDistro Distro) {
@@ -1254,6 +1256,8 @@ static LinuxDistro DetectLinuxDistro(llvm::Triple::ArchType Arch) {
12541256
return UbuntuLucid;
12551257
else if (Lines[i] == "DISTRIB_CODENAME=jaunty")
12561258
return UbuntuJaunty;
1259+
else if (Lines[i] == "DISTRIB_CODENAME=karmic")
1260+
return UbuntuKarmic;
12571261
}
12581262
return UnknownDistro;
12591263
}
@@ -1342,7 +1346,7 @@ Linux::Linux(const HostInfo &Host, const llvm::Triple& Triple)
13421346
GccTriple = "i586-suse-linux";
13431347
}
13441348

1345-
const char* GccVersions[] = {"4.5.1", "4.5", "4.4.5", "4.4.4", "4.4.3",
1349+
const char* GccVersions[] = {"4.5.1", "4.5", "4.4.5", "4.4.4", "4.4.3", "4.4",
13461350
"4.3.3", "4.3.2"};
13471351
std::string Base = "";
13481352
for (unsigned i = 0; i < sizeof(GccVersions)/sizeof(char*); ++i) {
@@ -1392,14 +1396,16 @@ Linux::Linux(const HostInfo &Host, const llvm::Triple& Triple)
13921396
if (IsFedora(Distro) || Distro == UbuntuMaverick)
13931397
ExtraOpts.push_back("--hash-style=gnu");
13941398

1395-
if (IsDebian(Distro) || Distro == UbuntuLucid || Distro == UbuntuJaunty)
1399+
if (IsDebian(Distro) || Distro == UbuntuLucid || Distro == UbuntuJaunty ||
1400+
Distro == UbuntuKarmic)
13961401
ExtraOpts.push_back("--hash-style=both");
13971402

13981403
if (IsFedora(Distro))
13991404
ExtraOpts.push_back("--no-add-needed");
14001405

14011406
if (Distro == DebianSqueeze || IsOpenSuse(Distro) ||
1402-
IsFedora(Distro) || Distro == UbuntuLucid || Distro == UbuntuMaverick)
1407+
IsFedora(Distro) || Distro == UbuntuLucid || Distro == UbuntuMaverick ||
1408+
Distro == UbuntuKarmic)
14031409
ExtraOpts.push_back("--build-id");
14041410

14051411
Paths.push_back(Base + Suffix);

0 commit comments

Comments
 (0)