mirror of
https://gitlab.archlinux.org/archlinux/aurweb.git
synced 2025-02-03 10:43:03 +01:00
Add Archive_Tar class to lib/
Some AUR setups do not have PEAR available. While other setups have access to outdated Archive_Tar versions. Avoid these problems completely by including the necessary files for Archive_Tar in lib/. Remove Archive_Tar requirement from INSTALL doc. Signed-off-by: canyonknight <canyonknight@gmail.com>
This commit is contained in:
parent
afaa2404ac
commit
acdf9a85a0
4 changed files with 3066 additions and 11 deletions
11
INSTALL
11
INSTALL
|
@ -51,17 +51,6 @@ Setup on Arch Linux:
|
|||
If those php extensions are separate packages on your system, install
|
||||
them.
|
||||
|
||||
AUR requires PEAR and the Archive_Tar module (version > 1.3.7).
|
||||
Installing PEAR will vary depending on the system and may already
|
||||
be included with PHP. You can also find it in the PHP source
|
||||
distribution.
|
||||
|
||||
PHP sources: http://www.php.net/downloads.php
|
||||
Archive_Tar PEAR module: http://pear.php.net/package/Archive_Tar
|
||||
|
||||
- Install the Archive_Tar PEAR package:
|
||||
# pear install Archive_Tar
|
||||
|
||||
6) Configure MySQL
|
||||
- Start the MySQL service. Example:
|
||||
# /etc/rc.d/mysqld start
|
||||
|
|
1063
web/lib/Archive/PEAR.php
Normal file
1063
web/lib/Archive/PEAR.php
Normal file
File diff suppressed because it is too large
Load diff
33
web/lib/Archive/PEAR5.php
Normal file
33
web/lib/Archive/PEAR5.php
Normal file
|
@ -0,0 +1,33 @@
|
|||
<?php
|
||||
/**
|
||||
* This is only meant for PHP 5 to get rid of certain strict warning
|
||||
* that doesn't get hidden since it's in the shutdown function
|
||||
*/
|
||||
class PEAR5
|
||||
{
|
||||
/**
|
||||
* If you have a class that's mostly/entirely static, and you need static
|
||||
* properties, you can use this method to simulate them. Eg. in your method(s)
|
||||
* do this: $myVar = &PEAR5::getStaticProperty('myclass', 'myVar');
|
||||
* You MUST use a reference, or they will not persist!
|
||||
*
|
||||
* @access public
|
||||
* @param string $class The calling classname, to prevent clashes
|
||||
* @param string $var The variable to retrieve.
|
||||
* @return mixed A reference to the variable. If not set it will be
|
||||
* auto initialised to NULL.
|
||||
*/
|
||||
static function &getStaticProperty($class, $var)
|
||||
{
|
||||
static $properties;
|
||||
if (!isset($properties[$class])) {
|
||||
$properties[$class] = array();
|
||||
}
|
||||
|
||||
if (!array_key_exists($var, $properties[$class])) {
|
||||
$properties[$class][$var] = null;
|
||||
}
|
||||
|
||||
return $properties[$class][$var];
|
||||
}
|
||||
}
|
1970
web/lib/Archive/Tar.php
Normal file
1970
web/lib/Archive/Tar.php
Normal file
File diff suppressed because it is too large
Load diff
Loading…
Add table
Reference in a new issue