Date: Thu, 29 May 2008 09:20:59 GMT From: Jan Henrik Sylvester <me@janh.de> To: freebsd-gnats-submit@FreeBSD.org Subject: ports/124094: editors/qemacs broken with gcc4 / gcc34 Message-ID: <200805290920.m4T9Kx9I062907@www.freebsd.org> Resent-Message-ID: <200805290930.m4T9U3rq090613@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 124094 >Category: ports >Synopsis: editors/qemacs broken with gcc4 / gcc34 >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Thu May 29 09:30:03 UTC 2008 >Closed-Date: >Last-Modified: >Originator: Jan Henrik Sylvester >Release: FreeBSD 7.0-RELEASE i386 >Organization: >Environment: >Description: qemacs needs the patch attached to even start (from qemacs-devel@nongnu.org) and not only give "No suitable display found, exiting". A lot more seems to be broken with gcc4 or gcc34. According to qemacs-devel, gcc4 needs many more patches that are in CVS with alpha status. Therefore, changing to gcc34 seems sensible to me, even if it is not required for the application to start up. I have given up to research this further as utf8 editing is obviously very broken leading to immediate segfaults on simple operations. >How-To-Repeat: Install editors/qemacs on FreeBSD 7 and start qemacs. >Fix: The patch attached seems to make simple ASCII editing possible. (The gcc34 part may not be required.) Patch attached with submission follows: diff -uN files/patch-qe.h.orig files/patch-qe.h --- files/patch-qe.h.orig 1970-01-01 01:00:00.000000000 +0100 +++ files/patch-qe.h 2008-05-29 10:05:38.000000000 +0200 @@ -0,0 +1,22 @@ +--- qe.h.orig 2003-04-22 00:01:42.000000000 +0200 ++++ qe.h 2005-06-07 16:02:27.000000000 +0200 +@@ -576,10 +576,18 @@ + + /* make sure that the keyword is not disabled by glibc (TINYC case) */ + #undef __attribute__ +- ++#if __GNUC__ < 3 || (__GNUC__ == 3 && __GNUC_MINOR__ < 3) + /* same method as the linux kernel... */ + #define __init_call __attribute__ ((unused,__section__ (".initcall.init"))) + #define __exit_call __attribute__ ((unused,__section__ (".exitcall.exit"))) ++#else ++#undef __attribute_used__ ++#define __attribute_used__ __attribute__((__used__)) ++#define __init_call __attribute_used__ __attribute__((__section__ (".initcall.init"))) ++#define __exit_call __attribute_used__ __attribute__((__section__ (".exitcall.exit"))) ++ ++#endif ++ + + #define qe_module_init(fn) \ + static int (*__initcall_##fn)(void) __init_call = fn diff -uN Makefile.orig Makefile --- Makefile.orig 2008-04-19 19:48:21.000000000 +0200 +++ Makefile 2008-05-29 09:56:07.000000000 +0200 @@ -18,6 +18,7 @@ HAS_CONFIGURE= yes CONFIGURE_ARGS= --prefix="${PREFIX}" --make="${GMAKE}" --cc="${CC}" \ --extra-cflags="${CFLAGS}" --extra-ldflags="${LDFLAGS}" +USE_GCC= 3.4 DATADIR= ${PREFIX}/share/qe >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200805290920.m4T9Kx9I062907>