SHA256
1
0
forked from pool/chafa
chafa/chafa.spec

113 lines
3.0 KiB
RPMSpec
Raw Normal View History

#
# spec file for package chafa
#
Accepting request 1137672 from home:smolsheep:upgrades - Update to 1.14.0: * Removed ImageMagick loader support. Packagers can now remove this dependency * Polite mode is now off by default. The new default eliminates cursor flicker and makes the output more robust against unusual terminal settings. The old behavior can be restored with --polite on. * Added image loaders for the AVIF and QOI formats. * sRGB gamma is now handled correctly in scaling operations. * New option: --passthrough=<auto|none|screen|tmux>. This allows passing graphics protocols like Sixels, iTerm and Kitty through a terminal multiplexer. It will be enabled automatically for Kitty, and can be enabled manually for other protocols with more limited support * New option: --view-size=<WxH>. Specifies width and height of the viewport, overriding the detected terminal size * New option: --fit-width. Fits images to the width of the viewport, allowing them to be taller than the viewport's height * New option: --relative=<bool>. Enables relative cursor positioning. Useful if you've pre-positioned the cursor at a particular offset where you want frames to appear, but tends to make the output illegible in pagers, e.g. less -R * New option: --exact-size=<auto|on|off>. Preserves the input pixel size when possible. Useful to avoid artifacts caused by resampling * New symbol selector: imported. This selects glyphs loaded with --glyph-file * Fontgen: Added a BDF font writer * Fontgen: Cleanup and modernization * The help text and manual page were overhauled for readability, and the API documentation now includes symbol indexes by version and deprecation status. * Added a zsh completion script * Fix "unknown file format" when using AVIF on stdin * Fix broken linking with libwebp-1.3.1 * Fix make check with --without-tools * Fix --duration not working well with still images * Fix sixel rendering of animations * Fix operator precedence in geometry calculation OBS-URL: https://build.opensuse.org/request/show/1137672 OBS-URL: https://build.opensuse.org/package/show/graphics/chafa?expand=0&rev=39
2024-01-09 09:19:14 +01:00
# Copyright (c) 2024 SUSE LLC
#
# 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 https://bugs.opensuse.org/
#
Name: chafa
Version: 1.14.1
Release: 0
Summary: Image-to-text converter for terminal
License: LGPL-3.0-or-later
Group: Amusements/Toys/Graphics
URL: https://hpjansson.org/chafa/
Source0: https://github.com/hpjansson/%{name}/releases/download/%{version}/%{name}-%{version}.tar.xz
2020-04-02 10:18:06 +02:00
BuildRequires: freetype2-devel
BuildRequires: gcc
BuildRequires: glib2-devel >= 2.26
BuildRequires: gtk-doc
BuildRequires: libjpeg-devel
BuildRequires: librsvg-devel
BuildRequires: libtiff-devel
BuildRequires: libtool
BuildRequires: libwebp-devel
Requires: libchafa0 = %{version}
%description
Chafa is a command-line utility that converts all kinds of images, including
animated image formats like GIFs, into ANSI/Unicode character output that can
be displayed in a terminal.
%package -n libchafa0
Summary: Shared library for %{name}
Group: Development/Libraries/C and C++
%description -n libchafa0
The core of Chafa which converts all kinds of images, including
animated image formats like GIFs, into ANSI/Unicode characters.
%package devel
Summary: Development files for %{name}
Group: Development/Libraries/C and C++
Requires: libchafa0 = %{version}
%description devel
Development files for %{name}.
%package doc
Summary: Chafa documentation
Group: Documentation/HTML
Recommends: %{name}-devel
BuildArch: noarch
%description doc
Documentation for %{name}.
%prep
%setup -q
autoreconf -ivf
# rpath
sed -i -e 's|hardcode_libdir_flag_spec=.*|hardcode_libdir_flag_spec=""|g' \
-e 's|runpath_var=LD_RUN_PATH|runpath_var=DIE_RPATH_DIE|g' \
-e "s|runpath_var='LD_RUN_PATH'|runpath_var=DIE_RPATH_DIE|g" \
configure
%build
%configure --disable-rpath
%make_build
%install
%make_install
rm -rf %{buildroot}%{_libdir}/libchafa.{a,la}
%post -n libchafa0 -p /sbin/ldconfig
%postun -n libchafa0 -p /sbin/ldconfig
%files
%license COPYING.LESSER
%doc README* NEWS
%{_bindir}/%{name}
%{_mandir}/man1/%{name}.1%{?ext_man}
%files -n libchafa0
%license COPYING.LESSER
%{_libdir}/lib%{name}.so.0*
%files devel
%license COPYING.LESSER
%{_includedir}/%{name}/
%{_libdir}/pkgconfig/%{name}.pc
%{_libdir}/lib%{name}.so
%dir %{_libdir}/chafa/
%{_libdir}/chafa/include/
%files doc
%doc AUTHORS
%license COPYING.LESSER
%doc %{_datadir}/gtk-doc/html/%{name}
%changelog