Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

llvmbot
Copy link
Member

@llvmbot llvmbot commented May 6, 2025

Backport 58e6883

Requested by: @tambry

@llvmbot
Copy link
Member Author

llvmbot commented May 6, 2025

@sylvestre What do you think about merging this PR to the release branch?

@llvmbot llvmbot requested a review from sylvestre May 6, 2025 08:35
@llvmbot llvmbot added clang Clang issues not falling into any other category clang:driver 'clang' and 'clang++' user-facing binaries. Not 'clang-cl' labels May 6, 2025
@llvmbot
Copy link
Member Author

llvmbot commented May 6, 2025

@llvm/pr-subscribers-clang-driver

Author: None (llvmbot)

Changes

Backport 58e6883

Requested by: @tambry


Full diff: https://github.com/llvm/llvm-project/pull/138652.diff

2 Files Affected:

  • (modified) clang/include/clang/Driver/Distro.h (+3-1)
  • (modified) clang/lib/Driver/Distro.cpp (+6)
diff --git a/clang/include/clang/Driver/Distro.h b/clang/include/clang/Driver/Distro.h
index b4d485dac8a26..c544a8c002191 100644
--- a/clang/include/clang/Driver/Distro.h
+++ b/clang/include/clang/Driver/Distro.h
@@ -39,6 +39,8 @@ class Distro {
     DebianBullseye,
     DebianBookworm,
     DebianTrixie,
+    DebianForky,
+    DebianDuke,
     Exherbo,
     RHEL5,
     RHEL6,
@@ -128,7 +130,7 @@ class Distro {
   bool IsOpenSUSE() const { return DistroVal == OpenSUSE; }
 
   bool IsDebian() const {
-    return DistroVal >= DebianLenny && DistroVal <= DebianTrixie;
+    return DistroVal >= DebianLenny && DistroVal <= DebianDuke;
   }
 
   bool IsUbuntu() const {
diff --git a/clang/lib/Driver/Distro.cpp b/clang/lib/Driver/Distro.cpp
index 3cc79535de8da..71ba71fa18379 100644
--- a/clang/lib/Driver/Distro.cpp
+++ b/clang/lib/Driver/Distro.cpp
@@ -160,6 +160,10 @@ static Distro::DistroType DetectDistro(llvm::vfs::FileSystem &VFS) {
         return Distro::DebianBookworm;
       case 13:
         return Distro::DebianTrixie;
+      case 14:
+        return Distro::DebianForky;
+      case 15:
+        return Distro::DebianDuke;
       default:
         return Distro::UnknownDistro;
       }
@@ -173,6 +177,8 @@ static Distro::DistroType DetectDistro(llvm::vfs::FileSystem &VFS) {
         .Case("bullseye/sid", Distro::DebianBullseye)
         .Case("bookworm/sid", Distro::DebianBookworm)
         .Case("trixie/sid", Distro::DebianTrixie)
+        .Case("forky/sid", Distro::DebianForky)
+        .Case("duke/sid", Distro::DebianDuke)
         .Default(Distro::UnknownDistro);
   }
 

@llvmbot
Copy link
Member Author

llvmbot commented May 6, 2025

@llvm/pr-subscribers-clang

Author: None (llvmbot)

Changes

Backport 58e6883

Requested by: @tambry


Full diff: https://github.com/llvm/llvm-project/pull/138652.diff

2 Files Affected:

  • (modified) clang/include/clang/Driver/Distro.h (+3-1)
  • (modified) clang/lib/Driver/Distro.cpp (+6)
diff --git a/clang/include/clang/Driver/Distro.h b/clang/include/clang/Driver/Distro.h
index b4d485dac8a26..c544a8c002191 100644
--- a/clang/include/clang/Driver/Distro.h
+++ b/clang/include/clang/Driver/Distro.h
@@ -39,6 +39,8 @@ class Distro {
     DebianBullseye,
     DebianBookworm,
     DebianTrixie,
+    DebianForky,
+    DebianDuke,
     Exherbo,
     RHEL5,
     RHEL6,
@@ -128,7 +130,7 @@ class Distro {
   bool IsOpenSUSE() const { return DistroVal == OpenSUSE; }
 
   bool IsDebian() const {
-    return DistroVal >= DebianLenny && DistroVal <= DebianTrixie;
+    return DistroVal >= DebianLenny && DistroVal <= DebianDuke;
   }
 
   bool IsUbuntu() const {
diff --git a/clang/lib/Driver/Distro.cpp b/clang/lib/Driver/Distro.cpp
index 3cc79535de8da..71ba71fa18379 100644
--- a/clang/lib/Driver/Distro.cpp
+++ b/clang/lib/Driver/Distro.cpp
@@ -160,6 +160,10 @@ static Distro::DistroType DetectDistro(llvm::vfs::FileSystem &VFS) {
         return Distro::DebianBookworm;
       case 13:
         return Distro::DebianTrixie;
+      case 14:
+        return Distro::DebianForky;
+      case 15:
+        return Distro::DebianDuke;
       default:
         return Distro::UnknownDistro;
       }
@@ -173,6 +177,8 @@ static Distro::DistroType DetectDistro(llvm::vfs::FileSystem &VFS) {
         .Case("bullseye/sid", Distro::DebianBullseye)
         .Case("bookworm/sid", Distro::DebianBookworm)
         .Case("trixie/sid", Distro::DebianTrixie)
+        .Case("forky/sid", Distro::DebianForky)
+        .Case("duke/sid", Distro::DebianDuke)
         .Default(Distro::UnknownDistro);
   }
 

@github-project-automation github-project-automation bot moved this from Needs Triage to Needs Merge in LLVM Release Status May 9, 2025
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)
@tstellar tstellar merged commit 5429418 into llvm:release/20.x May 9, 2025
7 of 9 checks passed
@github-project-automation github-project-automation bot moved this from Needs Merge to Done in LLVM Release Status May 9, 2025
Copy link

github-actions bot commented May 9, 2025

@tambry (or anyone else). If you would like to add a note about this fix in the release notes (completely optional). Please reply to this comment with a one or two sentence description of the fix. When you are done, please add the release:note label to this PR.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
clang:driver 'clang' and 'clang++' user-facing binaries. Not 'clang-cl' clang Clang issues not falling into any other category
Projects
Development

Successfully merging this pull request may close these issues.

4 participants