[packages/php-seclib] up to 0.3.5, MIT licensed now
glen
glen at pld-linux.org
Tue Jul 9 09:32:25 CEST 2013
commit ca17a2a5a504e92cfd639e684a3002954bf9a3fb
Author: Elan Ruusamäe <glen at delfi.ee>
Date: Tue Jul 9 10:30:07 2013 +0300
up to 0.3.5, MIT licensed now
includes.patch | 69 +++++++++++++++++++++++++++++++++++++++++++++------------
php-seclib.spec | 45 ++++++++++++++++++-------------------
2 files changed, 77 insertions(+), 37 deletions(-)
---
diff --git a/php-seclib.spec b/php-seclib.spec
index 1f19971..c10d984 100644
--- a/php-seclib.spec
+++ b/php-seclib.spec
@@ -1,20 +1,19 @@
# TODO
-# - individtual php-pear-XXX packages
+# - individual php-pear-XXX packages
# http://phpseclib.sourceforge.net/pear.htm
# pear remote-list -c phpseclib
-%define subver a
-%define rel 3
+# this way it won't file-conflict with PEAR packages
%define pkgname seclib
%define php_min_version 5.2.0
%include /usr/lib/rpm/macros.php
Summary: PHP Secure Communications Library
Name: php-%{pkgname}
-Version: 0.2.1
-Release: 0.%{subver}.%{rel}
-License: LGPL
+Version: 0.3.5
+Release: 1
+License: MIT
Group: Development/Languages/PHP
-Source0: http://downloads.sourceforge.net/phpseclib/phpseclib%{version}%{subver}.zip
-# Source0-md5: 028be0414123f4bff61f1b2b4fd68fab
+Source0: http://downloads.sourceforge.net/phpseclib/phpseclib%{version}.zip
+# Source0-md5: d4a0692a8c2d5ef919f8f867e3878a74
URL: http://phpseclib.sourceforge.net/
BuildRequires: php-pear-PEAR
BuildRequires: rpm-php-pearprov >= 4.4.2-11
@@ -39,39 +38,39 @@ AES, SSH-1, SSH-2, and SFTP.
%prep
%setup -qc
-%undos -f php,html,css
+%undos -f php
%patch0 -p1
-mkdir html
-mv *.html *.css html
-
-# php 4.2, php 5.0
-rm PHP/Compat/Function/array_fill.php
-# php 5.0
-rm PHP/Compat/Function/bcpowmod.php
-# php 5.0
-rm PHP/Compat/Function/str_split.php
-
%install
rm -rf $RPM_BUILD_ROOT
install -d $RPM_BUILD_ROOT%{php_pear_dir}
-cp -a PHP Crypt Math Net $RPM_BUILD_ROOT%{php_pear_dir}
+cp -a . $RPM_BUILD_ROOT%{php_pear_dir}
+
+%{__rm} $RPM_BUILD_ROOT%{php_pear_dir}/openssl.cnf
%clean
rm -rf $RPM_BUILD_ROOT
%files
%defattr(644,root,root,755)
-%doc html
+%doc openssl.cnf
%{php_pear_dir}/Crypt/AES.php
+%{php_pear_dir}/Crypt/Blowfish.php
%{php_pear_dir}/Crypt/DES.php
%{php_pear_dir}/Crypt/Hash.php
-%{php_pear_dir}/Crypt/RC4.php
-%{php_pear_dir}/Crypt/RSA.php
%{php_pear_dir}/Crypt/Random.php
+%{php_pear_dir}/Crypt/RC4.php
%{php_pear_dir}/Crypt/Rijndael.php
+%{php_pear_dir}/Crypt/RSA.php
%{php_pear_dir}/Crypt/TripleDES.php
+%{php_pear_dir}/Crypt/Twofish.php
+%{php_pear_dir}/File/ANSI.php
+%{php_pear_dir}/File/ASN1.php
+%{php_pear_dir}/File/X509.php
%{php_pear_dir}/Math/BigInteger.php
+%{php_pear_dir}/Net/SCP.php
%{php_pear_dir}/Net/SFTP.php
+%dir %{php_pear_dir}/Net/SFTP
+%{php_pear_dir}/Net/SFTP/Stream.php
%{php_pear_dir}/Net/SSH1.php
%{php_pear_dir}/Net/SSH2.php
diff --git a/includes.patch b/includes.patch
index 6f189b3..9c5a9d8 100644
--- a/includes.patch
+++ b/includes.patch
@@ -1,22 +1,63 @@
---- php-seclib-0.2.1/Crypt/TripleDES.php~ 2010-02-25 22:40:26.000000000 +0200
-+++ php-seclib-0.2.1/Crypt/TripleDES.php 2010-08-31 09:54:45.919440789 +0300
-@@ -54,7 +54,7 @@
- /**
+--- php-seclib-0.3.5/Crypt/TripleDES.php~ 2013-07-09 09:59:43.969186930 +0300
++++ php-seclib-0.3.5/Crypt/TripleDES.php 2013-07-09 10:00:41.654938715 +0300
+@@ -57,7 +57,7 @@
* Include Crypt_DES
*/
--require_once 'DES.php';
-+require_once 'Crypt/DES.php';
+ if (!class_exists('Crypt_DES')) {
+- require_once('DES.php');
++ require_once 'Crypt/DES.php';
+ }
/**
- * Encrypt / decrypt using inner chaining
---- php-seclib-0.2.1/Crypt/AES.php~ 2010-02-09 01:10:26.000000000 +0200
-+++ php-seclib-0.2.1/Crypt/AES.php 2010-08-31 09:56:04.703391530 +0300
-@@ -63,7 +63,7 @@
- /**
+--- php-seclib-0.3.5/Crypt/AES.php~ 2013-07-09 09:59:43.959187088 +0300
++++ php-seclib-0.3.5/Crypt/AES.php 2013-07-09 10:01:25.154248818 +0300
+@@ -66,7 +66,7 @@
* Include Crypt_Rijndael
*/
--require_once 'Rijndael.php';
-+require_once 'Crypt/Rijndael.php';
+ if (!class_exists('Crypt_Rijndael')) {
+- require_once 'Rijndael.php';
++ require_once 'Crypt/Rijndael.php';
+ }
+
+ /**#@+
+--- php-seclib-0.3.5/File/X509.php~ 2013-07-09 10:10:56.128526606 +0300
++++ php-seclib-0.3.5/File/X509.php 2013-07-09 10:18:52.044324034 +0300
+@@ -47,7 +47,7 @@
+ * Include File_ASN1
+ */
+ if (!class_exists('File_ASN1')) {
+- require_once('ASN1.php');
++ require_once('File/ASN1.php');
+ }
+
+ /**
+--- php-seclib-0.3.5/Crypt/RSA.php~ 2013-07-09 10:10:56.118526764 +0300
++++ php-seclib-0.3.5/Crypt/RSA.php 2013-07-09 10:19:47.630110406 +0300
+@@ -76,14 +76,14 @@
+ // call function_exists() a second time to stop the require_once from being called outside
+ // of the auto loader
+ if (!function_exists('crypt_random_string')) {
+- require_once('Random.php');
++ require_once('Crypt/Random.php');
+ }
+
+ /**
+ * Include Crypt_Hash
+ */
+ if (!class_exists('Crypt_Hash')) {
+- require_once('Hash.php');
++ require_once('Crypt/Hash.php');
+ }
+
+ /**#@+
+--- php-seclib-0.3.5/Net/SFTP.php~ 2013-07-09 10:10:56.135193167 +0300
++++ php-seclib-0.3.5/Net/SFTP.php 2013-07-09 10:20:32.236070644 +0300
+@@ -58,7 +58,7 @@
+ * Include Net_SSH2
+ */
+ if (!class_exists('Net_SSH2')) {
+- require_once('SSH2.php');
++ require_once('Net/SSH2.php');
+ }
/**#@+
- * @access public
================================================================
---- gitweb:
http://git.pld-linux.org/gitweb.cgi/packages/php-seclib.git/commitdiff/ca17a2a5a504e92cfd639e684a3002954bf9a3fb
More information about the pld-cvs-commit
mailing list