]> git.pld-linux.org Git - packages/util-vserver.git/blame - util-vserver-pld.patch
- added
[packages/util-vserver.git] / util-vserver-pld.patch
CommitLineData
4fadbbef
JR
1diff -urN -x '*~' -x '*.orig' util-vserver-0.30.209-clean/distrib/Makefile.am util-vserver-0.30.209-poldek2/distrib/Makefile.am
2--- util-vserver-0.30.209-clean/distrib/Makefile.am 2005-10-28 19:53:49.000000000 +0200
3+++ util-vserver-0.30.209-poldek2/distrib/Makefile.am 2006-01-20 14:00:20.000000000 +0100
4@@ -48,14 +48,20 @@
5 centos42/pkgs/01 centos42/pkgs/02 centos42/pkgs/03 \
6 centos42/yum/yum.conf $(wildcard centos42/yum.repos.d/CentOS*.repo) \
e7229914
JR
7 suse91/apt/rpmpriorities suse91/pkgs/01 suse91/pkgs/02 \
8- suse91/rpm/macros
9+ suse91/rpm/macros \
e2166ed1 10+ pld-ac/pkgs/01 pld-ac/rpm/macros pld-ac/rpmlist.d/00.lst
e7229914
JR
11
12 nobase_confdistrib_DATA = rh9/apt/sources.list \
13 fc1/apt/sources.list \
4fadbbef
JR
14 fc2/apt/sources.list \
15 fc3/apt/sources.list \
16 fc4/apt/sources.list \
17- suse91/apt/sources.list
18+ suse91/apt/sources.list \
19+ pld-ac/poldek/aliases.conf \
20+ pld-ac/poldek/fetch.conf \
21+ pld-ac/poldek/pld-source.conf \
22+ pld-ac/poldek/poldek.conf \
7d1b77ad 23+ pld-ac/poldek/source.conf
4fadbbef
JR
24
25 AM_INSTALLCHECK_STD_OPTIONS_EXEMPT \
26 = $(nobase_distrib_SCRIPTS)
27@@ -75,6 +81,10 @@
e7229914
JR
28 ln -sf ../redhat/initpost $(DESTDIR)$(distribdir)/$$i/ && \
29 ln -sf ../redhat/initpre $(DESTDIR)$(distribdir)/$$i/; \
30 done
4fadbbef
JR
31+ POLDEKARCH=$(shell rpm -E '%{_target_cpu}' 2>/dev/null); \
32+ if [ -z "$$POLDEKARCH" ] ; then POLDEKARCH=$(shell uname -m) ; fi ; \
33+ sed "s|%ARCH%|$$POLDEKARCH|g" $(DESTDIR)$(confdistribdir)/pld-ac/poldek/pld-source.conf > $(DESTDIR)$(confdistribdir)/pld-ac/poldek/pld-source.conf.tmp ; \
34+ mv $(DESTDIR)$(confdistribdir)/pld-ac/poldek/pld-source.conf.tmp $(DESTDIR)$(confdistribdir)/pld-ac/poldek/pld-source.conf
e7229914
JR
35 $(mkinstalldirs) $(DESTDIR)$(confdir) \
36 $(DESTDIR)$(confdistribdir)/.common/pubkeys \
37 $(DESTDIR)$(confdefaultsdir) \
4fadbbef
JR
38diff -urN -x '*~' -x '*.orig' util-vserver-0.30.209-clean/distrib/pld-ac/pkgs/01 util-vserver-0.30.209-poldek2/distrib/pld-ac/pkgs/01
39--- util-vserver-0.30.209-clean/distrib/pld-ac/pkgs/01 1970-01-01 01:00:00.000000000 +0100
40+++ util-vserver-0.30.209-poldek2/distrib/pld-ac/pkgs/01 2006-01-20 13:45:53.000000000 +0100
34158836 41@@ -0,0 +1,5 @@
452506e7 42+basesystem
e7229914 43+glibc
4e5a2018 44+issue
f5f1d176 45+rpm-base
34158836 46+vserver-packages
4fadbbef
JR
47diff -urN -x '*~' -x '*.orig' util-vserver-0.30.209-clean/distrib/pld-ac/poldek/aliases.conf util-vserver-0.30.209-poldek2/distrib/pld-ac/poldek/aliases.conf
48--- util-vserver-0.30.209-clean/distrib/pld-ac/poldek/aliases.conf 1970-01-01 01:00:00.000000000 +0100
49+++ util-vserver-0.30.209-poldek2/distrib/pld-ac/poldek/aliases.conf 2006-01-20 13:42:33.000000000 +0100
50@@ -0,0 +1,30 @@
51+# System wide aliases
52+# ls
53+ll = ls -l
54+llu = ls -lu
55+llU = ls -lU
56+lli = ls -lI
57+
58+# install
59+freshen = install -FN
60+upgrade = install -F
61+
62+# for backward compatybility, greedy is on by default now
63+greedy-upgrade = install -FG
64+
65+just-install = install -IN
66+
67+# search
68+what-requires = search -r
69+what-provides = search -p
70+rsearch = search --perlre
71+
72+exit = quit
73+
74+# for fun
75+#ls = uninstall kernel
76+
77+less = !less
78+grep = !grep
79+awk = !awk
80+
81diff -urN -x '*~' -x '*.orig' util-vserver-0.30.209-clean/distrib/pld-ac/poldek/fetch.conf util-vserver-0.30.209-poldek2/distrib/pld-ac/poldek/fetch.conf
82--- util-vserver-0.30.209-clean/distrib/pld-ac/poldek/fetch.conf 1970-01-01 01:00:00.000000000 +0100
83+++ util-vserver-0.30.209-poldek2/distrib/pld-ac/poldek/fetch.conf 2006-01-20 13:42:29.000000000 +0100
84@@ -0,0 +1,62 @@
85+# Configuration of poldek external file getters. Each [fetcher] section
86+# declares one external downloader. The syntax is:
87+# [fetcher]
88+# name = NAME
89+# proto = PROTOCOL[ ,PROTOCOL... ]
90+# cmd = CMD [OPTION...] DESTINATION-MACRO URL-MACRO
91+# Possible parameters are:
92+#
93+#[fetcher]
94+# Unique name of the fetcher. This is an optional parameter, if not set then
95+# name is taken from the "cmd" parameter value as "$(basename $cmd)".
96+#name = foo
97+
98+# Protocol or protocols supported by fetcher. Name of the protocol can be
99+# completely arbitrary, i.e. if you can handle protocol "foo" by writing
100+# a script which takes URLs in form 'foo://'.
101+#proto = foo,bar
102+
103+# Parameter specifies an external command and its invoking syntax.
104+# The syntax of "cmd" is:
105+# cmd = COMMAND [ OPTION... ] {%d,%D} {%p,%P}[n]
106+# Where COMMAND is the name or full path of command, OPTION is command specific
107+# options. Macro '%d' is replaced with cache directory, '%D' is replaced with
108+# 'cache directory/file basename', and '%p' with file basename, %P with file full
109+# path (URL). Optional suffix 'n' with %p and %P means that command can be
110+# invoked with multiple files at once.
111+#cmd = foogetter.sh -N %D %Pn
112+
113+##Configured fetchers
114+[fetcher]
115+proto = cdrom
116+cmd = vfjuggle %d %Pn
117+
118+[fetcher]
119+proto = http,ftp,https
120+cmd = wget -N --dot-style=binary -P %d %Pn
121+
122+[fetcher]
123+proto = http,ftp
124+cmd = snarf %P %D
125+
126+[fetcher]
127+proto = https
128+cmd = curl %P -o %D
129+
130+[fetcher]
131+proto = rsync
132+cmd = rsync -v %P %d
133+
134+[fetcher]
135+proto = smb
136+cmd = vfsmb -v %P %d
137+
138+#[fetcher]
139+#proto = ssh
140+#cmd = vfssh.sh %d %Pn
141+
142+#[fetcher]
143+#proto = foo
144+#cmd = foo.sh %d %Pn
145+
146+
147diff -urN -x '*~' -x '*.orig' util-vserver-0.30.209-clean/distrib/pld-ac/poldek/pld-source.conf util-vserver-0.30.209-poldek2/distrib/pld-ac/poldek/pld-source.conf
148--- util-vserver-0.30.209-clean/distrib/pld-ac/poldek/pld-source.conf 1970-01-01 01:00:00.000000000 +0100
149+++ util-vserver-0.30.209-poldek2/distrib/pld-ac/poldek/pld-source.conf 2006-01-20 13:44:14.000000000 +0100
150@@ -0,0 +1,47 @@
151+# $Id$
152+# PLD <http://www.pld-linux.org/>
153+
154+_pld_arch = %ARCH%
155+_pld_prefix = ftp://ftp.ac.pld-linux.org/dists/ac
156+## Some mirrors
157+## You can use them if you have better connection there
158+# CI TASK:
159+#_pld_prefix = ftp://ftp.task.pld-linux.org/dists/ac
160+
161+
162+_ac_idxtype = pndir
163+
164+# PLD 2.0 (Ac)
165+[source]
166+type = %{_ac_idxtype}
167+name = ac
168+path = %{_pld_prefix}/PLD/%{_pld_arch}/PLD/RPMS/
169+
170+[source]
171+type = %{_ac_idxtype}
172+name = ac-updates-security
173+path = %{_pld_prefix}/updates/security/%{_pld_arch}/
174+
175+[source]
176+type = %{_ac_idxtype}
177+name = ac-updates-general
178+path = %{_pld_prefix}/updates/general/%{_pld_arch}/
179+noauto = yes
180+
181+[source]
182+type = %{_ac_idxtype}
183+name = ac-supported
184+path = %{_pld_prefix}/supported/%{_pld_arch}/
185+noauto = yes
186+
187+[source]
188+type = %{_ac_idxtype}
189+name = ac-ready
190+path = %{_pld_prefix}/ready/%{_pld_arch}/
191+noauto = yes
192+
193+[source]
194+type = %{_ac_idxtype}
195+name = ac-test
196+path = %{_pld_prefix}/test/%{_pld_arch}/
197+noauto = yes
198diff -urN -x '*~' -x '*.orig' util-vserver-0.30.209-clean/distrib/pld-ac/poldek/poldek.conf util-vserver-0.30.209-poldek2/distrib/pld-ac/poldek/poldek.conf
199--- util-vserver-0.30.209-clean/distrib/pld-ac/poldek/poldek.conf 1970-01-01 01:00:00.000000000 +0100
200+++ util-vserver-0.30.209-poldek2/distrib/pld-ac/poldek/poldek.conf 2006-01-20 13:44:46.000000000 +0100
201@@ -0,0 +1,182 @@
202+# poldek main configuration file.
203+
204+# Some macros. Macros are local, they are not visible in included files
205+# and macros declared in them are not visible to includer.
206+# Macros names starts with underscore '_'.
207+#
208+_distro = pld
209+
210+# Both local and remote files may be included. Included files may not contain
211+# [global] section, it will be ignored anyway.
212+%include %{_distro}-source.conf
213+
214+# local sources
215+%include source.conf
216+
217+# External downloaders configuration, not necessary in most cases, cause
218+# to internal HTTP and FTP client.
219+#%include fetch.conf
220+
221+[global]
222+
223+
224+# This parameter allows to configure the default repository index type.
225+#default index type = pndir
226+
227+# Cache directory for downloaded files. NOTE: that parent directory of cachedir
228+# must exists.
229+#cachedir = $HOME/.poldek-cache
230+
231+# Switch to ordinary user at startup when executed by root
232+#runas = poldek
233+
234+# Permits using root privileges for installation only. Automatically turned
235+# on when poldek executed as ordinary user.
236+#use sudo = no
237+
238+# Load /etc/apt/sources.list.
239+#load apt sources list = no
240+
241+# Handle gzipped indexes externally (needed on RedHat 9 and Fedora Core 1 and 2).
242+# This option is a workaround for broken zlib linked into librpm; with enabled
243+# 'auto zlib in rpm' poldek tries to detect such case and then enables external
244+# *.gz handling automatically.
245+#vfile external compress = no
246+
247+# Auto detection of zlib linked into librpm. See 'vfile external compress'
248+# description.
249+#auto zlib in rpm = yes
250+
251+# Automatically download whole index if incremental update fails.
252+#autoupa = yes
253+
254+# Do not save given paths into created indexes. This option may significantly
255+# reduce index size. Example (notice missing starting '/'):
256+# exclude path = usr/share/doc:usr/share/man:usr/src
257+#exclude path =
258+
259+# Full path name to a PM (rpm for now) binary.
260+#pm command = /bin/rpm
261+
262+# Full path name to sudo binary.
263+#sudo command = /usr/bin/sudo
264+
265+
266+### File downloaders configuration
267+
268+# Send ${USER}@${HOSTNAME} as anonymous FTP password (by default
269+# 'poldek@znienacka.net' is sent)
270+#vfile ftp sysuser as anon passwd = no
271+
272+# File getters configuration parameter. By this option URL handlers may be configured.
273+# To get file from HTTP and FTP servers poldek uses its internal client (what is
274+# recommended), although it can be changedby this option. Others protocols handled
275+# by external utilities can be configured also. The syntax is:
276+# default fetcher = PROTOCOL[,PROTOCOL...]:FETCHER_NAME
277+
278+# where FETCHER_NAME is a name of one of the fetcher preconfigured in [fetch]
279+# sections (placed in fetch.conf in default configuration).
280+# Examples:
281+# default fetcher = ftp,http:internal
282+# default fetcher = https:wget
283+# default fetcher = cdrom:vfjuggle
284+# vfjuggle is a cdrom getter supplied with poldek.
285+#default fetcher = http,ftp: internal
286+
287+# Proxies for internal FTP and HTTP client may be configured in usual
288+# way, by environment variables ftp_proxy and http_proxy, or by this option.
289+# Its syntax is similar to "default fetcher" one:
290+# proxy = PROTOCOL[,PROTOCOL...]:PROXY_URL
291+# Example:
292+# proxy = http: http://w3cache.foo.org:8080
293+#proxy =
294+
295+# Comma separated list of hosts or domains which will not be accessed via proxy.
296+# Option overrides no_proxy environment variable.
297+# Example:
298+# noproxy = localhost, .pl, ftp.foo.bar.org
299+#noproxy =
300+
301+# Internal HTTP and FTP client is stubborn, it retries to retrive
302+# file if connection breaks. This option tells it how many times
303+# it should try.
304+#vfile retries = 128
305+
306+
307+### Installation options
308+
309+# Install packages in small groups instead of doing all-or-nothing
310+# installations.
311+particle install = no
312+
313+# Do not remove downloaded packages after its successful installation.
314+#keep downloads = no
315+
316+# Controls visibility of multiple package instances with different EVR.
317+# If on, only one, highest version will be visible.
318+#unique package names = no
319+
320+# Epoch autopromotion during dependency comparision. RPM specific.
321+# Set it up if you are using system with rpm prior to 4.2.1 version.
322+#promoteepoch = no
323+
324+# Confirm packages installation.
325+#confirm installation = no
326+
327+# Confirm packages removal.
328+#confirm removal = yes
329+
330+# Let the user select package among equivalents.
cc65018c 331+choose equivalents manually = yes
4fadbbef
JR
332+
333+# Prevent package listed from being upgraded if they are already installed.
334+# hold = kernel* dev
335+#hold =
336+
337+# Ignore package list - packages fits given mask will be invisible.
338+# ignore = *-smp-* foo*
339+ignore = kernel* udev devfs
340+
341+# Conflicts with already installed packages are treated as resolved
342+# if at least one of multiple-installed package satisfies conflict.
343+# rpm doesn't support such cases, so --pm-nodeps is needed (use with
344+# care).
345+#allow duplicates = yes
346+
347+
348+### RPM specific options
349+
350+# rpm macros can be set by this option. Examples:
351+# rpmdef = _install_langs pl:pl_PL:lt:lt_LT
352+# Do not install any documentation:
353+# rpmdef = _netsharedpath /usr/share/info:/usr/share/man
354+# rpmdef = _excludedocs 1
355+#rpmdef =
356+
357+
358+### Dependency processing settings
359+# Subtle dependency processing options, they should not be changed
360+# unless you know what you are doing
361+
362+# Automatically install packages required by installed ones.
363+#follow = yes
364+
365+# Greedy upgrades, i.e. upgrade packages which dependencies are broken
366+# by being uninstalled ones.
367+#greedy = yes
368+
369+# Be yet more greedy; if successor of orphaned package found, and this
370+# successor drags no packages then upgrade the package instead of process
371+# its dependencies. Option value is implied by 'greedy' one by defalut.
372+#aggressive greedy = yes
373+
374+# Be tolerant for unmatched versioned dependencies which rpm tolerates, e.g.
375+# package A requires capability foo &gt;= 1.0 while package B provides "foo"
376+# without any version. Use with care, it may cause weird dependency errors.
377+#mercy = no
378+
379+# Taking into account package Obsoletes.
380+#obsoletes = yes
381+
382+# Taking into account package Conflicts.
383+#conflicts = yes
384diff -urN -x '*~' -x '*.orig' util-vserver-0.30.209-clean/distrib/pld-ac/poldek/source.conf util-vserver-0.30.209-poldek2/distrib/pld-ac/poldek/source.conf
385--- util-vserver-0.30.209-clean/distrib/pld-ac/poldek/source.conf 1970-01-01 01:00:00.000000000 +0100
386+++ util-vserver-0.30.209-poldek2/distrib/pld-ac/poldek/source.conf 2006-01-20 13:42:29.000000000 +0100
387@@ -0,0 +1,85 @@
388+# Sample poldek sources configuration
389+# Every source is configured in his own [source] section.
390+# Possible parameters are:
391+#
392+#[source]
393+# Unique name of the repository.
394+#name = foo
395+
396+# Type of repository index. Permitted values are 'pndir', 'pdir', 'apt', 'yum'
397+# and 'dir' as listed by --stl switch.
398+#type = pndir
399+
400+# This parameter sets index original type i.e type of repository
401+# from what this repository is created. Default is 'dir' - means
402+# that directory of packages is scanned.
403+#original type = dir
404+
405+# Unique name of the repository. May be either path or URL.
406+#path = /some/url/or/dir
407+
408+# If package index and packages are stored in different locations then
409+# prefix stands for packages path.
410+#prefix = /some/url/or/dir
411+
412+# Controls visibility of multiple package instances with different EVR.
413+# If on, only one, highest version will be visible.
414+#douniq = no
415+
416+# Repository priority. If the same packages (equal names and EVR)
417+# are available in more than one source then package from highest
418+# prioritized source are taken. Priority is numeric value. Lower number
419+# means higher priority, and negative priorities are allowed.
420+# Priority is numeric value.
421+#pri = 0
422+
423+# Controling if repository index will be implicit loaded. Set it off if
424+# the index should be loaded on demand only, i.e. if specified directly
425+# by --sn option.
426+#auto = yes
427+
428+# Controls if repository index will be implicit updated. Set it off if
429+# the index should be updated on demand only, i.e. if specified directly
430+# by --sn option.
431+#autoup = yes
432+
433+# Packages PGP/GPG signatures (if any) will be verified before their
434+# installation.
435+#signed = no
436+
437+# Have the same meaning as [global] parameter. Example:
438+# hold = kernel* dev
439+#hold =
440+
441+# Have the same meaning as [global] parameter. Example:
442+# ignore = kernel*smp* dev
443+#ignore =
444+
445+# Parameter have the same meaning as [global] parameter.
446+# exclude path = usr/share/doc:usr/share/man:usr/src
447+#exclude path =
448+
449+# Preferred language of package descriptions. If not set, taken from locale
450+# settings. Example:
451+# lang = pl_PL:lt_LT
452+#lang =
453+
454+[source]
455+name = home
456+type = dir
457+path = $HOME/rpm/RPMS
458+auto = no
459+autoup = no
460+
461+#[source]
462+#type = pndir
463+#name = foo
464+#path = ftp://ftp.foo.bar.org/RPMS/
465+#pri = -10
466+#auto = no
467+#autoup = no
468+#signed = yes
469+#hold = kernel*
470+#ignore = kernel*-smp-*
471+#dscr = pl_PL
472+
473diff -urN -x '*~' -x '*.orig' util-vserver-0.30.209-clean/distrib/pld-ac/rpm/macros util-vserver-0.30.209-poldek2/distrib/pld-ac/rpm/macros
474--- util-vserver-0.30.209-clean/distrib/pld-ac/rpm/macros 1970-01-01 01:00:00.000000000 +0100
475+++ util-vserver-0.30.209-poldek2/distrib/pld-ac/rpm/macros 2006-01-20 13:45:53.000000000 +0100
d7090917 476@@ -0,0 +1,4 @@
e7229914
JR
477+# Because of https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=52725
478+# you have to use at least one language beside 'C'
479+%_install_langs C:en:pl
d7090917 480+%_netsharedpath /dev
4fadbbef
JR
481diff -urN -x '*~' -x '*.orig' util-vserver-0.30.209-clean/distrib/pld-ac/rpmlist.d/00.lst util-vserver-0.30.209-poldek2/distrib/pld-ac/rpmlist.d/00.lst
482--- util-vserver-0.30.209-clean/distrib/pld-ac/rpmlist.d/00.lst 1970-01-01 01:00:00.000000000 +0100
483+++ util-vserver-0.30.209-poldek2/distrib/pld-ac/rpmlist.d/00.lst 2006-01-20 13:45:53.000000000 +0100
34158836 484@@ -0,0 +1,10 @@
452506e7
JR
485+basesystem-*.rpm
486+dev-*.rpm
e7229914
JR
487+FHS-*.rpm
488+glibc-misc-*.rpm
489+glibc-[0-9]*.rpm
490+libgcc-[0-9]*.rpm
491+setup-*.rpm
4e5a2018 492+issue-[0-9]*.rpm
f5f1d176 493+rpm-base-*.rpm
34158836 494+vserver-packages-*.rpm
4fadbbef
JR
495diff -urN -x '*~' -x '*.orig' util-vserver-0.30.209-clean/scripts/Makefile-files util-vserver-0.30.209-poldek2/scripts/Makefile-files
496--- util-vserver-0.30.209-clean/scripts/Makefile-files 2005-04-28 19:45:34.000000000 +0200
497+++ util-vserver-0.30.209-poldek2/scripts/Makefile-files 2006-01-20 13:45:53.000000000 +0100
498@@ -21,6 +21,7 @@
499 scripts/vapt-get-worker \
500 scripts/vrpm-worker \
501 scripts/vyum-worker \
502+ scripts/vpoldek-worker \
503 scripts/vrpm-preload \
504 scripts/save_s_context \
505 scripts/vservers.grabinfo.sh \
506@@ -43,11 +44,13 @@
507 scripts/vserver-build.debootstrap \
508 scripts/vserver-build.rpm \
509 scripts/vserver-build.yum \
510+ scripts/vserver-build.poldek \
511 scripts/vserver-build.functions \
512 scripts/vserver-build.functions.apt \
513 scripts/vserver-build.functions.rpm \
514 scripts/vserver-build.functions.pkgmgmt \
515 scripts/vserver-build.functions.yum \
516+ scripts/vserver-build.functions.poldek \
517 scripts/vserver-setup.functions \
518 scripts/vserver.functions \
519 scripts/vserver.start \
520@@ -59,6 +62,7 @@
521 scripts_pkglib_src_SCRPTS = scripts/pkgmgmt \
522 scripts/vapt-get-worker \
523 scripts/vpkg \
524+ scripts/vpoldek-worker \
525 scripts/vrpm-worker \
526 scripts/vrpm-preload \
527 scripts/start-vservers \
528@@ -80,6 +84,7 @@
529
530 scripts_sbin_src_PRGS = scripts/chcontext \
531 scripts/vapt-get \
532+ scripts/vpoldek \
533 scripts/vpstree \
534 scripts/vrpm \
535 scripts/vserver \
536diff -urN -x '*~' -x '*.orig' util-vserver-0.30.209-clean/scripts/functions util-vserver-0.30.209-poldek2/scripts/functions
537--- util-vserver-0.30.209-clean/scripts/functions 2005-10-28 19:59:37.000000000 +0200
538+++ util-vserver-0.30.209-poldek2/scripts/functions 2006-01-20 16:46:03.000000000 +0100
539@@ -370,6 +370,20 @@
540 fi
541 }
542
543+function _pkgSetVarsPoldek
544+{
545+ if test -n "$PKGDIR"; then
546+ findDir POLDEKETCDIR $PKGDIR/poldeketc $PKGDIR/base/poldek/etc /etc/poldek
547+ findDir POLDEKCACHEDIR $PKGDIR/poldek-cache $PKGDIR/base/poldek/cache
548+ else
549+ findDir POLDEKETCDIR "$VDIR"/etc/poldek /etc/poldek
550+ findDir POLDEKCACHEDIR "$VDIR"/var/tmp/poldek-cache
551+ fi
552+
553+ findFile POLDEK_CONFIG "$POLDEKETCDIR"/poldek.conf ""
554+ test -z "$POLDEK_CONFIG" || export POLDEK_CONFIG
555+}
556+
557
558 function _pkgMountBase
559 {
560@@ -443,6 +457,7 @@
561 rpm) _pkgSetVarsRPM;;
562 apt) _pkgSetVarsApt;;
563 yum) _pkgSetVarsYum;;
564+ poldek) _pkgSetVarsPoldek;;
565 *) echo "Unknown packaging flavor" >&2; exit 1;;
566 esac
567 done
568@@ -705,6 +720,8 @@
4e5a2018
JR
569 style=redhat
570 elif test -e "$_pgs_vdir"/etc/mandrake-release; then
571 style=mandrake
572+ elif test -e "$_pgs_vdir"/etc/pld-release; then
573+ style=pld
574 elif test -e "$_pgs_vdir"/etc/debian_version; then
575 style=debian
576 elif test -e "$_pgs_vdir"/etc/SuSE-release; then
4fadbbef
JR
577@@ -772,6 +789,27 @@
578 test -n "$have_yum" && return 0 || return 1
579 }
580
581+## Usage: pkgmgmt.isPoldekAvailable <cfgdir> <vdir> [<is-internal>]
582+function pkgmgmt.isPoldekAvailable
583+{
584+ local cfgdir="$1"
585+ local vdir="$2"
586+ local is_internal="$3"
587+
588+ local have_poldek i
589+ if test -n "$is_internal"; then
590+ have_poldek=1
591+ test -d "$cfgdir"/base/poldek -o -d "$cfgdir"/poldeketc || have_poldek=
592+ else
593+ have_poldek=
594+ for i in /bin /usr/bin /usr/local/bin; do
595+ test ! -x "$vdir$i"/poldek || { have_poldek=1; break; }
596+ done
597+ fi
598+
599+ test -n "$have_poldek" && return 0 || return 1
600+}
601+
602
603 function vshelper.doSanityCheck
604 {
605diff -urN -x '*~' -x '*.orig' util-vserver-0.30.209-clean/scripts/pkgmgmt util-vserver-0.30.209-poldek2/scripts/pkgmgmt
606--- util-vserver-0.30.209-clean/scripts/pkgmgmt 2005-07-03 19:43:34.000000000 +0200
607+++ util-vserver-0.30.209-poldek2/scripts/pkgmgmt 2006-01-20 14:40:48.000000000 +0100
608@@ -193,7 +193,7 @@
609 "
610
611 case $2 in
612- (RH) pkgs=$(vrpm "$1" -- -q --qf '---%{NAME}---\n' rpm apt yum "${YUM_RELEASEPKGS[@]}")
613+ (RH) pkgs=$(vrpm "$1" -- -q --qf '---%{NAME}---\n' rpm apt yum poldek "${YUM_RELEASEPKGS[@]}")
614 hasSubstring "$pkgs" ---rpm--- || {
615 warning "$ERR
616 * The vserver does not seem to have the 'rpm' package which is required
617@@ -203,9 +203,9 @@
618 ERR=
619 }
620
621- hasSubstring "$pkgs" ---apt--- ---yum--- || {
622+ hasSubstring "$pkgs" ---apt--- ---yum--- ---poldek--- || {
623 warning "$ERR
624-* The vserver does not seem to have a depsolver like 'apt' or 'yum'
625+* The vserver does not seem to have a depsolver like 'apt', 'yum' or 'poldek'
626 installed. It is suggested to install such a program before setting
627 up internal package management."
628 res=1
629@@ -366,6 +366,131 @@
630 fi
631 }
632
633+function processVserver_PLD()
634+{
635+ local vserver=$1
636+ local is_internalize=$2
637+ local cfgdir
638+ local i
639+
640+ cfgdir=$($_VSERVER_INFO "$vserver" APPDIR pkgmgmt) || \
641+ cfgdir=$($_VSERVER_INFO "$vserver" APPDIR)/pkgmgmt
642+
643+ ## Figure out the environment....
644+ pkgmgmt.isPoldekAvailable "$cfgdir" "$vdir" "$is_internalize" || have_poldek=
645+
646+ local POLDEKETCDIR=
647+ local POLDEKCACHEDIR=
648+ local RPMETCDIR=
649+ local RPMSTATEDIR=
650+
651+ ## Create directories and assign variables where configuration
652+ ## can/will be found on the host
653+ if test -n "$is_internalize"; then
654+ verifyInternalPackages "$vserver" RH || test -n "$IS_FORCE" ||
655+ panic "
656+Can not continue; use '--force' to override this check"
657+
658+ pushd "$vdir" >/dev/null
659+
660+ test ! -L var/lib/rpm || {
661+ $_EXEC_CD /var/lib $_RM rpm &&
662+ $_EXEC_CD /var/lib $_MKDIR -m755 rpm &&
663+ $_EXEC_CD /var/lib $_CHOWN rpm:rpm rpm ||
664+ :
665+ } </dev/null 2>/dev/null
666+
667+ for i in var/tmp/poldek-cache etc/rpm etc/poldek; do
668+ test -d "$i" ||
669+ $_EXEC_CD /$(dirname "$i") $_MKDIR -m755 $(basename "$i") || :
670+ done #2>/dev/null
671+
672+ popd >/dev/null
673+
674+ if test -n "$have_poldek"; then
675+ findDir POLDEKETCDIR "$cfgdir"/poldeketc "$cfgdir"/base/poldek/etc /etc/poldek
676+ fi
677+
678+ findDir RPMETCDIR "$cfgdir"/rpmetc "$cfgdir"/base/rpm/etc /etc/rpm /
679+ findDir RPMSTATEDIR "$cfgdir"/rpmstate "$cfgdir"/base/rpm/state
680+ else
681+ mkdir -m755 -p "$cfgdir"
682+ local need_base=
683+
684+ if test -n "$have_poldek"; then
685+ findDir POLDEKETCDIR "$cfgdir"/poldeketc "$cfgdir"/base/poldek/etc /
686+ findDir POLDEKCACHEDIR "$cfgdir"/poldek-cache "$cfgdir"/base/poldek/cache /
687+
688+ test "$POLDEKETCDIR" != / || POLDEKETCDIR=$cfgdir/base/poldek/etc
689+ test "$POLDEKCACHEDIR" != / || POLDEKCACHEDIR=$cfgdir/base/poldek/cache
690+
691+ test -d "$cfgdir"/poldeketc -a -d "$cfgdir"/poldek-cache || need_base=1
692+ fi
693+
694+ findDir RPMETCDIR "$cfgdir"/rpmetc "$cfgdir"/base/rpm/etc /
695+ findDir RPMSTATEDIR "$cfgdir"/rpmstate "$cfgdir"/base/rpm/state /
696+
697+ test "$RPMETCDIR" != / || RPMETCDIR=$cfgdir/base/rpm/etc
698+ test "$RPMSTATEDIR" != / || RPMSTATEDIR=$cfgdir/base/rpm/state
699+
700+ test -d "$cfgdir"/rpmetc -a -d "$cfgdir"/rpmstate || need_base=1
701+ test ! -e "$cfgdir"/base || need_base=
702+
703+ test -z "$need_base" || ln -s "$PKGCFGDIR" "$cfgdir"/base
704+
705+ mkdir -m755 -p "$PKGCFGDIR"
706+ _createDirs "$POLDEKETCDIR" "$POLDEKCACHEDIR" \
707+ "$RPMETCDIR" "$RPMSTATEDIR"
708+ fi
709+
710+ ## Copy the files...
711+ if test -n "$is_internalize"; then
712+ if test -n "$have_poldek"; then
713+ _copySecure "$vdir" "$POLDEKETCDIR" /etc/poldek
714+ pushd "$vdir" >/dev/null
715+ _hashAuto /etc/poldek.conf '/'
716+ popd >/dev/null
717+ fi
718+
719+ _copySecure "$vdir" "$RPMETCDIR" /etc/rpm
720+ _copySecure "$vdir" "$RPMSTATEDIR" /var/lib/rpm
721+
722+ pushd "$vdir" >/dev/null
723+ ## remove %_dbpath settings
724+ _substFile /etc/rpm/macros '/^%_dbpath[ \t].*/D'
725+ popd >/dev/null
726+ else
727+ if test -n "$have_poldek"; then
728+ _copySecureRev "$vdir" /etc/poldek "$POLDEKETCDIR"
729+ _unhashAuto "$POLDEKETCDIR"/poldek.conf '/'
730+ fi
731+
732+ _copySecureRev "$vdir" /etc/rpm "$RPMETCDIR"
733+ _copySecureRev "$vdir" /var/lib/rpm "$RPMSTATEDIR"
734+
735+ echo -e "%_dbpath\t\t$rpmdb_mntpoint" >>$RPMETCDIR/macros
736+ fi
737+
738+ ## Cleanups...
739+ if test -n "$is_internalize"; then
740+ :
741+ else
8d5b8ef9 742+ tmpdir=$($_MKTEMPDIR -p /var/tmp pgmgmt.XXXXXX)
4fadbbef
JR
743+ trap "$_RM -rf $tmpdir" EXIT
744+ pushd "$vdir" >/dev/null
745+ $_EXEC_CD /var/lib $_MV rpm $tmpdir/
746+ $_EXEC_CD /var/lib $_LN_S "$rpmdb_mntpoint" rpm
747+ $_RM -rf $tmpdir
748+ fi
749+
750+ ## Finish it...
751+ if test -n "$is_internalize"; then
752+ $_TOUCH "$cfgdir"/internal
753+ else
754+ $_RM -f "$cfgdir"/internal
755+ fi
756+}
757+
758 function processVserver_Debian()
759 {
760 local vserver=$1
761@@ -415,6 +540,7 @@
762
763 case "$style" in
764 (redhat|mandrake) processVserver_RH "$vserver" "$IS_INTERNALIZE";;
765+ (pld) processVserver_PLD "$vserver" "$IS_INTERNALIZE";;
766 (debian) processVserver_Debian "$vserver" "$IS_INTERNALIZE";;
767 (*)
768 echo $"Vserver style '$style' is not supported for packagemanagment" >&2
769diff -urN -x '*~' -x '*.orig' util-vserver-0.30.209-clean/scripts/util-vserver-vars.pathsubst util-vserver-0.30.209-poldek2/scripts/util-vserver-vars.pathsubst
770--- util-vserver-0.30.209-clean/scripts/util-vserver-vars.pathsubst 2005-07-03 19:43:55.000000000 +0200
771+++ util-vserver-0.30.209-poldek2/scripts/util-vserver-vars.pathsubst 2006-01-20 13:45:53.000000000 +0100
772@@ -48,6 +48,7 @@
773 _LIB_VSERVER_BUILD_FUNCTIONS_RPM="$__PKGLIBDIR/vserver-build.functions.rpm"
774 _LIB_VSERVER_BUILD_FUNCTIONS_YUM="$__PKGLIBDIR/vserver-build.functions.yum"
775 _LIB_VSERVER_BUILD_FUNCTIONS_PKGMGMT="$__PKGLIBDIR/vserver-build.functions.pkgmgmt"
776+_LIB_VSERVER_BUILD_FUNCTIONS_POLDEK="$__PKGLIBDIR/vserver-build.functions.poldek"
777 _LISTDEVIP="$__LEGACYDIR/listdevip"
778 _LOCKFILE="$__PKGLIBDIR/lockfile"
779 _MASK2PREFIX="$__PKGLIBDIR/mask2prefix"
780@@ -91,6 +92,8 @@
781 _VUNIFY="$__PKGLIBDIR/vunify"
782 _VYUM="$__SBINDIR/vyum"
783 _VYUM_WORKER="$__PKGLIBDIR/vyum-worker"
784+_VPOLDEK="$__SBINDIR/vpoldek"
785+_VPOLDEK_WORKER="$__PKGLIBDIR/vpoldek-worker"
786
787 _AWK="@AWK@"
788 _CAT="@CAT@"
789diff -urN -x '*~' -x '*.orig' util-vserver-0.30.209-clean/scripts/vpkg util-vserver-0.30.209-poldek2/scripts/vpkg
790--- util-vserver-0.30.209-clean/scripts/vpkg 2005-03-21 21:03:30.000000000 +0100
791+++ util-vserver-0.30.209-poldek2/scripts/vpkg 2006-01-20 13:45:53.000000000 +0100
4e5a2018
JR
792@@ -115,6 +115,44 @@
793 fi
794 fi
795 ;;
796+ (pld)
797+ rpm_param=
798+ poldek_param=
799+ case "$tag" in
800+ ## rpm outputs sometimes '(contains no files)', so return
801+ ## only the valid output
802+ (get-conffiles)
803+ rpm_param=( -qac --pipe "$_SED '\!^/!p;d'" );;
804+ (install)
805+ rpm_param=( -Uvh "$@" )
806+ poldek_param=( --install -v "$@" )
807+ ;;
808+ esac
809+
810+ if test -n "$is_external"; then
811+ have_poldek=1
812+ test -d "$cfgdir"/base/poldek -o -d "$cfgdir"/poldeketc || have_poldek=
813+ else
814+ have_poldek=
815+ for i in /bin /usr/bin /usr/local/bin; do
816+ test ! -x "$vdir$i"/poldek || { have_poldek=1; break; }
817+ done
818+ fi
819+
820+ if test -n "$is_external"; then
821+ if test "$have_poldek" -a "$poldek_param"; then
822+ cmd=( "$_VPOLDEK" "$vserver" -- "${poldek_param[@]}" )
823+ else
824+ cmd=( "$_VRPM" "$vserver" -- "${rpm_param[@]}" )
825+ fi
826+ else
827+ if test "$have_poldek" -a "$poldek_param"; then
828+ cmd=( "$_VSERVER" --silent "$vserver" exec poldek "${poldek_param[@]}" )
829+ else
830+ cmd=( "$_VSERVER" --silent "$vserver" exec rpm "${rpm_param[@]}" )
831+ fi
832+ fi
833+ ;;
834 (debian)
835 case "$tag" in
836 (get-conffiles)
4fadbbef
JR
837diff -urN -x '*~' -x '*.orig' util-vserver-0.30.209-clean/scripts/vpoldek util-vserver-0.30.209-poldek2/scripts/vpoldek
838--- util-vserver-0.30.209-clean/scripts/vpoldek 1970-01-01 01:00:00.000000000 +0100
839+++ util-vserver-0.30.209-poldek2/scripts/vpoldek 2006-01-20 13:45:53.000000000 +0100
840@@ -0,0 +1,96 @@
841+#! /bin/bash
842+# $Id$
843+
844+# Copyright (C) 2003 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de>
845+#
846+# This program is free software; you can redistribute it and/or modify
847+# it under the terms of the GNU General Public License as published by
848+# the Free Software Foundation; version 2 of the License.
849+#
850+# This program is distributed in the hope that it will be useful,
851+# but WITHOUT ANY WARRANTY; without even the implied warranty of
852+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
853+# GNU General Public License for more details.
854+#
855+# You should have received a copy of the GNU General Public License
856+# along with this program; if not, write to the Free Software
857+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
858+
859+: ${UTIL_VSERVER_VARS:=/usr/lib/util-vserver/util-vserver-vars}
860+test -e "$UTIL_VSERVER_VARS" || {
861+ echo $"Can not find util-vserver installation (the file '$UTIL_VSERVER_VARS' would be expected); aborting..." >&2
862+ exit 1
863+}
864+. "$UTIL_VSERVER_VARS"
865+. "$_LIB_FUNCTIONS"
866+
867+
868+function showHelp()
869+{
870+ echo \
871+$"Usage: $0 <vserver-name>* [--all] -- <params>+
872+
873+Report bugs to <$PACKAGE_BUGREPORT>."
874+ exit 0
875+}
876+
877+function showVersion()
878+{
879+ echo \
880+$"vpoldek $PACKAGE_VERSION -- poldek for vservers
881+This program is part of $PACKAGE_STRING
882+
883+Copyright (C) 2003 Enrico Scholz
884+This program is free software; you may redistribute it under the terms of
885+the GNU General Public License. This program has absolutely no warranty."
886+ exit 0
887+}
888+
889+is_quiet=
890+declare -a vservers=()
891+
892+while test "$#" -ge 1; do
893+ case "$1" in
894+ --) shift; break;;
895+ --help) showHelp $0;;
896+ --quiet|-q) is_quiet=1 ;;
897+ --all)
898+ getAllVservers tmp
899+ vservers=( "${vservers[@]}" "${tmp[@]}" )
900+ ;;
901+ --version)
902+ showVersion ;;
903+ *) vservers=( "${vservers[@]}" "$1" )
904+ esac
905+ shift
906+done
907+
908+cnt=0
909+res=255
910+for i in "${vservers[@]}"; do
911+ cnt=$[ cnt + 1 ]
912+
913+ test -n "$is_quiet" || {
914+ colorize bold echo -n "vpoldek: operating on vserver "
915+ colorize bold colorize emph echo "$i"
916+ xtermTitle "vpoldek: operating on vserver '$i' [$cnt/${#vservers[@]}]"
917+ }
918+
919+ if pkgmgmt.isInternal "$i"; then
920+ $_VSERVER "$i" exec poldek "$@"
921+ else
922+ callInNamespace "$i" \
923+ "$_VNAMESPACE" --new -- "$_VPOLDEK_WORKER" "$i" "$@"
924+ fi
925+ res=$?
926+
927+ test $res -eq 0 -o -n "$is_quiet" || {
928+ colorize error echo -n $"vpoldek failed on vserver '$i' with errorcode $res"
929+ echo
930+ }
931+
932+ test -n "$is_quiet" || echo
933+done
934+
935+test "$cnt" -ge 0 || echo "No vservers specified" >&2
936+exit $res
937diff -urN -x '*~' -x '*.orig' util-vserver-0.30.209-clean/scripts/vpoldek-worker util-vserver-0.30.209-poldek2/scripts/vpoldek-worker
938--- util-vserver-0.30.209-clean/scripts/vpoldek-worker 1970-01-01 01:00:00.000000000 +0100
939+++ util-vserver-0.30.209-poldek2/scripts/vpoldek-worker 2006-01-20 13:45:53.000000000 +0100
940@@ -0,0 +1,45 @@
941+#! /bin/bash
942+# $Id$
943+
944+# Copyright (C) 2003 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de>
945+#
946+# This program is free software; you can redistribute it and/or modify
947+# it under the terms of the GNU General Public License as published by
948+# the Free Software Foundation; version 2 of the License.
949+#
950+# This program is distributed in the hope that it will be useful,
951+# but WITHOUT ANY WARRANTY; without even the implied warranty of
952+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
953+# GNU General Public License for more details.
954+#
955+# You should have received a copy of the GNU General Public License
956+# along with this program; if not, write to the Free Software
957+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
958+
959+set -e
960+
961+: ${UTIL_VSERVER_VARS:=/usr/lib/util-vserver/util-vserver-vars}
962+test -e "$UTIL_VSERVER_VARS" || {
963+ echo $"Can not find util-vserver installation (the file '$UTIL_VSERVER_VARS' would be expected); aborting..." >&2
964+ exit 1
965+}
966+. "$UTIL_VSERVER_VARS"
967+. "$_LIB_FUNCTIONS"
968+
969+
970+vserver="$1"
971+shift
972+
973+pkgInit "$vserver" rpm poldek
974+
975+test -z "$_POLDEK" || {
976+ warning $"The environment variable \$_POLDEK is not supported anymore; please use \$POLDEK instead of"
977+ ${POLDEK:=$_POLDEK}
978+}
979+
980+exec ${_POLDEK:-poldek} \
981+ -v --root=$VDIR \
982+ --cachedir=$POLDEKCACHEDIR \
983+ --conf=$POLDEK_CONFIG \
984+ --pmcmd=$RPM_BINARY \
985+ "$@"
986diff -urN -x '*~' -x '*.orig' util-vserver-0.30.209-clean/scripts/vserver-build util-vserver-0.30.209-poldek2/scripts/vserver-build
987--- util-vserver-0.30.209-clean/scripts/vserver-build 2006-01-20 13:45:34.000000000 +0100
988+++ util-vserver-0.30.209-poldek2/scripts/vserver-build 2006-01-20 13:45:53.000000000 +0100
989@@ -59,6 +59,9 @@
990 yum ... -- -d <distribution>
991 ... installs the base-packages of the given distribution with
992 help of 'vyum'
993+ poldek ... -- -d <distribution>
994+ ... installs the base-packages of the given distribution with
995+ help of 'vpoldek'
996 rpm ... -- [-d <distribution>] --empty|([--force] [--nodeps] <manifest>)+
997 ... installs lists of rpm-packages
998 skeleton ... -- [<cmd> <args>*]
999@@ -132,7 +135,7 @@
1000
1001 case x"$method" in
1002 (xlegacy) exec $_VSERVER_LEGACY "$VSERVER_NAME" build "$@" ;;
1003- (xapt-rpm|xcopy|xskeleton|xdebootstrap|xyum|xrpm)
1004+ (xapt-rpm|xcopy|xskeleton|xdebootstrap|xyum|xrpm|xpoldek)
1005 . $__PKGLIBDIR/vserver-build.$method
1006 ;;
1007 (x) panic $"No build-method specified";;
1008diff -urN -x '*~' -x '*.orig' util-vserver-0.30.209-clean/scripts/vserver-build.functions util-vserver-0.30.209-poldek2/scripts/vserver-build.functions
1009--- util-vserver-0.30.209-clean/scripts/vserver-build.functions 2005-10-28 20:40:39.000000000 +0200
1010+++ util-vserver-0.30.209-poldek2/scripts/vserver-build.functions 2006-01-20 13:55:09.000000000 +0100
1011@@ -137,6 +137,12 @@
1012 elif test -e /etc/slackware-release; then
1013 set -- $(cat /etc/slackware-release)
1014 DISTRIBUTION=slackware$2
1015+ elif test -e /etc/pld-release; then
1016+ old_IFS=$IFS
1017+ IFS='()'
1018+ set -- $(cat /etc/pld-release)
1019+ DISTRIBUTION=pld-$(echo $2 | tr A-Z a-z)
1020+ IFS=$old_IFS
1021 elif test -n "$1"; then
1022 DISTRIBUTION=$1
1023 else
1024diff -urN -x '*~' -x '*.orig' util-vserver-0.30.209-clean/scripts/vserver-build.functions.poldek util-vserver-0.30.209-poldek2/scripts/vserver-build.functions.poldek
1025--- util-vserver-0.30.209-clean/scripts/vserver-build.functions.poldek 1970-01-01 01:00:00.000000000 +0100
1026+++ util-vserver-0.30.209-poldek2/scripts/vserver-build.functions.poldek 2006-01-20 14:47:58.000000000 +0100
1027@@ -0,0 +1,67 @@
1028+# $Id$ --*- sh -*--
1029+
1030+# Copyright (C) 2003 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de>
1031+#
1032+# This program is free software; you can redistribute it and/or modify
1033+# it under the terms of the GNU General Public License as published by
1034+# the Free Software Foundation; version 2 of the License.
1035+#
1036+# This program is distributed in the hope that it will be useful,
1037+# but WITHOUT ANY WARRANTY; without even the implied warranty of
1038+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
1039+# GNU General Public License for more details.
1040+#
1041+# You should have received a copy of the GNU General Public License
1042+# along with this program; if not, write to the Free Software
1043+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
1044+
1045+function poldek.installBasePackages
1046+{
1047+ local name="$1"
1048+ local dir="$2"
1049+
1050+ test "$dir" != / || return 0
1051+ for filelist in "$dir"/*; do
1052+ isRegularFile "$filelist" || continue
1053+ local idx=0
1054+ local can_fail=false
1055+ local flags='--install'
1056+
1057+ set -- $(<$filelist)
1058+ while test "$#" -gt 0; do
1059+ case "$1" in
1060+ --reinstall) flags='--reinstall';;
1061+ --can-fail) can_fail=true;;
1062+ *) break;;
1063+ esac
1064+ shift
1065+ done
1066+ "$_VPOLDEK" "$name" -- $flags $* || $can_fail
1067+ done
1068+}
1069+
1070+function poldek.initVariables
1071+{
1072+ findFile POLDEKCONFDEFAULT \
1073+ "$__CONFDIR/.distributions/$DISTRIBUTION/poldek/poldek.conf" \
1074+ "$__CONFDIR/.defaults/apps/pkgmgmt/poldek/poldek.conf" \
1075+ "$__DISTRIBDIR/$DISTRIBUTION/poldek/poldek.conf" \
1076+ "$__DISTRIBDIR/defaults/poldek/poldek.conf" \
1077+ ''
1078+}
1079+
1080+function poldek.initFilesystem
1081+{
1082+ mkdir -p "$PKGCFGDIR"/poldek/etc
1083+ mkdir -p "$PKGCFGBASE"/poldek-cache
1084+
1085+ $_LN_S "$PKGCFGBASE"/poldek-cache "$PKGCFGDIR"/poldek/cache
1086+
1087+ populateDirectory "$PKGCFGDIR/poldek/etc" \
1088+ "$__DISTRIBDIR/defaults/poldek" \
1089+ "$__DISTRIBDIR/$DISTRIBUTION/poldek" \
1090+ "$__CONFDIR/.distributions/$DISTRIBUTION/poldek"
1091+
78219c44
JR
1092+# test -z "$POLDEKCONFDEFAULT" || \
1093+# $_LN_S "$POLDEKCONFDEFAULT" "$PKGCFGDIR"/poldek/etc/
4fadbbef
JR
1094+}
1095diff -urN -x '*~' -x '*.orig' util-vserver-0.30.209-clean/scripts/vserver-build.poldek util-vserver-0.30.209-poldek2/scripts/vserver-build.poldek
1096--- util-vserver-0.30.209-clean/scripts/vserver-build.poldek 1970-01-01 01:00:00.000000000 +0100
1097+++ util-vserver-0.30.209-poldek2/scripts/vserver-build.poldek 2006-01-20 13:45:53.000000000 +0100
1098@@ -0,0 +1,64 @@
1099+# $Id$ --*- sh -*--
1100+
1101+# Copyright (C) 2003 Enrico Scholz <enrico.scholz@informatik.tu-chemnitz.de>
1102+#
1103+# This program is free software; you can redistribute it and/or modify
1104+# it under the terms of the GNU General Public License as published by
1105+# the Free Software Foundation; version 2 of the License.
1106+#
1107+# This program is distributed in the hope that it will be useful,
1108+# but WITHOUT ANY WARRANTY; without even the implied warranty of
1109+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
1110+# GNU General Public License for more details.
1111+#
1112+# You should have received a copy of the GNU General Public License
1113+# along with this program; if not, write to the Free Software
1114+# Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
1115+
1116+tmp=$(getopt -o +d: --long debug -n "$0" -- "$@") || exit 1
1117+eval set -- "$tmp"
1118+
1119+. "$_LIB_VSERVER_BUILD_FUNCTIONS_RPM"
1120+. "$_LIB_VSERVER_BUILD_FUNCTIONS_POLDEK"
1121+. "$_LIB_VSERVER_BUILD_FUNCTIONS_PKGMGMT"
1122+
1123+while true; do
1124+ case "$1" in
1125+ (-d) DISTRIBUTION=$2; shift;;
1126+ (--debug) set -x;;
1127+ (--) shift; break ;;
1128+ (*) echo "vserver-build.poldek: internal error: unrecognized option '$1'" >&2
1129+ exit 1
1130+ ;;
1131+ esac
1132+ shift
1133+done
1134+
1135+getDistribution
1136+
1137+base.init
1138+
1139+pkgmgmt.initVariables
1140+rpm.initVariables
1141+poldek.initVariables
1142+
1143+base.initFilesystem "$OPTION_FORCE"
1144+pkgmgmt.initFilesystem "$OPTION_FORCE"
1145+rpm.initFilesystem
1146+poldek.initFilesystem
1147+
1148+setup_writeOption "$VSERVER_NAME"
1149+setup_writeInitialFstab
1150+
1151+test -z "$BUILD_INITPRE" || "$BUILD_INITPRE" "$SETUP_CONFDIR" "$UTIL_VSERVER_VARS"
1152+rpm.initDB "$SETUP_CONFDIR"
1153+rpm.importGPGPubKeys "$SETUP_CONFDIR" \
1154+ "$__CONFDIR/.distributions/$DISTRIBUTION/pubkeys" \
1155+ "$__CONFDIR/.distributions/.common/pubkeys" \
1156+ "$__DISTRIBDIR/$DISTRIBUTION/pubkeys"
1157+
1158+$_VPOLDEK "$SETUP_CONFDIR" -- --update-whole
1159+poldek.installBasePackages "$SETUP_CONFDIR" "$PKGINSTALLDIR"
1160+test -z "$BUILD_INITPOST" || "$BUILD_INITPOST" "$SETUP_CONFDIR" "$UTIL_VSERVER_VARS"
1161+
1162+base.setSuccess
This page took 0.304835 seconds and 4 git commands to generate.