Bug#574285: cdebconf: Please switch from DirectFB to X11
Source: cdebconf
Version: 0.148
Severity: wishlist
Tags: d-i patch
Hi,
please find attached the patch to switch from DirectFB to X11. See
http://lists.debian.org/debian-boot/2010/03/msg00313.html for the
details.
Thanks for considering.
Mraw,
KiBi.
Index: debian/control
===================================================================
--- debian/control (révision 62665)
+++ debian/control (copie de travail)
@@ -1,7 +1,7 @@
Source: cdebconf
Section: utils
Priority: optional
-Build-Depends: debhelper (>= 7.0.0~), po-debconf (>= 0.5.0), libslang2-dev, libnewt-dev, libtextwrap-dev (>= 0.1-5), libdebian-installer4-dev (>= 0.41) | libdebian-installer-dev, libgtk-directfb-2.0-dev (>= 2.8.18-5), libcairo2-dev (>= 1.6.4-6.1)
+Build-Depends: debhelper (>= 7.0.0~), po-debconf (>= 0.5.0), libslang2-dev, libnewt-dev, libtextwrap-dev (>= 0.1-5), libdebian-installer4-dev (>= 0.41) | libdebian-installer-dev, libgtk2.0-dev (>= 2.18.7-2), libcairo2-dev (>= 1.8.10-3)
Maintainer: Debian Install System Team <debian-boot@lists.debian.org>
Uploaders: Joey Hess <joeyh@debian.org>, Colin Watson <cjwatson@debian.org>, Bastian Blank <waldi@debian.org>, Jérémy Bobbio <lunar@debian.org>, Nicolas FRANCOIS (Nekral) <nicolas.francois@centraliens.net>
Standards-Version: 3.8.4
Index: debian/changelog
===================================================================
--- debian/changelog (révision 62665)
+++ debian/changelog (copie de travail)
@@ -1,8 +1,21 @@
cdebconf (0.149) UNRELEASED; urgency=low
+ [ Colin Watson ]
* Remove unused variable in newt_initialize.
* Silence compiler warning in dpkg-reconfigure when filling argv.
+ [ Cyril Brulebois ]
+ * Switch udeb from DirectFB to Xlib to prepare the move to an X11-based
+ graphical installer:
+ - Replace libgtk-directfb-2.0-dev with libgtk2.0-dev, versioned to
+ ensure the new udeb gets a dependency on libgtk-x11-udeb.
+ - Bump the Build-Depends on libcairo2-dev to ensure the new udeb gets
+ a dependency on libcairo2-udeb.
+ - Disable DirectFB includes and dfb_input_device_reload_keymap().
+ - Update libraries in pkg-config calls.
+ - Set a default cursor after having switched to fullscreen.
+ * Many thanks to Julien Cristau for his patches.
+
-- Colin Watson <cjwatson@debian.org> Tue, 23 Feb 2010 12:34:16 +0000
cdebconf (0.148) unstable; urgency=low
Index: src/modules/frontend/gtk/ui.c
===================================================================
--- src/modules/frontend/gtk/ui.c (révision 62665)
+++ src/modules/frontend/gtk/ui.c (copie de travail)
@@ -454,6 +454,7 @@
GtkWidget * dialog;
GtkWidget * vbox;
GtkWidget * frame;
+ GtkWidget * label;
/* XXX: check NULL! */
dialog = gtk_window_new(GTK_WINDOW_TOPLEVEL);
@@ -465,13 +466,17 @@
gtk_window_set_decorated(GTK_WINDOW(dialog), FALSE /* no decoration */);
gtk_container_set_border_width(GTK_CONTAINER(dialog), 0 /* no border */);
+ /* Create a wrapped label */
+ label = gtk_label_new(message);
+ gtk_label_set_line_wrap(GTK_LABEL(label), TRUE);
+
/* XXX: check NULL! */
vbox = gtk_vbox_new(FALSE /* don't make children equal */,
DEFAULT_PADDING);
gtk_box_pack_start(GTK_BOX(vbox), create_dialog_title_label(title),
FALSE /* don't expand */, FALSE /* don't fill */,
0 /* no padding */);
- gtk_box_pack_start(GTK_BOX(vbox), gtk_label_new(message),
+ gtk_box_pack_start(GTK_BOX(vbox), label,
FALSE /* don't expand */, FALSE /* don't fill */,
DEFAULT_PADDING);
gtk_box_pack_start(GTK_BOX(vbox), gtk_hseparator_new(),
Index: src/modules/frontend/gtk/di.c
===================================================================
--- src/modules/frontend/gtk/di.c (révision 62665)
+++ src/modules/frontend/gtk/di.c (copie de travail)
@@ -44,9 +44,11 @@
#include <unistd.h>
#include <syslog.h>
+#if 0
#include <directfb.h>
/* for dfb_input_device_reload_keymap() and dfb_input_device_at() */
#include <core/input.h>
+#endif
#include <gtk/gtk.h>
#include "question.h"
@@ -173,6 +175,7 @@
{
struct frontend_data * fe_data = fe->data;
struct di_data * di_data;
+ GdkCursor * cursor;
g_assert(NULL == fe_data->di_data);
if (NULL == (di_data = g_malloc0(sizeof (struct di_data)))) {
@@ -189,6 +192,10 @@
make_fullscreen(fe_data->window);
+ cursor = gdk_cursor_new(GDK_LEFT_PTR);
+ gdk_window_set_cursor(gdk_get_default_root_window(), cursor);
+ gdk_cursor_unref(cursor);
+
return TRUE;
}
@@ -202,7 +209,9 @@
*/
static void refresh_keymap(struct frontend * fe)
{
+#if 0
dfb_input_device_reload_keymap(dfb_input_device_at(DIDID_KEYBOARD));
+#endif
}
/** Returns the current text direction.
Index: src/modules/frontend/gtk/Makefile
===================================================================
--- src/modules/frontend/gtk/Makefile (révision 62665)
+++ src/modules/frontend/gtk/Makefile (copie de travail)
@@ -14,10 +14,10 @@
ifneq ($(strip $(filter -DDI_UDEB, $(CFLAGS))),)
OBJS += screenshot.opic di.opic
-MODCFLAGS = `pkg-config --cflags gtk+-directfb-2.0 \
- gthread-2.0 directfb-internal`
-MODLDFLAGS = `pkg-config --libs gtk+-directfb-2.0 \
- gthread-2.0 directfb-internal` -ldebian-installer
+MODCFLAGS = `pkg-config --cflags gtk+-x11-2.0 \
+ gthread-2.0`
+MODLDFLAGS = `pkg-config --libs gtk+-x11-2.0 \
+ gthread-2.0` -ldebian-installer
else
MODCFLAGS = `pkg-config --cflags gtk+-2.0 gthread-2.0`
MODLDFLAGS = `pkg-config --libs gtk+-2.0 gthread-2.0` -ldebian-installer
Reply to: