aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorUlrich Müller <ulm@gentoo.org>2009-05-29 15:28:40 +0000
committerUlrich Müller <ulm@gentoo.org>2009-05-29 15:28:40 +0000
commit0a36193036cf7de3e2d447474302e83b531e8486 (patch)
tree2045ac206e0e9b924df06836973bd9b74fa9749a
parentFix compilation with glibc 2.10 headers. (diff)
downloademacs-patches-0a36193036cf7de3e2d447474302e83b531e8486.tar.gz
emacs-patches-0a36193036cf7de3e2d447474302e83b531e8486.tar.bz2
emacs-patches-0a36193036cf7de3e2d447474302e83b531e8486.zip
Move patches for Emacs 22.3 from Portage tree to here.emacs-22.3-patches-1
-rw-r--r--emacs/22.3/01_all_Xaw3d-headers.patch150
-rw-r--r--emacs/22.3/02_all_freebsd-sparc.patch17
-rw-r--r--emacs/22.3/03_all_sh.patch26
-rw-r--r--emacs/22.3/04_all_linux-random-heap.patch15
4 files changed, 208 insertions, 0 deletions
diff --git a/emacs/22.3/01_all_Xaw3d-headers.patch b/emacs/22.3/01_all_Xaw3d-headers.patch
new file mode 100644
index 0000000..8b4f332
--- /dev/null
+++ b/emacs/22.3/01_all_Xaw3d-headers.patch
@@ -0,0 +1,150 @@
+--- emacs-22.1-orig/src/xfns.c 2007-06-02 06:00:11.000000000 +0200
++++ emacs-22.1/src/xfns.c 2007-07-01 17:19:35.000000000 +0200
+@@ -72,8 +72,13 @@
+ #include <X11/Shell.h>
+
+ #ifndef USE_MOTIF
++#ifdef HAVE_XAW3D
++#include <X11/Xaw3d/Paned.h>
++#include <X11/Xaw3d/Label.h>
++#else /* !HAVE_XAW3D */
+ #include <X11/Xaw/Paned.h>
+ #include <X11/Xaw/Label.h>
++#endif /* HAVE_XAW3D */
+ #endif /* USE_MOTIF */
+
+ #ifdef USG
+--- emacs-22.1-orig/src/xmenu.c 2007-05-14 16:56:31.000000000 +0200
++++ emacs-22.1/src/xmenu.c 2007-07-01 17:19:35.000000000 +0200
+@@ -82,7 +82,11 @@
+ #include <X11/StringDefs.h>
+ #include <X11/Shell.h>
+ #ifdef USE_LUCID
++#ifdef HAVE_XAW3D
++#include <X11/Xaw3d/Paned.h>
++#else /* !HAVE_XAW3D */
+ #include <X11/Xaw/Paned.h>
++#endif /* HAVE_XAW3D */
+ #endif /* USE_LUCID */
+ #include "../lwlib/lwlib.h"
+ #else /* not USE_X_TOOLKIT */
+--- emacs-22.1-orig/lwlib/lwlib.c 2007-04-20 15:27:29.000000000 +0200
++++ emacs-22.1/lwlib/lwlib.c 2007-07-01 17:19:35.000000000 +0200
+@@ -48,7 +48,11 @@
+ #endif /* not USE_MOTIF && USE_LUCID */
+ #endif
+ #if defined (USE_XAW)
++#ifdef HAVE_XAW3D
++#include <X11/Xaw3d/Paned.h>
++#else /* !HAVE_XAW3D */
+ #include <X11/Xaw/Paned.h>
++#endif /* HAVE_XAW3D */
+ #include "lwlib-Xaw.h"
+ #endif
+
+--- emacs-22.1-orig/lwlib/lwlib-Xaw.c 2007-04-20 15:27:29.000000000 +0200
++++ emacs-22.1/lwlib/lwlib-Xaw.c 2007-07-01 17:19:35.000000000 +0200
+@@ -35,12 +35,21 @@
+ #include <X11/CoreP.h>
+ #include <X11/Shell.h>
+
++#ifdef HAVE_XAW3D
++#include <X11/Xaw3d/Scrollbar.h>
++#include <X11/Xaw3d/Paned.h>
++#include <X11/Xaw3d/Dialog.h>
++#include <X11/Xaw3d/Form.h>
++#include <X11/Xaw3d/Command.h>
++#include <X11/Xaw3d/Label.h>
++#else /* !HAVE_XAW3D */
+ #include <X11/Xaw/Scrollbar.h>
+ #include <X11/Xaw/Paned.h>
+ #include <X11/Xaw/Dialog.h>
+ #include <X11/Xaw/Form.h>
+ #include <X11/Xaw/Command.h>
+ #include <X11/Xaw/Label.h>
++#endif /* HAVE_XAW3D */
+
+ #include <X11/Xatom.h>
+
+--- emacs-22.1-orig/configure.in 2007-05-25 14:43:29.000000000 +0200
++++ emacs-22.1/configure.in 2007-07-01 17:19:35.000000000 +0200
+@@ -2205,29 +2205,45 @@
+
+ dnl Do not put whitespace before the #include statements below.
+ dnl Older compilers (eg sunos4 cc) choke on it.
++HAVE_XAW3D=no
+ if test x"${USE_X_TOOLKIT}" = xmaybe || test x"${USE_X_TOOLKIT}" = xLUCID; then
+- if test x"${HAVE_X11R5}" = xyes; then
+- AC_MSG_CHECKING(X11 version 5 with Xaw)
+- AC_CACHE_VAL(emacs_cv_x11_version_5_with_xaw,
++ if test x"${HAVE_X11R5}" != xyes; then
++ USE_X_TOOLKIT=none
++ else
++ AC_MSG_CHECKING(for xaw3d)
++ AC_CACHE_VAL(emacs_cv_xaw3d,
+ [AC_TRY_LINK([
+ #include <X11/Intrinsic.h>
+-#include <X11/Xaw/Simple.h>],
++#include <X11/Xaw3d/Simple.h>],
+ [],
+- emacs_cv_x11_version_5_with_xaw=yes,
+- emacs_cv_x11_version_5_with_xaw=no)])
+- if test $emacs_cv_x11_version_5_with_xaw = yes; then
+- AC_MSG_RESULT([5 or newer, with Xaw; use toolkit by default])
++ emacs_cv_xaw3d=yes,
++ emacs_cv_xaw3d=no)])
++ if test $emacs_cv_xaw3d = yes; then
++ AC_MSG_RESULT([yes; using Lucid toolkit])
+ USE_X_TOOLKIT=LUCID
++ HAVE_XAW3D=yes
++ AC_DEFINE(HAVE_XAW3D, 1,
++ [Define to 1 if you have the Xaw3d library (-lXaw3d).])
+ else
+- if test x"${USE_X_TOOLKIT}" = xLUCID; then
++ AC_MSG_RESULT(no)
++ AC_MSG_CHECKING(for libXaw)
++ AC_CACHE_VAL(emacs_cv_xaw,
++ [AC_TRY_LINK([
++#include <X11/Intrinsic.h>
++#include <X11/Xaw/Simple.h>],
++ [],
++ emacs_cv_xaw=yes,
++ emacs_cv_xaw=no)])
++ if test $emacs_cv_xaw = yes; then
++ AC_MSG_RESULT([yes; using Lucid toolkit])
++ USE_X_TOOLKIT=LUCID
++ elif test x"${USE_X_TOOLKIT}" = xLUCID; then
+ AC_MSG_ERROR([Lucid toolkit requires X11/Xaw include files])
+ else
+- AC_MSG_RESULT(before 5 or no Xaw; do not use toolkit by default)
++ AC_MSG_RESULT([no; do not use toolkit by default])
+ USE_X_TOOLKIT=none
+ fi
+ fi
+- else
+- USE_X_TOOLKIT=none
+ fi
+ fi
+
+@@ -2315,21 +2331,6 @@
+ fi
+ fi
+
+-### Is -lXaw3d available?
+-HAVE_XAW3D=no
+-if test "${HAVE_X11}" = "yes"; then
+- if test "${USE_X_TOOLKIT}" != "none" && test "${with_toolkit_scroll_bars}" != "no"; then
+- dnl Fixme: determine what Scrollbar.h needs to avoid compilation
+- dnl errors from the test without the `-'.
+- AC_CHECK_HEADER(X11/Xaw3d/Scrollbar.h,
+- [AC_CHECK_LIB(Xaw3d, XawScrollbarSetThumb, HAVE_XAW3D=yes)], , -)
+- if test "${HAVE_XAW3D}" = "yes"; then
+- AC_DEFINE(HAVE_XAW3D, 1,
+- [Define to 1 if you have the Xaw3d library (-lXaw3d).])
+- fi
+- fi
+-fi
+-
+ dnl Use toolkit scroll bars if configured for GTK or X toolkit and either
+ dnl using Motif or Xaw3d is available, and unless
+ dnl --with-toolkit-scroll-bars=no was specified.
diff --git a/emacs/22.3/02_all_freebsd-sparc.patch b/emacs/22.3/02_all_freebsd-sparc.patch
new file mode 100644
index 0000000..de206e7
--- /dev/null
+++ b/emacs/22.3/02_all_freebsd-sparc.patch
@@ -0,0 +1,17 @@
+http://bugs.gentoo.org/159584
+Patch taken from FreeBSD ports, by Giorgos Keramidas <keramida@freebsd.org>
+
+--- emacs-orig/src/alloc.c
++++ emacs/src/alloc.c
+@@ -4573,7 +4573,11 @@
+ needed on ia64 too. See mach_dep.c, where it also says inline
+ assembler doesn't work with relevant proprietary compilers. */
+ #ifdef __sparc__
++#ifdef __sparc64__
++ asm ("flushw");
++#else
+ asm ("ta 3");
++#endif
+ #endif
+
+ /* Save registers that we need to see on the stack. We need to see
diff --git a/emacs/22.3/03_all_sh.patch b/emacs/22.3/03_all_sh.patch
new file mode 100644
index 0000000..c4a6469
--- /dev/null
+++ b/emacs/22.3/03_all_sh.patch
@@ -0,0 +1,26 @@
+--- emacs-22.2-orig/configure.in 2008-09-26 07:20:44.000000000 +0200
++++ emacs-22.2/configure.in 2008-09-30 12:57:06.000000000 +0200
+@@ -1192,6 +1192,16 @@
+ machine=mips opsys=gnu-linux
+ ;;
+
++ ## SuperH (little endian) Linux-based GNU system
++ sh[34]-*-linux-gnu* )
++ machine=sh3el opsys=gnu-linux
++ ;;
++
++ ## SuperH (big endian) Linux-based GNU system
++ sh[34]eb-*-linux-gnu* )
++ machine=sh3eb opsys=gnu-linux
++ ;;
++
+ ## UXP/DS
+ sparc-fujitsu-sysv4* )
+ machine=sparc opsys=uxpds
+--- emacs-22.2-orig/src/m/sh3eb.h 1970-01-01 01:00:00.000000000 +0100
++++ emacs-22.2/src/m/sh3eb.h 2008-09-30 12:59:44.000000000 +0200
+@@ -0,0 +1,4 @@
++/* machine description file for big-endian SuperH. */
++
++#include "sh3el.h"
++#define WORDS_BIG_ENDIAN
diff --git a/emacs/22.3/04_all_linux-random-heap.patch b/emacs/22.3/04_all_linux-random-heap.patch
new file mode 100644
index 0000000..37bee82
--- /dev/null
+++ b/emacs/22.3/04_all_linux-random-heap.patch
@@ -0,0 +1,15 @@
+http://bugs.gentoo.org/236579
+http://emacsbugs.donarmstrong.com/cgi-bin/bugreport.cgi?bug=900
+Fixes sporadic segmentation faults in unexec.
+
+--- emacs-22.3-orig/src/emacs.c 2008-05-12 10:30:13.000000000 +0200
++++ emacs-22.3/src/emacs.c 2008-10-21 16:45:50.000000000 +0200
+@@ -883,7 +883,7 @@
+ if (!initialized
+ && (strcmp (argv[argc-1], "dump") == 0
+ || strcmp (argv[argc-1], "bootstrap") == 0)
+- && heap_bss_diff > MAX_HEAP_BSS_DIFF)
++ /*&& heap_bss_diff > MAX_HEAP_BSS_DIFF*/)
+ {
+ if (! getenv ("EMACS_HEAP_EXEC"))
+ {