diff options
author | Peter Pentchev <roam@FreeBSD.org> | 2006-04-20 13:08:23 +0000 |
---|---|---|
committer | Peter Pentchev <roam@FreeBSD.org> | 2006-04-20 13:08:23 +0000 |
commit | 49af322fe4bd0eab97a2091cb51eadc9a97b8a1d (patch) | |
tree | 053d1a731c6d03fe8e0df84ac644c6e16a562c13 /www/p5-Net-Akismet | |
parent | d4751730c3a2531ce8b7a8a18ee250eee90abf85 (diff) | |
download | ports-49af322fe4bd0eab97a2091cb51eadc9a97b8a1d.tar.gz ports-49af322fe4bd0eab97a2091cb51eadc9a97b8a1d.zip |
Notes
Diffstat (limited to 'www/p5-Net-Akismet')
-rw-r--r-- | www/p5-Net-Akismet/Makefile | 45 | ||||
-rw-r--r-- | www/p5-Net-Akismet/distinfo | 3 | ||||
-rw-r--r-- | www/p5-Net-Akismet/files/Net-Akismet-coverage.t | 15 | ||||
-rw-r--r-- | www/p5-Net-Akismet/files/Net-Akismet-podcheck.t | 27 | ||||
-rw-r--r-- | www/p5-Net-Akismet/files/patch-lib-Net-Akismet.pm | 38 | ||||
-rw-r--r-- | www/p5-Net-Akismet/pkg-descr | 12 | ||||
-rw-r--r-- | www/p5-Net-Akismet/pkg-plist | 5 |
7 files changed, 145 insertions, 0 deletions
diff --git a/www/p5-Net-Akismet/Makefile b/www/p5-Net-Akismet/Makefile new file mode 100644 index 000000000000..48402fe8b552 --- /dev/null +++ b/www/p5-Net-Akismet/Makefile @@ -0,0 +1,45 @@ +# New ports collection makefile for: p5-Net-Akismet +# Date created: April 20th, 2006 +# Whom: Peter Pentchev <roam@FreeBSD.org> +# +# $FreeBSD$ +# + +PORTNAME= Net-Akismet +PORTVERSION= 0.01 +CATEGORIES= www perl5 +MASTER_SITES= ${MASTER_SITE_PERL_CPAN} +MASTER_SITE_SUBDIR= Net +PKGNAMEPREFIX= p5- + +MAINTAINER= roam@FreeBSD.org +COMMENT= A Perl interface to the Akismet comment and trackback spam blocker + +BUILD_DEPENDS+= ${SITE_PERL}/Bundle/LWP.pm:${PORTSDIR}/www/p5-libwww +RUN_DEPENDS= ${BUILD_DEPENDS} + +.if !defined(WITHOUT_TEST_POD_COVERAGE) +BUILD_DEPENDS+= ${SITE_PERL}/Test/Pod/Coverage.pm:${PORTSDIR}/devel/p5-Test-Pod-Coverage +.endif + +PERL_CONFIGURE= yes + +MAN3= Net::Akismet.3 + +post-patch: + ${CP} ${FILESDIR}/Net-Akismet-podcheck.t \ + ${FILESDIR}/Net-Akismet-coverage.t \ + ${WRKSRC}/t/ + # Grrrr, this really shouldn't be needed! + ${RM} ${WRKSRC}/lib/Net/Akismet.pm.orig + +test: build + @cd ${WRKSRC} && ${SETENV} ${MAKE_ENV} ${MAKE} ${MAKE_FLAGS} ${MAKEFILE} ${MAKE_ARGS} test + +.include <bsd.port.pre.mk> + +.if ${PERL_LEVEL} < 500600 +IGNORE= needs Perl 5.6 or later +.endif + +.include <bsd.port.post.mk> diff --git a/www/p5-Net-Akismet/distinfo b/www/p5-Net-Akismet/distinfo new file mode 100644 index 000000000000..77d31dfd591e --- /dev/null +++ b/www/p5-Net-Akismet/distinfo @@ -0,0 +1,3 @@ +MD5 (Net-Akismet-0.01.tar.gz) = ea0510f5f5fccf913d862ec28c92fe1f +SHA256 (Net-Akismet-0.01.tar.gz) = 76863a80913865750c2804791fbb90f25fcf79f8f6d1d7dd7e60143bab1ca5b0 +SIZE (Net-Akismet-0.01.tar.gz) = 3774 diff --git a/www/p5-Net-Akismet/files/Net-Akismet-coverage.t b/www/p5-Net-Akismet/files/Net-Akismet-coverage.t new file mode 100644 index 000000000000..cfd9d2e16236 --- /dev/null +++ b/www/p5-Net-Akismet/files/Net-Akismet-coverage.t @@ -0,0 +1,15 @@ +# Before `make install' is performed this script should be runnable with +# `make test'. After `make install' it should work as `perl Net-Akismet-coverage.t' + +BEGIN { + eval 'use Test::Pod::Coverage tests => 1'; + if ($@) { + use Test; + plan tests => 1; + skip('Test::Pod::Coverage not found'); + exit(0); + } +} + + +pod_coverage_ok('Net::Akismet'); diff --git a/www/p5-Net-Akismet/files/Net-Akismet-podcheck.t b/www/p5-Net-Akismet/files/Net-Akismet-podcheck.t new file mode 100644 index 000000000000..f49e99c16b3a --- /dev/null +++ b/www/p5-Net-Akismet/files/Net-Akismet-podcheck.t @@ -0,0 +1,27 @@ +# $Id: Net-Akismet-podcheck.t 135 2006-01-27 17:54:46Z roam $ +# Before `make install' is performed this script should be runnable with +# `make test'. After `make install' it should work as `perl Net-Akismet-coverage.t' + +use Pod::Checker; +use Test; +plan tests => 6; + +my ($c, $res); + +$c = new Pod::Checker '-warnings' => 1; +ok($c); +$res = $c->parse_from_file('lib/Net/Akismet.pm', \*STDERR); +if ($res == -1) { + warn "No POD data found in Net::Akismet\n"; +} +ok(!$res); +ok($c->num_errors() == 0 && $c->num_warnings() == 0); + +$c = new Pod::Checker '-warnings' => 5; +ok($c); +$res = $c->parse_from_file('lib/Net/Akismet.pm', \*STDERR); +if ($res == -1) { + warn "No POD data found in Net::Akismet\n"; +} +ok(!$res); +ok($c->num_errors() == 0 && $c->num_warnings() == 0); diff --git a/www/p5-Net-Akismet/files/patch-lib-Net-Akismet.pm b/www/p5-Net-Akismet/files/patch-lib-Net-Akismet.pm new file mode 100644 index 000000000000..6553b3977992 --- /dev/null +++ b/www/p5-Net-Akismet/files/patch-lib-Net-Akismet.pm @@ -0,0 +1,38 @@ +--- lib/Net/Akismet.pm.old Thu Apr 20 15:50:08 2006 ++++ lib/Net/Akismet.pm Thu Apr 20 15:50:49 2006 +@@ -24,7 +24,7 @@ + KEY => 'secret-baba-API-key', + URL => 'http://example.blog.net/', + ) or die('Key verification failure!'); +- ++ + my $verdict = $akismet->check( + USER_IP => '10.10.10.11', + COMMENT_CONTENT => 'Run, Lola, Run, the spam will catch you!', +@@ -37,7 +37,7 @@ + + print "I found spam. I am a spam-founder!\n"; + } +- ++ + =head1 METHODS + + =over 8 +@@ -47,7 +47,7 @@ + Net::Akismet->new(PARAM => ...); + + Acceptable parameters: +- ++ + =over 4 + + =item KEY +@@ -61,7 +61,7 @@ + =item USER_AGENT + + If supplied the value is prepended to this module's identification string to become something like: +- ++ + yourkillerapp/0.042 | Akismet Perl/0.01 + + Otherwise just Akismet Perl's user agent string will be sent. diff --git a/www/p5-Net-Akismet/pkg-descr b/www/p5-Net-Akismet/pkg-descr new file mode 100644 index 000000000000..c0dc06c1ec39 --- /dev/null +++ b/www/p5-Net-Akismet/pkg-descr @@ -0,0 +1,12 @@ +From the README file: + + Net::Akismet is meant to provide perl interface to the Akismet web service. + + Akismet is blog comment and trackback spam blocker, free for personal use. + More info on http://akismet.com/ + + The module allows you to either check if an item is spam or report certain + comment as spam/false postivie. + +Author: Nikolay Bachiyski <nbachiyski@developer.bg> +WWW: http://search.cpan.org/dist/Net-Akismet/ diff --git a/www/p5-Net-Akismet/pkg-plist b/www/p5-Net-Akismet/pkg-plist new file mode 100644 index 000000000000..2aba6b0f1b17 --- /dev/null +++ b/www/p5-Net-Akismet/pkg-plist @@ -0,0 +1,5 @@ +%%SITE_PERL%%/%%PERL_ARCH%%/auto/Net/Akismet/.packlist +@dirrm %%SITE_PERL%%/%%PERL_ARCH%%/auto/Net/Akismet +@dirrmtry %%SITE_PERL%%/%%PERL_ARCH%%/auto/Net +%%SITE_PERL%%/Net/Akismet.pm +@dirrmtry %%SITE_PERL%%/Net |