To test:
0. Apply patch
1a. perl Makefile.PL
1b. Choose "single" Installation mode
1c. Specify /opt/koha directory
2. make
2b. ls blib/API_CGI_DIR/v1/swagger/swagger_bundle.json
3. Ensure you're running as root or make koha user own /opt
4. make install
5. ls /opt/koha/api/v1/swagger/swagger_bundle.json
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
It's missing from the Makefile.PL!
Same as erm.js when need to install it.
Signed-off-by: David Nind <david@davidnind.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Katrin Fischer <katrin.fischer@bsz-bw.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This script was never fully promoted or documented and it requires third
party libraries are installed to use. This patch removes it from the
repository and the Makefile so it is no longer installed.
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Paul Derscheid <paul.derscheid@lmscloud.de>
Signed-off-by: Pedro Amorim <pedro.amorim@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
to test:
- run makefile, note failure
$ perl Makefile.PL
$ make
$ make install
webpack 5.74.0 compiled with 3 warnings in 20831 ms
Done in 36.01s.
make: *** No rule to make target 'koha-tmpl/opac-tmpl/bootstrap/css/maps/opac-rtl.css.map', needed by 'pm_to_blib'. Stop.
- apply patch
- run makefile, note success
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This patch adds a new target to the Makefile which gets
called as the first step of the "all" target. This means
that CSS and JS files get compiled every time "make" is
called.
(Note: Since the "install" target depends on "all", it will
be re-run at install time.)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This patch adds a trivial perl wrapper around the yarn build and calls
it from Makefile.PL.
I 'think' this is all we need to get packaging, dev and standard
installs happy with the lack of our compiled files in source.
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
The purpose of this script was to load the relevant Koha lib for the
different scripts (installation, cronjob, CLI, etc.)
However it is not used consistently and we prefer to rely on PERL5LIB.
From bug 28617 comment 6 from Galen:
"""
Time marches on, and one of the motivations for having kohalib.pl - making
it possible to install Koha without setting a single environment variable -
has been obviated by the vast improvements in the ease of installing Koha.
Consequently, I think kohalib.pl can go away.
"""
Test plan:
confirm that the changes make sense and that kohalib.pl can be removed
safely.
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Fridolin Somers <fridolin.somers@biblibre.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This patch adds a "lib" directory to the source tree which gets
mapped to the same directory as "C4" and "Koha" for single and
standard installations.
CGI::Session::Serialize::yamlxs is put into this "lib" directory.
This patch also includes some changes so that dev/git installations
work as well.
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This patch adds a systemd unit file which gets rewritten according to
the configuration specified by Makefile.PL. This can be linked or
copied to systemd directories for running a systemd service for
background_jobs_worker.pl
Test plan:
1. perl Makefile.PL
1a. Choose "single" installation
1b. Choose "/opt/koha" for a file path
2. make
3. vi blib/KOHA_CONF_DIR/koha-worker.service
4. Verify that PERL5LIB, KOHA_CONF, ExecStart, and SyslogIdentifier
all appear to be correctly filled in
Signed-off-by: Victor Grousset/tuxayo <victor@tuxayo.net>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This feature is not used as far as we know and it's not known to work.
It's preferable to remove it.
Test plan:
Make sure the OpacGroupResults pref code is removed, as well as the
PazPar2 files and code.
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This patch adds the /pos directory to the Makefile so that pos gets
properly mapped at make and install time.
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
to test...
1/ attempt to install koha 20.05 package on deb11, fail :'(
2/ apply patch and build new koha package
3/ attempt to install new koha package on deb11, succeed!
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This patch adds a .perlcriticrc (copied from qa-test-tools) and fixes
almost all perlcrictic violations according to this .perlcriticrc
The remaining violations are silenced out by appending a '## no critic'
to the offending lines. They can still be seen by using the --force
option of perlcritic
This patch also modify t/00-testcritic.t to check all Perl files using
the new .perlcriticrc.
I'm not sure if this test script is still useful as it is now equivalent
to `perlcritic --quiet .` and it looks like it is much slower
(approximatively 5 times slower on my machine)
Test plan:
1. Run `perlcritic --quiet .` from the root directory. It should output
nothing
2. Run `perlcritic --quiet --force .`. It should output 7 errors (6
StringyEval, 1 BarewordFileHandles)
3. Run `TEST_QA=1 prove t/00-testcritic.t`
4. Read the patch. Check that all changes make sense and do not
introduce undesired behaviour
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
According to the list of two-letter language codes found in ISO 639-1
(https://en.wikipedia.org/wiki/List_of_ISO_639-1_codes), the correct
Zebra language option for Greek should be 'el', not 'gr'.
This patch fixes that.
Test plan:
0) Apply the patch.
1) Confirm that 'gr' has been changed to 'el' in all relevant files.
2) Create a new Koha instance using `koha-create --zebralang el testinst1`.
3) Edit /etc/koha/koha-sites.conf and set ZEBRA_LANGUAGE to 'el'. Then,
create another Koha instance with `koha-create testinst2`.
4) Confirm that both instances created in steps 2) and 3) have picked up
the Zebra CHR file from the /etc/koha/zebradb/lang_defs/el/ directory.
This is done by inspecting the value of 'profilePath' in these files:
/etc/koha/sites/testinst{1,2}/zebra-authorities-dom.cfg
/etc/koha/sites/testinst{1,2}/zebra-biblios-dom.cfg
Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
cpanfile is a format for describing CPAN dependencies for Perl
applications.
It is more concise - thus easier to read and maintain - than
C4::Installer::PerlDependencies, and allows to describe requirements
more accurately (using version ranges or features for instance)
Additionally it can be read by tools such as cpanm or carton for an
easy way to install dependencies on non-Debian-based systems.
For more information on cpanfile, see
http://search.cpan.org/~miyagawa/Module-CPANfile-1.1002/lib/cpanfile.pod
This patch replace C4::Installer::PerlDependencies by an equivalent
cpanfile and update all scripts/modules that were using PerlDependencies
It also removes dead code from C4::Installer::PerlModules (some
subroutines were not used at all, except in unit tests)
Added dependencies:
- Module::CPANfile
- CPAN::Meta (dependency of Module::CPANfile, but we need a more recent
version than the one Module::CPANfile requires)
Test plan:
1. Go to About page, tab Perl modules and keep this browser tab open
2. Apply patch
3. Install Module::CPANfile and CPAN::Meta
a. On Debian-based systems:
# will install libcpan-meta-perl as a dependency
sudo apt install libmodule-cpanfile-perl
b. Others:
# will install CPAN::Meta as a dependency
sudo cpanm Module::CPANfile
4. In a new browser tab, go to About page, tab Perl modules and compare
the table with the one in the previous browser tab
They should be identical, except for newly added dependencies
(Module::CPANfile and CPAN::Meta)
5. Do a 'standard' install
a. perl Makefile.PL (select 'standard')
b. make
c. sudo make install
d. Configure your database, web server, ... and go through the web
install process
6. Verify that the cpanfile got copied into PERL_MODULE_DIR (which
should be /usr/share/koha/lib)
7. Go to the about page of this fresh install and compare it with your
dev install
8. Verify that debian/list-deps still works
This takes a lot of time and it may not be necessary to wait until
the end. If you see some Debian package names that correspond to
modules in cpanfile, it means it still works
(you need apt-file for this script to work)
9. Verify that koha_perl_deps.pl still works
10. prove t/Installer_pm.t t/Installer_PerlModules.t
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Missing installer for debian packages.
Sponsored-by: Koha-Suomi Oy
Signed-off-by: Johanna Raisa <johanna.raisa@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Like history.txt we need to tell some debian/ files to copy
teams.yaml
Also pick it for the `make install` process (Makefile.PL)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Like history.txt we need to tell some debian/ files to copy contributors.yaml
Also pick it for the `make install` process (Makefile.PL)
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
There appears to be no xml_sax.pl in Koha, so the
reference should be removed.
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
This patch was generated using codespell
Test plan:
Read through changes and confirm they make sense
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Owen Leonard <oleonard@myacpl.org>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
https://bugs.koha-community.org/show_bug.cgi?id=21706
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Remove:
- BIB_INDEX_MODE and AUTH_INDEX_MODE env var
- bib_index_mode and auth_index_mode options from scripts
- Warnings from about page, just kept one if zebra_bib_index_mode or
zebra_auth_index_mode still exist in config and are set to grs1
Test plan:
- Install Koha from src
- Install Koha from pkg
- Read the code, carefully!
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Rebased
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
koha_1 | # Failed test 'All directories should be mapped:
.sass-lint.yml,.scss-lint.yml,gulpfile.js,package.json,yarn.lock'
koha_1 | # at t/Makefile.t line 47.
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Nick Clemens <nick@bywatersolutions.com>
Note that there is no way to create an install without memcached.
As it is now considered as stable, there is no point to not use it.
Test plan:
Create a new Koha install and make sure memcached is enabled by default
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This patch adds Makefile.PL the capability of handling the template_cache_dir configuration entry.
To do so, it:
- Adds the --template-cache-dir option switch (consistency with koha-create)
- Sets a default value for template_cache_dir to '/tmp/koha'
- Adds a dialog requesting the path for the template cache dir to Makefile.PL
- It tweaks etc/koha-conf.xml so it is correctly changed by rewrite-config.PL
To test:
- Apply this patch
- Run:
$ perl Makefile.PL --template-cache-dir your/favourite/dir
=> SUCCESS: The dialogs don't ask for template cache dir
=> SUCCESS: The resulting Makefile contains an entry for TEMPLATE_CACHE_DIR which value
matches what we passed to --template-cache-dir
- Run:
$ perl Makefile.PL
- When prompted for a template cache dir, introduce whatever you want
=> SUCCESS: The default you are offered is /tmp/koha
=> SUCCESS: At the end of the process, Makefile contains what we put in there
- Run:
$ sudo make install
=> SUCCESS: The resulting koha-conf.xml contains a <template_cache_dir> entry containing
whatever you picked for that purpose.
- Sign off :-D
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This Commit is at the heart of adding an interlibrary loans framework
for Koha. The framework does not prescribe a particular workflow.
Instead it provides a general framework that can be extended &
implemented by individual backends whose responsibility it is to
implement a specific workflow.
The module is largely self-sufficient: it adds new tables to the Koha
database and touches only a few files in the Koha source tree.
Primarily, we add our files to the Makefile and the koha-conf.xml,
define ill paths for the REST API, and introduce links from the main
intranet, opac pages & user permissions.
Outside of this we simply add new files & functionality.
Signed-off-by: Magnus Enger <magnus@libriotech.no>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
Signed-off-by: Benjamin Rokseth <benjamin.rokseth@kul.oslo.kommune.no>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
This patch adds the required entry in Makefile.PL so the clubs/ dir is correctly installed
during the make install step.
To test:
- Run:
$ cd kohaclone
$ perl Makefile.PL
- Follow any install method and options
- Run
$ make
$ ls blib/INTRANET_CGI_DIR/ | grep clubs
=> FAIL: No clubs dir
- Run:
$ make clean
- Apply this patch
- Run:
$ perl Makefile.PL
- Follow any install method and options
- Run
$ make
$ ls blib/INTRANET_CGI_DIR/ | grep clubs
=> SUCCESS: The clubs/ dir is correctly picked for inclussion in the intranet cgi dir
- Sign off :-D
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Bug 18028 removed the install_misc directory but
install_misc/UpgradeBackup.pm was still used by the 'upgrade' rule of
make.
Other files from install_misc were useless to it may be better not to
reintroduce this directory with only 1 file.
Test plan:
`make`
`sudo make install`
`make upgrade`
Signed-off-by: Josef Moravec <josef.moravec@gmail.com>
Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
In summary, changes are:
1) If you have chosen MySQL, Makefile.PL will ask you if you want TLS (default:
"no"), and then the locations for CA cert, client cert and client key
(reasonable defaults are provided). Settings <tls>, <ca>, <cert> and <key> are
added in koha-conf.xml
2) If <tls>yes</tls> in koha-conf.xml, the installer and database connection
scripts add the TLS options in both DBI connection strings and mysql command
line
To test
1/ Apply patch
2/ Check everything still works and db connections are the same as before
3/ Either run Makefile.PL and step through the options or edit your koha-conf.xml to
enable TLS
4/ Check db connections are still working
Patch provided to me by Dimitris Kamenopoulos and I reformatted it into a git patch,
any errors are probably mine
Signed-off-by: Mirko Tietgen <mirko@abunchofthings.net>
Signed-off-by: Jonathan Druart <jonathan.druart@bugs.koha-community.org>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
* Makefile.PL: Add `zebra_sru_host`, `zebra_sru_biblios_port` &
`zebra_sru_authorities_port` as possible command line arguments.
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Currently the Makefile.pl script only accepts the '--prev-install-log' commandline flag for reading Koha configuration values from the previous installation.
The Makefile does not have help output.
The aim of this bug report is to add 2 things:
- --help output
- commandline parameters that should allow automating many of the common settings if desired
- when commandline parameters are not passed we simply fall back to the interactive method of old
Test Plan:
- Run the Makefile without parameters — the script should work as before.
- Run the script with the '-h' flag — it should output help.
- Run the script with any number of additional legal flags — the script should skip those questions in its interactive mode.
Signed-off-by: Nicolas Legrand <nicolas.legrand@bulac.fr>
Reworked the log message with Bugzilla comments.
Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com>
Amended patch: perltidy GetOptions block
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>