summaryrefslogtreecommitdiffstats
path: root/perl/perl-Coro
diff options
context:
space:
mode:
Diffstat (limited to 'perl/perl-Coro')
-rw-r--r--perl/perl-Coro/README28
-rw-r--r--perl/perl-Coro/perl-Coro.SlackBuild23
-rw-r--r--perl/perl-Coro/perl-Coro.info8
3 files changed, 35 insertions, 24 deletions
diff --git a/perl/perl-Coro/README b/perl/perl-Coro/README
index 829b494763..22b7805e1e 100644
--- a/perl/perl-Coro/README
+++ b/perl/perl-Coro/README
@@ -1,29 +1,29 @@
-This module collection manages continuations in general, most often in
+This module collection manages continuations in general, most often in
the form of cooperative threads (also called coros, or simply "coro" in
the documentation). They are similar to kernel threads but don't (in
general) run in parallel at the same time even on SMP machines. The
specific flavor of thread offered by this module also guarantees you
that it will not switch between threads unless necessary, at
easily-identified points in your program, so locking and parallel access
-are rarely an issue, making thread programming much safer and easier than
-using other thread models.
+are rarely an issue, making thread programming much safer and easier
+than using other thread models.
Unlike the so-called "Perl threads" (which are not actually real threads
-but only the windows process emulation (see section of same name for more
-details) ported to UNIX, and as such act as processes), Coro provides a
-full shared address space, which makes communication between threads very
-easy. And coro threads are fast, too: disabling the Windows process
-emulation code in your perl and using Coro can easily result in a two to
-four times speed increase for your programs. A parallel matrix
+but only the windows process emulation (see section of same name for
+more details) ported to UNIX, and as such act as processes), Coro
+provides a full shared address space, which makes communication between
+threads very easy. And coro threads are fast, too: disabling the Windows
+process emulation code in your perl and using Coro can easily result in
+a two to four times speed increase for your programs. A parallel matrix
multiplication benchmark (very communication-intensive) runs over 300
times faster on a single core than perls pseudo-threads on a quad core
using all four cores.
-Coro achieves that by supporting multiple running interpreters that share
-data, which is especially useful to code pseudo-parallel processes and for
-event-based programming, such as multiple HTTP-GET requests running
-concurrently. See Coro::AnyEvent to learn more on how to integrate Coro
-into an event-based environment.
+Coro achieves that by supporting multiple running interpreters that
+share data, which is especially useful to code pseudo-parallel processes
+and for event-based programming, such as multiple HTTP-GET requests
+running concurrently. See Coro::AnyEvent to learn more on how to
+integrate Coro into an event-based environment.
In this module, a thread is defined as "callchain + lexical variables +
some package variables + C stack), that is, a thread has its own
diff --git a/perl/perl-Coro/perl-Coro.SlackBuild b/perl/perl-Coro/perl-Coro.SlackBuild
index f514741909..6a5cb26ac2 100644
--- a/perl/perl-Coro/perl-Coro.SlackBuild
+++ b/perl/perl-Coro/perl-Coro.SlackBuild
@@ -1,4 +1,4 @@
-#!/bin/sh
+#!/bin/bash
# Slackware build script for perl-Coro
@@ -22,10 +22,13 @@
# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+cd $(dirname $0) ; CWD=$(pwd)
+
PRGNAM=perl-Coro
-VERSION=${VERSION:-6.54}
-BUILD=${BUILD:-1}
+VERSION=${VERSION:-6.57}
+BUILD=${BUILD:-2}
TAG=${TAG:-_SBo}
+PKGTYPE=${PKGTYPE:-tgz}
SRCNAM="$(printf $PRGNAM | cut -d- -f2-)"
@@ -37,7 +40,14 @@ if [ -z "$ARCH" ]; then
esac
fi
-CWD=$(pwd)
+# If the variable PRINT_PACKAGE_NAME is set, then this script will report what
+# the name of the created package would be, and then exit. This information
+# could be useful to other scripts.
+if [ ! -z "${PRINT_PACKAGE_NAME}" ]; then
+ echo "$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE"
+ exit 0
+fi
+
TMP=${TMP:-/tmp/SBo}
PKG=$TMP/package-$PRGNAM
OUTPUT=${OUTPUT:-/tmp}
@@ -78,14 +88,15 @@ perl Makefile.PL \
INSTALLDIRS=vendor \
INSTALLVENDORMAN1DIR=/usr/man/man1 \
INSTALLVENDORMAN3DIR=/usr/man/man3
+
make
make test
make install DESTDIR=$PKG
find $PKG -name perllocal.pod -o -name ".packlist" -o -name "*.bs" | xargs rm -f || true
-
find $PKG -depth -type d -empty -delete || true
+find $PKG/usr/man -type f -exec gzip -9 {} \+
mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION
cp -a Changes COPYING README $PKG/usr/doc/$PRGNAM-$VERSION
cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild
@@ -94,4 +105,4 @@ mkdir -p $PKG/install
cat $CWD/slack-desc > $PKG/install/slack-desc
cd $PKG
-/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.${PKGTYPE:-tgz}
+/sbin/makepkg -l y -c n $OUTPUT/$PRGNAM-$VERSION-$ARCH-$BUILD$TAG.$PKGTYPE
diff --git a/perl/perl-Coro/perl-Coro.info b/perl/perl-Coro/perl-Coro.info
index 95fd559863..36d93832a0 100644
--- a/perl/perl-Coro/perl-Coro.info
+++ b/perl/perl-Coro/perl-Coro.info
@@ -1,10 +1,10 @@
PRGNAM="perl-Coro"
-VERSION="6.54"
+VERSION="6.57"
HOMEPAGE="https://metacpan.org/pod/Coro"
-DOWNLOAD="https://cpan.metacpan.org/authors/id/M/ML/MLEHMANN/Coro-6.54.tar.gz"
-MD5SUM="aaf5ca766a7323feaab7c9aea77e6ea8"
+DOWNLOAD="https://cpan.metacpan.org/authors/id/M/ML/MLEHMANN/Coro-6.57.tar.gz"
+MD5SUM="fa5970a2a2f3df9d68d4369c7dde1a55"
DOWNLOAD_x86_64=""
MD5SUM_x86_64=""
-REQUIRES="perl-EV perl-AnyEvent perl-common-sense perl-Guard perl-event"
+REQUIRES="perl-EV perl-AnyEvent perl-Guard perl-event"
MAINTAINER="Sergei Fedosoff"
EMAIL="eleksir@gmail.com"