gnuradio / pybombs

PyBOMBS (Python Build Overlay Managed Bundle System) is the GNU Radio install management system for resolving dependencies and pulling in out-of-tree projects.
https://gnuradio.org
GNU General Public License v3.0
415 stars 190 forks source link

Switch to source packager if dependencies were built from source #342

Open mbr0wn opened 8 years ago

mbr0wn commented 8 years ago

Say you have a dep tree as such:

pkg1
\-+ pkg2
  |
  \- pkg3

Now imagine you've installed pkg3 from source. The only correct way to continue is to also build pkg2 and pkg1 from source, too.

Currently, PyBOMBS doesn't do that. It'll build pkg3 from source, then the next leaf node (pkg2) has its completely own logic about choosing source or not. Same for pkg1.

This is why @mhostetter ran into #339.

The current behaviour is buggy, but this will require some more changes than a small bugfix, I guess.

NinjaComics commented 8 years ago

@mbr0wn Correct me if I am wrong, but shouldn't the approach to chose the packager be independent for each package ? Say I have ten packages under the main package to be installed, and if the tenth package is built from source, I will have to wait for a long time (depending upon the type of packages) to install the other 9 packages also from source, which is a time consuming process (building anything from source is always a tedious process ?).

mbr0wn commented 8 years ago

The fact that it takes time to build from source is inconsequential -- if you want a source build, it'll just take time. The idea of PyBOMBS is that it doesn't require handholding, so you can just kick off the build before you go to bed if you like.

Now, for the choice of packager, what you suggest is what we currently have. However, it doesn't really make sense. Say you request a source build of UHD, but for GNU Radio, you say 'pick whatever'. PyBOMBS will first install UHD from source. So far, so good. Now, in this prefix, you would expect other packages to use the UHD version you just built from source, right? However, in this case, PyBOMBS might decide to install GNU Radio via apt-get. This will pull in another, different UHD version through apt-get also (and thus pollute your system). Same goes for any other library -- if you've went out of your way to tell PyBOMBS to build it from source, you want to use it. The only way to use it is to also build dependees from source.