Copying missing files from rel-1-2 to trunk
This commit is contained in:
parent
1a6b88483f
commit
a119883471
8 changed files with 4151 additions and 0 deletions
340
LICENSE
Normal file
340
LICENSE
Normal file
|
@ -0,0 +1,340 @@
|
|||
GNU GENERAL PUBLIC LICENSE
|
||||
Version 2, June 1991
|
||||
|
||||
Copyright (C) 1989, 1991 Free Software Foundation, Inc.
|
||||
59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
Everyone is permitted to copy and distribute verbatim copies
|
||||
of this license document, but changing it is not allowed.
|
||||
|
||||
Preamble
|
||||
|
||||
The licenses for most software are designed to take away your
|
||||
freedom to share and change it. By contrast, the GNU General Public
|
||||
License is intended to guarantee your freedom to share and change free
|
||||
software--to make sure the software is free for all its users. This
|
||||
General Public License applies to most of the Free Software
|
||||
Foundation's software and to any other program whose authors commit to
|
||||
using it. (Some other Free Software Foundation software is covered by
|
||||
the GNU Library General Public License instead.) You can apply it to
|
||||
your programs, too.
|
||||
|
||||
When we speak of free software, we are referring to freedom, not
|
||||
price. Our General Public Licenses are designed to make sure that you
|
||||
have the freedom to distribute copies of free software (and charge for
|
||||
this service if you wish), that you receive source code or can get it
|
||||
if you want it, that you can change the software or use pieces of it
|
||||
in new free programs; and that you know you can do these things.
|
||||
|
||||
To protect your rights, we need to make restrictions that forbid
|
||||
anyone to deny you these rights or to ask you to surrender the rights.
|
||||
These restrictions translate to certain responsibilities for you if you
|
||||
distribute copies of the software, or if you modify it.
|
||||
|
||||
For example, if you distribute copies of such a program, whether
|
||||
gratis or for a fee, you must give the recipients all the rights that
|
||||
you have. You must make sure that they, too, receive or can get the
|
||||
source code. And you must show them these terms so they know their
|
||||
rights.
|
||||
|
||||
We protect your rights with two steps: (1) copyright the software, and
|
||||
(2) offer you this license which gives you legal permission to copy,
|
||||
distribute and/or modify the software.
|
||||
|
||||
Also, for each author's protection and ours, we want to make certain
|
||||
that everyone understands that there is no warranty for this free
|
||||
software. If the software is modified by someone else and passed on, we
|
||||
want its recipients to know that what they have is not the original, so
|
||||
that any problems introduced by others will not reflect on the original
|
||||
authors' reputations.
|
||||
|
||||
Finally, any free program is threatened constantly by software
|
||||
patents. We wish to avoid the danger that redistributors of a free
|
||||
program will individually obtain patent licenses, in effect making the
|
||||
program proprietary. To prevent this, we have made it clear that any
|
||||
patent must be licensed for everyone's free use or not licensed at all.
|
||||
|
||||
The precise terms and conditions for copying, distribution and
|
||||
modification follow.
|
||||
|
||||
GNU GENERAL PUBLIC LICENSE
|
||||
TERMS AND CONDITIONS FOR COPYING, DISTRIBUTION AND MODIFICATION
|
||||
|
||||
0. This License applies to any program or other work which contains
|
||||
a notice placed by the copyright holder saying it may be distributed
|
||||
under the terms of this General Public License. The "Program", below,
|
||||
refers to any such program or work, and a "work based on the Program"
|
||||
means either the Program or any derivative work under copyright law:
|
||||
that is to say, a work containing the Program or a portion of it,
|
||||
either verbatim or with modifications and/or translated into another
|
||||
language. (Hereinafter, translation is included without limitation in
|
||||
the term "modification".) Each licensee is addressed as "you".
|
||||
|
||||
Activities other than copying, distribution and modification are not
|
||||
covered by this License; they are outside its scope. The act of
|
||||
running the Program is not restricted, and the output from the Program
|
||||
is covered only if its contents constitute a work based on the
|
||||
Program (independent of having been made by running the Program).
|
||||
Whether that is true depends on what the Program does.
|
||||
|
||||
1. You may copy and distribute verbatim copies of the Program's
|
||||
source code as you receive it, in any medium, provided that you
|
||||
conspicuously and appropriately publish on each copy an appropriate
|
||||
copyright notice and disclaimer of warranty; keep intact all the
|
||||
notices that refer to this License and to the absence of any warranty;
|
||||
and give any other recipients of the Program a copy of this License
|
||||
along with the Program.
|
||||
|
||||
You may charge a fee for the physical act of transferring a copy, and
|
||||
you may at your option offer warranty protection in exchange for a fee.
|
||||
|
||||
2. You may modify your copy or copies of the Program or any portion
|
||||
of it, thus forming a work based on the Program, and copy and
|
||||
distribute such modifications or work under the terms of Section 1
|
||||
above, provided that you also meet all of these conditions:
|
||||
|
||||
a) You must cause the modified files to carry prominent notices
|
||||
stating that you changed the files and the date of any change.
|
||||
|
||||
b) You must cause any work that you distribute or publish, that in
|
||||
whole or in part contains or is derived from the Program or any
|
||||
part thereof, to be licensed as a whole at no charge to all third
|
||||
parties under the terms of this License.
|
||||
|
||||
c) If the modified program normally reads commands interactively
|
||||
when run, you must cause it, when started running for such
|
||||
interactive use in the most ordinary way, to print or display an
|
||||
announcement including an appropriate copyright notice and a
|
||||
notice that there is no warranty (or else, saying that you provide
|
||||
a warranty) and that users may redistribute the program under
|
||||
these conditions, and telling the user how to view a copy of this
|
||||
License. (Exception: if the Program itself is interactive but
|
||||
does not normally print such an announcement, your work based on
|
||||
the Program is not required to print an announcement.)
|
||||
|
||||
These requirements apply to the modified work as a whole. If
|
||||
identifiable sections of that work are not derived from the Program,
|
||||
and can be reasonably considered independent and separate works in
|
||||
themselves, then this License, and its terms, do not apply to those
|
||||
sections when you distribute them as separate works. But when you
|
||||
distribute the same sections as part of a whole which is a work based
|
||||
on the Program, the distribution of the whole must be on the terms of
|
||||
this License, whose permissions for other licensees extend to the
|
||||
entire whole, and thus to each and every part regardless of who wrote it.
|
||||
|
||||
Thus, it is not the intent of this section to claim rights or contest
|
||||
your rights to work written entirely by you; rather, the intent is to
|
||||
exercise the right to control the distribution of derivative or
|
||||
collective works based on the Program.
|
||||
|
||||
In addition, mere aggregation of another work not based on the Program
|
||||
with the Program (or with a work based on the Program) on a volume of
|
||||
a storage or distribution medium does not bring the other work under
|
||||
the scope of this License.
|
||||
|
||||
3. You may copy and distribute the Program (or a work based on it,
|
||||
under Section 2) in object code or executable form under the terms of
|
||||
Sections 1 and 2 above provided that you also do one of the following:
|
||||
|
||||
a) Accompany it with the complete corresponding machine-readable
|
||||
source code, which must be distributed under the terms of Sections
|
||||
1 and 2 above on a medium customarily used for software interchange; or,
|
||||
|
||||
b) Accompany it with a written offer, valid for at least three
|
||||
years, to give any third party, for a charge no more than your
|
||||
cost of physically performing source distribution, a complete
|
||||
machine-readable copy of the corresponding source code, to be
|
||||
distributed under the terms of Sections 1 and 2 above on a medium
|
||||
customarily used for software interchange; or,
|
||||
|
||||
c) Accompany it with the information you received as to the offer
|
||||
to distribute corresponding source code. (This alternative is
|
||||
allowed only for noncommercial distribution and only if you
|
||||
received the program in object code or executable form with such
|
||||
an offer, in accord with Subsection b above.)
|
||||
|
||||
The source code for a work means the preferred form of the work for
|
||||
making modifications to it. For an executable work, complete source
|
||||
code means all the source code for all modules it contains, plus any
|
||||
associated interface definition files, plus the scripts used to
|
||||
control compilation and installation of the executable. However, as a
|
||||
special exception, the source code distributed need not include
|
||||
anything that is normally distributed (in either source or binary
|
||||
form) with the major components (compiler, kernel, and so on) of the
|
||||
operating system on which the executable runs, unless that component
|
||||
itself accompanies the executable.
|
||||
|
||||
If distribution of executable or object code is made by offering
|
||||
access to copy from a designated place, then offering equivalent
|
||||
access to copy the source code from the same place counts as
|
||||
distribution of the source code, even though third parties are not
|
||||
compelled to copy the source along with the object code.
|
||||
|
||||
4. You may not copy, modify, sublicense, or distribute the Program
|
||||
except as expressly provided under this License. Any attempt
|
||||
otherwise to copy, modify, sublicense or distribute the Program is
|
||||
void, and will automatically terminate your rights under this License.
|
||||
However, parties who have received copies, or rights, from you under
|
||||
this License will not have their licenses terminated so long as such
|
||||
parties remain in full compliance.
|
||||
|
||||
5. You are not required to accept this License, since you have not
|
||||
signed it. However, nothing else grants you permission to modify or
|
||||
distribute the Program or its derivative works. These actions are
|
||||
prohibited by law if you do not accept this License. Therefore, by
|
||||
modifying or distributing the Program (or any work based on the
|
||||
Program), you indicate your acceptance of this License to do so, and
|
||||
all its terms and conditions for copying, distributing or modifying
|
||||
the Program or works based on it.
|
||||
|
||||
6. Each time you redistribute the Program (or any work based on the
|
||||
Program), the recipient automatically receives a license from the
|
||||
original licensor to copy, distribute or modify the Program subject to
|
||||
these terms and conditions. You may not impose any further
|
||||
restrictions on the recipients' exercise of the rights granted herein.
|
||||
You are not responsible for enforcing compliance by third parties to
|
||||
this License.
|
||||
|
||||
7. If, as a consequence of a court judgment or allegation of patent
|
||||
infringement or for any other reason (not limited to patent issues),
|
||||
conditions are imposed on you (whether by court order, agreement or
|
||||
otherwise) that contradict the conditions of this License, they do not
|
||||
excuse you from the conditions of this License. If you cannot
|
||||
distribute so as to satisfy simultaneously your obligations under this
|
||||
License and any other pertinent obligations, then as a consequence you
|
||||
may not distribute the Program at all. For example, if a patent
|
||||
license would not permit royalty-free redistribution of the Program by
|
||||
all those who receive copies directly or indirectly through you, then
|
||||
the only way you could satisfy both it and this License would be to
|
||||
refrain entirely from distribution of the Program.
|
||||
|
||||
If any portion of this section is held invalid or unenforceable under
|
||||
any particular circumstance, the balance of the section is intended to
|
||||
apply and the section as a whole is intended to apply in other
|
||||
circumstances.
|
||||
|
||||
It is not the purpose of this section to induce you to infringe any
|
||||
patents or other property right claims or to contest validity of any
|
||||
such claims; this section has the sole purpose of protecting the
|
||||
integrity of the free software distribution system, which is
|
||||
implemented by public license practices. Many people have made
|
||||
generous contributions to the wide range of software distributed
|
||||
through that system in reliance on consistent application of that
|
||||
system; it is up to the author/donor to decide if he or she is willing
|
||||
to distribute software through any other system and a licensee cannot
|
||||
impose that choice.
|
||||
|
||||
This section is intended to make thoroughly clear what is believed to
|
||||
be a consequence of the rest of this License.
|
||||
|
||||
8. If the distribution and/or use of the Program is restricted in
|
||||
certain countries either by patents or by copyrighted interfaces, the
|
||||
original copyright holder who places the Program under this License
|
||||
may add an explicit geographical distribution limitation excluding
|
||||
those countries, so that distribution is permitted only in or among
|
||||
countries not thus excluded. In such case, this License incorporates
|
||||
the limitation as if written in the body of this License.
|
||||
|
||||
9. The Free Software Foundation may publish revised and/or new versions
|
||||
of the General Public License from time to time. Such new versions will
|
||||
be similar in spirit to the present version, but may differ in detail to
|
||||
address new problems or concerns.
|
||||
|
||||
Each version is given a distinguishing version number. If the Program
|
||||
specifies a version number of this License which applies to it and "any
|
||||
later version", you have the option of following the terms and conditions
|
||||
either of that version or of any later version published by the Free
|
||||
Software Foundation. If the Program does not specify a version number of
|
||||
this License, you may choose any version ever published by the Free Software
|
||||
Foundation.
|
||||
|
||||
10. If you wish to incorporate parts of the Program into other free
|
||||
programs whose distribution conditions are different, write to the author
|
||||
to ask for permission. For software which is copyrighted by the Free
|
||||
Software Foundation, write to the Free Software Foundation; we sometimes
|
||||
make exceptions for this. Our decision will be guided by the two goals
|
||||
of preserving the free status of all derivatives of our free software and
|
||||
of promoting the sharing and reuse of software generally.
|
||||
|
||||
NO WARRANTY
|
||||
|
||||
11. BECAUSE THE PROGRAM IS LICENSED FREE OF CHARGE, THERE IS NO WARRANTY
|
||||
FOR THE PROGRAM, TO THE EXTENT PERMITTED BY APPLICABLE LAW. EXCEPT WHEN
|
||||
OTHERWISE STATED IN WRITING THE COPYRIGHT HOLDERS AND/OR OTHER PARTIES
|
||||
PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESSED
|
||||
OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
|
||||
MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE. THE ENTIRE RISK AS
|
||||
TO THE QUALITY AND PERFORMANCE OF THE PROGRAM IS WITH YOU. SHOULD THE
|
||||
PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF ALL NECESSARY SERVICING,
|
||||
REPAIR OR CORRECTION.
|
||||
|
||||
12. IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
|
||||
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MAY MODIFY AND/OR
|
||||
REDISTRIBUTE THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES,
|
||||
INCLUDING ANY GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING
|
||||
OUT OF THE USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED
|
||||
TO LOSS OF DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY
|
||||
YOU OR THIRD PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER
|
||||
PROGRAMS), EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE
|
||||
POSSIBILITY OF SUCH DAMAGES.
|
||||
|
||||
END OF TERMS AND CONDITIONS
|
||||
|
||||
How to Apply These Terms to Your New Programs
|
||||
|
||||
If you develop a new program, and you want it to be of the greatest
|
||||
possible use to the public, the best way to achieve this is to make it
|
||||
free software which everyone can redistribute and change under these terms.
|
||||
|
||||
To do so, attach the following notices to the program. It is safest
|
||||
to attach them to the start of each source file to most effectively
|
||||
convey the exclusion of warranty; and each file should have at least
|
||||
the "copyright" line and a pointer to where the full notice is found.
|
||||
|
||||
<one line to give the program's name and a brief idea of what it does.>
|
||||
Copyright (C) 19yy <name of author>
|
||||
|
||||
This program is free software; you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation; either version 2 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program; if not, write to the Free Software
|
||||
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||
|
||||
|
||||
Also add information on how to contact you by electronic and paper mail.
|
||||
|
||||
If the program is interactive, make it output a short notice like this
|
||||
when it starts in an interactive mode:
|
||||
|
||||
Gnomovision version 69, Copyright (C) 19yy name of author
|
||||
Gnomovision comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
|
||||
This is free software, and you are welcome to redistribute it
|
||||
under certain conditions; type `show c' for details.
|
||||
|
||||
The hypothetical commands `show w' and `show c' should show the appropriate
|
||||
parts of the General Public License. Of course, the commands you use may
|
||||
be called something other than `show w' and `show c'; they could even be
|
||||
mouse-clicks or menu items--whatever suits your program.
|
||||
|
||||
You should also get your employer (if you work as a programmer) or your
|
||||
school, if any, to sign a "copyright disclaimer" for the program, if
|
||||
necessary. Here is a sample; alter the names:
|
||||
|
||||
Yoyodyne, Inc., hereby disclaims all copyright interest in the program
|
||||
`Gnomovision' (which makes passes at compilers) written by James Hacker.
|
||||
|
||||
<signature of Ty Coon>, 1 April 1989
|
||||
Ty Coon, President of Vice
|
||||
|
||||
This General Public License does not permit incorporating your program into
|
||||
proprietary programs. If your program is a subroutine library, you may
|
||||
consider it more useful to permit linking proprietary applications with the
|
||||
library. If this is what you want to do, use the GNU Library General
|
||||
Public License instead of this License.
|
7
README
Normal file
7
README
Normal file
|
@ -0,0 +1,7 @@
|
|||
19/7/00 chris@katipo.co.nz
|
||||
|
||||
Koha is distributed under the GPL license, please read the file LICENSE for
|
||||
more details.
|
||||
|
||||
To install the system please read INSTALL
|
||||
|
72
TODO
Normal file
72
TODO
Normal file
|
@ -0,0 +1,72 @@
|
|||
Koha TODO File
|
||||
==============
|
||||
|
||||
There are many planned features and enhancements to be made to Koha.
|
||||
If there are any items that you feel you can help with please subscribe
|
||||
to the Koha mailling list. See http://www.koha.org/mailing_list.html
|
||||
|
||||
|
||||
ITEMS TO BE DONE
|
||||
================
|
||||
* Tidy Documentation, including INSTALL file.
|
||||
* DatabaseOoptimisation.
|
||||
* Installer and packaging.
|
||||
* Tidy up HTML.
|
||||
* Branch Transfers.
|
||||
* Tidy Web Based Circulation.
|
||||
* Make OPAC Customisable.
|
||||
* Member Access
|
||||
* Accession and Shelf Lists.
|
||||
* Dewey Labels.
|
||||
* MARC Support.
|
||||
* Templating/"Skins".
|
||||
* Translations.
|
||||
* Z35.50 Support.
|
||||
* Circulation Protocol.
|
||||
|
||||
Below is a proposed roadmap of how new fetures will be implemented into
|
||||
Koha.
|
||||
|
||||
|
||||
PLANNED IMPLEMENTATION ROADMAP
|
||||
==============================
|
||||
1.2.x [stable] Planned Features
|
||||
* Tweaking HTML to make Koha more generic.
|
||||
* Installer + Packaging to incorporate updates as well as new installation.
|
||||
* Branch transfers and tidying up web circulation.
|
||||
* Customisable opac.
|
||||
(so librarians can choose what to display to the public easily).
|
||||
* Add websites, as both an item type, and as a biblio.
|
||||
|
||||
==
|
||||
1.3.x [devel] Planned Features
|
||||
Targets include:
|
||||
* Accession and shelf Lists.
|
||||
* Dewey labels.
|
||||
* MARC database changes "MARC invisible".
|
||||
* Transition tools.
|
||||
* Templating/"skins" feature.
|
||||
* Ethnicity question.
|
||||
* Ideas for member access.
|
||||
* Z39.50 import.
|
||||
|
||||
==
|
||||
1.3.5 [devel] Planned Features:
|
||||
* MARC front end changes "MARC visible".
|
||||
* "beta" version of member access change (LDAP, etc).
|
||||
* MARC import/export.
|
||||
* Additional skins for language & look-n-feel.
|
||||
* Z39.50 export (experimental).
|
||||
|
||||
==
|
||||
1.4.0 [stable] Planned Features:
|
||||
* Additional templates (Skins and Languages/Translations).
|
||||
* Ensure Koha mod_perl safe, test with persistent db connections.
|
||||
|
||||
==
|
||||
1.5.0 [devel] Planned Features:
|
||||
* Z39.50 export.
|
||||
* Accomodate batch imports/exports of biblio records in USMARC/UNIMARC format.
|
||||
* Circulation protocol (NCIP).
|
||||
* "Advanced" MARC features, XML
|
||||
[OCLC, Library of Congress has early release version of these tools out)
|
301
buildrelease
Normal file
301
buildrelease
Normal file
|
@ -0,0 +1,301 @@
|
|||
#!/usr/bin/perl
|
||||
|
||||
my $kohadir=`pwd`;
|
||||
chomp $kohadir;
|
||||
my $kohahtmldir="/koha/koha/koha-html/";
|
||||
|
||||
if (-e "/root/.kohaautobuild.conf") {
|
||||
open C, "/root/.kohaautobuild.conf";
|
||||
while (<C>) {
|
||||
chomp;
|
||||
if (/kohadir=(.*)/) {
|
||||
$kohadir=$1;
|
||||
}
|
||||
if (/kohahtmldir=(.*)/) {
|
||||
$kohahtmldir=$1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
my $input;
|
||||
|
||||
print qq |
|
||||
***************************************
|
||||
* Welcome to the Koha Release Builder *
|
||||
***************************************
|
||||
|
||||
This script will automatically build a release tarball.
|
||||
|
||||
The script assumes that you already have the koha and koha-html modules checked
|
||||
out for the release that you want to build, although it will update the modules
|
||||
before building.
|
||||
|
||||
|;
|
||||
print "\nWhere is the 'koha' cvs module located [$kohadir]: ";
|
||||
chomp($input = <STDIN>);
|
||||
if ($input) {
|
||||
$kohadir=$input;
|
||||
}
|
||||
|
||||
|
||||
print "\nWhere is the 'koha-html' cvs module located [$kohahtmldir]: ";
|
||||
chomp($input = <STDIN>);
|
||||
if ($input) {
|
||||
$kohahtmldir=$input;
|
||||
}
|
||||
|
||||
open (C, ">/root/.kohaautobuild.conf");
|
||||
print C qq|
|
||||
kohadir=$kohadir
|
||||
kohahtmldir=$kohahtmldir
|
||||
|;
|
||||
|
||||
print "\n\nGuessing at next release version. You may need to enter your SourceForge password...\n";
|
||||
chdir $kohadir;
|
||||
open (CVSLOG, "cvs log buildrelease|");
|
||||
my $symbolicnamessection=0;
|
||||
my $symbolicnames;
|
||||
my $highestversion;
|
||||
my $highestrc;
|
||||
my $released;
|
||||
while (<CVSLOG>) {
|
||||
if (/^symbolic names:/) {
|
||||
$symbolicnamessection=1;
|
||||
}
|
||||
if ($symbolicnamessection && (/^\s+([^:]*):/)) {
|
||||
my $tag=$1;
|
||||
if ($tag=~/R_(.*)/) {
|
||||
my $version='';
|
||||
my $rc=0;
|
||||
my $id=$1;
|
||||
$id=~s/-/\./g;
|
||||
if ($id =~/(.*)RC(.*)/) {
|
||||
$version=$1;
|
||||
$rc=$2;
|
||||
if (versioncompare($version, $highestversion)) {
|
||||
$highestversion=$version;
|
||||
$released=0;
|
||||
$highestrc=$rc;
|
||||
}
|
||||
} else {
|
||||
$version=$id;
|
||||
if (versioncompare($version, $highestversion)) {
|
||||
$highestversion=$version;
|
||||
$released=1;
|
||||
$highestrc=0;
|
||||
}
|
||||
}
|
||||
$symbolicnames->{$version}->{$rc}=1;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
my $releaseversion='';
|
||||
my $currentversion='';
|
||||
|
||||
if ($released) {
|
||||
$releaseversion=($highestversion+1)."RC1";
|
||||
$currentversion=$highestversion;
|
||||
} else {
|
||||
$releaseversion="$highestversion\RC".($highestrc+1);
|
||||
$currentversion="$highestversion\RC$highestrc";
|
||||
}
|
||||
|
||||
print "Current release tag is $currentversion.\n";
|
||||
print "\nWould you like to bump that up to $releaseversion? [Y]/N: ";
|
||||
chomp($input = <STDIN>);
|
||||
if ($input =~ /^n/i) {
|
||||
print "\nWould you like to rebuild the $currentversion tarball? Y/[N]: ";
|
||||
chomp($input = <STDIN>);
|
||||
if ($input =~ /^y/i) {
|
||||
$releaseversion=$currentversion;
|
||||
print "\n\n";
|
||||
print "Do not do this if you have released the tarball to anybody, as it will\n";
|
||||
print "overwrite the tag marking the files that were in the tarball.\n\n";
|
||||
print "Confirm that you want to overwrite the tag for $releaseversion? Y/[N]: ";
|
||||
chomp($input = <STDIN>);
|
||||
if ($input =~ /^n/i || $input eq '') {
|
||||
print "\nStopping. Please re-run buildrelease now.\n";
|
||||
exit;
|
||||
}
|
||||
} else {
|
||||
print "What should the new version be? [$releaseversion]: ";
|
||||
chomp ($input=<STDIN>);
|
||||
if ($input) {
|
||||
$releaseversion=$input;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
my $sfuserid='';
|
||||
if ($cvsroot=$ENV{'CVSROOT'}) {
|
||||
$cvsroot=~m#(.*)\@cvs#;
|
||||
$sfuserid=$1;
|
||||
} else {
|
||||
$ENV{'CVS_RSH'}='ssh';
|
||||
print "\nWhat is your userid at SourceForge: ";
|
||||
chomp($input = <STDIN>);
|
||||
if ($input) {
|
||||
$sfuserid=$input;
|
||||
}
|
||||
$ENV{'CVSROOT'}="$sfuserid\@cvs.koha.sourceforge.net:/cvsroot/koha";
|
||||
}
|
||||
my $tagname=$releaseversion;
|
||||
$tagname=~s/\./-/g;
|
||||
|
||||
print qq|
|
||||
Updating the 'koha' CVS files. You may need to enter your SourceForge password.
|
||||
Using $kohadir.
|
||||
|;
|
||||
chdir($kohadir);
|
||||
system("cvs update");
|
||||
print qq|
|
||||
Tagging koha with tag R_$tagname
|
||||
|;
|
||||
system("cvs tag -F R_$tagname");
|
||||
print qq|
|
||||
Updating the 'koha-html' CVS files. You may need to enter your SourceForge password.
|
||||
Using $kohahtmldir.
|
||||
|;
|
||||
chdir($kohahtmldir);
|
||||
system("cvs update");
|
||||
print qq|
|
||||
Tagging koha-html with tag R_$tagname
|
||||
|;
|
||||
system("cvs tag -F R_$tagname");
|
||||
|
||||
|
||||
|
||||
|
||||
my $rootdir="/tmp/koha-".$releaseversion;
|
||||
system("rm -rf $rootdir");
|
||||
mkdir ($rootdir, 0700);
|
||||
chdir($rootdir);
|
||||
|
||||
mkdir("intranet-cgi", 0755);
|
||||
mkdir("intranet-html", 0755);
|
||||
mkdir("opac-cgi", 0755);
|
||||
mkdir("opac-html", 0755);
|
||||
mkdir("scripts", 0755);
|
||||
mkdir("scripts/z3950daemon", 0755);
|
||||
mkdir("modules", 0755);
|
||||
mkdir("docs", 0755);
|
||||
|
||||
# Create koha.versin file
|
||||
|
||||
open (KV, ">$rootdir/koha.version");
|
||||
print KV "$releaseversion\n";
|
||||
close KV;
|
||||
|
||||
# Copy all CVS files to intranet-cgi
|
||||
system("cp -a $kohadir/* $rootdir/intranet-cgi");
|
||||
|
||||
# Move C4 to modules directory
|
||||
system("mv $rootdir/intranet-cgi/C4 $rootdir/modules");
|
||||
|
||||
# Move files from intranet-cgi to root of tarball
|
||||
system("mv $rootdir/intranet-cgi/INSTALL $rootdir");
|
||||
system("mv $rootdir/intranet-cgi/ChangeLog* $rootdir");
|
||||
system("mv $rootdir/intranet-cgi/Hints $rootdir");
|
||||
system("mv $rootdir/intranet-cgi/LICENSE $rootdir");
|
||||
system("mv $rootdir/intranet-cgi/News $rootdir");
|
||||
system("mv $rootdir/intranet-cgi/README $rootdir");
|
||||
system("mv $rootdir/intranet-cgi/TODO $rootdir");
|
||||
system("mv $rootdir/intranet-cgi/databaseinstall.sh $rootdir");
|
||||
system("mv $rootdir/intranet-cgi/installer.pl $rootdir");
|
||||
system("mv $rootdir/intranet-cgi/koha.upgrade $rootdir");
|
||||
chmod 0770, "$rootdir/installer.pl";
|
||||
chmod 0770, "$rootdir/koha.upgrade";
|
||||
system("mv $rootdir/intranet-cgi/koha.conf $rootdir");
|
||||
system("mv $rootdir/intranet-cgi/koha.mysql $rootdir");
|
||||
system("mv $rootdir/intranet-cgi/sampledata-1.2 $rootdir");
|
||||
system("gzip -9 $rootdir/sampledata-1.2");
|
||||
|
||||
# Copy files from intranet-cgi to opac-cgi
|
||||
system("cp $rootdir/intranet-cgi/detail.pl $rootdir/opac-cgi");
|
||||
system("cp $rootdir/intranet-cgi/moredetail.pl $rootdir/opac-cgi");
|
||||
system("cp $rootdir/intranet-cgi/search.pl $rootdir/opac-cgi");
|
||||
|
||||
|
||||
# Move files from intranet-cgi to /scripts/ directory
|
||||
system("mv $rootdir/intranet-cgi/telnet $rootdir/scripts");
|
||||
system("mv $rootdir/intranet-cgi/tkperl $rootdir/scripts");
|
||||
system("mv $rootdir/intranet-cgi/translator $rootdir/scripts");
|
||||
system("mv $rootdir/intranet-cgi/updater $rootdir/scripts");
|
||||
system("mv $rootdir/intranet-cgi/misc $rootdir/scripts");
|
||||
system("mv $rootdir/intranet-cgi/acqui.simple/processz3950queue $rootdir/scripts/z3950daemon/");
|
||||
system("mv $rootdir/intranet-cgi/acqui.simple/z3950-daemon-launch.sh $rootdir/scripts/z3950daemon/");
|
||||
system("mv $rootdir/intranet-cgi/acqui.simple/z3950-daemon-shell.sh $rootdir/scripts/z3950daemon/");
|
||||
|
||||
|
||||
# Remove extraneous files from intranet-cgi
|
||||
system("rm -f $rootdir/intranet-cgi/ChangeLog.bak");
|
||||
system("rm -f $rootdir/intranet-cgi/ChangeLog.bak");
|
||||
system("rm -f $rootdir/intranet-cgi/SendMessages");
|
||||
system("rm -f $rootdir/intranet-cgi/buildrelease");
|
||||
system("rm -f $rootdir/intranet-cgi/database.mysql");
|
||||
system("rm -f $rootdir/intranet-cgi/installer-lite.pl");
|
||||
system("rm -f $rootdir/intranet-cgi/koha-1.2.0.tar.gz");
|
||||
system("rm -f $rootdir/intranet-cgi/rel-1-2");
|
||||
system("rm -f $rootdir/intranet-cgi/testKoha.pl");
|
||||
system("rm -rf $rootdir/intranet-cgi/html-template");
|
||||
system("rm -rf $rootdir/intranet-cgi/t");
|
||||
|
||||
# Copy all CVS files to intranet-html and opac-html
|
||||
system("cp -a $kohahtmldir/intranet-html/* $rootdir/intranet-html");
|
||||
system("cp -a $kohahtmldir/opac-html/* $rootdir/opac-html");
|
||||
|
||||
# Remove extraneous files from opac-html
|
||||
system("rm -f $rootdir/opac-html/koha.mo");
|
||||
system("rm -f $rootdir/opac-html/koha.pot");
|
||||
system("rm -f $rootdir/opac-html/test");
|
||||
|
||||
# Remove extraneous files from intranet-html
|
||||
system("rm -f $rootdir/intranet-html/koha.pot");
|
||||
system("rm -f $rootdir/intranet-html/results.html");
|
||||
system("rm -f $rootdir/intranet-html/test");
|
||||
|
||||
# Remove junk from directory
|
||||
system("find $rootdir -name CVS -exec rm -rf \\{\\} \\; 2>/dev/null");
|
||||
system("find $rootdir -name *~ -exec rm -rf \\{\\} \\; 2>/dev/null");
|
||||
system("find $rootdir -name .#* -exec rm -rf \\{\\} \\; 2>/dev/null");
|
||||
|
||||
if (-e "/root/docs") {
|
||||
print "Copying docs folder from /root/docs...";
|
||||
system("cp -r /root/docs/* $rootdir/docs/");
|
||||
} else {
|
||||
print "I would have copied the docs from from /root/docs, but I couldn't find it.\n";
|
||||
print "Press <ENTER> to continue...\n";
|
||||
<STDIN>;
|
||||
}
|
||||
|
||||
chdir("/tmp");
|
||||
system("tar czf /tmp/koha-$releaseversion.tar.gz koha-".$releaseversion);
|
||||
system("rm -rf $rootdir");
|
||||
|
||||
print qq|
|
||||
============
|
||||
= ALL DONE =
|
||||
============
|
||||
|
||||
Your new tarball is located in /tmp/koha-$releaseversion.tar.gz
|
||||
|
||||
|;
|
||||
|
||||
|
||||
sub versioncompare {
|
||||
my $v1=shift;
|
||||
my $v2=shift;
|
||||
my @v1=split(/\./, $v1);
|
||||
my @v2=split(/\./, $v2);
|
||||
my $count=$#v1;
|
||||
($#v2>$count) && ($count=$#v2);
|
||||
for (my $index=0; $index<$count; $index++) {
|
||||
if ($v1[$index]>$v2[$index]) {
|
||||
return 1;
|
||||
}
|
||||
}
|
||||
return 0;
|
||||
}
|
4
koha.conf
Normal file
4
koha.conf
Normal file
|
@ -0,0 +1,4 @@
|
|||
database=koha
|
||||
hostname=localhost
|
||||
user=Koha
|
||||
pass=password
|
788
koha.mysql
Normal file
788
koha.mysql
Normal file
|
@ -0,0 +1,788 @@
|
|||
# MySQL dump 7.1
|
||||
#
|
||||
# Host: localhost Database: c4test
|
||||
#--------------------------------------------------------
|
||||
# Server version 3.22.32-log
|
||||
|
||||
#
|
||||
# Table structure for table 'accountlines'
|
||||
#
|
||||
CREATE TABLE accountlines (
|
||||
borrowernumber int(11) DEFAULT '0' NOT NULL,
|
||||
accountno smallint(6) DEFAULT '0' NOT NULL,
|
||||
itemnumber int(11),
|
||||
date date,
|
||||
amount decimal(28,6),
|
||||
description text,
|
||||
dispute text,
|
||||
accounttype varchar(5),
|
||||
amountoutstanding decimal(28,6),
|
||||
timestamp timestamp(14),
|
||||
KEY acctsborridx (borrowernumber),
|
||||
KEY timeidx (timestamp)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'accountoffsets'
|
||||
#
|
||||
CREATE TABLE accountoffsets (
|
||||
borrowernumber int(11) DEFAULT '0' NOT NULL,
|
||||
accountno smallint(6) DEFAULT '0' NOT NULL,
|
||||
offsetaccount smallint(6) DEFAULT '0' NOT NULL,
|
||||
offsetamount decimal(28,6),
|
||||
timestamp timestamp(14)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'additionalauthors'
|
||||
#
|
||||
CREATE TABLE additionalauthors (
|
||||
author text NOT NULL,
|
||||
biblionumber int(11) DEFAULT '0' NOT NULL,
|
||||
KEY bibidx (biblionumber)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'aqbookfund'
|
||||
#
|
||||
CREATE TABLE aqbookfund (
|
||||
bookfundid varchar(5) DEFAULT '' NOT NULL,
|
||||
bookfundname text,
|
||||
bookfundgroup varchar(5)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'aqbooksellers'
|
||||
#
|
||||
CREATE TABLE aqbooksellers (
|
||||
id int(11),
|
||||
name text,
|
||||
address1 text,
|
||||
address2 text,
|
||||
address3 text,
|
||||
address4 text,
|
||||
phone varchar(30),
|
||||
accountnumber text,
|
||||
othersupplier text,
|
||||
currency char(3) DEFAULT '' NOT NULL,
|
||||
deliverydays smallint(6),
|
||||
followupdays smallint(6),
|
||||
followupscancel smallint(6),
|
||||
specialty text,
|
||||
booksellerfax text,
|
||||
notes text,
|
||||
bookselleremail text,
|
||||
booksellerurl text,
|
||||
contact varchar(100),
|
||||
postal text,
|
||||
url varchar(255),
|
||||
contpos varchar(100),
|
||||
contphone varchar(100),
|
||||
contfax varchar(100),
|
||||
contaltphone varchar(100),
|
||||
contemail varchar(100),
|
||||
contnotes text,
|
||||
active tinyint(4),
|
||||
listprice varchar(5),
|
||||
invoiceprice varchar(5),
|
||||
gstreg tinyint(4),
|
||||
listincgst tinyint(4),
|
||||
invoiceincgst tinyint(4),
|
||||
discount float(6,4),
|
||||
fax varchar(50)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'aqbudget'
|
||||
#
|
||||
CREATE TABLE aqbudget (
|
||||
bookfundid char(5) DEFAULT '' NOT NULL,
|
||||
startdate date DEFAULT '0000-00-00' NOT NULL,
|
||||
enddate date,
|
||||
budgetamount decimal(13,2)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'aqorderbreakdown'
|
||||
#
|
||||
CREATE TABLE aqorderbreakdown (
|
||||
ordernumber int(11),
|
||||
linenumber int(11),
|
||||
branchcode char(4),
|
||||
bookfundid char(5) DEFAULT '' NOT NULL,
|
||||
allocation smallint(6)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'aqorderdelivery'
|
||||
#
|
||||
CREATE TABLE aqorderdelivery (
|
||||
ordernumber date DEFAULT '0000-00-00' NOT NULL,
|
||||
deliverynumber smallint(6) DEFAULT '0' NOT NULL,
|
||||
deliverydate varchar(18),
|
||||
qtydelivered smallint(6),
|
||||
deliverycomments text
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'aqorders'
|
||||
#
|
||||
CREATE TABLE aqorders (
|
||||
ordernumber int(11) DEFAULT '0' NOT NULL auto_increment,
|
||||
biblionumber int(11),
|
||||
title text,
|
||||
requisitionedby varchar(10),
|
||||
authorisedby varchar(10),
|
||||
booksellerid varchar(10) DEFAULT '' NOT NULL,
|
||||
deliverydays smallint(6),
|
||||
followupdays smallint(6),
|
||||
numberfollowupsallowed smallint(6),
|
||||
numberfollowupssent smallint(6),
|
||||
entrydate date,
|
||||
dateprinted date,
|
||||
quantity smallint(6),
|
||||
currency char(3),
|
||||
listprice decimal(28,6),
|
||||
totalamount decimal(28,6),
|
||||
datereceived date,
|
||||
booksellerinvoicenumber text,
|
||||
freight decimal(28,6),
|
||||
unitprice decimal(28,6),
|
||||
quantityreceived smallint(6),
|
||||
sourced text,
|
||||
cancelledby varchar(10),
|
||||
quantityreceiveddamaged smallint(6),
|
||||
datecancellationprinted date,
|
||||
notes text,
|
||||
supplierreference text,
|
||||
purchaseordernumber text,
|
||||
subscription tinyint(1),
|
||||
subscriptionfrom date,
|
||||
subscriptionto date,
|
||||
serialid varchar(30),
|
||||
basketno int(11),
|
||||
biblioitemnumber int(11),
|
||||
timestamp timestamp(14),
|
||||
rrp decimal(13,2),
|
||||
ecost decimal(13,2),
|
||||
gst decimal(13,2),
|
||||
PRIMARY KEY (ordernumber)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'biblio'
|
||||
#
|
||||
CREATE TABLE biblio (
|
||||
biblionumber int(11) DEFAULT '0' NOT NULL,
|
||||
author text,
|
||||
title text,
|
||||
unititle text,
|
||||
notes text,
|
||||
serial tinyint(1),
|
||||
seriestitle text,
|
||||
copyrightdate smallint(6),
|
||||
timestamp timestamp(14),
|
||||
KEY blbnoidx (biblionumber),
|
||||
PRIMARY KEY (biblionumber)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'biblioanalysis'
|
||||
#
|
||||
CREATE TABLE biblioanalysis (
|
||||
analyticaltitle text,
|
||||
biblionumber int(11) DEFAULT '0' NOT NULL,
|
||||
analyticalauthor text
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'biblioitems'
|
||||
#
|
||||
CREATE TABLE biblioitems (
|
||||
biblioitemnumber int(11) DEFAULT '0' NOT NULL,
|
||||
biblionumber int(11) DEFAULT '0' NOT NULL,
|
||||
volume text,
|
||||
number text,
|
||||
classification varchar(25),
|
||||
itemtype varchar(4),
|
||||
isbn varchar(14),
|
||||
issn varchar(9),
|
||||
dewey double(8,6),
|
||||
subclass char(3),
|
||||
publicationyear smallint(6),
|
||||
publishercode varchar(255),
|
||||
volumedate date,
|
||||
volumeddesc varchar(255),
|
||||
timestamp timestamp(14),
|
||||
illus varchar(255),
|
||||
pages varchar(255),
|
||||
notes text,
|
||||
size varchar(255),
|
||||
place varchar(255),
|
||||
KEY bibinoidx (biblioitemnumber),
|
||||
KEY bibnoidx (biblionumber),
|
||||
PRIMARY KEY (biblioitemnumber)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'bibliosubject'
|
||||
#
|
||||
CREATE TABLE bibliosubject (
|
||||
subject text NOT NULL,
|
||||
biblionumber int(11) DEFAULT '0' NOT NULL
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'bibliosubtitle'
|
||||
#
|
||||
CREATE TABLE bibliosubtitle (
|
||||
subtitle text NOT NULL,
|
||||
biblionumber int(11) DEFAULT '0' NOT NULL,
|
||||
KEY bibsubidx (biblionumber)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'borexp'
|
||||
#
|
||||
CREATE TABLE borexp (
|
||||
borrowernumber int(11),
|
||||
newexp date
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'borrowers'
|
||||
#
|
||||
CREATE TABLE borrowers (
|
||||
borrowernumber int(11) DEFAULT '0' NOT NULL,
|
||||
cardnumber varchar(9) DEFAULT '' NOT NULL,
|
||||
surname text NOT NULL,
|
||||
firstname text NOT NULL,
|
||||
title text,
|
||||
othernames text,
|
||||
initials text NOT NULL,
|
||||
streetaddress text NOT NULL,
|
||||
suburb text,
|
||||
city text NOT NULL,
|
||||
phone text NOT NULL,
|
||||
emailaddress text,
|
||||
faxnumber text,
|
||||
altstreetaddress text,
|
||||
altsuburb text,
|
||||
altcity text,
|
||||
altphone text,
|
||||
dateofbirth date,
|
||||
branchcode varchar(4) DEFAULT '' NOT NULL,
|
||||
categorycode char(2),
|
||||
dateenrolled date,
|
||||
gonenoaddress tinyint(1),
|
||||
lost tinyint(1),
|
||||
debarred tinyint(1),
|
||||
studentnumber text,
|
||||
school text,
|
||||
contactname text,
|
||||
borrowernotes text,
|
||||
guarantor int(11),
|
||||
area char(2),
|
||||
ethnicity varchar(50),
|
||||
ethnotes varchar(255),
|
||||
sex char(1),
|
||||
expiry date,
|
||||
altnotes varchar(255),
|
||||
altrelationship varchar(100),
|
||||
streetcity text,
|
||||
phoneday varchar(50),
|
||||
preferredcont char(1),
|
||||
physstreet varchar(100),
|
||||
KEY borrowernumber (borrowernumber),
|
||||
KEY cardnumber (cardnumber)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'branchcategories'
|
||||
#
|
||||
CREATE TABLE branchcategories (
|
||||
categorycode char(2) DEFAULT '' NOT NULL,
|
||||
branchcode char(4) DEFAULT '' NOT NULL,
|
||||
branchholding int(11)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'branches'
|
||||
#
|
||||
CREATE TABLE branches (
|
||||
branchcode varchar(4) DEFAULT '' NOT NULL,
|
||||
branchname text NOT NULL,
|
||||
branchaddress1 text,
|
||||
branchaddress2 text,
|
||||
branchaddress3 text,
|
||||
branchphone text,
|
||||
branchfax text,
|
||||
branchemail text,
|
||||
issuing tinyint(4),
|
||||
UNIQUE branchcode (branchcode)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'branchtransfers'
|
||||
#
|
||||
CREATE TABLE branchtransfers (
|
||||
itemnumber int(11) DEFAULT '0' NOT NULL,
|
||||
datesent date DEFAULT '0000-00-00' NOT NULL,
|
||||
frombranch varchar(4),
|
||||
datearrived date,
|
||||
tobranch varchar(4),
|
||||
comments text
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'catalogueentry'
|
||||
#
|
||||
CREATE TABLE catalogueentry (
|
||||
catalogueentry text NOT NULL,
|
||||
entrytype char(2),
|
||||
see text,
|
||||
seealso text,
|
||||
seeinstead text,
|
||||
biblionumber int(11)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'categories'
|
||||
#
|
||||
CREATE TABLE categories (
|
||||
categorycode char(2) DEFAULT '' NOT NULL,
|
||||
description text,
|
||||
enrolmentperiod smallint(6),
|
||||
upperagelimit smallint(6),
|
||||
dateofbirthrequired tinyint(1),
|
||||
finetype varchar(30),
|
||||
bulk tinyint(1),
|
||||
enrolmentfee decimal(28,6),
|
||||
overduenoticerequired tinyint(1),
|
||||
issuelimit smallint(6),
|
||||
reservefee decimal(28,6),
|
||||
UNIQUE categorycode (categorycode)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'categoryitem'
|
||||
#
|
||||
CREATE TABLE categoryitem (
|
||||
categorycode char(2) DEFAULT '' NOT NULL,
|
||||
itemtype varchar(4) DEFAULT '' NOT NULL,
|
||||
restrictedtype tinyint(1),
|
||||
rentaldiscount decimal(28,6),
|
||||
reservecharge decimal(28,6),
|
||||
fine decimal(28,6),
|
||||
firstremind int(11),
|
||||
chargeperiod int(11),
|
||||
accountsent int(11),
|
||||
chargename varchar(100)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'classification'
|
||||
#
|
||||
CREATE TABLE classification (
|
||||
classification varchar(12) DEFAULT '' NOT NULL
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'currency'
|
||||
#
|
||||
CREATE TABLE currency (
|
||||
currency varchar(10),
|
||||
rate float(7,5)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'deletedbiblio'
|
||||
#
|
||||
CREATE TABLE deletedbiblio (
|
||||
biblionumber int(11) DEFAULT '0' NOT NULL,
|
||||
author text,
|
||||
title text,
|
||||
unititle text,
|
||||
notes text,
|
||||
serial tinyint(1),
|
||||
seriestitle text,
|
||||
copyrightdate smallint(6),
|
||||
timestamp timestamp(14),
|
||||
KEY blbnoidx (biblionumber),
|
||||
PRIMARY KEY (biblionumber)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'deletedbiblioitems'
|
||||
#
|
||||
CREATE TABLE deletedbiblioitems (
|
||||
biblioitemnumber int(11) DEFAULT '0' NOT NULL,
|
||||
biblionumber int(11) DEFAULT '0' NOT NULL,
|
||||
volume text,
|
||||
number text,
|
||||
classification varchar(25),
|
||||
itemtype varchar(4),
|
||||
isbn varchar(14),
|
||||
issn varchar(9),
|
||||
dewey double(8,6),
|
||||
subclass char(3),
|
||||
publicationyear smallint(6),
|
||||
publishercode varchar(255),
|
||||
volumedate date,
|
||||
volumeddesc varchar(255),
|
||||
timestamp timestamp(14),
|
||||
illus varchar(255),
|
||||
pages varchar(255),
|
||||
notes text,
|
||||
size varchar(255),
|
||||
KEY bibinoidx (biblioitemnumber),
|
||||
KEY bibnoidx (biblionumber),
|
||||
PRIMARY KEY (biblioitemnumber)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'deletedborrowers'
|
||||
#
|
||||
CREATE TABLE deletedborrowers (
|
||||
borrowernumber int(11) DEFAULT '0' NOT NULL,
|
||||
cardnumber varchar(9) DEFAULT '' NOT NULL,
|
||||
surname text NOT NULL,
|
||||
firstname text NOT NULL,
|
||||
title text,
|
||||
othernames text,
|
||||
initials text NOT NULL,
|
||||
streetaddress text NOT NULL,
|
||||
suburb text,
|
||||
city text NOT NULL,
|
||||
phone text NOT NULL,
|
||||
emailaddress text,
|
||||
faxnumber text,
|
||||
altstreetaddress text,
|
||||
altsuburb text,
|
||||
altcity text,
|
||||
altphone text,
|
||||
dateofbirth date,
|
||||
branchcode varchar(4) DEFAULT '' NOT NULL,
|
||||
categorycode char(2),
|
||||
dateenrolled date,
|
||||
gonenoaddress tinyint(1),
|
||||
lost tinyint(1),
|
||||
debarred tinyint(1),
|
||||
studentnumber text,
|
||||
school text,
|
||||
contactname text,
|
||||
borrowernotes text,
|
||||
guarantor int(11),
|
||||
area char(2),
|
||||
ethnicity varchar(50),
|
||||
ethnotes varchar(255),
|
||||
sex char(1),
|
||||
expiry date,
|
||||
altnotes varchar(255),
|
||||
altrelationship varchar(100),
|
||||
streetcity text,
|
||||
phoneday varchar(50),
|
||||
preferredcont varchar(100),
|
||||
physstreet varchar(100),
|
||||
KEY borrowernumber (borrowernumber),
|
||||
KEY cardnumber (cardnumber)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'deleteditems'
|
||||
#
|
||||
CREATE TABLE deleteditems (
|
||||
itemnumber int(11) DEFAULT '0' NOT NULL,
|
||||
biblionumber int(11) DEFAULT '0' NOT NULL,
|
||||
multivolumepart varchar(30),
|
||||
biblioitemnumber int(11) DEFAULT '0' NOT NULL,
|
||||
barcode varchar(9) DEFAULT '' NOT NULL,
|
||||
dateaccessioned date,
|
||||
booksellerid varchar(10),
|
||||
homebranch varchar(4),
|
||||
price decimal(28,6),
|
||||
replacementprice decimal(28,6),
|
||||
replacementpricedate date,
|
||||
datelastborrowed date,
|
||||
datelastseen date,
|
||||
multivolume tinyint(1),
|
||||
stack tinyint(1),
|
||||
notforloan tinyint(1),
|
||||
itemlost tinyint(1),
|
||||
wthdrawn tinyint(1),
|
||||
bulk varchar(30),
|
||||
issues smallint(6),
|
||||
renewals smallint(6),
|
||||
reserves smallint(6),
|
||||
restricted tinyint(1),
|
||||
binding decimal(28,6),
|
||||
itemnotes text,
|
||||
holdingbranch varchar(4),
|
||||
interim tinyint(1),
|
||||
timestamp timestamp(14),
|
||||
KEY itembarcodeidx (barcode),
|
||||
KEY itembinoidx (biblioitemnumber),
|
||||
KEY itembibnoidx (biblionumber),
|
||||
PRIMARY KEY (itemnumber),
|
||||
UNIQUE barcode (barcode)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'issues'
|
||||
#
|
||||
CREATE TABLE issues (
|
||||
borrowernumber int(11) DEFAULT '0' NOT NULL,
|
||||
itemnumber int(11) DEFAULT '0' NOT NULL,
|
||||
date_due date,
|
||||
branchcode char(4),
|
||||
issuingbranch char(18),
|
||||
returndate date,
|
||||
lastreneweddate date,
|
||||
return char(4),
|
||||
renewals tinyint(4),
|
||||
timestamp timestamp(14),
|
||||
KEY issuesborridx (borrowernumber),
|
||||
KEY issuesitemidx (itemnumber),
|
||||
KEY bordate (borrowernumber,timestamp)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'items'
|
||||
#
|
||||
CREATE TABLE items (
|
||||
itemnumber int(11) DEFAULT '0' NOT NULL,
|
||||
biblionumber int(11) DEFAULT '0' NOT NULL,
|
||||
multivolumepart varchar(30),
|
||||
biblioitemnumber int(11) DEFAULT '0' NOT NULL,
|
||||
barcode varchar(9) DEFAULT '' NOT NULL,
|
||||
dateaccessioned date,
|
||||
booksellerid varchar(10),
|
||||
homebranch varchar(4),
|
||||
price decimal(8,2),
|
||||
replacementprice decimal(8,2),
|
||||
replacementpricedate date,
|
||||
datelastborrowed date,
|
||||
datelastseen date,
|
||||
multivolume tinyint(1),
|
||||
stack tinyint(1),
|
||||
notforloan tinyint(1),
|
||||
itemlost tinyint(1),
|
||||
wthdrawn tinyint(1),
|
||||
bulk varchar(30),
|
||||
issues smallint(6),
|
||||
renewals smallint(6),
|
||||
reserves smallint(6),
|
||||
restricted tinyint(1),
|
||||
binding decimal(28,6),
|
||||
itemnotes text,
|
||||
holdingbranch varchar(4),
|
||||
paidfor text,
|
||||
timestamp timestamp(14),
|
||||
KEY itembarcodeidx (barcode),
|
||||
KEY itembinoidx (biblioitemnumber),
|
||||
KEY itembibnoidx (biblionumber),
|
||||
PRIMARY KEY (itemnumber),
|
||||
UNIQUE barcode (barcode)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'itemsprices'
|
||||
#
|
||||
CREATE TABLE itemsprices (
|
||||
itemnumber int(11),
|
||||
price1 decimal(28,6),
|
||||
price2 decimal(28,6)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'itemtypes'
|
||||
#
|
||||
CREATE TABLE itemtypes (
|
||||
itemtype varchar(4) DEFAULT '' NOT NULL,
|
||||
description text,
|
||||
loanlength smallint(6),
|
||||
renewalsallowed smallint(6),
|
||||
rentalcharge double(16,4),
|
||||
UNIQUE itemtype (itemtype)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'multipart'
|
||||
#
|
||||
CREATE TABLE multipart (
|
||||
itemnumber int(11) DEFAULT '0' NOT NULL,
|
||||
other int(11) DEFAULT '0' NOT NULL
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'multivolume'
|
||||
#
|
||||
CREATE TABLE multivolume (
|
||||
biblionumber int(11) DEFAULT '0' NOT NULL,
|
||||
multivolumepart varchar(30) DEFAULT '' NOT NULL
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'newitems'
|
||||
#
|
||||
CREATE TABLE newitems (
|
||||
itemnumber int(11) DEFAULT '0' NOT NULL,
|
||||
publishercode varchar(18),
|
||||
biblionumber int(11) DEFAULT '0' NOT NULL,
|
||||
multivolumepart varchar(30),
|
||||
barcode varchar(9) DEFAULT '' NOT NULL,
|
||||
dateaccessioned date,
|
||||
booksellerid varchar(10),
|
||||
homebranch varchar(4),
|
||||
price decimal(28,6),
|
||||
replacementprice decimal(28,6),
|
||||
replacementpricedate date,
|
||||
datelastborrowed date,
|
||||
datelastseen date,
|
||||
multivolume tinyint(1),
|
||||
stack tinyint(1),
|
||||
notforloan tinyint(1),
|
||||
itemlost tinyint(1),
|
||||
wthdrawn tinyint(1),
|
||||
bulk varchar(30),
|
||||
issues smallint(6),
|
||||
renewals smallint(6),
|
||||
reserves smallint(6),
|
||||
restricted tinyint(1),
|
||||
binding decimal(28,6),
|
||||
itemnotes text,
|
||||
holdingbranch varchar(4),
|
||||
interim tinyint(1),
|
||||
volume text,
|
||||
number text,
|
||||
classification varchar(12),
|
||||
itemtype varchar(4),
|
||||
isbn varchar(14),
|
||||
issn varchar(9),
|
||||
dewey double(16,4),
|
||||
subclass char(3),
|
||||
publicationyear smallint(6),
|
||||
KEY itembarcodeidx (barcode),
|
||||
KEY itembibnoidx (biblionumber),
|
||||
PRIMARY KEY (itemnumber)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'printers'
|
||||
#
|
||||
CREATE TABLE printers (
|
||||
printername char(40),
|
||||
printqueue char(20),
|
||||
printtype char(20)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'procedures'
|
||||
#
|
||||
CREATE TABLE procedures (
|
||||
proccode varchar(4),
|
||||
procdesc text,
|
||||
proclevel smallint(6)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'publisher'
|
||||
#
|
||||
CREATE TABLE publisher (
|
||||
publishercode varchar(18) DEFAULT '' NOT NULL,
|
||||
publishername text NOT NULL
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'reserveconstraints'
|
||||
#
|
||||
CREATE TABLE reserveconstraints (
|
||||
borrowernumber int(11) DEFAULT '0' NOT NULL,
|
||||
reservedate date DEFAULT '0000-00-00' NOT NULL,
|
||||
biblionumber int(11) DEFAULT '0' NOT NULL,
|
||||
biblioitemnumber int(11),
|
||||
timestamp timestamp(14)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'reserves'
|
||||
#
|
||||
CREATE TABLE reserves (
|
||||
borrowernumber int(11) DEFAULT '0' NOT NULL,
|
||||
reservedate date DEFAULT '0000-00-00' NOT NULL,
|
||||
biblionumber int(11) DEFAULT '0' NOT NULL,
|
||||
constrainttype char(1),
|
||||
branchcode varchar(4),
|
||||
notificationdate date,
|
||||
reminderdate date,
|
||||
cancellationdate date,
|
||||
reservenotes text,
|
||||
priority smallint(6),
|
||||
found char(1),
|
||||
timestamp timestamp(14),
|
||||
itemnumber int(11)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'searchstats'
|
||||
#
|
||||
CREATE TABLE searchstats (
|
||||
time datetime,
|
||||
searchstring text
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'serialissues'
|
||||
#
|
||||
CREATE TABLE serialissues (
|
||||
biblionumber int(11) DEFAULT '0' NOT NULL,
|
||||
volume varchar(20) DEFAULT '' NOT NULL,
|
||||
number varchar(20) DEFAULT '' NOT NULL,
|
||||
ordernumber smallint(6),
|
||||
issuedate varchar(20),
|
||||
received varchar(18)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'statistics'
|
||||
#
|
||||
CREATE TABLE statistics (
|
||||
datetime datetime DEFAULT '0000-00-00 00:00:00' NOT NULL,
|
||||
branch varchar(4),
|
||||
proccode varchar(4),
|
||||
value double(16,4),
|
||||
type varchar(16),
|
||||
other text,
|
||||
usercode varchar(10),
|
||||
itemnumber int(11),
|
||||
itemtype varchar(4),
|
||||
borrowernumber int(11) default NULL,
|
||||
KEY timeidx (datetime)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'stopwords'
|
||||
#
|
||||
CREATE TABLE stopwords (
|
||||
word varchar(255)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'systempreferences'
|
||||
#
|
||||
CREATE TABLE systempreferences (
|
||||
variable char(50) DEFAULT '' NOT NULL,
|
||||
value char(200),
|
||||
PRIMARY KEY (variable)
|
||||
);
|
||||
|
||||
#
|
||||
# Table structure for table 'users'
|
||||
#
|
||||
CREATE TABLE users (
|
||||
usercode varchar(10),
|
||||
username text,
|
||||
password text,
|
||||
level smallint(6)
|
||||
);
|
||||
|
335
koha.upgrade
Normal file
335
koha.upgrade
Normal file
|
@ -0,0 +1,335 @@
|
|||
#!/usr/bin/perl -w
|
||||
|
||||
my %configfile;
|
||||
open (KC, "/etc/koha.conf");
|
||||
while (<KC>) {
|
||||
chomp;
|
||||
(next) if (/^\s*#/);
|
||||
if (/(.*)\s*=\s*(.*)/) {
|
||||
my $variable=$1;
|
||||
my $value=$2;
|
||||
# Clean up white space at beginning and end
|
||||
$variable=~s/^\s*//g;
|
||||
$variable=~s/\s*$//g;
|
||||
$value=~s/^\s*//g;
|
||||
$value=~s/\s*$//g;
|
||||
$configfile{$variable}=$value;
|
||||
}
|
||||
}
|
||||
|
||||
my $intranetdir=$configfile{'intranetdir'};
|
||||
my $opacdir=$configfile{'opacdir'};
|
||||
my $kohaversion=$configfile{'kohaversion'};
|
||||
my $database=$configfile{'database'};
|
||||
my $host=$configfile{'host'};
|
||||
my $user=$configfile{'user'};
|
||||
my $pass=$configfile{'pass'};
|
||||
|
||||
|
||||
($kohaversion) || ($kohaversion='unknown version');
|
||||
my $newversion=`cat koha.version`;
|
||||
chomp $newversion;
|
||||
|
||||
print qq|
|
||||
|
||||
================
|
||||
= Koha Upgrade =
|
||||
================
|
||||
|
||||
You are attempting to upgrade from Koha $kohaversion to $newversion.
|
||||
|
||||
We recommend that you do a complete backup of all your files before upgrading.
|
||||
This upgrade script will make a backup copy of your files for you.
|
||||
|
||||
Would you like to proceed? ([Y]/N):
|
||||
|;
|
||||
|
||||
my $answer = <STDIN>;
|
||||
chomp $answer;
|
||||
|
||||
if ($answer eq "Y" || $answer eq "y") {
|
||||
print "Great! continuing upgrade... \n";
|
||||
} else {
|
||||
print qq|
|
||||
|
||||
Aborting. Please re-run koha.upgrade when you are ready to upgrade Koha.
|
||||
|;
|
||||
exit;
|
||||
};
|
||||
|
||||
my $backupdir='/usr/local/koha/backups';
|
||||
print "Please specify a backup directory [$backupdir]: ";
|
||||
|
||||
$answer = <STDIN>;
|
||||
chomp $answer;
|
||||
|
||||
if ($answer) {
|
||||
$backupdir=$answer;
|
||||
}
|
||||
|
||||
if (! -e $backupdir) {
|
||||
my $result=mkdir ($backupdir, oct(770));
|
||||
if ($result==0) {
|
||||
my @dirs = split(m#/#, $backupdir);
|
||||
my $checkdir='';
|
||||
foreach (@dirs) {
|
||||
$checkdir.="$_/";
|
||||
unless (-e "$checkdir") {
|
||||
mkdir($checkdir, 0775);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
chmod 0770, $backupdir;
|
||||
|
||||
# Backup MySql database
|
||||
#
|
||||
#
|
||||
my $mysql;
|
||||
my $mysqldir;
|
||||
|
||||
foreach my $mysql (qw(/usr/local/mysql
|
||||
/opt/mysql
|
||||
)) {
|
||||
if ( -d $mysql ) {
|
||||
$mysqldir=$mysql;
|
||||
}
|
||||
}
|
||||
if (!$mysqldir){
|
||||
$mysqldir='/usr';
|
||||
}
|
||||
|
||||
|
||||
|
||||
my ($sec, $min, $hr, $day, $month, $year) = (localtime(time))[0,1,2,3,4,5];
|
||||
$month++;
|
||||
$year+=1900;
|
||||
my $date= sprintf "%4d-%02d-%02d_%02d:%02d:%02d", $year, $month, $day,$hr,$min,$sec;
|
||||
|
||||
open (MD, "$mysqldir/bin/mysqldump --user=$user --password=$pass --host=$host $database|");
|
||||
|
||||
open BF, ">$backupdir/Koha.backup_$date";
|
||||
|
||||
my $itemcounter=0;
|
||||
my $bibliocounter=0;
|
||||
my $biblioitemcounter=0;
|
||||
my $membercounter=0;
|
||||
|
||||
while (<MD>) {
|
||||
(/insert into items /i) && ($itemcounter++);
|
||||
(/insert into biblioitems /i) && ($biblioitemcounter++);
|
||||
(/insert into biblio /i) && ($bibliocounter++);
|
||||
(/insert into borrowers /i) && ($membercounter++);
|
||||
print BF $_;
|
||||
}
|
||||
|
||||
close BF;
|
||||
close MD;
|
||||
|
||||
|
||||
my $filels=`ls -hl $backupdir/Koha.backup_$date`;
|
||||
chomp $filels;
|
||||
printf qq|
|
||||
|
||||
Backed up:
|
||||
|
||||
%6d biblio entries
|
||||
%6d biblioitems entries
|
||||
%6d items entries
|
||||
%6d borrowers
|
||||
|
||||
$filels
|
||||
|
||||
Does this look right? ([Y]/N):
|
||||
|, $bibliocounter, $biblioitemcounter, $itemcounter, $membercounter;
|
||||
|
||||
$answer = <STDIN>;
|
||||
chomp $answer;
|
||||
|
||||
if ($answer=~/^n/i) {
|
||||
print qq|
|
||||
|
||||
Aborting. The database dump is located in:
|
||||
|
||||
$backupdir/Koha.backup_$date
|
||||
|
||||
|;
|
||||
exit;
|
||||
} else {
|
||||
print "Great! continuing upgrade... \n";
|
||||
};
|
||||
|
||||
|
||||
|
||||
if ($opacdir && $intranetdir) {
|
||||
print qq|
|
||||
|
||||
I believe that your old files are located in:
|
||||
|
||||
OPAC: $opacdir
|
||||
INTRANET: $intranetdir
|
||||
|
||||
|
||||
Does this look right? ([Y]/N):
|
||||
|;
|
||||
$answer = <STDIN>;
|
||||
chomp $answer;
|
||||
|
||||
if ($answer =~/n/i) {
|
||||
$intranetdir='';
|
||||
$opacdir='';
|
||||
} else {
|
||||
print "Great! continuing upgrade... \n";
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
if (!$opacdir || !$intranetdir) {
|
||||
$intranetdir='';
|
||||
$opacdir='';
|
||||
while (!$intranetdir) {
|
||||
print "Please specify the location of your INTRANET files: ";
|
||||
|
||||
$answer = <STDIN>;
|
||||
chomp $answer;
|
||||
|
||||
if ($answer) {
|
||||
$intranetdir=$answer;
|
||||
}
|
||||
if (! -e "$intranetdir/htdocs") {
|
||||
print "\nCouldn't find the htdocs directory here. That doesn't look right.\nPlease enter another location.\n\n";
|
||||
$intranetdir='';
|
||||
}
|
||||
}
|
||||
while (!$opacdir) {
|
||||
print "Please specify the location of your OPAC files: ";
|
||||
|
||||
$answer = <STDIN>;
|
||||
chomp $answer;
|
||||
|
||||
if ($answer) {
|
||||
$opacdir=$answer;
|
||||
}
|
||||
if (! -e "$opacdir/htdocs") {
|
||||
print "\nCouldn't find the htdocs directory here. That doesn't look right.\nPlease enter another location.\n\n";
|
||||
$opacdir='';
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
print "\n\nBacking up old Koha scripts...\n";
|
||||
print "===============================\n\n";
|
||||
|
||||
mkdir "$backupdir/kohafiles-$date", 0770;
|
||||
mkdir "$backupdir/kohafiles-$date/intranet", 0770;
|
||||
mkdir "$backupdir/kohafiles-$date/opac", 0770;
|
||||
|
||||
my $result=system("cp -R $intranetdir/* $backupdir/kohafiles-$date/intranet/");
|
||||
if ($result) {
|
||||
print "Error encounted when copying $intranetdir to $backupdir/kohafiles-$date/intranet/\n";
|
||||
exit;
|
||||
} else {
|
||||
system("rm -rf $intranetdir/*");
|
||||
}
|
||||
$result=system("cp -R $opacdir/* $backupdir/kohafiles-$date/opac/");
|
||||
if ($result) {
|
||||
print "Error encounted when copying $opacdir to $backupdir/kohafiles-$date/opac/\n";
|
||||
exit;
|
||||
} else {
|
||||
system("rm -rf $opacdir/*");
|
||||
}
|
||||
|
||||
print "Creating $intranetdir/htdocs...\n";
|
||||
mkdir ("$intranetdir/htdocs", oct(750));
|
||||
print "Creating $intranetdir/cgi-bin...\n";
|
||||
mkdir ("$intranetdir/cgi-bin", oct(750));
|
||||
print "Creating $intranetdir/modules...\n";
|
||||
mkdir ("$intranetdir/modules", oct(750));
|
||||
print "Creating $intranetdir/scripts...\n";
|
||||
mkdir ("$intranetdir/scripts", oct(750));
|
||||
chmod (oct(770), "$opacdir");
|
||||
print "Creating $opacdir/htdocs...\n";
|
||||
mkdir ("$opacdir/htdocs", oct(750));
|
||||
print "Creating $opacdir/cgi-bin...\n";
|
||||
mkdir ("$opacdir/cgi-bin", oct(750));
|
||||
|
||||
my $httpduser;
|
||||
my $realhttpdconf;
|
||||
|
||||
foreach my $httpdconf (qw(/usr/local/apache/conf/httpd.conf
|
||||
/usr/local/etc/apache/httpd.conf
|
||||
/usr/local/etc/apache/apache.conf
|
||||
/var/www/conf/httpd.conf
|
||||
/etc/apache/conf/httpd.conf
|
||||
/etc/apache/conf/apache.conf
|
||||
/etc/apache-ssl/conf/apache.conf
|
||||
/etc/httpd/conf/httpd.conf
|
||||
/etc/httpd/httpd.conf)) {
|
||||
if ( -f $httpdconf ) {
|
||||
$realhttpdconf=$httpdconf;
|
||||
open (HTTPDCONF, $httpdconf) or warn "Insufficient privileges to open $httpdconf for reading.\n";
|
||||
while (<HTTPDCONF>) {
|
||||
if (/^\s*User\s+"?([-\w]+)"?\s*$/) {
|
||||
$httpduser = $1;
|
||||
}
|
||||
}
|
||||
close(HTTPDCONF);
|
||||
}
|
||||
}
|
||||
$httpduser ||= 'Undetermined';
|
||||
|
||||
print "\n\nINSTALLING KOHA...\n";
|
||||
print "\n\n==================\n";
|
||||
print "Copying internet-html files to $intranetdir/htdocs...\n";
|
||||
system("cp -R intranet-html/* $intranetdir/htdocs/");
|
||||
print "Copying intranet-cgi files to $intranetdir/cgi-bin...\n";
|
||||
system("cp -R intranet-cgi/* $intranetdir/cgi-bin/");
|
||||
print "Copying script files to $intranetdir/scripts...\n";
|
||||
system("cp -R scripts/* $intranetdir/scripts/");
|
||||
print "Copying module files to $intranetdir/modules...\n";
|
||||
system("cp -R modules/* $intranetdir/modules/");
|
||||
print "Copying opac-html files to $opacdir/htdocs...\n";
|
||||
system("cp -R opac-html/* $opacdir/htdocs/");
|
||||
print "Copying opac-cgi files to $opacdir/cgi-bin...\n";
|
||||
system("cp -R opac-cgi/* $opacdir/cgi-bin/");
|
||||
|
||||
system("chown -R root.$httpduser $opacdir");
|
||||
system("chown -R root.$httpduser $intranetdir");
|
||||
|
||||
|
||||
print qq|
|
||||
|
||||
Upgrading Database
|
||||
==================
|
||||
|;
|
||||
system ("perl -I $intranetdir/modules scripts/updater/updatedatabase");
|
||||
|
||||
|
||||
|
||||
print qq|
|
||||
|
||||
==========================
|
||||
= Koha Upgrade Completed =
|
||||
==========================
|
||||
The Koha Upgrade is finished. If you are upgrading from a version of Koha
|
||||
prior to 1.2.1, it is likely that you will have to modify your Apache
|
||||
configuration to point it to the new files.
|
||||
|
||||
In your INTRANET VirtualHost section you should have:
|
||||
DocumentRoot $intranetdir/htdocs
|
||||
ScriptAlias /cgi-bin/koha/ $intranetdir/cgi-bin/
|
||||
SetEnv PERL5LIB $intranetdir/modules
|
||||
|
||||
In the OPAC VirtualHost section you should have:
|
||||
DocumentRoot $opacdir/htdocs
|
||||
ScriptAlias /cgi-bin/koha/ $opacdir/cgi-bin/
|
||||
SetEnv PERL5LIB $intranetdir/modules
|
||||
|
||||
You may also need to uncomment a "LoadModules env_module ... " line and restart
|
||||
Apache.
|
||||
|
||||
Please report any problems you encounter through http://bugs.koha.org/
|
||||
|;
|
2304
sampledata-1.2
Normal file
2304
sampledata-1.2
Normal file
File diff suppressed because it is too large
Load diff
Loading…
Reference in a new issue