From fd8dee4f1ba014c847e6682d50b2bbdcccb7942f Mon Sep 17 00:00:00 2001 From: Fredrik Fornwall Date: Wed, 31 Aug 2016 11:14:00 -0400 Subject: [PATCH] asciinema: Update from 1.2 to 1.3 --- packages/asciinema/Makefile.patch | 14 -------------- packages/asciinema/build.sh | 21 ++++++++++----------- packages/asciinema/commands-rec.go.patch | 12 ------------ packages/asciinema/util-cfg.go.patch | 12 ------------ packages/asciinema/ztypes_arm64.go.patch | 16 ---------------- 5 files changed, 10 insertions(+), 65 deletions(-) delete mode 100644 packages/asciinema/Makefile.patch delete mode 100644 packages/asciinema/commands-rec.go.patch delete mode 100644 packages/asciinema/util-cfg.go.patch delete mode 100644 packages/asciinema/ztypes_arm64.go.patch diff --git a/packages/asciinema/Makefile.patch b/packages/asciinema/Makefile.patch deleted file mode 100644 index 9c509540b..000000000 --- a/packages/asciinema/Makefile.patch +++ /dev/null @@ -1,14 +0,0 @@ -diff -u -r ../asciinema-1.2.0/Makefile ./Makefile ---- ../asciinema-1.2.0/Makefile 2016-02-22 06:00:31.000000000 -0500 -+++ ./Makefile 2016-03-07 18:42:26.516807994 -0500 -@@ -13,8 +13,8 @@ - - all: build - --build: test -- go build -o bin/asciinema -+build: -+ go build -o bin/asciinema -ldflags "-extldflags=-pie" - - test: - go test ./... diff --git a/packages/asciinema/build.sh b/packages/asciinema/build.sh index 08a1ae43f..0960aa1c1 100644 --- a/packages/asciinema/build.sh +++ b/packages/asciinema/build.sh @@ -1,23 +1,22 @@ TERMUX_PKG_HOMEPAGE=https://asciinema.org/ TERMUX_PKG_DESCRIPTION="Record and share your terminal sessions, the right way" -TERMUX_PKG_VERSION=1.2.0 +TERMUX_PKG_VERSION=1.3.0 +# ncurses-utils for tput which asciinema uses: +TERMUX_PKG_DEPENDS="python, ncurses-utils" TERMUX_PKG_SRCURL=https://github.com/asciinema/asciinema/archive/v${TERMUX_PKG_VERSION}.tar.gz TERMUX_PKG_FOLDERNAME=asciinema-${TERMUX_PKG_VERSION} TERMUX_PKG_BUILD_IN_SRC=yes +TERMUX_PKG_PLATFORM_INDEPENDENT=yes termux_step_make () { - termux_setup_golang - export GOPATH=$TERMUX_PKG_TMPDIR - cd $GOPATH - mkdir -p src/github.com/asciinema/asciinema/ - cp -Rf $TERMUX_PKG_SRCDIR/* src/github.com/asciinema/asciinema/ + return } termux_step_make_install () { - cd $GOPATH/src/github.com/asciinema/asciinema - PREFIX=$TERMUX_PREFIX make build - PREFIX=$TERMUX_PREFIX make install + export PYTHONPATH=$TERMUX_PREFIX/lib/python3.5/site-packages/ + python3.5 setup.py install --prefix=$TERMUX_PREFIX --force +} - mkdir -p $TERMUX_PREFIX/share/man/man1/ - cp $TERMUX_PKG_SRCDIR/man/asciinema.1 $TERMUX_PREFIX/share/man/man1/ +termux_step_post_massage () { + find . -path '*/__pycache__*' -delete } diff --git a/packages/asciinema/commands-rec.go.patch b/packages/asciinema/commands-rec.go.patch deleted file mode 100644 index 8c99a45f7..000000000 --- a/packages/asciinema/commands-rec.go.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -u -r ../asciinema-1.1.1/commands/rec.go ./commands/rec.go ---- ../asciinema-1.1.1/commands/rec.go 2015-06-21 17:58:14.000000000 +0200 -+++ ./commands/rec.go 2015-08-20 01:45:49.000000000 +0200 -@@ -69,7 +69,7 @@ - } - - func tmpPath() (string, error) { -- file, err := ioutil.TempFile("", "asciicast-") -+ file, err := ioutil.TempFile("@TERMUX_PREFIX@/tmp", "asciicast-") - if err != nil { - return "", err - } diff --git a/packages/asciinema/util-cfg.go.patch b/packages/asciinema/util-cfg.go.patch deleted file mode 100644 index 9aaece69e..000000000 --- a/packages/asciinema/util-cfg.go.patch +++ /dev/null @@ -1,12 +0,0 @@ -diff -u -r ../asciinema-1.1.1/util/cfg.go ./util/cfg.go ---- ../asciinema-1.1.1/util/cfg.go 2015-06-21 17:58:14.000000000 +0200 -+++ ./util/cfg.go 2015-08-20 01:47:50.000000000 +0200 -@@ -13,7 +13,7 @@ - - const ( - DefaultAPIURL = "https://asciinema.org" -- DefaultCommand = "/bin/sh" -+ DefaultCommand = "@TERMUX_PREFIX@/bin/bash" - ) - - type ConfigAPI struct { diff --git a/packages/asciinema/ztypes_arm64.go.patch b/packages/asciinema/ztypes_arm64.go.patch deleted file mode 100644 index 08c209673..000000000 --- a/packages/asciinema/ztypes_arm64.go.patch +++ /dev/null @@ -1,16 +0,0 @@ -diff -N -u -r ../asciinema-1.1.1/Godeps/_workspace/src/github.com/kr/pty/ztypes_arm64.go ./Godeps/_workspace/src/github.com/kr/pty/ztypes_arm64.go ---- ../asciinema-1.1.1/Godeps/_workspace/src/github.com/kr/pty/ztypes_arm64.go 1969-12-31 19:00:00.000000000 -0500 -+++ ./Godeps/_workspace/src/github.com/kr/pty/ztypes_arm64.go 2015-12-20 17:45:50.332987015 -0500 -@@ -0,0 +1,12 @@ -+// From upstream pty package - https://github.com/kr/pty/blob/master/ztypes_arm64.go -+// Created by cgo -godefs - DO NOT EDIT -+// cgo -godefs types.go -+ -+// +build arm64 -+ -+package pty -+ -+type ( -+ _C_int int32 -+ _C_uint uint32 -+)