!rWxyQqNqMUDLECdsIf:blad.is

Poetry2nix

332 Members
https://github.com/nix-community/poetry2nix63 Servers

Load older messages


SenderMessageTime
25 May 2022
@reivilibre:librepush.netreivilibre wonder if you need nativeBuildInputs, but that's just an idle thought 14:00:33
@reivilibre:librepush.netreivilibrehm I probably have it backwards14:01:59
@k900:0upti.meK900 You probably want to remove the manual cflags and add pkg-config to nativeBuildInputs instead 14:02:45
@reivilibre:librepush.netreivilibre I don't know but should you be passing FFTW as a build input in an override for pyfftw rather than your package? 14:03:35
@k900:0upti.meK900Also that yes14:04:08
26 May 2022
@loicreynier:matrix.orgLoïc Reynier Removing the cflags and adding pkg-config as nativeBuildInputs did not make it work 16:49:25
@loicreynier:matrix.orgLoïc Reynier I thought that the packages passed in buildInputs would be available for all packages built in the environment, so it would not be necessary to add build input for all the packages 16:51:49
@adis:blad.isadisbladis
In reply to @loicreynier:matrix.org
I thought that the packages passed in buildInputs would be available for all packages built in the environment, so it would not be necessary to add build input for all the packages
No, they will not be passed to the entire graph. You're looking for overrides.
16:53:21
@loicreynier:matrix.orgLoïc Reynier

Thanks you, it did the trick:

overrides = prev.poetry2nix.overrides.withDefaults (self: super: {
            pyfftw = super.pyfftw.overrideAttrs (
              old: {
                buildInputs = with prev; [
                  fftw
                  fftwFloat
                  fftwLongDouble
                ];
              });
17:11:29
@loicreynier:matrix.orgLoïc Reynier *

Thanks you, it did the trick:

overrides = prev.poetry2nix.overrides.withDefaults (self: super: {
  pyfftw = super.pyfftw.overrideAttrs (
    old: {
      buildInputs = with prev; [
        fftw
        fftwFloat
        fftwLongDouble
      ];
    });
  });

17:11:59
@loicreynier:matrix.orgLoïc Reynier *

Thanks you, it did the trick:

overrides = prev.poetry2nix.overrides.withDefaults (self: super: {
  pyfftw = super.pyfftw.overrideAttrs (
    old: {
      buildInputs = with prev; [
        fftw
        fftwFloat
        fftwLongDouble
      ];
    });
  });
17:12:09
@adis:blad.isadisbladisAdd it upstream in https://github.com/nix-community/poetry2nix/pull/64917:14:35
@madhadder:matrix.orgmadhadder joined the room.17:58:46
@notgne2:wizbos.clubnotgne2 joined the room.22:19:08
3 Jun 2022
@gmacon:matrix.orggmacon joined the room.19:58:51
4 Jun 2022
@schuelermine:matrix.orgschuelermine joined the room.12:31:16
@schuelermine:matrix.orgschuelermine Hi! I’ve never used Poetry before but I want to package a project that uses it. Can I use the Poetry2Nix functions directly inside Nixpkgs? I noticed that poetry build generates a dist directory and the tarball inside contains a setup.py. Should I specify the Poetry2Nix call as src? I’m unsure how this is supposed to work. 12:33:29
@adis:blad.isadisbladis
In reply to @schuelermine:matrix.org
Hi! I’ve never used Poetry before but I want to package a project that uses it. Can I use the Poetry2Nix functions directly inside Nixpkgs? I noticed that poetry build generates a dist directory and the tarball inside contains a setup.py. Should I specify the Poetry2Nix call as src? I’m unsure how this is supposed to work.
You don't use the build directory from poetry build for packaging.
13:23:04
@adis:blad.isadisbladisThat directory is used for publishing on pypi13:23:20
@adis:blad.isadisbladisYou should just point poetry2nix to the sources13:23:31
@adis:blad.isadisbladisThe setup.py is a compatibility thing13:23:45
@schuelermine:matrix.orgschuelermineOh OK13:26:16
@schuelermine:matrix.orgschuelermineThanks13:26:27
@adis:blad.isadisbladisInternally poetry still generates the setup.py at build time iirc13:26:48
@adis:blad.isadisbladisBut that's not something you need to bother with, it's an implementation detail13:26:59
@schuelermine:matrix.orgschuelermineBut is it correct to put fetchFromGitHub or similar in projectDir?13:35:37
@schuelermine:matrix.orgschuelermineAnd is the result from the call to mkPoetryApplication a derivation that can be put into nixpkgs?13:35:54
@adis:blad.isadisbladisYou can do that, but that would result in IFD13:36:00
@adis:blad.isadisbladisWhich isn't allowed in nixpkgs13:36:08
@schuelermine:matrix.orgschuelermineOh13:36:14

Show newer messages


Back to Room ListRoom Version: 6