Re: How do I reference the src checkout in a package?

2022-10-29 Thread Zhu Zihao

Try `#$(package-source this-package)` in the builder gexp.

Or you can try `(assoc-ref inputs "source")`, but be careful, this is
undocumented behaviour and it may change without notice and break your
recipes.

OT: it's better to ask for help in help-g...@gnu.org :)

jgart  writes:

> On Sat, 29 Oct 2022 23:05:50 -0500 jgart  wrote:
>
> For example, nix allows you to reference the source checkout with the $src 
> variable:
>
> https://github.com/NixOS/nixpkgs/blob/nixos-unstable/pkgs/development/compilers/carp/default.nix#L38


-- 
Retrieve my PGP public key:

  gpg --recv-keys B3EBC086AB0EBC0F45E0B4D433DB374BCEE4D9DC

Zihao


signature.asc
Description: PGP signature


Re: How do I reference the src checkout in a package?

2022-10-29 Thread jgart
On Sat, 29 Oct 2022 23:05:50 -0500 jgart  wrote:

For example, nix allows you to reference the source checkout with the $src 
variable:

https://github.com/NixOS/nixpkgs/blob/nixos-unstable/pkgs/development/compilers/carp/default.nix#L38



How do I reference the src checkout in a package?

2022-10-29 Thread jgart
Hi,

I need to reference the carp checkout in an environment variable so that
carp can find the libs it needs:

/gnu/store/0xhn0vyjlcb2dv1h2333vhbj7j1vvrr6-carp-0.5.5-checkout

How can I do that?

* carp package definition

```
(define-public carp
  (package
(name "carp")
(version "0.5.5")
(source
 (origin
   (method git-fetch)
   (uri (git-reference
 (url "https://github.com/carp-lang/Carp;)
 (commit (string-append "v" version
   (file-name (git-file-name name version))
   (sha256
(base32 "14jdnv0ljqvpr9ych1plfw7hp5q57a8j1bv8h3v345x06z783d07"
(build-system haskell-build-system)
(arguments
 `(#:phases
   (modify-phases %standard-phases
   (add-after 'install 'make-clang-available-at-runtime
 (lambda* (#:key inputs outputs #:allow-other-keys)
   (let ((out (assoc-ref outputs "out"))
 (clang (assoc-ref inputs "clang")))
 (wrap-program (string-append out "/bin/carp")
   `("CARP_DIR" = (,out))
   `("PATH" = (,(string-append clang "/bin"
 (wrap-program (string-append out "/bin/carp-header-parse")
   `("CARP_DIR" = (,out))
   `("PATH" = (,(string-append clang "/bin"))
(native-inputs (list ghc-hunit))
(inputs (list clang
  ghc-blaze-markup
  ghc-blaze-html
  ghc-split
  ghc-ansi-terminal
  ghc-cmark
  ghc-edit-distance
  ghc-hashable
  ghc-open-browser
  ghc-optparse-applicative))
(home-page "https://carp-lang.org/;)
(synopsis "Statically typed Lisp without a garbage collector")
(description
"@code{carp} is a programming language designed to work well for
interactive and performance sensitive use cases like games, sound
synthesis and visualizations.")
(license license:asl2.0)))
```



Re: Release progress, week 3

2022-10-29 Thread Guillaume Le Vaillant
Ludovic Courtès  skribis:

> Release progress: week 3.
>
>   • Architectures:
>  [...]
>  - armhf-linux: No progress so far.

I tried doing a "guix pull" for armhf-linux on a Raspberry Pi 2 B
(Raspberry Pi OS with Guix as package manager), and also on a more
powerful x86_64 machine with "guix pull -s armhf-linux -p /tmp/arm-guix",
but it fails in both cases when building "guix-packages-base.drv" (more
precisely the process hangs, CPU usage at 0 and memory around 2 or
3 GB).

The build log ends with:
--8<---cut here---start->8---
compiling...  95.6% of 344 files
GC Warning: Failed to expand heap by 8388608 bytes
GC Warning: Failed to expand heap by 8388608 bytes
GC Warning: Failed to expand heap by 8388608 bytes
[... same message many times ...]
GC Warning: Failed to expand heap by 8388608 bytes
GC Warning: Failed to expand heap by 8388608 bytes
GC Warning: Failed to expand heap by 8388608 bytes
Too many heap sections: Increase MAXHINCR or MAX_HEAP_SECTS
--8<---cut here---end--->8---

Does someone have an idea how to fix this?


signature.asc
Description: PGP signature


Re: Mailman From header rewrite

2022-10-29 Thread Kyle Meyer
Kyle Meyer writes:

> Sarah Morgensen writes:
>
>> On Tuesday, January 5th, 2021 at 5:01 AM, Kyle Meyer  wrote:
>>
>>> add the appropriate "From:" header to the body of each patch. `git am`
>>> will take the in-body header over the actual header.
>>
>> I wonder if there is a way to automate the duplication of the "From"
>> header into the body of the patch?
>
> I'm not aware of an existing way at the git level.  Here's the only
> discussion I found about it on the git list [...]

Git 2.38.0 gained support for this via a --force-in-body-from option and
the associated format.forceInBodyFrom config variable.

  https://lore.kernel.org/git/20220829213837.13849-1-gits...@pobox.com/



Re: How Do We Fish If It Loads?

2022-10-29 Thread jgart
On Sat, 29 Oct 2022 09:30:50 +0800 Zhu Zihao  wrote:
> 
> It seems that there's no carp-lang packaged in Guix. So we have to
> package it first.

Ya, I don't think that will be too hard. There's a nixpkgs definition
here that shows what will be required:

https://github.com/NixOS/nixpkgs/blob/nixos-22.05/pkgs/development/compilers/carp/default.nix#L4

> And we should find out how the build system of Carp work.

Yup!

> OT: People will happier if you can elaborate the software you want to
> package, e.g. describe what is Carp.

Carp is a lisp that handles memory management in a similar way to
Rust. Not many other langs like that.

all best,

jgart



Re: bug#58859: profile contents depends on package order

2022-10-29 Thread Attila Lendvai
this is also somewhat related to:

https://issues.guix.gnu.org/50878

-- 
• attila lendvai
• PGP: 963F 5D5F 45C7 DFCD 0A39
--
“In your journey to healing, you will learn to appreciate the many faceted 
qualities of others. Your early impressions will grow more accurate and you 
will use your trust more wisely. As your boundaries become more clearly 
defined, you will detect more quickly when others violate them. When the wounds 
are healed, the sharks will no longer circle.”
— Richard Moskovitz, 'Lost in the Mirror'




Re: Antioxidant (new rust build system) update - 100% builds

2022-10-29 Thread Tobias Geerinckx-Rice

Hi Maxime,

This is so great.

It's been downright fun watching antioxidant steadily grow in 
power.  Thank you so much for working on it!


Kind regards,

T G-R


signature.asc
Description: PGP signature


Antioxidant (new rust build system) update - 100% builds

2022-10-29 Thread Maxime Devos

Hi,

100% (rounded up) of the packages build with antioxidant, though a very 
few still fail to build: .


So far, work on antioxidant has been done in a separate channel for 
convenience, but given that almost everything builds now, I think it's a 
good time to start looking into moving it into Guix proper (initially as 
a branch, as there are some remaining TODOs like e.g. 'why are some of 
the binaries made with antioxidant larger than with cargo-build-system + 
fix that').


More concretely, this would mean changing the 'runtime' transformations 
done by 'antioxidant-packages.scm' (in the style of '(guix)Defining 
Package Variants') to source code transformations ("guix style").


IIRC, Ludo' has some "guix style" patches for moving #:cargo-inputs to 
'inputs' and such; those could perhaps be used as a basis.


Greetings,
Maxime.


OpenPGP_0x49E3EE22191725EE.asc
Description: OpenPGP public key


OpenPGP_signature
Description: OpenPGP digital signature


Re: bug#58859: profile contents depends on package order

2022-10-29 Thread Maxime Devos
Looks sort-of but not quite a duplicate of 
 (‘guix shell’ skips profile 
collisions checks) to me.


Greetings,
Maxime.


OpenPGP_0x49E3EE22191725EE.asc
Description: OpenPGP public key


OpenPGP_signature
Description: OpenPGP digital signature