summaryrefslogtreecommitdiff
path: root/dev-lang/nim
diff options
context:
space:
mode:
authorV3n3RiX <venerix@koprulu.sector>2021-12-25 20:34:27 +0000
committerV3n3RiX <venerix@koprulu.sector>2021-12-25 20:34:27 +0000
commit0f15659d48c193027158492acb726297501202c5 (patch)
tree5502ba879a78b759da28441d418dbbfe08bd8f03 /dev-lang/nim
parent93a93e9a3b53c1a73142a305ea1f8136846942ee (diff)
gentoo xmass resync : 25.12.2021
Diffstat (limited to 'dev-lang/nim')
-rw-r--r--dev-lang/nim/Manifest4
-rw-r--r--dev-lang/nim/metadata.xml39
-rw-r--r--dev-lang/nim/nim-1.6.2.ebuild91
3 files changed, 129 insertions, 5 deletions
diff --git a/dev-lang/nim/Manifest b/dev-lang/nim/Manifest
index 851cd412d323..355814bbd2b5 100644
--- a/dev-lang/nim/Manifest
+++ b/dev-lang/nim/Manifest
@@ -1,4 +1,6 @@
AUX nim-0.20.0-paths.patch 934 BLAKE2B 6a4e44c5656cde6d5127bf6a6b8db92cdf8aada0892c27d536d0c1030ed7da8dc97138a8941030101918021f2a301fa683169c8a656fefc6fb7d0fcdb24029d4 SHA512 bf8dbc3e3861ec3ea2718092b981e495194ead5b547e69d01d5d842d128dc4b96b0ba3e95c78afd8fd822d594199315a01de370851ed8f594c091231b9a10ee9
DIST nim-1.4.8.tar.xz 4786360 BLAKE2B 961b38275c4f9de87ac522c5b47368ce7f5543811a2dfd7b4f3fd79a104bcd0458caaaaab1705f99eb42c64735ca5f71d5018f8a8275a430d883233b28b1d412 SHA512 e6b245271495880f0eea271c46b4f5ce9168a421716a9a22367b6be3c2a9822937aad1f48eb61c151b040ac961728a89c8a6d143c8300057c0d8c1f2d66f3dd3
+DIST nim-1.6.2.tar.xz 5181616 BLAKE2B adedbcaad1b135b6f99459894856190103e2d2b678849e0418f77c02a54fde44224456ea13949f3fe9f5f020a90adde46593497895674bd9ae892b17708df292 SHA512 052b62c987035f7633f965356993cd4eec686f4f4f5c675cf966d82cb30fcf574045887a4402bcc20e487299fb5e8f65a921951c2dc21ac334e695e31d95d992
EBUILD nim-1.4.8.ebuild 1908 BLAKE2B c7e267e92cda81ae16e1dba7a82baaec77c12b7b7a3a4dccec994d868bef4cf7558562fe3d6f80ec5542f8195dacf0d291fce5d3ac3cabf1172bc887870ccae1 SHA512 70b3b578fc1ca1450fd02d31e865a1d7a2805d9c26c31ceba26076d9eb21100df1357645eee62f68b25f0a434f3bbd07479cbd661ec19b78af6cf253b7dc2438
-MISC metadata.xml 245 BLAKE2B 09d4ba8c1cc63eaf82d16d7371c3b7751b41971730cc81d830d88e3b965beeaf0fa9c49a1520a06c19325a392632cc7bb834bc77628b7df8bd5aca090053197c SHA512 e217497284ab5b4f89dbf65f8ff03ed238487a285c299b41392851b06d93c396d5062a46fa448889deee68a3b42ba790ae320c436277b0f88457917909054a19
+EBUILD nim-1.6.2.ebuild 2119 BLAKE2B b4c2954c990fd7c3a42e122ff7e98427a7a51a1b9468dcb2de46f0cfa47e6de66838ff7f74b94f63d9e00e5f880ed7c0adafe2b8346a53b92c6d0138f53e7754 SHA512 c385fb10fd13f8b9c31df16eabced9aaeb27824634d3f2eeaafcf9b37bdb441546a1ac3a7b789dd3f4bd5bcdacf8980a305541243c30cb23360010be3a797fcf
+MISC metadata.xml 1894 BLAKE2B 8ba43a558af584b0c455e16f6d710a2482fbd3d8a4ae80817ee0080165227e931f40b2269d6316ca4fc8773cea0e6d941feafcc30d8a2eb5eb0843d8f7e7df71 SHA512 6fbc92e65c8a85c82cba372aba12133acc626c2a33ec35aff4a02246e70f64dd06c51af121f17fb5cbab48df1aafa3e9af9375a1ccbd769590e26078a7dacf88
diff --git a/dev-lang/nim/metadata.xml b/dev-lang/nim/metadata.xml
index 9144ad2e7557..cca80bdcbe60 100644
--- a/dev-lang/nim/metadata.xml
+++ b/dev-lang/nim/metadata.xml
@@ -1,8 +1,39 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "https://www.gentoo.org/dtd/metadata.dtd">
+
<pkgmetadata>
- <!-- maintainer-needed -->
- <upstream>
- <remote-id type="github">nim-lang/Nim</remote-id>
- </upstream>
+ <maintainer type="person">
+ <email>xgqt@gentoo.org</email>
+ <name>Maciej Barć</name>
+ </maintainer>
+ <longdescription>
+ Nim is a statically typed compiled systems programming language.
+ It combines successful concepts from mature languages like Python,
+ Ada and Modula.
+ Nim generates native dependency-free executables, not dependent on a
+ virtual machine, which are small and allow easy redistribution.
+ The Nim compiler and the generated executables support all major platforms
+ like Windows, Linux, BSD and macOS.
+ Nim's memory management is deterministic and customizable with destructors
+ and move semantics, inspired by C++ and Rust. It is well-suited for
+ embedded, hard-realtime systems.
+ Modern concepts like zero-overhead iterators and compile-time evaluation of
+ user-defined functions, in combination with the preference of value-based
+ datatypes allocated on the stack, lead to extremely performant code.
+ Support for various backends: it compiles to C, C++ or JavaScript so that
+ Nim can be used for all backend and frontend needs.
+ Nim is self-contained: the compiler and the standard library are
+ implemented in Nim.
+ Nim has a powerful macro system which allows direct manipulation of the
+ AST, offering nearly unlimited opportunities.
+ Macros cannot change Nim's syntax because there is no need for it — the
+ syntax is flexible enough.
+ Modern type system with local type inference, tuples, generics and sum
+ types.
+ Statements are grouped by indentation but can span multiple lines.
+ </longdescription>
+ <upstream>
+ <bugs-to>https://github.com/nim-lang/Nim/issues/</bugs-to>
+ <remote-id type="github">nim-lang/Nim</remote-id>
+ </upstream>
</pkgmetadata>
diff --git a/dev-lang/nim/nim-1.6.2.ebuild b/dev-lang/nim/nim-1.6.2.ebuild
new file mode 100644
index 000000000000..6e066c0a612d
--- /dev/null
+++ b/dev-lang/nim/nim-1.6.2.ebuild
@@ -0,0 +1,91 @@
+# Copyright 1999-2021 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=8
+
+inherit bash-completion-r1 multiprocessing toolchain-funcs
+
+DESCRIPTION="compiled, garbage-collected systems programming language"
+HOMEPAGE="https://nim-lang.org/"
+SRC_URI="https://nim-lang.org/download/${P}.tar.xz"
+
+LICENSE="MIT"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~x86"
+IUSE="debug +readline"
+RESTRICT="test" # need to sort out depends and numerous failures
+
+RDEPEND="readline? ( sys-libs/readline:0= )"
+DEPEND="${DEPEND}"
+# test? ( net-libs/nodejs )
+
+PATCHES=( "${FILESDIR}"/${PN}-0.20.0-paths.patch )
+
+QA_FLAGS_IGNORED="
+usr/bin/atlas
+usr/bin/nim
+usr/bin/nim_dbg
+usr/bin/nimble
+usr/bin/nimgrep
+usr/bin/nimpretty
+usr/bin/nimsuggest
+usr/bin/testament
+"
+
+_run() {
+ echo "Running: ${@}"
+ PATH="${S}/bin:${PATH}" "${@}" || die "Failed: \"${*}\""
+}
+
+nim_use_enable() {
+ [[ -z "${2}" ]] && die "usage: nim_use_enable <USE flag> <compiler flag>"
+ use "${1}" && echo "-d:${2}"
+}
+
+src_configure() {
+ export XDG_CACHE_HOME="${T}/cache" #667182
+ unset NIMBLE_DIR
+ tc-export CC CXX LD
+
+ local build_type
+ if use debug ; then
+ build_type="debug"
+ else
+ build_type="release"
+ fi
+ export NIM_OPTS=( --parallelBuild:$(makeopts_jobs) -d:${build_type} )
+
+ # Override defaults
+ echo "gcc.exe = \"$(tc-getCC)\"" >> config/nim.cfg || die
+ echo "gcc.linkerexe = \"$(tc-getCC)\"" >> config/nim.cfg || die
+ echo "gcc.cpp.exe = \"$(tc-getCXX)\"" >> config/nim.cfg || die
+ echo "gcc.cpp.linkerexe = \"$(tc-getCXX)\"" >> config/nim.cfg || die
+}
+
+src_compile() {
+ _run bash ./build.sh
+
+ _run ./bin/nim ${NIM_OPTS[@]} compile koch
+ _run ./koch boot ${NIM_OPTS[@]} $(nim_use_enable readline useGnuReadline)
+ _run ./koch tools ${NIM_OPTS[@]}
+}
+
+src_install() {
+ _run ./koch install "${ED}"
+
+ # "./koch install" installs only "nim" binary
+ # but not the rest
+ exeinto /usr/bin
+ local exe
+ for exe in bin/* ; do
+ [[ "${exe}" == bin/nim ]] && continue
+ doexe "${exe}"
+ done
+
+ newbashcomp tools/nim.bash-completion nim
+ newbashcomp dist/nimble/nimble.bash-completion nimble
+}
+
+src_test() {
+ _run ./koch test
+}