Skip to content

Commit

Permalink
fix(kernel_crawler): fix photonOS kernelrelease, stripping ".$arch" s…
Browse files Browse the repository at this point in the history
…ubstring.

Signed-off-by: Federico Di Pierro <[email protected]>
  • Loading branch information
FedeDP authored and poiana committed Oct 25, 2023
1 parent 3e8acae commit 03ac9c3
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions kernel_crawler/photon.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,12 @@ def list_repos(self):
for version, repo_tag in self.PHOTON_OS_VERSIONS]

def to_driverkit_config(self, release, deps):
# PhotonOS kernel packages have a ".$arch" suffix,
# thus our kernelrelease is different from `uname -r` output.
# Fix this by manually removing the suffix.
suffix = "."+self.arch
if release.endswith(suffix):
release = release[:-len(suffix)]
for dep in deps:
if dep.find("-devel") != -1:
return repo.DriverKitConfig(release, "photon", dep)

0 comments on commit 03ac9c3

Please sign in to comment.