-
Notifications
You must be signed in to change notification settings - Fork 2
/
Copy pathREADME
167 lines (128 loc) · 6.61 KB
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
NAME
get-gauche.sh - Ensure Gauche availability
SYNOPSIS
get-gauche.sh [--system|--home|--current|--prefix PREFIX|--update]
[--auto][--version VERSION][--check-only][--force][--list]
[--skip-tests][--configure-args ARGS][--destdir DIR]
[--uninstall]
DESCRIPTION
The `get-gauche.sh` script is a convenient way to ensure Gauche installed
on the running platform. By default, it checks if the desired version
of Gauche is already installed, and if not, download the tarball and
install it.
It can also be used with distributing Gauche applications.
In the application's build or installation script, you can call
get-gauche.sh, so that the user won't need to install Gauche separately.
If --check-only option is given, the script only checks if Gauche
has already installed but does not attempt to download and install.
The installation location can be specified by --prefix, --system,
--home, --update or --current option. These options are mutually
exclusive. When none of these options is given, get-gauche.sh prompts
the user to enter the location. (The location must be specified
with --auto option.)
If --force options is given, the script always downloads and installs
Gauche, regardless of whether Gauche is already installed or not.
By default, installed Gauche is searched in $PATH as well as the
specified location. So, for example, if Gauche is installed under
/usr and 'get-gauche.sh --home' is run, and if it finds /usr/bin/gosh
and the version requirement is satisfied, it won't attempt to install
Gauche unless --force option is given. If you want to ensure that
desired Gauche is always installed under specified location, use
--fixed-path option.
If you don't have the write permission in the install destination,
get-gauche.sh asks you if it can use sudo to install Gauche.
You can use --sudo option to omit its asking.
OPTIONS
--auto
When get-gauche.sh finds Gauche needs to be installed, it proceed
to download and install without asking the user. By default,
the user is asked before download begins.
--check-only
detect Gauche and report result, but not to attempt download
and install.
--configure-args ARGS
Pass ARGS to `configure' script of Gauche. ARGS are passed as is.
--current
install Gauche under the current directory (e.g. ./bin/gosh for
executable, ./{lib,share}/gauche-x.x/ for libraries, etc.)
Equivalent to --prefix `pwd`.
--destdir DIR
set DESIDIR to DIR when run `male install'. This can be used to
prepare a binary tarball.
--fixed-path
detect Gauche only under prefix (specified by --prefix, --system,
--home or --current option). By default, get-gauche.sh also checks
under directories in PATH.
--force
regardless of the result of version check, always download and
install the specified version of Gauche.
--home
install Gauche under the user's home directory (e.g. $HOME/bin/gosh
for executable, $HOME/{lib,share}/gauche-x.x/ for libraries, etc.)
Equivalent to --preifx $HOME.
--keep-builddir
Do not remove build directory after installation. Useful for
troubleshooting. Build directory is created under the
current directory with a name 'build-YYYYMMDD_hhmmss.xxxxxx'
where 'YYYYMMDD_hhmmss' is the timestamp and 'xxxxxx' is a random
string.
--list
show valid Gauche versions for --version option and exit. No
other operations are performed.
--prefix PREFIX
install Gauche under PREFIX. The gosh executable is in PREFIX/bin,
binary libraries are in PREFIX/{lib,share}, etc.
--skip-tests
Skip running self-tests before installing, in the emergency case
when you have to do so.
DO NOT USE THIS, unless you know what you're doing.
--sudo
invoke 'make install' via sudo. Needed if you want to install
Gauche where you don't have write permissions. You may be asked
to type your password by sudo.
--uninstall
uninstall the version of Gauche which would've been installed if
this option weren't given. The other versions of Gauche remains,
if they exist. Note: This operation removes all the files of the
specified version, but may keep empty directories created by
installation.
--update
install Gauche under the same directory as the currently installed
one. If no previous installation is found, get-gauche.sh prompts the
user to type the directory.
--system
install Gauche under system directory.
Equivalent to --prefix /usr.
--version VERSION
specify the desired version of Gauche. VERSION can be a version
string (e.g. '0.9.5'), or either one of the following:
* 'latest' : The latest official release
* 'snapshot' : The latest "snapshot" release, usually suffixed with
'-p1' or -p2', if it's newer than the latest release. Otherwise,
the latest release.
* 'bleeding' : The latest "bleeding-edge" sources, which is created
daily automatically. Note that it may be unstable or even
doesn't build.
By default, 'latest' is assumed.
EXAMPLES
1. The simplest way to install the latest release. The user will be
asked install location. If there's already another Gauche installed,
its prefix is presented as the default install location.
$ get-gauche.sh
2. You want to have the latest release of Gauche. If the system
already has it, you can use it. Otherwise, install under your home
directory.
$ get-gauche.sh --home
3. You want to update installed Gauche to the latest snapshot. The
existing Gauche is installed in the system directory so you need to
use sudo to install.
$ get-gauche.sh --update --sudo --version snapshot
4. You distribute a Gauche application, and always want to use Gauche
0.9.4 under application-specific directory. You can run get-gauche.sh
during the build or installation process of your application as follows:
$ get-gauche.sh --version 0.9.4 --prefix /app/dir/gauche \
--fixed-path --auto
The --fixed-path option ignores other Gauches installed under PATH
but only checks /app/dir/gauche. If there's already 0.9.4 or later
Gauche under that directory, you'll use it. Otherwise that version
is downloaded and installed there.