Installing Dependencies.

I am trying to use the RUNTIME_DEPENDENCY system to install the shared libraries and dlls that have been linked to in my project. But just those.

Our build server puts our builds in an opt folder, either /opt or c:/opt and I link thru various import and module or config normal methods.

I cannot find information on what each of the Pre and Post Include and exclude regexs are and have been unsuccessful in linux especially getting it to not include a bunch of extra dependencies it should not.

Can I exclude all "" then include /opt/

PRE lists are used to ignore references coming from scanned files. POST lists are used to handle recursion on matching library dependencies. It should be enough to use POST_INCLUDE_REGEXES /opt/.* to handle this case.

I still cannot get this to NOT include all the libs in the system including libc

Hrm. Some debugging support for the logic would be useful I suppose (akin to --debug-find).

I added a PRE_EXCLUDE on /lib to exclude the system and got rid of the libc and such.

It exposed and interesting point in that it is actually ignoring my installed openssl build and grabbing the one in the OS so those disappeared from the install.

A little coffee in the morning should fix that right up.

I have scrapped this idea, It is way to much like File GLOBing and as soon as I fixed one I had the side effect of breaking another. Very Very fragile.

IMHO, This should not be dnoe this way, using dumpbin/ldd can easily introduce errors.

I have specified all paths, and found all libs, that list should be translatable into dll/so names.

Perhaps this really should be the package maintainer responsibility, A target property like libraries and includes. i,e, INSTALL( FILES {FOO}_INSTALL_DEPENDENCIES) DESTINATION .)

In the Linux world it would probably be better if I made them dependencies of the package system but for now I am just going to use install (FILES… with generator expressions as needed using the variables used for finding the dependencies. It is simple, deterministic and will get the job done.

( at least until I cross compile…)

12+ hours fighting this automatic feature, < 1 hour to just do it manually. It is a small project.