-
-
Notifications
You must be signed in to change notification settings - Fork 12
Fixes on SDL3 binding and nob to compile blc on Debian GNU/Linux 11.x systems #186
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
base: master
Are you sure you want to change the base?
Conversation
Added libpthread (-lpthread) on link flags
…hics server (x11 or wayland) on a Linux system
|
Hello, thanks for your contribution. I appreciate your interest in BL and Tine! Please take a look at my notes. |
| cmd_append(&cmd, LIBZ, LIBZSTD, LIBCURSES); | ||
| #else | ||
| cmd_append(&cmd, LIBZ, LIBZSTD, LIBTINFO); | ||
| cmd_append(&cmd, "-ldl", "-lm", "-lpthread"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This cause all listed flags to be added second time, I guess it can be removed. Let me know if there are any other issues (maybe something with ordering of link flags?). Also there is incorrect indentation; use tabs please.
| DisplayID :: u32; | ||
|
|
||
| HINT_VIDEO_DRIVER :: "SDL_VIDEO_DRIVER"; | ||
| HINT_VIDEO_DRIVER :: "SDL_HINT_VIDEO_DRIVER"; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
According to docs https://wiki.libsdl.org/SDL3/SDL_HINT_VIDEO_DRIVER this should be SDL_VIDEO_DRIVER, accepting list of drivers separated by comma. Your Tine build probably works because the hint is ignored?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Maybe there should not be space after the comma in the list? https://github.com/travisdoor/tine/blob/db44045a22bb9ff1a59be1a0f8566c9ce8c035db/src/window.bl#L38 IDK.
|
Regarding SLD3 linking issues; this is a bit weird, binaries should be included in your bl clone https://github.com/biscuitlang/bl/tree/master/lib/bl/api/extra/sdl3/linux |
Hi!
This PR is because I liked the idea and interface of your Tine editor (simple and effective, in line with the UNIX philosophy) and I wanted to try it on a Debian GNU/Linux 11.x "bullseye" based system (yes, I know, now "oldstable" but, without a doubt, very "stable"), I needed to first compile the latest version (master) of your "Biscuit Language" compiler (blc). It seems that, when linking libraries, they were giving unresolved symbol errors associated with libpthread (
-lpthread). Once added tosrc/nob.c, I was able to compileblc.Also, in order to build Tine, I found out that I must (manually) build the SDL3 library (via the
build.blscript inlib/bl/api/extra/sdl3) since neitherbuild.sh allnorbuild.sh build-allbuild it but, when I was able to compile Tine and run it, Tine cannot init because SDL3 couldn't detect the graphics system (X11/Xorg in my case) and therefore neither could the SDL video subsystem (the only way was to use theSDL_VIDEODRIVER=x11environment variable as a workaround).I later discovered that
HINT_VIDEO_DRIVERbinding (inlib/bl/api/extra/sdl3/sdl3.bl) was associated withSDL_VIDEO_DRIVERwhen (at least in SDL3) it should instead be associated withSDL_HINT_VIDEO_DRIVERso I changed, re-compile and finaly now... it works!!I hope this helps you improve Biscuit Language on Linux-based systems! :)