-
Notifications
You must be signed in to change notification settings - Fork 354
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
Text starts from the right hand side on ARM Mac #1238
Comments
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
This comment has been minimized.
Well, it's not the obvious thing, so i'm out of ideas really. Ask the homebrew people, I guess? They messed up their terminfo or whatever. |
See if you get same behavior with another terminal, like iTerm2, which is the 'preferred' terminal by most irssi users. At least that's what everybody says but there is no poll on it or anything :) |
Same issue here, across multiple terminals (Terminal.app as OP mentioned and Rosetta'd Alacritty). Homebrew is just running |
I see homebrew as both a build system and a distro. They are in charge of ensuring that their builds interact well with the libraries they depend on. Also, they know more about their own platform than we do. Not saying it's their fault, but they are way more likely to be able to help on this issue than us. |
This comment has been minimized.
This comment has been minimized.
Hi guys, I compiled irssi manually but it still results in a right-aligned irssi. Wondering how you guys resolved this? |
Tried debugging this issue with the Homebrew community (see Homebrew/homebrew-core#68856) but they suggested it's an upstream issue. |
@676339784 Only other thing I can think of trying is iTerm2 (does it have an ARM build?) |
I can confirm I do actually have the same issue. I forgot to report back after this but when I confirmed it was working for myself I was accidentally SSH'd into a server in my TMUX pane and not on my macbook. This problem occurs in both the builtin Terminal.app and iTerm2 (which does have an ARM build) with various $TERM settings tested in-between. |
@WA9ACE Yup, I share the same problems as you do |
I'm not too good at C but I'll try stepping through it tonight, to see if I can pinpoint the problem for a PR. |
Trying to look into it, just writing down some stuff that might be useful to someone too in digging. Bug is totally reproducing on both iterm2 and Terminal.app; it is not terminals fault because irssi on x86_64 and aarch64 Linux renders just fine in both of them (via ssh). Building irssi from source with added ncurses to the PKG_CONFIG_PATH doesn't do the trick apparently and it still links against system libncurses; possibly that's why Homebrew/homebrew-core#68856 (comment) this tryout didn't change anything. Overriding CFLAGS and LDFLAGS though produces some interesting result - irssi now clearly builds with libncurses-6.2 from homebrew installation and links against that and it totally destroys iterm2 upon launch. Whole terminal emulator with all its apps just leaks indefinitely and hard freezes. "Stock" Terminal.app manages to withstands the new binary but produces pitch black screen. I'll try to debug it / check ncurses but maybe the provided info will help some folks that are more knowledgeable than me. Output of
Screenshot of the Terminal app with |
does this patch do anything
|
Yes, this patch and building with ncurses from homebrew does seem to fix it. |
Used wise @ailin-nemui insight and the following change allowed the fix to work with a "stock" macos ncurses too (homebrew ncurses works as well):
|
note that this is an Apple issue, arm64 on Linux has no such issues |
as discussed on IRC, we cannot just apply above patch due to compatibility concerns. We need a comprehensive and compatible solution. One such solution might be to properly search for and, if found, Technically of course, it is illegal to have So if anyone can come up with and contribute such a solution, that would be great. Especially since the devs don't have any proprietary devices to test. Interested contributors should keep in mind that, for the time being, the solution has to be implemented in both meson and autotools. |
If term.h is present, use that instead of defining prototypes for the terminfo functions in terminfo-core.c. This causes problems on certain platforms (e.g. Apple aarch64) due to the functions being prototyped as non-variadic but called as variadic. If term.h isn't found, it falls back to the old behaviour. Fixes irssi#1238.
If term.h is present, use that instead of defining prototypes for the terminfo functions in terminfo-core.c. This causes problems on certain platforms (e.g. Apple aarch64) due to the functions being prototyped as non-variadic but called as variadic. If term.h isn't found, it falls back to the old behaviour. Fixes irssi#1238.
Irssi on Apple ARM does not properly render to screen.
The issue is that Apple on ARM puts variadic arguments in function calls in a different place than everyone else.
In the mean time, you can find a patch to try in #1238 (comment)
Unfortunately, we cannot unconditionally patch Irssi like this because it might break rendering on other platforms.
original bug report follows
The text was updated successfully, but these errors were encountered: