summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Lauer <mickey@vanille-media.de>2008-09-04 11:12:29 +0000
committerMichael Lauer <mickey@vanille-media.de>2008-09-04 11:12:29 +0000
commit7151970dde7e1a95c7d829f2b7792e038ef83398 (patch)
tree845c6d498afbf2de502b731081731d0b0a546c26
parent3a02d533d73cf7dfaddafb7992bcbdc1bc4258ca (diff)
parentb95401db19f6290654111d2b0709269a221953c0 (diff)
merge of 'b9249f27ed481c5d02d4b0a68b50c1e6688fe484'
and 'c8025b1589420ff484c99ad1c0e06906ad36b85d'
-rw-r--r--packages/classpath/classpath-minimal_0.97.2.bb3
-rw-r--r--packages/classpath/classpath-native_0.97.2.bb1
-rw-r--r--packages/classpath/classpath_0.97.2.bb3
-rw-r--r--packages/classpath/files/cp-byte-loophelper.patch68
-rw-r--r--packages/classpath/files/decimalformat.patch31
-rw-r--r--packages/clucene/.mtn2git_empty (renamed from packages/nonworking/clucene/.mtn2git_empty)0
-rw-r--r--packages/clucene/clucene-core_0.9.21.bb23
-rw-r--r--packages/kde4/.mtn2git_empty (renamed from packages/nonworking/clucene/clucene-0.8.12-pre/.mtn2git_empty)0
-rw-r--r--packages/kde4/akonadi_1.0.bb9
-rw-r--r--packages/kde4/automoc-native_svn.bb8
-rw-r--r--packages/kde4/gmm_3.0.bb12
-rw-r--r--packages/kde4/kde4-native.inc14
-rw-r--r--packages/kde4/kde4.inc46
-rw-r--r--packages/kde4/qca_2.0.0.bb7
-rw-r--r--packages/kde4/soprano_2.1.bb9
-rw-r--r--packages/kde4/strigi_0.5.10.bb17
-rw-r--r--packages/kexecboot/files/kexecboot-rewrite.patch344
-rw-r--r--packages/kexecboot/files/rootdelay.patch11
-rw-r--r--packages/kexecboot/initramfs-kexecboot_1.0.bb3
-rw-r--r--packages/kexecboot/kexecboot_0.3.bb14
-rw-r--r--packages/kexecboot/linux-kexecboot-2.6.26/defconfig-akita3
-rw-r--r--packages/kexecboot/linux-kexecboot-2.6.26/defconfig-bootcdx862
-rw-r--r--packages/kexecboot/linux-kexecboot-2.6.26/defconfig-c7x03
-rw-r--r--packages/kexecboot/linux-kexecboot-2.6.26/defconfig-htcuniversal3
-rw-r--r--packages/kexecboot/linux-kexecboot-2.6.26/defconfig-hx20002
-rw-r--r--packages/kexecboot/linux-kexecboot-2.6.26/defconfig-poodle3
-rw-r--r--packages/kexecboot/linux-kexecboot-2.6.26/defconfig-qemuarm2
-rw-r--r--packages/kexecboot/linux-kexecboot-2.6.26/defconfig-qemux862
-rw-r--r--packages/kexecboot/linux-kexecboot-2.6.26/defconfig-spitz3
-rw-r--r--packages/kexecboot/linux-kexecboot-2.6.26/defconfig-zylonite3
-rw-r--r--packages/kexecboot/linux-kexecboot.inc6
-rw-r--r--packages/kexecboot/linux-kexecboot_2.6.26.bb4
-rw-r--r--packages/nonworking/clucene/clucene-0.8.12-pre/compile-fix.patch23
-rw-r--r--packages/nonworking/clucene/clucene_0.8.12-pre.bb24
34 files changed, 627 insertions, 79 deletions
diff --git a/packages/classpath/classpath-minimal_0.97.2.bb b/packages/classpath/classpath-minimal_0.97.2.bb
index 8a87d1f636..44cffcec32 100644
--- a/packages/classpath/classpath-minimal_0.97.2.bb
+++ b/packages/classpath/classpath-minimal_0.97.2.bb
@@ -7,9 +7,10 @@ SRC_URI += "\
file://ecj_java_dir.patch;patch=1 \
file://autotools.patch;patch=1 \
file://decimalformat.patch;patch=1 \
+ file://cp-byte-loophelper.patch;patch=1;pnum=0 \
"
-PR = "r2"
+PR = "r3"
PROVIDES = "${PN} classpath"
diff --git a/packages/classpath/classpath-native_0.97.2.bb b/packages/classpath/classpath-native_0.97.2.bb
index 499ad9f5fb..cec256ecc2 100644
--- a/packages/classpath/classpath-native_0.97.2.bb
+++ b/packages/classpath/classpath-native_0.97.2.bb
@@ -13,5 +13,6 @@ SRC_URI += "\
file://ecj_java_dir.patch;patch=1 \
file://autotools.patch;patch=1 \
file://decimalformat.patch;patch=1 \
+ file://cp-byte-loophelper.patch;patch=1;pnum=0 \
"
diff --git a/packages/classpath/classpath_0.97.2.bb b/packages/classpath/classpath_0.97.2.bb
index 5267222104..242bab95f2 100644
--- a/packages/classpath/classpath_0.97.2.bb
+++ b/packages/classpath/classpath_0.97.2.bb
@@ -7,9 +7,10 @@ SRC_URI += "\
file://ecj_java_dir.patch;patch=1 \
file://autotools.patch;patch=1 \
file://decimalformat.patch;patch=1 \
+ file://cp-byte-loophelper.patch;patch=1;pnum=0 \
"
-PR = "r3"
+PR = "r4"
DEPENDS += "gtk+ gconf libxtst"
diff --git a/packages/classpath/files/cp-byte-loophelper.patch b/packages/classpath/files/cp-byte-loophelper.patch
new file mode 100644
index 0000000000..4fac362cba
--- /dev/null
+++ b/packages/classpath/files/cp-byte-loophelper.patch
@@ -0,0 +1,68 @@
+Index: gnu/java/nio/charset/ByteDecodeLoopHelper.java
+===================================================================
+RCS file: /sources/classpath/classpath/gnu/java/nio/charset/ByteDecodeLoopHelper.java,v
+retrieving revision 1.1
+diff -u -r1.1 ByteDecodeLoopHelper.java
+--- gnu/java/nio/charset/ByteDecodeLoopHelper.java 23 Nov 2007 16:11:17 -0000 1.1
++++ gnu/java/nio/charset/ByteDecodeLoopHelper.java 3 Sep 2008 23:11:29 -0000
+@@ -119,6 +119,8 @@
+ int inRemaining = in.remaining();
+ int outRemaining = out.remaining();
+ CoderResult result;
++
++ bailOut:
+ if (inRemaining <= outRemaining)
+ {
+ for (int i = 0; i < inRemaining; i++)
+@@ -129,7 +131,7 @@
+ {
+ inPos--;
+ result = CoderResult.unmappableForLength(1);
+- break;
++ break bailOut;
+ }
+ char c = mapToChar(b);
+ outArray[outPos] = c;
+@@ -147,7 +149,7 @@
+ {
+ inPos--;
+ result = CoderResult.unmappableForLength(1);
+- break;
++ break bailOut;
+ }
+ char c = mapToChar(b);
+ outArray[outPos] = c;
+Index: gnu/java/nio/charset/ByteEncodeLoopHelper.java
+===================================================================
+RCS file: /sources/classpath/classpath/gnu/java/nio/charset/ByteEncodeLoopHelper.java,v
+retrieving revision 1.1
+diff -u -r1.1 ByteEncodeLoopHelper.java
+--- gnu/java/nio/charset/ByteEncodeLoopHelper.java 23 Nov 2007 16:11:17 -0000 1.1
++++ gnu/java/nio/charset/ByteEncodeLoopHelper.java 3 Sep 2008 23:11:29 -0000
+@@ -120,6 +120,8 @@
+ int inRemaining = in.remaining();
+ int outRemaining = out.remaining();
+ CoderResult result;
++
++ bailOut:
+ if (inRemaining <= outRemaining)
+ {
+ for (int i = 0; i < inRemaining; i++)
+@@ -130,7 +132,7 @@
+ {
+ inPos--;
+ result = CoderResult.unmappableForLength(1);
+- break;
++ break bailOut;
+ }
+ byte b = mapToByte(inChar);
+ outArray[outPos] = b;
+@@ -148,7 +150,7 @@
+ {
+ inPos--;
+ result = CoderResult.unmappableForLength(1);
+- break;
++ break bailOut;
+ }
+ byte b = mapToByte(inChar);
+ outArray[outPos] = b;
diff --git a/packages/classpath/files/decimalformat.patch b/packages/classpath/files/decimalformat.patch
new file mode 100644
index 0000000000..4997523830
--- /dev/null
+++ b/packages/classpath/files/decimalformat.patch
@@ -0,0 +1,31 @@
+Index: classpath-0.97.2/java/text/DecimalFormat.java
+===================================================================
+--- classpath-0.97.2.orig/java/text/DecimalFormat.java
++++ classpath-0.97.2/java/text/DecimalFormat.java
+@@ -1296,7 +1296,7 @@ public class DecimalFormat extends Numbe
+ currencySymbol = this.symbols.getCurrencySymbol();
+
+ // if \u00A4 is doubled, we use the international currency symbol
+- if (i < len && pattern.charAt(i + 1) == '\u00A4')
++ if ((i + 1) < len && pattern.charAt(i + 1) == '\u00A4')
+ {
+ currencySymbol = this.symbols.getInternationalCurrencySymbol();
+ i++;
+@@ -1320,7 +1320,7 @@ public class DecimalFormat extends Numbe
+ else if (ch == '\'')
+ {
+ // QUOTE
+- if (i < len && pattern.charAt(i + 1) == '\'')
++ if ((i + 1) < len && pattern.charAt(i + 1) == '\'')
+ {
+ // we need to add ' to the buffer
+ buffer.append(ch);
+@@ -1692,7 +1692,7 @@ public class DecimalFormat extends Numbe
+ else if (ch == '\'')
+ {
+ // QUOTE
+- if (i < len && pattern.charAt(i + 1) == '\'')
++ if ((i + 1) < len && pattern.charAt(i + 1) == '\'')
+ {
+ // we need to add ' to the buffer
+ buffer.append(ch);
diff --git a/packages/nonworking/clucene/.mtn2git_empty b/packages/clucene/.mtn2git_empty
index e69de29bb2..e69de29bb2 100644
--- a/packages/nonworking/clucene/.mtn2git_empty
+++ b/packages/clucene/.mtn2git_empty
diff --git a/packages/clucene/clucene-core_0.9.21.bb b/packages/clucene/clucene-core_0.9.21.bb
new file mode 100644
index 0000000000..0416f9110e
--- /dev/null
+++ b/packages/clucene/clucene-core_0.9.21.bb
@@ -0,0 +1,23 @@
+DESCRIPTION = "CLucene is a C++ port of Lucene: the high-performance, full-featured text search engine written in Java."
+SECTION = "libs"
+LICENSE = "LGPL"
+
+DEPENDS = "libtool"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/clucene/clucene-core-${PV}.tar.bz2"
+
+inherit autotools
+
+EXTRA_OECONF = "--disable-multithreading dps_static_const_type=2"
+
+do_configure() {
+ gnu-configize
+ cp ${STAGING_DATADIR}/libtool/config.sub ${S}/config
+ oe_runconf
+}
+
+do_stage() {
+ autotools_stage_all
+}
+
+FILES_${PN}-dev += "${libdir}/CLucene"
diff --git a/packages/nonworking/clucene/clucene-0.8.12-pre/.mtn2git_empty b/packages/kde4/.mtn2git_empty
index e69de29bb2..e69de29bb2 100644
--- a/packages/nonworking/clucene/clucene-0.8.12-pre/.mtn2git_empty
+++ b/packages/kde4/.mtn2git_empty
diff --git a/packages/kde4/akonadi_1.0.bb b/packages/kde4/akonadi_1.0.bb
new file mode 100644
index 0000000000..2d361bfef2
--- /dev/null
+++ b/packages/kde4/akonadi_1.0.bb
@@ -0,0 +1,9 @@
+require kde4.inc
+
+DEPENDS += "automoc-native"
+
+PV = "1.0"
+SRC_URI = "svn://anonsvn.kde.org/home/kde/branches/akonadi;module=1.0;proto=svn"
+
+S= "${WORKDIR}/1.0"
+
diff --git a/packages/kde4/automoc-native_svn.bb b/packages/kde4/automoc-native_svn.bb
new file mode 100644
index 0000000000..c79e7d1df9
--- /dev/null
+++ b/packages/kde4/automoc-native_svn.bb
@@ -0,0 +1,8 @@
+require kde4.inc
+require kde4-native.inc
+inherit native
+
+SRC_URI = "svn://anonsvn.kde.org/home/kde/trunk/kdesupport;module=automoc;proto=svn"
+
+S = "${WORKDIR}/automoc"
+
diff --git a/packages/kde4/gmm_3.0.bb b/packages/kde4/gmm_3.0.bb
new file mode 100644
index 0000000000..47cda16506
--- /dev/null
+++ b/packages/kde4/gmm_3.0.bb
@@ -0,0 +1,12 @@
+DESCRIPTION = "The Getfem++ project focuses on the development of a generic and efficient C++ library for finite element methods."
+LICENSE = "LGPLv2"
+
+inherit autotools
+
+SRC_URI = "http://download.gna.org/getfem/stable/gmm-3.0.tar.gz"
+
+AUTOTOOLS_STAGE_PKGCONFIG = "1"
+do_stage() {
+ autotools_stage_all
+}
+
diff --git a/packages/kde4/kde4-native.inc b/packages/kde4/kde4-native.inc
new file mode 100644
index 0000000000..247d13704a
--- /dev/null
+++ b/packages/kde4/kde4-native.inc
@@ -0,0 +1,14 @@
+
+# Ugly, use qt4 from the buildhost till someone adds a qt4-native recipe
+
+EXTRA_OECMAKE = "-DQT_LIBRARY_DIR=/usr/lib \
+ -DQT_INSTALL_LIBS=/usr/lib \
+ -DQT_INCLUDE_DIR=/usr/include/qt4 \
+ -DQT_MOC_EXECUTABLE=${OE_QMAKE_MOC} \
+ -DQT_UIC_EXECUTABLE=${OE_QMAKE_UIC} \
+ -DQT_UIC3_EXECUTABLE=${OE_QMAKE_UIC3} \
+ -DQT_RCC_EXECUTABLE=${OE_QMAKE_RCC} \
+ -DQT_QMAKE_EXECUTABLE=${OE_QMAKE_QMAKE} \
+ -DQT_QTCORE_INCLUDE_DIR=/usr/include/qt4/QtCore \
+ "
+
diff --git a/packages/kde4/kde4.inc b/packages/kde4/kde4.inc
new file mode 100644
index 0000000000..a5ea173b5e
--- /dev/null
+++ b/packages/kde4/kde4.inc
@@ -0,0 +1,46 @@
+LICENSE = "GPL"
+
+inherit qt4x11 cmake
+
+PV = "4.1+svnr${SRCREV}"
+SRCREV = "856719"
+SRC_URI = "svn://anonsvn.kde.org/home/kde/branches/KDE/4.1;module=${PN};proto=svn"
+
+# OE lacks some native qt4 tools, so we use the ones form the host :/
+EXTRA_OECMAKE = "-DQT_LIBRARY_DIR=${OE_QMAKE_LIBDIR_QT} \
+ -DQT_INSTALL_LIBS=${OE_QMAKE_LIBDIR_QT} \
+ -DQT_INCLUDE_DIR=${OE_QMAKE_INCDIR_QT} \
+ -DQT_MOC_EXECUTABLE=${OE_QMAKE_MOC} \
+ -DQT_UIC_EXECUTABLE=${OE_QMAKE_UIC} \
+ -DQT_UIC3_EXECUTABLE=${OE_QMAKE_UIC3} \
+ -DQT_RCC_EXECUTABLE=${OE_QMAKE_RCC} \
+ -DQT_QMAKE_EXECUTABLE=${OE_QMAKE_QMAKE} \
+ -DQT_QTCORE_INCLUDE_DIR=${OE_QMAKE_INCDIR_QT}/QtCore \
+ -DQT_DBUSXML2CPP_EXECUTABLE=/usr/bin/qdbusxml2cpp \
+ -DQT_DBUSCPP2XML_EXECUTABLE=/usr/bin/qdbuscpp2xml \
+ "
+
+
+S = "${WORKDIR}/${PN}"
+
+
+do_install_append() {
+ install -d ${D}/${libdir}/qt4
+ mv ${D}/${STAGING_DIR_TARGET}/qt4/plugins* ${D}/${libdir}/qt4 || true
+}
+
+FILES_${PN} += "${libdir}/qt4 \
+ ${datadir}/mime \
+ ${datadir}/dbus-1 \
+ ${datadir}/config \
+ "
+
+FILES_${PN}-dbg += "${libdir}/qt4/.debug \
+ ${libdir}/qt4/*/.debug \
+ ${libdir}/qt4/*/*/.debug"
+
+
+AUTOTOOLS_STAGE_PKGCONFIG = "1"
+do_stage() {
+ autotools_stage_all
+}
diff --git a/packages/kde4/qca_2.0.0.bb b/packages/kde4/qca_2.0.0.bb
new file mode 100644
index 0000000000..c2e7e3f371
--- /dev/null
+++ b/packages/kde4/qca_2.0.0.bb
@@ -0,0 +1,7 @@
+require kde4.inc
+
+PV = "2.0.0"
+SRC_URI = "svn://anonsvn.kde.org/home/kde/tags/qca;module=2.0.0;proto=svn"
+
+S= "${WORKDIR}/2.0.0"
+
diff --git a/packages/kde4/soprano_2.1.bb b/packages/kde4/soprano_2.1.bb
new file mode 100644
index 0000000000..f2393663c8
--- /dev/null
+++ b/packages/kde4/soprano_2.1.bb
@@ -0,0 +1,9 @@
+require kde4.inc
+
+DEPENDS += "automoc-native clucene-core"
+
+PV = "2.1"
+SRC_URI = "svn://anonsvn.kde.org/home/kde/branches/soprano;module=${PV};proto=svn"
+
+S= "${WORKDIR}/${PV}"
+
diff --git a/packages/kde4/strigi_0.5.10.bb b/packages/kde4/strigi_0.5.10.bb
new file mode 100644
index 0000000000..3dacbfa2f0
--- /dev/null
+++ b/packages/kde4/strigi_0.5.10.bb
@@ -0,0 +1,17 @@
+inherit qt4x11 cmake
+
+DEPENDS += "clucene-core pidgin expat gamin"
+
+SRC_URI = "${SOURCEFORGE_MIRROR}/strigi/strigi-${PV}.tar.bz2"
+
+EXTRA_OECMAKE = "-DENABLE_FAM:BOOL=ON \
+ -DENABLE_EXPAT:BOOL=ON \
+ -DENABLE_INOTIFY:BOOL=ON \
+ -DGAMIN_LIBARIES:STRING=${STAGING_LIBDIR} \
+ -DGAMIN_LIBRARIES:STRING=${STAGING_LIBDIR} \
+ "
+
+FILES_${PN} += "${datadir}/dbus-1 \
+ "
+
+
diff --git a/packages/kexecboot/files/kexecboot-rewrite.patch b/packages/kexecboot/files/kexecboot-rewrite.patch
new file mode 100644
index 0000000000..4f252061ab
--- /dev/null
+++ b/packages/kexecboot/files/kexecboot-rewrite.patch
@@ -0,0 +1,344 @@
+--- kexecboot-0.3.orig/kexecboot.h 2008-09-03 02:35:40.000000000 +0400
++++ kexecboot-0.3/kexecboot.h 2008-09-03 02:36:04.000000000 +0400
+@@ -24,6 +24,10 @@
+ #include <string.h>
+ #include <linux/input.h>
+ #include <termios.h>
++#include <unistd.h>
++#include <signal.h>
++#include <sys/wait.h>
++#include <ctype.h>
+ #include "fb.h"
+ #include "devicescan.h"
+ #include "res/logo-img.h"
+@@ -33,4 +37,14 @@
+ #include "res/memory-img.h"
+ #include "res/radeon-font.h"
+
++/* Macro for dealing with NULL strings */
++#define strlenn(s) ( (NULL != s) ? (strlen(s)) : 0 )
++
++/* Tags we want from /proc/cmdline */
++char *wanted_tags[] = {
++ "mtdparts",
++ NULL
++};
++
++
+ #endif
+--- kexecboot-0.3.orig/kexecboot.c 2008-09-03 02:35:40.000000000 +0400
++++ kexecboot-0.3/kexecboot.c 2008-09-03 03:33:05.000000000 +0400
+@@ -78,20 +78,293 @@
+ fb_render(fb);
+ }
+
++/*
++ * Function: get_extra_cmdline()
++ * It gets wanted tags from original cmdline.
++ * Takes 2 args:
++ * - extra_cmdline - buffer to store cmdline parameters;
++ * - extra_cmdline_size - size of buffer
++ * (inc. terminating '\0').
++ * Return values:
++ * - length of extra_cmdline on success (w/o term. zero);
++ * - -1 on error;
++ * - (- length of extra_cmdline - 1) on insufficient buffer space.
++ */
++
++int get_extra_cmdline(char *const extra_cmdline, const size_t extra_cmdline_size)
++{
++ char *p, *t, *tag = NULL;
++ char line[COMMAND_LINE_SIZE];
++ int i, len, sp_size;
++ int sum_len = 0;
++ int wanted_tag_found = 0;
++ int overflow = 0;
++
++ const char proc_cmdline_path[] = "/proc/cmdline";
++
++ /* Open /proc/cmdline and read cmdline */
++ FILE *f = fopen(proc_cmdline_path, "r");
++ if (NULL == f) {
++ perror("Can't open /proc/cmdline");
++ return -1;
++ }
++
++ if ( NULL == fgets(line, sizeof(line), f) ) {
++ perror("Can't read /proc/cmdline");
++ fclose(f);
++ return -1;
++ }
++
++ fclose(f);
++
++ /* clean up buffer before parsing */
++ t = extra_cmdline;
++ *t = '\0';
++
++ p = line-1; /* because of ++p below */
++
++ sp_size = 0; /* size of (first) space */
++
++ do {
++ ++p;
++
++ if ( (NULL == tag) && (isalnum(*p)) ) {
++ /* new tag found */
++ tag = p;
++ } else if (tag) {
++ /* we are working on some tag */
++
++ if (isspace(*p) || ('\0' == *p) || ('=' == *p) ) {
++ /* end of tag or '=' found */
++
++ if (!wanted_tag_found) {
++ /* search in wanted_tags */
++ for (i = 0; wanted_tags[i] != NULL; i++) {
++ if ( 0 == strncmp(wanted_tags[i], tag, p-tag) ) {
++ /* match found */
++ wanted_tag_found = 1;
++ break;
++ }
++ }
++ }
++
++ if ( ('=' != *p) && wanted_tag_found ) {
++ /* end of wanted tag found -> copy */
++
++ len = p - tag;
++ if ( (sum_len + len + sp_size) < extra_cmdline_size ) {
++ if (sp_size) {
++ /* prepend space when have tags already */
++ *t = ' ';
++ ++t;
++ *t = '\0';
++ ++sum_len;
++ } else {
++ sp_size = sizeof(char);
++ }
++
++ /* NOTE: tag is not null-terminated so copy only
++ * len chars and terminate it directly
++ */
++ strncpy(t, tag, len);
++ /* move pointer to position after copied tag */
++ t += len ;
++ /* null-terminate */
++ *t = '\0';
++ /* update summary length */
++ sum_len += len;
++ } else {
++ /* we have no space - skip this tag */
++ overflow = 1;
++ }
++
++ /* reset wanted_tag_found */
++ wanted_tag_found = 0;
++ }
++
++ /* reset tag */
++ if (!wanted_tag_found) tag = NULL;
++
++ }
++ }
++
++ } while ('\0' != *p);
++
++ if (overflow) return -sum_len-1;
++ return sum_len;
++}
++
++/*
++ * Function: kexec_execw()
++ * (execve and wait)
++ * kexecboot's replace of system() call without /bin/sh invocation.
++ * During execution of the command, SIGCHLD will be blocked,
++ * and SIGINT and SIGQUIT will be ignored (like system() does).
++ * Takes 2 args (execve()-like):
++ * - path - full path to executable file
++ * - argv[] - array of args for executed file (command options e.g.)
++ * - envp[] - array of environment strings ("key=value")
++ * Return value:
++ * - command exit status on success
++ * - -1 on error (e.g. fork() failed)
++ */
++int kexec_execw(const char *path, char *const argv[], char *const envp[])
++{
++ pid_t pid;
++ struct sigaction ignore, old_int, old_quit;
++ sigset_t masked, oldmask;
++ int status;
++
++ /* Block SIGCHLD and ignore SIGINT and SIGQUIT */
++ /* Do this before the fork() to avoid races */
++
++ ignore.sa_handler = SIG_IGN;
++ sigemptyset(&ignore.sa_mask);
++ ignore.sa_flags = 0;
++ sigaction(SIGINT, &ignore, &old_int);
++ sigaction(SIGQUIT, &ignore, &old_quit);
++
++ sigemptyset(&masked);
++ sigaddset(&masked, SIGCHLD);
++ sigprocmask(SIG_BLOCK, &masked, &oldmask);
++
++ pid = fork();
++
++ if (pid < 0)
++ /* can't fork */
++ return -1;
++ else if (pid == 0) {
++ /* it is child */
++ sigaction(SIGINT, &old_int, NULL);
++ sigaction(SIGQUIT, &old_quit, NULL);
++ sigprocmask(SIG_SETMASK, &oldmask, NULL);
++
++ /* replace child with executed file */
++ execve(path, (char *const *)argv, (char *const *)envp);
++ /* should not happens but... */
++ _exit(127);
++ }
++
++ /* it is parent */
++
++ /* wait for our child and store status */
++ waitpid(pid, &status, 0);
++
++ /* restore signal handlers */
++ sigaction(SIGINT, &old_int, NULL);
++ sigaction(SIGQUIT, &old_quit, NULL);
++ sigprocmask(SIG_SETMASK, &oldmask, NULL);
++
++ return status;
++}
++
+ void start_kernel(struct boot *boot)
+ {
+- //kexec --command-line="CMDLINE" -l /mnt/boot/zImage
+- char command[COMMAND_LINE_SIZE + 60];
+- mount(boot->device, "/mnt", boot->fstype, MS_RDONLY, NULL);
+- if( boot->cmdline )
+- sprintf(command,"/usr/sbin/kexec --command-line=\"%s root=%s rootfstype=%s\" -l %s",
+- boot->cmdline, boot->device, boot->fstype, boot->kernelpath);
+- else
+- sprintf(command,"kexec -l %s", boot->kernelpath);
+- system(command);
+-// puts(command);
+- umount("/mnt");
+- system("/usr/sbin/kexec -e");
++ /* we use var[] instead of *var because sizeof(var) using */
++ const char mount_point[] = "/mnt";
++ const char kexec_path[] = "/usr/sbin/kexec";
++
++ const char str_cmdline_start[] = "--command-line=";
++ const char str_root[] = " root=";
++ const char str_rootfstype[] = " rootfstype=";
++ const char str_rootwait[] = " rootwait";
++
++ /* empty environment */
++ char *const envp[] = { NULL };
++
++ const char *kexec_load_argv[] = { NULL, "-l", NULL, NULL, NULL };
++ const char *kexec_exec_argv[] = { NULL, "-e", NULL};
++
++ char extra_cmdline_buffer[COMMAND_LINE_SIZE];
++ char *extra_cmdline, *cmdline_arg = NULL;
++ int n, idx;
++
++ kexec_exec_argv[0] = kexec_path;
++ kexec_load_argv[0] = kexec_path;
++
++ /* --command-line arg generation */
++ idx = 2; /* kexec_load_argv current option index */
++
++ /* get some parts of cmdline from boot loader (e.g. mtdparts) */
++ n = get_extra_cmdline( extra_cmdline_buffer,
++ sizeof(extra_cmdline_buffer) );
++ if ( -1 == n ) {
++ /* clean up extra_cmdline on error */
++ extra_cmdline = NULL;
++/* } else if ( n < -1 ) { */
++ /* Do something when we have no space to get all wanted tags */
++ /* Now do nothing ;) */
++ } else {
++ extra_cmdline = extra_cmdline_buffer;
++ }
++
++ /* fill '--command-line' option */
++ if (boot->cmdline || extra_cmdline || boot->device) {
++ /* allocate space */
++ n = strlenn(str_cmdline_start) + strlenn(boot->cmdline) +
++ sizeof(char) + strlenn(extra_cmdline) +
++ strlenn(str_root) + strlenn(boot->device) +
++ strlenn(str_rootfstype) + strlenn(boot->fstype) +
++ strlenn(str_rootwait) + sizeof(char);
++
++ cmdline_arg = (char *)malloc(n);
++ if (NULL == cmdline_arg) {
++ perror("Can't allocate memory for cmdline_arg");
++ /* Should we exit?
++ exit(-1);
++ */
++ } else {
++ strcat(cmdline_arg, str_cmdline_start);
++ if (extra_cmdline)
++ strcat(cmdline_arg, extra_cmdline);
++ if (boot->cmdline && extra_cmdline)
++ strcat(cmdline_arg, " ");
++ if (boot->cmdline)
++ strcat(cmdline_arg, boot->cmdline);
++ if (boot->device) {
++ strcat(cmdline_arg, str_root);
++ strcat(cmdline_arg, boot->device);
++ if (boot->fstype) {
++ strcat(cmdline_arg, str_rootfstype);
++ strcat(cmdline_arg, boot->fstype);
++ }
++ }
++ strcat(cmdline_arg, str_rootwait);
++
++ kexec_load_argv[idx] = cmdline_arg;
++ ++idx;
++ }
++ }
++
++ /* Append kernelpath as last arg of kexec */
++ kexec_load_argv[idx] = boot->kernelpath;
++
++ /* Debug
++ fprintf(stderr, "%s\n%s\n%s\n%s\n", kexec_load_argv[0],
++ kexec_load_argv[1], kexec_load_argv[2],
++ kexec_load_argv[3]); */
++
++ /* Mount boot device */
++ if ( -1 == mount(boot->device, mount_point, boot->fstype,
++ MS_RDONLY, NULL) ) {
++ perror("Can't mount boot device");
++ exit(-1);
++ }
++
++ /* Load kernel */
++ n = kexec_execw(kexec_path, (char *const *)kexec_load_argv, envp);
++ if (-1 == n) {
++ perror("Kexec can't load kernel");
++ exit(-1);
++ }
++
++ if (cmdline_arg)
++ free(cmdline_arg);
++
++ umount(mount_point);
++
++ /* Boot new kernel */
++ execve(kexec_path, (char *const *)kexec_exec_argv, envp);
+ }
+
+ int main(int argc, char **argv)
+@@ -219,5 +492,6 @@
+ tcsetattr(fileno(stdin), TCSANOW, &old);
+ fb_destroy(fb);
+ start_kernel(bl->list[choice]);
+- return 0;
++ /* When we reach this point then some error was occured */
++ return -1;
+ }
diff --git a/packages/kexecboot/files/rootdelay.patch b/packages/kexecboot/files/rootdelay.patch
deleted file mode 100644
index 19a712ab57..0000000000
--- a/packages/kexecboot/files/rootdelay.patch
+++ /dev/null
@@ -1,11 +0,0 @@
---- kexecboot-0.3/kexecboot.c 2008-08-03 17:08:31.000000000 +0200
-+++ kexecboot/kexecboot.c 2008-08-04 13:35:32.167062391 +0200
-@@ -84,7 +84,7 @@
- char command[COMMAND_LINE_SIZE + 60];
- mount(boot->device, "/mnt", boot->fstype, MS_RDONLY, NULL);
- if( boot->cmdline )
-- sprintf(command,"/usr/sbin/kexec --command-line=\"%s root=%s rootfstype=%s\" -l %s",
-+ sprintf(command,"/usr/sbin/kexec --command-line=\"%s root=%s rootfstype=%s rootdelay=3\" -l %s",
- boot->cmdline, boot->device, boot->fstype, boot->kernelpath);
- else
- sprintf(command,"kexec -l %s", boot->kernelpath);
diff --git a/packages/kexecboot/initramfs-kexecboot_1.0.bb b/packages/kexecboot/initramfs-kexecboot_1.0.bb
index 75fb8e8708..a6450b0bfb 100644
--- a/packages/kexecboot/initramfs-kexecboot_1.0.bb
+++ b/packages/kexecboot/initramfs-kexecboot_1.0.bb
@@ -1,8 +1,9 @@
DESCRIPTON = "A init script that mounts a device and kexecs a new kernel from it."
-PR = "r7"
+PR = "r8"
RDEPENDS = "kexecboot klibc-utils-static-mount klibc-utils-static-sh klibc-utils-static-sleep"
FBANGLE = "270"
+FBANGLE_c7x0 = "0"
INPUTDEV = "/dev/event0"
diff --git a/packages/kexecboot/kexecboot_0.3.bb b/packages/kexecboot/kexecboot_0.3.bb
index f3fb6e35cb..f94e31b4e2 100644
--- a/packages/kexecboot/kexecboot_0.3.bb
+++ b/packages/kexecboot/kexecboot_0.3.bb
@@ -1,21 +1,21 @@
LICENSE = "GPL"
-PR = "r1"
+PR = "r2"
DEPENDS = "klibc"
RDEPENDS = "kexec-static"
+
inherit autotools
# You can create your own *-img.h by doing
# ./make-image-header.sh <file>.png HAND
SRC_URI = "http://projects.linuxtogo.org/frs/download.php/221/kexecboot-${PV}.tar.gz \
- file://rootdelay.patch;patch=1"
-S = "${WORKDIR}/kexecboot-${PV}"
+ file://kexecboot-rewrite.patch;patch=1"
+S = "${WORKDIR}/kexecboot-${PV}"
export CC=${TARGET_PREFIX}klcc
# standart oe cflags don't work with klcc
-export CFLAGS=""
-export CPPFLAGS=""
-export LDFLAGS=""
-
+export CFLAGS = ""
+export CPPFLAGS = ""
+export LDFLAGS = ""
diff --git a/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-akita b/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-akita
index e630a9abff..21201dabc2 100644
--- a/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-akita
+++ b/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-akita
@@ -53,7 +53,8 @@ CONFIG_FAIR_USER_SCHED=y
# CONFIG_FAIR_CGROUP_SCHED is not set
CONFIG_SYSFS_DEPRECATED=y
# CONFIG_RELAY is not set
-# CONFIG_BLK_DEV_INITRD is not set
+CONFIG_BLK_DEV_INITRD=y
+CONFIG_INITRAMFS_SOURCE="initramfs.cpio.gz"
CONFIG_CC_OPTIMIZE_FOR_SIZE=y
CONFIG_SYSCTL=y
CONFIG_EMBEDDED=y
diff --git a/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-bootcdx86 b/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-bootcdx86
index 35e9b5cd22..1176bc70bd 100644
--- a/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-bootcdx86
+++ b/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-bootcdx86
@@ -72,7 +72,7 @@ CONFIG_FAIR_USER_SCHED=y
CONFIG_SYSFS_DEPRECATED=y
# CONFIG_RELAY is not set
CONFIG_BLK_DEV_INITRD=y
-CONFIG_INITRAMFS_SOURCE=""
+CONFIG_INITRAMFS_SOURCE="initramfs.cpio.gz"
# CONFIG_CC_OPTIMIZE_FOR_SIZE is not set
CONFIG_SYSCTL=y
CONFIG_EMBEDDED=y
diff --git a/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-c7x0 b/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-c7x0
index 6c188e7b57..b57b4c7277 100644
--- a/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-c7x0
+++ b/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-c7x0
@@ -53,7 +53,8 @@ CONFIG_FAIR_USER_SCHED=y
# CONFIG_FAIR_CGROUP_SCHED is not set
CONFIG_SYSFS_DEPRECATED=y
# CONFIG_RELAY is not set
-# CONFIG_BLK_DEV_INITRD is not set
+CONFIG_BLK_DEV_INITRD=y
+CONFIG_INITRAMFS_SOURCE="initramfs.cpio.gz"
CONFIG_CC_OPTIMIZE_FOR_SIZE=y
CONFIG_SYSCTL=y
CONFIG_EMBEDDED=y
diff --git a/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-htcuniversal b/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-htcuniversal
index 8b2a31dbb0..e9d5dc1e22 100644
--- a/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-htcuniversal
+++ b/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-htcuniversal
@@ -53,7 +53,8 @@ CONFIG_FAIR_USER_SCHED=y
# CONFIG_FAIR_CGROUP_SCHED is not set
CONFIG_SYSFS_DEPRECATED=y
# CONFIG_RELAY is not set
-# CONFIG_BLK_DEV_INITRD is not set
+CONFIG_BLK_DEV_INITRD=y
+CONFIG_INITRAMFS_SOURCE="initramfs.cpio.gz"
CONFIG_CC_OPTIMIZE_FOR_SIZE=y
CONFIG_SYSCTL=y
CONFIG_EMBEDDED=y
diff --git a/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-hx2000 b/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-hx2000
index 0f2557c0f7..1fcf2bb910 100644
--- a/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-hx2000
+++ b/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-hx2000
@@ -54,7 +54,7 @@ CONFIG_FAIR_USER_SCHED=y
CONFIG_SYSFS_DEPRECATED=y
# CONFIG_RELAY is not set
CONFIG_BLK_DEV_INITRD=y
-CONFIG_INITRAMFS_SOURCE=""
+CONFIG_INITRAMFS_SOURCE="initramfs.cpio.gz"
CONFIG_CC_OPTIMIZE_FOR_SIZE=y
CONFIG_SYSCTL=y
CONFIG_EMBEDDED=y
diff --git a/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-poodle b/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-poodle
index 7d41252b15..a89a82bee8 100644
--- a/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-poodle
+++ b/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-poodle
@@ -53,7 +53,8 @@ CONFIG_FAIR_USER_SCHED=y
# CONFIG_FAIR_CGROUP_SCHED is not set
CONFIG_SYSFS_DEPRECATED=y
# CONFIG_RELAY is not set
-# CONFIG_BLK_DEV_INITRD is not set
+CONFIG_BLK_DEV_INITRD=y
+CONFIG_INITRAMFS_SOURCE="initramfs.cpio.gz"
CONFIG_CC_OPTIMIZE_FOR_SIZE=y
CONFIG_SYSCTL=y
CONFIG_EMBEDDED=y
diff --git a/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-qemuarm b/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-qemuarm
index e636b6c671..6a4502f95b 100644
--- a/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-qemuarm
+++ b/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-qemuarm
@@ -53,7 +53,7 @@ CONFIG_FAIR_USER_SCHED=y
CONFIG_SYSFS_DEPRECATED=y
# CONFIG_RELAY is not set
CONFIG_BLK_DEV_INITRD=y
-CONFIG_INITRAMFS_SOURCE=""
+CONFIG_INITRAMFS_SOURCE="initramfs.cpio.gz"
CONFIG_CC_OPTIMIZE_FOR_SIZE=y
CONFIG_SYSCTL=y
CONFIG_EMBEDDED=y
diff --git a/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-qemux86 b/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-qemux86
index 42f6740201..3724f1602b 100644
--- a/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-qemux86
+++ b/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-qemux86
@@ -72,7 +72,7 @@ CONFIG_FAIR_USER_SCHED=y
CONFIG_SYSFS_DEPRECATED=y
# CONFIG_RELAY is not set
CONFIG_BLK_DEV_INITRD=y
-CONFIG_INITRAMFS_SOURCE=""
+CONFIG_INITRAMFS_SOURCE="initramfs.cpio.gz"
# CONFIG_CC_OPTIMIZE_FOR_SIZE is not set
CONFIG_SYSCTL=y
CONFIG_EMBEDDED=y
diff --git a/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-spitz b/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-spitz
index 9c8f0ae8a1..cc66e0f10e 100644
--- a/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-spitz
+++ b/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-spitz
@@ -52,7 +52,8 @@ CONFIG_SYSFS_DEPRECATED=y
CONFIG_SYSFS_DEPRECATED_V2=y
# CONFIG_RELAY is not set
# CONFIG_NAMESPACES is not set
-# CONFIG_BLK_DEV_INITRD is not set
+CONFIG_BLK_DEV_INITRD=y
+CONFIG_INITRAMFS_SOURCE="initramfs.cpio.gz"
CONFIG_CC_OPTIMIZE_FOR_SIZE=y
CONFIG_SYSCTL=y
CONFIG_EMBEDDED=y
diff --git a/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-zylonite b/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-zylonite
index cc2fc482ae..3e7f96f6a7 100644
--- a/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-zylonite
+++ b/packages/kexecboot/linux-kexecboot-2.6.26/defconfig-zylonite
@@ -53,7 +53,8 @@ CONFIG_FAIR_USER_SCHED=y
# CONFIG_FAIR_CGROUP_SCHED is not set
CONFIG_SYSFS_DEPRECATED=y
# CONFIG_RELAY is not set
-# CONFIG_BLK_DEV_INITRD is not set
+CONFIG_BLK_DEV_INITRD=y
+CONFIG_INITRAMFS_SOURCE="initramfs.cpio.gz"
CONFIG_CC_OPTIMIZE_FOR_SIZE=y
CONFIG_SYSCTL=y
CONFIG_EMBEDDED=y
diff --git a/packages/kexecboot/linux-kexecboot.inc b/packages/kexecboot/linux-kexecboot.inc
index 1671a49512..5926778eff 100644
--- a/packages/kexecboot/linux-kexecboot.inc
+++ b/packages/kexecboot/linux-kexecboot.inc
@@ -4,6 +4,12 @@ LICENSE = "GPL"
DONT_CHECK_KERNELSIZE = ""
INITRAMFS_IMAGE = "initramfs-kexecboot-image"
+
+# uncomment the following lines if you use u-boot as bootloader
+#KERNEL_IMAGETYPE_c7x0="uImage"
+#KERNEL_IMAGETYPE_akita="uImage"
+#KERNEL_IMAGETYPE_spitz="uImage"
+
inherit kernel
PACKAGES = ""
PROVIDES = ""
diff --git a/packages/kexecboot/linux-kexecboot_2.6.26.bb b/packages/kexecboot/linux-kexecboot_2.6.26.bb
index 5d31aae5cb..2be42e6c17 100644
--- a/packages/kexecboot/linux-kexecboot_2.6.26.bb
+++ b/packages/kexecboot/linux-kexecboot_2.6.26.bb
@@ -1,11 +1,13 @@
require linux-kexecboot.inc
-PR = "r2"
+PR = "r3"
DEFAULT_PREFERENCE = "-1"
DEFAULT_PREFERENCE_qemuarm = "-1"
DEFAULT_PREFERENCE_qemux86 = "-1"
DEFAULT_PREFERENCE_spitz = "1"
DEFAULT_PREFERENCE_collie = "1"
+DEFAULT_PREFERENCE_c7x0 = "1"
+DEFAULT_PREFERENCE_akita = "1"
# Handy URLs
# git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux-2.6.git;protocol=git;tag=ef7d1b244fa6c94fb76d5f787b8629df64ea4046
diff --git a/packages/nonworking/clucene/clucene-0.8.12-pre/compile-fix.patch b/packages/nonworking/clucene/clucene-0.8.12-pre/compile-fix.patch
deleted file mode 100644
index 5f6c8f1911..0000000000
--- a/packages/nonworking/clucene/clucene-0.8.12-pre/compile-fix.patch
+++ /dev/null
@@ -1,23 +0,0 @@
-
-#
-# Patch managed by http://www.mn-logistik.de/unsupported/pxa250/patcher
-#
-
---- clucene-0.8.11-r0/src/CLucene/store/Lock.cpp~compile-fix 2004-04-13 15:43:21.000000000 +0200
-+++ clucene-0.8.11-r0/src/CLucene/store/Lock.cpp 2004-07-08 00:21:06.000000000 +0200
-@@ -1,6 +1,6 @@
- #include "CLucene/StdHeader.h"
- #include "Lock.h"
--
-+using namespace std;
- namespace lucene{ namespace store{
-
- LuceneLockWith::~LuceneLockWith(){
---- clucene-0.8.11-r0/Makefile.am~compile-fix 2003-11-04 07:54:04.000000000 +0100
-+++ clucene-0.8.11-r0/Makefile.am 2004-07-08 00:22:43.000000000 +0200
-@@ -2,4 +2,4 @@
-
- INCLUDES = -I$(top_srcdir)
-
--SUBDIRS = src wrappers examples .
-+SUBDIRS = src wrappers .
diff --git a/packages/nonworking/clucene/clucene_0.8.12-pre.bb b/packages/nonworking/clucene/clucene_0.8.12-pre.bb
deleted file mode 100644
index 2c8122c921..0000000000
--- a/packages/nonworking/clucene/clucene_0.8.12-pre.bb
+++ /dev/null
@@ -1,24 +0,0 @@
-DESCRIPTION = "CLucene is a C++ port of Lucene: the high-performance, full-featured text search engine written in Java."
-SECTION = "libs"
-LICENSE = "LGPL"
-PRIORITY = "optional"
-SRCDATE = "20040704"
-SRC_URI = "cvs://anonymous@clucene.cvs.sourceforge.net/cvsroot/clucene;module=. \
- file://compile-fix.patch;patch=1"
-S = "${WORKDIR}"
-
-inherit autotools
-
-do_stage() {
- oe_libinstall -C src libclucene ${STAGING_LIBDIR}
- install -d ${STAGING_INCDIR}/CLucene/
- install src/CLucene.h ${STAGING_INCDIR}/CLucene/
- cd src
- headers=`find . -name "*.h"`
- for f in $headers
- do
- install -d ${STAGING_INCDIR}/`dirname $f`
- install -m 0644 $f ${STAGING_INCDIR}/$f
- done
- echo > ${STAGING_INCDIR}/CLucene/util/dirent.h
-}