spamprobe: remove broken image support, use patches from fedora
This commit is contained in:
parent
f123a298e8
commit
e81cc1a857
@ -1,7 +1,7 @@
|
|||||||
untrusted comment: verify with /etc/ports/opt.pub
|
untrusted comment: verify with /etc/ports/opt.pub
|
||||||
RWSE3ohX2g5d/diyfDE4iAu/cJd2gSinXsOZwzOsDOdrRaMDtbcJzlC2enrtNIsIqPwvnBF9yq1bddogBeNvXh6ghaWrsfMfgQ8=
|
RWSE3ohX2g5d/bYjm8F0RSPN7PGoGTKugpE87la/IzWBNhUu9UjjOD/RsQfJxJS+sv7eJynk6m/Ky2smt5bR8nfY93hAzrt69ws=
|
||||||
SHA256 (Pkgfile) = e09148b5d36c4c65e54d593a2b4c9134fe29fdaa8a26a49fdca6ef1a38b56c06
|
SHA256 (Pkgfile) = 00dfa7f30ce5a61fdb79478d5c587873793509c8a97fcdf83f33f852e3e0dc5a
|
||||||
SHA256 (.footprint) = 18a8e9a9a4743437d61b5a7cf02bfd38a3337a240229441d169b9d8e4c253add
|
SHA256 (.footprint) = 18a8e9a9a4743437d61b5a7cf02bfd38a3337a240229441d169b9d8e4c253add
|
||||||
SHA256 (spamprobe-1.4d.tar.gz) = 217ce47dcc6f58d8201fbb0a5e2dc38b5b06349fadb1378fb3647ad8a3f44d68
|
SHA256 (spamprobe-1.4d.tar.gz) = 217ce47dcc6f58d8201fbb0a5e2dc38b5b06349fadb1378fb3647ad8a3f44d68
|
||||||
SHA256 (spamprobe-1.4d-14.patch) = c3a085f05da2504a0681c2bea5e07900239da4d74de218a7ee94dd46a8d4ee24
|
SHA256 (64bit.patch) = 86af19e88f769d4c35d2e0941d1e7c1670e77d3a6b0012902737529ff5bd14d9
|
||||||
SHA256 (spamprobe-1.4d-giflib5.patch) = af1a610bee4f4d4ad68267b88278d837ecde271e371342497f1b048e528d7d36
|
SHA256 (compile-fixes.patch) = 9c7452e24e257d17bd1f55468b08bbae55c64c70c4e8ac3051fed926343ccf86
|
||||||
|
39
spamprobe/64bit.patch
Normal file
39
spamprobe/64bit.patch
Normal file
@ -0,0 +1,39 @@
|
|||||||
|
diff -up spamprobe-1.4d/src/database/WordArray.h.64bit spamprobe-1.4d/src/database/WordArray.h
|
||||||
|
--- spamprobe-1.4d/src/database/WordArray.h.64bit 2006-11-16 23:24:48.000000000 -0800
|
||||||
|
+++ spamprobe-1.4d/src/database/WordArray.h 2012-08-13 12:45:31.000000000 -0700
|
||||||
|
@@ -31,6 +31,8 @@
|
||||||
|
#ifndef _WordArray_h
|
||||||
|
#define _WordArray_h
|
||||||
|
|
||||||
|
+#include <stdint.h>
|
||||||
|
+
|
||||||
|
class WordData;
|
||||||
|
|
||||||
|
class WordArray
|
||||||
|
@@ -47,7 +49,7 @@ public:
|
||||||
|
FLAGS_SIZE = 2,
|
||||||
|
};
|
||||||
|
|
||||||
|
- typedef unsigned long key_t;
|
||||||
|
+ typedef uint32_t key_t;
|
||||||
|
|
||||||
|
void reset(char *buffer,
|
||||||
|
int num_words);
|
||||||
|
diff -up spamprobe-1.4d/src/includes/hash.h.64bit spamprobe-1.4d/src/includes/hash.h
|
||||||
|
--- spamprobe-1.4d/src/includes/hash.h.64bit 2006-11-16 23:14:30.000000000 -0800
|
||||||
|
+++ spamprobe-1.4d/src/includes/hash.h 2012-08-13 12:45:31.000000000 -0700
|
||||||
|
@@ -10,11 +10,13 @@
|
||||||
|
#ifndef _jenkinshash_h
|
||||||
|
#define _jenkinshash_h
|
||||||
|
|
||||||
|
+#include <stdint.h>
|
||||||
|
+
|
||||||
|
#ifdef __cplusplus
|
||||||
|
extern "C" {
|
||||||
|
#endif
|
||||||
|
|
||||||
|
-typedef unsigned long int ub4; /* unsigned 4-byte quantities */
|
||||||
|
+typedef uint32_t ub4; /* unsigned 4-byte quantities */
|
||||||
|
typedef unsigned char ub1; /* unsigned 1-byte quantities */
|
||||||
|
|
||||||
|
#define hashsize(n) ((ub4)1<<(n))
|
@ -5,20 +5,21 @@
|
|||||||
|
|
||||||
name=spamprobe
|
name=spamprobe
|
||||||
version=1.4d
|
version=1.4d
|
||||||
release=7
|
release=8
|
||||||
source=(http://downloads.sourceforge.net/project/$name/$name/$version/$name-$version.tar.gz
|
source=(http://downloads.sourceforge.net/project/$name/$name/$version/$name-$version.tar.gz
|
||||||
$name-$version-14.patch
|
64bit.patch compile-fixes.patch)
|
||||||
$name-$version-giflib5.patch)
|
|
||||||
|
|
||||||
build () {
|
build () {
|
||||||
cd $SRC/$name-$version
|
cd $SRC/$name-$version
|
||||||
|
|
||||||
patch -p1 -i $SRC/$name-$version-14.patch
|
# https://src.fedoraproject.org/rpms/spamprobe/tree/master
|
||||||
patch -p0 -i $SRC/$name-$version-giflib5.patch
|
patch -p1 -i $SRC/64bit.patch
|
||||||
|
patch -p1 -i $SRC/compile-fixes.patch
|
||||||
|
|
||||||
./configure --prefix=/usr \
|
./configure --prefix=/usr \
|
||||||
--mandir=/usr/share/man \
|
--mandir=/usr/share/man \
|
||||||
--enable-default-8-bit
|
--enable-default-8-bit \
|
||||||
|
--without-{gif,jpeg,png}
|
||||||
|
|
||||||
make
|
make
|
||||||
make DESTDIR=$PKG install
|
make DESTDIR=$PKG install
|
||||||
|
59
spamprobe/compile-fixes.patch
Normal file
59
spamprobe/compile-fixes.patch
Normal file
@ -0,0 +1,59 @@
|
|||||||
|
diff -up spamprobe-1.4d/src/database/HashDataFile.h.compile-fixes spamprobe-1.4d/src/database/HashDataFile.h
|
||||||
|
--- spamprobe-1.4d/src/database/HashDataFile.h.compile-fixes 2006-11-16 23:24:48.000000000 -0800
|
||||||
|
+++ spamprobe-1.4d/src/database/HashDataFile.h 2012-08-13 01:12:35.000000000 -0700
|
||||||
|
@@ -93,7 +93,7 @@ public:
|
||||||
|
|
||||||
|
bool isReadOnly() const
|
||||||
|
{
|
||||||
|
- m_isReadOnly;
|
||||||
|
+ return m_isReadOnly;
|
||||||
|
}
|
||||||
|
|
||||||
|
int createMode() const
|
||||||
|
diff -up spamprobe-1.4d/src/includes/MultiLineSubString.h.compile-fixes spamprobe-1.4d/src/includes/MultiLineSubString.h
|
||||||
|
--- spamprobe-1.4d/src/includes/MultiLineSubString.h.compile-fixes 2006-11-16 23:24:48.000000000 -0800
|
||||||
|
+++ spamprobe-1.4d/src/includes/MultiLineSubString.h 2012-08-13 01:12:35.000000000 -0700
|
||||||
|
@@ -31,6 +31,7 @@
|
||||||
|
#ifndef _MultiLineSubString_h
|
||||||
|
#define _MultiLineSubString_h
|
||||||
|
|
||||||
|
+#include <limits.h>
|
||||||
|
#include "AbstractMultiLineString.h"
|
||||||
|
|
||||||
|
class MultiLineSubString : public AbstractMultiLineString
|
||||||
|
diff -up spamprobe-1.4d/src/includes/Ref.h.compile-fixes spamprobe-1.4d/src/includes/Ref.h
|
||||||
|
--- spamprobe-1.4d/src/includes/Ref.h.compile-fixes 2006-11-16 23:24:48.000000000 -0800
|
||||||
|
+++ spamprobe-1.4d/src/includes/Ref.h 2012-08-13 01:19:29.000000000 -0700
|
||||||
|
@@ -189,7 +189,7 @@ public:
|
||||||
|
|
||||||
|
CRef<T> &operator=(const CRef<T> &other)
|
||||||
|
{
|
||||||
|
- assign(other);
|
||||||
|
+ this->assign(other);
|
||||||
|
return *this;
|
||||||
|
}
|
||||||
|
|
||||||
|
@@ -245,7 +245,7 @@ public:
|
||||||
|
|
||||||
|
Ref<T> &operator=(const Ref<T> &other)
|
||||||
|
{
|
||||||
|
- assign(other);
|
||||||
|
+ this->assign(other);
|
||||||
|
return *this;
|
||||||
|
}
|
||||||
|
|
||||||
|
diff -up spamprobe-1.4d/src/includes/util.h.compile-fixes spamprobe-1.4d/src/includes/util.h
|
||||||
|
--- spamprobe-1.4d/src/includes/util.h.compile-fixes 2006-11-16 23:24:49.000000000 -0800
|
||||||
|
+++ spamprobe-1.4d/src/includes/util.h 2012-08-13 01:12:35.000000000 -0700
|
||||||
|
@@ -35,9 +35,10 @@
|
||||||
|
#include <unistd.h>
|
||||||
|
#endif
|
||||||
|
|
||||||
|
+#include <stdlib.h>
|
||||||
|
+#include <string.h>
|
||||||
|
#include <cmath>
|
||||||
|
#include <memory>
|
||||||
|
-#include <string>
|
||||||
|
#include <cctype>
|
||||||
|
#include <cassert>
|
||||||
|
#include <iostream>
|
@ -1,238 +0,0 @@
|
|||||||
# Extracted from http://ftp.de.debian.org/debian/pool/main/s/spamprobe/spamprobe_1.4d-14.diff.gz
|
|
||||||
|
|
||||||
Description: missing cassert includes
|
|
||||||
Author: Martin Michlmayr <tbm@cyrius.com>
|
|
||||||
Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=357478
|
|
||||||
--- spamprobe-1.4d.orig/src/includes/Buffer.h
|
|
||||||
+++ spamprobe-1.4d/src/includes/Buffer.h
|
|
||||||
@@ -32,6 +32,7 @@
|
|
||||||
#define _Buffer_h
|
|
||||||
|
|
||||||
#include "Array.h"
|
|
||||||
+#include <cassert>
|
|
||||||
|
|
||||||
//
|
|
||||||
// Similar to Array but handles variable length.
|
|
||||||
Description: Hash target doesn't work
|
|
||||||
Author: Francis Russell <francis+dbts@unchartedbackwaters.co.uk>
|
|
||||||
Bug: http://sourceforge.net/tracker/?func=detail&aid=2998863&group_id=61201&atid=496457
|
|
||||||
Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=564643
|
|
||||||
--- spamprobe-1.4d.orig/src/includes/hash.h
|
|
||||||
+++ spamprobe-1.4d/src/includes/hash.h
|
|
||||||
@@ -10,11 +10,13 @@
|
|
||||||
#ifndef _jenkinshash_h
|
|
||||||
#define _jenkinshash_h
|
|
||||||
|
|
||||||
+#include <stdint.h>
|
|
||||||
+
|
|
||||||
#ifdef __cplusplus
|
|
||||||
extern "C" {
|
|
||||||
#endif
|
|
||||||
|
|
||||||
-typedef unsigned long int ub4; /* unsigned 4-byte quantities */
|
|
||||||
+typedef uint32_t ub4; /* unsigned 4-byte quantities */
|
|
||||||
typedef unsigned char ub1; /* unsigned 1-byte quantities */
|
|
||||||
|
|
||||||
#define hashsize(n) ((ub4)1<<(n))
|
|
||||||
--- spamprobe-1.4d.orig/src/database/WordArray.h
|
|
||||||
+++ spamprobe-1.4d/src/database/WordArray.h
|
|
||||||
@@ -31,6 +31,8 @@
|
|
||||||
#ifndef _WordArray_h
|
|
||||||
#define _WordArray_h
|
|
||||||
|
|
||||||
+#include <stdint.h>
|
|
||||||
+
|
|
||||||
class WordData;
|
|
||||||
|
|
||||||
class WordArray
|
|
||||||
@@ -47,7 +49,7 @@ public:
|
|
||||||
FLAGS_SIZE = 2,
|
|
||||||
};
|
|
||||||
|
|
||||||
- typedef unsigned long key_t;
|
|
||||||
+ typedef uint32_t key_t;
|
|
||||||
|
|
||||||
void reset(char *buffer,
|
|
||||||
int num_words);
|
|
||||||
Description: include cstdlib, climits and cstring
|
|
||||||
--- spamprobe-1.4d.orig/src/parser/AutoTrainMailMessageReader.cc
|
|
||||||
+++ spamprobe-1.4d/src/parser/AutoTrainMailMessageReader.cc
|
|
||||||
@@ -28,6 +28,7 @@
|
|
||||||
// http://www.cooldevtools.com/qpl.html
|
|
||||||
//
|
|
||||||
|
|
||||||
+#include <cstdlib>
|
|
||||||
#include "MailMessage.h"
|
|
||||||
#include "AutoTrainMailMessageReader.h"
|
|
||||||
|
|
||||||
--- spamprobe-1.4d.orig/src/spamprobe/Command_cleanup.cc
|
|
||||||
+++ spamprobe-1.4d/src/spamprobe/Command_cleanup.cc
|
|
||||||
@@ -28,6 +28,7 @@
|
|
||||||
// http://www.cooldevtools.com/qpl.html
|
|
||||||
//
|
|
||||||
|
|
||||||
+#include <cstdlib>
|
|
||||||
#include "CleanupManager.h"
|
|
||||||
#include "SpamFilter.h"
|
|
||||||
#include "FrequencyDB.h"
|
|
||||||
--- spamprobe-1.4d.orig/src/spamprobe/Command_edit_term.cc
|
|
||||||
+++ spamprobe-1.4d/src/spamprobe/Command_edit_term.cc
|
|
||||||
@@ -28,6 +28,7 @@
|
|
||||||
// http://www.cooldevtools.com/qpl.html
|
|
||||||
//
|
|
||||||
|
|
||||||
+#include <cstdlib>
|
|
||||||
#include "SpamFilter.h"
|
|
||||||
#include "FrequencyDB.h"
|
|
||||||
#include "CommandConfig.h"
|
|
||||||
--- spamprobe-1.4d.orig/src/spamprobe/Command_exec.cc
|
|
||||||
+++ spamprobe-1.4d/src/spamprobe/Command_exec.cc
|
|
||||||
@@ -28,6 +28,7 @@
|
|
||||||
// http://www.cooldevtools.com/qpl.html
|
|
||||||
//
|
|
||||||
|
|
||||||
+#include <cstdlib>
|
|
||||||
#include "SpamFilter.h"
|
|
||||||
#include "CommandConfig.h"
|
|
||||||
#include "ConfigManager.h"
|
|
||||||
--- spamprobe-1.4d.orig/src/spamprobe/Command_import.cc
|
|
||||||
+++ spamprobe-1.4d/src/spamprobe/Command_import.cc
|
|
||||||
@@ -28,6 +28,7 @@
|
|
||||||
// http://www.cooldevtools.com/qpl.html
|
|
||||||
//
|
|
||||||
|
|
||||||
+#include <cstdlib>
|
|
||||||
#include <fstream>
|
|
||||||
#include "LineReader.h"
|
|
||||||
#include "IstreamCharReader.h"
|
|
||||||
--- spamprobe-1.4d.orig/src/spamprobe/Command_purge.cc
|
|
||||||
+++ spamprobe-1.4d/src/spamprobe/Command_purge.cc
|
|
||||||
@@ -28,6 +28,7 @@
|
|
||||||
// http://www.cooldevtools.com/qpl.html
|
|
||||||
//
|
|
||||||
|
|
||||||
+#include <cstdlib>
|
|
||||||
#include "CleanupManager.h"
|
|
||||||
#include "SpamFilter.h"
|
|
||||||
#include "FrequencyDB.h"
|
|
||||||
--- spamprobe-1.4d.orig/src/database/DatabaseConfig.cc
|
|
||||||
+++ spamprobe-1.4d/src/database/DatabaseConfig.cc
|
|
||||||
@@ -29,6 +29,7 @@
|
|
||||||
//
|
|
||||||
|
|
||||||
#include <stdexcept>
|
|
||||||
+#include <cstdlib>
|
|
||||||
#include "File.h"
|
|
||||||
#include "WordData.h"
|
|
||||||
#include "FrequencyDBImpl.h"
|
|
||||||
--- spamprobe-1.4d.orig/src/hdl/HdlTokenizer.cc
|
|
||||||
+++ spamprobe-1.4d/src/hdl/HdlTokenizer.cc
|
|
||||||
@@ -28,6 +28,7 @@
|
|
||||||
// http://www.cooldevtools.com/qpl.html
|
|
||||||
//
|
|
||||||
|
|
||||||
+#include <cstdlib>
|
|
||||||
#include "AbstractCharReader.h"
|
|
||||||
#include "HdlError.h"
|
|
||||||
#include "HdlToken.h"
|
|
||||||
--- spamprobe-1.4d.orig/src/parser/HtmlTokenizer.cc
|
|
||||||
+++ spamprobe-1.4d/src/parser/HtmlTokenizer.cc
|
|
||||||
@@ -28,6 +28,7 @@
|
|
||||||
// http://www.cooldevtools.com/qpl.html
|
|
||||||
//
|
|
||||||
|
|
||||||
+#include <cstdlib>
|
|
||||||
#include "AbstractTokenReceiver.h"
|
|
||||||
#include "StringReader.h"
|
|
||||||
#include "RegularExpression.h"
|
|
||||||
--- spamprobe-1.4d.orig/src/parser/MailMessageReader.cc
|
|
||||||
+++ spamprobe-1.4d/src/parser/MailMessageReader.cc
|
|
||||||
@@ -28,6 +28,7 @@
|
|
||||||
// http://www.cooldevtools.com/qpl.html
|
|
||||||
//
|
|
||||||
|
|
||||||
+#include <cstdlib>
|
|
||||||
#include "RegularExpression.h"
|
|
||||||
#include "MailMessage.h"
|
|
||||||
#include "MailMessageList.h"
|
|
||||||
--- spamprobe-1.4d.orig/src/parser/MbxMailMessageReader.cc
|
|
||||||
+++ spamprobe-1.4d/src/parser/MbxMailMessageReader.cc
|
|
||||||
@@ -28,6 +28,7 @@
|
|
||||||
// http://www.cooldevtools.com/qpl.html
|
|
||||||
//
|
|
||||||
|
|
||||||
+#include <cstdlib>
|
|
||||||
#include <stdexcept>
|
|
||||||
#include "MailMessage.h"
|
|
||||||
#include "MailMessageList.h"
|
|
||||||
--- spamprobe-1.4d.orig/src/includes/MultiLineSubString.h
|
|
||||||
+++ spamprobe-1.4d/src/includes/MultiLineSubString.h
|
|
||||||
@@ -31,6 +31,7 @@
|
|
||||||
#ifndef _MultiLineSubString_h
|
|
||||||
#define _MultiLineSubString_h
|
|
||||||
|
|
||||||
+#include <climits>
|
|
||||||
#include "AbstractMultiLineString.h"
|
|
||||||
|
|
||||||
class MultiLineSubString : public AbstractMultiLineString
|
|
||||||
--- spamprobe-1.4d.orig/src/spamprobe/spamprobe.cc
|
|
||||||
+++ spamprobe-1.4d/src/spamprobe/spamprobe.cc
|
|
||||||
@@ -28,6 +28,7 @@
|
|
||||||
// http://www.cooldevtools.com/qpl.html
|
|
||||||
//
|
|
||||||
|
|
||||||
+#include <cstdlib>
|
|
||||||
#include <unistd.h>
|
|
||||||
#include <locale.h>
|
|
||||||
#include <signal.h>
|
|
||||||
--- spamprobe-1.4d.orig/src/includes/util.h
|
|
||||||
+++ spamprobe-1.4d/src/includes/util.h
|
|
||||||
@@ -42,6 +42,7 @@
|
|
||||||
#include <cassert>
|
|
||||||
#include <iostream>
|
|
||||||
#include <cstdio>
|
|
||||||
+#include <cstring>
|
|
||||||
#include "Ptr.h"
|
|
||||||
#include "Ref.h"
|
|
||||||
|
|
||||||
Description: Build with libpng 1.5
|
|
||||||
Author: Nobuhiro Iwamatsu <iwamatsu@nigauri.org>
|
|
||||||
Bug-Debian: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=641890
|
|
||||||
--- spamprobe-1.4d.orig/src/parser/PngParser.cc
|
|
||||||
+++ spamprobe-1.4d/src/parser/PngParser.cc
|
|
||||||
@@ -37,6 +37,14 @@
|
|
||||||
#include "StringReader.h"
|
|
||||||
#include "PngParser.h"
|
|
||||||
|
|
||||||
+#ifndef int_p_NULL
|
|
||||||
+#define int_p_NULL NULL
|
|
||||||
+#endif
|
|
||||||
+
|
|
||||||
+#ifndef png_infopp_NULL
|
|
||||||
+#define png_infopp_NULL NULL
|
|
||||||
+#endif
|
|
||||||
+
|
|
||||||
PngParser::PngParser(Message *message,
|
|
||||||
AbstractTokenizer *tokenizer,
|
|
||||||
AbstractTokenReceiver *receiver,
|
|
||||||
Description: UNKNOWN
|
|
||||||
--- spamprobe-1.4d.orig/src/includes/Ref.h
|
|
||||||
+++ spamprobe-1.4d/src/includes/Ref.h
|
|
||||||
@@ -189,7 +189,7 @@ public:
|
|
||||||
|
|
||||||
CRef<T> &operator=(const CRef<T> &other)
|
|
||||||
{
|
|
||||||
- assign(other);
|
|
||||||
+ this->assign(other);
|
|
||||||
return *this;
|
|
||||||
}
|
|
||||||
|
|
||||||
@@ -245,7 +245,7 @@ public:
|
|
||||||
|
|
||||||
Ref<T> &operator=(const Ref<T> &other)
|
|
||||||
{
|
|
||||||
- assign(other);
|
|
||||||
+ this->assign(other);
|
|
||||||
return *this;
|
|
||||||
}
|
|
||||||
|
|
@ -1,20 +0,0 @@
|
|||||||
--- src/parser/GifParser.cc 2006-11-17 08:24:49.000000000 +0100
|
|
||||||
+++ src/parser/GifParser.cc 2014-07-31 09:23:19.372474921 +0200
|
|
||||||
@@ -81,7 +81,7 @@
|
|
||||||
GifParser::~GifParser()
|
|
||||||
{
|
|
||||||
if (m_gif) {
|
|
||||||
- DGifCloseFile(m_gif);
|
|
||||||
+ DGifCloseFile(m_gif, NULL);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
@@ -99,7 +99,7 @@
|
|
||||||
void GifParser::openImage()
|
|
||||||
{
|
|
||||||
m_nextByteIndex = 0;
|
|
||||||
- m_gif = DGifOpen(this, readFromBuffer);
|
|
||||||
+ m_gif = DGifOpen(this, readFromBuffer, NULL);
|
|
||||||
if (!m_gif) {
|
|
||||||
throw runtime_error("open gif failed");
|
|
||||||
}
|
|
Loading…
x
Reference in New Issue
Block a user