Packaging Next browser (Common Lisp) [work in progress]

DoneSubmitted by Pierre Neidhardt.
Details
3 participants
  • Andy Patterson
  • Pierre Neidhardt
  • Pierre Neidhardt
Owner
unassigned
Severity
normal
P
P
Pierre Neidhardt wrote on 19 Sep 2018 09:15
(address . bug-guix@gnu.org)
87o9cuez56.fsf@ambrevar.xyz
I've started working on packaging a collection of Common Lispdependencies for Next browser:
http://next.atlas.engineer/
My progress can be found on the wip-next-browser branch.
-- Pierre Neidhardthttps://ambrevar.xyz/
-----BEGIN PGP SIGNATURE-----
iQEzBAEBCAAdFiEEUPM+LlsMPZAEJKvom9z0l6S7zH8FAluh95UACgkQm9z0l6S7zH//ogf+OIznYHNER9afqbT9+5t1fQsFJ/OqGTjTc5Vwj55Ebb67HqZtOVMoJYs1fy0NMAKdoCWdeRhmpKdlw/oPl99gD4tjygHhoxOPz7t97sR18b4fQTt5pV6iZWITAkOMuEUbhRjQFJZHdQ2vufVN/cy6/QiNCDN8epJjq7nlcduZDfbs1etCdL4CwPhUAOMP9ljPkFLyixlDyEvKTKJ8GF3WPX3hYAV0O6o7GEp5hJRiy+2kq7O4Dr4V4kY5h1fTtHOUOTVk6elqtxLpt3HhAKqgiS56oJhFJUKBA48cmf9NW71sC5B4h1Fvfh6PwOb+XzGaFz3yjwviwjKGtv8N149JQQ===yLP+-----END PGP SIGNATURE-----
P
P
Pierre Neidhardt wrote on 10 Oct 2018 15:21
(address . 32769@debbugs.gnu.org)(name . Andy Patterson)(address . ajpatter@uwaterloo.ca)
87va6a7x9l.fsf@ambrevar.xyz
The good news: all Next browser dependencies are now packaged under thebranch wip-nextbrowser.
The bad news: Next browser fails to build.
Toggle snippet (117 lines); compiling file "/gnu/store/39vh5ghdn9x7zwb6ky7law678wkz20l2-next-browser-0.0.8-1.ccc289b/share/common-lisp/sbcl-source/next/gtk/next/source/document-mode.lisp" (written 10 OCT 2018 01:12:05 PM):; compiling (IN-PACKAGE :NEXT); compiling (DEFVAR *DOCUMENT-MODE-MAP* ...); compiling (DEFCLASS DOCUMENT-MODE ...); compiling (DEFPARENSTATIC SCROLL-TO-TOP ...); compiling (DEFPARENSTATIC SCROLL-TO-BOTTOM ...); compiling (DEFPARENSTATIC SCROLL-DOWN ...); compiling (DEFPARENSTATIC SCROLL-UP ...); compiling (DEFPARENSTATIC SCROLL-LEFT ...); compiling (DEFPARENSTATIC SCROLL-RIGHT ...); compiling (DEFUN ENSURE-ZOOM-RATIO-RANGE ...); compiling (DEFPAREN %ZOOM-IN-PAGE ...); compiling (DEFINE-COMMAND ZOOM-IN-PAGE ...); compiling (DEFPAREN %ZOOM-OUT-PAGE ...); compiling (DEFINE-COMMAND ZOOM-OUT-PAGE ...); compiling (DEFPAREN %UNZOOM-PAGE ...); compiling (DEFINE-COMMAND UNZOOM-PAGE ...); compiling (DEFINE-COMMAND HISTORY-BACKWARDS ...); compiling (DEFINE-COMMAND HISTORY-FORWARDS ...); compiling (DEFUN HISTORY-FOWARDS-QUERY-COMPLETE ...); compiling (DEFINE-COMMAND HISTORY-FORWARDS-QUERY ...); compiling (DEFUN ADD-OR-TRAVERSE-HISTORY ...); compiling (DEFINE-COMMAND SET-URL-NEW-BUFFER ...); compiling (DEFUN SET-URL-BUFFER ...); compiling (DEFUN SET-URL-NEW-BUFFER ...); file: /gnu/store/39vh5ghdn9x7zwb6ky7law678wkz20l2-next-browser-0.0.8-1.ccc289b/share/common-lisp/sbcl-source/next/gtk/next/source/document-mode.lisp; in: DEFUN SET-URL-NEW-BUFFER; (DEFUN NEXT::SET-URL-NEW-BUFFER; (NEXT::INPUT-URL &OPTIONAL NEXT::DISABLE-HISTORY); (LET ((NEXT::NEW-BUFFER (NEXT::GENERATE-NEW-BUFFER "default" #))); (NEXT::SET-VISIBLE-ACTIVE-BUFFER NEXT::NEW-BUFFER); (NEXT::SET-URL-BUFFER NEXT::INPUT-URL NEXT::NEW-BUFFER; NEXT::DISABLE-HISTORY))); --> PROGN; ==>; (EVAL-WHEN (:COMPILE-TOPLEVEL); (SB-C:%COMPILER-DEFUN 'NEXT::SET-URL-NEW-BUFFER NIL T));; caught WARNING:; Duplicate definition for SET-URL-NEW-BUFFER found in one file.; See also:; The ANSI Standard, Section 3.2.2.3
; compiling (DEFUN SETUP-URL ...); compiling (DEFUN SET-URL ...); compiling (DEFINE-COMMAND SET-URL-CURRENT-BUFFER ...); compiling (DEFINE-COMMAND SET-URL-FROM-BOOKMARK ...); compiling (DEFUN SETUP-ANCHOR ...); compiling (DEFINE-COMMAND GO-ANCHOR ...); compiling (DEFINE-COMMAND GO-ANCHOR-NEW-BUFFER ...); compiling (DEFINE-COMMAND GO-ANCHOR-NEW-BUFFER-FOCUS ...); compiling (DEFUN DOCUMENT-MODE ...); compiling (DEFMETHOD SETUP ...)
; /gnu/store/39vh5ghdn9x7zwb6ky7law678wkz20l2-next-browser-0.0.8-1.ccc289b/lib/sbcl/next/source/document-mode-tmpOPCILR65.fasl written; compilation finished in 0:00:00.058Unhandled UIOP/LISP-BUILD:COMPILE-FILE-ERROR in thread #<SB-THREAD:THREAD "main thread" RUNNING {10005585B3}>: COMPILE-FILE-ERROR while compiling #<CL-SOURCE-FILE "next" "document-mode">
Backtrace for: #<SB-THREAD:THREAD "main thread" RUNNING {10005585B3}>0: (SB-DEBUG::DEBUGGER-DISABLED-HOOK #<UIOP/LISP-BUILD:COMPILE-FILE-ERROR {1004DDACA3}> #<unused argument> :QUIT T)1: (SB-DEBUG::RUN-HOOK *INVOKE-DEBUGGER-HOOK* #<UIOP/LISP-BUILD:COMPILE-FILE-ERROR {1004DDACA3}>)2: (INVOKE-DEBUGGER #<UIOP/LISP-BUILD:COMPILE-FILE-ERROR {1004DDACA3}>)3: (ERROR UIOP/LISP-BUILD:COMPILE-FILE-ERROR :CONTEXT-FORMAT "~/asdf-action::format-action/" :CONTEXT-ARGUMENTS ((#<ASDF/LISP-ACTION:COMPILE-OP > . #<ASDF/LISP-ACTION:CL-SOURCE-FILE "next" "document-mode">)))4: (UIOP/LISP-BUILD:CHECK-LISP-COMPILE-RESULTS NIL T T "~/asdf-action::format-action/" ((#<ASDF/LISP-ACTION:COMPILE-OP > . #<ASDF/LISP-ACTION:CL-SOURCE-FILE "next" "document-mode">)))5: ((SB-PCL::EMF ASDF/ACTION:PERFORM) #<unused argument> #<unused argument> #<ASDF/LISP-ACTION:COMPILE-OP > #<ASDF/LISP-ACTION:CL-SOURCE-FILE "next" "document-mode">)6: ((LAMBDA NIL :IN ASDF/ACTION:CALL-WHILE-VISITING-ACTION))7: ((:METHOD ASDF/ACTION:PERFORM-WITH-RESTARTS :AROUND (T T)) #<ASDF/LISP-ACTION:COMPILE-OP > #<ASDF/LISP-ACTION:CL-SOURCE-FILE "next" "document-mode">) [fast-method]8: ((:METHOD ASDF/PLAN:PERFORM-PLAN (T)) #<ASDF/PLAN:SEQUENTIAL-PLAN {1002497DE3}>) [fast-method]9: ((FLET SB-C::WITH-IT :IN SB-C::%WITH-COMPILATION-UNIT))10: ((:METHOD ASDF/PLAN:PERFORM-PLAN :AROUND (T)) #<ASDF/PLAN:SEQUENTIAL-PLAN {1002497DE3}>) [fast-method]11: ((:METHOD ASDF/OPERATE:OPERATE (ASDF/OPERATION:OPERATION ASDF/COMPONENT:COMPONENT)) #<ASDF/BUNDLE:COMPILE-BUNDLE-OP > #<ASDF/SYSTEM:SYSTEM "next/gtk"> :PLAN-CLASS NIL :PLAN-OPTIONS NIL) [fast-method]12: ((SB-PCL::EMF ASDF/OPERATE:OPERATE) #<unused argument> #<unused argument> #<ASDF/BUNDLE:COMPILE-BUNDLE-OP > #<ASDF/SYSTEM:SYSTEM "next/gtk">)13: ((LAMBDA NIL :IN ASDF/OPERATE:OPERATE))14: ((:METHOD ASDF/OPERATE:OPERATE :AROUND (T T)) #<ASDF/BUNDLE:COMPILE-BUNDLE-OP > #<ASDF/SYSTEM:SYSTEM "next/gtk">) [fast-method]15: ((SB-PCL::EMF ASDF/OPERATE:OPERATE) #<unused argument> #<unused argument> ASDF/BUNDLE:COMPILE-BUNDLE-OP "next/gtk")16: ((LAMBDA NIL :IN ASDF/OPERATE:OPERATE))17: ((:METHOD ASDF/OPERATE:OPERATE :AROUND (T T)) ASDF/BUNDLE:COMPILE-BUNDLE-OP "next/gtk") [fast-method]18: (ASDF/SESSION:CALL-WITH-ASDF-SESSION #<CLOSURE (LAMBDA NIL :IN ASDF/OPERATE:OPERATE) {1002351FBB}> :OVERRIDE T :KEY NIL :OVERRIDE-CACHE T :OVERRIDE-FORCING NIL)19: ((LAMBDA NIL :IN ASDF/OPERATE:OPERATE))20: (ASDF/SESSION:CALL-WITH-ASDF-SESSION #<CLOSURE (LAMBDA NIL :IN ASDF/OPERATE:OPERATE) {1004329D1B}> :OVERRIDE NIL :KEY NIL :OVERRIDE-CACHE NIL :OVERRIDE-FORCING NIL)21: ((:METHOD ASDF/OPERATE:OPERATE :AROUND (T T)) ASDF/BUNDLE:COMPILE-BUNDLE-OP "next/gtk") [fast-method]22: (SB-INT:SIMPLE-EVAL-IN-LEXENV (ASDF/OPERATE:OPERATE (QUOTE ASDF/BUNDLE:COMPILE-BUNDLE-OP) "next/gtk") #<NULL-LEXENV>)23: (EVAL (ASDF/OPERATE:OPERATE (QUOTE ASDF/BUNDLE:COMPILE-BUNDLE-OP) "next/gtk"))24: (SB-IMPL::PROCESS-EVAL/LOAD-OPTIONS ((:EVAL . "(require :asdf)") (:EVAL . "(let ((*package* (find-package :asdf))) (load \"/gnu/store/39vh5ghdn9x7zwb6ky7law678wkz20l2-next-browser-0.0.8-1.ccc289b/share/common-lisp/sbcl-source/next/gtk/next/next.asd\"))") (:EVAL . "(asdf:operate (quote asdf:compile-bundle-op) \"next/gtk\")") (:QUIT)))25: (SB-IMPL::TOPLEVEL-INIT)26: ((FLET SB-UNIX::BODY :IN SAVE-LISP-AND-DIE))27: ((FLET "WITHOUT-INTERRUPTS-BODY-27" :IN SAVE-LISP-AND-DIE))28: ((LABELS SB-IMPL::RESTART-LISP :IN SAVE-LISP-AND-DIE))
unhandled condition in --disable-debugger mode, quitting;; compilation unit aborted; caught 1 fatal ERROR condition; caught 1 WARNING condition; caught 8 STYLE-WARNING conditionsBacktrace: 7 (primitive-load "/gnu/store/6v5dy1rnk8m3h154q4c8mjwgq7y…")In ice-9/eval.scm: 191:35 6 (_ _)In ice-9/boot-9.scm: 152:2 5 (with-fluid* _ _ _) 152:2 4 (with-fluid* _ _ _)In srfi/srfi-1.scm: 640:9 3 (for-each #<procedure 98e3a0 at /gnu/store/k4nbgbgygrv…> …)In /gnu/store/k4nbgbgygrv0lk97d5phx8fwrxr0ah9r-module-import/guix/build/gnu-build-system.scm: 799:31 2 (_ _)In /gnu/store/k4nbgbgygrv0lk97d5phx8fwrxr0ah9r-module-import/guix/build/asdf-build-system.scm: 124:4 1 (build #:outputs _ #:inputs _ #:asd-file _ # _)In unknown file: 0 (scm-error misc-error #f "~A ~S ~S" ("lisp-eval-pro…" …) …)
ERROR: In procedure scm-error:lisp-eval-program failed! "/gnu/store/rdvy6q3nskb0r01rwjrxj3935d850r2d-sbcl-1.4.4/bin/sbcl" ((require :asdf) (let ((*package* (find-package :asdf))) (load "/gnu/store/39vh5ghdn9x7zwb6ky7law678wkz20l2-next-browser-0.0.8-1.ccc289b/share/common-lisp/sbcl-source/next/gtk/next/next.asd")) (asdf:operate (quote asdf:compile-bundle-op) "next/gtk"))
Andy, any clue on this?
--Pierre Neidhardthttps://ambrevar.xyz/
-----BEGIN PGP SIGNATURE-----
iQEzBAEBCAAdFiEEUPM+LlsMPZAEJKvom9z0l6S7zH8FAlu9/NYACgkQm9z0l6S7zH9jFQf6A5kY0Qiu2nrj/sKPcYtk5sbqHwAhxYd9h+koMg0X8HG1f4/eO0+H0DZzwbPQNLB7KdedqHRHWn6yCXutbuwXOKBDsCaCN7eeAuO9t8MTLraB4AA6aGGSVFe5OLnhRzK9YPq32L6cM86lSwHfXDBjXdCnk/eGkj9SHPjD0gTkCSWsWqwmyn4avvLqObq2AWLzGwB/kWjSk1BxdlHEXafFrWOyn0cNYZTesiXs8looAzWtP1+9HtOVAGYC103O2WwEQF8fPnaAnHuah2XinnQK+mavNpLMqP8JS6Dn3xTKhnGpbIrtBXDqqOfTRUqCKg/PXbGEb08qLGbxKKcj1g9p5g===QX1p-----END PGP SIGNATURE-----
A
A
Andy Patterson wrote on 11 Oct 2018 09:16
(name . Pierre Neidhardt)(address . mail@ambrevar.xyz)(address . 32769@debbugs.gnu.org)
20181011031649.5863f9a8@mailservices.uwaterloo.ca
Hi,
On Wed, 10 Oct 2018 15:21:26 +0200Pierre Neidhardt <mail@ambrevar.xyz> wrote:
Toggle quote (9 lines)> The good news: all Next browser dependencies are now packaged under> the branch wip-nextbrowser.> > The bad news: Next browser fails to build.> > [...]> > Andy, any clue on this?
It's probably the
Toggle quote (3 lines)> ; caught WARNING:> ; Duplicate definition for SET-URL-NEW-BUFFER found in one file.
since sbcl (at least on guix?) treats some warnings as errors for somereason.
Hoping that helps,
--Andy
P
P
Pierre Neidhardt wrote on 11 Oct 2018 10:50
(name . Andy Patterson)(address . ajpatter@uwaterloo.ca)(address . 32769@debbugs.gnu.org)
87va68uatd.fsf@ambrevar.xyz
I'll try this. Note that Next builds fine via Quicklisp. Any idea why?
-- Pierre Neidhardthttps://ambrevar.xyz/
-----BEGIN PGP SIGNATURE-----
iQEzBAEBCAAdFiEEUPM+LlsMPZAEJKvom9z0l6S7zH8FAlu/Dr4ACgkQm9z0l6S7zH9kTAf/Wuh9FuwdCB1zqTnjsyHGiUgRgr9YEgzAW4dbuEizQhNWkpnq97PLJw8Gc0tydv9NIYFVPiKngwL8Eoiu6umYKusih9bpZRIvxwMovtV9zDQAgopMmhTwFkrz1I4bUo9r+pFzkNW9fA1LRHLc+R+rWdBvaJ7hnpznYrWKffdNXLx3dB7b4JbYVpMK02hAkiPVwnABDAF1kH7WotUbvrtvYaXDE+9SMRnj6fBZc/jPXv73/NhSy9qW3gXbkLfEVsVXSKKinm0ZmwTbwVqhzq/KCTLZVo5PGZuJU8rrbu7Pr1GSvbDbbjLdhTYMTZ9e96GhbAVxXFKHhvO2ZSEX1WUlWA===14IF-----END PGP SIGNATURE-----
P
P
Pierre Neidhardt wrote on 11 Oct 2018 12:44
(name . Andy Patterson)(address . ajpatter@uwaterloo.ca)(address . 32769@debbugs.gnu.org)
87sh1cu5ic.fsf@ambrevar.xyz
You were right, this was the issue. I've posted a patch upstream, it should befixed soon.
Now Next compiles. Hurray!!! :D
There is one last step though: the .asd bunble works, but not the"build-program".See the wip-nextbrowser for what I've tried. I've re-used the code fromStumpwm.
I narrowed down the issue to the "generate-executable" function:
Toggle snippet (19 lines)define* (generate-executable out-file #:key dependencies dependency-prefixes entry-program type #:allow-other-keys) "Generate an executable by using asdf operation TYPE, containing whithin theimage all DEPENDENCIES, and running ENTRY-PROGRAM in the case of anexecutable. Link in any asd files from DEPENDENCY-PREFIXES to ensurereferences to those libraries are retained." let* ((bin-directory (dirname out-file)) (name (basename out-file))) (mkdir-p bin-directory) (with-directory-excursion bin-directory (generate-executable-wrapper-system name dependencies) (generate-executable-entry-point name entry-program)) ...
The problem is that Next's system is called "next/gtk", but we cannot use thatas an out-file. If I use something else, say "next", then compilation failswith
Toggle snippet (3 lines) Component :NEXT not found, required by #<SYSTEM "next-exec">
I guess there is a flaw in the logic here. The system name should be
#:asd-system-name
and not
(name (basename out-file))
What shall we do?
-- Pierre Neidhardthttps://ambrevar.xyz/
-----BEGIN PGP SIGNATURE-----
iQEzBAEBCAAdFiEEUPM+LlsMPZAEJKvom9z0l6S7zH8FAlu/KZsACgkQm9z0l6S7zH8oVwgAhblptWhgLpVnW9+gu4wsaecbHdzliU+5ogyDBUmo/ikvKnLy/mCcLaumtTDzV0N4eRsv34Fjorj4ogRO6NOacwPE7ylkfPA+ROQ3Fcm3FvUNNALd/IeSVkCliQa054LZ1oGfzPOaaqrRLzFSLL/m3aLFVvgPPg746Ty4kwUmO+a1FykdSRllpOuKN5sUiwUVLmtk7NERk7xj3jM9O0ubVBPKIgxonWjmi1sZtzD3CspBEVxYLvHAIOwPjhklWMiSd5oF0mk1dSEyHSHDlwPOiDDuX9aEJ3tyL5pC7oNiFhOgd1lVthfmKGZJIwEj3xt7fcUyQOce9mlkIupa2xkU7Q===61Hg-----END PGP SIGNATURE-----
A
A
Andy Patterson wrote on 12 Oct 2018 07:51
(name . Pierre Neidhardt)(address . mail@ambrevar.xyz)(address . 32769@debbugs.gnu.org)
20181012015120.686812a8@mailservices.uwaterloo.ca
Hi Pierre,
On Thu, 11 Oct 2018 12:44:43 +0200Pierre Neidhardt <mail@ambrevar.xyz> wrote:
Toggle quote (5 lines)> You were right, this was the issue. I've posted a patch upstream, it> should be fixed soon.> > Now Next compiles. Hurray!!! :D
Nice.
Toggle quote (29 lines)> > There is one last step though: the .asd bunble works, but not the> "build-program".> See the wip-nextbrowser for what I've tried. I've re-used the code> from Stumpwm.> > I narrowed down the issue to the "generate-executable" function:> > [...]> > The problem is that Next's system is called "next/gtk", but we cannot> use that as an out-file. If I use something else, say "next", then> compilation fails with> > --8<---------------cut here---------------start------------->8---> Component :NEXT not found, required by #<SYSTEM "next-exec">> --8<---------------cut here---------------end--------------->8---> > I guess there is a flaw in the logic here. The system name should be> > #:asd-system-name> > and not> > (name (basename out-file))> > What shall we do?>
That seems right. I guess we'll need to update that and then maybealso normalize the generated asd. Doesn't seem like it'd be toodifficult; there just weren't enough examples of program-generatingsystems for this to get caught.
Thanks for the update,
--Andy
P
P
Pierre Neidhardt wrote on 12 Oct 2018 08:44
(name . Andy Patterson)(address . ajpatter@uwaterloo.ca)(address . 32769@debbugs.gnu.org)
87ftxbslyk.fsf@ambrevar.xyz
Let me know if you'd like to do it or if I should give it a shot :)
-- Pierre Neidhardthttps://ambrevar.xyz/
-----BEGIN PGP SIGNATURE-----
iQEzBAEBCAAdFiEEUPM+LlsMPZAEJKvom9z0l6S7zH8FAlvAQtMACgkQm9z0l6S7zH8OXwf+MxTGSBlRxURaFs+nSlOn+1Dzzln2n/FR6fD7CZZpZgpB7eZhX6zJNSBWI8rjmjDAbWzkKCbgk9c8BXUgDfjwVydwEu7TWMLseXAeFscnhRAuHZYqKrYbJz44VzNBPtvI92qk8YQzQ8B3zcggujCnnsihTmWqzj/h4OgI12zB/WFe0rUIYfnx+/ariUoDRpGqcSfvBzlpCKAfH3qL9kN5WWM4FL4wZOzpeyGaYvNee1VkTXEGoAUi2Zo8bSFPNHgwuQZF+FCvwweKBAX6bOExUyjPq+fqXdBeqNqO/uEUW6PbiXanlXr6dqQz23oJjcEI3p+UoS3Hj2wlZJWH1jphBQ===dhdy-----END PGP SIGNATURE-----
A
A
Andy Patterson wrote on 13 Oct 2018 00:25
(name . Pierre Neidhardt)(address . mail@ambrevar.xyz)(address . 32769@debbugs.gnu.org)
20181012182510.693c28f6@mailservices.uwaterloo.ca
Hi,
On Fri, 12 Oct 2018 08:44:35 +0200Pierre Neidhardt <mail@ambrevar.xyz> wrote:
Toggle quote (3 lines)> Let me know if you'd like to do it or if I should give it a shot :)>
Please feel free. I'll probably get around to it this weekend if youdon't have time before then, if that's ok with you.
Thanks,
--Andy
P
P
Pierre Neidhardt wrote on 14 Oct 2018 10:27
(name . Andy Patterson)(address . ajpatter@uwaterloo.ca)(address . 32769@debbugs.gnu.org)
878t31kk59.fsf@ambrevar.xyz
I won't have time this weekend, so you can go ahead. Otherwise I'll do it nextweek.
Cheers!
-- Pierre Neidhardthttps://ambrevar.xyz/
-----BEGIN PGP SIGNATURE-----
iQEzBAEBCAAdFiEEUPM+LlsMPZAEJKvom9z0l6S7zH8FAlvC/gIACgkQm9z0l6S7zH9Gngf/VSyRdSLyOqSbdgoJ0cZBdvQqcb3GQ1zhIKZTnZfyP9q+JNwpjO/oz0mBSartv17MC1YN18TynjQTbL49I09YtYxqfjlcllYZKn0oalz3BOsOHXDbMIvGISpSipDI9hnhyUNkSmU7AdmFk8afDqsXB8Liqq70UdYu+z7/0EZSDSorrChUVE78VAnGjR9fnHfZrGR0qXCNgUwwDjreeQpD/WcS1H9M8WodSPo8M38x8pHf8iGlbLiLqI0WTYJ8HzxYdkB1ny7hGcld1Uf6qyBMfekUlQzkR4EVadfaFZNIFty1Oa5P+2E+fMl8DKplwmia9LHbFhHO9R/CJVBiviiJog===2Pbp-----END PGP SIGNATURE-----
A
A
Andy Patterson wrote on 15 Oct 2018 08:05
(name . Pierre Neidhardt)(address . mail@ambrevar.xyz)(address . 32769@debbugs.gnu.org)
20181015020505.2387a8c7@mailservices.uwaterloo.ca
Hi Pierre,
On Sun, 14 Oct 2018 10:27:46 +0200Pierre Neidhardt <mail@ambrevar.xyz> wrote:
Toggle quote (3 lines)> I won't have time this weekend, so you can go ahead. Otherwise I'll> do it next week.
I investigated the problem and I think the build-program procedure isok. It has the option to specify which dependencies you want (maybethat's what you used?), and I think that's the right option.
You said that you'd tried passing "next" in some way - in this case thesystem that the executable will depend on is "next-gtk". There's acouple of things here - firstly we need a system for "next" and aseparate one for "next/gtk". The other is that the resulting systemswill be normalized, so we'll end up with "next-gtk" as the system thatwe want to use a dependency for the next-browser executable.
I made these changes and found that I still had problems buildingnext. I managed to figure out that it's because next exercises someless common asd options which makes the bundle that it outputs notconform to the expectations of the build system. We'll have to makesome changes to accommodate that, but for now, here's a patch that makesnext build.
I wasn't able to really test whether or not it works - it throws anexception whenever I press a key. I was able to find out that its*active-buffer* variable is nil, which it expects not to be. If youwant to debug the problems, I recommend doing something like
$ guix environment --ad-hoc sbcl sbcl-slynk:image next-browser:lib &&slynk.image* (slynk:create-server :port 4545)
and then connecting from sly. You might also pass(sb-ext:enable-debugger) to the entry program if you prefer thatinterface but I haven't tried. You can then run
|> (asdf:load-system 'next-gtk)|> (next:start)
to get started.
Hoping that helps,
--Andy
From 452bb2919ab1db6d819973d655407b1a335b2741 Mon Sep 17 00:00:00 2001From: Andy Patterson <ajpatter@uwaterloo.ca>Date: Mon, 15 Oct 2018 01:59:25 -0400Subject: [PATCH] gnu: next-browser: Fix the build.
* gnu/packages/web-browsers.scm (next-browser-core): New variable.(next-browser): Inherit from next-browser-core.--- gnu/packages/lisp.scm | 1 + gnu/packages/web-browsers.scm | 59 ++++++++++++++++++++++++----------- 2 files changed, 42 insertions(+), 18 deletions(-)
Toggle diff (116 lines)diff --git a/gnu/packages/lisp.scm b/gnu/packages/lisp.scmindex fcd3156a7..1b390b66d 100644--- a/gnu/packages/lisp.scm+++ b/gnu/packages/lisp.scm@@ -30,6 +30,7 @@ #:use-module ((guix licenses) #:prefix license:) #:use-module (guix packages) #:use-module (guix download)+ #:use-module (guix hg-download) #:use-module (guix git-download) #:use-module (guix utils) #:use-module (guix build-system gnu)diff --git a/gnu/packages/web-browsers.scm b/gnu/packages/web-browsers.scmindex 0df9180d7..c6844c868 100644--- a/gnu/packages/web-browsers.scm+++ b/gnu/packages/web-browsers.scm@@ -25,6 +25,7 @@ (define-module (gnu packages web-browsers) #:use-module ((guix licenses) #:prefix license:) #:use-module (guix packages)+ #:use-module (guix utils) #:use-module (gnu packages) #:use-module (gnu packages compression) #:use-module (gnu packages databases)@@ -324,10 +325,10 @@ access.") GUI. It is based on PyQt5 and QtWebKit.") (license license:gpl3+))) -(define-public next-browser+(define-public next-browser-core (let ((commit "ccc289b44610ada4ae9c875910af7720e85b546b")) (package- (name "next-browser")+ (name "next-browser-core") (version (git-version "0.0.8" "1" commit)) (source (origin (method git-fetch)@@ -338,11 +339,11 @@ GUI. It is based on PyQt5 and QtWebKit.") (search-patches "next-fix-duplicate-function.patch")) (sha256 (base32- "1pcpb274zb0qm26rrglgcgzg2d2v7j2aja5685swwyq9rcqlbdf4"))))+ "0rccs9w49p577l12kgykccxrjkr03rf1cfz9mvxbjzc8g82dya2k"))+ (file-name (git-file-name name version)))) (build-system asdf-build-system/sbcl) ;; TODO: Move Common Lisp libraries to "native-inputs"? ;; TODO: Does runtime depends on gsettings-desktop-schemas and glib-networking?- (outputs '("out" "lib")) (inputs `(("alexandria" ,sbcl-alexandria) ("cl-strings" ,sbcl-cl-strings)@@ -352,26 +353,48 @@ GUI. It is based on PyQt5 and QtWebKit.") ("cl-sqlite" ,sbcl-cl-sqlite) ("parenscript" ,sbcl-parenscript) ("cl-json" ,sbcl-cl-json)- ("unix-opts" ,sbcl-unix-opts)- ("cl-cffi-gtk" ,sbcl-cl-cffi-gtk)- ("cl-webkit" ,sbcl-cl-webkit)- ("lparallel" ,sbcl-lparallel)))+ ("unix-opts" ,sbcl-unix-opts))) (arguments `( ;; #:tests? #f #:asd-file "next/next.asd"- #:asd-system-name "next/gtk"- #:phases- (modify-phases %standard-phases- (add-after 'create-symlinks 'build-program- (lambda* (#:key outputs #:allow-other-keys)- (build-program- (string-append (assoc-ref outputs "out") "/bin/next-browser")- outputs- #:entry-program '((next:start) 0)))))- ))+ #:asd-system-name "next")) (home-page "http://next.atlas.engineer/") (synopsis "Emacs-inspired web browser in extensible in Common Lisp") (description "Next is a keyboard-oriented, extensible web-browser inspired by Emacs and designed for power users. The application has familiar key-bindings, is fully configurable and extensible in Lisp.") (license license:expat))))++(define-public next-browser+ (package+ (inherit next-browser-core)+ (name "next-browser")+ (outputs '("out" "lib"))+ (inputs+ `(("next" ,next-browser-core)+ ("cl-cffi-gtk" ,sbcl-cl-cffi-gtk)+ ("cl-webkit" ,sbcl-cl-webkit)+ ("lparallel" ,sbcl-lparallel)))+ (arguments+ (substitute-keyword-arguments (package-arguments next-browser-core)+ ((#:asd-system-name _ #f) "next/gtk")+ ((#:phases phases '%standard-phases)+ `(modify-phases ,phases+ (add-before 'cleanup 'move-bundle+ (lambda* (#:key outputs #:allow-other-keys)+ (define lib (assoc-ref outputs "lib"))+ (define actual-fasl (string-append+ lib+ "/lib/sbcl/next/source/next-gtk.fasl"))+ (define expected-fasl (string-append+ lib+ "/lib/sbcl/gtk--system.fasl"))+ (copy-file actual-fasl expected-fasl)+ #t))+ (add-after 'create-symlinks 'build-program+ (lambda* (#:key outputs #:allow-other-keys)+ (build-program+ (string-append (assoc-ref outputs "out") "/bin/next-browser")+ outputs+ #:entry-program '((next:start) 0)+ #:dependencies '("next-gtk"))))))))))-- 2.19.1
P
P
Pierre Neidhardt wrote on 15 Oct 2018 11:34
(name . Andy Patterson)(address . ajpatter@uwaterloo.ca)(address . 32769@debbugs.gnu.org)
87o9bvk0yx.fsf@ambrevar.xyz
Hi Andy!
Thanks for the hard work, this is pretty elegant indeed!
Question: do we need both "out" and "lib" outputs?My understanding is that "lib" is useful when one wants to start the programfrom a REPL. Correct?
Toggle quote (3 lines)> I wasn't able to really test whether or not it works - it throws an> exception whenever I press a key.
Same here. It does not do that when built manually with Quicklisp. Although Irecall seeing something similar when building manually with the wrong arguments.
I also suspect that some CFFI dependency (gtk?) is not packaged correctly andsome paths are missing.
I'll look into it.
-- Pierre Neidhardthttps://ambrevar.xyz/
-----BEGIN PGP SIGNATURE-----
iQEzBAEBCAAdFiEEUPM+LlsMPZAEJKvom9z0l6S7zH8FAlvEXxYACgkQm9z0l6S7zH9n+gf/TzTS2tNXEB255mC9Yg1knYRtmNHp6rN1/1SOzCIHFQHHhNMDGM9FDrOGlNxlXPyRNOIY79NZREN+vmSXNk6zaPsltlczZbpuVADMqw+ovfaKDCn6pZKYMnP01tYfIB8cCHYRFSzO1FbeTIZTsM0taggtIvsbfpTiReqo9tAwU91BSJdU5HOZvXwXu1ZF1B2OLAFwwTk+NFOcgl7G2BPx6Q2P7zQh+gIkZvzR/8b6S0aNoWA3xUnI7Z2OX+mWAhw9UoQICEIOUVNbGq0FDqqLIRlXmWJSOkL3hlpU1P13RYHD5FWMK2N/glU1Jssh6djS27C7/xAebN3tfu3vyGDv0w===ItQ6-----END PGP SIGNATURE-----
P
P
Pierre Neidhardt wrote on 15 Oct 2018 12:04
(name . Andy Patterson)(address . ajpatter@uwaterloo.ca)(address . 32769@debbugs.gnu.org)
87murfjzkx.fsf@ambrevar.xyz
It could also be a dependency version that's different from the one pulled byQuicklisp.
-- Pierre Neidhardthttps://ambrevar.xyz/
-----BEGIN PGP SIGNATURE-----
iQEzBAEBCAAdFiEEUPM+LlsMPZAEJKvom9z0l6S7zH8FAlvEZh4ACgkQm9z0l6S7zH/F0Qf9F/vNcwXRNTrge8IH9LiZjqwKeQVlxNZEKd/LLnHFfSM2QiCz9smKngd42UI6PbTJV5IAWzhP4NGCin/EBQddYzM7hcbn2kOPTPlVXYP3/qLeC+4PD366g5n/vQlBGVRu5ez83KM1kbh/Q7rDxvzxqrHapBQn4DbH+OU+En6tqYiF4NT0ws/mQC+Ay51uRqTsJSgOcV1LYYOkzRdbGN4+Rw1nOt4m6nGxa8bXJJ8rdeSH+3A2/dHnagoiEuWPVLTQT99Ll1zg9ELEfDVks5MxdOlyTF/OQ4BzOWQvsNunN/s986WiD03dwVHnDquw9y604HB/t/C33rKu+0dJKl75Gw===ML1y-----END PGP SIGNATURE-----
A
A
Andy Patterson wrote on 16 Oct 2018 05:11
(name . Pierre Neidhardt)(address . mail@ambrevar.xyz)(address . 32769@debbugs.gnu.org)
20181015231120.17d2bf7a@mailservices.uwaterloo.ca
Hi Pierre,
On Mon, 15 Oct 2018 11:34:14 +0200Pierre Neidhardt <mail@ambrevar.xyz> wrote:
Toggle quote (4 lines)> Question: do we need both "out" and "lib" outputs?> My understanding is that "lib" is useful when one wants to start the> program from a REPL. Correct?
"out" will always depend on "lib" for programs. We want to build itthe same way as other systems so that all of the source for theprogram remains inspect-able at run-time, even if it's just aone-liner.
--Andy
P
P
Pierre Neidhardt wrote on 19 Oct 2018 18:05
(name . Andy Patterson)(address . ajpatter@uwaterloo.ca)(address . 32769@debbugs.gnu.org)
87sh11q5vm.fsf@ambrevar.xyz
I haven't managed to figure what's happening. According to John Mercouris (Nextdeveloper), the state of CFFI-GTK is rather poor and it will be hard to trackdown exactly what's wrong.
Next browser will soon move to another interface which does not rely on cffi-gtkso it won't be a problem.
Andy, if you have an immediate solution, feel free to chime in, otherwise Nextwill have to wait a few more weeks before hitting the Guix repository.
I've merged all the 78 (?) new Lisp packages onto master.I've moved the Next package draft to wip-next-browser3.
-- Pierre Neidhardthttps://ambrevar.xyz/
-----BEGIN PGP SIGNATURE-----
iQEzBAEBCAAdFiEEUPM+LlsMPZAEJKvom9z0l6S7zH8FAlvKAL0ACgkQm9z0l6S7zH9IjQf/TjnDlOycQT8XCkdEuinbcWXbYphfggsLZx53V1CKMfawSqq7kaovzXrMccd+/UqUXVjD3i1LSsBBt1XbI7DSav5A5h8/+w5GqDW+hxNtAA2eNPkXllwebkbI41gKBzZcmrayiBOT5gw5lXABHATgZ968NrkZqZsB6gpJ8yN8IFC2my+fMkbabBhfl+EkVPDfrBy33cqAvuHCz99ebMPqeGUJGwSdQqeo0tlDpMACuH/1s+8TrpqwQnstuKIRzyTISBWbcDSC4wms8xLESfNJlAerycUV5tbBXgzlIwONjeEjh7i6tSM9ZdDLbKhgwjBK5zR7kuvtGC3mYr8aMVO/Nw===nRSn-----END PGP SIGNATURE-----
P
P
Pierre Neidhardt wrote on 2 Dec 2018 13:32
control message for bug #32769
(address . control@debbugs.gnu.org)
87ftvgun19.fsf@atlas.engineer
tags 32769 fixedclose 32769
?
Your comment

This issue is archived.

To comment on this conversation send email to 32769@debbugs.gnu.org