diff --git a/CONF.sh b/CONF.sh index 7149423a..f0caeb45 100644 --- a/CONF.sh +++ b/CONF.sh @@ -87,3 +87,13 @@ export APTTMP=/ftp/tmp/apt # uncoment this to make build_all.sh try to build a simple CD image if # the proper official CD run does not work #ATTEMPT_FALLBACK=yes + +# We don't want certain packages to take up space on CD1... +#export EXCLUDE="$BASEDIR"/tasks/exclude-potato +# ...but they are okay for other CDs (UNEXCLUDEx == may be included on CD >= x) +#export UNEXCLUDE2="$BASEDIR"/tasks/unexclude-CD2-potato +# Any packages listed in EXCLUDE but not in any UNEXCLUDE will be +# excluded completely. + +# We also exclude some source packages +#export SRCEXCLUDE="$BASEDIR"/tasks/exclude-src-potato diff --git a/debian/CONF.sh b/debian/CONF.sh index 1e13473f..41cff5c2 100644 --- a/debian/CONF.sh +++ b/debian/CONF.sh @@ -75,3 +75,20 @@ export APTTMP=/home/ftp/tmp/apt # export MKISOFS=/usr/bin/mkhybrid # export MKISOFS_OPTS="-a -r -T" #For normal users # export MKISOFS_OPTS="-a -r -F . -T" #For symlink farmers + +# uncomment this to if you want to see more of what the Makefile is doing +#export VERBOSE_MAKE=1 + +# uncoment this to make build_all.sh try to build a simple CD image if +# the proper official CD run does not work +#ATTEMPT_FALLBACK=yes + +# We don't want certain packages to take up space on CD1... +#export EXCLUDE="$BASEDIR"/tasks/exclude-potato +# ...but they are okay for other CDs (UNEXCLUDEx == may be included on CD >= x) +#export UNEXCLUDE2="$BASEDIR"/tasks/unexclude-CD2-potato +# Any packages listed in EXCLUDE but not in any UNEXCLUDE will be +# excluded completely. + +# We also exclude some source packages +#export SRCEXCLUDE="$BASEDIR"/tasks/exclude-src-potato diff --git a/debian/changelog b/debian/changelog index 58036777..585a0de7 100644 --- a/debian/changelog +++ b/debian/changelog @@ -18,6 +18,8 @@ debian-cd (2.2.4) unstable; urgency=low * Some esthetic corrections to the Makefile. * Updated the popularity-contest file. * Redesigned and updated README to match new www.debian.org style. + * Added exclude feature for source packages and un-exclude feature + for binary packages. -- Raphael Hertzog Sat, 14 Apr 2001 22:48:19 +0200 diff --git a/tools/cds2src b/tools/cds2src index 96eed725..c978a823 100755 --- a/tools/cds2src +++ b/tools/cds2src @@ -132,6 +132,24 @@ while (defined($_ = )) { $/ = $oldrs; + +# Get the list of excluded packages +my $exclude = $ENV{'SRCEXCLUDE'} || "sorry-no-srcexclude"; +if (-e $exclude) { + open (EXCL, "< $exclude") || die "Can't open $exclude : $!\n"; + while (defined($_=)) { + chomp; + if (not exists $sources{$_}) { + msg(1, "INIT: Source '$_' is in srcexcluded but " . + "doesn't exist. Ignored.\n"); + next; + } + $excluded{$_} = 'user choice'; + } + close EXCL; +} + + # Get the list of included packages my @list = (); my $i = 1; @@ -287,6 +305,7 @@ sub add_src { $total_size += $size; add_to_cd ($cd, \@files); + msg(1, " size: $size\n"); $included{$src} = $cd; } diff --git a/tools/list2cds b/tools/list2cds index e5f66a5c..fd0e94c3 100755 --- a/tools/list2cds +++ b/tools/list2cds @@ -83,8 +83,8 @@ if (-e $exclude) { while (defined($_=)) { chomp; if (not exists $packages{$_}) { - msg(1, "INIT: Package '$_' is in excluded but" . - "doesn't exist. Ignored."); + msg(1, "INIT: Package '$_' is in excluded but " . + "doesn't exist. Ignored.\n"); next; } $excluded{$_} = 'user choice'; @@ -461,6 +461,9 @@ sub add_package { # New limit $limit = $ENV{"SIZELIMIT$cd"} || $deflimit; msg(2, "Limit for CD $cd is $limit.\n"); + + # Unexclude packages + unexclude ($cd); } msg(2, " \$cd_size = $cd_size, \$size = $size\n"); @@ -636,3 +639,23 @@ sub add_to_cd { push(@{$cds{$cd}}, @{$ref}); } +# Unexclude packages before given CD is started +sub unexclude { + my $cd = shift; + my $unexclude = $ENV{"UNEXCLUDE$cd"} || "$list.unexclude$cd"; + + if (-e $unexclude) { + open (UNEXCL, "< $unexclude") || die "Can't open $unexclude : $!\n"; + while (defined($_=)) { + chomp; + if (not exists $packages{$_}) { + msg(1, "Package '$_' is in unexcluded but " . + "doesn't exist. Ignored.\n"); + next; + } + $excluded{$_} = 0; + msg(1, "Unexcluding package '$_'\n"); + } + close UNEXCL; + } +}