r35474 - in /desktop/experimental/gobject-introspection/debian: changelog control control.in tests/ tests/build tests/control

mpitt at users.alioth.debian.org mpitt at users.alioth.debian.org
Wed Jun 27 10:20:30 UTC 2012


Author: mpitt
Date: Wed Jun 27 10:20:29 2012
New Revision: 35474

URL: http://svn.debian.org/wsvn/pkg-gnome/?sc=1&rev=35474
Log:
* Add debian/tests/build: autopkgtest check: Build and run a program against
  libgirepository1.0-dev, to verify that the headers and pkg-config file are
  installed correctly.
* Add debian/tests/control: DEP-8 autopkgtest control file. Add XS-Testsuite
  header to debian/control.in.

Added:
    desktop/experimental/gobject-introspection/debian/tests/
    desktop/experimental/gobject-introspection/debian/tests/build   (with props)
    desktop/experimental/gobject-introspection/debian/tests/control
Modified:
    desktop/experimental/gobject-introspection/debian/changelog
    desktop/experimental/gobject-introspection/debian/control
    desktop/experimental/gobject-introspection/debian/control.in

Modified: desktop/experimental/gobject-introspection/debian/changelog
URL: http://svn.debian.org/wsvn/pkg-gnome/desktop/experimental/gobject-introspection/debian/changelog?rev=35474&op=diff
==============================================================================
--- desktop/experimental/gobject-introspection/debian/changelog [utf-8] (original)
+++ desktop/experimental/gobject-introspection/debian/changelog [utf-8] Wed Jun 27 10:20:29 2012
@@ -1,3 +1,13 @@
+gobject-introspection (1.33.3-2) UNRELEASED; urgency=low
+
+  * Add debian/tests/build: autopkgtest check: Build and run a program against
+    libgirepository1.0-dev, to verify that the headers and pkg-config file are
+    installed correctly.
+  * Add debian/tests/control: DEP-8 autopkgtest control file. Add XS-Testsuite
+    header to debian/control.in.
+
+ -- Martin Pitt <mpitt at debian.org>  Wed, 27 Jun 2012 12:19:06 +0200
+
 gobject-introspection (1.33.3-1) experimental; urgency=low
 
   * New upstream release.

Modified: desktop/experimental/gobject-introspection/debian/control
URL: http://svn.debian.org/wsvn/pkg-gnome/desktop/experimental/gobject-introspection/debian/control?rev=35474&op=diff
==============================================================================
--- desktop/experimental/gobject-introspection/debian/control [utf-8] (original)
+++ desktop/experimental/gobject-introspection/debian/control [utf-8] Wed Jun 27 10:20:29 2012
@@ -27,6 +27,7 @@
 Homepage: http://live.gnome.org/GObjectIntrospection
 Vcs-Svn: svn://svn.debian.org/svn/pkg-gnome/desktop/unstable/gobject-introspection
 Vcs-Browser: http://svn.debian.org/viewsvn/pkg-gnome/desktop/unstable/gobject-introspection/
+XS-Testsuite: autopkgtest
 
 Package: libgirepository-1.0-1
 Section: libs

Modified: desktop/experimental/gobject-introspection/debian/control.in
URL: http://svn.debian.org/wsvn/pkg-gnome/desktop/experimental/gobject-introspection/debian/control.in?rev=35474&op=diff
==============================================================================
--- desktop/experimental/gobject-introspection/debian/control.in [utf-8] (original)
+++ desktop/experimental/gobject-introspection/debian/control.in [utf-8] Wed Jun 27 10:20:29 2012
@@ -22,6 +22,7 @@
 Homepage: http://live.gnome.org/GObjectIntrospection
 Vcs-Svn: svn://svn.debian.org/svn/pkg-gnome/desktop/unstable/gobject-introspection
 Vcs-Browser: http://svn.debian.org/viewsvn/pkg-gnome/desktop/unstable/gobject-introspection/
+XS-Testsuite: autopkgtest
 
 Package: libgirepository-1.0-1
 Section: libs

Added: desktop/experimental/gobject-introspection/debian/tests/build
URL: http://svn.debian.org/wsvn/pkg-gnome/desktop/experimental/gobject-introspection/debian/tests/build?rev=35474&op=file
==============================================================================
--- desktop/experimental/gobject-introspection/debian/tests/build (added)
+++ desktop/experimental/gobject-introspection/debian/tests/build [utf-8] Wed Jun 27 10:20:29 2012
@@ -1,0 +1,42 @@
+#!/bin/sh
+# autopkgtest check: Build and run a program against libgirepository, to verify
+# that the headers and pkg-config file are installed correctly
+# (C) 2012 Canonical Ltd.
+# Author: Martin Pitt <martin.pitt at ubuntu.com>
+
+set -e
+
+WORKDIR=$(mktemp -d)
+trap "rm -rf $WORKDIR" 0 INT QUIT ABRT PIPE TERM
+cd $WORKDIR
+cat <<EOF > gitest.c
+#include <girepository.h>
+
+int main()
+{
+    GIRepository *repository;
+    GIBaseInfo *info;
+    GList *versions, *i;
+    int ret = 1;
+
+    g_type_init();
+
+    repository = g_irepository_get_default ();
+    g_return_val_if_fail(repository != NULL, 1);
+
+    /* we depend on gir-gtk-3.0, so this should be present */
+    versions = g_irepository_enumerate_versions (repository, "Gtk");
+    for (i = g_list_first (versions); i != NULL; i = g_list_next (i))
+        if (strcmp ((gchar*) i->data, "3.0") == 0)
+           ret = 0;
+
+    return ret;
+}
+EOF
+
+gcc -o gitest gitest.c `pkg-config --cflags --libs gobject-introspection-1.0`
+echo "build: OK"
+[ -x gitest ]
+echo -n "run: "
+./gitest || { echo "FAIL"; exit 1; }
+echo "OK"

Propchange: desktop/experimental/gobject-introspection/debian/tests/build
------------------------------------------------------------------------------
    svn:executable = *

Added: desktop/experimental/gobject-introspection/debian/tests/control
URL: http://svn.debian.org/wsvn/pkg-gnome/desktop/experimental/gobject-introspection/debian/tests/control?rev=35474&op=file
==============================================================================
--- desktop/experimental/gobject-introspection/debian/tests/control (added)
+++ desktop/experimental/gobject-introspection/debian/tests/control [utf-8] Wed Jun 27 10:20:29 2012
@@ -1,0 +1,4 @@
+Tests: build 
+# deliberately avoid depending on gir1.2-glib-2.0 and friends; gir1.2-gtk-3.0
+# ought to pull these in
+Depends: gobject-introspection, libgirepository1.0-dev, gir1.2-gtk-3.0




More information about the pkg-gnome-commits mailing list