1 --- util-vserver-0.30.216-r2837.orig/distrib/defaults/poldek/poldek.conf 1970-01-01 01:00:00.000000000 +0100
2 +++ util-vserver-0.30.216-r2837/distrib/defaults/poldek/poldek.conf 2009-06-22 17:48:26.000000000 +0200
4 +# poldek configuration file.
10 +choose equivalents manually = yes
11 +unique package names = yes
14 +ignore = kernel* udev devfs
15 --- util-vserver-0.30.216-r2837.orig/distrib/Makefile.am 2009-06-22 17:36:52.000000000 +0200
16 +++ util-vserver-0.30.216-r2837/distrib/Makefile.am 2009-06-22 17:49:36.000000000 +0200
20 defaults/apt/apt.conf \
21 + defaults/poldek/poldek.conf \
22 template/initpost template/initpre \
23 rh9/apt/rpmpriorities rh9/pkgs/01 rh9/pkgs/02 \
24 fc1/apt/rpmpriorities fc1/pkgs/01 fc1/pkgs/02 \
26 suse91/apt/rpmpriorities suse91/pkgs/01 suse91/pkgs/02 \
28 gentoo/init-vserver.sh gentoo/net.vserver \
29 - gentoo/reboot.sh gentoo/shutdown.sh
30 + gentoo/reboot.sh gentoo/shutdown.sh\
31 + pld-ac/pkgs/01 pld-ac/rpm/macros \
32 + pld-th/pkgs/01 pld-th/rpm/macros \
33 + pld-ti/pkgs/01 pld-ti/rpm/macros
35 nobase_confdistrib_DATA = rh9/apt/sources.list \
36 fc1/apt/sources.list \
38 fc5/apt/sources.list \
39 fc6/apt/sources.list \
41 - suse91/apt/sources.list
42 + suse91/apt/sources.list \
43 + pld-ac/poldek/repos.d/pld.conf \
44 + pld-th/poldek/repos.d/pld.conf \
45 + pld-ti/poldek/repos.d/pld.conf
47 AM_INSTALLCHECK_STD_OPTIONS_EXEMPT \
48 = $(nobase_distrib_SCRIPTS)
49 --- util-vserver-0.30.216-r2837.orig/distrib/pld-ac/pkgs/01 1970-01-01 01:00:00.000000000 +0100
50 +++ util-vserver-0.30.216-r2837/distrib/pld-ac/pkgs/01 2009-06-22 17:48:26.000000000 +0200
58 --- util-vserver-0.30.216-r2837.orig/distrib/pld-ac/poldek/repos.d/pld.conf 1970-01-01 01:00:00.000000000 +0100
59 +++ util-vserver-0.30.216-r2837/distrib/pld-ac/poldek/repos.d/pld.conf 2009-06-22 17:48:26.000000000 +0200
62 +# PLD Linux Distribution <http://www.pld-linux.org/>.
64 +# specify our packages architecture
67 +# main PLD-site for often changed things:
68 +_pld_main_prefix = ftp://ftp.ac.pld-linux.org/dists/ac
71 +## You can use them if you have better connection there
73 +#_prefix = ftp://ftp.task.pld-linux.org/dists/ac
74 +#_prefix = %{_pld_main_prefix}
75 +_prefix = %{_pld_main_prefix}
83 +path = %{_prefix}/PLD/%{_arch}/PLD/RPMS/
85 +# buggy deps -- use one from updates instead
86 +ignore = msmtp-sendmail*
92 +path = %{_prefix}/updates/%{_arch}/
99 +path = %{_prefix}/supported/%{_arch}/
107 +path = %{_pld_main_prefix}/ready/%{_arch}/
114 +path = %{_pld_main_prefix}/test/%{_arch}/
117 --- util-vserver-0.30.216-r2837.orig/distrib/pld-ac/rpm/macros 1970-01-01 01:00:00.000000000 +0100
118 +++ util-vserver-0.30.216-r2837/distrib/pld-ac/rpm/macros 2009-06-22 17:48:26.000000000 +0200
120 +# Because of https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=52725
121 +# you have to use at least one language beside 'C'
122 +%_install_langs C:en:pl
123 +%_netsharedpath /dev:/proc
126 --- util-vserver-0.30.216-r2837.orig/distrib/pld-th/pkgs/01 1970-01-01 01:00:00.000000000 +0100
127 +++ util-vserver-0.30.216-r2837/distrib/pld-th/pkgs/01 2009-06-22 17:48:26.000000000 +0200
135 --- util-vserver-0.30.216-r2837.orig/distrib/pld-th/poldek/repos.d/pld.conf 1970-01-01 01:00:00.000000000 +0100
136 +++ util-vserver-0.30.216-r2837/distrib/pld-th/poldek/repos.d/pld.conf 2009-06-22 17:48:26.000000000 +0200
138 +# PLD Linux Distribution <http://www.pld-linux.org/>.
141 +_prefix = ftp://ftp.th.pld-linux.org/dists/th
143 +## You can use them if you have better connection there
145 +#_prefix = ftp://ftp.task.pld-linux.org/dists/th
153 +path = %{_prefix}/PLD/%{_arch}/RPMS/
158 +path = %{_prefix}/PLD/noarch/RPMS/
163 +#path = %{_prefix}/updates/%{_arch}/RPMS/
168 +#path = %{_prefix}/updates/noarch/RPMS/
172 +#name = th-supported
173 +#path = %{_prefix}/supported/%{_arch}/
179 +path = %{_prefix}/ready/%{_arch}/RPMS/
186 +path = %{_prefix}/ready/noarch/RPMS/
193 +path = %{_prefix}/test/%{_arch}/RPMS/
200 +path = %{_prefix}/test/noarch/RPMS/
203 --- util-vserver-0.30.216-r2837.orig/distrib/pld-th/rpm/macros 1970-01-01 01:00:00.000000000 +0100
204 +++ util-vserver-0.30.216-r2837/distrib/pld-th/rpm/macros 2009-06-22 17:48:26.000000000 +0200
206 +# Because of https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=52725
207 +# you have to use at least one language beside 'C'
208 +%_install_langs C:en:pl
209 +%_netsharedpath /dev:/proc
212 --- util-vserver-0.30.216-r2837.orig/distrib/pld-ti/pkgs/01 1970-01-01 01:00:00.000000000 +0100
213 +++ util-vserver-0.30.216-r2837/distrib/pld-ti/pkgs/01 2009-06-22 17:48:26.000000000 +0200
221 --- util-vserver-0.30.216-r2837.orig/distrib/pld-ti/poldek/repos.d/pld.conf 1970-01-01 01:00:00.000000000 +0100
222 +++ util-vserver-0.30.216-r2837/distrib/pld-ti/poldek/repos.d/pld.conf 2009-06-22 17:48:26.000000000 +0200
225 +# Unofficial version of PLD Linux Distribution
226 +# http://www.pld-linux.org/Titanium
229 +_prefix = ftp://ftp.titanium.pld-linux.org/branches/titanium
236 +path = %{_prefix}/PLD/%{_arch}/RPMS/
241 +path = %{_prefix}/PLD/noarch/RPMS/
245 +name = titanium-ready
246 +path = %{_prefix}/ready/%{_arch}/RPMS/
252 +name = titanium-ready
253 +path = %{_prefix}/ready/noarch/RPMS/
259 +name = titanium-test
260 +path = %{_prefix}/test/%{_arch}/RPMS/
266 +name = titanium-test
267 +path = %{_prefix}/test/noarch/RPMS/
270 --- util-vserver-0.30.216-r2837.orig/distrib/pld-ti/rpm/macros 1970-01-01 01:00:00.000000000 +0100
271 +++ util-vserver-0.30.216-r2837/distrib/pld-ti/rpm/macros 2009-06-22 17:48:26.000000000 +0200
273 +# Because of https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=52725
274 +# you have to use at least one language beside 'C'
275 +%_install_langs C:en:pl
276 +%_netsharedpath /dev:/proc
279 --- util-vserver-0.30.216-r2837.orig/scripts/functions 2009-06-22 17:36:35.000000000 +0200
280 +++ util-vserver-0.30.216-r2837/scripts/functions 2009-06-22 17:48:26.000000000 +0200
285 +function _pkgSetVarsPoldek
287 + if test -n "$PKGDIR"; then
288 + findDir POLDEKETCDIR $PKGDIR/poldeketc $PKGDIR/base/poldek/etc /etc/poldek
289 + findDir POLDEKCACHEDIR $PKGDIR/poldek-cache $PKGDIR/base/poldek/cache
291 + findDir POLDEKETCDIR "$VDIR"/etc/poldek /etc/poldek
292 + findDir POLDEKCACHEDIR "$VDIR"/var/tmp/poldek-cache
295 + findFile POLDEK_CONFIG "$POLDEKETCDIR"/poldek.conf ""
296 + test -z "$POLDEK_CONFIG" || export POLDEK_CONFIG
300 function _pkgMountBase
303 rpm) _pkgSetVarsRPM;;
304 apt) _pkgSetVarsApt;;
305 yum) _pkgSetVarsYum;;
306 + poldek) _pkgSetVarsPoldek;;
307 *) echo "Unknown packaging flavor" >&2; exit 1;;
312 elif test -e "$_pgs_vdir"/etc/mandrake-release; then
314 + elif test -e "$_pgs_vdir"/etc/pld-release; then
316 elif test -e "$_pgs_vdir"/etc/debian_version; then
318 elif test -e "$_pgs_vdir"/etc/SuSE-release; then
320 test -n "$have_yum" && return 0 || return 1
323 +## Usage: pkgmgmt.isPoldekAvailable <cfgdir> <vdir> [<is-internal>]
324 +function pkgmgmt.isPoldekAvailable
328 + local is_internal="$3"
330 + local have_poldek i
331 + if test -n "$is_internal"; then
333 + test -d "$cfgdir"/base/poldek -o -d "$cfgdir"/poldeketc || have_poldek=
336 + for i in /bin /usr/bin /usr/local/bin; do
337 + test ! -x "$vdir$i"/poldek || { have_poldek=1; break; }
341 + test -n "$have_poldek" && return 0 || return 1
345 function vshelper.doSanityCheck
347 --- util-vserver-0.30.216-r2837.orig/scripts/Makefile-files 2009-06-22 17:36:35.000000000 +0200
348 +++ util-vserver-0.30.216-r2837/scripts/Makefile-files 2009-06-22 17:48:26.000000000 +0200
350 scripts/vapt-get-worker \
351 scripts/vrpm-worker \
352 scripts/vyum-worker \
353 + scripts/vpoldek-worker \
354 scripts/vrpm-preload \
355 scripts/save_s_context \
356 scripts/vservers.grabinfo.sh \
358 scripts/vserver-build.template \
359 scripts/vserver-build.rsync \
360 scripts/vserver-build.clone \
361 + scripts/vserver-build.poldek \
362 scripts/vserver-build.functions \
363 scripts/vserver-build.functions.apt \
364 scripts/vserver-build.functions.rpm \
365 scripts/vserver-build.functions.pkgmgmt \
366 scripts/vserver-build.functions.yum \
367 + scripts/vserver-build.functions.poldek \
368 scripts/vserver-setup.functions \
369 scripts/vserver.functions \
370 scripts/vserver.start \
372 scripts_pkglib_src_SCRPTS = scripts/pkgmgmt \
373 scripts/vapt-get-worker \
375 + scripts/vpoldek-worker \
376 scripts/vrpm-worker \
377 scripts/vrpm-preload \
378 scripts/start-vservers \
380 scripts_sbin_src_PRGS = scripts/chbind \
384 scripts/vdispatch-conf \
387 --- util-vserver-0.30.216-r2837.orig/scripts/pkgmgmt 2009-06-22 17:36:34.000000000 +0200
388 +++ util-vserver-0.30.216-r2837/scripts/pkgmgmt 2009-06-22 17:48:26.000000000 +0200
393 - (RH) pkgs=$(vrpm "$1" -- -q --qf '---%{NAME}---\n' rpm apt yum "${YUM_RELEASEPKGS[@]}")
394 + (RH) pkgs=$(vrpm "$1" -- -q --qf '---%{NAME}---\n' rpm apt yum poldek "${YUM_RELEASEPKGS[@]}")
395 hasSubstring "$pkgs" ---rpm--- || {
397 * The vserver does not seem to have the 'rpm' package which is required
402 - hasSubstring "$pkgs" ---apt--- ---yum--- || {
403 + hasSubstring "$pkgs" ---apt--- ---yum--- ---poldek--- || {
405 -* The vserver does not seem to have a depsolver like 'apt' or 'yum'
406 +* The vserver does not seem to have a depsolver like 'apt', 'yum' or 'poldek'
407 installed. It is suggested to install such a program before setting
408 up internal package management."
410 @@ -368,6 +368,131 @@
414 +function processVserver_PLD()
417 + local is_internalize=$2
421 + cfgdir=$($_VSERVER_INFO "$vserver" APPDIR pkgmgmt) || \
422 + cfgdir=$($_VSERVER_INFO "$vserver" APPDIR)/pkgmgmt
424 + ## Figure out the environment....
425 + pkgmgmt.isPoldekAvailable "$cfgdir" "$vdir" "$is_internalize" || have_poldek=
427 + local POLDEKETCDIR=
428 + local POLDEKCACHEDIR=
432 + ## Create directories and assign variables where configuration
433 + ## can/will be found on the host
434 + if test -n "$is_internalize"; then
435 + verifyInternalPackages "$vserver" RH || test -n "$IS_FORCE" ||
437 +Can not continue; use '--force' to override this check"
439 + pushd "$vdir" >/dev/null
441 + test ! -L var/lib/rpm || {
442 + $_EXEC_CD /var/lib $_RM rpm &&
443 + $_EXEC_CD /var/lib $_MKDIR -m755 rpm &&
444 + $_EXEC_CD /var/lib $_CHOWN rpm:rpm rpm ||
446 + } </dev/null 2>/dev/null
448 + for i in var/tmp/poldek-cache etc/rpm etc/poldek; do
450 + $_EXEC_CD /$(dirname "$i") $_MKDIR -m755 $(basename "$i") || :
455 + if test -n "$have_poldek"; then
456 + findDir POLDEKETCDIR "$cfgdir"/poldeketc "$cfgdir"/base/poldek/etc /etc/poldek
459 + findDir RPMETCDIR "$cfgdir"/rpmetc "$cfgdir"/base/rpm/etc /etc/rpm /
460 + findDir RPMSTATEDIR "$cfgdir"/rpmstate "$cfgdir"/base/rpm/state
462 + mkdir -m755 -p "$cfgdir"
465 + if test -n "$have_poldek"; then
466 + findDir POLDEKETCDIR "$cfgdir"/poldeketc "$cfgdir"/base/poldek/etc /
467 + findDir POLDEKCACHEDIR "$cfgdir"/poldek-cache "$cfgdir"/base/poldek/cache /
469 + test "$POLDEKETCDIR" != / || POLDEKETCDIR=$cfgdir/base/poldek/etc
470 + test "$POLDEKCACHEDIR" != / || POLDEKCACHEDIR=$cfgdir/base/poldek/cache
472 + test -d "$cfgdir"/poldeketc -a -d "$cfgdir"/poldek-cache || need_base=1
475 + findDir RPMETCDIR "$cfgdir"/rpmetc "$cfgdir"/base/rpm/etc /
476 + findDir RPMSTATEDIR "$cfgdir"/rpmstate "$cfgdir"/base/rpm/state /
478 + test "$RPMETCDIR" != / || RPMETCDIR=$cfgdir/base/rpm/etc
479 + test "$RPMSTATEDIR" != / || RPMSTATEDIR=$cfgdir/base/rpm/state
481 + test -d "$cfgdir"/rpmetc -a -d "$cfgdir"/rpmstate || need_base=1
482 + test ! -e "$cfgdir"/base || need_base=
484 + test -z "$need_base" || ln -s "$PKGCFGDIR" "$cfgdir"/base
486 + mkdir -m755 -p "$PKGCFGDIR"
487 + _createDirs "$POLDEKETCDIR" "$POLDEKCACHEDIR" \
488 + "$RPMETCDIR" "$RPMSTATEDIR"
491 + ## Copy the files...
492 + if test -n "$is_internalize"; then
493 + if test -n "$have_poldek"; then
494 + _copySecure "$vdir" "$POLDEKETCDIR" /etc/poldek
495 + pushd "$vdir" >/dev/null
496 + _hashAuto /etc/poldek.conf '/'
500 + _copySecure "$vdir" "$RPMETCDIR" /etc/rpm
501 + _copySecure "$vdir" "$RPMSTATEDIR" /var/lib/rpm
503 + pushd "$vdir" >/dev/null
504 + ## remove %_dbpath settings
505 + _substFile /etc/rpm/macros '/^%_dbpath[ \t].*/D'
508 + if test -n "$have_poldek"; then
509 + _copySecureRev "$vdir" /etc/poldek "$POLDEKETCDIR"
510 + _unhashAuto "$POLDEKETCDIR"/poldek.conf '/'
513 + _copySecureRev "$vdir" /etc/rpm "$RPMETCDIR"
514 + _copySecureRev "$vdir" /var/lib/rpm "$RPMSTATEDIR"
516 + echo -e "%_dbpath\t\t$rpmdb_mntpoint" >>$RPMETCDIR/macros
520 + if test -n "$is_internalize"; then
523 + tmpdir=$($_MKTEMPDIR -p /var/tmp pgmgmt.XXXXXX)
524 + trap "$_RM -rf $tmpdir" EXIT
525 + pushd "$vdir" >/dev/null
526 + $_EXEC_CD /var/lib $_MV rpm $tmpdir/
527 + $_EXEC_CD /var/lib $_LN_S "$rpmdb_mntpoint" rpm
532 + if test -n "$is_internalize"; then
533 + $_TOUCH "$cfgdir"/internal
535 + $_RM -f "$cfgdir"/internal
539 function processVserver_Debian()
545 (redhat|mandrake) processVserver_RH "$vserver" "$IS_INTERNALIZE";;
546 + (pld) processVserver_PLD "$vserver" "$IS_INTERNALIZE";;
547 (debian) processVserver_Debian "$vserver" "$IS_INTERNALIZE";;
549 echo $"Vserver style '$style' is not supported for packagemanagment" >&2
550 --- util-vserver-0.30.216-r2837.orig/scripts/util-vserver-vars.pathsubst 2009-06-22 17:36:34.000000000 +0200
551 +++ util-vserver-0.30.216-r2837/scripts/util-vserver-vars.pathsubst 2009-06-22 17:48:26.000000000 +0200
553 _LIB_VSERVER_BUILD_FUNCTIONS_RPM="$__PKGLIBDIR/vserver-build.functions.rpm"
554 _LIB_VSERVER_BUILD_FUNCTIONS_YUM="$__PKGLIBDIR/vserver-build.functions.yum"
555 _LIB_VSERVER_BUILD_FUNCTIONS_PKGMGMT="$__PKGLIBDIR/vserver-build.functions.pkgmgmt"
556 +_LIB_VSERVER_BUILD_FUNCTIONS_POLDEK="$__PKGLIBDIR/vserver-build.functions.poldek"
557 _LISTDEVIP="$__LEGACYDIR/listdevip"
558 _LOCKFILE="$__PKGLIBDIR/lockfile"
559 _MASK2PREFIX="$__PKGLIBDIR/mask2prefix"
561 _VUNIFY="$__PKGLIBDIR/vunify"
562 _VYUM="$__SBINDIR/vyum"
563 _VYUM_WORKER="$__PKGLIBDIR/vyum-worker"
564 +_VPOLDEK="$__SBINDIR/vpoldek"
565 +_VPOLDEK_WORKER="$__PKGLIBDIR/vpoldek-worker"
569 --- util-vserver-0.30.216-r2837.orig/scripts/vpkg 2009-06-22 17:36:34.000000000 +0200
570 +++ util-vserver-0.30.216-r2837/scripts/vpkg 2009-06-22 17:48:26.000000000 +0200
579 + ## rpm outputs sometimes '(contains no files)', so return
580 + ## only the valid output
582 + rpm_param=( -qac --pipe "$_SED '\!^/!p;d'" );;
584 + rpm_param=( -Uvh "$@" )
585 + poldek_param=( --install -v "$@" )
589 + if test -n "$is_external"; then
591 + test -d "$cfgdir"/base/poldek -o -d "$cfgdir"/poldeketc || have_poldek=
594 + for i in /bin /usr/bin /usr/local/bin; do
595 + test ! -x "$vdir$i"/poldek || { have_poldek=1; break; }
599 + if test -n "$is_external"; then
600 + if test "$have_poldek" -a "$poldek_param"; then
601 + cmd=( "$_VPOLDEK" "$vserver" -- "${poldek_param[@]}" )
603 + cmd=( "$_VRPM" "$vserver" -- "${rpm_param[@]}" )
606 + if test "$have_poldek" -a "$poldek_param"; then
607 + cmd=( "$_VSERVER" --silent "$vserver" exec poldek "${poldek_param[@]}" )
609 + cmd=( "$_VSERVER" --silent "$vserver" exec rpm "${rpm_param[@]}" )
616 --- util-vserver-0.30.216-r2837.orig/scripts/vpoldek 1970-01-01 01:00:00.000000000 +0100
617 +++ util-vserver-0.30.216-r2837/scripts/vpoldek 2009-06-22 17:48:26.000000000 +0200
622 +# Copyright (C) 2007 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de>
624 +# This program is free software; you can redistribute it and/or modify
625 +# it under the terms of the GNU General Public License as published by
626 +# the Free Software Foundation; version 2 of the License.
628 +# This program is distributed in the hope that it will be useful,
629 +# but WITHOUT ANY WARRANTY; without even the implied warranty of
630 +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
631 +# GNU General Public License for more details.
633 +# You should have received a copy of the GNU General Public License
634 +# along with this program; if not, write to the Free Software
635 +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
637 +: ${UTIL_VSERVER_VARS:=/usr/lib/util-vserver/util-vserver-vars}
638 +test -e "$UTIL_VSERVER_VARS" || {
639 + echo $"Can not find util-vserver installation (the file '$UTIL_VSERVER_VARS' would be expected); aborting..." >&2
642 +. "$UTIL_VSERVER_VARS"
649 +$"Usage: $0 <vserver-name>* [--all] -- <params>+
651 +Report bugs to <$PACKAGE_BUGREPORT>."
655 +function showVersion()
658 +$"vpoldek $PACKAGE_VERSION -- poldek for vservers
659 +This program is part of $PACKAGE_STRING
661 +Copyright (C) 2007 Enrico Scholz
662 +This program is free software; you may redistribute it under the terms of
663 +the GNU General Public License. This program has absolutely no warranty."
667 +tmp=$(getopt -o +q --long help,version,debug,quiet,all -n "$0" -- "$@") || exit 1
670 +declare -a send_through poldek_opts
674 + (--help) showHelp $0 ;;
675 + (--version) showVersion ;;
676 + (--debug) send_through=( "${send_through[@]}" "$1" ); set -x;;
677 + (--quiet|-q) send_through=( "${send_through[@]}" "$1" );;
678 + (--all) poldek_opts=( "${poldek_opts[@]}" "$1" );;
679 + (--) shift; break;;
680 + (*) echo $"vpoldek: internal error; arg=='$1'" >&2; exit 1;;
685 +VSOMETHING_TITLE=vpoldek
686 +VSOMETHING_WORKER=$_VPOLDEK_WORKER
687 +VSOMETHING_PKGMGMT=1
689 +export VSOMETHING_TITLE VSOMETHING_WORKER VSOMETHING_PKGMGMT
691 +test ${#poldek_opts[@]} -eq 0 || poldek_opts=( "${poldek_opts[@]}" -- )
692 +exec $_VSOMETHING "${send_through[@]}" poldek "${poldek_opts[@]}" "$@"
693 --- util-vserver-0.30.216-r2837.orig/scripts/vpoldek-worker 1970-01-01 01:00:00.000000000 +0100
694 +++ util-vserver-0.30.216-r2837/scripts/vpoldek-worker 2009-06-22 17:48:26.000000000 +0200
699 +# Copyright (C) 2003 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de>
701 +# This program is free software; you can redistribute it and/or modify
702 +# it under the terms of the GNU General Public License as published by
703 +# the Free Software Foundation; version 2 of the License.
705 +# This program is distributed in the hope that it will be useful,
706 +# but WITHOUT ANY WARRANTY; without even the implied warranty of
707 +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
708 +# GNU General Public License for more details.
710 +# You should have received a copy of the GNU General Public License
711 +# along with this program; if not, write to the Free Software
712 +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
716 +: ${UTIL_VSERVER_VARS:=/usr/lib/util-vserver/util-vserver-vars}
717 +test -e "$UTIL_VSERVER_VARS" || {
718 + echo $"Can not find util-vserver installation (the file '$UTIL_VSERVER_VARS' would be expected); aborting..." >&2
721 +. "$UTIL_VSERVER_VARS"
728 +pkgInit "$vserver" rpm poldek
730 +test -z "$_POLDEK" || {
731 + warning $"The environment variable \$_POLDEK is not supported anymore; please use \$POLDEK instead of"
732 + ${POLDEK:=$_POLDEK}
735 +exec ${_POLDEK:-poldek} \
737 + --cachedir=$POLDEKCACHEDIR \
738 + --conf=$POLDEK_CONFIG \
739 + --pmcmd=$RPM_BINARY \
741 --- util-vserver-0.30.216-r2837.orig/scripts/vserver-build 2009-06-22 17:36:34.000000000 +0200
742 +++ util-vserver-0.30.216-r2837/scripts/vserver-build 2009-06-22 17:48:26.000000000 +0200
744 yum ... -- -d <distribution>
745 ... installs the base-packages of the given distribution with
747 + poldek ... -- -d <distribution>
748 + ... installs the base-packages of the given distribution with
750 rpm ... -- [-d <distribution>] --empty|([--force] [--nodeps] <manifest>)+
751 ... installs lists of rpm-packages
752 skeleton ... -- [<cmd> <args>*]
756 (xlegacy) exec $_VSERVER_LEGACY "$VSERVER_NAME" build "$@" ;;
757 - (xapt-rpm|xcopy|xskeleton|xdebootstrap|xyum|xrpm|xtemplate|xfai|xrsync|xclone)
758 + (xapt-rpm|xcopy|xskeleton|xdebootstrap|xyum|xrpm|xtemplate|xfai|xrsync|xclone|xpoldek)
759 . $__PKGLIBDIR/vserver-build.$method
761 (x) panic $"No build-method specified";;
762 --- util-vserver-0.30.216-r2837.orig/scripts/vserver-build.functions 2009-06-22 17:36:35.000000000 +0200
763 +++ util-vserver-0.30.216-r2837/scripts/vserver-build.functions 2009-06-22 17:48:26.000000000 +0200
765 elif test -e /etc/slackware-version; then
766 set -- $(cat /etc/slackware-version)
767 DISTRIBUTION=slackware$2
768 + elif test -e /etc/pld-release; then
771 + set -- $(cat /etc/pld-release)
772 + DISTRIBUTION=pld-$(echo $2 | tr A-Z a-z)
774 elif test -n "$1"; then
777 --- util-vserver-0.30.216-r2837.orig/scripts/vserver-build.functions.poldek 1970-01-01 01:00:00.000000000 +0100
778 +++ util-vserver-0.30.216-r2837/scripts/vserver-build.functions.poldek 2009-06-22 17:48:26.000000000 +0200
782 +# Copyright (C) 2003 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de>
784 +# This program is free software; you can redistribute it and/or modify
785 +# it under the terms of the GNU General Public License as published by
786 +# the Free Software Foundation; version 2 of the License.
788 +# This program is distributed in the hope that it will be useful,
789 +# but WITHOUT ANY WARRANTY; without even the implied warranty of
790 +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
791 +# GNU General Public License for more details.
793 +# You should have received a copy of the GNU General Public License
794 +# along with this program; if not, write to the Free Software
795 +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
797 +function poldek.installBasePackages
802 + test "$dir" != / || return 0
803 + for filelist in "$dir"/*; do
804 + isRegularFile "$filelist" || continue
806 + local can_fail=false
807 + local flags='--install'
809 + set -- $(<$filelist)
810 + while test "$#" -gt 0; do
812 + --reinstall) flags='--reinstall';;
813 + --can-fail) can_fail=true;;
818 + "$_VPOLDEK" "$name" -- $flags $* || $can_fail
822 +function poldek.initVariables
824 + findFile POLDEKCONFDEFAULT \
825 + "$__CONFDIR/.distributions/$DISTRIBUTION/poldek/poldek.conf" \
826 + "$__CONFDIR/.defaults/apps/pkgmgmt/poldek/poldek.conf" \
827 + "$__DISTRIBDIR/$DISTRIBUTION/poldek/poldek.conf" \
828 + "$__DISTRIBDIR/defaults/poldek/poldek.conf" \
832 +function poldek.initFilesystem
834 + mkdir -p "$PKGCFGDIR"/poldek/etc/repos.d
836 + $_LN_S "$__CONFDIR"/.defaults/cachebase/poldek "$PKGCFGDIR"/poldek/cache
838 + populateDirectory "$PKGCFGDIR/poldek/etc" \
839 + "$__DISTRIBDIR/defaults/poldek" \
840 + "$__DISTRIBDIR/$DISTRIBUTION/poldek" \
841 + "$__CONFDIR/.distributions/$DISTRIBUTION/poldek"
843 + populateDirectory "$PKGCFGDIR/poldek/etc/repos.d" \
844 + "$__DISTRIBDIR/defaults/poldek/repos.d" \
845 + "$__DISTRIBDIR/$DISTRIBUTION/poldek/repos.d" \
846 + "$__CONFDIR/.distributions/$DISTRIBUTION/poldek/repos.d"
848 + if [ -n "$SETUP_MACHINE" ]; then
849 + say "Using $SETUP_MACHINE as machine"
850 + sed -i -e "s#^\(_arch\s*\)=.*#\1= $SETUP_MACHINE#" "$PKGCFGDIR"/poldek/etc/repos.d/*.conf
853 + if [ -n "$MIRROR" ]; then
854 + say "Using $MIRROR as mirror URL"
855 + sed -i -e "s#^\(_prefix\s*\)=.*#\1= $MIRROR#" "$PKGCFGDIR"/poldek/etc/repos.d/*.conf
858 +# test -z "$POLDEKCONFDEFAULT" || \
859 +# $_LN_S "$POLDEKCONFDEFAULT" "$PKGCFGDIR"/poldek/etc/
861 --- util-vserver-0.30.216-r2837.orig/scripts/vserver-build.poldek 1970-01-01 01:00:00.000000000 +0100
862 +++ util-vserver-0.30.216-r2837/scripts/vserver-build.poldek 2009-06-22 17:48:26.000000000 +0200
866 +# Copyright (C) 2003 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de>
868 +# This program is free software; you can redistribute it and/or modify
869 +# it under the terms of the GNU General Public License as published by
870 +# the Free Software Foundation; version 2 of the License.
872 +# This program is distributed in the hope that it will be useful,
873 +# but WITHOUT ANY WARRANTY; without even the implied warranty of
874 +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
875 +# GNU General Public License for more details.
877 +# You should have received a copy of the GNU General Public License
878 +# along with this program; if not, write to the Free Software
879 +# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
881 +tmp=$(getopt -o +d:,m: --long debug -n "$0" -- "$@") || exit 1
884 +. "$_LIB_VSERVER_BUILD_FUNCTIONS_RPM"
885 +. "$_LIB_VSERVER_BUILD_FUNCTIONS_POLDEK"
886 +. "$_LIB_VSERVER_BUILD_FUNCTIONS_PKGMGMT"
890 + (-d) DISTRIBUTION=$2; shift;;
891 + (-m) MIRROR=$2; shift;;
893 + (--) shift; break ;;
894 + (*) echo "vserver-build.poldek: internal error: unrecognized option '$1'" >&2
905 +pkgmgmt.initVariables
907 +poldek.initVariables
909 +base.initFilesystem "$OPTION_FORCE"
910 +pkgmgmt.initFilesystem "$OPTION_FORCE"
912 +poldek.initFilesystem
914 +setup_writeOption "$VSERVER_NAME"
915 +setup_writeInitialFstab
917 +test -z "$BUILD_INITPRE" || "$BUILD_INITPRE" "$SETUP_CONFDIR" "$UTIL_VSERVER_VARS"
918 +rpm.initDB "$SETUP_CONFDIR"
919 +rpm.importGPGPubKeys "$SETUP_CONFDIR" \
920 + "$__CONFDIR/.distributions/$DISTRIBUTION/pubkeys" \
921 + "$__CONFDIR/.distributions/.common/pubkeys" \
922 + "$__DISTRIBDIR/$DISTRIBUTION/pubkeys"
924 +$_VPOLDEK "$SETUP_CONFDIR" -- --update-whole
925 +poldek.installBasePackages "$SETUP_CONFDIR" "$PKGINSTALLDIR"
926 +test -z "$BUILD_INITPOST" || "$BUILD_INITPOST" "$SETUP_CONFDIR" "$UTIL_VSERVER_VARS"