aboutsummaryrefslogtreecommitdiffstats
path: root/admin
diff options
context:
space:
mode:
authorGerd Moellmann2001-10-19 11:31:22 +0000
committerGerd Moellmann2001-10-19 11:31:22 +0000
commit53e7bbb89f7ad9b07b281f2fe826167779863ade (patch)
treea69df901995c1da7133f55ff882183fbe862b53a /admin
parentc4e7e308b3e3b4f1911089b11a47d47b6198fec2 (diff)
downloademacs-53e7bbb89f7ad9b07b281f2fe826167779863ade.tar.gz
emacs-53e7bbb89f7ad9b07b281f2fe826167779863ade.zip
Add --help option. Add support for building
in arbitrary source trees.
Diffstat (limited to 'admin')
-rwxr-xr-xadmin/build-configs31
1 files changed, 30 insertions, 1 deletions
diff --git a/admin/build-configs b/admin/build-configs
index 521afb3acff..5827276bf5e 100755
--- a/admin/build-configs
+++ b/admin/build-configs
@@ -21,6 +21,11 @@
21 21
22# Build Emacs in several different configurations. 22# Build Emacs in several different configurations.
23 23
24require 5;
25use Getopt::Long;
26use File::Basename;
27use Cwd;
28
24@configs = 29@configs =
25 ( 30 (
26 ["--without-x", "--optim"], 31 ["--without-x", "--optim"],
@@ -39,7 +44,31 @@ unlink $log;
39 44
40$root = $ENV{"EMACS_ROOT"}; 45$root = $ENV{"EMACS_ROOT"};
41$root = "/gd/gnu/emacs" unless $root; 46$root = "/gd/gnu/emacs" unless $root;
42chdir ($root) or die "Cannot chdir to emacs"; 47
48$rc = GetOptions ("help" => \$help);
49if ($rc == 0 || $help)
50 {
51 print <<USAGE;
52build-configs
53
54Build Emacs in different configurations.
55
56--help show this help
57
58USAGE
59 exit 1;
60 }
61
62# Chdir to the top-level directory of the tree. If not in a tree
63# containing Emacs, use the default.
64
65while (! -f "src/emacs.c" && cwd () ne "/")
66 {
67 chdir "..";
68 }
69
70chdir $root if cwd () eq "/";
71print "Build in ", cwd (), "\n";
43 72
44foreach $config (@configs) 73foreach $config (@configs)
45 { 74 {