[bamf] fix build

Tom Callaway spot at fedoraproject.org
Thu Apr 25 16:03:16 UTC 2013


commit 5663a31ab8dd2ece4151dc6258a321c789d3fc72
Author: Tom Callaway <spot at fedoraproject.org>
Date:   Thu Apr 25 12:02:34 2013 -0400

    fix build

 bamf-0.3.6-glib-fix.patch |   37 +++++++++++++++++++++++++++++++++++++
 bamf.spec                 |   12 +++++++++---
 2 files changed, 46 insertions(+), 3 deletions(-)
---
diff --git a/bamf-0.3.6-glib-fix.patch b/bamf-0.3.6-glib-fix.patch
new file mode 100644
index 0000000..b3c68b8
--- /dev/null
+++ b/bamf-0.3.6-glib-fix.patch
@@ -0,0 +1,37 @@
+diff -up bamf-0.3.6/doc/reference/libbamf/Makefile.am.glibfix bamf-0.3.6/doc/reference/libbamf/Makefile.am
+--- bamf-0.3.6/doc/reference/libbamf/Makefile.am.glibfix	2013-01-11 11:57:19.981616000 -0500
++++ bamf-0.3.6/doc/reference/libbamf/Makefile.am	2013-04-25 11:39:43.231676689 -0400
+@@ -19,7 +19,7 @@ DOC_MAIN_SGML_FILE = $(DOC_MODULE)-docs.
+ DOC_SOURCE_DIR = ../../../lib/libbamf
+ 
+ # Extra options to pass to gtkdoc-scangobj. Not normally needed.
+-SCANGOBJ_OPTIONS =
++SCANGOBJ_OPTIONS = --type-init-func="g_type_class_ref(G_TYPE_OBJECT);"
+ 
+ # Extra options to supply to gtkdoc-scan.
+ # Fx --rebuild-types --rebuild-sections
+diff -up bamf-0.3.6/doc/reference/libbamf/Makefile.in.glibfix bamf-0.3.6/doc/reference/libbamf/Makefile.in
+--- bamf-0.3.6/doc/reference/libbamf/Makefile.in.glibfix	2013-04-25 11:40:16.699677191 -0400
++++ bamf-0.3.6/doc/reference/libbamf/Makefile.in	2013-04-25 11:40:30.356677396 -0400
+@@ -260,7 +260,7 @@ DOC_MAIN_SGML_FILE = $(DOC_MODULE)-docs.
+ DOC_SOURCE_DIR = ../../../lib/libbamf
+ 
+ # Extra options to pass to gtkdoc-scangobj. Not normally needed.
+-SCANGOBJ_OPTIONS = 
++SCANGOBJ_OPTIONS = --type-init-func="g_type_class_ref(G_TYPE_OBJECT);"
+ 
+ # Extra options to supply to gtkdoc-scan.
+ # Fx --rebuild-types --rebuild-sections
+diff -up bamf-0.3.6/tests/libbamf/test-libbamf.c.glibfix bamf-0.3.6/tests/libbamf/test-libbamf.c
+--- bamf-0.3.6/tests/libbamf/test-libbamf.c.glibfix	2013-01-11 11:57:19.981616000 -0500
++++ bamf-0.3.6/tests/libbamf/test-libbamf.c	2013-04-25 11:39:43.231676689 -0400
+@@ -30,7 +30,9 @@ void test_matcher_create_suite (void);
+ gint
+ main (gint argc, gchar *argv[])
+ {
++#if !GLIB_CHECK_VERSION(2,35,0)
+   g_type_init ();
++#endif
+   g_test_init (&argc, &argv, NULL);
+ 
+   gtk_init (&argc, &argv);
diff --git a/bamf.spec b/bamf.spec
index e144f25..014827f 100644
--- a/bamf.spec
+++ b/bamf.spec
@@ -1,7 +1,7 @@
 Summary:        Application matching framework
 Name:           bamf
 Version:        0.3.6
-Release:        1%{?dist}
+Release:        2%{?dist}
 # Library bits are LGPLv2 or LGPLv3 (but not open-ended LGPLv2+);
 # non-lib bits are GPLv3.
 # pbrobinson points out that three files in the lib are actually
@@ -16,6 +16,8 @@ Source0:        http://launchpad.net/bamf/0.3/%{version}/+download/%{name}-%{ver
 # backport of commit 525:
 # move directives from CFLAGS to scanner flags
 Patch0:         bamf-0.3.6-use-scanner-flags.patch
+# Fix test
+Patch1:		bamf-0.3.6-glib-fix.patch
 
 BuildRequires:  vala-tools
 BuildRequires:  gtk-doc
@@ -91,6 +93,7 @@ developing applications that use %{name} (GTK+ 3 build).
 %prep
 %setup -q
 %patch0 -p1 -b .use-scanner-flags
+%patch1 -p1 -b .glibfix
 
 %build
 %global _configure ../configure
@@ -98,11 +101,11 @@ rm -rf build-gtk3 build-gtk2
 mkdir build-gtk3 build-gtk2
 pushd build-gtk2
 %configure --disable-static --disable-webapps --with-gtk=2 --enable-gtk-doc
-make %{?_smp_mflags}
+make %{?_smp_mflags} VALA_API_GEN="/usr/bin/vapigen-0.20"
 popd
 pushd build-gtk3
 %configure --disable-static --disable-webapps --with-gtk=3 --enable-gtk-doc
-make %{?_smp_mflags}
+make %{?_smp_mflags} VALA_API_GEN="/usr/bin/vapigen-0.20"
 popd
 
 %install
@@ -161,6 +164,9 @@ rm -rf %{name}-%{version} %{name}-%{version}-gtk3
 %{_datadir}/dbus-1/services/*.service
 
 %changelog
+* Thu Apr 25 2013 Tom Callaway <spot at fedoraproject.org> - 0.3.6-2
+- fix build
+
 * Sat Apr 20 2013 Michel Salim <salimma at fedoraproject.org> - 0.3.6-1
 - Update to 0.3.6
 


More information about the scm-commits mailing list