%global commit 37f6bc2dbb1b525f7eabc71f43ae3949f0671be6 %global shortcommit %(c=%{commit}; echo ${c:0:7}) %global libsuffix yui %global _hardened_build 1 Name: lib%{libsuffix} Version: 3.0.4 Release: 1%{?dist} License: LGPLv2 or LGPLv3 Source0: https://github.com/%{name}/%{name}/archive/%{commit}/%{name}-%{version}-%{shortcommit}.tar.gz # both will be commited and merged with https://github.com/libyui/libyui/pull/47 Patch0: libyui_honor_compiler_flags.patch Patch1: libyui_skip_doxygen_latex.patch Group: System Environment/Libraries BuildRequires: boost-devel BuildRequires: cmake >= 2.8 BuildRequires: doxygen BuildRequires: fdupes BuildRequires: graphviz BuildRequires: pkgconfig URL: https://github.com/%{name}/%{name}/ Summary: GUI-abstraction library %description This is the user interface engine that provides the abstraction from graphical user interfaces (Qt, Gtk) and text based user interfaces (ncurses). Originally developed for YaST, %{name} can now be used independently of YaST for generic (C++) applications. %{name} has very few dependencies. %package devel Group: Development/Libraries Requires: boost-devel%{?_isa} Requires: cmake%{?_isa} Requires: %{name}%{?_isa} = %{version}-%{release} Summary: Files needed for developing with %{name} %description devel %{name} can be used independently of YaST for generic (C++) applications and has very few dependencies. %package doc Group: Documentation BuildArch: noarch Summary: Documentation files for %{name} %description doc This package includes the developer's documentation as HTML and some brief examples how to build a UI using %{name}. %prep %setup -q -n %{name}-%{commit} %patch0 %patch1 ./bootstrap.sh %build mkdir -p build cd build %cmake ..\ -DPREFIX=%{_prefix} \ -DLIB_DIR=%{_libdir} \ -DDOC_DIR=%{_defaultdocdir} \ -DDOC_SUBDIR=%{name}-%{version} \ -DINSTALL_DOCS=ON \ -DSKIP_LATEX=ON \ -DCMAKE_BUILD_TYPE=RELEASE make %{?_smp_mflags} make %{?_smp_mflags} docs %install cd build %make_install install -m0755 -d %{buildroot}/%{_libdir}/%{libsuffix} install -m0755 -d %{buildroot}/%{_datadir}/%{name}/theme install -pm0644 ../COPYING* %{buildroot}/%{_defaultdocdir}/%{name}-%{version} install -pm0644 ../ChangeLog %{buildroot}/%{_defaultdocdir}/%{name}-%{version} %fdupes %{buildroot}/%{_defaultdocdir}/%{name}-%{version} %post -p /sbin/ldconfig %postun -p /sbin/ldconfig %files %{_libdir}/lib*.so.* %dir %{_libdir}/%{libsuffix} %dir %{_datadir}/%{name} %dir %{_datadir}/%{name}/theme %dir %{_defaultdocdir}/%{name}-%{version} %doc %{_defaultdocdir}/%{name}-%{version}/C* %files devel %{_libdir}/lib*.so %{_includedir}/%{libsuffix} %{_libdir}/pkgconfig/%{name}.pc %{_libdir}/cmake/%{name} %{_datadir}/%{name}/buildtools %files doc %dir %{_defaultdocdir}/%{name}-%{version} %doc %{_defaultdocdir}/%{name}-%{version}/*/ %changelog * Wed May 15 2013 Björn Esser - 3.0.4-1 - new upstream version - add Patch1 to skip generation of pdf-docs if doxygen-latex is installed. - added needed bootstrap to prep * Tue May 14 2013 Björn Esser - 3.0.3-3 - removed macro from Patch0. - fixed typo -> s/pakage/package/ - removed Provides/Requires: yui_ui * Mon May 13 2013 Björn Esser - 3.0.3-2 - fixup as suggested in https://bugzilla.redhat.com/show_bug.cgi?id=959926#c2 - add Patch0 to obey conventions about the compiler flags set in the system rpm configuration. See: https://fedoraproject.org/wiki/Packaging:Guidelines#Compiler_flags - fixup as suggested in https://bugzilla.redhat.com/show_bug.cgi?id=959926#c4 - build a hardened version just in case - add Requires: %{libsuffix}-ui, because %{name} without UI-plugins is as useful as a car without gas and tires. - add -devel Provides: %{libsuffix}-ui to provide a FAKE %{libsuffix}-ui to satisfy dependencies during rpmbuild of the UI-plugins and made sure this is known by documenting this in %{name}-devel description. - add -devel Requires: cmake to solve the /usr/lib*/cmake/ ownership-problem, which is needed for libyui*-builds anyways. * Mon May 06 2013 Björn Esser - 3.0.3-1 - Initial RPM release.