File vte-CentOS6.spec of Package vte
%define realname vte
%define majorver 0.28
%define realver %{majorver}.2
%define srcext tar.xz
%define vte_api 0.0
%define so_ver 9
# turn off the generation of debuginfo rpm (RH9) ??
%global debug_package %{nil}
# Common info
Name: lib%{realname}%{so_ver}
Version: %{realver}
Release: wiz%{?extraver:0.}1%{?dist}
License: GPL-2.0
Group: System/Libraries
URL: https://developer.gnome.org/vte/
Summary: Terminal emulator widget for GTK+
# Install-time parameters
#Provides: lib%{name}
#Requires:
%define GTK_API_VERSION 2.0
%define GTK_REQUIRED 2.20.0
%define GLADE_API_VERSION 1.0
%define GLIB_REQUIRED 2.26.0
%define PANGO_REQUIRED 1.22.0
# Build-time parameters
BuildRequires: gettext intltool >= 0.35.0 pkgconfig
BuildRequires: ncurses-devel
BuildRequires: pkgconfig(glib-2.0) >= %{GLIB_REQUIRED}
BuildRequires: pkgconfig(gobject-2.0)
BuildRequires: pkgconfig(gtk+-%{GTK_API_VERSION}) >= %{GTK_REQUIRED}
BuildRequires: pkgconfig(pango) >= %{PANGO_REQUIRED}
BuildRoot: %{_tmppath}/%{name}-root
Source: http://ftp.gnome.org/pub/GNOME/sources/%{realname}/%{majorver}/%{realname}-%{realver}%{?extraver}.%{srcext}
%description
VTE is a library (libvte) implementing a terminal emulator widget for GTK+,
and a minimal sample application (vte) using that. Vte is mainly used in
gnome-terminal, but can also be used to embed a console/terminal in games,
editors, IDEs, etc.
VTE supports Unicode and character set conversion, as well as emulating any
terminal known to the system's terminfo database.
%package -n %{realname}-devel
Group: Development/Languages/C and C++
Summary: Development files for %{name}
Requires: %{name} = %{version}-%{release}
Provides: %{name}-devel
%description -n %{realname}-devel
Development files for %{name}
%package -n %{realname}-lang
Group: System/X11/Terminals
Summary: Localization for GNOME terminal emulator
%description -n %{realname}-lang
Localization files for vte - simple GNOME terminal emulator.
# Preparation step (unpackung and patching if necessary)
%prep
%setup -q -n %{realname}-%{realver}%{?extraver}
%build
_CFLAGS='%{optflags} %{?gcc_lto}'
_LDFLAGS='-Wl,--as-needed -Wl,--strip-all %{?gcc_lto}'
%configure \
--disable-static \
--disable-gnome-pty-helper \
--enable-glade \
--disable-introspection \
CFLAGS="$_CFLAGS" \
CXXFLAGS="$_CFLAGS" \
LDFLAGS="$_LDFLAGS"
%{__make} %{?_smp_mflags}
%install
%{__make} install DESTDIR=%{buildroot}
%find_lang %{realname}-%{vte_api}
%clean
[ "%{buildroot}" != "/" ] && %{__rm} -rf %{buildroot}
%files
%defattr(-,root,root)
%doc AUTHORS COPYING NEWS README
%{_bindir}/vte
%{_libdir}/lib%{realname}.so.%{?so_ver}*
%{_datadir}/vte/
# Development stuff
%files -n %{realname}-devel
%defattr(-,root,root)
%{_libdir}/pkgconfig/%{realname}.pc
%dir %{_includedir}/%{realname}-%{vte_api}/vte
%dir %{_includedir}/%{realname}-%{vte_api}/
%{_includedir}/%{realname}-%{vte_api}/vte/*.h
%{_libdir}/lib%{realname}.so
%exclude %{_libdir}/*.la
%docdir %{_datadir}/gtk-doc/html/%{realname}-%{vte_api}
%{_datadir}/gtk-doc/html/%{realname}-%{vte_api}/
# Localization
%files -n %{realname}-lang -f %{realname}-%{vte_api}.lang
%defattr(-,root,root)
%post -p /sbin/ldconfig
%postun -p /sbin/ldconfig
%changelog