On 01/11/2015 18:51, Bruce Dubbs wrote: > Pierre Labastie wrote: >> Hi, >> >> I do not know who monitors this list, > > I do that. > >> Now, the BLFS part offers much more room for improvement: > > I don't use jhalfs for BLFS, but there are a couple of tools I'd like to see > for it. I'd like a tool to print out the dependency tree for a package. For > instance, > > dependencies package-name [required | all] > > would look at the dependencies of for example, parted, and give a tree of > packages needed. The normal output would be required+recommended, but the > optional argument 'required' would give just required dependencies while 'all' > would give required+recommended+optional. It would look something like: > > $ dependencies parted > parted-3.2 > LVM2-2.02.133 > > $ dependencies parted all > parted-3.2 > LVM2-2.02.133 > mdadm-3.3.4 > reiserfsprogs-3.6.24 > Valgrind-3.11.0 > Boost-1.59.0 > ICU-56.1 > LLVM-3.7.0 (with Clang) > Python-2.7.10 > libffi-3.2.1 > DejaGnu-1.5.3 > Expect-5.45 > DocBook-utils-0.6.14 > OpenJade-1.3.2, docbook-dsssl-1.79, and docbook-3.1 > SGMLSpm-1.1 > Lynx-2.8.8rel.2 or > OpenSSL-1.0.2d or > MIT Kerberos V5-1.13.2 > DejaGnu-1.5.3 > GnuPG-2.1.9 > keyutils-1.5.9 > OpenLDAP-2.4.42 > Python-2.7.10 > GnuTLS-3.4.6 > Zip-3.0 > UnZip-6.0 > MTA > Links-2.12 or > w3m-0.5.3 > docbook2X (external) > BlueZ-5.35 > *Valgrind-3.11.0 > OpenSSL-1.0.2d > SQLite-3.9.1 > Tk-8.6.4 > Open MPI (external) > *LLVM-3.7.0 (with Clang), > GDB-7.10 > libxslt-1.1.28 > texlive-20150521 > Which-2.21 > xfsprogs-4.2.0 > thin-provisioning-tools (external) > Pth-2.0.7 > texlive-20150521 > ghostscript-9.18 > FreeType-2.6.1 > libjpeg-turbo-1.4.2 > libpng-1.6.18 > LibTIFF-4.0.6 > Little CMS-2.7 > Cairo-1.14.4 > Cups-2.1.0 > Fontconfig-2.11.1 > GTK+-2.24.28 > libidn-1.32 > libpaper-1.1.24+nmu4 > Little CMS-1.19 > X Window System > > I wouldn't expand 'X Window System'. I didn't finish the above, but you get > the idea. This is far from a trivial program. The circular dependencies need > to be handled in some way and there probably would need to be some changes to > the book to flag dependency issues.
I almost have it. One tricky issue is to treat the "or", ","(comma), and "and" in the dependency lists. Right now, the tool treats those all the same (as an "and"). Also, there are sentences like "if you haven't installed <xref linkend="something"/>, then...", and the tools believes that "something" is a dependency. Analyzing natural language is not that easy... Also, the tool does not list external dependencies, although it is easy to add. Furthermore, right now, the leaves of the tree are not listed, but this is easy to add too. To test the the tool. From the jhalfs directory, type: ---- TRACKING_DIR=$HOME/blfs_root/trackdir ./install-blfs-tools.sh # a directory "blfs_root" is created in the home directory. cd ~/blfs_root # the tool has to be slightly modified for optional dependencies: sed '/dep_level=2/s/^/#/' -i libs/func_dependencies make #tick whatever packages you want to see, plus do not forget to choose the #dependency level at the bottom of the menu ----- You'll see that you get a lot of circular dependencies. You can answer no (the default) to all. Optional dependencies of lvm2 means 482 packages... Good luck! Actually, presently, required, recommended and optional dependencies are treated all the same. I think that there should be some priority (order of required deps is more important than that of optional ones...). Pierre -- http://lists.linuxfromscratch.org/listinfo/alfs-discuss FAQ: http://www.linuxfromscratch.org/faq/ Unsubscribe: See the above information page
