Sapwood server added
authorKirtika Ruchandani <kirtibr@gmail.com>
Mon, 22 Jun 2009 10:50:54 +0000 (16:20 +0530)
committerKirtika Ruchandani <kirtibr@gmail.com>
Mon, 22 Jun 2009 10:50:54 +0000 (16:20 +0530)
sapwood/mer-changes.patch [new file with mode: 0644]
sapwood/socket.patch [new file with mode: 0644]
sapwood_3.1.1.bb [new file with mode: 0644]

diff --git a/sapwood/mer-changes.patch b/sapwood/mer-changes.patch
new file mode 100644 (file)
index 0000000..9f3fae0
--- /dev/null
@@ -0,0 +1,71 @@
+--- sapwood-3.1.1-2+0m5/debian/control
++++ sapwood-3.1.1-2+0m5/debian/control
+@@ -3,7 +3,7 @@
+ Priority: optional
+ Maintainer: Tommi Komulainen <tommi.komulainen@nokia.com>
+ Standards-Version: 3.6.0
+-Build-Depends: debhelper (>> 4.0.0), libgtk2.0-dev (>= 2.8.0), upstart-dev
++Build-Depends: debhelper (>> 4.0.0), libgtk2.0-dev (>= 2.8.0), upstart-dev, automake, autoconf, libtool
+ Package: gtk2-engines-sapwood
+ Architecture: any
+--- sapwood-3.1.1-2+0m5/debian/changelog
++++ sapwood-3.1.1-2+0m5/debian/changelog
+@@ -1,3 +1,10 @@
++sapwood (3.1.1-2+0m5-mer1) jaunty; urgency=low
++
++  * Add automake, libtool, autoconf to build-dep
++  * Fix bad alignment on < ARMv6, causing crashes on 770 (thanks to RST38h)
++
++ -- Carsten V. Munk <cvm@cs.au.dk>  Thu, 21 May 2009 19:58:41 +0000
++
+ sapwood (3.1.1-2+0m5) unstable; urgency=low
+   * This entry has been added by BIFH queue processor
+--- sapwood-3.1.1-2+0m5/engine/sapwood-pixmap.c
++++ sapwood-3.1.1-2+0m5/engine/sapwood-pixmap.c
+@@ -91,14 +91,19 @@
+                              GError    **err)
+ {
+   SapwoodPixmap     *self;
+-  char               buf[ sizeof(PixbufOpenRequest) + PATH_MAX + 1 ] = {0};
+-  PixbufOpenRequest *req = (PixbufOpenRequest *) buf;
+   PixbufOpenResponse rep;
+   int                flen;
+   int                i, j;
++  struct
++  {
++    PixbufOpenRequest request;
++    char namebuf[PATH_MAX+1];
++  } req;
++  memset(&req, 0, sizeof(req));
++      
+   /* marshal request */
+-  flen = g_strlcpy (req->filename, filename, PATH_MAX);
++  flen = g_strlcpy (req.request.filename, filename, PATH_MAX);
+   if (flen > PATH_MAX)
+     {
+       g_set_error (err, SAPWOOD_CLIENT_ERROR, SAPWOOD_CLIENT_ERROR_UNKNOWN,
+@@ -106,14 +111,14 @@
+       return NULL;
+     }
+-  req->base.op       = PIXBUF_OP_OPEN;
+-  req->base.length   = sizeof(*req) + flen + 1;
+-  req->border_left   = border_left;
+-  req->border_right  = border_right;
+-  req->border_top    = border_top;
+-  req->border_bottom = border_bottom;
++  req.request.base.op       = PIXBUF_OP_OPEN;
++  req.request.base.length   = sizeof(PixbufOpenRequest) + flen + 1;
++  req.request.border_left   = border_left;
++  req.request.border_right  = border_right;
++  req.request.border_top    = border_top;
++  req.request.border_bottom = border_bottom;
+-  if (!pixbuf_proto_request ((char*)req,  req->base.length,
++  if (!pixbuf_proto_request ((char*)&req,  req.request.base.length,
+                            (char*)&rep, sizeof(rep), err))
+     return NULL;
diff --git a/sapwood/socket.patch b/sapwood/socket.patch
new file mode 100644 (file)
index 0000000..2960cf7
--- /dev/null
@@ -0,0 +1,96 @@
+diff --git a/configure.in b/configure.in
+index bd36a9b..6f85678 100644
+--- configure.in
++++ configure.in
+@@ -14,51 +14,52 @@ AC_PROG_INSTALL
+ AC_PROG_MAKE_SET
+ dnl abstract sockets namespace checks, from dbus
+-AC_ARG_ENABLE(abstract-sockets,
+-            [AC_HELP_STRING([--enable-abstract-sockets],
+-                            [use abstract socket namespace (linux only)])],
+-            [enable_abstract_sockets=$enableval],
+-            [enable_abstract_sockets=auto])
+-
+-AC_MSG_CHECKING(abstract socket namespace)
+-AC_RUN_IFELSE([AC_LANG_PROGRAM(
+-[[
++#AC_ARG_ENABLE(abstract-sockets,
++#           [AC_HELP_STRING([--enable-abstract-sockets],
++#                           [use abstract socket namespace (linux only)])],
++#           [enable_abstract_sockets=$enableval],
++#           [enable_abstract_sockets=auto])
++#
++#AC_MSG_CHECKING(abstract socket namespace)
++#AC_RUN_IFELSE([AC_LANG_PROGRAM(
++#[[
+ #include <sys/types.h>
+ #include <stdlib.h>
+ #include <stdio.h>
+ #include <sys/socket.h>
+ #include <sys/un.h>
+ #include <errno.h>
+-]],
+-[[
+-  int listen_fd;
+-  struct sockaddr_un addr;
+-
+-  listen_fd = socket (PF_UNIX, SOCK_STREAM, 0);
+-
+-  if (listen_fd < 0)
+-    {
+-      fprintf (stderr, "socket() failed: %s\n", strerror (errno));
+-      exit (1);
+-    }
+-
+-  memset (&addr, '\0', sizeof (addr));
+-  addr.sun_family = AF_UNIX;
+-  strcpy (addr.sun_path, "X/tmp/sapwood-fake-socket-path-used-in-configure-test");
+-  addr.sun_path[0] = '\0'; /* this is what makes it abstract */
+-
+-  if (bind (listen_fd, (struct sockaddr*) &addr, SUN_LEN (&addr)) < 0)
+-    {
+-      fprintf (stderr, "Abstract socket namespace bind() failed: %s\n",
+-               strerror (errno));
+-      exit (1);
+-    }
+-  else
+-    exit (0);
+-]])],
+-  [have_abstract_sockets=yes],
+-  [have_abstract_sockets=no])
+-AC_MSG_RESULT($have_abstract_sockets)
++#]],
++#[[
++#  int listen_fd;
++#  struct sockaddr_un addr;
++#
++#  listen_fd = socket (PF_UNIX, SOCK_STREAM, 0);
++#
++#  if (listen_fd < 0)
++#    {
++#      fprintf (stderr, "socket() failed: %s\n", strerror (errno));
++#      exit (1);
++#    }
++#
++#  memset (&addr, '\0', sizeof (addr));
++#  addr.sun_family = AF_UNIX;
++#  strcpy (addr.sun_path, "X/tmp/sapwood-fake-socket-path-used-in-configure-test");
++#  addr.sun_path[0] = '\0'; /* this is what makes it abstract */
++#
++#  if (bind (listen_fd, (struct sockaddr*) &addr, SUN_LEN (&addr)) < 0)
++#    {
++#      fprintf (stderr, "Abstract socket namespace bind() failed: %s\n",
++#               strerror (errno));
++#      exit (1);
++#    }
++#  else
++#    exit (0);
++#]])],
++#  [have_abstract_sockets=yes],
++#  [have_abstract_sockets=no])
++#AC_MSG_RESULT($have_abstract_sockets)
++enable_abstract_socket=no
+ if test x$enable_abstract_sockets = xyes; then
+   if test x$have_abstract_sockets = xno; then
diff --git a/sapwood_3.1.1.bb b/sapwood_3.1.1.bb
new file mode 100644 (file)
index 0000000..1250e1b
--- /dev/null
@@ -0,0 +1,32 @@
+# Copyright (C) 2009 Kirtika Ruchandani <kirtibr@gmail.com>
+# Released under the MIT license (see COPYING.MIT for the terms)
+
+DESCRIPTION = "Sapwood: pixbuf based theming for gtk+ 2.x"
+HOMEPAGE = "http://maemo.org"
+LICENSE = "GNU Lesser General Public License-version 2.0"
+SECTION = "x11/base"
+DEPENDS = "gtk+2.0 upstart"
+
+PR = "r2"
+
+SRC_URI = "http://repository.maemo.org/pool/fremantle/free/s/${PN}/${PN}_${PV}-2+0m5.tar.gz \
+           file://sapwood/mer-changes.patch;patch=1 \
+           file://sapwood/socket.patch;patch=1;pnum=0 "
+
+inherit autotools pkgconfig
+
+EXTRA_OECONF += "--enable-abstract-sockets=no"
+
+
+FILES_${PN} += "${libdir}/gtk-2.0/2.10.0/engines/"
+
+do_stage(){
+    autotools_stage_all
+}
+
+
+do_install_append () {
+       install -d ${D}${sysconfdir}/osso-af-init
+       install -m755 ${S}/debian/sapwood-server.sh  ${D}${sysconfdir}/osso-af-init/sapwood-server.sh
+}
+