<Henson>
nly: are you building that from a derivation or directly in a shell?
<nly>
in shell with `nix-shell -p libgccjit'
<Henson>
nly: oops, it looks like from a shell. Make sure glibc is in your path. Maybe try doing a "nix-shell -p glibc" before running your gcc command.
cantstanya has quit [Ping timeout: 268 seconds]
<simpson>
Henson++ can you share what you changed? I'm sure that a PR would be welcome.
<{^_^}>
Henson's karma got increased to like 12, I think
<Henson>
simpson: about OpenCV?
cantstanya has joined #nixos
<simpson>
Yeah.
<Henson>
simpson: when I include the package in my shell.nix, I just overrode the derivation to exclude openblas like this: (opencv4.override {enableOpenblas=false;} ) I tried rebuilding to include lapack-reference and blas-reference, but it complains about a missing cblas function reference. I don't have time to get to the bottom of how to keep blas and lapack and make it work properly, but that's
<Henson>
simpson: the short-term fix for the time being. I don't think the Debian version uses openblas, but I'll have to try building the Debian version from source to figure out the combination of packages it uses.
<Henson>
simpson: I don't know if OpenCV will perform some mathematical operations slower now that I've disabled openblas
<simpson>
No worries. Thanks for digging into it.
<Henson>
simpson: should I file some kind of bug report?
<simpson>
Henson: The best sort of bug report to file is a PR against nixpkgs. You can also open an issue without code.
chrsmth has joined #nixos
codygman__ has joined #nixos
evils has joined #nixos
<matthewcroughan_>
gchristensen: Man, Tailscale is great. I tried to do my own thing with Wireguard, but it's just impossible, because DNS on Android is basically unconfigurable.
<matthewcroughan_>
I really wish I could do it all myself, all I wanted was magic dns
<bb_>
Hi, why would stuff like this be neccesary: export LD_LIBRARY_PATH=${pkgs.lib.makeLibraryPath buildInputs}:$LD_LIBRARY_PATH and not be handled automatically by mkDerivation?
Shiranai has quit [Quit: Connection closed]
endformationage has quit [Quit: WeeChat 2.9]
Vadrigar has joined #nixos
Vadrigar has quit [Ping timeout: 260 seconds]
stree has quit [Ping timeout: 246 seconds]
MarcWeber has joined #nixos
simba1 has joined #nixos
stree has joined #nixos
hyper_ch5 has quit [Read error: Connection reset by peer]
<clever>
Ke: this function can be ran thru lib.fix, to map self to its own return value, and make everything work
<clever>
Ke: but, thru the magic of makeScope and overrideScope', i can insert a second function
<clever>
so it becomes more like `f (f2 result)`
dominikh has joined #nixos
<clever>
then i can mutate things before they go back in
jmeredith has quit [Quit: Connection closed for inactivity]
<rydnr>
So, to call `f` the first time, we need to pass it the return value of the previous call, and to get it we enter the loop. Is that the reasoning, right?
cyphase has quit [Ping timeout: 240 seconds]
<clever>
rydnr: it only gets ran once, thru the magic of lazyness, that 1st run can depend on its own return value
<clever>
the trick, is that nix must be able to compute the top-level value of `f`, before its args
<clever>
so if you do `f = self: { a=...; b=...; }`
<clever>
then nix can figure out, that the top-level value is a set, with the keys a&b
concept2 has quit [Quit: Ping timeout (120 seconds)]
<clever>
and now it knows that self is a set, with keys a&b
<clever>
and then it can keep computing things
concept2 has joined #nixos
<clever>
it doesnt need to know what self is, to figure out what `self: { a=...; b=...; }` is returning, as the root value
<Ke>
clever: I guess I would need some time to look that through
<rydnr>
`self`is an arbitrary name or a regular function parameter when defining an anonymous function?
<rydnr>
arbitrary -> special, sorry
<clever>
rydnr: just a regular argument
stree has joined #nixos
<srhb>
Ke: I'd say its use is pretty reasonable -- it's just DRY for lazy FP really. Otherwise we'd have to re-implement it all over the place :)
<rydnr>
clever: and that is suitable regardless of the actual function? Can nix figure out the return of the function regardless of the input passed to it?
<clever>
rydnr: if you write the function the right way, yeah
<clever>
rydnr: nix is lazy, so it wont figure out what the arguments are, until something references it
LilleCarl has joined #nixos
<clever>
so if you have something like: `f = self: { a=...; b=...; }` and then try to use `fix f` then nix will first look at fix, and do the code i explained before
<clever>
so the `result` in fix, will return the `{a=...; b=...;}` part of the function, and the only special thing, is that any reference to `self` in the ..., now has a lazy reference to something
<clever>
its not until you do the .a or .b, does nix try to figure out what a= or b= evaluates ot
<wloczykij>
For some reason my wifi suddenly stopped working. Systemd tries to enable wlp3s0 interface at boot but fails. noxos-option networking.usePredictableInterfaceNames is true bud when I ifconfig I see wlan0 listed. Ethernet interface is enp0s25 though. Any idea what might have caused the wlan interface naming inconsistency?
<apeyroux>
i want to use substituteInPlace with .so file but the default-builder.sh takes 100% CPU and the build freezes. We can use substituteInPlace with a .so?
<clever>
apeyroux: it deals poorly with large files, and if the old and new string are of a different length, it will also break binary files
m0rphism has joined #nixos
sonne has left #nixos ["Leaving"]
<apeyroux>
clever: ok thx !
<apeyroux>
clever: "if the old and new string are of a different length, it will also break binary files" Is there a way to avoid this? (I have a /usr/bin/xxx in a .so ...)
<phalrax>
Hi, quick question, why is the kernel version relatively old? The rest of the available packages seem pretty up to date, so the kernel surprised me
<srhb>
phalrax: What's "relatively old"?
<srhb>
phalrax: (It helps to tell s what version, why you think it's old, which channel your system is on, etc :))
<phalrax>
5.4 is relatively old for me, considering 5.11 is out. I'm on 20.09, default channel
<ar>
phalrax: iirc kernel package follows latest lts kernel; if you want the latest version, you can set boot.kernelPackages = pkgs.linuxPackages_latest;
<srhb>
phalrax: The stabl channels (20.09 right now) generally use the latest LTS kernel at the time of release, which was 5.4
<srhb>
phalrax: I'd expect it to be 5.10 in NixOS 21.05
<phalrax>
ah, so that's the reason. got it, thanks!
<ar>
though i'm not sure if pkgs.linuxPackages_latest gets updated in stable channels
<phalrax>
I'm trying to use services.sanoid.datasets, but I'm not sure how to do a "attribute set of submodules", do I just put the datasets I want inside [] or {}?
<shla>
dutchie, isn't it the idea of _latest to always ship latest stable kernel?
thc202 has joined #nixos
<s1341_>
is it possible to use why-depends on a nix-shell derivation?
<dutchie>
shla: there's always a tension between "shipping the always latest version" and "shipping a stable unchanging set of software"
<dutchie>
you can use -unstable if you prefer the first (and can cope with the resulting occasional breakage) and the release channels for the second (and deal with slightly older packages)
<bb_>
can someone please help with the patch issue
<bb_>
I really dont understand
<shla>
i prefer the stability, so I'll stick stable channel
<dutchie>
you can also import linuxPackages_latest from unstable (or even master!)
<supersandro2000>
shla: not debian stable?
<shla>
supersandro2000, not anymore.
<supersandro2000>
well, real rebels use debian sid with nix master everywhere
<AlesHuzik[m]>
Is there anyone here who managed to get Mobile NixOS running on PinePhone? It seems to be a supported device, but I can't make it boot using latest successful image from hydra.
lsix1 has joined #nixos
<AlesHuzik[m]>
Any help would be very much appreciated
<gchristensen>
AlesHuzik[m]: I think you'll get good help if you re-ask in, umm... 6-8 hours in #nixos-aarch64
<AlesHuzik[m]>
gchristensen: thanks!
avaq_ has joined #nixos
<aforemny>
AlesHuzik[m]: I recently managed to get Mobile NixOS running on Pinephone. Maybe ask in #nixos-aarch64 now and I might be able to help! (I'm assuming #nixos-aarch64 might be better suited.)
<phalrax>
Hi, is there a way to include one off commands in my configuration.nix? For example I'd need to run 'smbpasswd -a $USER' when doing a complete reinstall and would like to somehow keep that in my config
<supersandro2000>
phalrax: can you easily check if that command was already run?
<remexre>
is there a way to get the expression / file / etc that caused a derivation to exist?
<sterni>
cinimod: accelerate-blas is not in the inputs of f, so it wouldn't be built? as far as I can tell nothing else depends on it in haskellPackages
<sterni>
remexre: meta.position, but it is not always reliable
<sterni>
it mostly tells you where the meta.description or the name of the derivation was defined, but that can be pretty far away from the derivation in some cases
<sterni>
remexre: doesn't seem like it, you could nix-env -qaP -f path/to/nixpkgs --out-path and grep for the .drvs outpath then you'd have the attrpath of the derivation in nixpkgs
<sterni>
cinimod: oh right, must've read over it sorry
<toasty_avocado[m>
I just typed something in incorrectly 😅 and was questioning things.
fendor has joined #nixos
<karantan>
how can I use NIX_PATH that is defined in a nixpkgs.nix file? nixpkgs.nix file has this content: https://pastebin.com/mduzK5MG
fendor_ has quit [Ping timeout: 246 seconds]
<sterni>
cinimod: you need to use self / super properly inside the overrides I'm pretty sure accelerate and the other stuff are not picking up on each other
<conkker>
is there any plan on tagging binary packages in nixpkgs? Like packages that download binaries from somewhere else, instead of building from source. I feel insecure using them and it would be nice if I could disable them like `allowBinPkgs = false;`, similarly to `allowUnfree`
<simpson>
conkker: Why are binaries less secure than building from source? If you trust us to publish hashes for source code and compilers, why wouldn't you trust us to publish hashes for binaries? I grok your concern but I think that the threat model isn't quite aligned.
<simpson>
With that said, I do wish that we had the ability to ingest and verify signatures/hashes published by upstream providers of said binaries. I know that Triton, a nixpkgs fork, has some support for it; I don't think that we've adopted any of it though.
<conkker>
simpson It's harder to hide something malicious in source than binary, and I can at least build a source package myself if I want to, I can't do that with binary packages
<rippla>
Hi, can somebody help me get that expression right? I'm experimenting with getting that local let working instead of making a file wide one, but something is obviously wrong, it's complaining about the []
<cole-h>
Note that if you paste / send more than some amount of lines, you will get K-lined by freenode. Staff can undo that, but it's better to just paste in the first place.
<rippla>
will do in the future
* jess
wiggles undo button around
<cole-h>
hehe
<cole-h>
jess++
<{^_^}>
jess's karma got increased to 4
<cole-h>
rippla: that said, you want to remove the curly braces after `in`
grimvar has joined #nixos
<cole-h>
and that should work
karantan has quit [Quit: My MacBook has gone to sleep. ZZZzzz…]
<dutchie>
{} aren't block structure in nix, they create an attrset
<rippla>
oh I can't have multiple environment.systemPackages? I tried to split the unstable one from my other one
<rippla>
or is there a way to "add" the unstable one to my already existing declaration?
mallox has joined #nixos
<dutchie>
you should be able to, either by using ++ to concatenate them directly, or by defining it in separate Nixos modules and letting the module system merge them together
<cole-h>
Yeah, you can't have things declared with the same attr in the same file
<lovesegfault>
if I have a an attrset like { foo = someDrv; bar = otherDrv; ... } is there a handy way of creating a single derivation with `foo` and `bar` as separate outputs?
<dutchie>
the easiest way in this case is probably to just take your existing definition of environment.systemPackages and put `[ whatever it is] ++` inside the let
<lovesegfault>
so I can build `joined.foo` and `joined.bar` but if I just build `joined` I get `result-foo` and `result-bar`
grimvar has joined #nixos
<dutchie>
`environment.systemPackages = with pkgs; let unstable = ...; in [ old package list ] ++ [ unstable.terraform_0_14 ];`
<dutchie>
although at that point you may as well just put `unstable.terraform_0_14` into the main list
<cole-h>
lovesegfault: Not easily, I don't think...
<lovesegfault>
cole-h: :(
<cole-h>
You'd have to make something of your own :P
<lovesegfault>
nyah!
<cole-h>
Could probably base it off of `linkFarm`, though
<rippla>
ah cool, got it! thanks everyone :D
<dutchie>
the thing it's easy to forget if you aren't used to similar functional languages is that everything has a value
<lovesegfault>
cole-h: Maybe? looking at the linkFarm code I'm not sure
<rippla>
I dabbled in clojure a bit before
<rippla>
not quite used to nix's syntax yet
<lovesegfault>
idk if I can add extra outputs to runCommand
<cole-h>
lovesegfault: Isn't the stuff in the attr before the multiline string passed to mkDerivation?
<lovesegfault>
🤔
* lovesegfault
tries
ahmed_elgabri has quit [Ping timeout: 264 seconds]
justan0theruser has joined #nixos
<sterni>
cinimod: move everything into the overrides, use super instead of nixpkgs.haskellPackages and you need to use overrideCabal instead of overrideAttrs for haskellPackages unfortunately
<sterni>
cinimod: or overrideSrc in your case that can be found in pkgs.haskell.lib
justanotheruser has quit [Ping timeout: 265 seconds]
<sterni>
s1341_: where do you need a conditional override and depending on what?
John111 has joined #nixos
<s1341_>
sterni: i want to override the binutils.bintools derivation (or extend the existing override to include a src attribute) but only if hostPlatform.isAndroid.
<leothrix>
Hello! I read up on how to pin down my nixops setup to 20.09, so I have my nixpkgs pointed at a 20.09 revision in my nixops shell.nix. However, I tell nixops to deploy to a remote machine and now my laptop is building, like... everything (as in, glibc upwards). Can I check whether I should be getting stuff from cache.nixos.org?
<leothrix>
I'm not super nix-literate so there's a good chance I've got big gaps of knowledge here about how it should be working
<Reventlov>
I'm trying to use the module, it runs ok, but I have a small problem with something (namely, accessing the "account console" after running keycloak)
<talyz>
Reventlov: hi! yes, i do!
<Reventlov>
I was wondering if you had some hints on what could go wrong (my conf is very simple, i'll paste it in a few seconds)
<Reventlov>
and what I get is a 403 on some script when trying to go to the account console (I didn't configure anything else), so I guess something is broken in my conf or somewhere else
<{^_^}>
[nixpkgs] @svanderburg merged pull request #116455 → systemd: allow custom unit folders to be configured with SYSTEMD_UNIT… → https://github.com/NixOS/nixpkgs/pull/116455
sigtrm has quit [Remote host closed the connection]
Lord_of_Life has quit [Ping timeout: 264 seconds]
<talyz>
Reventlov: interesting, i haven't seen anything like that, but i can't see anything wrong with your config either
philr_ has joined #nixos
lordcirth has joined #nixos
simba1 has quit [Ping timeout: 256 seconds]
<talyz>
Reventlov: i haven't had time to properly test the latest version of keycloak yet, so it might be that it's problematic
<Reventlov>
hmmm, can I fallback to some old version ?
<jmercouris>
matthewcroughan_: the package is "ECL"
<jmercouris>
it is on version 16, currently there is version 21 available...
<jmercouris>
which quite some important fixes
<matthewcroughan_>
Search for it here, click source on the package, then the nix package will have a section where the maintainers are defined.
<matthewcroughan_>
the maintainers will probably be in this irc channel
<gchristensen>
matthewcroughan_: sure, I work with remote builders of aarch64 linux, x86_64 linux, aarch64 darwin, x86_64 darwin, armv7l linux, and other more exotic platforms
<jmercouris>
maybe I will make this change myself and make a package on my machine
<sterni>
jmercouris: you can always PR, I can review
<jmercouris>
sterni: I will consider, thank you
<jmercouris>
sterni: is your name on GitHub the same?
<sterni>
jmercouris: no more verbose, sternenseemann
<jmercouris>
sea star man
<sterni>
indeed
<sterni>
jmercouris: what channel are you on?
<jmercouris>
20.09
<sterni>
jmercouris: master already has 21.2.1
<sterni>
unstable probably as well
<jmercouris>
I see
<sterni>
is that release security related?
<sterni>
then we should backport
<jmercouris>
I do not believe so
<matthewcroughan_>
gchristensen: yes, but what about if your local machine is a pinebook and you want to use a remote x86 machine to cross-compile for your pinebook
<jmercouris>
I guess I can just install from unstable then
<jmercouris>
sterni: the closest I can find to a security concern is this: Random state initial state generation was buggy and insecure (entropy
<jmercouris>
from urandom was rejected)
<jmercouris>
I do not believe that qualifies as being significant enough
<sterni>
jmercouris: it will be in 21.05, but it won't come to 20.09
<jmercouris>
I see
<jmercouris>
and 21.05 will come out in May or later?
<jmercouris>
it's a serious question
<sterni>
jmercouris: stable releases are essentially forks of nixpkgs at some point in time (“branch-off”) and after that only critical™ stuff is applied
<tpw_rules>
jmercouris: because nix you can just download the default.nix and related files and create an overlay to use them
<jmercouris>
right, I'm using an overlay for Lisp packages
<jmercouris>
not sure exactly how it works, but I am using it
<sterni>
jmercouris: we are aiming for may, but it can always be delayed it is released when it's considered ready, i. e. stable enough
<jmercouris>
this Nix lang is a huge challenge for me to using Nix effectively
<madonius[m]>
o/
<madonius[m]>
has anyone a FIDO2 setup running in their nixos?
<Yaniel>
madonius[m]: `fido2luks credential` gave me a long alphanumeric string when I pressed the button on the key, I take it that's what it is supposed to do?
<Yaniel>
which nixos channel are you on?
<madonius[m]>
20.09
<Yaniel>
ah, I'm on unstable (well, actually git HEAD atm)
<ryantm>
cole-h: My only reservation is I haven't tried or reviewed it yet :(
<madonius[m]>
with ykman fido list
<madonius[m]>
I can see the cred I generated under debian
<ryantm>
cole-h: My PC is acting stable today after spending the weekend troubleshooting it, so that's a good sign :)
<madonius[m]>
which worked fine, btw
<matthewcroughan_>
gchristensen: remote builder is working out fine so far, thanks for that
<matthewcroughan_>
But my dream is to remote-cross-compile all the packages for armv7 so my crappy SBCs can be brought online.
konubinix has quit [Ping timeout: 264 seconds]
<matthewcroughan_>
do you recommend using qemu for this? or is there a way to do it with pkgsCross>gchristensen
<matthewcroughan_>
oh crap, autocompleted your name at the end
<Yaniel>
madonius[m]: I found some blog post setting up a yubikey for gpg and it says to put yubikey-personalization into environment.systemPackages rather than udev packages
<Yaniel>
ah no it does have it in both
<Yaniel>
did you reboot after adding that?
<madonius[m]>
yeah it's been there a long time
<Yaniel>
apparently you need to run udevadm or reboot in order for it to pick up the new rules
<madonius[m]>
the reason I added it was because the personalization tool did not recognise the yubikey
<madonius[m]>
I will try and report back
<sterni>
matthewcroughan_: I would love to use pkgsCross targeting gchristensen
<sterni>
not sure what for though
mcornick has joined #nixos
<cole-h>
ryantm: Ah, OK :) Just wanted to make sure it hadn't been forgotten (though I'm fine running with my branch for the moment)