Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 1690 lines (1384 sloc) 67.242 kb
d0cc4b2 New installer and exclusions file
slef authored
1 # Copyright 2007 MJ Ray
2 #
3 # This file is part of Koha.
4 #
5 # Koha is free software; you can redistribute it and/or modify it under the
6 # terms of the GNU General Public License as published by the Free Software
7 # Foundation; either version 2 of the License, or (at your option) any later
8 # version.
9 #
10 # Koha is distributed in the hope that it will be useful, but WITHOUT ANY
11 # WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
12 # A PARTICULAR PURPOSE. See the GNU General Public License for more details.
13 #
14 # You should have received a copy of the GNU General Public License along with
15 # Koha; if not, write to the Free Software Foundation, Inc., 59 Temple Place,
16 # Suite 330, Boston, MA 02111-1307 USA
17 #
18 # Current maintainer MJR http://mjr.towers.org.uk/
19 # See http://www.koha.org/wiki/?page=KohaInstaller
7d99474 Corrected CGI copy to include entire 'installer' subdir structure
Chris Nighswonger authored
20 #
faaf13a Cleaned up recursion routine a bit
Chris Nighswonger authored
21
5befdd2 installer (part 2): more work
Galen Charlton authored
22 use strict;
23 use warnings;
d0cc4b2 New installer and exclusions file
slef authored
24 use ExtUtils::MakeMaker;
25 use POSIX;
44efd0f installer (part 1): started major changes
Galen Charlton authored
26 use File::Spec;
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
27 use Getopt::Long;
d0cc4b2 New installer and exclusions file
slef authored
28
5befdd2 installer (part 2): more work
Galen Charlton authored
29 my $DEBUG = 0;
b8e6e70 @pjones9 Updates to module requirements listed in installer files
pjones9 authored
30 die "perl 5.10.0 or later required" unless ($] >= 5.010000);
d0cc4b2 New installer and exclusions file
slef authored
31
faaf13a Cleaned up recursion routine a bit
Chris Nighswonger authored
32 # Hash up directory structure & files beginning with the directory we were called from (should be the base of koha)...
33
34 my $dirtree = hashdir('.');
35 my %result = ();
36
d0cc4b2 New installer and exclusions file
slef authored
37 =head1 NAME
38
39 Makefile.PL - Koha packager and installer
40
41 =head1 SYNOPSIS
42
61190e9 @mjray New installation instructions and release notes.
mjray authored
43 =head2 BASIC INSTALLATION
44
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
45 perl Makefile.PL
46 make
47 make test
48 sudo make install
49
50 =head2 UPGRADE INSTALLATION
981a345 Clairifying pod for upgrade and correcting dmake message for Win32
Chris Nighswonger authored
51
52 NOTE: This option is only available if koha-install-log exists.
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
53
54 perl Makefile.PL --prev-install-log /path/to/koha-install-log
55
56 make
57 make test
58 sudo make upgrade
61190e9 @mjray New installation instructions and release notes.
mjray authored
59
60 =head2 PACKAGING RELEASE TARBALLS
61
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
62 make manifest tardist
63 make manifest zipdist
d0cc4b2 New installer and exclusions file
slef authored
64
61190e9 @mjray New installation instructions and release notes.
mjray authored
65 =head2 CLEANING UP
66
67 make clean
68
d0cc4b2 New installer and exclusions file
slef authored
69 =head1 DESCRIPTION
70
44efd0f installer (part 1): started major changes
Galen Charlton authored
71 This is a packager and installer that uses
d0cc4b2 New installer and exclusions file
slef authored
72 ExtUtils::MakeMaker, which is fairly common
73 on perl systems.
74 As well as building tar or zip files
61190e9 @mjray New installation instructions and release notes.
mjray authored
75 and installing with the above commands,
d0cc4b2 New installer and exclusions file
slef authored
76 it allows us to check pre-requisites
77 and generate configuration files.
78
79 =head1 VARIABLES
80
e449c13 @mjray Add configuration file helper to the installer
mjray authored
81 =head2 NAME, VERSION_FROM, ABSTRACT, AUTHOR
d0cc4b2 New installer and exclusions file
slef authored
82
83 Basic metadata about this software.
84
85 =head2 NO_META
86
87 Suppress generation of META.yml file.
88
89 =head2 PREREQ_PM
90
91 Hash of perl modules and versions required.
92
93 =head2 PM
94
95 Hash of file mappings
96
97 =head2 PL_FILES
98
99 This is a hash of PL scripts to run after installation and
100 the files to ask them to generate.
101 Maybe use the values from CONFIGURE
61190e9 @mjray New installation instructions and release notes.
mjray authored
102 to generate initial configuration files in future.
d0cc4b2 New installer and exclusions file
slef authored
103
104 =cut
105
44efd0f installer (part 1): started major changes
Galen Charlton authored
106 =head2 target_map
4b1d132 More work on the installer, just have to fix make now
Chris Cormack authored
107
44efd0f installer (part 1): started major changes
Galen Charlton authored
108 This is a hash mapping directories and files in the
109 source tree to installation target directories. The rules
110 for this mapping are:
4b1d132 More work on the installer, just have to fix make now
Chris Cormack authored
111
44efd0f installer (part 1): started major changes
Galen Charlton authored
112 =over 4
677f10b Working on the installer setting up the right zebra config
Chris Cormack authored
113
44efd0f installer (part 1): started major changes
Galen Charlton authored
114 =item If a directory or file is specified, it and its
115 contents will be copied to the installation target directory.
116
117 =item If a subdirectory of a mapped directory is specified,
118 its target overrides the parent's target for that subdirectory.
119
120 =item The value of each map entry may either be a scalar containing
c31b5c2 installer: moved web template dirs; got rid of multi-targets
Galen Charlton authored
121 one target or a reference to a hash containing 'target' and 'trimdir'
122 keys.
44efd0f installer (part 1): started major changes
Galen Charlton authored
123
124 =item Any files at the top level of the source tree that are
125 not included in the map will not be installed.
126
127 =item Any directories at the top level of the source tree
128 that are not included in the map will be installed in
129 INTRANET_CGI_DIR. This is a sensible default given the
130 current organization of the source tree, but (FIXME) it
131 would be better to reorganize the source tree to better
132 match the installation system, to allow adding new directories
133 without having to adjust Makefile.PL each time. The idea
5befdd2 installer (part 2): more work
Galen Charlton authored
134 is to make the C<$target_map> hash as minimal as possible.
44efd0f installer (part 1): started major changes
Galen Charlton authored
135
136 =back
137
138 The permitted installation targets are:
139
140 =over 4
141
142 =item INTRANET_CGI_DIR
143
144 CGI scripts for intranet (staff) interface.
145
146 =item INTRANET_TMPL_DIR
147
148 HTML templates for the intranet interface.
149
150 =item INTRANET_WWW_DIR
151
152 HTML files, images, etc. for DocumentRoot for the intranet interface.
153
154 =item OPAC_CGI_DIR
155
156 CGI scripts for OPAC (public) interface.
157
158 =item OPAC_TMPL_DIR
159
160 HTML templates for the OPAC interface.
161
162 =item OPAC_WWW_DIR
163
164 HTML files, images, etc. for DocumentRoot for the OPAC interface.
165
166 =item PERL_MODULE_DIR
167
168 Perl modules (at present just the C4 modules) that are intimately
169 tied to Koha. Depending on the installation options, these
170 may or may not be installed one of the standard directories
171 in Perl's default @LIB.
172
173 =item KOHA_CONF_DIR
174
175 Directory for Koha configuration files.
176
177 =item ZEBRA_CONF_DIR
178
179 Directory for Zebra configuration files.
180
5befdd2 installer (part 2): more work
Galen Charlton authored
181 =item ZEBRA_LOCK_DIR
182
183 Directory for Zebra's lock files.
184
185 =item ZEBRA_DATA_DIR
186
187 Directory for Zebra's data files.
188
189 =item ZEBRA_RUN_DIR
190
191 Directory for Zebra's UNIX-domain sockets.
192
1b71360 installer: various changes
Galen Charlton authored
193 =item MISC_DIR
5befdd2 installer (part 2): more work
Galen Charlton authored
194
1b71360 installer: various changes
Galen Charlton authored
195 Directory for for miscellaenous scripts, among other
196 things the translation toolkit and RSS feed tools.
5befdd2 installer (part 2): more work
Galen Charlton authored
197
198 =item SCRIPT_DIR
199
f20a581 kohabug 1776 - enable daemon controls scripts for 'dev' mode
Galen Charlton authored
200 Directory for command-line scripts and daemons to
201 be set up all for installation modes.
202
203 =item SCRIPT_NONDEV_DIR
204
205 Directory for command-line scripts that should
206 be installed in the same directory as the
207 SCRIPT_DIR target except 'dev' installs.
5befdd2 installer (part 2): more work
Galen Charlton authored
208
209 =item MAN_DIR
210
211 Directory for man pages created from POD -- will mostly
212 contain information of interest to Koha developers.
213
214 =item DOC_DIR
215
216 Directory for Koha documentation accessed from the
217 command-line, e.g., READMEs.
218
219 =item LOG_DIR
220
221 Directory for Apache and Zebra logs produced by Koha.
222
70dccac FRBR: configure PazPar2 during installation
Galen Charlton authored
223 =item PAZPAR2_CONF_DIR
224
225 Directory for PazPar2 configuration files.
226
44efd0f installer (part 1): started major changes
Galen Charlton authored
227 =item NONE
228
229 This is a dummy target used to explicitly state
230 that a given file or directory is not to be installed.
231 This is used either for parts of the installer itself
232 or for development tools that are not applicable to a
233 production installation.
234
235 =back
236
237 =cut
238
5befdd2 installer (part 2): more work
Galen Charlton authored
239 my $target_map = {
240 './about.pl' => 'INTRANET_CGI_DIR',
241 './acqui' => 'INTRANET_CGI_DIR',
242 './admin' => 'INTRANET_CGI_DIR',
243 './authorities' => 'INTRANET_CGI_DIR',
65c19cc @ctfliblime Moving everything around and ditching kohaversion.pl
ctfliblime authored
244 './lib/C4' => 'PERL_MODULE_DIR',
245 './lib/C4/SIP/t' => 'NONE',
246 './lib/C4/SIP/koha_test' => 'NONE',
247 './lib/C4/tests' => 'NONE',
5befdd2 installer (part 2): more work
Galen Charlton authored
248 './catalogue' => 'INTRANET_CGI_DIR',
249 './cataloguing' => 'INTRANET_CGI_DIR',
c31b5c2 installer: moved web template dirs; got rid of multi-targets
Galen Charlton authored
250 './changelanguage.pl' => 'INTRANET_CGI_DIR',
5befdd2 installer (part 2): more work
Galen Charlton authored
251 './check_sysprefs.pl' => 'NONE',
252 './circ' => 'INTRANET_CGI_DIR',
e512077 Tweak offline_circ - honor itemBarcodeInputFilter and add to Makefile.PL
Michael Hafen authored
253 './offline_circ' => 'INTRANET_CGI_DIR',
5befdd2 installer (part 2): more work
Galen Charlton authored
254 './edithelp.pl' => 'INTRANET_CGI_DIR',
255 './etc' => { target => 'KOHA_CONF_DIR', trimdir => -1 },
256 './etc/zebradb' => { target => 'ZEBRA_CONF_DIR', trimdir => -1 },
70dccac FRBR: configure PazPar2 during installation
Galen Charlton authored
257 './etc/pazpar2' => { target => 'PAZPAR2_CONF_DIR', trimdir => -1 },
1b71360 installer: various changes
Galen Charlton authored
258 './help.pl' => 'INTRANET_CGI_DIR',
5befdd2 installer (part 2): more work
Galen Charlton authored
259 './installer-CPAN.pl' => 'NONE',
260 './installer' => 'INTRANET_CGI_DIR',
f53d084 bug 1803 - fix error page handling
Galen Charlton authored
261 './errors' => {target => 'INTRANET_CGI_DIR'},
5befdd2 installer (part 2): more work
Galen Charlton authored
262 './koha-tmpl/intranet-tmpl' => {target => 'INTRANET_TMPL_DIR', trimdir => -1},
c31b5c2 installer: moved web template dirs; got rid of multi-targets
Galen Charlton authored
263 './koha-tmpl/opac-tmpl' => {target => 'OPAC_TMPL_DIR', trimdir => -1},
5befdd2 installer (part 2): more work
Galen Charlton authored
264 './labels' => 'INTRANET_CGI_DIR',
265 './mainpage.pl' => 'INTRANET_CGI_DIR',
266 './Makefile.PL' => 'NONE',
267 './MANIFEST.SKIP' => 'NONE',
268 './members' => 'INTRANET_CGI_DIR',
f20a581 kohabug 1776 - enable daemon controls scripts for 'dev' mode
Galen Charlton authored
269 './misc' => { target => 'SCRIPT_NONDEV_DIR', trimdir => -1 },
e6ee69b various installer changes
Galen Charlton authored
270 './misc/bin' => { target => 'SCRIPT_DIR', trimdir => -1 },
bbd043f adding three new variables for installation:
Joshua Ferraro authored
271 './misc/release_notes' => { target => 'DOC_DIR', trimdir => 2 },
1b71360 installer: various changes
Galen Charlton authored
272 './misc/translator' => { target => 'MISC_DIR', trimdir => 2 },
82daf0a installer: added install log
Galen Charlton authored
273 './misc/koha-install-log' => { target => 'MISC_DIR', trimdir => -1 },
5befdd2 installer (part 2): more work
Galen Charlton authored
274 './misc/installer_devel_notes' => 'NONE',
275 './opac' => 'OPAC_CGI_DIR',
276 './README.txt' => 'NONE',
277 './reports' => 'INTRANET_CGI_DIR',
278 './reserve' => 'INTRANET_CGI_DIR',
279 './reviews' => 'INTRANET_CGI_DIR',
65c19cc @ctfliblime Moving everything around and ditching kohaversion.pl
ctfliblime authored
280 './installer/rewrite-config.PL' => 'NONE',
5befdd2 installer (part 2): more work
Galen Charlton authored
281 './reviews' => 'INTRANET_CGI_DIR',
282 './serials' => 'INTRANET_CGI_DIR',
65c19cc @ctfliblime Moving everything around and ditching kohaversion.pl
ctfliblime authored
283 './installer/skel' => 'NONE',
284 './installer/skel/var/log/koha' => { target => 'LOG_DIR', trimdir => -1 },
285 './installer/skel/var/run/koha/zebradb' => { target => 'ZEBRA_RUN_DIR', trimdir => -1 },
286 './installer/skel/var/lock/koha/zebradb/authorities' => { target => 'ZEBRA_LOCK_DIR', trimdir => 7 },
287 './installer/skel/var/lib/koha/zebradb/authorities/key' => { target => 'ZEBRA_DATA_DIR', trimdir => 7 },
288 './installer/skel/var/lib/koha/zebradb/authorities/register' => { target => 'ZEBRA_DATA_DIR', trimdir => 7 },
289 './installer/skel/var/lib/koha/zebradb/authorities/shadow' => { target => 'ZEBRA_DATA_DIR', trimdir => 7 },
290 './installer/skel/var/lib/koha/zebradb/authorities/tmp' => { target => 'ZEBRA_DATA_DIR', trimdir => 7 },
291 './installer/skel/var/lock/koha/zebradb/biblios' => { target => 'ZEBRA_LOCK_DIR', trimdir => 7 },
292 './installer/skel/var/lib/koha/zebradb/biblios/key' => { target => 'ZEBRA_DATA_DIR', trimdir => 7 },
293 './installer/skel/var/lib/koha/zebradb/biblios/register' => { target => 'ZEBRA_DATA_DIR', trimdir => 7 },
294 './installer/skel/var/lib/koha/zebradb/biblios/shadow' => { target => 'ZEBRA_DATA_DIR', trimdir => 7 },
295 './installer/skel/var/lib/koha/zebradb/biblios/tmp' => { target => 'ZEBRA_DATA_DIR', trimdir => 7 },
5befdd2 installer (part 2): more work
Galen Charlton authored
296 './sms' => 'INTRANET_CGI_DIR',
297 './suggestion' => 'INTRANET_CGI_DIR',
298 './svc' => 'INTRANET_CGI_DIR',
299 './t' => 'NONE',
3efe32e bug 2305: install tags/* to intranet CGI directory
Galen Charlton authored
300 './tags' => 'INTRANET_CGI_DIR',
1b71360 installer: various changes
Galen Charlton authored
301 './tmp' => 'NONE', # FIXME need to determine whether
302 # Koha generates any persistent temp files
303 # that should go in /var/tmp/koha
5befdd2 installer (part 2): more work
Galen Charlton authored
304 './tools' => 'INTRANET_CGI_DIR',
305 './virtualshelves' => 'INTRANET_CGI_DIR',
306 # ignore files and directories created by the install itself
307 './pm_to_blib' => 'NONE',
308 './blib' => 'NONE',
309 };
44efd0f installer (part 1): started major changes
Galen Charlton authored
310
311 =head1 CONFIGURATION OPTIONS
312
313 The following configuration options are used by the installer.
314
315 =over 4
316
317 =item INSTALL_MODE
318
319 Specifies whether installation will be FHS-compliant (default,
320 assumes user has root), put everything under
321 a single directory (for users installing on a web host
322 that allows CGI scripts and a MySQL database but not root
323 access), or development (for a developer who wants to run
324 Koha from a git clone with no fuss).
325
326 =item INSTALL_BASE
d0cc4b2 New installer and exclusions file
slef authored
327
44efd0f installer (part 1): started major changes
Galen Charlton authored
328 Directory under which most components will go. Default
329 value will vary depending on INSTALL_MODE.
330
1b71360 installer: various changes
Galen Charlton authored
331 =item DB_TYPE
332
333 Type of DBMS (e.g., mysql or Pg).
334
335 =item DB_HOST
336
337 Name of DBMS server.
338
339 =item DB_PORT
340
341 Port that DBMS server is listening on.
342
343 =item DB_NAME
344
345 Name of the DBMS database for Koha.
346
347 =item DB_USER
348
349 Name of DBMS user account for Koha's database.
350
351 =item DB_PASS
352
353 Pasword of DMBS user account for Koha's database.
354
44efd0f installer (part 1): started major changes
Galen Charlton authored
355 =item INSTALL_ZEBRA
356
357 Whether to install Zebra configuration files and data
358 directories.
359
360 =item ZEBRA_MARC_FORMAT
361
362 Specifies format of MARC records to be indexed by Zebra.
363
364 =item ZEBRA_LANGUAGE
365
366 Specifies primary language of records that will be
367 indexed by Zebra.
368
1b71360 installer: various changes
Galen Charlton authored
369 =item ZEBRA_USER
370
371 Internal Zebra user account for the index.
372
373 =item ZEBRA_PASS
374
375 Internal Zebra user account's password.
376
377 =item KOHA_USER
378
379 System user account that will own Koha's files.
380
381 =item KOHA_GROUP
382
383 System group that will own Koha's files.
384
44efd0f installer (part 1): started major changes
Galen Charlton authored
385 =back
386
387 =cut
388
389 # default configuration options
390 my %config_defaults = (
bd0877f installer: prompt for more configuration parameters
Galen Charlton authored
391 'DB_TYPE' => 'mysql',
392 'DB_HOST' => 'localhost',
393 'DB_NAME' => 'koha',
394 'DB_USER' => 'kohaadmin',
395 'DB_PASS' => 'katikoan',
44efd0f installer (part 1): started major changes
Galen Charlton authored
396 'INSTALL_ZEBRA' => 'yes',
ecc8e2c @ctfliblime Update installer for koha-conf.xml <basedir> directive
ctfliblime authored
397 'INSTALL_SRU' => 'no',
70dccac FRBR: configure PazPar2 during installation
Galen Charlton authored
398 'INSTALL_PAZPAR2' => 'no',
ecc8e2c @ctfliblime Update installer for koha-conf.xml <basedir> directive
ctfliblime authored
399 'AUTH_INDEX_MODE' => 'dom',
44efd0f installer (part 1): started major changes
Galen Charlton authored
400 'ZEBRA_MARC_FORMAT' => 'marc21',
401 'ZEBRA_LANGUAGE' => 'en',
bd0877f installer: prompt for more configuration parameters
Galen Charlton authored
402 'ZEBRA_USER' => 'kohauser',
403 'ZEBRA_PASS' => 'zebrastripes',
bbd043f adding three new variables for installation:
Joshua Ferraro authored
404 'ZEBRA_SRU_HOST' => 'localhost',
405 'ZEBRA_SRU_BIBLIOS_PORT' => '9998',
406 'ZEBRA_SRU_AUTHORITIES_PORT' => '9999',
be79314 installer: start support for non-root file owner
Galen Charlton authored
407 'KOHA_USER' => 'koha',
408 'KOHA_GROUP' => 'koha',
70dccac FRBR: configure PazPar2 during installation
Galen Charlton authored
409 'MERGE_SERVER_HOST' => 'localhost',
410 'MERGE_SERVER_PORT' => '11001',
411 'PAZPAR2_HOST' => 'localhost',
412 'PAZPAR2_PORT' => '11002',
8056846 @amoore improvements to automated tests, including a testing database
amoore authored
413 'RUN_DATABASE_TESTS' => 'no',
2fafa14 kohabug 1776 - try to locate Zebra during install
Galen Charlton authored
414 'PATH_TO_ZEBRA' => '',
e16e920 @ranginui Updating the Makefile so memcached configuration can be added to the koh...
ranginui authored
415 'USE_MEMCACHED' => 'no',
416 'MEMCACHED_SERVERS' => '127.0.0.1:11211',
417 'MEMCACHED_NAMESPACE' => 'KOHA'
44efd0f installer (part 1): started major changes
Galen Charlton authored
418 );
419
e64f395 @Elwell Minor documentation typos
Elwell authored
420 # set some default configuration options based on OS
118283b Initial work on adding Win32 support to installer.
Chris Nighswonger authored
421 # more conditions need to be added for other OS's
422 # this should probably also incorporate usage of Win32::GetOSName() and/or Win32::GetOSVersion()
423 # to allow for more granular decisions based on which Win32 platform
424
425 warn "Your platform appears to be $^O.\n" if $DEBUG;
426
427 if ( $^O eq 'MSWin32' ) {
428 # Most Unix2Win32 ports seem to poke everything into the Program Files directory
429 # this could be changed to put some files (ie. libraries) into system32, etc.
430 $config_defaults{'INSTALL_MODE'} = 'single';
431 $config_defaults{'INSTALL_BASE'} = 'c:/progra~1/koha'; # Use 8.3 names to be safe...
432 }
433 elsif ( $^O eq 'cygwin' ) {
434 # Most Unix2Win32 ports seem to poke everything into the Program Files directory
435 # this could be changed to put some files (ie. libraries) into system32, etc.
436 $config_defaults{'INSTALL_MODE'} = 'single';
437 $config_defaults{'INSTALL_BASE'} = 'c:/progra~1/koha'; # Use 8.3 names to be safe...
438 }
439 else {
ecc8e2c @ctfliblime Update installer for koha-conf.xml <basedir> directive
ctfliblime authored
440 $config_defaults{'INSTALL_MODE'} = 'dev';
118283b Initial work on adding Win32 support to installer.
Chris Nighswonger authored
441 $config_defaults{'INSTALL_BASE'} = '/usr/share/koha';
442 }
443
44efd0f installer (part 1): started major changes
Galen Charlton authored
444 # valid values for certain configuration options
445 my %valid_config_values = (
446 'INSTALL_MODE' => { 'standard' => 1, 'single' => 1, 'dev' => 1 },
bd0877f installer: prompt for more configuration parameters
Galen Charlton authored
447 'DB_TYPE' => { 'mysql' => 1, 'Pg' => 1 },
44efd0f installer (part 1): started major changes
Galen Charlton authored
448 'INSTALL_ZEBRA' => { 'yes' => 1, 'no' => 1 },
bbd043f adding three new variables for installation:
Joshua Ferraro authored
449 'INSTALL_SRU' => { 'yes' => 1, 'no' => 1 },
1c0401e authorities - enabled DOM indexing
Galen Charlton authored
450 'AUTH_INDEX_MODE' => { 'grs1' => 1, 'dom' => 1 },
44efd0f installer (part 1): started major changes
Galen Charlton authored
451 'ZEBRA_MARC_FORMAT' => { 'marc21' => 1, 'unimarc' => 1 }, # FIXME should generate from contents of distributation
452 'ZEBRA_LANGUAGE' => { 'en' => 1, 'fr' => 1 }, # FIXME should generate from contents of distribution
8056846 @amoore improvements to automated tests, including a testing database
amoore authored
453 'RUN_DATABASE_TESTS' => { 'yes' => 1, 'no' => 1 },
e16e920 @ranginui Updating the Makefile so memcached configuration can be added to the koh...
ranginui authored
454 'USE_MEMCACHED' => { 'yes' => 1, 'no' => 1 },
44efd0f installer (part 1): started major changes
Galen Charlton authored
455 );
456
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
457 # get settings from command-line
458 my $koha_install_log = "";
459 Getopt::Long::Configure('pass_through');
460 my $results = GetOptions(
461 "prev-install-log=s" => \$koha_install_log
462 );
463
464 my %install_log_values = ();
465 if ($koha_install_log ne "") {
466 get_install_log_values($koha_install_log, \%install_log_values);
467 }
468
469 my %config = get_configuration(\%config_defaults, \%valid_config_values, \%install_log_values);
1b71360 installer: various changes
Galen Charlton authored
470 my ($target_directories, $skip_directories) = get_target_directories(\%config);
471 display_configuration(\%config, $target_directories);
5befdd2 installer (part 2): more work
Galen Charlton authored
472 my $file_map = {};
3b58e09 installer: now respects INSTALL_ZEBRA = no
Galen Charlton authored
473 get_file_map($target_map, $dirtree, $file_map, $config{'INSTALL_ZEBRA'} eq "yes" ? 1: 0);
474
475 my $pl_files = {
65c19cc @ctfliblime Moving everything around and ditching kohaversion.pl
ctfliblime authored
476 'installer/rewrite-config.PL' => [
3b58e09 installer: now respects INSTALL_ZEBRA = no
Galen Charlton authored
477 'blib/KOHA_CONF_DIR/koha-conf.xml',
82daf0a installer: added install log
Galen Charlton authored
478 'blib/MISC_DIR/koha-install-log'
4c991a4 Win32 support: Moved shebang sub to separate script to be called in pl_f...
Chris Nighswonger authored
479 ],
3b58e09 installer: now respects INSTALL_ZEBRA = no
Galen Charlton authored
480 };
481
482 if ($config{'INSTALL_ZEBRA'} eq "yes") {
65c19cc @ctfliblime Moving everything around and ditching kohaversion.pl
ctfliblime authored
483 push @{ $pl_files->{'installer/rewrite-config.PL'} }, (
f5903fb installer: location of koha-conf.xml
Galen Charlton authored
484 'blib/ZEBRA_CONF_DIR/etc/passwd',
485 'blib/ZEBRA_CONF_DIR/zebra-biblios.cfg',
bbd043f adding three new variables for installation:
Joshua Ferraro authored
486 'blib/ZEBRA_CONF_DIR/zebra-authorities.cfg',
1c0401e authorities - enabled DOM indexing
Galen Charlton authored
487 'blib/ZEBRA_CONF_DIR/zebra-authorities-dom.cfg',
bbd043f adding three new variables for installation:
Joshua Ferraro authored
488 'blib/ZEBRA_CONF_DIR/explain-authorities.xml',
1c0401e authorities - enabled DOM indexing
Galen Charlton authored
489 'blib/ZEBRA_CONF_DIR/explain-biblios.xml',
490 'blib/ZEBRA_CONF_DIR/retrieval-info-auth-grs1.xml',
491 'blib/ZEBRA_CONF_DIR/retrieval-info-auth-dom.xml',
f5903fb installer: location of koha-conf.xml
Galen Charlton authored
492 );
65c19cc @ctfliblime Moving everything around and ditching kohaversion.pl
ctfliblime authored
493 push @{ $pl_files->{'installer/rewrite-config.PL'} }, (
f20a581 kohabug 1776 - enable daemon controls scripts for 'dev' mode
Galen Charlton authored
494 'blib/SCRIPT_DIR/koha-zebra-ctl.sh',
495 'blib/SCRIPT_DIR/koha-pazpar2-ctl.sh',
496 'blib/SCRIPT_DIR/koha-zebraqueue-ctl.sh',
497 );
70dccac FRBR: configure PazPar2 during installation
Galen Charlton authored
498 if ($config{'INSTALL_PAZPAR2'} eq 'yes') {
65c19cc @ctfliblime Moving everything around and ditching kohaversion.pl
ctfliblime authored
499 push @{ $pl_files->{'installer/rewrite-config.PL'} }, (
70dccac FRBR: configure PazPar2 during installation
Galen Charlton authored
500 'blib/PAZPAR2_CONF_DIR/koha-biblios.xml',
501 'blib/PAZPAR2_CONF_DIR/pazpar2.xml'
502 );
503 }
1c0401e authorities - enabled DOM indexing
Galen Charlton authored
504 $config{'ZEBRA_AUTH_CFG'} = $config{'AUTH_INDEX_MODE'} eq 'dom' ? 'zebra-authorities-dom.cfg' : 'zebra-authorities.cfg';
505 $config{'AUTH_RETRIEVAL_CFG'} =
506 $config{'AUTH_INDEX_MODE'} eq 'dom' ? 'retrieval-info-auth-dom.xml' : 'retrieval-info-auth-grs1.xml';
f5903fb installer: location of koha-conf.xml
Galen Charlton authored
507 }
508
509 if ($config{'INSTALL_MODE'} ne "dev") {
65c19cc @ctfliblime Moving everything around and ditching kohaversion.pl
ctfliblime authored
510 push @{ $pl_files->{'installer/rewrite-config.PL'} }, (
511 'blib/PERL_MODULE_DIR/lib/C4/Context.pm',
f20a581 kohabug 1776 - enable daemon controls scripts for 'dev' mode
Galen Charlton authored
512 'blib/SCRIPT_NONDEV_DIR/kohalib.pl'
3b58e09 installer: now respects INSTALL_ZEBRA = no
Galen Charlton authored
513 );
514 }
44efd0f installer (part 1): started major changes
Galen Charlton authored
515
33036c4 test suite - various changes
Galen Charlton authored
516 my %test_suite_override_dirs = (
517 KOHA_CONF_DIR => ['etc'],
518 ZEBRA_CONF_DIR => ['etc', 'zebradb'],
519 LOG_DIR => ['var', 'log'],
520 SCRIPT_DIR => ['bin'],
521 ZEBRA_LOCK_DIR => ['var', 'lock', 'zebradb'],
522 ZEBRA_DATA_DIR => ['var', 'lib', 'zebradb'],
523 ZEBRA_RUN_DIR => ['var', 'run', 'zebradb'],
524 );
525
44efd0f installer (part 1): started major changes
Galen Charlton authored
526 WriteMakefile(
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
527 NAME => 'koha',
528 #VERSION => strftime('2.9.%Y%m%d%H',gmtime),
65c19cc @ctfliblime Moving everything around and ditching kohaversion.pl
ctfliblime authored
529 #VERSION_FROM => 'kohaversion.pl',
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
530 ABSTRACT => 'Award-winning integrated library system (ILS) and Web OPAC',
531 AUTHOR => 'Koha Developers <koha-devel@nongnu.org>',
532 NO_META => 1,
533 PREREQ_PM => {
50533a1 @Elwell Consistency check between Makefile.pl and about.pl We weren't picking up...
Elwell authored
534 'Algorithm::CheckDigits' => 0.50,
b8e6e70 @pjones9 Updates to module requirements listed in installer files
pjones9 authored
535 'Attribute::Handlers' => 0.79,
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
536 'Biblio::EndnoteStyle' => 0.05,
a438d95 @dlbptfs Allows for search by equivalent ISBN-10 and ISBN-13
dlbptfs authored
537 'Business::ISBN' => 2.05,
b8e6e70 @pjones9 Updates to module requirements listed in installer files
pjones9 authored
538 'Cache::Memcached' => 1.24,
539 'Cache::Memcached::Fast' => 0.19,
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
540 'CGI' => 3.15,
541 'CGI::Carp' => 1.29,
c33f42a @ctfliblime Update deps in Makefile.PL
ctfliblime authored
542 'CGI::Compile' => 0.15,
b8e6e70 @pjones9 Updates to module requirements listed in installer files
pjones9 authored
543 'CGI::Cookie' => 1.29,
c33f42a @ctfliblime Update deps in Makefile.PL
ctfliblime authored
544 'CGI::Emulate::PSGI' => 0.14,
50533a1 @Elwell Consistency check between Makefile.pl and about.pl We weren't picking up...
Elwell authored
545 'CGI::Session' => 4.20,
546 'CGI::Session::Serialize::yaml' => 4.20,
c33f42a @ctfliblime Update deps in Makefile.PL
ctfliblime authored
547 'CHI' => 0.49,
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
548 'Class::Factory::Util' => 1.6,
549 'Class::Accessor' => 0.30,
b8e6e70 @pjones9 Updates to module requirements listed in installer files
pjones9 authored
550 'Clone' => 0.31,
551 'DateTime' => 0.65,
552 'DateTime::Format::DateParse' => 0.05,
553 'DateTime::Format::Strptime' => 1.5000,
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
554 'DBD::mysql' => 4.004,
b8e6e70 @pjones9 Updates to module requirements listed in installer files
pjones9 authored
555 'DBD::SQLite' => 0.33, # optional, used for offline circulation
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
556 'DBI' => 1.53,
d431080 @ctfliblime Utilize DBIx::Connector for C4::Context
ctfliblime authored
557 'DBIx::Connector' => 0.47,
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
558 'Data::Dumper' => 2.121,
50533a1 @Elwell Consistency check between Makefile.pl and about.pl We weren't picking up...
Elwell authored
559 'Data::ICal' => 0.13,
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
560 'Date::Calc' => 5.4,
561 'Date::ICal' => 1.72,
562 'Date::Manip' => 5.44,
563 'Digest::MD5' => 2.36,
54f7ca4 @laurenthdl bug 3204: implement request signing for Amazon Web Services
laurenthdl authored
564 'Digest::SHA' => 5.43,
f896384 @PaulPoulain Adding Email::Date dependancy, requested by MIME::Lite
PaulPoulain authored
565 'Email::Date' => 1.103,
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
566 'File::Temp' => 0.16,
72e2ead @ctfliblime Instantiate sysprefs by defaults file.
ctfliblime authored
567 'File::Slurp' => 9999.13,
639a3cf kohabug 2457 Minor patch to correct GD
Chris Nighswonger authored
568 'GD' => 2.39, #optional
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
569 'GD::Barcode::UPCE' => 1.1,
570 'Getopt::Long' => 2.35,
571 'Getopt::Std' => 1.05,
572 'HTML::Template::Pro' => 0.69,
573 'HTML::Scrubber' => 0.08,
574 'HTTP::Cookies' => 1.39,
c263446 @ctfliblime Update Makefile.PL with new dependencies
ctfliblime authored
575 'HTTP::Exception' => 0.03001,
9c4a717 added dependencies for new OAI-PMH server
Galen Charlton authored
576 'HTTP::OAI' => 3.20,
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
577 'HTTP::Request::Common' => 1.26,
5cd357e @gmcharlt bug 3465: enhance DB update reporting by web installer
gmcharlt authored
578 'IPC::Cmd' => 0.46,
50533a1 @Elwell Consistency check between Makefile.pl and about.pl We weren't picking up...
Elwell authored
579 'JSON' => 2.07, # Needed by admin/item_circulation_alerts.pl
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
580 'LWP::Simple' => 1.41,
581 'LWP::UserAgent' => 2.033,
582 'Lingua::Stem' => 0.82,
583 'List::Util' => 1.18,
584 'List::MoreUtils' => 0.21,
585 'Locale::Language' => 2.07,
586 'MARC::Charset' => 0.98,
587 'MARC::Crosswalk::DublinCore' => 0.02,
588 'MARC::File::XML' => 0.88,
589 'MARC::Record' => 2.00,
590 'MIME::Base64' => 3.07,
d0c0df9 @amoore Bug 2274: reducing MIME::Lite requirement to 3.0
amoore authored
591 'MIME::Lite' => 3.00,
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
592 'MIME::QuotedPrint' => 3.07,
593 'Mail::Sendmail' => 0.79,
e16e920 @ranginui Updating the Makefile so memcached configuration can be added to the koh...
ranginui authored
594 'Memoize::Memcached' => 0.03, # optional
c1ea667 @ctfliblime [Fixes #11958287] Use branch categories to constrain OPAC searches
ctfliblime authored
595 'Modern::Perl' => 1.03,
c263446 @ctfliblime Update Makefile.PL with new dependencies
ctfliblime authored
596 'Moose' => 2.0006,
597 'MooseX::Role::Parameterized' => 0.26,
e257a1d @ctfliblime [#16336565] Replace Net::CIDR::Compare with Net::IP
ctfliblime authored
598 'Net::IP' => 1.25,
4bc2303 @mjray Note optional modules, for later reference.
mjray authored
599 'Net::LDAP' => 0.33, # optional
600 'Net::LDAP::Filter' => 0.14, # optional
b8e6e70 @pjones9 Updates to module requirements listed in installer files
pjones9 authored
601 'Net::Server::PreFork' => 0.97,
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
602 'Net::Z3950::ZOOM' => 1.16,
603 'PDF::API2' => 2.000,
604 'PDF::API2::Page' => 2.000,
605 'PDF::API2::Util' => 2.000,
606 'PDF::Reuse' => 0.33,
607 'PDF::Reuse::Barcode' => 0.05,
c263446 @ctfliblime Update Makefile.PL with new dependencies
ctfliblime authored
608 'Plack' => 0.9978,
609 'Plack::Middleware::Deflater' => 0.03,
faf589e @ctfliblime [delivers #16336385] Deprecate Koha::Plack::ScrubStatus
ctfliblime authored
610 'Plack::Middleware::Header' => 0.04,
0af5ed8 @ctfliblime Update default psgi for expires and warn prefixes
ctfliblime authored
611 'Plack::Middleware::Expires' => 0.03,
8de4dbf @ctfliblime Updates to default app.psgi and Plack utils
ctfliblime authored
612 'Plack::Middleware::HTTPExceptions' => 0.01,
4db7153 @ctfliblime [delivers #16371557] Cordon off administrative functions from web access
ctfliblime authored
613 'Plack::Middleware::Status' => 1.101150,
c263446 @ctfliblime Update Makefile.PL with new dependencies
ctfliblime authored
614 'Plack::Middleware::MethodOverride' => 0.10,
8de4dbf @ctfliblime Updates to default app.psgi and Plack utils
ctfliblime authored
615 'Plack::Middleware::ReverseProxy' => 0.09,
616 'Plack::Middleware::Rewrite' => 1.003,
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
617 'POE' => 0.9999,
618 'POSIX' => 1.09,
b8e6e70 @pjones9 Updates to module requirements listed in installer files
pjones9 authored
619 'Rose::DB' => 0.762,
620 'Rose::DB::Object' => 0.791,
621 'Rose::DB::Object::Helpers' => 0.784,
622 'Rose::DB::Object::Loader' => 0.787,
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
623 'Schedule::At' => 1.06,
4bc2303 @mjray Note optional modules, for later reference.
mjray authored
624 'SMS::Send' => 0.05, # optional
c263446 @ctfliblime Update Makefile.PL with new dependencies
ctfliblime authored
625 'Squatting' => 0.81,
626 'Squatting::On::PSGI' => 0.06,
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
627 'Term::ANSIColor' => 1.10,
628 'Test' => 1.25,
629 'Test::Harness' => 2.56,
2d87fbe @gmcharlt bumped up required version of Test::More
gmcharlt authored
630 'Test::More' => 0.80,
b8e6e70 @pjones9 Updates to module requirements listed in installer files
pjones9 authored
631 'Text::Aspell' => 0.04,
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
632 'Text::CSV' => 0.01,
633 'Text::CSV_XS' => 0.32,
634 'Text::Iconv' => 1.7,
635 'Text::Wrap' => 2005.082401,
b8e6e70 @pjones9 Updates to module requirements listed in installer files
pjones9 authored
636 'Tie::File' => '0.97_02',
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
637 'Time::HiRes' => 1.86,
638 'Time::localtime' => 1.02,
b8e6e70 @pjones9 Updates to module requirements listed in installer files
pjones9 authored
639 'Try::Tiny' => 0.06,
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
640 'Unicode::Normalize' => 0.32,
54f7ca4 @laurenthdl bug 3204: implement request signing for Amazon Web Services
laurenthdl authored
641 'URI::Escape' => 1.36,
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
642 'XML::Dumper' => 0.81,
643 'XML::LibXML' => 1.59,
644 'XML::LibXSLT' => 1.59,
b8e6e70 @pjones9 Updates to module requirements listed in installer files
pjones9 authored
645 'XML::SAX::ExpatXS' => 1.31,
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
646 'XML::SAX::ParserFactory' => 1.01,
9c4a717 added dependencies for new OAI-PMH server
Galen Charlton authored
647 'XML::SAX::Writer' => 0.44,
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
648 'XML::Simple' => 2.14,
649 'XML::RSS' => 1.31,
650 'YAML::Syck' => 0.71,
651 },
652
653 # File tree mapping
654 PM => $file_map,
655
656 # Man pages generated from POD
9087249 @vdanjean Add support for DESTDIR
vdanjean authored
657 # ExtUtils::MakeMaker already manage $(DESTDIR)
658 INSTALLMAN1DIR => File::Spec->catdir(_strip_destdir($target_directories->{'MAN_DIR'}), 'man1'),
659 INSTALLMAN3DIR => File::Spec->catdir(_strip_destdir($target_directories->{'MAN_DIR'}), 'man3'),
11aed99 @amoore Bug 2176: adding SMS::Send to list of dependencies
amoore authored
660
661 PL_FILES => $pl_files,
d0cc4b2 New installer and exclusions file
slef authored
662 );
663
664 =head1 FUNCTIONS
665
faaf13a Cleaned up recursion routine a bit
Chris Nighswonger authored
666 =head2 hashdir
d0cc4b2 New installer and exclusions file
slef authored
667
faaf13a Cleaned up recursion routine a bit
Chris Nighswonger authored
668 This function recurses through the directory structure and builds
669 a hash of hashes containing the structure with arrays holding filenames.
670 This directory hashing routine was taken from BrowserUK @ http://www.perlmonks.org/?node_id=219919
d0cc4b2 New installer and exclusions file
slef authored
671
672 =cut
673
faaf13a Cleaned up recursion routine a bit
Chris Nighswonger authored
674 sub hashdir{
675 my $dir = shift;
676 opendir my $dh, $dir or die $!;
677 my $tree = {}->{$dir} = {};
678 while( my $file = readdir($dh) ) {
61ca8a3 installer: use htdocs instead of www; handle .htaccess
Galen Charlton authored
679 next if $file =~ m/^\.{1,2}/ and $file !~ /^\.htaccess/; # .htaccess is a special case
faaf13a Cleaned up recursion routine a bit
Chris Nighswonger authored
680 my $path = $dir .'/' . $file;
681 $tree->{$file} = hashdir($path), next if -d $path;
682 push @{$tree->{'.'}}, $file;
683 }
684 return $tree;
685 }
d0cc4b2 New installer and exclusions file
slef authored
686
5befdd2 installer (part 2): more work
Galen Charlton authored
687 =head2 get_file_map
688
689 This function combines the target_map and file hash to
690 map each source file to its destination relative to
691 the set of installation targets.
692
693 Output will be a hash mapping from each source file
694 to its destination value, like this:
695
696 'mainpage.pl' => '$(INTRANET_CGI_DIR)/mainpage.pl'
697
698 =cut
699
700 sub get_file_map {
701 my $target_map = shift;
702 my $dirtree = shift;
703 my $file_map = shift;
3b58e09 installer: now respects INSTALL_ZEBRA = no
Galen Charlton authored
704 my $install_zebra = shift;
5befdd2 installer (part 2): more work
Galen Charlton authored
705 my $curr_path = @_ ? shift : ['.'];
706
707 # Traverse the directory tree.
708 # For each file or directory, identify the
709 # most specific match in the target_map
710 foreach my $dir (sort keys %{ $dirtree }) {
711 if ($dir eq '.') {
712 # deal with files in directory
713 foreach my $file (sort @{ $dirtree->{$dir} }) {
714 my $targetdir = undef;
715 my $matchlevel = undef;
716 # first, see if there is a match on this specific
717 # file in the target map
718 my $filepath = join("/", @$curr_path, $file);
719 if (exists $target_map->{$filepath}) {
720 $targetdir = $target_map->{$filepath};
721 $matchlevel = scalar(@$curr_path) + 1;
722 } else {
723 # no match on the specific file; look for
724 # a directory match
725 for (my $i = scalar(@$curr_path) - 1; $i >= 0; $i--) {
726 my $dirpath = join("/", @$curr_path[0..$i]);
727 if (exists $target_map->{$dirpath}) {
728 $targetdir = $target_map->{$dirpath};
729 $matchlevel = $i + 1;
730 last;
731 }
732 }
733 }
734 if (defined $targetdir) {
3b58e09 installer: now respects INSTALL_ZEBRA = no
Galen Charlton authored
735 _add_to_file_map($file_map, $targetdir, $curr_path, $file, $matchlevel, $install_zebra);
5befdd2 installer (part 2): more work
Galen Charlton authored
736 } else {
737 my $path = join("/", @$curr_path);
738 print "failed to map: $path/$file\n" if $DEBUG;
739 }
740 }
741 } else {
742 # dealing with subdirectory
743 push @$curr_path, $dir;
3b58e09 installer: now respects INSTALL_ZEBRA = no
Galen Charlton authored
744 get_file_map($target_map, $dirtree->{$dir}, $file_map, $install_zebra, $curr_path);
5befdd2 installer (part 2): more work
Galen Charlton authored
745 pop @$curr_path;
746 }
747 }
748 }
749
750 sub _add_to_file_map {
751 my $file_map = shift;
752 my $targetdir = shift;
753 my $curr_path = shift;
754 my $file = shift;
755 my $matchlevel = shift;
3b58e09 installer: now respects INSTALL_ZEBRA = no
Galen Charlton authored
756 my $install_zebra = shift;
5befdd2 installer (part 2): more work
Galen Charlton authored
757 my $dest_path = @_ ? shift : $curr_path;
758
759 # The target can be one of the following:
760 # 1. scalar representing target symbol
761 # 2. hash ref containing target and trimdir keys
762 #
763 # Consequently, this routine traverses this structure,
764 # calling itself recursively, until it deals with
765 # all of the scalar target symbols.
c31b5c2 installer: moved web template dirs; got rid of multi-targets
Galen Charlton authored
766 if (ref $targetdir eq 'HASH') {
5befdd2 installer (part 2): more work
Galen Charlton authored
767 my $subtarget = $targetdir->{target};
768 if (exists $targetdir->{trimdir}) {
769 # if we get here, we've specified that
770 # rather than installing the file to
771 # $(TARGET)/matching/dirs/subdirs/file,
772 # we want to install it to
773 # $(TARGET)/subdirs/file
774 #
775 # Note that this the only place where
776 # $matchlevel is used.
777 my @new_dest_path = @$dest_path;
778 if ($targetdir->{trimdir} == -1) {
779 splice @new_dest_path, 0, $matchlevel;
780 } else {
781 splice @new_dest_path, 0, $targetdir->{trimdir};
782 }
3b58e09 installer: now respects INSTALL_ZEBRA = no
Galen Charlton authored
783 _add_to_file_map($file_map, $subtarget, $curr_path, $file, $matchlevel, $install_zebra, \@new_dest_path);
5befdd2 installer (part 2): more work
Galen Charlton authored
784 } else {
785 # actually getting here means that the
786 # target was unnecessarily listed
787 # as a hash, but we'll forgive that
3b58e09 installer: now respects INSTALL_ZEBRA = no
Galen Charlton authored
788 _add_to_file_map($file_map, $subtarget, $curr_path, $file, $matchlevel, $install_zebra);
5befdd2 installer (part 2): more work
Galen Charlton authored
789 }
790 } elsif ($targetdir ne 'NONE' and $targetdir ne '') {
791 my $source = File::Spec->catfile(@$curr_path, $file);
792 my $destination = File::Spec->catfile('blib', $targetdir, @$dest_path, $file);
793 #print "$source => $destination\n"; # DEBUG
eebd56b install: handle spaces in file names
Galen Charlton authored
794 # quote spaces in file names
795 # FIXME: this is of questionable portability and
796 # probably depends on user's make recognizing this
797 # quoting syntax -- probably better to remove
798 # spaces and shell metacharacters from all file names
799 $source =~ s/ /\\ /g;
800 $destination =~ s/ /\\ /g;
3b58e09 installer: now respects INSTALL_ZEBRA = no
Galen Charlton authored
801
802 $file_map->{$source} = $destination unless (!$install_zebra and $targetdir =~ /ZEBRA/);
5befdd2 installer (part 2): more work
Galen Charlton authored
803 }
804 }
805
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
806 =head2 get_install_log_values
807
808 Reads value from the Koha install log specified by
809 --prev-install-log
810
811 =cut
812
813 sub get_install_log_values {
814 my $install_log = shift;
815 my $values = shift;
816
817 open LOG, "<$install_log" or die "Cannot open install log $install_log: $!\n";
818 while (<LOG>) {
819 chomp;
820 next if /^#/ or /^\s*$/;
821 next if /^=/;
822 next unless m/=/;
25e1b9e installer: added 'make upgrade' target
Galen Charlton authored
823 s/\s+$//g;
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
824 my ($key, $value) = split /=/, $_, 2;
825 $values->{$key} = $value;
826 }
827 close LOG;
828
829 print <<_EXPLAIN_INSTALL_LOG_;
830 Reading values from install log $install_log. You
831 will be prompted only for settings that have been
832 added since the last time you installed Koha. To
833 be prompted for all settings, run 'perl Makefile.PL'
834 without the --prev-install-log option.
835 _EXPLAIN_INSTALL_LOG_
836 }
837
5d6cc9c Makefile.PL - trivial perldoc correction
Joe Atzberger authored
838 =head2 get_configuration
44efd0f installer (part 1): started major changes
Galen Charlton authored
839
840 This prompts the user for various configuration options.
841
842 =cut
843
844 sub get_configuration {
845 my $defaults = shift;
846 my $valid_values = shift;
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
847 my $install_log_values = shift;
44efd0f installer (part 1): started major changes
Galen Charlton authored
848 my %config = ();
849
850 my $msg = q(
851 By default, Koha can be installed in one of three ways:
852
853 standard: Install files in conformance with the Filesystem
854 Hierarchy Standard (FHS). This is the default mode
855 and should be used when installing a production
856 Koha system. On Unix systems, root access is
857 needed to complete a standard installation.
858
859 single: Install files under a single directory. This option
860 is useful for installing Koha without root access, e.g.,
861 on a web host that allows CGI scripts and MySQL databases
862 but requires the user to keep all files under the user's
863 HOME directory.
864
865 dev: Create a set of symbolic links and configuration files to
866 allow Koha to run directly from the source distribution.
867 This mode is useful for developers who want to run
868 Koha from a git clone.
869
d7a09ca installer: modified wording of some questions
Galen Charlton authored
870 Installation mode);
44efd0f installer (part 1): started major changes
Galen Charlton authored
871 $msg .= _add_valid_values_disp('INSTALL_MODE', $valid_values);
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
872 $config{'INSTALL_MODE'} = _get_value('INSTALL_MODE', $msg, $defaults->{'INSTALL_MODE'}, $valid_values, $install_log_values);
44efd0f installer (part 1): started major changes
Galen Charlton authored
873
874 # set message and default value for INSTALL_BASE
875 # depending on value of INSTALL_MODE
876 my $install_base_default = $defaults->{'INSTALL_BASE'};
877 if ($config{'INSTALL_MODE'} eq 'dev') {
878 $msg = q(
879 Please specify the directory in which to install Koha's
880 active configuration files and (if applicable) the
881 Zebra database. Koha's CGI scripts and templates will
d7a09ca installer: modified wording of some questions
Galen Charlton authored
882 be run from the current directory.
883
884 Configuration directory:);
44efd0f installer (part 1): started major changes
Galen Charlton authored
885 # FIXME - home directory portability consideration apply
118283b Initial work on adding Win32 support to installer.
Chris Nighswonger authored
886 $install_base_default = (exists $ENV{'HOME'}) ? "$ENV{'HOME'}/koha-dev" : "$defaults->{'INSTALL_BASE'}-dev";
44efd0f installer (part 1): started major changes
Galen Charlton authored
887 } elsif ($config{'INSTALL_MODE'} eq 'single') {
888 $msg = "\nPlease specify the directory in which to install Koha";
889 # FIXME -- we're assuming under a 'single' mode install
890 # that user will likely want to install under the home
891 # directory. This is OK in and of itself, but we should
892 # use File::HomeDir to locate the home directory portably.
893 # This is deferred for now because File::HomeDir is not yet
894 # core.
118283b Initial work on adding Win32 support to installer.
Chris Nighswonger authored
895 # --we must also keep this portable to the major OS's -fbcit
896 $install_base_default = (exists $ENV{'HOME'}) ? "$ENV{'HOME'}/koha" : $defaults->{'INSTALL_BASE'};
44efd0f installer (part 1): started major changes
Galen Charlton authored
897 } else {
898 # must be standard
899 $msg = q(
900 Please specify the directory under which most Koha files
901 will be installed.
902
903 Note that if you are planning in installing more than
904 one instance of Koha, you may want to modify the last
905 component of the directory path, which will be used
d7a09ca installer: modified wording of some questions
Galen Charlton authored
906 as the package name in the FHS layout.
907
908 Base installation directory);
44efd0f installer (part 1): started major changes
Galen Charlton authored
909 }
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
910 $config{'INSTALL_BASE'} = _get_value('INSTALL_BASE', $msg, $install_base_default, $valid_values, $install_log_values);
44efd0f installer (part 1): started major changes
Galen Charlton authored
911
118283b Initial work on adding Win32 support to installer.
Chris Nighswonger authored
912 $config{'INSTALL_BASE'} = File::Spec->rel2abs($config{'INSTALL_BASE'});
913 print "INSTALL_BASE=$config{'INSTALL_BASE'}\r\n" if $DEBUG;
be79314 installer: start support for non-root file owner
Galen Charlton authored
914 if ($config{'INSTALL_MODE'} eq "standard") {
915 $msg = q(
916 Since you are using the 'standard' install
917 mode, you should run 'make install' as root.
918 However, it is recommended that a non-root
919 user (on Unix and Linux platforms) have
920 ownership of Koha's files, including the
921 Zebra indexes if applicable.
922
923 Please specify a user account. This
924 user account does not need to exist
925 right now, but it needs to exist
926 before you run 'make install'. Please
927 note that for security reasons, this
928 user should not be the same as the user
929 account Apache runs under.
930
931 User account);
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
932 $config{'KOHA_USER'} = _get_value('KOHA_USER', $msg, $defaults->{'KOHA_USER'}, $valid_values, $install_log_values);
be79314 installer: start support for non-root file owner
Galen Charlton authored
933
934 $msg = q(
935 Please specify the group that should own
936 Koha's files. As above, this group need
937 not exist right now, but should be created
938 before you run 'make install'.
939
940 Group);
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
941 $config{'KOHA_GROUP'} = _get_value('KOHA_GROUP', $msg, $defaults->{'KOHA_GROUP'}, $valid_values, $install_log_values);
be79314 installer: start support for non-root file owner
Galen Charlton authored
942 }
943
44efd0f installer (part 1): started major changes
Galen Charlton authored
944 $msg = q(
bd0877f installer: prompt for more configuration parameters
Galen Charlton authored
945 Please specify which database engine you will use
946 to store data in Koha. The choices are MySQL and
947 PostgreSQL; please note that at the moment
948 PostgreSQL support is highly experimental.
949
950 DBMS to use);
951 $msg .= _add_valid_values_disp('DB_TYPE', $valid_values);
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
952 $config{'DB_TYPE'} = _get_value('DB_TYPE', $msg, $defaults->{'DB_TYPE'}, $valid_values, $install_log_values);
bd0877f installer: prompt for more configuration parameters
Galen Charlton authored
953
954 $msg = q(
955 Please specify the name or address of your
956 database server. Note that the database
957 does not have to exist at this point, it
958 can be created after running 'make install'
959 and before you try using Koha for the first time.
960
961 Database server);
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
962 $config{'DB_HOST'} = _get_value('DB_HOST', $msg, $defaults->{'DB_HOST'}, $valid_values, $install_log_values);
bd0877f installer: prompt for more configuration parameters
Galen Charlton authored
963
964 $msg = q(
965 Please specify the port used to connect to the
966 DMBS);
967 my $db_port_default = $config{'DB_TYPE'} eq 'mysql' ? '3306' : '5432';
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
968 $config{'DB_PORT'} = _get_value('DB_PORT', $msg, $db_port_default, $valid_values, $install_log_values);
bd0877f installer: prompt for more configuration parameters
Galen Charlton authored
969
970 $msg = q(
971 Please specify the name of the database to be
972 used by Koha);
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
973 $config{'DB_NAME'} = _get_value('DB_NAME', $msg, $defaults->{'DB_NAME'}, $valid_values, $install_log_values);
bd0877f installer: prompt for more configuration parameters
Galen Charlton authored
974
975 $msg = q(
976 Please specify the user that owns the database to be
977 used by Koha);
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
978 $config{'DB_USER'} = _get_value('DB_USER', $msg, $defaults->{'DB_USER'}, $valid_values, $install_log_values);
bd0877f installer: prompt for more configuration parameters
Galen Charlton authored
979
980 $msg = q(
981 Please specify the password of the user that owns the
982 database to be used by Koha);
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
983 $config{'DB_PASS'} = _get_value('DB_PASS', $msg, $defaults->{'DB_PASS'}, $valid_values, $install_log_values);
bd0877f installer: prompt for more configuration parameters
Galen Charlton authored
984
985 $msg = q(
44efd0f installer (part 1): started major changes
Galen Charlton authored
986 Koha can use the Zebra search engine for high-performance
987 searching of bibliographic and authority records. If you
988 have installed the Zebra software and would like to use it,
989 please answer 'yes' to the following question. Otherwise,
990 Koha will default to using its internal search engine.
991
3b58e09 installer: now respects INSTALL_ZEBRA = no
Galen Charlton authored
992 Please note that if you choose *NOT* to install Zebra,
993 koha-conf.xml will still contain some references to Zebra
994 settings. Those references will be ignored by Koha.
995
d7a09ca installer: modified wording of some questions
Galen Charlton authored
996 Install the Zebra configuration files?);
44efd0f installer (part 1): started major changes
Galen Charlton authored
997 $msg .= _add_valid_values_disp('INSTALL_ZEBRA', $valid_values);
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
998 $config{'INSTALL_ZEBRA'} = _get_value('INSTALL_ZEBRA', $msg, $defaults->{'INSTALL_ZEBRA'}, $valid_values, $install_log_values);
44efd0f installer (part 1): started major changes
Galen Charlton authored
999
1000 if ($config{'INSTALL_ZEBRA'} eq 'yes') {
2fafa14 kohabug 1776 - try to locate Zebra during install
Galen Charlton authored
1001
1002 if (defined(my $zebra_path = find_zebra())) {
1003 $config{'PATH_TO_ZEBRA'} = $zebra_path;
1004 print qq(
1005 Found 'zebrasrv' and 'zebraidx' in $zebra_path.
1006 );
1007 } else {
1008 print q(
1009 Unable to find the Zebra programs 'zebrasrv' and 'zebraidx'
1010 in your PATH or in some of the usual places. If you haven't
1011 installed Zebra yet, please do so and run Makefile.PL again.
1012
1013 );
1014 }
1015
44efd0f installer (part 1): started major changes
Galen Charlton authored
1016 $msg = q(
1017 Since you've chosen to use Zebra with Koha,
1018 you must specify the primary MARC format of the
1019 records to be indexed by Zebra.
1020
1021 Koha provides Zebra configuration files for MARC 21
1022 and UNIMARC.
1023
d7a09ca installer: modified wording of some questions
Galen Charlton authored
1024 MARC format for Zebra indexing);
44efd0f installer (part 1): started major changes
Galen Charlton authored
1025 $msg .= _add_valid_values_disp('ZEBRA_MARC_FORMAT', $valid_values);
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
1026 $config{'ZEBRA_MARC_FORMAT'} = _get_value('ZEBRA_MARC_FORMAT', $msg, $defaults->{'ZEBRA_MARC_FORMAT'}, $valid_values, $install_log_values);
44efd0f installer (part 1): started major changes
Galen Charlton authored
1027 $msg = q(
1028 Koha supplies Zebra configuration files tuned for
1029 searching either English (en) or French (fr) MARC
1030 records.
1031
d7a09ca installer: modified wording of some questions
Galen Charlton authored
1032 Primary language for Zebra indexing);
44efd0f installer (part 1): started major changes
Galen Charlton authored
1033 $msg .= _add_valid_values_disp('ZEBRA_LANGUAGE', $valid_values);
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
1034 $config{'ZEBRA_LANGUAGE'} = _get_value('ZEBRA_LANGUAGE', $msg, $defaults->{'ZEBRA_LANGUAGE'}, $valid_values, $install_log_values);
1c0401e authorities - enabled DOM indexing
Galen Charlton authored
1035
1036 $msg = q(
1037 Koha can use one of two different indexing modes
1038 for the MARC authorities records:
1039
1040 grs1 - uses the Zebra GRS-1 filter, available
1041 for legacy support
1042 dom - uses the DOM XML filter; offers improved
1043 functionality.
1044
1045 Authorities indexing mode);
1046 $msg .= _add_valid_values_disp('AUTH_INDEX_MODE', $valid_values);
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
1047 $config{'AUTH_INDEX_MODE'} = _get_value('AUTH_INDEX_MODE', $msg, $defaults->{'AUTH_INDEX_MODE'}, $valid_values, $install_log_values);
1c0401e authorities - enabled DOM indexing
Galen Charlton authored
1048
bd0877f installer: prompt for more configuration parameters
Galen Charlton authored
1049 $msg = q(
1050 Please specify Zebra database user);
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
1051 $config{'ZEBRA_USER'} = _get_value('ZEBRA_USER', $msg, $defaults->{'ZEBRA_USER'}, $valid_values, $install_log_values);
bd0877f installer: prompt for more configuration parameters
Galen Charlton authored
1052
1053 $msg = q(
1054 Please specify the Zebra database password);
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
1055 $config{'ZEBRA_PASS'} = _get_value('ZEBRA_PASS', $msg, $defaults->{'ZEBRA_PASS'}, $valid_values, $install_log_values);
bd0877f installer: prompt for more configuration parameters
Galen Charlton authored
1056
bbd043f adding three new variables for installation:
Joshua Ferraro authored
1057 $msg = q(
1058 Since you've chosen to use Zebra, you can enable the SRU/
1059 Z39.50 Server if you so choose, but you must specify a
1060 few configuration options for it.
1061
1062 Please note that if you choose *NOT* to configure SRU,
1063 koha-conf.xml will still contain some references to SRU
1064 settings. Those references will be ignored by Koha.
1065
1066 Install the SRU configuration files?);
1067 $msg .= _add_valid_values_disp('INSTALL_SRU', $valid_values);
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
1068 $config{'INSTALL_SRU'} = _get_value('INSTALL_SRU', $msg, $defaults->{'INSTALL_SRU'}, $valid_values, $install_log_values);
bbd043f adding three new variables for installation:
Joshua Ferraro authored
1069
1070 if ($config{'INSTALL_SRU'} eq 'yes') {
1071 $msg = q(
1072 Since you've chosen to configure SRU, you must
1073 specify the host and port(s) that the SRU
1074 Servers (bibliographic and authority) should run on.
1075 );
1076 $msg = q(
1077 SRU Database host?);
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
1078 $config{'ZEBRA_SRU_HOST'} = _get_value('ZEBRA_SRU_HOST', $msg, $defaults->{'ZEBRA_SRU_HOST'}, $valid_values, $install_log_values);
bbd043f adding three new variables for installation:
Joshua Ferraro authored
1079
1080 $msg = q(
1081 SRU port for bibliographic data?);
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
1082 $config{'ZEBRA_SRU_BIBLIOS_PORT'} = _get_value('ZEBRA_SRU_BIBLIOS_PORT', $msg, $defaults->{'ZEBRA_SRU_BIBLIOS_PORT'}, $valid_values, $install_log_values);
bbd043f adding three new variables for installation:
Joshua Ferraro authored
1083
1084 $msg = q(
1085 SRU port for authority data?);
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
1086 $config{'ZEBRA_SRU_AUTHORITIES_PORT'} = _get_value('ZEBRA_SRU_AUTHORITIES_PORT', $msg, $defaults->{'ZEBRA_SRU_AUTHORITIES_PORT'}, $valid_values, $install_log_values);
bbd043f adding three new variables for installation:
Joshua Ferraro authored
1087
1088 }
70dccac FRBR: configure PazPar2 during installation
Galen Charlton authored
1089
1090 $msg = q(
1091 Since you've chosen to use Zebra, you can also choose to
1092 install PazPar2, which is a metasearch tool. With PazPar2,
1093 Koha can perform on-the-fly merging of bibliographic
1094 records during searching, allowing for FRBRization of
1095 the results list.
1096
1097 Install the PazPar2 configuration files?);
1098 $msg .= _add_valid_values_disp('INSTALL_PAZPAR2', $valid_values);
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
1099 $config{'INSTALL_PAZPAR2'} = _get_value('INSTALL_PAZPAR2', $msg, $defaults->{'INSTALL_PAZPAR2'}, $valid_values, $install_log_values);
70dccac FRBR: configure PazPar2 during installation
Galen Charlton authored
1100
1101 if ($config{'INSTALL_PAZPAR2'} eq 'yes') {
1102 $msg = q(
1103 Since you've chosen to configure PazPar2, you must
1104 specify the host and port(s) that PazPar2
1105 uses:
1106 );
1107 $msg = q(
1108 Zebra bibliographic server host?);
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
1109 $config{'MERGE_SERVER_HOST'} = _get_value('MERGE_SERVER_HOST', $msg, $defaults->{'MERGE_SERVER_HOST'}, $valid_values, $install_log_values);
70dccac FRBR: configure PazPar2 during installation
Galen Charlton authored
1110
1111 $msg = q(
1112 Zebra bibliographic port for PazPar2 to use?);
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
1113 $config{'MERGE_SERVER_PORT'} = _get_value('MERGE_SERVER_PORT', $msg, $defaults->{'MERGE_SERVER_PORT'}, $valid_values, $install_log_values);
70dccac FRBR: configure PazPar2 during installation
Galen Charlton authored
1114
1115 $msg = q(
1116 PazPar2 host?);
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
1117 $config{'PAZPAR2_HOST'} = _get_value('PAZPAR2_HOST', $msg, $defaults->{'PAZPAR2_HOST'}, $valid_values, $install_log_values);
70dccac FRBR: configure PazPar2 during installation
Galen Charlton authored
1118
1119 $msg = q(
1120 PazPar2 port?);
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
1121 $config{'PAZPAR2_PORT'} = _get_value('PAZPAR2_PORT', $msg, $defaults->{'PAZPAR2_PORT'}, $valid_values, $install_log_values);
70dccac FRBR: configure PazPar2 during installation
Galen Charlton authored
1122
1123 }
44efd0f installer (part 1): started major changes
Galen Charlton authored
1124 }
e16e920 @ranginui Updating the Makefile so memcached configuration can be added to the koh...
ranginui authored
1125 $msg = q(
1126 Use memcached and memoize to cache the results of some function calls?
1127 This provides a signficant performance improvement.
1128 You will need a Memcached server running.);
1129 $msg .= _add_valid_values_disp('USE_MEMCACHED', $valid_values);
1130 $config{'USE_MEMCACHED'} = _get_value('USE_MEMCACHED', $msg, $defaults->{'USE_MEMCACHED'}, $valid_values, $install_log_values);
1131 if ($config{'USE_MEMCACHED'} eq 'yes'){
1132 $msg = q(
1133 Since you've chosen to use caching, you must specify the memcached servers and the namespace to use:
1134 );
1135 $msg = q(
1136 Memcached server address?);
1137 $config{'MEMCACHED_SERVERS'} = _get_value('MEMCACHED_SERVERS', $msg, $defaults->{'MEMCACHED_SERVERS'}, $valid_values, $install_log_values);
1138
1139 $msg = q(
1140 Memcached namespace?);
1141 $config{'MEMCACHED_NAMESPACE'} = _get_value('MEMCACHED_NAMESPACE', $msg, $defaults->{'MEMCACHED_NAMESPACE'}, $valid_values, $install_log_values);
1142 }
1143
1144
d6eba77 installer: now can use env vars to set installation variables
Galen Charlton authored
1145
8056846 @amoore improvements to automated tests, including a testing database
amoore authored
1146 $msg = q(
1147 Would you like to run the database-dependent test suite?);
1148 $msg .= _add_valid_values_disp( 'RUN_DATABASE_TESTS', $valid_values );
1149 $config{'RUN_DATABASE_TESTS'} = _get_value( 'RUN_DATABASE_TESTS', $msg, $defaults->{'RUN_DATABASE_TESTS'}, $valid_values, $install_log_values );
1150
1151 if ( $config{'RUN_DATABASE_TESTS'} eq 'yes' ) {
1152 $config{'TEST_DB_TYPE'} = $config{'DB_TYPE'};
1153 $config{'TEST_DB_HOST'} = $config{'DB_HOST'};
1a6d84c @amoore testing framework: adding more warnings about possible data loss
amoore authored
1154 $msg = q(TEST DATABASE
1155
1156 THE DATA IN THIS DATABASE WILL BE DESTROYED during the process of
1157 testing. Please don't do this on your production database. It is not
1158 reversable.
1159
1160 YOU WILL SUFFER DATA LOSS if you run this test suite on your test
1161 database. You are better off not running this optional test suite than
1162 doing it in a database that you don't want to lose.
1163
8056846 @amoore improvements to automated tests, including a testing database
amoore authored
1164 Please specify the name of the test database to be
1165 used by Koha);
1a6d84c @amoore testing framework: adding more warnings about possible data loss
amoore authored
1166
05b334d @amoore bug 2083: requiring that the test database have a different name from th...
amoore authored
1167 $config{'TEST_DB_NAME'} = _get_value('TEST_DB_NAME', $msg, $defaults->{'TEST_DB_NAME'}, $valid_values, $install_log_values);
1168 while ( $config{'TEST_DB_NAME'} eq $config{'DB_NAME'} ) {
1169 $msg = q(Please do not use the same database for testing as you do for production. You run the severe risk of data loss.);
1170 $config{'TEST_DB_NAME'} = _get_value('TEST_DB_NAME', $msg, $defaults->{'TEST_DB_NAME'}, $valid_values, $install_log_values);
1171 }
8056846 @amoore improvements to automated tests, including a testing database
amoore authored
1172
1173 $msg = q(
1174 Please specify the user that owns the database to be
1175 used by Koha);
1176 $config{'TEST_DB_USER'} = _get_value('TEST_DB_USER', $msg, $defaults->{'TEST_DB_USER'}, $valid_values, $install_log_values);
1177
1178 $msg = q(
1179 Please specify the password of the user that owns the
1180 database to be used by Koha);
1181 $config{'TEST_DB_PASS'} = _get_value('TEST_DB_PASS', $msg, $defaults->{'TEST_DB_PASS'}, $valid_values, $install_log_values);
1182 }
1183
d6eba77 installer: now can use env vars to set installation variables
Galen Charlton authored
1184 print "\n\n";
82daf0a installer: added install log
Galen Charlton authored
1185
1186 # add version number
1187 my $version = "no_version_found";
1188 eval {
1189 require 'kohaversion.pl';
1190 $version = kohaversion();
1191 };
1192 $config{'KOHA_INSTALLED_VERSION'} = $version;
1193
44efd0f installer (part 1): started major changes
Galen Charlton authored
1194 return %config;
1195 }
1196
1197 sub _add_valid_values_disp {
1198 my $key = shift;
1199 my $valid_values = shift;
1200
1201 my $disp = "";
1202 if (exists $valid_values->{$key}) {
1203 $disp = " (" . join(", ", sort keys %{ $valid_values->{$key} }) . ")";
1204 }
1205 return $disp;
1206 }
1207
1208 sub _get_value {
1209 my $key = shift;
1210 my $msg = shift;
1211 my $default = shift;
1212 my $valid_values = shift;
20f1c41 install: added --prev-install-log option to Makefile.PL
Galen Charlton authored
1213 my $install_log_values = shift;
1214
1215 # take value from install log if present
1216 if (exists $install_log_values{$key}) {
1217 return $install_log_values{$key};
1218 }
44efd0f installer (part 1): started major changes
Galen Charlton authored
1219
d6eba77 installer: now can use env vars to set installation variables
Galen Charlton authored
1220 # override default value from environment
1221 if (exists $ENV{$key}) {
1222 $default = $ENV{$key};
1223 $msg .= " (default from environment)";
1224 }
1225
44efd0f installer (part 1): started major changes
Galen Charlton authored
1226 my $val = prompt($msg, $default);
3f5c71d installer: always accept default value as valid
Galen Charlton authored
1227
1228 while (exists $valid_values->{$key} and
1229 $val ne $default and
1230 not exists $valid_values->{$key}->{$val}) {
44efd0f installer (part 1): started major changes
Galen Charlton authored
1231 my $retry_msg = "Value '$val' is not a valid option.\n";
1232 $retry_msg .= "Please enter a value";
1233 $retry_msg .= _add_valid_values_disp($key, $valid_values);
1234 $val = prompt($retry_msg, $default);
1235 }
1236 return $val;
1237 }
1238
1239 =head2 get_target_directories
1240
1241 Creates a hash mapping from symbols for installation target
1242 directories to actual directory paths.
1243
1b71360 installer: various changes
Galen Charlton authored
1244 Also returns a hash indicating targets for which
1245 files need not be copied -- this is used for the 'dev'
1246 mode installation, where some files are installed in place.
1247
44efd0f installer (part 1): started major changes
Galen Charlton authored
1248 =cut
1249
1250 sub get_target_directories {
1251 my $config = shift;
1252
1253 my $base = $config->{'INSTALL_BASE'};
1254 my $mode = $config->{'INSTALL_MODE'};
1255
1256 # get last component of install base directory
1257 # to treat as package name
1258 my ($volume, $directories, $file) = File::Spec->splitpath($base, 1);
118283b Initial work on adding Win32 support to installer.
Chris Nighswonger authored
1259
44efd0f installer (part 1): started major changes
Galen Charlton authored
1260 my @basedir = File::Spec->splitdir($directories);
118283b Initial work on adding Win32 support to installer.
Chris Nighswonger authored
1261
1262 # for Win32 we need to prepend the volume to the directory path
1263 if ( $^O eq 'MSWin32' ) { shift @basedir; unshift @basedir, $volume; }
1264 elsif ( $^O eq 'cygwin' ) { shift @basedir; unshift @basedir, 'c:'; } # in a cygwin environment, $volume is returned empty
1265
44efd0f installer (part 1): started major changes
Galen Charlton authored
1266 my $package = pop @basedir;
1267
118283b Initial work on adding Win32 support to installer.
Chris Nighswonger authored
1268
44efd0f installer (part 1): started major changes
Galen Charlton authored
1269 my %dirmap = ();
1b71360 installer: various changes
Galen Charlton authored
1270 my %skipdirs = ();
44efd0f installer (part 1): started major changes
Galen Charlton authored
1271 if ($mode eq 'single') {
1272 $dirmap{'INTRANET_CGI_DIR'} = File::Spec->catdir(@basedir, $package, 'intranet', 'cgi-bin');
c31b5c2 installer: moved web template dirs; got rid of multi-targets
Galen Charlton authored
1273 $dirmap{'INTRANET_TMPL_DIR'} = File::Spec->catdir(@basedir, $package, 'intranet', 'htdocs', 'intranet-tmpl');
61ca8a3 installer: use htdocs instead of www; handle .htaccess
Galen Charlton authored
1274 $dirmap{'INTRANET_WWW_DIR'} = File::Spec->catdir(@basedir, $package, 'intranet', 'htdocs');
44efd0f installer (part 1): started major changes
Galen Charlton authored
1275 $dirmap{'OPAC_CGI_DIR'} = File::Spec->catdir(@basedir, $package, 'opac', 'cgi-bin');
c31b5c2 installer: moved web template dirs; got rid of multi-targets
Galen Charlton authored
1276 $dirmap{'OPAC_TMPL_DIR'} = File::Spec->catdir(@basedir, $package, 'opac', 'htdocs', 'opac-tmpl');
61ca8a3 installer: use htdocs instead of www; handle .htaccess
Galen Charlton authored
1277 $dirmap{'OPAC_WWW_DIR'} = File::Spec->catdir(@basedir, $package, 'opac', 'htdocs');
44efd0f installer (part 1): started major changes
Galen Charlton authored
1278 $dirmap{'PERL_MODULE_DIR'} = File::Spec->catdir(@basedir, $package, 'lib');
1279 $dirmap{'KOHA_CONF_DIR'} = File::Spec->catdir(@basedir, $package, 'etc');
1280 $dirmap{'ZEBRA_CONF_DIR'} = File::Spec->catdir(@basedir, $package, 'etc', 'zebradb');
70dccac FRBR: configure PazPar2 during installation
Galen Charlton authored
1281 $dirmap{'PAZPAR2_CONF_DIR'} = File::Spec->catdir(@basedir, $package, 'etc', 'pazpar2');
1b71360 installer: various changes
Galen Charlton authored
1282 $dirmap{'MISC_DIR'} = File::Spec->catdir(@basedir, $package, 'misc');
44efd0f installer (part 1): started major changes
Galen Charlton authored
1283 $dirmap{'SCRIPT_DIR'} = File::Spec->catdir(@basedir, $package, 'bin');
f20a581 kohabug 1776 - enable daemon controls scripts for 'dev' mode
Galen Charlton authored
1284 $dirmap{'SCRIPT_NONDEV_DIR'} = $dirmap{'SCRIPT_DIR'};
44efd0f installer (part 1): started major changes
Galen Charlton authored
1285 $dirmap{'MAN_DIR'} = File::Spec->catdir(@basedir, $package, 'man');
1286 $dirmap{'DOC_DIR'} = File::Spec->catdir(@basedir, $package, 'doc');
1287 $dirmap{'ZEBRA_LOCK_DIR'} = File::Spec->catdir(@basedir, $package, 'var', 'lock', 'zebradb');
1288 $dirmap{'LOG_DIR'} = File::Spec->catdir(@basedir, $package, 'var', 'log');
1289 $dirmap{'ZEBRA_DATA_DIR'} = File::Spec->catdir(@basedir, $package, 'var', 'lib', 'zebradb');
5befdd2 installer (part 2): more work
Galen Charlton authored
1290 $dirmap{'ZEBRA_RUN_DIR'} = File::Spec->catdir(@basedir, $package, 'var', 'run', 'zebradb');
44efd0f installer (part 1): started major changes
Galen Charlton authored
1291 } elsif ($mode eq 'dev') {
1292 my $curdir = File::Spec->rel2abs(File::Spec->curdir());
ecc8e2c @ctfliblime Update installer for koha-conf.xml <basedir> directive
ctfliblime authored
1293 $dirmap{'KOHA_BASE_DIR'} = File::Spec->catdir($curdir);
65c19cc @ctfliblime Moving everything around and ditching kohaversion.pl
ctfliblime authored
1294 $dirmap{'INTRANET_CGI_DIR'} = File::Spec->catdir($curdir, 'cgi');
1b71360 installer: various changes
Galen Charlton authored
1295 $skipdirs{'INTRANET_CGI_DIR'} = 1;
44efd0f installer (part 1): started major changes
Galen Charlton authored
1296 $dirmap{'INTRANET_TMPL_DIR'} = File::Spec->catdir($curdir, 'koha-tmpl', 'intranet-tmpl');
1b71360 installer: various changes
Galen Charlton authored
1297 $skipdirs{'INTRANET_TMPL_DIR'} = 1;
b3b3609 installer: fixed *_WWW_DIR for 'dev' install mode
Galen Charlton authored
1298 $dirmap{'INTRANET_WWW_DIR'} = File::Spec->catdir($curdir, 'koha-tmpl');
1b71360 installer: various changes
Galen Charlton authored
1299 $skipdirs{'INTRANET_WWW_DIR'} = 1;
65c19cc @ctfliblime Moving everything around and ditching kohaversion.pl
ctfliblime authored
1300 $dirmap{'OPAC_CGI_DIR'} = File::Spec->catdir($curdir, 'cgi');
1b71360 installer: various changes
Galen Charlton authored
1301 $skipdirs{'OPAC_CGI_DIR'} = 1;
44efd0f installer (part 1): started major changes
Galen Charlton authored
1302 $dirmap{'OPAC_TMPL_DIR'} = File::Spec->catdir($curdir, 'koha-tmpl', 'opac-tmpl');
1b71360 installer: various changes
Galen Charlton authored
1303 $skipdirs{'OPAC_TMPL_DIR'} = 1;
b3b3609 installer: fixed *_WWW_DIR for 'dev' install mode
Galen Charlton authored
1304 $dirmap{'OPAC_WWW_DIR'} = File::Spec->catdir($curdir, 'koha-tmpl');
1b71360 installer: various changes
Galen Charlton authored
1305 $skipdirs{'OPAC_WWW_DIR'} = 1;
65c19cc @ctfliblime Moving everything around and ditching kohaversion.pl
ctfliblime authored
1306 $dirmap{'PERL_MODULE_DIR'} = File::Spec->catdir($curdir, 'lib');
1b71360 installer: various changes
Galen Charlton authored
1307 $skipdirs{'PERL_MODULE_DIR'} = 1;
44efd0f installer (part 1): started major changes
Galen Charlton authored
1308 $dirmap{'KOHA_CONF_DIR'} = File::Spec->catdir(@basedir, $package, 'etc');
1309 $dirmap{'ZEBRA_CONF_DIR'} = File::Spec->catdir(@basedir, $package, 'etc', 'zebradb');
70dccac FRBR: configure PazPar2 during installation
Galen Charlton authored
1310 $dirmap{'PAZPAR2_CONF_DIR'} = File::Spec->catdir(@basedir, $package, 'etc', 'pazpar2');
1b71360 installer: various changes
Galen Charlton authored
1311 $dirmap{'MISC_DIR'} = File::Spec->catdir(@basedir, $package, 'misc');
44efd0f installer (part 1): started major changes
Galen Charlton authored
1312 $dirmap{'SCRIPT_DIR'} = File::Spec->catdir(@basedir, $package, 'bin');
f20a581 kohabug 1776 - enable daemon controls scripts for 'dev' mode
Galen Charlton authored
1313 $dirmap{'SCRIPT_NONDEV_DIR'} = $dirmap{'SCRIPT_DIR'};
1314 $skipdirs{'SCRIPT_NONDEV_DIR'} = 1;
44efd0f installer (part 1): started major changes
Galen Charlton authored
1315 $dirmap{'MAN_DIR'} = File::Spec->catdir(@basedir, $package, 'man');
1316 $dirmap{'DOC_DIR'} = File::Spec->catdir(@basedir, $package, 'doc');
1317 $dirmap{'ZEBRA_LOCK_DIR'} = File::Spec->catdir(@basedir, $package, 'var', 'lock', 'zebradb');
1318 $dirmap{'LOG_DIR'} = File::Spec->catdir(@basedir, $package, 'var', 'log');
1319 $dirmap{'ZEBRA_DATA_DIR'} = File::Spec->catdir(@basedir, $package, 'var', 'lib', 'zebradb');
5befdd2 installer (part 2): more work
Galen Charlton authored
1320 $dirmap{'ZEBRA_RUN_DIR'} = File::Spec->catdir(@basedir, $package, 'var', 'run', 'zebradb');
44efd0f installer (part 1): started major changes
Galen Charlton authored
1321 } else {
1322 # mode is standard, i.e., 'fhs'
1323 $dirmap{'INTRANET_CGI_DIR'} = File::Spec->catdir(@basedir, $package, 'intranet', 'cgi-bin');
c31b5c2 installer: moved web template dirs; got rid of multi-targets
Galen Charlton authored
1324 $dirmap{'INTRANET_TMPL_DIR'} = File::Spec->catdir(@basedir, $package, 'intranet', 'htdocs', 'intranet-tmpl');
61ca8a3 installer: use htdocs instead of www; handle .htaccess
Galen Charlton authored
1325 $dirmap{'INTRANET_WWW_DIR'} = File::Spec->catdir(@basedir, $package, 'intranet', 'htdocs');
44efd0f installer (part 1): started major changes
Galen Charlton authored
1326 $dirmap{'OPAC_CGI_DIR'} = File::Spec->catdir(@basedir, $package, 'opac', 'cgi-bin');
c31b5c2 installer: moved web template dirs; got rid of multi-targets
Galen Charlton authored
1327 $dirmap{'OPAC_TMPL_DIR'} = File::Spec->catdir(@basedir, $package, 'opac', 'htdocs', 'opac-tmpl');
61ca8a3 installer: use htdocs instead of www; handle .htaccess
Galen Charlton authored
1328 $dirmap{'OPAC_WWW_DIR'} = File::Spec->catdir(@basedir, $package, 'opac', 'htdocs');
44efd0f installer (part 1): started major changes
Galen Charlton authored
1329 $dirmap{'PERL_MODULE_DIR'} = File::Spec->catdir(@basedir, $package, 'lib');
1330 $dirmap{'KOHA_CONF_DIR'} = File::Spec->catdir(File::Spec->rootdir(), 'etc', $package);
1331 $dirmap{'ZEBRA_CONF_DIR'} = File::Spec->catdir(File::Spec->rootdir(), 'etc', $package, 'zebradb');
70dccac FRBR: configure PazPar2 during installation
Galen Charlton authored
1332 $dirmap{'PAZPAR2_CONF_DIR'} = File::Spec->catdir(File::Spec->rootdir(), 'etc', $package, 'pazpar2');
1b71360 installer: various changes
Galen Charlton authored
1333 $dirmap{'MISC_DIR'} = File::Spec->catdir(@basedir, $package, 'misc');
44efd0f installer (part 1): started major changes
Galen Charlton authored
1334 $dirmap{'SCRIPT_DIR'} = File::Spec->catdir(@basedir, $package, 'bin');
f20a581 kohabug 1776 - enable daemon controls scripts for 'dev' mode
Galen Charlton authored
1335 $dirmap{'SCRIPT_NONDEV_DIR'} = $dirmap{'SCRIPT_DIR'};
44efd0f installer (part 1): started major changes
Galen Charlton authored
1336 $dirmap{'MAN_DIR'} = File::Spec->catdir(@basedir, $package, 'man');
1337 $dirmap{'DOC_DIR'} = File::Spec->catdir(@basedir, $package, 'doc');
1338 $dirmap{'ZEBRA_LOCK_DIR'} = File::Spec->catdir(File::Spec->rootdir(), 'var', 'lock', $package, 'zebradb');
1339 $dirmap{'LOG_DIR'} = File::Spec->catdir(File::Spec->rootdir(), 'var', 'log', $package);
1340 $dirmap{'ZEBRA_DATA_DIR'} = File::Spec->catdir(File::Spec->rootdir(), 'var', 'lib', $package, 'zebradb');
5befdd2 installer (part 2): more work
Galen Charlton authored
1341 $dirmap{'ZEBRA_RUN_DIR'} = File::Spec->catdir(File::Spec->rootdir(), 'var', 'run', $package, 'zebradb');
44efd0f installer (part 1): started major changes
Galen Charlton authored
1342 }
1343
d6eba77 installer: now can use env vars to set installation variables
Galen Charlton authored
1344 _get_env_overrides(\%dirmap);
bd0877f installer: prompt for more configuration parameters
Galen Charlton authored
1345 _get_argv_overrides(\%dirmap);
9087249 @vdanjean Add support for DESTDIR
vdanjean authored
1346 _add_destdir(\%dirmap);
bd0877f installer: prompt for more configuration parameters
Galen Charlton authored
1347
1b71360 installer: various changes
Galen Charlton authored
1348 return \%dirmap, \%skipdirs;
44efd0f installer (part 1): started major changes
Galen Charlton authored
1349 }
1350
33036c4 test suite - various changes
Galen Charlton authored
1351 =head2 get_test_dir
1352
1353 Map a directory target to the corresponding path for
1354 the test suite.
1355
1356 =cut
1357
1358 sub get_test_dir {
1359 my ($dirname) = @_;
1360
1361 my @basedir = (File::Spec->rel2abs(File::Spec->curdir()), 't', 'run');
1362 if (exists $test_suite_override_dirs{$dirname}) {
1363 return File::Spec->catdir(@basedir, @{ $test_suite_override_dirs{$dirname} });
1364 } else {
1365 return;
1366 }
1367
1368 }
1369
d6eba77 installer: now can use env vars to set installation variables
Galen Charlton authored
1370 sub _get_env_overrides {
1371 my $dirmap = shift;
1372
1373 foreach my $key (keys %$dirmap) {
1374 if (exists $ENV{$key}) {
1375 $dirmap->{$key} = $ENV{$key};
1376 print "Setting $key from environment\n";
1377 }
1378 }
1379 }
1380
bd0877f installer: prompt for more configuration parameters
Galen Charlton authored
1381 sub _get_argv_overrides {
1382 my $dirmap = shift;
1383
1384 my @new_argv = ();
1385 for (my $i = 0; $i <= $#ARGV; $i++) {
1386 if ($ARGV[$i] =~ /^([^=]+)=([^=]+)$/ and exists $dirmap->{$1}) {
1387 $dirmap->{$1} = $2;
1388 } else {
1389 push @new_argv, $ARGV[$i];
1390 }
1391 }
1392 @ARGV = @new_argv;
1393 }
1394
9087249 @vdanjean Add support for DESTDIR
vdanjean authored
1395 sub _strip_destdir {
1396 my $dir = shift;
1397 $dir =~ s/^\$\(DESTDIR\)//;
1398 return $dir;
1399 }
1400
1401 sub _add_destdir {
1402 my $dirmap = shift;
1403
1404 foreach my $key (keys %$dirmap) {
1405 $dirmap->{$key} = '$(DESTDIR)'.$dirmap->{$key};
1406 }
1407 }
1408
bd0877f installer: prompt for more configuration parameters
Galen Charlton authored
1409 sub display_configuration {
1410 my $config = shift;
1411 my $dirmap = shift;
1412 print "\n\nKoha will be installed with the following configuration parameters:\n\n";
1413 foreach my $key (sort keys %$config) {
1414 print sprintf("%-25.25s%s\n", $key, $config->{$key});
1415 }
1416
1417 print "\nand in the following directories:\n\n";
1418 foreach my $key (sort keys %$dirmap) {
1419 print sprintf("%-25.25s%s\n", $key, $dirmap->{$key});
1420 }
1421 print "\n\nTo change any configuration setting, please run\n";
1422 print "perl Makefile.PL again. To override one of the target\n";
1423 print "directories, you can do so on the command line like this:\n";
1424 print "\nperl Makefile.PL PERL_MODULE_DIR=/usr/share/perl/5.8\n\n";
d6eba77 installer: now can use env vars to set installation variables
Galen Charlton authored
1425 print "You can also set different default values for parameters\n";
1426 print "or override directory locations by using environment variables.\n";
1427 print "\nFor example:\n\n";
1428 print "export DB_USER=my_koha\n";
1429 print "perl Makefile.PL\n";
1430 print "\nor\n\n";
1431 print "DB_USER=my_koha DOC_DIR=/usr/local/info perl Makefile.PL\n\n";
981a345 Clairifying pod for upgrade and correcting dmake message for Win32
Chris Nighswonger authored
1432 print "If installing on a Win32 platform, be sure to use:\n";
1433 print "'dmake -x MAXLINELENGTH=300000'\n\n";
bd0877f installer: prompt for more configuration parameters
Galen Charlton authored
1434 }
1435
2fafa14 kohabug 1776 - try to locate Zebra during install
Galen Charlton authored
1436 =head2 find_zebra
1437
1438 Attempt to find Zebra - check user's PATH and
1439 a few other directories for zebrasrv and zebraidx.
1440
1441 FIXME: doesn't handle Win32
1442
1443 =cut
1444
1445 sub find_zebra {
1446 my @search_dirs = map {
1447 my $abs = File::Spec->rel2abs($_);
1448 my ($toss, $directories);
1449 ($toss, $directories, $toss) = File::Spec->splitpath($abs, 1);
1450 $directories;
1451 } split /:/, $ENV{PATH};
1452 push @search_dirs, qw(/usr/local/bin /opt/local/bin /usr/bin);
1453 my @zebrasrv_dirs = grep { -x File::Spec->catpath('', $_, 'zebrasrv') } @search_dirs;
1454 return unless @zebrasrv_dirs;
1455 # verify that directory that contains zebrasrv also contains zebraidx
1456 foreach my $dir (@zebrasrv_dirs) {
1457 return $dir if -x File::Spec->catpath('', $dir, 'zebraidx');
1458 }
1459 return;
1460 }
1461
5befdd2 installer (part 2): more work
Galen Charlton authored
1462 package MY;
7f01995 installer (part 3): enabled 'make test'
Galen Charlton authored
1463
118283b Initial work on adding Win32 support to installer.
Chris Nighswonger authored
1464 # This will have to be reworked in order to accommodate Win32...
1465
7f01995 installer (part 3): enabled 'make test'
Galen Charlton authored
1466 sub test {
1467 my $self = shift;
1468 my $test = $self->SUPER::test(@_);
1469 $test =~ s!\$\(INST_LIB\)!blib/PERL_MODULE_DIR!g;
6530b68 Makefile.PL - set KOHA_CONF for make test
Galen Charlton authored
1470
1471 # set KOHA_CONF
1472 $test =~ s!\$\(FULLPERLRUN\)!KOHA_CONF=blib/KOHA_CONF_DIR/koha-conf.xml \$(FULLPERLRUN)!g;
7f01995 installer (part 3): enabled 'make test'
Galen Charlton authored
1473 return $test;
1474 }
1475
5befdd2 installer (part 2): more work
Galen Charlton authored
1476 sub install {
1477 my $self = shift;
1478 my $install = "";
1479 # NOTE: we're *not* doing this: my $install = $self->SUPER::install(@_);
1480 # This means that we're completely overriding EU::MM's default
1481 # installation and uninstallation targets.
118283b Initial work on adding Win32 support to installer.
Chris Nighswonger authored
1482
1483 # If installation is on Win32, we need to do permissions different from *nix
deba213 @fredericd Bug #3036 Avoid command-line installer blocking on opensolaris plateform
fredericd authored
1484