summaryrefslogtreecommitdiff
path: root/source4/build/smb_build/main.pm
diff options
context:
space:
mode:
authorJelmer Vernooij <jelmer@samba.org>2004-11-14 16:22:01 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 13:05:47 -0500
commit8e16d8a76f8a3b8ccc89eb317c8e5daa6cf43b71 (patch)
tree8e8ccaddb94efc6a85ab6c339cab76cea1f44085 /source4/build/smb_build/main.pm
parent7367d23713a34a6c29a492adb365292399adffe8 (diff)
downloadsamba-8e16d8a76f8a3b8ccc89eb317c8e5daa6cf43b71.tar.gz
samba-8e16d8a76f8a3b8ccc89eb317c8e5daa6cf43b71.tar.bz2
samba-8e16d8a76f8a3b8ccc89eb317c8e5daa6cf43b71.zip
r3733: More build system fixes/features:
- Use .mk files directly (no need for a SMB_*_MK() macro when adding a new SUBSYSTEM, MODULE or BINARY). This allows addition of new modules and subsystems without running configure - Add support for generating .dot files with the Samba4 dependency tree (as used by the graphviz and springgraph utilities) (This used to be commit 64826da834e26ee0488674e27a0eae36491ee179)
Diffstat (limited to 'source4/build/smb_build/main.pm')
-rw-r--r--source4/build/smb_build/main.pm11
1 files changed, 11 insertions, 0 deletions
diff --git a/source4/build/smb_build/main.pm b/source4/build/smb_build/main.pm
index 50aae15fdc..324b8adc61 100644
--- a/source4/build/smb_build/main.pm
+++ b/source4/build/smb_build/main.pm
@@ -12,6 +12,7 @@ use input;
use config_mk;
use output;
use direct;
+use dot;
use strict;
sub smb_build_main($)
@@ -21,6 +22,12 @@ sub smb_build_main($)
INPUT => $INPUT
);
+ my @mkfiles = split /\n/, `find -name "*.mk"`;
+
+ for my $mkfile (@mkfiles) {
+ config_mk::import_file($SMB_BUILD_CTX{INPUT}, $mkfile);
+ }
+
%{$SMB_BUILD_CTX{DEPEND}} = input::check(\%SMB_BUILD_CTX);
%{$SMB_BUILD_CTX{OUTPUT}} = output::create_output($SMB_BUILD_CTX{DEPEND});
@@ -28,5 +35,9 @@ sub smb_build_main($)
makefile::create_makefile_in($SMB_BUILD_CTX{OUTPUT});
smb_build_h::create_smb_build_h($SMB_BUILD_CTX{OUTPUT});
+
+ open DOTTY, ">samba4-deps.dot";
+ print DOTTY dot::generate($SMB_BUILD_CTX{DEPEND});
+ close DOTTY;
}
1;