Go to:
Gentoo Home
Documentation
Forums
Lists
Bugs
Planet
Store
Wiki
Get Gentoo!
Gentoo's Bugzilla – Attachment 45042 Details for
Bug 70226
iptables/ip6tables can start after net
Home
|
New
–
[Ex]
|
Browse
|
Search
|
Privacy Policy
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Patches to dependancy scanning awk scripts
depscan.sh.diff.d (text/plain), 3.35 KB, created by
Ed Grimm
on 2004-12-01 01:39:36 UTC
(
hide
)
Description:
Patches to dependancy scanning awk scripts
Filename:
MIME Type:
Creator:
Ed Grimm
Created:
2004-12-01 01:39:36 UTC
Size:
3.35 KB
patch
obsolete
>--- /lib/rcscripts/awk/cachedepends.awk 2004-10-24 03:05:34.000000000 +0000 >+++ /lib/rcscripts/awk/cachedepends.awk 2004-11-24 08:20:33.204186536 +0000 >@@ -3,12 +3,14 @@ > # $Header: /home/cvsroot/gentoo-src/rc-scripts/src/awk/cachedepends.awk,v 1.17 2004/04/21 17:09:18 vapier Exp $ > > function print_start() { >- print "source /sbin/functions.sh" >> TMPCACHE >- print "" >> TMPCACHE > print "need() {" >> TMPCACHE > print " echo \"NEED $*\"; return 0" >> TMPCACHE > print "}" >> TMPCACHE > print "" >> TMPCACHE >+ print "needsme() {" >> TMPCACHE >+ print " echo \"NEEDSME $*\"; return 0" >> TMPCACHE >+ print "}" >> TMPCACHE >+ print "" >> TMPCACHE > print "use() {" >> TMPCACHE > print " echo \"USE $*\"; return 0" >> TMPCACHE > print "}" >> TMPCACHE >--- /lib/rcscripts/awk/gendepends.awk 2004-11-24 01:28:58.000000000 +0000 >+++ /lib/rcscripts/awk/gendepends.awk 2004-11-24 08:13:00.177057128 +0000 >@@ -66,6 +66,34 @@ > return 1 > } > >+# bool add_deptree_item_by_name(name, type, item) >+# >+# Add an item(s) 'item' to the DEPTREE array at index [rcnumber,type] >+# >+function add_deptree_item_by_name(name, type, item) >+{ >+ if (IMPOSEDTREE[name,type] != "") >+ IMPOSEDTREE[name,type] = IMPOSEDTREE[name,type] " " item >+ else >+ IMPOSEDTREE[name,type] = item >+ >+ return 1 >+} >+ >+# array find_services(pat) >+# >+# Search for all services whose name matches the given pattern. >+# >+function find_services(pat) >+{ >+ delete FOUND_SERVICES >+ for (x = 1; x <= RC_NUMBER; ++x) { >+ if (match(DEPTREE[x,NAME], pat)) { >+ FOUND_SERVICES[DEPTREE[x,NAME]] = 1; >+ } >+ } >+} >+ > # bool add_provide(service, provide) > # > # Add a name of a virtual service ('provide') that 'service' Provides >@@ -401,15 +429,20 @@ > add_db_entry(DEPTREE[RC_NUMBER,NAME], MTIME, $0) > } > } >+ >+ if ($1 == "NEEDSME") { >+ sub(/NEEDSME[[:space:]]*/, "") >+ >+ if ($0 != "") { >+ split($0, imposedupon, " ") >+ for (depend in imposedupon) >+ add_deptree_item_by_name(imposedupon[depend], >+ NEED, DEPTREE[RC_NUMBER,NAME]) >+ } >+ } > } > > END { >- # Add the 'net' service if it do not exist ... >- if (!check_service("net")) { >- RC_NUMBER++ >- DEPTREE[RC_NUMBER,NAME] = "net" >- } >- > # Calculate all the provides and parallels ... > for (x = 1;x <= RC_NUMBER;x++) { > >@@ -420,20 +453,37 @@ > add_parallel(DEPTREE[x,NAME], DEPTREE[x,PARALLEL]) > } > >+ # Add the 'net' service if it do not exist ... >+ if (!check_service("net")) { >+ RC_NUMBER++ >+ DEPTREE[RC_NUMBER,NAME] = "net" >+ } >+ > # Now do NEED, USE, BEFORE and AFTER > for (x = 1;x <= RC_NUMBER;x++) { > >+ name=DEPTREE[x,NAME] >+ > if ((x,NEED) in DEPTREE) >- resolve_depend(NEED, DEPTREE[x,NAME], DEPTREE[x,NEED]) >+ resolve_depend(NEED, name, DEPTREE[x,NEED]) > > if ((x,USE) in DEPTREE) >- resolve_depend(USE, DEPTREE[x,NAME], DEPTREE[x,USE]) >+ resolve_depend(USE, name, DEPTREE[x,USE]) > > if ((x,BEFORE) in DEPTREE) >- resolve_depend(BEFORE, DEPTREE[x,NAME], DEPTREE[x,BEFORE]) >+ resolve_depend(BEFORE, name, DEPTREE[x,BEFORE]) > > if ((x,AFTER) in DEPTREE) >- resolve_depend(AFTER, DEPTREE[x,NAME], DEPTREE[x,AFTER]) >+ resolve_depend(AFTER, name, DEPTREE[x,AFTER]) >+ } >+ >+ # Now impose dependancies on other services (how rude!) >+ for (depend in IMPOSEDTREE) { >+ split(depend, nameandtype, SUBSEP) >+ find_services(nameandtype[1]) >+ for (service in FOUND_SERVICES) { >+ resolve_depend(nameandtype[2], service, IMPOSEDTREE[depend]) >+ } > } > > for (x = TYPES_MIN; x <= TYPES_MAX; x++)
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
Attachments on
bug 70226
:
44611
| 45042