vircadia / vircadia-builder

Builds Vircadia's native Interface and Domain server ("Project Athena") on Linux.
GNU General Public License v3.0
20 stars 37 forks source link

When using installable Qt libraries, Qt is not added to --get-source-deps list #63

Open Misterblue opened 3 years ago

Misterblue commented 3 years ago

If relying on the --get-source-deps feature to get the list of dependent libraries, when vircadia-builder decides the installable Qt library is sufficient (doesn't need to build Qt), it doesn't add Qt to the output of the dependent libraries.

I'm building Docker images and the target image is the built Vircadia binaries plus the dependent libraries. Previously I copied /opt/vircadia/qt5-install/lib into the target image but, if vircadia-builder decides to use the installable Qt, that directory doesn't exist and Qt is not listed in dependent libraries. Because of Docker limitations, it's hard to test if the directory exists.

Could you add Qt to the list of dependent libraries if the installable library is available.

daleglass commented 3 years ago

The different --get-*deps arguments just retrieve the contents of the different sections of the data files, and they don't do any work like concatenating lists together currently. There is:

So to get the full list of dependencies for a system you'll need two of those: --get-source-deps, and whatever Qt approach you're going to use.

Misterblue commented 3 years ago

Is there an external way for a script to tell which Qt has been chosen? That is, how can my script know when Qt is built and when it is to be installed?

I need this because my Docker image build is in two steps where one builds Vircadia and its dependencies and later another image is created that is just the VIrcadia binaries plus its runtime dependencies. For that later image, I need to know whether to copy the built Qt or to install the system Qt. I think I can pull that off if my scripts can somehow sense which choice was made by vircadia-builder.

JulianGro commented 3 years ago

You could run ldd interface on the Interface binary and it will tell you which libraries are getting used and where they are. If it's downloaded or built Qt it will be in ~/Vircadia/qt-install/ or whatever directory you chose for building, and if it's system Qt it will be in a system folder like /usr/lib/x86_64-linux-gnu/ (they are here on Ubuntu 18.04)