LogoopenSUSE Build Service > Projects
Sign Up | Log In

View File terminology.spec of Package terminology (Project X11:Enlightenment:Nightly)

# spec file for package terminology
# Copyright (c) 2018 SUSE LINUX 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 e_branding_package %(rpm -q --qf '%%{name}' --whatprovides enlightenment-branding)
%if 0%{?suse_version} && 0%{?is_opensuse}
%define e_branding_version %(rpm -q --qf '%%{version}' %{e_branding_package})
%define e_branding_version 0.1
Name:           terminology
Version:        @SERVICE@
Release:        0
Summary:        EFL based terminal emulator
License:        BSD-2-Clause AND OFL-1.1
Group:          System/X11/Terminals
URL:            http://enlightenment.org
Source:         %{name}-%{version}.tar.xz
BuildRequires:  ImageMagick
BuildRequires:  hicolor-icon-theme
BuildRequires:  meson >= 0.40.1
BuildRequires:  pkgconfig
BuildRequires:  pkgconfig(ecore)
BuildRequires:  pkgconfig(ecore-evas)
BuildRequires:  pkgconfig(ecore-file)
BuildRequires:  pkgconfig(ecore-imf)
BuildRequires:  pkgconfig(ecore-imf-evas)
BuildRequires:  pkgconfig(ecore-input)
BuildRequires:  pkgconfig(ecore-ipc)
BuildRequires:  pkgconfig(edje)
BuildRequires:  pkgconfig(eet)
BuildRequires:  pkgconfig(efreet)
BuildRequires:  pkgconfig(eina)
BuildRequires:  pkgconfig(elementary) >= 1.8.0
BuildRequires:  pkgconfig(emotion)
BuildRequires:  pkgconfig(ethumb_client)
BuildRequires:  pkgconfig(evas)
Requires:       efl
Requires:       elementary >= 1.8.0
# provides default.edj
Requires:       terminology-theme-dft
Recommends:     %{name}-lang
Conflicts:      evas-generic-loaders < 1.8.0
%if 0%{?suse_version}
Recommends:     evas-generic-loaders >= 1.8.0
Recommends:     terminology-theme-dark
Recommends:     terminology-theme-misc
Recommends:     terminology-theme-openSUSE
Recommends:     terminology-theme-openSUSE-oliveleaf
%if 0%{?suse_version}
BuildRequires:  fdupes
BuildRequires:  update-desktop-files
%if 0%{?is_opensuse}
BuildRequires:  enlightenment-branding-openSUSE

Fast and lightweight terminal emulator using EFL libraries.

%package theme-upstream
Summary:        Default Enlightenment theme
Group:          System/X11/Terminals
Conflicts:      terminology-theme-dft
Provides:       terminology-theme = %{e_branding_version}
Provides:       terminology-theme-dft

%description  theme-upstream
For use with upstream branding, when using openSUSE themes, when using
openSUSE themes.

Use the Dark theme instead.

%package theme-dark
Summary:        Default terminology theme(Dark)
Group:          System/X11/Terminals
Provides:       terminology-theme

%description  theme-dark
The default theme for terminology install when using openSUSE branding.

%package theme-misc
Summary:        Miscellaneous terminology themes
Group:          System/X11/Terminals
Provides:       terminology-theme

%description  theme-misc
Miscellaneous themes provided by the terminology devs, includes Solarized,
Mild and Black themes.


%setup -q

export CFLAGS="%{optflags} %{?mageia:-g}"


# convert icons to hicolor
_width=$(identify -format %w $_file)
_height=$(identify -format %h $_file)
if [ "$_width" -eq $_height ]; then
    ls %{_datadir}/icons/hicolor | grep '[0-9]x[0-9]' | sort -n | while read _size; do
      if [ "$_width" -ge ${_size%x*} ]; then
        mkdir -p %{buildroot}%{_datadir}/icons/hicolor/${_size}/apps
        convert -strip \
          $_file -resize $_size \
    install -Dm0644 $_file %{buildroot}%{_datadir}/pixmaps/${_file##*/}
rm %{buildroot}%{_datadir}/icons/%{name}.png
sed -i 's/.png[[:blank:]]*$//' %{buildroot}%{_datadir}/applications/%{name}.desktop

# make 2 copys of default for branding
cp %{buildroot}%{_datadir}/%{name}/themes/default.edj %{buildroot}%{_datadir}/%{name}/themes/dark.edj

%find_lang %{name}
%if 0%{?suse_version}
%suse_update_desktop_file -r %{name} Enlightenment System TerminalEmulator
%fdupes %{buildroot}/%{_datadir}

%if 0%{?suse_version} < 1320


%{!?suse_version:%files -f %{name}.lang}
%exclude %{_datadir}/%{name}/themes/*

%files theme-upstream

%files theme-dark

%files theme-misc
%exclude %{_datadir}/%{name}/themes/dark.edj
%exclude %{_datadir}/%{name}/themes/default.edj

%{?suse_version:%files lang -f %{name}.lang}