Browse Source

* Added doincludes.pl, and let the desktop task use it to explode the

kde metapackage, so its entire dep list is put in the task, and if it does
     not ship with woody, we still will get kde. Closes: #135797
   * The same include mechanism should probably be used for the other
     metapackages, like the junior stuff (and X?). But not right now.
tags/debian_version_1_16
Joey Hess 19 years ago
parent
commit
d70183b4a2
4 changed files with 136 additions and 1 deletions
  1. +1
    -0
      Makefile
  2. +10
    -0
      debian/changelog
  3. +70
    -0
      doincludes.pl
  4. +55
    -1
      tasks/desktop

+ 1
- 0
Makefile View File

@@ -22,6 +22,7 @@ LINK = $(CC) $(CFLAGS) $(DEFS) -o
all: $(PROGRAM) $(TASKDESC)

$(TASKDESC): makedesc.pl $(DESCDIR)/*
perl doincludes.pl $(DESCDIR)
perl makedesc.pl $(DESCDIR) $(TASKDESC)

%.o: %.c


+ 10
- 0
debian/changelog View File

@@ -1,3 +1,13 @@
tasksel (1.16) unstable; urgency=medium

* Added doincludes.pl, and let the desktop task use it to explode the
kde metapackage, so its entire dep list is put in the task, and if it does
not ship with woody, we still will get kde. Closes: #135797
* The same include mechanism should probably be used for the other
metapackages, like the junior stuff (and X?). But not right now.

-- Joey Hess <joeyh@debian.org> Tue, 26 Feb 2002 11:17:36 -0500

tasksel (1.15) unstable; urgency=low

* Include sawfish-gnome in desktop task so gnome will have a WM.


+ 70
- 0
doincludes.pl View File

@@ -0,0 +1,70 @@
#!/usr/bin/perl
#
# doincludes directory
#
# Expands #include directives in files in the directory. This is used
# to let task package pull in the contents of metapackages, keeping the
# contents up-to-date, w/o actually pulling in the metapackages themselves,
# since some metapackages are rather prone to breakage near release time.

my $dir=shift or die "no directory specified\n";

my %depends;
{
local $/="\n\n";
if (! open (AVAIL, "/var/lib/dpkg/available")) {
warn "cannot real available file, so disabling lint check\n";
$dolint=0;
}
while (<AVAIL>) {
my ($package)=/Package:\s*(.*?)\n/;
my ($depends)=/Depends:\s*(.*?)\n/;
$depends{$package}=$depends;
}
close AVAIL;
}

use File::Find;
find(\&processfile, $dir);

sub processfile {
my $file=$_; # File::Find craziness.
return unless -f $file;
return unless $file =~ /^([-+_.a-z0-9]+)$/;
my @lines;
open (IN, $file) or die "$file: $!";
while (<IN>) {
if (/#\s*endinclude/) {
if (! $skipping) {
die "$file: #endinclude without #include";
}
$skipping=0;
}
push @lines, $_ unless $skipping;

if (/^#\s*include\s+(\w+)/) {
my $pkg=$1;
if ($skipping) {
die "$file: nested includes near $_\n";
}
if (! exists $depends{$pkg}) {
die "$file: #include $1 failed; no such package";
}
push @lines, "#Automatically added by doincludes.pl; do not edit.\n";
# Split deps and remove alternates and versioned
# deps. Include the metapackage on the list.
push @lines, map { s/[|(].*//; " $_\n" }
split(/,\s+/, $depends{$pkg}), $pkg;
$skipping=1;
}
}
close IN;
if ($skipping) {
die "$file: #include without #endinclude";
}
open (OUT, ">$file") or die "$file: $!";
print OUT @lines;
close OUT;
}

+ 55
- 1
tasks/desktop View File

@@ -22,9 +22,63 @@ Packages:
gnome-help
gdm
gnome-utils
kde
mozilla
mozilla-psm
menu
abiword
gimp1.2
#include kde
#Automatically added by doincludes.pl; do not edit.
kdelibs3
libarts
libkmid
kdebase
kdebase-audiolibs
kdebase-libs
libkonq3
konqueror
kate
konsole
kdebase-doc
kscreensaver
kdewallpapers
kuser
ksysv
kcron
kpackage
secpolicy
kghostview
kview
kmail
korn
korganizer
ark
kab
karm
kcalc
kcharselect
kdepasswd
kdf
kedit
kfind
khexedit
kjots
knotes
kpm
kpaint
kiconedit
kfract
ksnapshot
kruler
kdict
kdepim-libs
kdm
kit
knode
ksirc
koffice
knewsticker
ktimer
kcoloredit
kde
#endinclude

Loading…
Cancel
Save