IRC channel logs

2018-08-03.log

back to list of logs

<amz31>snape: what is your contribution about?
<amz31>guix edit woof?
<amz31>... works like a charm.
<snape>amz31: it was adding the 'woof' package, yes :-)
<amz31>snape: when you have at line 4232 what is the lexical scope of the execution of the begin form?
<amz31>line 4233 on my side
<pkill9>there's this neat script i want to use that takes a picture with the webcam and calculates the light intensity using opencv, and adjusts backlight brightness accordingly
<amz31>oh
<amz31>you speak with daviid in #guile
<amz31>s/speak/talk/
<amz31>he created a library to do image recognition in guile
<pkill9>oh cool
<pkill9>this script is a python script
<pkill9>i haven't talked to daviid
<amz31> https://www.gnu.org/software/guile-cv/
<amz31>pkill9: like everyone else he is busy but skilled
<pkill9>i found the script on this page undre 'screen brightness' http://www.tfiu.de/x240/
<pkill9>under*
<snape>amz31: it's a scheme expression that builds the package output(s). The package derivation refers to that builder.
<snape>so it's use at build time
<snape>used
<snape>see the output of 'guix build -d woof'
<amz31>tx
<amz31>that's the serialization of the parameters for the procedure to be executed by the build daemon via somekind of stored and trusted procedure
<amz31>the thing that make me tickle is the ' after the arguments
<snape>yes, it's just a list. The famous 'code is data'
<amz31>but then how is eval the data?
<amz31>via an environment or a sandbox?
<snape>amz31: see https://guix.info/manual/en/Derivations.html#Derivations
<snape>and have a look at a derivation (i.e. `guix build -d woof`)
<snape>the build is done in an environment, that is defined by the derivation
<amz31>that's the point where I get lost
<amz31>it mention gexp
<amz31>well i am tired, I need some sleep
<amz31>happy hacking
<snape>good night!
<amz31>!
<g_bor>Hello guix!
<snape>o/
<rekado_>Hello!
<rekado>Hello!
<rekado>(IRC is confusing)
<g_bor>rekado: Why is it so confusing?
<rekado>my account was renamed to “rekado_” and I could not simply change it with “/nick” as it said: “Cannot change nickname while banned on channel”
<rekado>bad error message, because I certainly wasn’t banned.
<rekado>oof… I may not be able to get around packaging mozjs-52 :(
<rekado>gjs also depends on it now.
<rekado>bleh.
<rekado>this means that the GNOME upgrades will take even longer.
<efraim>Fun times :(
<roptat>hi guix!
<pkill9>don't suppose anyone knows how to make an acpi call?
<rekado>pkill9: can you give more context?
<pkill9>rekado: I want to force my thinkpad's internal battery to discharge when the external battery reaches 40%, however there's isn't a /sys interface for it out of the box (there is for setting battery charigng thresholds though). However, I think it's possible because this kernel module i found called 'tpacpi-bat' claims to support forcing battery discharging, and it uses the 'acpi_call' kernel module (neither of
<pkill9>which are in the linux kernel). Since it's a hassle trying to add kernel modules to the linux build tree and test it, then recompile it if/when it fails, and I only want to use a couple ACPI calls, then I wondered if I could make the neccessary acpi calls without tpacpi-bat or acpi_call, i.e. without adding any kernel modules to the linux build tree
<pkill9>this is tpacpi-bat: https://github.com/teleshoes/tpacpi-bat
<pkill9>and this is acpi_call: https://github.com/mkottman/acpi_call
<pkill9>really best option would be to learn how to buid linux kernel with additional modules, but i feel like I'm blindly doing it by trial and error lol
<rekado>you really don’t have to add module sources to the kernel tree to use extra modules in GuixSD.
<rekado>The fuse package, for example, provides a kernel module.
<rekado>you can add that package and then just use that module
<rekado>I don’t understand why it would not work for any other kernel module.
<rekado>you don’t have to rebuild the kernel just to add modules.
<pkill9>oh ok
<pkill9>i'm a noob when it comes to kernel stuff
<pkill9>i'll see how the fuse package does it
<pkill9>rekado: how could i compile and use acpi_call?
<snape>rekado: fuse.ko is provided by linux-libre
<snape>pkill9: you can compile the module like any other package, and then use "modprobe --dirname=DIR" I guess, to load it
<snape>I don't think loading a module from a custom directory is supported by GuixSD
<snape>I meant having that custom module in config.scm
<pkill9>i need the build tree to compile it :<
<snape>pkill9: you can get it to depend on linux-libre can't you?
<pkill9>what do you mean?
<snape>did you mean the 'linux-libre' build tree?
<pkill9>yeah
<pkill9>where /run/current-system/kernel/lib/module/4.x.x/build would be
<snape>pkill9: I don't know
<snape>you could use package-source if you need the source, maybe
<snape>or linux-libre-headers
<snape>if you need the headers
<snape>I have no idea how to use 'package-source' though
<snape>I meant (package-source linux-libre)
<pkill9>yeha probalby, my issue isn't actually in making the package definition, just manually compiling the kernel lol
<pkill9>i'm new to working with the kernel
<snape>you shouldn't manually compile it, you should use the Guix package definition
<mbakke>rekado: What were the problems with MozJS 52? Rust?
<pkill9>snape: i think actually i only need the headers
<snape>pkill9: then it's probably easier, just add linux-libre-headers to the inputs of your package
<pkill9>i'm trying to build it with gcc in a guix environment but it's not working
<pkill9>doens't find the headers
<pkill9>including when i set path using -B or --sysroot
<snape>pkill9: are you using the gnu-build-system?
<cryptocat1094>Is there a particular reason that's no armhf image?
<pkill9>snape: i'm using gcc in `guix environment --ad-hoc gcc-toolchain make`
<snape>cryptocat1094: because each board has its own particularities I think
<pkill9>although i'm not using make
<pkill9>hmm i'll try -include
<rekado>mbakke: the first problem I have is that there does not seem to be a release tarball.
<rekado>mbakke: the spidermonkey website directs me to what looks like their continuous integration system.
<rekado>from there I’m supposed to pick any(?) commit of the whole mozilla 52 release branch.
<rekado>I don’t really want to do this, but I guess I’ll have to investigate more.
<pkill9>okay that worked
<pkill9>meh acpi_call i think is out of date and i don't know C well enough to update it
<mbakke>rekado: Yes, I think we just have to choose a snapshot.
<mbakke>That's what Debian does.
<mbakke> https://treeherder.mozilla.org/#/jobs?repo=mozilla-esr52&filter-searchStr=sm-tc
<mbakke>I looked into updating polkit as well due to the recent CVEs, but did not get much further with MozJS :/
<mbakke>Looks like I gave up wrangling configure.py in my branch, will give it another go.
<mbakke>rekado: If you do manage to get it working, please update polkit in 'master'!
<rekado>mbakke: I tried to get around updating polkit :)
<rekado>I needed the latest polkit for its polkit.its file, but then noticed that it needs mozjs-52, so I worked around it.
<mbakke>Heh.
<mbakke>Our current PolKit has a few security problems as well, so we really should fix it properly.
<rekado>Yeah.
<rekado>I’ll try building mozjs tonight.
<rekado>do you have something I could base my work on?
<cryptocat1094>snape: Hm, I guess makes sense, though there could be some for generic bootloaders like U-Boot which seems to be used for a large number of SoCs.
<mbakke>rekado: Not really, I just tried it and it fails at the configure stage: https://paste.debian.net/1036557/
<rekado>mbakke: thanks!
<rekado>(we could use hg-fetch here)
<mbakke>rekado: The Debian package is probably more useful: https://salsa.debian.org/gnome-team/mozjs52/tree/debian/master/debian
<rekado>mbakke: yes, I’ll use that instead.
<mbakke>I'm playing around with it, apparently it requires Autoconf 2.13 specifically -- however that autoconf does not support the --output argument.
<mbakke>How to do shell redirection in Scheme? :)
<mbakke>I've done something similar with open-pipe* in the past.
<mbakke>But it's not pretty.
<tune>if I want to build a package for something not in the repos, what part of the documentation should I look at?
<tune>a lot of software I want isn't packaged and I've waited many months, so I guess no one else wants this software and I'll have to [try to] figure it out myself
<mbakke>tune: I'd recommend the "contributing" section and send patches for the software you need.
<mbakke>If you don't want or can't redistribute the packages, check out GUIX_PACKAGE_PATH, where you can place custom package definitions.
<RetardedOnion>tune: like this? https://www.gnu.org/software/guix/manual/en/html_node/Defining-Packages.html
<brendyyn>tune: It's wrong to say that nobody wants it. It takes a lot of time and effort.
<tune>RetardedOnion: yes I think this is what I wanted
<brendyyn>since the beginning of the project, 7800+ packages have been made, and there are tens of thousands of more useful ones
<tune>I found someone's deluge recipe and tried to get it working, but it was out of date or something. didn't work by the time I figured out how to use it
<tune>and I've got a dozen more things besides deluge I wish were packaged
<brendyyn>Start packaging them then and they will be included
<tune>kinda doubt I'll be able to figure this out but I at least wanted to know where to look for how to do it
<brendyyn>I can help
<RetardedOnion>the contributions are probably not as easy. i have seen polybar more than once and i think its gpl. it might have a reason why packages arent always there.
<pkill9>tune: i look at other packages
<tune>hm polybar is one of the things in my list
<tune>(of things I wish were packaged)
<pkill9>i make packages but don't submit them, tho i intend to
<pkill9>tune: i made a package definition for polybar
<tune>yeah I was thinking of doing the local package thing first and seeing if I can get anything working
<pkill9>i'lll giv eyou a link
<tune>sweet
<RetardedOnion>pkill9: i saw you did polybar and zim. i really wish those were submitted
<tune>brendyyn: thanks for the offer, might take you up on that later. just woke up so I'm gonna probably eat and such before I try this
<RetardedOnion>tune: https://gitlab.com/pkill-9/guix-packages/blob/master/free/polybar.scm here it is
<pkill9>you beat me to it
<brendyyn>tune: It's almost bed time for me here in australia
<tune>ah alright
<pkill9>i did add a little patch to it to put the title before artist in the mpd plugin
<RetardedOnion>pkill9: my dead taught me how to beat
<brendyyn>I think next I'm going to package fcitx plugins
<pkill9>the zim test phase currently doesn't work because it doesn't fail when a test fails
<pkill9>i think the python file that runs the tests doesn't return non-zero when a unit test fails
<pkill9>why does linux-libre-headers not have the 'linux/proc_fs.h' header file?
<jlicht>'ello guix
<pkill9_>okay, tpacpi-bat is a simple perl script, but it needs acpi_call, and I think it just hasn'tbeen updated for newer kernel or something
<RetardedOnion>pkill9_: if you get into it, will you be doing tp_smapi as well?
<pkill9_>maybe
<pkill9_>still need to give acpi_call the headers it wants
<RetardedOnion>pkill9_: thanks for your work
<pkill9_>you're welcome :)
<cryptocat1094>What should I do to fix this command: guix system disk-image --target=armhf-linux-gnu --system=armhf-linux -e '((@ (gnu system install) os-with-u-boot) (@ (gnu system install) installation-os) "thisshouldbeanerror")'
<cryptocat1094>It fails at the point where it notices I'm not currently on an armhf. I'm wondering if there's a way to cross-compile without using an intermediary VM.
<cryptocat1094>(Or if Guix can take care of the provisioning and tear-down by itself)
<brendyyn>cryptocat1094: https://www.gnu.org/software/guix/manual/en/html_node/Virtualization-Services.html
<brendyyn>scroll to the bottom. it might help you
<cryptocat1094>brendyyn: In theory, this provides the raw magic I'd need. Now I'd need to see just how hard it'd be to glue it to `guix system` invocations.
<cryptocat1094>(Or if it'd just work straight out of the box)
<rekado>I have a build of mozjs-52.
<rekado>tests fail, but that seems to be expected.
<mbakke>rekado: Wooow :-)
<rekado>not as bad as I expected
<rekado>mbakke: I sent it to guix-patches and Cc to you. Feel free to apply it and update polkit.
<amz31>sneek_: regarding the piece of code we were discussing late last night, I don't understand why it's not '#:builder (lamda (out %build-inputs %outputs) ...) instead of '#:builder (begin ...) with the current from the lexical environment is very difficiult to guess without diving into of how that particular piece of code is called
<amz31>meh
<amz31>sneek_: botsnake
<amz31>mhhh
<amz31>rekado: what do you think about using an algorithm that must be trained to help fight spam?
<amz31>honestly
<cryptocat1094>What user does the Guix Offload facility need over SSH?
<cryptocat1094>The examples "bob" and "alice" suggest it's entirely up to me. Is that so
<cryptocat1094>?
<rekado>cryptocat1094: it’s up to you, but you need to specify the user in the machine configuration.
<rekado>amz31: re spam: this seems like too much effort. I would not use my time for something like that.
<jlicht>does anybody know where to find the sources for ssh-askpass? The homepage presented by both arch and nixpkgs is not reachable; http://www.jmknoble.net/software/x11-ssh-askpass/
<rekado>jlicht: have you tried the web.archive.org?
<cryptocat1094>Project page is gone? That's no good.
<jlicht>rekado: I have not, but it works! I'm not quite sure which of the myriad of ssh-askpass implementations is "the right one", but I can figure it out from there
<mbakke>I want to download a patch from a HTTP endpoint that only returns base64 and use it for a package source.
<mbakke>(patches (base64-decode (origin ...))) did not work very well. Any ideas?
<mbakke>^ That should be (patches (list (base64-decode (origin ...)))).
<jlicht>mbakke: you could put it in the guix source tree
<mbakke>jlicht: That's boring!
<jlicht>it is, isn't it :)
<mbakke>Let's say I want to download 100 giant patches from this endpoint :-)
<jlicht>then you'd still need to do that manually so you can properly verify the contents and hashes of these patches :P
<jlicht>you could see base64 encoding as some form of distributing content that requires an extraction phase, right? (even though here the extracted content would likely be smaller...)
<jlicht>so an again boring way to do this is to introduce a base64-fetch kind-of-thing
<mbakke>jlicht: I suspect a 'url-fetch/base64' is the right way to go indeed. Probably overkill for one package though.
<mbakke>I'll just add a patching phase for this case.
<jlicht>makes sense. It would be nice to have some form of composability in cases like these
***astronavt__ is now known as astronavt
<amz31>I like to see emacs improve over time
<amz31>not sure if it's my fault ;]
<OriansJ>amz31: do you remember to scrub and reduce your emacs config?
<amz31>my .emacs 500 lines
<amz31>i've been doing that for my personnal project, reboot the projet as way to scrub things.
<amz31>s/project/projects/
<OrangeShark>amz31: so reboot emacs in Guile? :)
<amz31>it's painful, I'd like to have a single project, I leave behind some errors, because I don't have time to fix them
<amz31>OrangeShark: https://framagit.org/a-guile-mind/azul/blob/master/editor/azul.scm
<amz31>I dream of a monorepo
<OrangeShark>amz31: oh right, I remember you posting that before :P
<amz31>but I did not commit to it for 1 year now
<amz31>also no guix integration
<OrangeShark>amz31: I wonder if it would be a good idea to reboot emacsy
<amz31>the graphical part of things is not clear to me, I mean what engine is best. that said the ux is different of what I have in mind
<amz31>I mean you have some kind of codified language that we use in emacs, but in the end I think there is an under appreciated natural language query engine that can use things like the 20 questions that can nail down queries to actual, say gnu commands
<Formbi>OrangeShark: there is a Guile Emacs
<Formbi>but it doesn't really work
<Formbi>see guile-emacs in Guix
<Formbi>basic stuff works, but it segfaults on ERC and probably some other things
<jlicht>OrangeShark: I recently tried to get emacsy to work in rust programs! (Not much success yet)
<jlicht>amz31: what is a monorepo?
<amz31>for instance in a monorepo philosophy, cuirass/ would be in guix.git repository
<cbaines>Looks like Savannah's cgit is down, which means that guix pull doesn't work...
<cbaines>It must either be working now, or intermittent, as I'm now guix pull'ing...
<amz31>jlicht: it's a single code base for a community
<amz31>I can't build cuirass test take very long time and various failures