Skip to content
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

Linux .a files missing from "vendor/stb/lib" (linker error) #3391

Closed
causecause1 opened this issue Apr 7, 2024 · 2 comments
Closed

Linux .a files missing from "vendor/stb/lib" (linker error) #3391

causecause1 opened this issue Apr 7, 2024 · 2 comments

Comments

@causecause1
Copy link

causecause1 commented Apr 7, 2024

Context

  • Operating System & Odin Version: Kubuntu 23.10
  • odin report output:
        Odin:    dev-2024-04:510574aa7
        OS:      Ubuntu 23.10, Linux 6.5.0-26-generic
        CPU:     AMD FX(tm)-6300 Six-Core Processor             
        RAM:     7914 MiB
        Backend: LLVM 17.0.2

Expected Behavior

Programs should compile.

Current Behavior

The linker throws an error because the file is missing.

Failure Information (for bugs)

/usr/bin/ld: cannot find -l:/home/user/dev/libs/Odin/vendor/stb/image//../lib/stb_image.a: No such file or directory
clang: error: linker command failed with exit code 1 (use -v to see invocation)

Steps to Reproduce

  1. Create a project (on Linux)
  2. import "vendor:stb/image"
  3. Try to run it. It fails because of the missing file

(The fix: Compile it yourself and place it in the path, or install it through the package manager.)

@laytan
Copy link
Sponsor Contributor

laytan commented Apr 7, 2024

On Linux we do not pre-compile some libraries, if that is the case we will either try to link to a system version, or provide a Makefile in the vendor package.

So in this case you can do cd vendor/stb/src && make and that will compile the stb libraries and put them in place.

@causecause1
Copy link
Author

causecause1 commented Apr 7, 2024

I see. I suppose that is the reason for GLFW missing it as well then (the issue I made regarding that).

The linking to the system package is already being done if it fails (both for stb and GLFW), but a makefile would be a nice addition! :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants