Skip to content

Commit

Permalink
use nim macros
Browse files Browse the repository at this point in the history
Signed-off-by: madomado <[email protected]>
  • Loading branch information
madonuko authored Oct 4, 2024
1 parent 1dd2e77 commit ccb9465
Showing 1 changed file with 5 additions and 11 deletions.
16 changes: 5 additions & 11 deletions anda/langs/nim/choosenim/choosenim.spec
Original file line number Diff line number Diff line change
Expand Up @@ -6,26 +6,20 @@ Release: 1%?dist
Summary: Easily install and manage multiple versions of the Nim programming language
License: BSD-3-Clause
URL: https://github.com/nim-lang/choosenim
Source1: https://nim-lang.org/download/nim-%nimver-linux_x64.tar.xz
Source0: %url/archive/refs/tags/v%version.tar.gz
Packager: madonuko <[email protected]>
BuildRequires: nim git-core curl tar anda-srpm-macros
BuildRequires: nim nim-tools git-core anda-srpm-macros

%description
choosenim installs the Nim programming language from official downloads and
sources, enabling you to easily switch between stable and development compilers.

%prep
%git_clone %url v%version
%dnl tar -xvJf %SOURCE1
%autosetup
%nim_prep

%build
NIMPATH=`pwd`/nim-%nimver/bin
PATH=$PATH:$NIMPATH
# compile choosenim
%dnl ls -lah
%dnl nimble install --path=$NIMPATH -y
%dnl %nim_c --path:$NIMPATH
nimble build -d:release -t:"%nim_tflags" -l:"%nim_lflags"
%nim_c src/choosenim

%install
install -Dm755 src/choosenim %buildroot%_bindir/choosenim
Expand Down

0 comments on commit ccb9465

Please sign in to comment.