diff --git a/.gitignore b/.gitignore index e69de29..3524ffe 100644 --- a/.gitignore +++ b/.gitignore @@ -0,0 +1 @@ +/bamf-0.2.74.tar.gz diff --git a/bamf-0.2.64-gio_parameter.patch b/bamf-0.2.64-gio_parameter.patch new file mode 100644 index 0000000..50c2daa --- /dev/null +++ b/bamf-0.2.64-gio_parameter.patch @@ -0,0 +1,33 @@ +diff -up bamf-0.2.64/configure.in.orig bamf-0.2.64/configure.in +--- bamf-0.2.64/configure.in.orig 2010-12-08 22:06:30.866289436 -0800 ++++ bamf-0.2.64/configure.in 2010-12-08 22:06:32.877061748 -0800 +@@ -106,6 +106,12 @@ CFLAGS="$CFLAGS -Wall -Werror -lm" + AC_SUBST(BAMFDAEMON_CFLAGS) + AC_SUBST(BAMFDAEMON_LIBS) + ++AC_ARG_ENABLE([gio-module], ++ AC_HELP_STRING([--disable-gio-module], ++ [Disables GIO module generation (disable this unless your glib is patched, see GNOME bug #606960)]),, ++ [enable_gio_module="yes"]) ++AM_CONDITIONAL(BUILD_GIO_MODULE, [test "$enable_gio_module" = "yes"]) ++ + origgiomodulesdir=`pkg-config --variable=giomoduledir gio-2.0` + # Make giomodulesdir honour 'prefix', so that distcheck works. + giomodulesdir=`echo "$origgiomodulesdir" | sed 's|/usr|${prefix}|'` +diff -up bamf-0.2.64/Makefile.am.orig bamf-0.2.64/Makefile.am +--- bamf-0.2.64/Makefile.am.orig 2010-12-08 22:07:48.767770644 -0800 ++++ bamf-0.2.64/Makefile.am 2010-12-08 22:08:12.687214995 -0800 +@@ -7,9 +7,12 @@ SUBDIRS = \ + tests/bamfdaemon \ + tests/libbamf \ + data \ +- module \ + doc + ++if BUILD_GIO_MODULE ++ SUBDIRS += module ++endif ++ + EXTRA_DIST = COPYING.LGPL autogen.sh build.rules.mk m4/i18n.m4 m4/programs.m4 m4/util.m4 + DISTCHECK_CONFIGURE_FLAGS = --enable-introspection=no --enable-gtk-doc + diff --git a/bamf.spec b/bamf.spec new file mode 100644 index 0000000..6780b3a --- /dev/null +++ b/bamf.spec @@ -0,0 +1,121 @@ +Summary: Application matching framework +Name: bamf +Version: 0.2.74 +Release: 1%{?dist} +# the GIO module is LGPLv3-*only*, but we don't build that. Other +# 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 +# marked GPL in headers, making library GPL, though we think this +# may not be upstream's intention. For now, marking library as +# GPL. +# License: LGPLv2 or LGPLv3 +License: GPLv2 or GPLv3 +Group: System Environment/Libraries +URL: https://launchpad.net/bamf +Source0: http://launchpad.net/bamf/0.2/%{version}/+download/%{name}-%{version}.tar.gz +# Convenience patch to add a configure parameter to disable building +# of the gio module: see https://bugs.launchpad.net/bamf/+bug/687683 +Patch0: bamf-0.2.64-gio_parameter.patch + +BuildRequires: vala-tools +BuildRequires: gtk-doc +BuildRequires: dbus-glib-devel +BuildRequires: gobject-introspection-devel +BuildRequires: gtk2-devel +BuildRequires: libwnck-devel +BuildRequires: libgtop2-devel + +%description +BAMF removes the headache of applications matching into a simple DBus +daemon and C wrapper library. Currently features application matching +at amazing levels of accuracy (covering nearly every corner case). This +package contains the bamf library. + +%package devel +Summary: Development files for %{name} +Group: Development/Libraries +License: LGPLv2 or LGPLv3 +Requires: %{name} = %{version}-%{release} +# For %{_libdir}/girepository-1.0 and %{_datadir}/gir-1.0 +Requires: gobject-introspection-devel +# For %{_datadir}/gtk-doc +Requires: gtk-doc +Requires: pkgconfig + +%description devel +The %{name}-devel package contains libraries and header files for +developing applications that use %{name}. + +%package daemon +Summary: Application matching framework +Group: System Environment/Libraries +License: GPLv3 + +%description daemon +BAMF removes the headache of applications matching into a simple DBus +daemon and C wrapper library. Currently features application matching +at amazing levels of accuracy (covering nearly every corner case). This +package contains the bamf daemon and supporting data. + +%prep +%setup -q +%patch0 -p1 + +%build +# needed for patch0 +autoreconf -i + +# disable unused-but-set-variable error for now as I'm not sure if we +# should really remove it from the code: bug reported upstream +# https://bugs.launchpad.net/bamf/+bug/706703 +%global optflags %{optflags} -Wno-error=unused-but-set-variable + +# we must disable the gio module as we do not carry the glib patch +# required to build it: https://bugzilla.gnome.org/show_bug.cgi?id=606960 +%configure --disable-static --disable-gio-module + +make %{?_smp_mflags} + +%install +rm -rf %{buildroot} +make DESTDIR=%{buildroot} install +find %{buildroot} -regex ".*\.la$" | xargs rm -f -- + +%post -p /sbin/ldconfig +%postun -p /sbin/ldconfig + +%files +%defattr(-,root,root,-) +%doc COPYING.LGPL COPYING +%{_libdir}/libbamf.so.* + +%files devel +%defattr(-,root,root,-) +%doc COPYING.LGPL COPYING +%{_includedir}/libbamf +%{_libdir}/libbamf.so +%{_libdir}/pkgconfig/libbamf.pc +%{_datadir}/gtk-doc/html/libbamf +# Installation of these was disabled in the 0.2.72 release commit, +# with no explanation - http://bazaar.launchpad.net/~unity-team/bamf/trunk/revision/374 +#%{_libdir}/girepository-1.0/Bamf*.typelib +#%{_datadir}/gir-1.0/Bamf*.gir +#%{_datadir}/vala/vapi/Bamf*.vapi + +%files daemon +%defattr(-,root,root,-) +%doc COPYING +%{_libexecdir}/bamfdaemon +%{_datadir}/dbus-1/services/*.service + +%changelog +* Sun Jan 23 2011 Adam Williamson - 0.2.74-1 +- new release 0.2.74 +- update license of library (thanks pbrobinson) +- fix build by disabling a strict warning which seems to have showed + up in gcc-4.6.0-0.3 +- gir and vala devel files aren't getting installed any more + +* Fri Dec 03 2010 Adam Williamson - 0.2.64-1 +- initial package diff --git a/sources b/sources index e69de29..7b81455 100644 --- a/sources +++ b/sources @@ -0,0 +1 @@ +fa9609a6621b595580c9c06dc38dd36f bamf-0.2.74.tar.gz