Skip to content

Commit 5429418

Browse files
tambrytstellar
authored andcommitted
[clang] Add support for Debian 14 Forky and Debian 15 Duke (llvm#138460)
Futureproofs our single Debian-specific special case for roughly the next 6 years. See: https://lists.debian.org/debian-devel-announce/2025/01/msg00004.html (cherry picked from commit 58e6883)
1 parent be087ab commit 5429418

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

clang/include/clang/Driver/Distro.h

+3-1
Original file line numberDiff line numberDiff line change
@@ -39,6 +39,8 @@ class Distro {
3939
DebianBullseye,
4040
DebianBookworm,
4141
DebianTrixie,
42+
DebianForky,
43+
DebianDuke,
4244
Exherbo,
4345
RHEL5,
4446
RHEL6,
@@ -128,7 +130,7 @@ class Distro {
128130
bool IsOpenSUSE() const { return DistroVal == OpenSUSE; }
129131

130132
bool IsDebian() const {
131-
return DistroVal >= DebianLenny && DistroVal <= DebianTrixie;
133+
return DistroVal >= DebianLenny && DistroVal <= DebianDuke;
132134
}
133135

134136
bool IsUbuntu() const {

clang/lib/Driver/Distro.cpp

+6
Original file line numberDiff line numberDiff line change
@@ -160,6 +160,10 @@ static Distro::DistroType DetectDistro(llvm::vfs::FileSystem &VFS) {
160160
return Distro::DebianBookworm;
161161
case 13:
162162
return Distro::DebianTrixie;
163+
case 14:
164+
return Distro::DebianForky;
165+
case 15:
166+
return Distro::DebianDuke;
163167
default:
164168
return Distro::UnknownDistro;
165169
}
@@ -173,6 +177,8 @@ static Distro::DistroType DetectDistro(llvm::vfs::FileSystem &VFS) {
173177
.Case("bullseye/sid", Distro::DebianBullseye)
174178
.Case("bookworm/sid", Distro::DebianBookworm)
175179
.Case("trixie/sid", Distro::DebianTrixie)
180+
.Case("forky/sid", Distro::DebianForky)
181+
.Case("duke/sid", Distro::DebianDuke)
176182
.Default(Distro::UnknownDistro);
177183
}
178184

0 commit comments

Comments
 (0)