libmcrypt: add

This commit is contained in:
suvari
2016-02-27 00:17:14 +02:00
parent 107a071f18
commit d9b3b0246c
6 changed files with 181 additions and 0 deletions
+25
View File
@@ -0,0 +1,25 @@
#!/usr/bin/python
# -*- coding: utf-8 -*-
#
# Licensed under the GNU General Public License, version 3.
# See the file http://www.gnu.org/licenses/gpl.txt
from pisi.actionsapi import autotools
from pisi.actionsapi import pisitools
def setup():
autotools.configure()
def build():
autotools.make()
def check():
autotools.make("check")
def install():
autotools.install()
# Empty
pisitools.removeDir("/usr/lib/libmcrypt")
pisitools.dodoc("ChangeLog","COPYING.LIB","KNOWN-BUGS","NEWS","README")
@@ -0,0 +1,35 @@
diff -up libmcrypt-2.5.8/Makefile.in.orig libmcrypt-2.5.8/Makefile.in
--- libmcrypt-2.5.8/Makefile.in.orig 2007-02-19 00:32:38.000000000 -0600
+++ libmcrypt-2.5.8/Makefile.in 2007-07-19 21:23:39.000000000 -0500
@@ -209,8 +209,8 @@ target_os = @target_os@
target_vendor = @target_vendor@
INCLUDES = $(INCLTDL)
EXTRA_DIST = KNOWN-BUGS THANKS NEWS libmcrypt.spec.in libmcrypt.spec COPYING.LIB
-DIST_SUBDIRS = libltdl modules include lib src doc
-SUBDIRS = $(LIBLTDL_DIR) modules include lib src doc
+DIST_SUBDIRS = modules include lib src doc
+SUBDIRS = modules include lib src doc
all: config.h
$(MAKE) $(AM_MAKEFLAGS) all-recursive
diff -up libmcrypt-2.5.8/configure.orig libmcrypt-2.5.8/configure
--- libmcrypt-2.5.8/configure.orig 2007-02-19 00:32:39.000000000 -0600
+++ libmcrypt-2.5.8/configure 2007-07-19 21:21:38.000000000 -0500
@@ -426,7 +426,7 @@ PACKAGE_STRING=
PACKAGE_BUGREPORT=
ac_unique_file="lib/mcrypt.c"
-ac_subdirs_all="$ac_subdirs_all libltdl"
+ac_subdirs_all="$ac_subdirs_all"
# Factoring default headers for most tests.
ac_includes_default="\
#include <stdio.h>
@@ -4425,7 +4425,7 @@ fi
-subdirs="$subdirs libltdl"
+subdirs="$subdirs"
# Check whether --enable-static or --disable-static was given.
if test "${enable_static+set}" = set; then
@@ -0,0 +1,35 @@
diff -up libmcrypt-2.5.8/modules/algorithms/des.c.BAD libmcrypt-2.5.8/modules/algorithms/des.c
--- libmcrypt-2.5.8/modules/algorithms/des.c.BAD 2008-08-25 17:40:29.000000000 -0400
+++ libmcrypt-2.5.8/modules/algorithms/des.c 2008-08-25 17:40:51.000000000 -0400
@@ -35,9 +35,12 @@
/* #define NULL 0 */
-static void permute_ip(), permute_fp(), perminit_ip(), spinit(),
-perminit_fp();
-static word32 f();
+static void permute_ip(char *, DES_KEY *, char *);
+static void permute_fp(char *, DES_KEY *, char *);
+static void perminit_ip(DES_KEY *);
+static void spinit(DES_KEY *);
+static void perminit_fp(DES_KEY *);
+static word32 f(DES_KEY *, register word32, register char *);
/* Tables defined in the Data Encryption Standard documents */
diff -up libmcrypt-2.5.8/modules/algorithms/tripledes.c.BAD libmcrypt-2.5.8/modules/algorithms/tripledes.c
--- libmcrypt-2.5.8/modules/algorithms/tripledes.c.BAD 2008-08-25 17:40:56.000000000 -0400
+++ libmcrypt-2.5.8/modules/algorithms/tripledes.c 2008-08-25 17:41:13.000000000 -0400
@@ -36,8 +36,10 @@
/* #define NULL 0 */
-static void permute(), perminit(), spinit();
-static word32 f();
+static void permute(char *, char[16][16][8], char *);
+static void perminit(char[16][16][8], char[64]);
+static void spinit(TRIPLEDES_KEY *, int);
+static word32 f(TRIPLEDES_KEY *, int, register word32, register char *);
/* Tables defined in the Data Encryption Standard documents */
@@ -0,0 +1,12 @@
diff -up libmcrypt-2.5.8/modules/algorithms/twofish.c.BAD libmcrypt-2.5.8/modules/algorithms/twofish.c
--- libmcrypt-2.5.8/modules/algorithms/twofish.c.BAD 2008-08-25 17:38:21.000000000 -0400
+++ libmcrypt-2.5.8/modules/algorithms/twofish.c 2008-08-25 17:38:30.000000000 -0400
@@ -499,7 +499,7 @@ static void f_rnd(int i, word32* blk, TW
/* encrypt a block of text */
WIN32DLL_DEFINE void _mcrypt_encrypt(TWI * pkey, word32 * in_blk)
{
- word32 t0, t1, blk[4];
+ word32 t0 = 0, t1 = 0, blk[4];
#ifdef WORDS_BIGENDIAN
blk[0] = byteswap32(in_blk[0]) ^ pkey->l_key[0];
blk[1] = byteswap32(in_blk[1]) ^ pkey->l_key[1];
+61
View File
@@ -0,0 +1,61 @@
<?xml version="1.0" ?>
<!DOCTYPE PISI SYSTEM "http://www.pisilinux.org/projeler/pisi/pisi-spec.dtd">
<PISI>
<Source>
<Name>libmcrypt</Name>
<Homepage>http://mcrypt.sourceforge.net/</Homepage>
<Packager>
<Name>PisiLinux Community</Name>
<Email>admins@pisilinux.org</Email>
</Packager>
<License>LGPLv2.1</License>
<IsA>library</IsA>
<Summary>A thread-safe encryption library</Summary>
<Description>libmcrypt is a thread-safe encryption library. It allows developers to use a wide range of encryption functions, without making drastic changes to their code. It allows users to encrypt files or data streams without having to be cryptographers.</Description>
<Archive sha1sum="b4d4d8851db543e6fda80572a54a4901b4e767da" type="tarbz2">mirrors://sourceforge/mcrypt/libmcrypt-2.5.8.tar.bz2</Archive>
<Patches>
<Patch level="1">libmcrypt-2.5.8-nolibltdl.patch</Patch>
<Patch level="1">libmcrypt-2.5.8-prototypes.patch</Patch>
<Patch level="1">libmcrypt-2.5.8-uninitialized.patch</Patch>
</Patches>
</Source>
<Package>
<Name>libmcrypt</Name>
<Files>
<Path fileType="library">/usr/lib</Path>
<Path fileType="doc">/usr/share/doc/libmcrypt</Path>
</Files>
</Package>
<Package>
<Name>libmcrypt-devel</Name>
<Summary>Development files for libmcrypt</Summary>
<RuntimeDependencies>
<Dependency release="current">libmcrypt</Dependency>
</RuntimeDependencies>
<Files>
<Path fileType="executable">/usr/bin</Path>
<Path fileType="header">/usr/include</Path>
<Path fileType="data">/usr/share/aclocal</Path>
<Path fileType="man">/usr/share/man</Path>
</Files>
</Package>
<History>
<Update release="2">
<Date>2014-01-31</Date>
<Version>2.5.8</Version>
<Comment>Rebuild</Comment>
<Name>Stefan Gronewold(groni)</Name>
<Email>groni@pisilinux.org</Email>
</Update>
<Update release="1">
<Date>2010-10-12</Date>
<Version>2.5.8</Version>
<Comment>First release</Comment>
<Name>Pisi Linux Admins</Name>
<Email>admins@pisilinux.org</Email>
</Update>
</History>
</PISI>
+13
View File
@@ -0,0 +1,13 @@
<?xml version="1.0" ?>
<PISI>
<Source>
<Name>libmcrypt</Name>
<Summary xml:lang="tr">Güvenli şifreleme kütüphanesi.</Summary>
<Description xml:lang="tr">libmcrypt bir güvenli şifreleme kütüphanesidir. Geliştiricilere kodlarında çok büyük bir değişikliğe gerek duymadan kullanabilecekleri, geniş bir şifreleme fonksiyon kaynağı sunar. Şifreleme uzmanı olmadan dosya ve verileri kolayca şifrelemenizi sağlar.</Description>
</Source>
<Package>
<Name>libmcrypt-devel</Name>
<Summary xml:lang="tr">libmcrypt için geliştirme dosyaları</Summary>
</Package>
</PISI>