On Sat, 2006-08-19 at 01:32 -0700, Paul Traina wrote: > Eric & KP, > > Looks nice, been trying to catch up on things... > > Couple of questions, while we're doing the 3.0 flag day, would it be OK > if we made the package dependancies explicit, not part of the help file? > > /var/lib/apkg/<packagename>.depend
I have this implemented in apk-tools. Take a look there how it can be implemented and feel free to reuse the code if possible. http://apk-tools.sourceforge.net (use svn version. I have made some progress since latest oficial release) > which would contain a list of packages that the current package depends upon > one per line: > e.g. > > $ cat /var/lib/apkg/tcpdump.depend > libpcap > > $ cat /var/lib/apkg/easyrsa.depend > openssl > > The dependencies should theoretically be recursive (there are pros and cons). > > easyrsa would depend upon openssl (but not directly on libssl) > openssl should depend upon libssl > > The pro is that indirect dependencies really shouldn't exist. The con is > that this could lead a naive user to have to do more lrpkg's or reboots, > however he does his test installs. > > $ lrpkg -i /mnt/easyrsa > lrpkg: not installing easyrsa, openssl required > > $ lrpkg --fulfill-dependencies -i /mnt/easyrsa > lrpkg: installing openssl > lrpkg: installing libssl > lrpkg: installing libcrpto > > If a dependency wasn't there... > > $ lrpkg --fulfil-dependancies -i /mnt/easyrsa > lrpkg: installing openssl > lrpkg: installing libssl > lrpkg: not installing easyrsa, openssl, libssl: libcrpto not found > > > In any case, the magic needed to be done to apkg/lrpkg can come later, > but we need to get the new hooks into the package control files sooner > rather than later. > > I propose modifying the XML to formalize the dependancies instead of > putting them in the help file, and creating <packagename>.depend control > files. > > What do you guys think? Its relatively easy to automatically find out the dependencies. find [ all elf files ] | while read elffile ; do for so in `readelf -d $elffile |\ grep NEEDED |\ sed 's/.*Shared library: //; s/\[\(.*\)\]/\1/'` ; do dep=`find_lrp_that_has_file $so` add_dependency $dep done done So you shouldn't need to figure out all dependencies by hand. -- Natanael Copa ------------------------------------------------------------------------- Using Tomcat but need to do more? Need to support web services, security? Get stuff done quickly with pre-integrated technology to make your job easier Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 _______________________________________________ leaf-devel mailing list leaf-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/leaf-devel