Skip to content

Commit

Permalink
Merge pull request #116 from mariux64/pdist-fix-kernel-excludes
Browse files Browse the repository at this point in the history
pdist Fix excludes for running kernel
  • Loading branch information
donald authored Jan 24, 2020
2 parents b71d255 + 3455406 commit 5750c19
Showing 1 changed file with 14 additions and 14 deletions.
28 changes: 14 additions & 14 deletions pdist/pdist
Original file line number Diff line number Diff line change
Expand Up @@ -651,20 +651,6 @@ sub prog_update

local($, , $\)=(' ',"\n");

if ($function == F_UPDATE) {
chomp (my $linux_version=`uname -r`); # '5.4.0-rc2.mx64.295'
if ($linux_version) {
my ($build) = $linux_version =~ /\.(\d+)$/;
push @EXCEPTS,
"/boot/mariux.$build",
"/boot/bzImage-$linux_version",
"/lib/modules/$linux_version",
"/boot/config-$linux_version",
"/boot/System.map-$linux_version",
"/usr/share/nvidia/kernel/$linux_version",
}
}

if ($tarfile && $tarfile ne '-') {
-d $TMPDIR or mkdir $TMPDIR or die $TMPDIR.": $!\n";
if (-d $TMPUPDDIR) {
Expand Down Expand Up @@ -796,7 +782,21 @@ sub prog_update

if ($function==F_UPDATE) {
if ($delete) {
my %except;
chomp (my $linux_version=`uname -r`); # '5.4.0-rc2.mx64.295'
if ($linux_version) {
my ($build) = $linux_version =~ /\.(\d+)$/;
%except=map {$_=>1} (
"/boot/mariux.$build",
"/boot/bzImage-$linux_version",
"/lib/modules/$linux_version",
"/boot/config-$linux_version",
"/boot/System.map-$linux_version",
"/usr/share/nvidia/kernel/$linux_version",
)
}
for my $path (keys %CLEAN) {
$except{$path} and next;
lstat $path or die "$path: $!\n";
if (-e _) {
if (-d _) {
Expand Down

0 comments on commit 5750c19

Please sign in to comment.