Last change
on this file since 30665 was 29536, checked in by Jeremy Symon, 10 years ago |
Working on a more flexible generation system. Only working for pacman so far, so if you want to generate packages you'll need to check out an old revision. The reason behind this change is that I discovered that the greenstone user database really needs to be owned by the tomcat user rather than root (things such as edit mode don't work properly otherwise), and setting file ownership requires .install files, which was not really possible with the existing system. At this point it would certainly have been faster to just write all the scripts by hand, but this way I get to learn perl.
|
-
Property svn:executable
set to
*
|
File size:
841 bytes
|
Line | |
---|
1 | #!/usr/bin/env perl
|
---|
2 |
|
---|
3 | # Generates Makefiles for different systems and packages
|
---|
4 |
|
---|
5 | use strict;
|
---|
6 | use warnings;
|
---|
7 | use utf8;
|
---|
8 | use File::Basename;
|
---|
9 | use lib 'perllib';
|
---|
10 | use Greenstone::Helpers;
|
---|
11 | use Greenstone::Package;
|
---|
12 |
|
---|
13 | my $USAGE = "Usage: " . basename($0) . " <distros> <packages>
|
---|
14 | distros: A comma separated list of the distros defined in distros/
|
---|
15 | Or 'all' (for all distros)
|
---|
16 | packages: A comma separated list of the packages defined in packages/
|
---|
17 | Or 'all' (for all packages)
|
---|
18 | ";
|
---|
19 |
|
---|
20 | $#ARGV == 1 or die $USAGE;
|
---|
21 |
|
---|
22 | my @distros = lsfiles "distros", shift;
|
---|
23 | my @packages = lsfiles "packages", shift;
|
---|
24 |
|
---|
25 | for my $distro (@distros) {
|
---|
26 | print $distro, "\n";
|
---|
27 | for my $package (@packages) {
|
---|
28 | print " - ", $package, "\n";
|
---|
29 | makepkg (
|
---|
30 | package => $package,
|
---|
31 | distro => $distro
|
---|
32 | );
|
---|
33 | }
|
---|
34 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.