From 19f0a2f760e634ce7b7d2d7d3e8a0493b572432e Mon Sep 17 00:00:00 2001 From: Jeff Parent Date: Sat, 26 Sep 2020 07:20:45 +0100 Subject: libraries/tcl-promise: Added (A promise/future lib for tcl) Signed-off-by: Dave Woodfall Signed-off-by: Willy Sudiarto Raharjo --- libraries/tcl-promise/README | 2 + libraries/tcl-promise/dst-installer.patch | 12 ++++++ libraries/tcl-promise/slack-desc | 19 +++++++++ libraries/tcl-promise/tcl-promise.SlackBuild | 58 ++++++++++++++++++++++++++++ libraries/tcl-promise/tcl-promise.info | 10 +++++ 5 files changed, 101 insertions(+) create mode 100644 libraries/tcl-promise/README create mode 100644 libraries/tcl-promise/dst-installer.patch create mode 100644 libraries/tcl-promise/slack-desc create mode 100644 libraries/tcl-promise/tcl-promise.SlackBuild create mode 100644 libraries/tcl-promise/tcl-promise.info diff --git a/libraries/tcl-promise/README b/libraries/tcl-promise/README new file mode 100644 index 0000000000..9f2d5439be --- /dev/null +++ b/libraries/tcl-promise/README @@ -0,0 +1,2 @@ +tcl-promise implements the 'promise' abstraction for asynchronous +programming. diff --git a/libraries/tcl-promise/dst-installer.patch b/libraries/tcl-promise/dst-installer.patch new file mode 100644 index 0000000000..293f59d268 --- /dev/null +++ b/libraries/tcl-promise/dst-installer.patch @@ -0,0 +1,12 @@ +--- promise-1.1.0.tm.orig 2020-07-27 12:00:27.771781329 -0500 ++++ promise-1.1.0.tm 2020-07-27 12:03:12.543787263 -0500 +@@ -1281,7 +1281,8 @@ + } + } + install { +- set dir [file join [tcl::pkgconfig get libdir,runtime] tcl8 8.6] ++ set dir [string cat [lindex $::argv 1] [file join [tcl::pkgconfig get libdir,runtime] tcl8 8.6]] ++ file mkdir $dir + if {[file extension $filename] eq ".tm"} { + # We already are a .tm with version number + set target $filename diff --git a/libraries/tcl-promise/slack-desc b/libraries/tcl-promise/slack-desc new file mode 100644 index 0000000000..b9ce42cbc3 --- /dev/null +++ b/libraries/tcl-promise/slack-desc @@ -0,0 +1,19 @@ +# HOW TO EDIT THIS FILE: +# The "handy ruler" below makes it easier to edit a package description. +# Line up the first '|' above the ':' following the base package name, and +# the '|' on the right side marks the last column you can put a character in. +# You must make exactly 11 lines for the formatting to be correct. It's also +# customary to leave one space after the ':' except on otherwise blank lines. + + |-----handy-ruler------------------------------------------------------| +tcl-promise: tcl-promise (A promise/future lib for tcl) +tcl-promise: +tcl-promise: This package implements the 'promise' abstraction for asynchronous +tcl-promise: programming. +tcl-promise: +tcl-promise: https://tcl-promise.magicsplat.com/ +tcl-promise: +tcl-promise: +tcl-promise: +tcl-promise: +tcl-promise: diff --git a/libraries/tcl-promise/tcl-promise.SlackBuild b/libraries/tcl-promise/tcl-promise.SlackBuild new file mode 100644 index 0000000000..5b43693fe6 --- /dev/null +++ b/libraries/tcl-promise/tcl-promise.SlackBuild @@ -0,0 +1,58 @@ +#!/bin/sh + +# Slackware build script for promise + +# Copyright 2020 Jeff Parent +# All rights reserved. +# +# Redistribution and use of this script, with or without modification, is +# permitted provided that the following conditions are met: +# +# 1. Redistributions of this script must retain the above copyright +# notice, this list of conditions and the following disclaimer. +# +# THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR IMPLIED +# WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF +# MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO +# EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, +# SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, +# PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; +# OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, +# WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR +# OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF +# ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. + +PRGNAM=tcl-promise +VERSION=${VERSION:-1.1.0} +BUILD=${BUILD:-1} +TAG=${TAG:-_SBo} + +if [ -z "$ARCH" ]; then + case "$( uname -m )" in + i?86) ARCH=i586 ;; + arm*) ARCH=arm ;; + *) ARCH=$( uname -m ) ;; + esac +fi + +CWD=$(pwd) +TMP=${TMP:-/tmp/SBo} +PKG=$TMP/package-$PRGNAM +OUTPUT=${OUTPUT:-/tmp} + +rm -rf $PKG +mkdir -p $TMP $PKG $OUTPUT +cd $TMP +cp $CWD/promise-${VERSION}.tm . +patch < $CWD/dst-installer.patch + +tclsh ./promise-${VERSION}.tm install "${PKG}" + +mkdir -p $PKG/usr/doc/$PRGNAM-$VERSION +cat $CWD/$PRGNAM.SlackBuild > $PKG/usr/doc/$PRGNAM-$VERSION/$PRGNAM.SlackBuild + +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} diff --git a/libraries/tcl-promise/tcl-promise.info b/libraries/tcl-promise/tcl-promise.info new file mode 100644 index 0000000000..afa3b5be6e --- /dev/null +++ b/libraries/tcl-promise/tcl-promise.info @@ -0,0 +1,10 @@ +PRGNAM="tcl-promise" +VERSION="1.1.0" +HOMEPAGE="http://www.magicsplat.com/blog/tags/promises/" +DOWNLOAD="https://master.dl.sourceforge.net/project/tcl-promise/promise-1.1.0.tm" +MD5SUM="c8c10f855bdc8a935246f29ab238cd9f" +DOWNLOAD_x86_64="" +MD5SUM_x86_64="" +REQUIRES="" +MAINTAINER="Jeff Parent" +EMAIL="jeff+SBo@sh0.xyz" -- cgit v1.2.3