3 # Find dependancies. Simple dpkg-shlibdeps wrapper.
5 BEGIN { push @INC, "debian", "/usr/share/debhelper" }
9 foreach $PACKAGE (@{$dh{DOPACKAGES}}) {
10 $TMP=tmpdir($PACKAGE);
11 $EXT=pkgext($PACKAGE);
16 # Generate a list of ELF binaries in the package, ignoring any
17 # we were told to exclude.
18 if (! defined($dh{EXCLUDE_FIND}) || $dh{EXCLUDE_FIND} eq '') {
22 $find_options="! \\( $dh{EXCLUDE_FIND} \\)";
24 foreach $file (split(/\n/,`find $TMP -type f \\( -perm +111 -or -name "*.so*" \\) $find_options`)) {
25 # TODO: this is slow, optimize. Ie, file can run once on multiple files..
27 if ($ff=~m/ELF/ && $ff!~/statically linked/) {
33 $ENV{'LD_LIBRARY_PATH'}=$dh{L_PARAMS}
37 doit("dpkg-shlibdeps","-Tdebian/$EXT\substvars",@{$dh{U_PARAMS}},'-dDepends',@filelist);