Last change
on this file since 414 was 414, checked in by Herwig Bauernfeind, 15 years ago |
Samba 3.5.0: Initial import
|
File size:
1.6 KB
|
Line | |
---|
1 | #!/bin/sh
|
---|
2 |
|
---|
3 | # Run this script to build samba from git.
|
---|
4 |
|
---|
5 | while true; do
|
---|
6 | case $1 in
|
---|
7 | --version-file)
|
---|
8 | VERSION_FILE=$2
|
---|
9 | shift 2
|
---|
10 | ;;
|
---|
11 | *)
|
---|
12 | break
|
---|
13 | ;;
|
---|
14 | esac
|
---|
15 | done
|
---|
16 |
|
---|
17 | ## insert all possible names (only works with
|
---|
18 | ## autoconf 2.x)
|
---|
19 | TESTAUTOHEADER="autoheader autoheader-2.53 autoheader2.50 autoheader259 autoheader253"
|
---|
20 | TESTAUTOCONF="autoconf autoconf-2.53 autoconf2.50 autoconf259 autoconf253"
|
---|
21 |
|
---|
22 | AUTOHEADERFOUND="0"
|
---|
23 | AUTOCONFFOUND="0"
|
---|
24 |
|
---|
25 | if which which > /dev/null 2>&1; then
|
---|
26 | echo -n
|
---|
27 | else
|
---|
28 | echo "$0: need 'which' to figure out if we have the right autoconf to build samba from git" >&2
|
---|
29 | exit 1
|
---|
30 | fi
|
---|
31 | ##
|
---|
32 | ## Look for autoheader
|
---|
33 | ##
|
---|
34 | for i in $TESTAUTOHEADER; do
|
---|
35 | if which $i > /dev/null 2>&1; then
|
---|
36 | if test `$i --version | head -n 1 | cut -d. -f 2 | sed "s/[^0-9]//g"` -ge 53; then
|
---|
37 | AUTOHEADER=$i
|
---|
38 | AUTOHEADERFOUND="1"
|
---|
39 | break
|
---|
40 | fi
|
---|
41 | fi
|
---|
42 | done
|
---|
43 |
|
---|
44 | ##
|
---|
45 | ## Look for autoconf
|
---|
46 | ##
|
---|
47 |
|
---|
48 | for i in $TESTAUTOCONF; do
|
---|
49 | if which $i > /dev/null 2>&1; then
|
---|
50 | if test `$i --version | head -n 1 | cut -d. -f 2 | sed "s/[^0-9]//g"` -ge 53; then
|
---|
51 | AUTOCONF=$i
|
---|
52 | AUTOCONFFOUND="1"
|
---|
53 | break
|
---|
54 | fi
|
---|
55 | fi
|
---|
56 | done
|
---|
57 |
|
---|
58 |
|
---|
59 | ##
|
---|
60 | ## do we have it?
|
---|
61 | ##
|
---|
62 | if test "$AUTOCONFFOUND" = "0" -o "$AUTOHEADERFOUND" = "0"; then
|
---|
63 | echo "$0: need autoconf 2.53 or later to build samba from git" >&2
|
---|
64 | exit 1
|
---|
65 | fi
|
---|
66 |
|
---|
67 | echo "$0: running script/mkversion.sh"
|
---|
68 | ./script/mkversion.sh $VERSION_FILE || exit 1
|
---|
69 |
|
---|
70 | rm -rf autom4te*.cache
|
---|
71 | rm -f configure include/config_tmp.h*
|
---|
72 |
|
---|
73 | IPATHS="-I. -I../lib/replace"
|
---|
74 |
|
---|
75 | echo "$0: running $AUTOHEADER $IPATHS"
|
---|
76 | $AUTOHEADER $IPATHS || exit 1
|
---|
77 |
|
---|
78 | echo "$0: running $AUTOCONF $IPATHS"
|
---|
79 | $AUTOCONF $IPATHS || exit 1
|
---|
80 |
|
---|
81 | rm -rf autom4te*.cache
|
---|
82 |
|
---|
83 | echo "Now run ./configure (or ./configure.developer) and then make."
|
---|
84 | exit 0
|
---|
Note:
See
TracBrowser
for help on using the repository browser.