Package Details: nim-git 1:1.4.6.r1321.a9ae5fe5b-1

Git Clone URL: https://aur.archlinux.org/nim-git.git (read-only, click to copy)
Package Base: nim-git
Description: Nim is a statically typed compiled systems programming language. It combines successful concepts from mature languages like Python, Ada and Modula. Its design focuses on efficiency, expressiveness, and elegance (in that order of priority).
Upstream URL: https://nim-lang.org/
Licenses: MIT
Conflicts: nim
Provides: nim
Submitter: atweiden
Maintainer: 0x647262
Last Packager: 0x647262
Votes: 7
Popularity: 0.098269
First Submitted: 2016-04-05 20:14 (UTC)
Last Updated: 2021-05-10 17:19 (UTC)

Dependencies (1)

Required by (40)

Sources (4)

Pinned Comments

0x647262 commented on 2018-09-24 19:43 (UTC)

Looking for co-maintainers!

Shoot me an email if you're interested.

Latest Comments

0x647262 commented on 2022-05-16 15:52 (UTC)

Just tested this on aarch64, compiles without errors, so you can add it to the list of supported archs. Also, it needed the "patch" package, which was not installed in my barebones arm 64 system, might as well add it to build deps.

@void09 I don't list aarch64 support since I don't have hardware to test it on, but I can get you added you to the co-maintainer list if you'd like to.

Also, it needed the "patch" package, which was not installed in my barebones arm 64 system, might as well add it to build deps.

Evidently, a C compiler is a dependency. Not sure if that's really the type of thing that belongs in the dependency list

To answer both of these in one go, base-devel (https://wiki.archlinux.org/title/Arch_User_Repository#Getting_started) is assumed to be installed (see the first note: https://wiki.archlinux.org/title/PKGBUILD#makedepends) before you start working with AUR packages.

void09 commented on 2022-05-16 12:01 (UTC)

Just tested this on aarch64, compiles without errors, so you can add it to the list of supported archs. Also, it needed the "patch" package, which was not installed in my barebones arm 64 system, might as well add it to build deps.

bwbuhse commented on 2022-02-02 14:20 (UTC)

Evidently, a C compiler is a dependency. Not sure if that's really the type of thing that belongs in the dependency list, but I had some issues a while back and removed gcc while I was fixing them then forgot about it. Kept having non-descriptive errors until I tried choosenim instead and it said I needed one.

IOAOI commented on 2021-05-07 01:09 (UTC)

Some helpful discussion of build issues here: https://github.com/nim-lang/Nim/issues/17907

alaviss commented on 2021-05-02 04:18 (UTC)

Nim has moved to csources_v1 to bootstrap, please update this PKGBUILD to use it so that it builds now that we start relying on the new bootstrap compiler.

Figworm commented on 2021-04-19 00:38 (UTC) (edited on 2021-04-19 00:39 (UTC) by Figworm)

nim-lang/Nim git repo: removed nimfind tool, succeeded by 'nim check --defusages' #17737

The current build fails with (paraphrased) 'unable to touch 'Nim/bin/nimfind' error. Removing references of nimfind in PKGBUILD, allows build to continue as normal.

haawda commented on 2021-01-06 22:25 (UTC)

The "examples" subdir vanished in upstreams repo.

IOAOI commented on 2020-10-29 18:52 (UTC)

The nim binary package builds some extra tools and includes nimpretty and nimsuggest, while nim-git doesn't.

nim-git /usr/bin/nim nim-git /usr/bin/nimgrep

nimpretty-git /usr/bin/nimpretty

nimsuggest-git /usr/bin/nimsuggest

nim usr/bin/nim nim usr/bin/nim-gdb nim usr/bin/nim-gdb.bash nim usr/bin/nim-gdb.bat nim usr/bin/nimfind nim usr/bin/nimgrep nim usr/bin/nimpretty nim usr/bin/nimsuggest nim usr/bin/testament

nim binary package PKGBUILD: https://git.archlinux.org/svntogit/community.git/tree/nim/repos/community-x86_64/PKGBUILD

haawda commented on 2020-09-30 16:39 (UTC)

Better pkgver function:

diff --git a/PKGBUILD b/PKGBUILD
index 6624742..3702f6b 100644
--- a/PKGBUILD
+++ b/PKGBUILD
@@ -10,7 +10,7 @@ pkgbase='nim-git'
 pkgname=('nim-git' 'nimble-git' 'nimsuggest-git' 'nimpretty-git')
 pkgdesc='Nim is a compiled, garbage-collected systems programming language with a design that focuses on efficiency, expressiveness, and elegance (in that order of priority).'
 epoch=1
-pkgver=0.19.4.r1821.d24585c49
+pkgver=1.4.0b4438.9c86f4867
 pkgrel=1
 arch=('i686' 'x86_64')
 groups=('nim')
@@ -22,14 +22,15 @@ source=(
   'git+https://github.com/nim-lang/nimble'
   'makepkg-conf.patch'
 )
-sha256sums=(
-  'SKIP' 'SKIP' 'SKIP' 'SKIP'
-  '9d73290e81a2e2a79f7bb8058d47854d90ba9301dda1bee107294e2d82f631bf'
-)
+sha256sums=('SKIP'
+            'SKIP'
+            'SKIP'
+            'SKIP'
+            '9d73290e81a2e2a79f7bb8058d47854d90ba9301dda1bee107294e2d82f631bf')

 _tag() {
   # Describes the most recent tag
-  git describe --abbrev=0 origin/master
+  head -1 changelog.md | cut -c3-8
 }

 _revision() {
@@ -46,7 +47,7 @@ pkgver() {
   cd Nim

   # Suggestions for improvement welcome!
-  printf '%s.r%s.%s'         \
+  printf '%sb%s.%s'         \
     "$(_tag | sed 's/v//g')" \
     "$(_revision)"           \
     "$(_commit)"

ruestique commented on 2019-05-07 04:00 (UTC)

edit pkgbuild, please -_-

ktamp commented on 2019-05-02 19:06 (UTC)

Please add '--abbrev=0' to _tag() in order to fix pkgver() issue.

luntik2012 commented on 2019-05-01 10:15 (UTC)

official nim from testing is broken too...

Cloning into 'nimble'...
done.
==> Starting prepare()...
patching file ./csources/build.sh
Hunk #1 succeeded at 40 with fuzz 3.
==> Starting pkgver()...
==> ERROR: pkgver is not allowed to contain colons, forward slashes, hyphens or whitespace.
==> ERROR: pkgver() generated an invalid version: 0.19.4-2-g7f3b686b8.r1787.c94ab4692
==> ERROR: Makepkg was unable to build nim-git.
==> Restart building nimble-git ? [y/N]

0x647262 commented on 2019-01-06 19:29 (UTC) (edited on 2019-01-06 21:22 (UTC) by 0x647262)

@tejasjadhav

Please read the following documentation: https://wiki.archlinux.org/index.php/VCS_package_guidelines#Guidelines

EDIT:

Nevermind... There are some discrepancies between master and devel that are preventing pkgver from picking up the tags correctly. I'll update pkgver() to accommodate for this.

Apologies for my initial hostility, I got a bit defensive since *-git packages often get wrongly flagged as out-of-date.

0x647262 commented on 2018-09-24 19:43 (UTC)

Looking for co-maintainers!

Shoot me an email if you're interested.

0x647262 commented on 2018-09-24 19:41 (UTC) (edited on 2018-09-24 19:57 (UTC) by 0x647262)

@haawda This will be fixed in pkgrel=2, as it relates to @ferion's comment.

Should have it pushed in the next 15 minutes or so!

Edit: Fixed! The next error:

install.nim(2, 20) Error: undeclared identifier: 'SystemError'
make: *** [Makefile:117: lib/tools] Error 1
make: *** Waiting for unfinished jobs....
utils.nim(222, 26) Error: undeclared identifier: 'SystemError'
make: *** [Makefile:123: src/pakku] Error 1
==> ERROR: A failure occurred in build().
    Aborting...

Is related to: https://github.com/nim-lang/Nim/blob/6e83746caabca00ab2b97a81bd732de4588996fe/changelog.md

The exception hierarchy was slightly reworked, SystemError was renamed to CatchableError and is the new base class for any exception that is guaranteed to be catchable. This change should have minimal impact on most existing Nim code.

haawda commented on 2018-09-22 09:14 (UTC)

Compiling pakku-git with nim-git fails with

==> Making package: pakku-git 0.13r6.gb7666cb-1 (Sat Sep 22 11:13:01 2018)
==> Checking runtime dependencies...
==> Checking buildtime dependencies...
==> Retrieving sources...
  -> Updating pakku git repo...
Fetching origin
==> Validating source files with sha256sums...
    pakku ... Skipped
==> Extracting sources...
  -> Creating working copy of pakku git repo...
Switched to a new branch 'makepkg'
==> Starting pkgver()...
==> Removing existing $pkgdir/ directory...
==> Starting build()...
NIM: lib/tools
tools.nim(1, 8) Error: cannot open file: os
make: *** [Makefile:117: lib/tools] Error 1
==> ERROR: A failure occurred in build().
    Aborting...

The same works fine with the stable nim.

eschwartz commented on 2018-09-07 03:31 (UTC)

Note that in order to properly upgrade to the new version scheme you'll need to use an epoch.

ferion commented on 2018-08-25 19:39 (UTC)

-d:useGnuReadline is also no longer supported by koch so I used -d:useLinenoise Also note that nim will check config files in /etc/nim/ now, otherwise nim will not know about the libraries in /usr/lib/nim https://github.com/nim-lang/Nim/issues/8653

0x647262 commented on 2018-08-18 18:01 (UTC) (edited on 2018-08-18 18:07 (UTC) by 0x647262)

This package no longer builds in a clean chroot:

Hint: operation successful (122109 lines compiled; 14.481 sec total; 411.09MiB peakmem; Release Build) [SuccessX]
iteration: 2
compiler/nim1 c -d:release -d:nativeStacktrace -d:useGnuReadline --nimcache:nimcache/r_linux_amd64 compiler/nim.nim
Hint: used config file '/build/nim-git/src/Nim/config/nim.cfg' [Conf]
Hint: used config file '/build/nim-git/src/Nim/compiler/nim.cfg' [Conf]
Hint: system [Processing]
lib/system/excpt.nim(310, 9) Error: type mismatch: got <nil> but expected 'seq[StackTraceEntry]'
FAILURE
==> ERROR: A failure occurred in build().
    Aborting...

This seems to be related to the following line:

./koch boot -d:release -d:nativeStacktrace -d:useGnuReadline

Utilizing two options that no longer seem supported by koch: https://github.com/nim-lang/Nim/blob/devel/koch.nim#L46

EDIT: Removing -d:nativeStacktrace fixes the build.

0x647262 commented on 2018-08-08 15:24 (UTC) (edited on 2018-08-08 15:25 (UTC) by 0x647262)

The pkgver() function should be replaced with the following:

pkgver() {
  cd "$pkgname"
  git describe --long --tags           \
    | sed 's/\([^-]*-g\)/r\1/;s/-/./g' \
    | sed 's/v//'
}

Which (currently) yields: 0.18.0.r1001.g506418ef5

alaviss commented on 2018-05-03 06:22 (UTC)

@ibrokemypie

You have to build nim-git with docs generation disabled first, then rebuild with docs after you've installed nim-git.

ibrokemypie commented on 2018-04-22 06:55 (UTC)

Currently failing to build with

manual_snippet_122.nim(4, 20) Error: undeclared identifier: 'ForLoopStmt'
Error: execution of an external program failed: 'nim c doc/nimcache/manual/manual_snippet_122.nim'

Error: execution of an external program failed: '/tmp/makepkg/nim-git/src/Nim/tools/nimweb --pdf web/website.ini --putenv:nimversion=0.18.1'
FAILURE
==> ERROR: A failure occurred in build().
    Aborting...

greenmanalishi commented on 2017-07-08 19:01 (UTC) (edited on 2017-07-08 19:07 (UTC) by greenmanalishi)

Any update for nimsuggest being moved to the main repo? Also 'texlive-fontsextra' is a huge package could this dep be avoided?

shiva commented on 2017-02-28 06:35 (UTC)

Thanks for this! How do we get https://www.archlinux.org/packages/community/x86_64/nim/ replaced with your changes?

atweiden commented on 2017-01-24 06:35 (UTC)

thanks @hcorion, updated

hcorion commented on 2017-01-23 20:49 (UTC)

Hi, this package currently doesn't build and crashes during the pdf generation section. To fix this the package texlive-fontsextra needs to be installed.