diff options
author | Solomon Peachy <pizza@shaftnet.org> | 2024-04-17 17:59:58 -0400 |
---|---|---|
committer | Solomon Peachy <pizza@shaftnet.org> | 2024-04-17 22:10:52 -0400 |
commit | ac9003546f99250fc1b129edd804496f69c3ef1a (patch) | |
tree | c6fc3609cda0336c3779045dec7fd00773411ea3 /tools/release/manuals.pl | |
parent | c38aeb3fbc6b45e5a71af4506c79459ce9cb2121 (diff) | |
download | rockbox-ac9003546f99250fc1b129edd804496f69c3ef1a.tar.gz rockbox-ac9003546f99250fc1b129edd804496f69c3ef1a.zip |
release: Revamp release scripts
Covers bins, voices, manuals, fonts, and source tarballs.
Only thing remaining is build-info integration
Change-Id: I3a93fd87bbeb725fc8e1b38c5787e33fa00f3f37
Diffstat (limited to 'tools/release/manuals.pl')
-rwxr-xr-x | tools/release/manuals.pl | 36 |
1 files changed, 17 insertions, 19 deletions
diff --git a/tools/release/manuals.pl b/tools/release/manuals.pl index 923cacf747..61d298fd38 100755 --- a/tools/release/manuals.pl +++ b/tools/release/manuals.pl | |||
@@ -1,8 +1,7 @@ | |||
1 | #!/usr/bin/perl | 1 | #!/usr/bin/perl -w |
2 | require "./tools/builds.pm"; | ||
2 | 3 | ||
3 | $version="3.15"; | 4 | require "./tools/builds.pm"; |
4 | |||
5 | require "tools/builds.pm"; | ||
6 | 5 | ||
7 | my $verbose; | 6 | my $verbose; |
8 | if($ARGV[0] eq "-v") { | 7 | if($ARGV[0] eq "-v") { |
@@ -10,21 +9,16 @@ if($ARGV[0] eq "-v") { | |||
10 | shift @ARGV; | 9 | shift @ARGV; |
11 | } | 10 | } |
12 | 11 | ||
13 | my $doonly; | 12 | my $tag = $ARGV[0]; |
14 | if($ARGV[0]) { | 13 | my $version = $ARGV[1]; |
15 | $doonly = $ARGV[0]; | 14 | |
16 | print "only build $doonly\n" if($verbose); | 15 | my $outdir = "output/manuals"; |
17 | } | ||
18 | 16 | ||
19 | # made once for all targets | 17 | # made once for all targets |
20 | sub runone { | 18 | sub runone { |
21 | my ($dir)=@_; | 19 | my ($dir)=@_; |
22 | my $a; | 20 | my $a; |
23 | 21 | ||
24 | if($doonly && ($doonly ne $dir)) { | ||
25 | return; | ||
26 | } | ||
27 | |||
28 | mkdir "buildm-$dir"; | 22 | mkdir "buildm-$dir"; |
29 | chdir "buildm-$dir"; | 23 | chdir "buildm-$dir"; |
30 | print "Build in buildm-$dir\n" if($verbose); | 24 | print "Build in buildm-$dir\n" if($verbose); |
@@ -34,16 +28,18 @@ sub runone { | |||
34 | 28 | ||
35 | chdir ".."; | 29 | chdir ".."; |
36 | 30 | ||
37 | my $o="buildm-$dir/manual/rockbox-build.pdf"; | 31 | my $o="buildm-$dir/rockbox-$dir-$version.pdf"; |
38 | if (-f $o) { | 32 | if (-f $o) { |
39 | my $newo="output/rockbox-$dir-$version.pdf"; | 33 | my $newo="$outdir/rockbox-$dir-$version.pdf"; |
40 | system("mv $o $newo"); | 34 | system("mv $o $newo"); |
41 | print "moved $o to $newo\n" if($verbose); | 35 | print "moved $o to $newo\n" if($verbose); |
36 | } else { | ||
37 | print "buildm-$dir/rockbox-$dir-$version.pdf not found\n"; | ||
42 | } | 38 | } |
43 | 39 | ||
44 | $o="buildm-$dir/rockbox-manual.zip"; | 40 | $o="buildm-$dir/rockbox-manual.zip"; |
45 | if (-f $o) { | 41 | if (-f $o) { |
46 | my $newo="output/rockbox-$dir-$version-html.zip"; | 42 | my $newo="$outdir/rockbox-$dir-$version-html.zip"; |
47 | system("mv $o $newo"); | 43 | system("mv $o $newo"); |
48 | print "moved $o to $newo\n" if($verbose); | 44 | print "moved $o to $newo\n" if($verbose); |
49 | } | 45 | } |
@@ -64,18 +60,20 @@ sub buildit { | |||
64 | print "C: $c\n" if($verbose); | 60 | print "C: $c\n" if($verbose); |
65 | `$c`; | 61 | `$c`; |
66 | 62 | ||
67 | print "Run 'make'\n" if($verbose); | 63 | print "Run 'make manual'\n" if($verbose); |
68 | `make manual VERSION=$version 2>/dev/null`; | 64 | `make manual VERSION=$version 2>/dev/null`; |
69 | 65 | ||
70 | print "Run 'make manual-zip'\n" if($verbose); | 66 | print "Run 'make manual-zip'\n" if($verbose); |
71 | `make manual-zip VERSION=$version 2>/dev/null`; | 67 | `make manual-zip VERSION=$version 2>/dev/null`; |
72 | } | 68 | } |
73 | 69 | ||
70 | `git checkout $tag`; | ||
71 | |||
74 | # run make in tools first to make sure they're up-to-date | 72 | # run make in tools first to make sure they're up-to-date |
75 | `(cd tools && make ) >/dev/null 2>&1`; | 73 | `(cd tools && make ) >/dev/null 2>&1`; |
76 | 74 | ||
77 | for my $b (&stablebuilds) { | 75 | `mkdir -p $outdir`; |
78 | next if (length($builds{$b}{configname}) > 0); # no variants | ||
79 | 76 | ||
77 | for my $b (&usablebuilds) { | ||
80 | runone($b); | 78 | runone($b); |
81 | } | 79 | } |