mirror of
https://github.com/samba-team/samba.git
synced 2024-12-25 23:21:54 +03:00
r14151: Add simple script that writes a summary to show what libraries the user
(might) be missing.
This commit is contained in:
parent
fc991c61b3
commit
ee90b80679
@ -1,3 +1,4 @@
|
||||
- subdir handler for install headers into a specific directory
|
||||
- sonames
|
||||
- hack for loading modules locally
|
||||
- create
|
||||
|
@ -2,6 +2,7 @@
|
||||
# - create output for build.h
|
||||
#
|
||||
# Copyright (C) Stefan (metze) Metzmacher 2004
|
||||
# Copyright (C) Jelmer Vernooij 2005
|
||||
# Released under the GNU GPL
|
||||
|
||||
package header;
|
||||
|
@ -33,10 +33,7 @@ sub str2array($)
|
||||
sub check_subsystem($$$)
|
||||
{
|
||||
my ($INPUT, $subsys, $default_ot) = @_;
|
||||
if ($subsys->{ENABLE} ne "YES") {
|
||||
printf("Subsystem `%s' disabled\n",$subsys->{NAME});
|
||||
return;
|
||||
}
|
||||
return if ($subsys->{ENABLE} ne "YES");
|
||||
|
||||
unless(defined($subsys->{OUTPUT_TYPE})) {
|
||||
$subsys->{OUTPUT_TYPE} = $default_ot;
|
||||
@ -60,11 +57,7 @@ sub check_module($$$)
|
||||
return;
|
||||
}
|
||||
|
||||
if ($mod->{ENABLE} ne "YES")
|
||||
{
|
||||
printf("Module `%s' disabled\n",$mod->{NAME});
|
||||
return;
|
||||
}
|
||||
return if ($mod->{ENABLE} ne "YES");
|
||||
|
||||
if (exists($INPUT->{$mod->{SUBSYSTEM}}{INIT_FUNCTION_TYPE})) {
|
||||
$mod->{INIT_FUNCTION_TYPE} = $INPUT->{$mod->{SUBSYSTEM}}{INIT_FUNCTION_TYPE};
|
||||
@ -91,10 +84,7 @@ sub check_library($$$)
|
||||
{
|
||||
my ($INPUT, $lib, $default_ot) = @_;
|
||||
|
||||
if ($lib->{ENABLE} ne "YES") {
|
||||
printf("Library `%s' disabled\n",$lib->{NAME});
|
||||
return;
|
||||
}
|
||||
return if ($lib->{ENABLE} ne "YES");
|
||||
|
||||
$lib->{OUTPUT_TYPE} = $default_ot;
|
||||
|
||||
@ -114,10 +104,7 @@ sub check_binary($$)
|
||||
{
|
||||
my ($INPUT, $bin) = @_;
|
||||
|
||||
if ($bin->{ENABLE} ne "YES") {
|
||||
printf("Binary `%s' disabled\n",$bin->{NAME});
|
||||
return;
|
||||
}
|
||||
return if ($bin->{ENABLE} ne "YES");
|
||||
|
||||
($bin->{BINARY} = (lc $bin->{NAME})) if not defined($bin->{BINARY});
|
||||
|
||||
|
@ -12,6 +12,7 @@ use smb_build::config_mk;
|
||||
use smb_build::output;
|
||||
use smb_build::env;
|
||||
use smb_build::cflags;
|
||||
use smb_build::summary;
|
||||
use config;
|
||||
use strict;
|
||||
|
||||
@ -81,4 +82,6 @@ header::create_smb_build_h($OUTPUT, "include/build.h");
|
||||
|
||||
cflags::create_cflags($OUTPUT, "extra_cflags.txt");
|
||||
|
||||
summary::show($OUTPUT, \%config::config);
|
||||
|
||||
1;
|
||||
|
51
source/build/smb_build/summary.pm
Normal file
51
source/build/smb_build/summary.pm
Normal file
@ -0,0 +1,51 @@
|
||||
# Samba Build System
|
||||
# - write out summary
|
||||
#
|
||||
# Copyright (C) Jelmer Vernooij 2006
|
||||
# Released under the GNU GPL
|
||||
|
||||
package summary;
|
||||
use strict;
|
||||
|
||||
sub showitem($$$)
|
||||
{
|
||||
my ($output,$desc,$items) = @_;
|
||||
|
||||
my @need = ();
|
||||
|
||||
foreach (@$items) {
|
||||
if ($output->{"EXT_LIB_$_"}->{ENABLE} ne "YES") {
|
||||
push (@need, $_);
|
||||
}
|
||||
}
|
||||
|
||||
print "Support for $desc: ";
|
||||
if ($#need > 0) {
|
||||
print "no (install " . join(',',@need) . ")\n";
|
||||
} else {
|
||||
print "yes\n";
|
||||
}
|
||||
}
|
||||
|
||||
sub show($$)
|
||||
{
|
||||
my ($output,$config) = @_;
|
||||
print "Summary:\n\n";
|
||||
showitem($output, "GTK+ frontends", ["gtk","gconf"]);
|
||||
showitem($output, "SSL in SWAT", ["GNUTLS"]);
|
||||
showitem($output, "threads in smbd", ["PTHREAD"]);
|
||||
showitem($output, "intelligent command line editing", ["READLINE"]);
|
||||
showitem($output, "changing process titles", ["SETPROCTITLE"]);
|
||||
print "Using external popt: $output->{EXT_LIB_POPT}->{ENABLE}\n";
|
||||
print "Using shared libraries internally (experimental): ";
|
||||
|
||||
if ($config->{BLDSHARED} eq "true") {
|
||||
print "yes\n";
|
||||
} else {
|
||||
print "no (try --enable-dso)\n";
|
||||
|
||||
}
|
||||
print "\n";
|
||||
}
|
||||
|
||||
1;
|
Loading…
Reference in New Issue
Block a user