41 |
|
|
42 |
progname="$0" |
progname="$0" |
43 |
## Default location to place it is /usr/local |
## Default location to place it is /usr/local |
44 |
|
|
45 |
prefix=/usr/local |
prefix=/usr/local |
46 |
if [ $1 ]; then |
with_config=yes |
|
prefix="$1" |
|
|
fi |
|
47 |
|
|
48 |
|
ac_prev= |
49 |
|
display_usage=false; |
50 |
|
config_options=--without-x |
51 |
|
while test $# != 0 |
52 |
|
do |
53 |
|
if test -n "$ac_prev"; then |
54 |
|
eval "$ac_prev=\$1" |
55 |
|
ac_prev= |
56 |
|
continue |
57 |
|
fi |
58 |
|
case $1 in |
59 |
|
-help | --help | --hel | --he | -h) |
60 |
|
display_usage=yes ;; |
61 |
|
-p | -prefix | --p | --prefix) |
62 |
|
ac_prev=prefix ;; |
63 |
|
-p=* | -prefix=* | --p=* | --prefix=*) |
64 |
|
prefix=`expr "x$1" : 'x[^=]*=\(.*\)'` ;; |
65 |
|
-no-configure | -no-conf | --no-configure | --no-conf) |
66 |
|
with_config=no ;; |
67 |
|
-with-x | --with-x) |
68 |
|
config_options= ;; |
69 |
|
esac |
70 |
|
shift |
71 |
|
done |
72 |
|
|
73 |
|
if test "$display_usage" = "yes"; then |
74 |
|
cat <<EOF |
75 |
|
\`make-package' generates a Mac OS X package from an Emacs distribution. |
76 |
|
By default, this first runs ./configure on the emacs directory. Then |
77 |
|
make install to create the emacs distribution. Then some mac-specific |
78 |
|
commands to generate the required information for the mac package. |
79 |
|
|
80 |
|
Usage: $0 [OPTION] |
81 |
|
|
82 |
|
Options: |
83 |
|
-h, --help display this help and exit |
84 |
|
--prefix=DIR Set install location for the Mac OS X package |
85 |
|
of the emacs related file. By default /usr/local |
86 |
|
--no-conf Do not run the configure script before running |
87 |
|
make install. |
88 |
|
--with-x Setup the install to use X Windows for its |
89 |
|
windowed display, instead of carbon. |
90 |
|
EOF |
91 |
|
exit 0 |
92 |
|
fi |
93 |
|
|
94 |
### Exit if a command fails. |
### Exit if a command fails. |
95 |
#set -e |
#set -e |
170 |
|
|
171 |
echo Installing into directory ${tempparentfull} >&2 |
echo Installing into directory ${tempparentfull} >&2 |
172 |
|
|
173 |
(cd ..; ./configure --without-x --prefix=${prefix}; make install prefix=${tempparentfull}${prefix}) |
if test "$with_config" = yes; then |
174 |
|
(cd ..; ./configure ${config_options} --prefix=${prefix};) |
175 |
|
fi |
176 |
|
|
177 |
|
(cd ..; make install prefix=${tempparentfull}${prefix}) |
178 |
|
|
179 |
### This trap ensures that the staging directory will be cleaned up even |
### This trap ensures that the staging directory will be cleaned up even |
180 |
### when the script is interrupted in mid-career. |
### when the script is interrupted in mid-career. |
264 |
rm -rf Emacs.pkg |
rm -rf Emacs.pkg |
265 |
|
|
266 |
### make-package ends here |
### make-package ends here |
|
|
|