From nobody Fri Nov 25 09:37:20 2022 X-Original-To: dev-commits-ports-main@mlmmj.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mlmmj.nyi.freebsd.org (Postfix) with ESMTP id 4NJVBm2YgLz4hQK2; Fri, 25 Nov 2022 09:37:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "R3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 4NJVBm1nCWz3PRP; Fri, 25 Nov 2022 09:37:20 +0000 (UTC) (envelope-from git@FreeBSD.org) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1669369040; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=I/w5pW175WzkopBdLimTA0TTR4JECin57hnqZoZlxUE=; b=qmAnoI//6GV/ofk0+7Thw3L5Warg8CSdnjm8dHGxVPKuJW1If6Wx8PlLaHaSUtvHsxPgx5 WTYpBBczk6g6gcht46uKMbfIGSZN+Do1xfTlPslbXptHd5kPJGrU2LpmTPRzuVIchaXw4I NPSSnOh6/JY9JAV++kwUBhPzGFXg1E/doJSY7gQBwT1DEML/yk0QCc4ICrNz5TjWEc4FkA bLloIaPpMDsAf0e5bN7LxBB0MG18tDmJfdJr453Ao9oxVVB8doCjNDXSgHuveW7w4NUkUs +ILpFvqJVS2xUing36KwFc6+8E+yvo8jlMU3bOUhyLcNjFOaaZsCGfH651DmuA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=freebsd.org; s=dkim; t=1669369040; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=I/w5pW175WzkopBdLimTA0TTR4JECin57hnqZoZlxUE=; b=QkxKpwmUIrrtvcj8dzPhQmM4kJ4iH8N04mnxAcYw2qPdTMUFYwtrwPMsPt6vd94UAb3Y7/ DKzCbH7amwrj5OIKwYsaBsdR4y0EeKQFl/snnIIsFqC8Y9Ul8PTjooU8Sm41nRtO/HiUNl RMFXZoSilUJXhls+Ke4bGBcJvdPlGUrgO6ai2lrc/BwPo4nCehBSmeOL9rYvNFkj23XWg1 DRzJjim+nVKe/NRqN1KbtK7ZoRRFPv9Siz3at7cQLubKWb4fohI/LqAaWKHMEPPqejt6Li 2zS099qA0OTFLsqt+QwIflt3A5a8eI8sEt5D+pNFijMaSExKfoTZUnarZ6HRXg== ARC-Authentication-Results: i=1; mx1.freebsd.org; none ARC-Seal: i=1; s=dkim; d=freebsd.org; t=1669369040; a=rsa-sha256; cv=none; b=D+H3pA3ygNX+il917FP4lMokS3ab4PpyEY8fGyf7uFh0MknhxUCuoTT/g+2JuSw3jI+qjG ES/y6gYqZvsFYesAAUH6eX9BJ0K0+DGir4wAd2mdu/HZTA/W8REmyNtWM30ArfsV4bcdOr Dbwi5P80594rSBIdOiQBHGjxbaZQYC5MeI7bVe3U1d8rxxiVIgIYjs7Lkv+74SWGdkw9DH 8pbBVfqdpxjV4UcdUuEsySlf7pdrVhr6jK6a1IqxK4nnZKz1EDQ+2G+SxSTXiI4zRUPKaN fKAZcuwdn7owQ7CxyJkOXDmozpKLgjYJq1K7mi9oZfj8Yhd4v+QQWUhs8NeFQQ== Received: from gitrepo.freebsd.org (gitrepo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:5]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 4NJVBm0nqlzbTB; Fri, 25 Nov 2022 09:37:20 +0000 (UTC) (envelope-from git@FreeBSD.org) Received: from gitrepo.freebsd.org ([127.0.1.44]) by gitrepo.freebsd.org (8.16.1/8.16.1) with ESMTP id 2AP9bKrM087592; Fri, 25 Nov 2022 09:37:20 GMT (envelope-from git@gitrepo.freebsd.org) Received: (from git@localhost) by gitrepo.freebsd.org (8.16.1/8.16.1/Submit) id 2AP9bKkJ087591; Fri, 25 Nov 2022 09:37:20 GMT (envelope-from git) Date: Fri, 25 Nov 2022 09:37:20 GMT Message-Id: <202211250937.2AP9bKkJ087591@gitrepo.freebsd.org> To: ports-committers@FreeBSD.org, dev-commits-ports-all@FreeBSD.org, dev-commits-ports-main@FreeBSD.org From: Yuri Victorovich Subject: git: 66fda47a11b5 - main - lang/colm: New port: Colm Programming Language List-Id: Commits to the main branch of the FreeBSD ports repository List-Archive: https://lists.freebsd.org/archives/dev-commits-ports-main List-Help: List-Post: List-Subscribe: List-Unsubscribe: Sender: owner-dev-commits-ports-main@freebsd.org X-BeenThere: dev-commits-ports-main@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit X-Git-Committer: yuri X-Git-Repository: ports X-Git-Refname: refs/heads/main X-Git-Reftype: branch X-Git-Commit: 66fda47a11b52b6c31b30016dfde8cfdb1f162a3 Auto-Submitted: auto-generated X-ThisMailContainsUnwantedMimeParts: N The branch main has been updated by yuri: URL: https://cgit.FreeBSD.org/ports/commit/?id=66fda47a11b52b6c31b30016dfde8cfdb1f162a3 commit 66fda47a11b52b6c31b30016dfde8cfdb1f162a3 Author: Yuri Victorovich AuthorDate: 2022-11-25 09:18:28 +0000 Commit: Yuri Victorovich CommitDate: 2022-11-25 09:37:16 +0000 lang/colm: New port: Colm Programming Language --- lang/Makefile | 1 + lang/colm/Makefile | 29 ++++++++++ lang/colm/distinfo | 3 + lang/colm/files/patch-src_bytecode.c | 13 +++++ lang/colm/files/patch-src_main.cc | 13 +++++ lang/colm/files/patch-test_runtests | 11 ++++ lang/colm/pkg-descr | 21 +++++++ lang/colm/pkg-plist | 106 +++++++++++++++++++++++++++++++++++ 8 files changed, 197 insertions(+) diff --git a/lang/Makefile b/lang/Makefile index 622dc1c1ac58..f842ce7afcf2 100644 --- a/lang/Makefile +++ b/lang/Makefile @@ -32,6 +32,7 @@ SUBDIR += clover SUBDIR += cocor SUBDIR += coffeescript + SUBDIR += colm SUBDIR += cparser SUBDIR += crystal SUBDIR += csharp-mode.el diff --git a/lang/colm/Makefile b/lang/colm/Makefile new file mode 100644 index 000000000000..6d66453ba76f --- /dev/null +++ b/lang/colm/Makefile @@ -0,0 +1,29 @@ +PORTNAME= colm +DISTVERSION= 0.14.7-43 +DISTVERSIONSUFFIX= -gd00ef793 +CATEGORIES= lang + +MAINTAINER= yuri@FreeBSD.org +COMMENT= Colm Programming Language +WWW= https://github.com/adrian-thurston/colm + +LICENSE= MIT +LICENSE_FILE= ${WRKSRC}/COPYING + +BUILD_DEPENDS= bash:shells/bash +RUN_DEPENDS= bash:shells/bash + +USES= autoreconf gmake libtool shebangfix + +USE_GITHUB= yes +GH_ACCOUNT= adrian-thurston + +SHEBANG_GLOB= *.sh +SHEBANG_FILES= test/runtests + +GNU_CONFIGURE= yes + +INSTALL_TARGET= install-strip +TEST_TARGET= check # 1 tests fails, see https://github.com/adrian-thurston/colm/issues/153 + +.include diff --git a/lang/colm/distinfo b/lang/colm/distinfo new file mode 100644 index 000000000000..2c4f2fd980dd --- /dev/null +++ b/lang/colm/distinfo @@ -0,0 +1,3 @@ +TIMESTAMP = 1669364665 +SHA256 (adrian-thurston-colm-0.14.7-43-gd00ef793_GH0.tar.gz) = 2a2f18b28319b8b4f8a17e58885ee7f5093a531f36da1ac120e7466742076eef +SIZE (adrian-thurston-colm-0.14.7-43-gd00ef793_GH0.tar.gz) = 1764267 diff --git a/lang/colm/files/patch-src_bytecode.c b/lang/colm/files/patch-src_bytecode.c new file mode 100644 index 000000000000..2969302188db --- /dev/null +++ b/lang/colm/files/patch-src_bytecode.c @@ -0,0 +1,13 @@ +- workaround for https://github.com/adrian-thurston/colm/issues/152 + +--- src/bytecode.c.orig 2022-08-23 18:33:46 UTC ++++ src/bytecode.c +@@ -20,6 +20,8 @@ + * SOFTWARE. + */ + ++#include "config.h" ++ + #include + + #include diff --git a/lang/colm/files/patch-src_main.cc b/lang/colm/files/patch-src_main.cc new file mode 100644 index 000000000000..594de46c7cbd --- /dev/null +++ b/lang/colm/files/patch-src_main.cc @@ -0,0 +1,13 @@ +- use cc as compiler + +--- src/main.cc.orig 2022-11-25 08:45:12 UTC ++++ src/main.cc +@@ -446,7 +446,7 @@ void compileOutput() + { + const char *compiler = getenv( "CC" ); + if ( compiler == 0 ) +- compiler = "gcc"; ++ compiler = "cc"; + + const char *cflags = getenv( "CFLAGS" ); + if ( cflags == 0 ) diff --git a/lang/colm/files/patch-test_runtests b/lang/colm/files/patch-test_runtests new file mode 100644 index 000000000000..d2cca0f2428e --- /dev/null +++ b/lang/colm/files/patch-test_runtests @@ -0,0 +1,11 @@ +--- test/runtests.orig 2022-11-25 08:51:12 UTC ++++ test/runtests +@@ -10,7 +10,7 @@ timed() + if [ -f /proc/cpuinfo ]; then + CORES=$(awk '/cpu cores/ { print $4; exit }' /proc/cpuinfo) + else +- CORES=$(sysctl -n hw.physicalcpu) ++ CORES=$(sysctl -n hw.ncpu) + fi + + diff --git a/lang/colm/pkg-descr b/lang/colm/pkg-descr new file mode 100644 index 000000000000..5e74ad962bf9 --- /dev/null +++ b/lang/colm/pkg-descr @@ -0,0 +1,21 @@ +Colm is COmputer Language Machinery. + +Colm is a programming language designed for the analysis and transformation of +computer languages. +Colm is influenced primarily by TXL. + +Features: +* Colm's main contribution lies in the parsing method. +* Colm's parsing engine is generalized, but it also allows for the construction + of arbitrary global data structures that can be queried during parsing. In + other generalized methods, construction of global data requires some very + careful consideration because of inherent concurrency in the parsing method. + It is such a tricky task that it is often avoided altogether and the problem + is deferred to a post-parse disambiguation of the parse forest. +* By default Colm will create an elf executable that can be used standalone for + that actual transformations. +* Colm is a static and strong typed scripting language. +* Colm is very tiny and fast and can easily be embedded/linked with c/cpp + programs. +* Colm's runtime is a stackbased VM that starts with the bare minimum of the + language and bootstraps itself. diff --git a/lang/colm/pkg-plist b/lang/colm/pkg-plist new file mode 100644 index 000000000000..53f5b40a2a6f --- /dev/null +++ b/lang/colm/pkg-plist @@ -0,0 +1,106 @@ +bin/colm +bin/colm-wrap +include/aapl/astring.h +include/aapl/avlbasic.h +include/aapl/avlcommon.h +include/aapl/avlibasic.h +include/aapl/avlikeyless.h +include/aapl/avlimap.h +include/aapl/avlimel.h +include/aapl/avlimelkey.h +include/aapl/avliset.h +include/aapl/avlitree.h +include/aapl/avlkeyless.h +include/aapl/avlmap.h +include/aapl/avlmel.h +include/aapl/avlmelkey.h +include/aapl/avlset.h +include/aapl/avltree.h +include/aapl/bstcommon.h +include/aapl/bstmap.h +include/aapl/bstset.h +include/aapl/bsttable.h +include/aapl/bubblesort.h +include/aapl/buffer.h +include/aapl/compare.h +include/aapl/dlcommon.h +include/aapl/dlist.h +include/aapl/dlistmel.h +include/aapl/dlistval.h +include/aapl/insertsort.h +include/aapl/mergesort.h +include/aapl/quicksort.h +include/aapl/resize.h +include/aapl/rope.h +include/aapl/sbstmap.h +include/aapl/sbstset.h +include/aapl/sbsttable.h +include/aapl/svector.h +include/aapl/table.h +include/aapl/vector.h +include/colm/bytecode.h +include/colm/colm.h +include/colm/colmex.h +include/colm/config.h +include/colm/debug.h +include/colm/defs.h +include/colm/input.h +include/colm/internal.h +include/colm/map.h +include/colm/pdarun.h +include/colm/pool.h +include/colm/program.h +include/colm/struct.h +include/colm/tree.h +include/colm/type.h +include/libfsm/actexp.h +include/libfsm/action.h +include/libfsm/actloop.h +include/libfsm/asm.h +include/libfsm/binary.h +include/libfsm/binbreak.h +include/libfsm/bingoto.h +include/libfsm/binvar.h +include/libfsm/codegen.h +include/libfsm/common.h +include/libfsm/dot.h +include/libfsm/flat.h +include/libfsm/flatbreak.h +include/libfsm/flatgoto.h +include/libfsm/flatvar.h +include/libfsm/fsmgraph.h +include/libfsm/gendata.h +include/libfsm/goto.h +include/libfsm/gotoexp.h +include/libfsm/gotoloop.h +include/libfsm/idbase.h +include/libfsm/ipgoto.h +include/libfsm/parsedata.h +include/libfsm/ragel.h +include/libfsm/redfsm.h +include/libfsm/switch.h +include/libfsm/switchbreak.h +include/libfsm/switchgoto.h +include/libfsm/switchvar.h +include/libfsm/tables.h +lib/libcolm-0.14.7.so +lib/libcolm.a +lib/libcolm.so +lib/libfsm-0.14.7.so +lib/libfsm.a +lib/libfsm.so +%%DATADIR%%/ril.lm +%%DATADIR%%/rlhc-c.lm +%%DATADIR%%/rlhc-crack.lm +%%DATADIR%%/rlhc-csharp.lm +%%DATADIR%%/rlhc-d.lm +%%DATADIR%%/rlhc-go.lm +%%DATADIR%%/rlhc-java.lm +%%DATADIR%%/rlhc-js.lm +%%DATADIR%%/rlhc-julia.lm +%%DATADIR%%/rlhc-main.lm +%%DATADIR%%/rlhc-ocaml.lm +%%DATADIR%%/rlhc-ruby.lm +%%DATADIR%%/rlhc-rust.lm +%%DATADIR%%/runtests +%%DOCSDIR%%/colm.vim