new package: gluelang

This commit is contained in:
Tee KOBAYASHI 2022-04-03 18:49:09 +09:00 committed by xtkoba
parent 168f0209da
commit 29cbf05867
3 changed files with 35 additions and 0 deletions

View File

@ -0,0 +1,9 @@
TERMUX_PKG_HOMEPAGE=https://ryuichiueda.github.io/GlueLang/
TERMUX_PKG_DESCRIPTION="A programming language that has a strong nature to be a glue of commands"
TERMUX_PKG_LICENSE="MIT"
TERMUX_PKG_MAINTAINER="@termux"
TERMUX_PKG_VERSION=0.2.0
TERMUX_PKG_SRCURL=https://github.com/ryuichiueda/GlueLang/archive/refs/tags/v${TERMUX_PKG_VERSION}.tar.gz
TERMUX_PKG_SHA256=abd46b8b9e0c0082289470b7dc6ffb8125066308a6165e6a92a92ab539ca11c1
TERMUX_PKG_DEPENDS="libc++"
TERMUX_PKG_BUILD_IN_SRC=true

View File

@ -0,0 +1,15 @@
--- a/src/Makefile
+++ b/src/Makefile
@@ -1,8 +1,8 @@
-CXX = g++
+CXX ?= g++
TARGET = glue
-BINDIR = /usr/local/bin
-CXXFLAGS = -Wall -O2 --static -std=c++11
-LDFLAGS = -lm
+BINDIR = @TERMUX_PREFIX@/bin
+CXXFLAGS ?= -Wall -O2 --static -std=c++11
+LDFLAGS ?= -lm
SRCS := $(wildcard *.cc)
OBJS := $(SRCS:.cc=.o)

View File

@ -0,0 +1,11 @@
--- a/src/main.cc
+++ b/src/main.cc
@@ -69,7 +69,7 @@
Feeder feeder(&ifs);
// set tmpdir
string tmp_k = "tmpdir";
- string tmp_v = "/tmp/";
+ string tmp_v = "@TERMUX_PREFIX@/tmp/";
env.setImportPath(&tmp_k,&tmp_v);
Script s(&feeder,&env,NULL);