aboutsummaryrefslogtreecommitdiffstats
path: root/recipes/emacs
diff options
context:
space:
mode:
authorDenis 'Gnutoo' Carikli <GNUtoo@no-log.org>2009-12-28 14:20:25 +0100
committerDenis 'Gnutoo' Carikli <GNUtoo@no-log.org>2009-12-28 14:58:51 +0100
commitacbf54300f0754250362e75497f62092faf7d499 (patch)
tree6868ec4fd7d7dd9e12dbf3512009b84463cd0be7 /recipes/emacs
parent969376ab44396ff23f8f628b9d5f4c8040d1cecf (diff)
downloadopenembedded-acbf54300f0754250362e75497f62092faf7d499.tar.gz
openembedded-acbf54300f0754250362e75497f62092faf7d499.tar.bz2
openembedded-acbf54300f0754250362e75497f62092faf7d499.zip
emacs: added version 23.1 and fixed compilation on x86
The main advantage in this version is that the handling of fonts is a lot better: In emacs-x11 the used fonts are not tiny anymore and can easily be chosen Note that we still use qemu for bytecode compilation on x86, that is for several reasons: *The most important one is that it prevents using the host's libraries *It simplifies the recipe(no separate case when the architecture is the same ) *It should work if someone cross-compiles for x86 on his mips,arm,powerpc,sparc computer Warning: emacs_23.1 has not been tested but emacs-x11_23.1 has so putting defaullt preference to -2 in emacs_23.1
Diffstat (limited to 'recipes/emacs')
-rw-r--r--recipes/emacs/emacs-x11_23.1.bb20
-rw-r--r--recipes/emacs/emacs.inc7
-rw-r--r--recipes/emacs/emacs_23.1.bb17
-rw-r--r--recipes/emacs/files/emacs23.1-use-qemu.patch98
4 files changed, 141 insertions, 1 deletions
diff --git a/recipes/emacs/emacs-x11_23.1.bb b/recipes/emacs/emacs-x11_23.1.bb
new file mode 100644
index 0000000000..65665f22a6
--- /dev/null
+++ b/recipes/emacs/emacs-x11_23.1.bb
@@ -0,0 +1,20 @@
+require emacs.inc
+
+# full X (non-diet) is needed for X support
+DEPENDS += "gtk+ libungif"
+
+EXTRA_OECONF = "--without-sound --with-x-toolkit=gtk"
+
+DEFAULT_PREFERENCE = "-1"
+
+RREPLACES = "emacs"
+
+FILESPATH = "${FILE_DIRNAME}/emacs-${PV}:${FILE_DIRNAME}/files"
+SRC_URI = "${GNU_MIRROR}/emacs/emacs-${PV}.tar.gz;name=tarball \
+ file://emacs23.1-use-qemu.patch;patch=1 \
+ file://nostdlib-unwind.patch;patch=1"
+SRC_URI[tarball.md5sum] = "a620d4452769d04ad8864d662f34f8dd"
+SRC_URI[tarball.sha256sum] = "a94cd46301f000d2d1dcd3fd7ef08ad952846d01ca5d4168b4ec3e38e857da47"
+
+
+S = "${WORKDIR}/emacs-${PV}"
diff --git a/recipes/emacs/emacs.inc b/recipes/emacs/emacs.inc
index 0464a26706..d643d31624 100644
--- a/recipes/emacs/emacs.inc
+++ b/recipes/emacs/emacs.inc
@@ -20,8 +20,13 @@ FILES_${PN}-dbg += "${libexecdir}/emacs/*/*/.debug ${datadir}/emacs/*/*/.debug"
TREEDIR = "${WORKDIR}/qemu-treedir"
+QEMUARCH= "${TARGET_ARCH}"
+QEMUARCH_i486 = "i386"
+QEMUARCH_i586 = "i386"
+QEMUARCH_i686 = "i386"
+
# Large stack is required at least on x86_64 host, otherwise random segfaults appear:
-QEMU = "qemu-${TARGET_ARCH} ${QEMU_OPTIONS} -s 1048576 -L ${TREEDIR}"
+QEMU = "qemu-${QEMUARCH} ${QEMU_OPTIONS} -s 1048576 -L ${TREEDIR} "
export LOGNAME = "$(whoami)"
diff --git a/recipes/emacs/emacs_23.1.bb b/recipes/emacs/emacs_23.1.bb
new file mode 100644
index 0000000000..feb56d4e44
--- /dev/null
+++ b/recipes/emacs/emacs_23.1.bb
@@ -0,0 +1,17 @@
+require emacs.inc
+
+EXTRA_OECONF = "--without-sound --without-x"
+
+#/!\warning untested recipe
+DEFAULT_PREFERENCE = "-2"
+
+
+FILESPATH = "${FILE_DIRNAME}/emacs-${PV}:${FILE_DIRNAME}/files"
+SRC_URI = "${GNU_MIRROR}/emacs/emacs-${PV}.tar.gz;name=tarball \
+ file://emacs23.1-use-qemu.patch;patch=1 \
+ file://nostdlib-unwind.patch;patch=1"
+SRC_URI[tarball.md5sum] = "a620d4452769d04ad8864d662f34f8dd"
+SRC_URI[tarball.sha256sum] = "a94cd46301f000d2d1dcd3fd7ef08ad952846d01ca5d4168b4ec3e38e857da47"
+
+
+S = "${WORKDIR}/emacs-${PV}"
diff --git a/recipes/emacs/files/emacs23.1-use-qemu.patch b/recipes/emacs/files/emacs23.1-use-qemu.patch
new file mode 100644
index 0000000000..dd1f384d6d
--- /dev/null
+++ b/recipes/emacs/files/emacs23.1-use-qemu.patch
@@ -0,0 +1,98 @@
+Index: emacs-23.1/leim/Makefile.in
+===================================================================
+--- emacs-23.1.orig/leim/Makefile.in
++++ emacs-23.1/leim/Makefile.in
+@@ -51,7 +51,7 @@ buildlisppath=${srcdir}/${dot}${dot}/lis
+
+ # How to run Emacs.
+ RUN-EMACS = EMACSLOADPATH=$(buildlisppath) LC_ALL=C \
+- ${BUILT-EMACS} -batch --no-init-file --no-site-file --multibyte
++ ${QEMU} ${BUILT-EMACS} -batch --no-init-file --no-site-file --multibyte
+
+ # Subdirectories to be made if ${srcdir} is different from the current
+ # directory.
+Index: emacs-23.1/lib-src/Makefile.in
+===================================================================
+--- emacs-23.1.orig/lib-src/Makefile.in
++++ emacs-23.1/lib-src/Makefile.in
+@@ -23,7 +23,7 @@
+ SHELL = /bin/sh
+
+ # Following ../lisp/Makefile.in.
+-EMACS = ../src/emacs
++EMACS = ${QEMU} ../src/emacs
+ EMACSOPT = -batch --no-site-file --multibyte
+
+ # ==================== Things `configure' will edit ====================
+@@ -371,7 +371,7 @@ TAGS: etags${EXEEXT}
+ clobbered too. */
+ test-distrib${EXEEXT}: ${srcdir}/test-distrib.c
+ $(CC) ${ALL_CFLAGS} -o test-distrib ${srcdir}/test-distrib.c
+- ./test-distrib ${srcdir}/testfile
++ ${QEMU} ./test-distrib ${srcdir}/testfile
+
+ /* We need the following in order to create a <getopt.h> when the system
+ does not have one that works with the given compiler. */
+Index: emacs-23.1/lisp/Makefile.in
+===================================================================
+--- emacs-23.1.orig/lisp/Makefile.in
++++ emacs-23.1/lisp/Makefile.in
+@@ -26,8 +26,7 @@ srcdir=@srcdir@/..
+ # You can specify a different executable on the make command line,
+ # e.g. "make EMACS=../src/emacs ...".
+
+-EMACS = ../src/emacs
+-
++EMACS = "${QEMU} ../src/emacs"
+ # Command line flags for Emacs. This must include --multibyte,
+ # otherwise some files will not compile.
+
+Index: emacs-23.1/Makefile.in
+===================================================================
+--- emacs-23.1.orig/Makefile.in
++++ emacs-23.1/Makefile.in
+@@ -336,7 +336,7 @@ lib-src lisp: Makefile FRC
+ # all preloaded elisp files, and only then dump the actual src/emacs, which
+ # is not wrong, but is overkill in 99.99% of the cases.
+ src: Makefile FRC
+- boot=bootstrap-emacs$(EXEEXT); \
++ boot=${QEMU} bootstrap-emacs$(EXEEXT); \
+ if [ ! -x "src/$$boot" ]; then \
+ cd $@; $(MAKE) all $(MFLAGS) \
+ CC='${CC}' CFLAGS='${CFLAGS}' CPPFLAGS='${CPPFLAGS}' \
+Index: emacs-23.1/src/Makefile.in
+===================================================================
+--- emacs-23.1.orig/src/Makefile.in
++++ emacs-23.1/src/Makefile.in
+@@ -895,9 +895,9 @@ LIBES = $(LOADLIBES) $(LIBS) $(LIBX) $(L
+ #endif
+
+ #ifdef HAVE_SHM
+-RUN_TEMACS = `/bin/pwd`/temacs -nl
++RUN_TEMACS = ${QEMU} temacs -nl
+ #else
+-RUN_TEMACS = `/bin/pwd`/temacs
++RUN_TEMACS = ${QEMU} temacs
+ #endif
+
+ all: emacs${EXEEXT} OTHER_FILES
+@@ -912,7 +912,7 @@ emacs${EXEEXT}: temacs${EXEEXT} ${etc}DO
+ @: bootstrap-emacs, so let us replace it.
+ -ln -f emacs${EXEEXT} bootstrap-emacs${EXEEXT}
+ #endif /* ! defined (CANNOT_DUMP) */
+- -./emacs -q -batch -f list-load-path-shadows
++ -${QEMU} ./emacs -q -batch -f list-load-path-shadows
+
+ /* We run make-docfile twice because the command line may get too long
+ on some systems. */
+@@ -929,8 +929,8 @@ emacs${EXEEXT}: temacs${EXEEXT} ${etc}DO
+ only in order to reduce the command line length. --Stef */
+ ${etc}DOC: ${libsrc}make-docfile${EXEEXT} ${obj} ${lisp} ${SOME_MACHINE_LISP}
+ -rm -f ${etc}DOC
+- ${libsrc}make-docfile -d ${srcdir} ${SOME_MACHINE_OBJECTS} ${obj} > ${etc}DOC
+- ${libsrc}make-docfile -a ${etc}DOC -d ${srcdir} ${SOME_MACHINE_LISP} ${shortlisp}
++ ${QEMU}${libsrc}make-docfile -d ${srcdir} ${SOME_MACHINE_OBJECTS} ${obj} > ${etc}DOC
++ ${QEMU} ${libsrc}make-docfile -a ${etc}DOC -d ${srcdir} ${SOME_MACHINE_LISP} ${shortlisp}
+
+ ${libsrc}make-docfile${EXEEXT}:
+ cd ${libsrc}; ${MAKE} ${MFLAGS} make-docfile${EXEEXT}