r21684: remove summary line for gtk code, as it's now maintained out-of-tree
[Samba.git] / source / build / smb_build / summary.pm
blob7b84266d62880470e0a365b608717cf7d00a5ea4
1 # Samba Build System
2 # - write out summary
4 # Copyright (C) Jelmer Vernooij 2006
5 # Released under the GNU GPL
7 package summary;
8 use strict;
10 sub enabled($)
12 my ($val) = @_;
14 return (defined($val) && $val =~ m/yes|true/i);
17 sub showitem($$$)
19 my ($output,$desc,$items) = @_;
21 my @need = ();
23 foreach (@$items) {
24 if (!enabled($output->{$_}->{ENABLE})) {
25 push (@need, $_);
29 print "Support for $desc: ";
30 if ($#need >= 0) {
31 print "no (install " . join(',',@need) . ")\n";
32 } else {
33 print "yes\n";
37 sub show($$)
39 my ($output,$config) = @_;
41 print "Summary:\n\n";
42 showitem($output, "SSL in SWAT and LDAP", ["GNUTLS"]);
43 showitem($output, "threads in smbd (see --with-pthread)", ["PTHREAD"]);
44 showitem($output, "intelligent command line editing", ["READLINE"]);
45 showitem($output, "changing process titles (see --with-setproctitle)", ["SETPROCTITLE"]);
46 showitem($output, "using extended attributes", ["XATTR"]);
47 showitem($output, "using libblkid", ["BLKID"]);
48 showitem($output, "using iconv", ["ICONV"]);
49 showitem($output, "using pam", ["PAM"]);
50 print "Using external popt: ".
51 (($output->{LIBPOPT}->{TYPE} eq "EXT_LIB")?"yes":"no")."\n";
52 print "Developer mode: ".(enabled($config->{developer})?"yes":"no")."\n";
53 print "Automatic dependencies: ".
54 (enabled($config->{automatic_dependencies})
55 ? "yes" : "no (install GNU make >= 3.81 and see --enable-automatic-dependencies)") .
56 "\n";
58 print "Building shared libraries: " .
59 (enabled($config->{BLDSHARED})
60 ? "yes" : "no (not supported on this system)") .
61 "\n";
62 print "Using shared libraries internally: " .
63 (enabled($config->{USESHARED})
64 ? "yes" : "no (specify --enable-dso)") .
65 "\n";
67 print "\n";