%if 0%{?rhel} %global have_polkit 0 %global have_lightdm 0 %global bundled_xdg 1 %global cmakeflags -DENABLE_POLICYKIT=OFF -DENABLE_LIGHTDM_GREETER=OFF -DBUNDLE_XDG_UTILS=Yes %else %global have_polkit 1 %global have_lightdm 1 %global bundled_xdg 0 %global cmakeflags -DENABLE_POLICYKIT=ON -DENABLE_LIGHTDM_GREETER=ON -DBUNDLE_XDG_UTILS=No %endif # rpmlint produses errors with this - "can't find libqtxdg" #global qtxdglib libqtxdg Name: razorqt Version: 0.5.2 Release: 8%{?dist} Summary: Lightweight desktop toolbox License: GPLv2+ Url: http://razor-qt.org Source0: http://razor-qt.org/downloads/%{name}-%{version}.tar.bz2 # find_lang helper: (for i in `find . -type f -name "*_uk.ts"`; do echo "`basename $i`" | sed -r 's/_uk\.ts$//'; done) | sort Source1: %{name}-l10n-%{version}.lst # These are customizations - not bugs Patch0: %{name}-%{version}-desktop.patch Patch1: %{name}-%{version}-panel.patch BuildRequires: cmake, doxygen, desktop-file-utils BuildRequires: pkgconfig(QtGui), pkgconfig(QtWebKit) BuildRequires: pkgconfig(xcomposite) Requires: %{name}-about = %{version}-%{release} Requires: %{name}-appswitcher = %{version}-%{release} Requires: %{name}-autosuspend = %{version}-%{release} Requires: %{name}-config = %{version}-%{release} Requires: %{name}-data = %{version}-%{release} Requires: %{name}-desktop = %{version}-%{release} Requires: %{name}-openssh-askpass = %{version}-%{release} Requires: %{name}-notifications = %{version}-%{release} Requires: %{name}-panel = %{version}-%{release} Requires: %{name}-power = %{version}-%{release} Requires: %{name}-runner = %{version}-%{release} Requires: %{name}-session = %{version}-%{release} Requires: %{name}-globalkeyshortcuts = %{version}-%{release} %if 0%{?have_polkit} == 1 Requires: %{name}-policykit-agent = %{version}-%{release} %endif %description RazorQt is an advanced, easy-to-use, and fast desktop environment based on Qt technologies. Unlike desktop environments, Razor-qt also works fine with weak machines and low requirements software. This meta-package provides all the components of Razor-qt. %package -n libqtxdg Summary: Qt implementation of the XDG Specifications BuildRequires: file-devel %description -n libqtxdg This library implements functions of the XDG Specifications in Qt. %package -n libqtxdg-devel Summary: Development files for QtXdg library Requires: libqtxdg%{?_isa} = %{version}-%{release} %description -n libqtxdg-devel Qt implementation of the XDG Specifications, development package. This package provides the development files for the qtxdg library. This library implements functions of the XDG Specifications in Qt. This package is part of the Razor-qt. %package libs Summary: Common libraries and binaries for the Razor-qt # it's quite a big dependency - but there are many bugreports with (I cannot see any # icons...) and at least one icon theme has to be installed Requires: oxygen-icon-theme Requires: upower %description libs This package provides the libraries and binaries that are shared amongst the various components of Razor-qt. %package libs-devel Summary: RazorQt development package Requires: %{name}-libs%{?_isa} = %{version}-%{release} %description libs-devel This package provides the development files for the libraries that are shared amongst the various components of Razor-qt. %package data Summary: Razor-qt resources and shared data Requires: redhat-menus Requires: %{name}-theme-light = %{version}-%{release} BuildArch: noarch %description data This package contains the architecture-independent shared data files needed for the Razor-qt desktop environment. This package is part of the Razor-qt. %package about Summary: GUI to provide basic info about DE Requires: %{name}-data = %{version}-%{release} %description about A tool to display Razor-qt version, license, and technical background. %package appswitcher Summary: Razor-qt running application switcher Requires: %{name}-data = %{version}-%{release} %description appswitcher Desktop Independent Alt-Tab window switcher from Razor-qt, it was written for Razor-qt but it can be used standalone as well. This application switcher supplements or replaces native window manager (if available) so it should be enabled in config first. This package is part of the Razor-qt. %package autosuspend Summary: Razor-qt power management Requires: %{name}-data = %{version}-%{release} Requires: hicolor-icon-theme %description autosuspend Razor-qt suspend manage application tool. The frontend manage application tool for LID or power management actions that relies on power manager from Razor-qt desktop. This package is part of the Razor-qt. %package config Summary: Razor-qt config tools Requires: %{name}-data = %{version}-%{release} %description config The Razor-qt user interface for configuring the aspects and applications of the Razor-qt desktop. This application also list configuration components of other desktop environments components such qt-config . This package is part of the Razor-qt. %package desktop Summary: Razor-qt desktop component Requires: %{name}-data = %{version}-%{release} %description desktop Desktop manager for Razor-qt. This package is part of the Razor-qt. %package globalkeyshortcuts Summary: Razor-qt global keyboard shortcuts tool Requires: %{name}-data = %{version}-%{release} %description globalkeyshortcuts The Razor-qt global keyboard shortcuts desktop tool manages the keyboard shortcuts assigned by user or also default assigned by desktop. This package is part of the Razor-qt. %if 0%{?have_lightdm} == 1 #package lightdm-greeter %package -n lightdm-razorqt Summary: LightDM greeter that uses the Razor-qt (Qt based) lib kit BuildRequires: pkgconfig(liblightdm-qt-2) Requires: %{name}-data = %{version}-%{release} Requires: lightdm Requires(post): %{_sbindir}/update-alternatives Requires(postun): %{_sbindir}/update-alternatives Provides: lightdm-greeter = 1.2 %description -n lightdm-razorqt A LightDM greeter that uses the Razor-qt and Qt libraries, it was written for Razor-qt but it can be used standalone as well. This package is part of the Razor-qt. %endif %package notifications Summary: Razor-qt notification daemon Requires: %{name}-data = %{version}-%{release} %description notifications Desktop Independent notifications daemon from Razor-qt, it was written for Razor-qt but it can be used standalone as well. It uses Freedesktop standard for notifications. This package is part of the Razor-qt. %package openssh-askpass Summary: Razor-qt openssh ask password interface Requires: %{name}-data = %{version}-%{release} %description openssh-askpass Desktop Independent ssh ask password interface from Razor-qt, it was written for Razor-qt but it can be used standalone as well. This application relies on desktop environment integration and works depending on it, for that please read docs. This package is part of the Razor-qt. %package panel Summary: Razor-qt panel and its plugins # libstatgrab-devel, pulseaudio-libs-devel BuildRequires: pkgconfig(libstatgrab) BuildRequires: pkgconfig(libpulse) BuildRequires: lm_sensors-devel Requires: %{name}-data = %{version}-%{release} Requires: xscreensaver-base %description panel Desktop Independent panel component from Razor-qt desktop. Package contains growing list of built in plugins for daily use. It was written for Razor-qt but it can be used standalone as well. This package is part of the Razor-qt. %if 0%{?have_polkit} == 1 %package policykit-agent Summary: A lightweight PolicyKit agent/user interface BuildRequires: pkgconfig(polkit-qt-agent-1), pkgconfig(polkit-agent-1) Requires: %{name}-data = %{version}-%{release} %description policykit-agent A Qt based PolicyKit agent. It provides a simple agent primarily for the usage of Razor-qt desktop or any other desktop. It was written for Razor-qt DE but can be used standalone This package is part of the Razor-qt. %endif %package power Summary: Razor-qt power management component Requires: %{name}-data = %{version}-%{release} %description power The power management component handles basic power actions and events for the Razor-qt desktop. This package is part of the Razor-qt. %package runner Summary: Razor-qt quick launch and runner application Requires: %{name}-data = %{version}-%{release} %description runner The quick launch and runner tool for launching applications. Depending on window-manager razor-runner can be activated by pressing the Alt + F2 key combination. This package is part of the Razor-qt. %package session Summary: Razor-qt session manager BuildRequires: python2-devel Requires: %{name}-data = %{version}-%{release} # or firstboot(windowsmanager)? Requires: openbox Requires: redhat-menus %if 0%{?bundled_xdg} == 1 Requires: %{name}-xdg = %{version}-%{release} %endif %description session The Razor-qt session manager handles the Razor-qt components initialization and startup, it is an essential part of the Razor-qt as a Desktop Environment. This package is part of the Razor-qt. %if 0%{?bundled_xdg} == 1 %package xdg Summary: Razor-qt xdg workaround License: MIT BuildArch: noarch %description xdg Razor-qt xdg-utils (older then 1.1.0 2012-03-02) workaround. %endif %package theme-amego Summary: Razor-qt a-mego theme Requires: %{name}-data = %{version}-%{release} Provides: %{name}-theme = %{version}-%{release} BuildArch: noarch %description theme-amego Razor-qt a-mego theme %package theme-ambiance Summary: Razor-qt ambiance theme Requires: %{name}-data = %{version}-%{release} Provides: %{name}-theme = %{version}-%{release} BuildArch: noarch %description theme-ambiance Razor-qt ambiance theme %package theme-green Summary: Razor-qt green theme Requires: %{name}-data = %{version}-%{release} Provides: %{name}-theme = %{version}-%{release} BuildArch: noarch %description theme-green Razor-qt green theme %package theme-light Summary: Razor-qt light theme Requires: %{name}-data = %{version}-%{release} Provides: %{name}-theme = %{version}-%{release} BuildArch: noarch %description theme-light Razor-qt light theme %package themes Summary: Razor-qt themes BuildArch: noarch Requires: %{name}-theme-amego = %{version}-%{release} Requires: %{name}-theme-ambiance = %{version}-%{release} Requires: %{name}-theme-green = %{version}-%{release} Requires: %{name}-theme-light = %{version}-%{release} %description themes Razor-qt themes meta-package %prep %setup -q cp razorqt-desktop/resources/desktop.conf razorqt-desktop/resources/desktop.conf.sample cp razorqt-panel/panel/resources/panel.conf razorqt-panel/panel/resources/panel.conf.sample %patch0 -p 0 %patch1 -p 0 %build mkdir build pushd build %cmake -DCMAKE_BUILD_TYPE=RelWithDebInfo %cmakeflags .. make %{?_smp_mflags} popd %install # 0. main installation pushd build %{make_install} popd # 1. find_lang %if 0%{?rhel} for i in `cat %{SOURCE1} | grep -v panelvolume | grep -v lightdm | grep -v policykit`; do %find_lang $i --with-qt --without-mo; done # find_lang bug workaround echo "%lang(sr@latin) /usr/share/razor/razor-config/razor-config-appearance_sr@latin.qm" >> razor-config-appearance.lang echo "%lang(sr@latin) /usr/share/razor/razor-panel/razor-panel_sr@latin.qm" >> razor-panel.lang %else for i in `cat %{SOURCE1}`; do %find_lang $i --with-qt --without-mo; done %endif # 2. greeter %if 0%{?have_lightdm} == 1 # own alternatives target (optional, but nice) -- rex touch %{buildroot}%{_datadir}/xgreeters/lightdm-greeter.desktop %endif # 3. check desktop files for i in `ls %{buildroot}/%{_datadir}/applications/*.desktop`; do desktop-file-validate $i; done # 4. hacks # - exec flag chmod 0755 %{buildroot}/%{_datadir}/razor/razor-confupdate/desktop-041-050.py # - kdm sessions rm -rf %{buildroot}/%{_datadir}/apps/ # - autostart entries rm -f %{buildroot}/%{_sysconfdir}/xdg/autostart/razor-{ptbatterysystemtray,qlipper,qstardict,qxkb,xscreensaver}-autostart.desktop # - autoinstalled sample rm -f %{buildroot}/%{_sysconfdir}/razor/desktop.conf.sample %if 0%{?have_polkit} == 0 # - autostart polkit agent rm -f %{buildroot}/%{_sysconfdir}/xdg/autostart/razor-policykit-agent.desktop %endif %post -n libqtxdg -p /sbin/ldconfig %postun -n libqtxdg -p /sbin/ldconfig %post libs -p /sbin/ldconfig %postun libs -p /sbin/ldconfig %post notifications -p /sbin/ldconfig %postun notifications -p /sbin/ldconfig %postun autosuspend if [ $1 -eq 0 ] ; then /usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || : fi %posttrans autosuspend /usr/bin/gtk-update-icon-cache %{_datadir}/icons/hicolor &>/dev/null || : %if 0%{?have_lightdm} == 1 %post -n lightdm-razorqt %{_sbindir}/update-alternatives \ --install %{_datadir}/xgreeters/lightdm-greeter.desktop \ lightdm-greeter \ %{_datadir}/xgreeters/lightdm-razor-greeter.desktop \ 5 %postun -n lightdm-razorqt if [ $1 -eq 0 ]; then %{_sbindir}/update-alternatives \ --remove lightdm-greeter \ %{_datadir}/xgreeters/lightdm-razor-greeter.desktop fi %endif %files # meta package %files -n libqtxdg -f libqtxdg.lang %doc COPYING GPL LGPL %{_libdir}/libqtxdg.so.* %dir %{_datadir}/libqtxdg/ %files -n libqtxdg-devel %{_libdir}/libqtxdg.so %{_libdir}/pkgconfig/qtxdg.pc %{_includedir}/qtxdg/ %files libs -f librazorqt.lang %doc COPYING GPL LGPL %{_libdir}/librazor*.so.* %dir %{_datadir}/librazorqt/ %files libs-devel %{_libdir}/librazor*.so %{_libdir}/pkgconfig/razor*.pc %{_includedir}/razor*/ %{_bindir}/razor-x11info %files data %doc README COPYING GPL LGPL %config(noreplace) %{_sysconfdir}/xdg/menus/razor-*.menu %dir %{_sysconfdir}/razor/ %config(noreplace) %{_sysconfdir}/razor/razor.conf %dir %{_datadir}/razor/ %{_datadir}/razor/graphics/ %dir %{_datadir}/razor/themes/ %{_datadir}/desktop-directories/razor* %dir %{_datadir}/desktop-directories/ %files about %{_bindir}/razor-about %{_datadir}/applications/razor-about.desktop %files appswitcher %{_bindir}/razor-appswitcher %{_sysconfdir}/xdg/autostart/razor-appswitcher.desktop %files autosuspend -f razor-autosuspend.lang -f razor-config-autosuspend.lang %{_bindir}/razor-autosuspend %{_bindir}/razor-config-autosuspend %{_datadir}/applications/razor-config-autosuspend.desktop %dir %{_datadir}/razor/razor-autosuspend/ %dir %{_datadir}/razor/razor-config-autosuspend/ %{_datadir}/icons/hicolor/scalable/apps/*.svg %{_sysconfdir}/xdg/autostart/razor-autosuspend.desktop %files config -f razor-config.lang -f razor-config-mouse.lang -f razor-config-appearance.lang %{_bindir}/razor-config %{_bindir}/razor-config-appearance %{_bindir}/razor-config-mouse %{_datadir}/applications/razor-config.desktop %{_datadir}/applications/razor-config-appearance.desktop %{_datadir}/applications/razor-config-mouse.desktop %{_datadir}/applications/razor-config-qtconfig.desktop %dir %{_datadir}/razor/razor-config/ %files desktop -f analogclock.lang -f desktop-razor.lang -f helloworld.lang -f iconview.lang -f notepad.lang -f razor-config-desktop.lang %doc razorqt-desktop/resources/desktop.conf.sample %config(noreplace) %{_sysconfdir}/razor/desktop.conf %{_bindir}/razor-desktop %{_bindir}/razor-config-desktop %{_libdir}/razor-desktop/ %{_datadir}/applications/razor-config-desktop.desktop %dir %{_datadir}/razor/razor-desktop/ %{_datadir}/razor/razor-desktop/*.desktop %{_sysconfdir}/xdg/autostart/razor-desktop.desktop %files globalkeyshortcuts -f razor-config-globalkeyshortcuts.lang %{_bindir}/razor-globalkeyshortcuts %{_bindir}/razor-config-globalkeyshortcuts %{_datadir}/applications/razor-config-globalkeyshortcuts.desktop %dir %{_datadir}/razor/razor-config-globalkeyshortcuts/ %{_sysconfdir}/xdg/autostart/razor-globalkeyshortcuts.desktop %files openssh-askpass -f razor-openssh-askpass.lang %{_bindir}/razor-openssh-askpass %dir %{_datadir}/razor/razor-openssh-askpass/ %if 0%{?have_lightdm} == 1 %files -n lightdm-razorqt -f razor-lightdm-greeter.lang %{_bindir}/razor-lightdm-greeter %{_datadir}/xgreeters/lightdm-razor-greeter.desktop %dir %{_datadir}/razor/razor-lightdm-greeter/ # own alternatives target %ghost %{_datadir}/xgreeters/lightdm-greeter.desktop %endif %files notifications -f razor-config-notificationd.lang -f razor-notificationd.lang %{_bindir}/razor-notificationd %{_bindir}/razor-config-notificationd %{_datadir}/applications/razor-config-notificationd.desktop %dir %{_datadir}/razor/razor-config-notificationd/ %dir %{_datadir}/razor/razor-notificationd/ %{_sysconfdir}/xdg/autostart/razor-notifications.desktop %if 0%{?rhel} %files panel -f clock.lang -f cpuload.lang -f desktopswitch.lang -f mainmenu.lang -f mount.lang -f networkmonitor.lang -f quicklaunch.lang -f razor-panel.lang -f screensaver.lang -f sensors.lang -f showdesktop.lang -f taskbar.lang %else %files panel -f clock.lang -f cpuload.lang -f desktopswitch.lang -f mainmenu.lang -f mount.lang -f networkmonitor.lang -f panelvolume.lang -f quicklaunch.lang -f razor-panel.lang -f screensaver.lang -f sensors.lang -f showdesktop.lang -f taskbar.lang %endif %doc razorqt-panel/panel/resources/panel.conf.sample %{_bindir}/razor-panel %{_libdir}/razor-panel/ %dir %{_datadir}/razor/razor-panel/ %{_datadir}/razor/razor-panel/*.desktop %dir %{_sysconfdir}/razor/razor-panel/ %config(noreplace) %{_sysconfdir}/razor/razor-panel/panel*.conf %{_sysconfdir}/xdg/autostart/razor-panel.desktop %if 0%{?have_polkit} == 1 %files policykit-agent -f razor-policykit-agent.lang %{_bindir}/razor-policykit-agent %dir %{_datadir}/razor/razor-policykit-agent/ %{_sysconfdir}/xdg/autostart/razor-policykit-agent.desktop %endif %files power -f razor-power.lang %{_bindir}/razor-power %dir %{_datadir}/razor/razor-power/ %{_datadir}/applications/razor-power.desktop %files runner -f razor-runner.lang %{_bindir}/razor-runner %dir %{_datadir}/razor/razor-runner/ %{_sysconfdir}/xdg/autostart/razor-runner.desktop %files session -f razor-config-session.lang -f razor-session.lang %doc build/razorqt-resources/autostart/razor-{ptbatterysystemtray,qlipper,qstardict,qxkb,xscreensaver}-autostart.desktop %{_bindir}/razor-session %{_bindir}/razor-config-session %{_bindir}/startrazor %{_bindir}/razor-confupdate %{_datadir}/xsessions/razor*.desktop %{_datadir}/applications/razor-config-session.desktop %dir %{_datadir}/razor/razor-session/ %dir %{_datadir}/razor/razor-config-session/ #{_sysconfdir}/xdg/autostart/razor*.desktop %config(noreplace) %{_sysconfdir}/razor/session.conf %config(noreplace) %{_sysconfdir}/razor/windowmanagers.conf %{_datadir}/razor/razor-confupdate/ %{_libdir}/razor-confupdate_bin %if 0%{?bundled_xdg} == 1 %files xdg # temp files - it will be removed when it becomes part of upstream %{_libdir}/razor-xdg-tools/ %endif %files theme-amego %{_datadir}/razor/themes/a-mego/ %files theme-ambiance %{_datadir}/razor/themes/ambiance/ %files theme-green %{_datadir}/razor/themes/green/ %files theme-light %{_datadir}/razor/themes/light/ %files themes # meta package %changelog * Mon May 06 2013 TI_Eugene 0.5.2-8 - %%description sections right after %%package - find_lang workaround for EL6 * Sun May 05 2013 TI_Eugene 0.5.2-7 - some unnesessary comments removed - comments and changelog cleanup (double %%) - GPL and LGPL files added to -libs and libqtxdg subpackages - MIT license added to -xdg subpackage - EL6: excluded some lang files (panelvolume, lightdm, policykit) - -devel subpackage renamed to -libs-devel * Sat Apr 27 2013 TI_Eugene 0.5.2-6 - *.lang files used * Fri Apr 26 2013 TI_Eugene 0.5.2-5 - xdg workaround back (for rhel; -xdg subpackage) - Requires: -data fixes - -themes Requires fix - _isa added to -devel packages - prepared for using find_lang for translations * Wed Apr 24 2013 TI_Eugene 0.5.2-4 - cmake build type added (RelWithDebInfo) * Mon Apr 22 2013 TI_Eugene 0.5.2-3 - bundled xdg-utils excluded (-DBUNDLE_XDG_UTILS=No) - -data is noarch now - -data requires -theme-light - themes moved to -theme-* subpackages * Sat Apr 20 2013 TI_Eugene 0.5.2-2 - %%define changed to %%global - dist added - license changed to GPLv2+ only - %%doc moved from main package into -data - -autosuspend: icon cache handling added - -data: requires redhat-menus (/etc/xdg/) - -data: requires python2-devel - -desktop: _datadir/razor/ moved to -data - -desktop: desktop.conf simplified - -panel: panel.conf simplified - -session: _datadir/apps/ removed - -session: requires redhat-menus added - -session: /etc/xdg/autostart/* moved to respective subpackages or samples * Tue Apr 16 2013 TI_Eugene 0.5.2-1 - Initial Fedora packaging