Skip to content
Permalink
83e0d7979c
Switch branches/tags

Name already in use

A tag already exists with the provided branch name. Many Git commands accept both tag and branch names, so creating this branch may cause unexpected behavior. Are you sure you want to create this branch?
Go to file
 
 
Cannot retrieve contributors at this time
executable file 80 lines (66 sloc) 1.98 KB
#! /usr/local/bin/perl
use strict;
use warnings;
our $B='/src/mariux/beeroot/bee-files';
our $TEMPLATE_CURRENT_USER = "nvidia_current-367.18-0.bee";
our $TEMPLATE_CURRENT_KERNEL = "nvidia_linux-4.7.2-99-367.18-0.bee";
our $TEMPLATE_LEGACY5_USER = "nvidia_legacy5-340.96-1.bee";
our $TEMPLATE_LEGACY5_KERNEL = "nvidia_linux-4.7.2-99-340.96-0.bee";
chdir ("/scratch/local") or die "/scratch/local: $!\n";
sub want_current_user {
my ($version,$build)=@_;
my $name="nvidia_current-$version-$build";
if (-e "$B/$name.bee") {
print "$B/$name.bee: already there\n";
return;
}
sys ('cp',"$B/$TEMPLATE_CURRENT_USER",".");
sys ('mv',$TEMPLATE_CURRENT_USER,"$name.bee");
sys ("./$name.bee");
}
sub want_legacy5_user{
my ($version,$build)=@_;
my $name="nvidia_legacy5-$version-$build";
if (-e "$B/$name.bee") {
print "$B/$name.bee: already there\n";
return;
}
sys ('cp',"$B/$TEMPLATE_LEGACY5_USER",".");
sys ('mv',$TEMPLATE_LEGACY5_USER,"$name.bee");
sys ("./$name.bee");
}
sub want_current_kernel {
my ($kernel,$version,$build)=@_;
my $name="nvidia_linux-$kernel-$version-$build";
if (-e "$B/$name.bee") {
print "$B/$name.bee: already there\n";
return;
}
sys ('cp',"$B/$TEMPLATE_CURRENT_KERNEL",".");
sys ('mv',$TEMPLATE_CURRENT_KERNEL,"$name.bee");
sys ("./$name.bee");
}
sub want_legacy5_kernel {
my ($kernel,$version,$build)=@_;
my $name="nvidia_linux-$kernel-$version-$build";
if (-e "$B/$name.bee") {
print "$B/$name.bee: already there\n";
return;
}
sys ('cp',"$B/$TEMPLATE_LEGACY5_KERNEL",".");
sys ('mv',$TEMPLATE_LEGACY5_KERNEL,"$name.bee");
sys ("./$name.bee");
}
sub sys {
print(join(' ',@_),"\n");
system @_ and exit 1;
}
# http://www.nvidia.com/object/unix.html
our $kernel='4.7.2-99';
our $current="367.44"; # latest long live branch
our $legacy5="340.96"; # 340.xx serie
# increase build number if you want a rebuild:
want_current_user($current,0);
want_legacy5_user($legacy5,1);
want_current_kernel($kernel,$current,0);
want_legacy5_kernel($kernel,$legacy5,0);