File devhelp.spec of Package devhelp
#
# spec file for package devhelp
#
# Copyright (c) 2011 SUSE LINUX Products GmbH, Nuernberg, Germany.
#
# All modifications and additions to the file contributed by third parties
# remain the property of their copyright owners, unless otherwise agreed
# upon. The license for this file, and modifications and additions to the
# file, is the same license as for the pristine package itself (unless the
# license for the pristine package is not an Open Source License, in which
# case the license is the MIT License). An "Open Source License" is a
# license that conforms to the Open Source Definition (Version 1.9)
# published by the Open Source Initiative.
# Please submit bugfixes or comments via http://bugs.opensuse.org/
#
%define vimplugin_dir %{_datadir}/vim/site
Name: devhelp
Version: 2.32.0
Release: 2
License: GPLv2+
Summary: Developer's Help Program for GNOME
Url: http://developer.imendio.com/wiki/Devhelp
Group: Development/Tools/Other
Source: %{name}-%{version}.tar.bz2
# PATCH-FIX-UPSTREAM devhelp-fix-gconf-default.patch bgo#630967 vuntz@opensuse.org -- Fix broken default value for a list
Patch0: devhelp-fix-gconf-default.patch
BuildRequires: fdupes
BuildRequires: gconf2-devel
# For directory ownership of the plugins:
BuildRequires: gedit
BuildRequires: gtk2-devel
BuildRequires: intltool
BuildRequires: libunique-devel
BuildRequires: libwebkitgtk-devel
BuildRequires: libwnck-devel
BuildRequires: translation-update-upstream
BuildRequires: update-desktop-files
BuildRequires: vim
Recommends: %{name}-lang
Suggests: gedit-plugin-devhelp
Suggests: vim-plugin-devhelp
BuildRoot: %{_tmppath}/%{name}-%{version}-build
%gconf_schemas_prereq
%description
Devhelp Features - Full indexing of books in XML
- HTML viewer (GtkHTML2)
- Search by function, struct, macro, and more
- Auto completion
- Command line search with nice Emacs integration
%package devel
License: GPLv2+
Summary: Developer's Help Program For GNOME
Group: Development/Tools/Other
Requires: %{name} = %{version}
Requires: gtk2-devel
Requires: libwebkitgtk-devel
%description devel
Devhelp Features - Full indexing of books in XML.
- HTML viewer (GtkHTML2).
- Search by function, struct, macro, and more.
- Auto completion.
- Commandline search, with nice emacs integration.
%package -n gedit-plugin-devhelp
License: GPLv2+
Summary: Developer's Help Program for GNOME
Group: Development/Tools/Other
Requires: gedit
%description -n gedit-plugin-devhelp
Devhelp Features - Full indexing of books in XML
- HTML viewer (GtkHTML2)
- Search by function, struct, macro, and more
- Auto completion
- Command line search with nice Emacs integration
%package -n vim-plugin-devhelp
License: GPLv2+
Summary: Developer's Help Program for GNOME
Group: Development/Tools/Other
Requires: vim
%description -n vim-plugin-devhelp
Devhelp Features - Full indexing of books in XML
- HTML viewer (GtkHTML2)
- Search by function, struct, macro, and more
- Auto completion
- Command line search with nice Emacs integration
%lang_package
%prep
%setup -q
translation-update-upstream
%patch0 -p1
%build
%configure \
--disable-static
%__make %{?jobs:-j%jobs}
%install
%makeinstall
%if 0%{?suse_version} <= 1120
%{__rm} %{buildroot}%{_datadir}/locale/en@shaw/LC_MESSAGES/*
%endif
# glibmm2 needs this
mkdir -p %{buildroot}%{_datadir}/devhelp/books
# install vim plugin
mkdir -p %{buildroot}%vimplugin_dir/plugin
cp -a misc/devhelp.vim %{buildroot}%vimplugin_dir/plugin
# FIXME: there's also an emacs plugin: misc/devhelp.el
%suse_update_desktop_file -G "Developer Help" %name Documentation
%find_lang %{name} %{?no_lang_C}
%find_gconf_schemas
find %{buildroot}%{_libdir} -name '*.la' -type f -delete -print
%fdupes %{buildroot}
%clean
rm -rf %{buildroot}
%pre -f %{name}.schemas_pre
%post
/sbin/ldconfig
%desktop_database_post
%icon_theme_cache_post
%posttrans -f %{name}.schemas_posttrans
%preun -f %{name}.schemas_preun
%postun
/sbin/ldconfig
%desktop_database_postun
%icon_theme_cache_postun
%files -f %{name}.schemas_list
%defattr(-, root, root)
%doc AUTHORS COPYING NEWS README INSTALL
%{_bindir}/devhelp
%{_datadir}/applications/devhelp.desktop
%{_datadir}/devhelp
%{_datadir}/icons/hicolor/*/apps/*.*
%{_libdir}/*.so.*
%files lang -f %{name}.lang
%files devel
%defattr(-, root, root)
%{_includedir}/*
%{_libdir}/*.so
%{_libdir}/pkgconfig/*.pc
%files -n gedit-plugin-devhelp
%defattr(-,root,root,0755)
%{_libdir}/gedit-2/plugins/*
%files -n vim-plugin-devhelp
%defattr(-,root,root,0755)
%vimplugin_dir/plugin/devhelp.vim
%changelog