finalterm icon indicating copy to clipboard operation
finalterm copied to clipboard

FreeBSD support

Open lantw44 opened this issue 11 years ago • 9 comments

I can build finalterm with little change on FreeBSD. Is there any plan to support FreeBSD? Here is my build log: http://fpaste.org/87273/95371105/

The problem is that finalterm just exits when I try to run it: (finalterm:3651): Gtk-CRITICAL **: gtk_widget_reparent: assertion 'priv->parent != NULL' failed

It exits normally and does not show any window.

I run this on FreeBSD 10.0-RELEASE with GNOME 3.11.92

Want to back this issue? Post a bounty on it! We accept bounties via Bountysource.

lantw44 avatar Mar 21 '14 03:03 lantw44

What is the change you needed to make in order to build on FreeBSD?

I'm always open to supporting new platforms. If the change doesn't break compatibility with other platforms I would appreciate a pull request. Once Final Term reliably builds on FreeBSD we can see about the crash.

p-e-w avatar Mar 25 '14 16:03 p-e-w

I remove #include <pty.h> in the generated Terminal.c file because this file does not exist on FreeBSD. It may be a vala bug. After Fianl Term is successfully built, I don't see any window or useful error message when I run it. It just exits.

lantw44 avatar Mar 25 '14 17:03 lantw44

Platform Header Library

Cygwin <pty.h> libc Interix <pty.h> libc OSF/1 4 and 5 <pty.h> libc glibc <pty.h> libutil MacOS X <util.h> libc OpenBSD, NetBSD <util.h> libutil FreeBSD <libutil.h> libutil

Might be where to look here. without pty's terminals do not work very well.

On Tue, Mar 25, 2014 at 12:03 PM, lantw44 [email protected] wrote:

I remove #include <pty.h> in the generated Terminal.c file because this file does not exist on FreeBSD. It may be a vala bug. After Fianl Term is successfully built, I don't see any window or useful error message when I run it. It just exits.

— Reply to this email directly or view it on GitHubhttps://github.com/p-e-w/finalterm/issues/261#issuecomment-38591649 .

Patrick S. Roberts 512.924.4039(c) IT Director 512.418.5792(o) Centaur Technology

preachermanx avatar Mar 26 '14 04:03 preachermanx

If it's the generated C code that's breaking I would guess it's a Vala bug. Not FinalTerm

steveno avatar Mar 26 '14 12:03 steveno

I find the cause of no message and no window exit of Finalterm. It is caused by hard-coded path of bash in Finalterm. Bash is installed as /usr/local/bin/bash in FreeBSD, and /bin/bash does not exist.

After replacing /bin/bash with /usr/local/bin/bash, Finalterm works. However, Finalterm sometimes crashes with following message:

(finalterm:87965): Cogl-WARNING **: X Error received while making drawable 0x02C00020 current

(finalterm:87965): Gdk-ERROR **: The program 'finalterm' received an X Window System error.
This probably reflects a bug in the program.
The error was 'BadDrawable (invalid Pixmap or Window parameter)'.
  (Details: serial 13050 error_code 9 request_code 152 (DRI2) minor_code 9)
  (Note to programmers: normally, X errors are reported asynchronously;
   that is, you will receive the error a while after causing it.
   To debug your program, run it with the GDK_SYNCHRONIZE environment
   variable to change this behavior. You can then get a meaningful
   backtrace from your debugger if you break on the gdk_x_error() function.)
Trace/BPT trap (core dumped)

I am using GNOME 3.13.3 on FreeBSD 10.0-RELEASE.

lantw44 avatar Jul 06 '14 06:07 lantw44

Actually, the path to bash is not hardcoded, but configurable using dconf. We might want to have CMake locate bash in the future to spare the user from having to configure this manually.

The crash you are seeing is one of the symptoms of https://github.com/p-e-w/finalterm/issues/296 and thus far completely eludes me, which is why I placed a bounty on it in the hope that someone else might bring enlightenment.

p-e-w avatar Jul 06 '14 17:07 p-e-w

Shell path used by Finalterm is configurable, but #!/bin/bash inside Termlets are not.

lantw44 avatar Jul 06 '14 17:07 lantw44

Oh, I see. ~~Is there a shebang syntax that works on all platforms that have bash?~~

Edit: I have found the answer here. Can you confirm that this works on your system?

p-e-w avatar Jul 07 '14 16:07 p-e-w

Yes, it works. There are also other packages using this syntax to find bash.

lantw44 avatar Jul 07 '14 17:07 lantw44