-
-
Notifications
You must be signed in to change notification settings - Fork 406
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Failure to build binary using proper source directory #2360
Comments
Ah, you are opening this issue right on time! I was going to ask for someone to test this before we release 3.0 :p I just tried here again and it works for me with
(I'm disabling submodules because I'm on Guix.) Could you try setting DESTDIR see if it makes a difference? @aartaka Any idea why the GTK extensions dir message appears twice? |
Actually I may have misunderstood your issue. @bubbleguuum Can you post an exact recipe for your issue? How do you start nyxt, what command do you run with what input, what do you expect, what do you see? |
I'm building latest git for openSUSE Tumbleweed (TW). Currently, gcc 12.1 is giving me a compilation error on tabs.c, but I'm going to open a separate issue for that, with the compiler output. It compiled fine 2 days ago, but Tumbleweed being a rolling distro, it is a moving target. |
There is no compilation issue with gcc 12.1, just warnings that I thought made the compilation fail but it was something else. |
To clarify, I was asking for a usage recipe, not the recipe you've to build Nyxt ;) But anyways, I can reproduce locally now, I'll handle it. |
Ah sorry for the misunderstanding. Other packaging related issues for which rpmlint complain:
|
Thanks for the report!
No, but for the sake of completeness, all sources are included.
I believe this is up to the packagers to do it. Are we missing a compilation flags in the
Does not apply to SBCL executables I believe.
This one is tricky, because I don't know how to find libraries reliably from Common Lisp. Packagers are free to install it wherever they want, so there should be a dynamic way to resolve the library location at run-time. An environment variable maybe? For now I'm storing it together with the source because the |
I know what's going on: we are correctly (?) setting the ASDF location for SBCL hard-codes the location of its compiled files. I'm not sure what to do about this.
Any ideea, anyone? |
Understood. For info,
This adds up to a lot of Badness score which makes the RPM build fail. This can be fixed (on the packaging side) by either:
Yes it can be stripped by packagers. But I think it would be better to do it in the makefile (or in lisp code called by the makefile)
It might be only for static binaries (which the
Wouldn't it work to put it in |
I'll update the .asd to not include the .c/.h files.
I beg to differ: it's an OS-level configuration detail. For instance Arch Linux or Gentoo let the user decide whether they want to strip the library or not. Applications should not force it on their side.
When we enable WebKit extensions, in (gobject:g-signal-connect
context "initialize-web-extensions"
(lambda (context)
(with-protect ("Error in \"initialize-web-extensions\" signal thread: ~a" :condition)
(webkit:webkit-web-context-set-web-extensions-directory
context
(uiop:native-namestring gtk-extensions-path))))) |
I've asked for help on Reddit: https://old.reddit.com/r/Common_Lisp/comments/vc6hix/source_location_for_deployed_binary/? |
Doesn't |
|
But how webkitgtk (assuming the .so library installed on the system and supposedly dynamically loaded by the |
Oops! You got me there, I wasn't thinking clearly! You are right, it's us who are in full control of the library location. Here is the relevant code (from (define-class gtk-extensions-directory (nyxt-file)
((files:name "gtk-extensions"))
(:export-class-name-p t)
(:accessor-name-transformer (class*:make-name-transformer name))
(:documentation "Directory where to load the 'libnyxt' library.
By default it is found in the source directory."))
(defmethod files:resolve ((profile nyxt-profile) (file gtk-extensions-directory))
(asdf:system-relative-pathname :nyxt "libraries/web-extensions/")) So what we could do is check multiple folders instead of just there above:
But maybe that's overly complicated. Alternatively, we could add a knob in the |
@bubbleguuum Can you test #2371 see if it fixes the source location issue on your side? |
To do after #2371 is merged:
|
@aartaka Does If so, then I guess we should not set the extension dir to Is it fine to store it in |
I also think the lib should go into its own directory (ie |
The direct effect of this function is adding the directory to WebKit sandbox, no more. But I am not certain about what happens next—it most probably calls
Yes, that should be the best option—it should also resolve the #1781 gratiously. |
OK, but that would still not answer the question for Guix and Nix that do not have |
Done with 4615482. |
Observed using latest master as of the date of this report.
I'm using a custom build of nyxt installed on a system.
Any functionality that requires loading the installed source lisp files fails (for example using
describe-function
), because the built nyxt binary is looking for them in the source folder used for the build, rather than the installed source dir:/home/abuild/rpmbuild/BUILD/nyxt-2.2.4+git20220610.fb7645ae
refers to the directory used to build nyxt (for reference it is built locally as a rpm package, in a sandbox, by Open Build Service).The resulting RPM installs the source in
/usr/share/nyxt/source
but the nyxt binary think they are in/home/abuild/rpmbuild/BUILD/nyxt-2.2.4+git20220610.fb7645ae
.I have a similar problem with gtk extensions with this message on startup (weirdly, it appears twice):
So, how to have these directories point the correct install location ?
Build commands are nothing special:
The text was updated successfully, but these errors were encountered: