jq/jq.spec

109 lines
2.9 KiB
RPMSpec
Raw Normal View History

#
# spec file for package jq
#
Accepting request 1109563 from home:mnhauke - Update to version 1.7 * Make object key color configurable using JQ_COLORS environment variable. * Change the default color of null to Bright Black. * Respect NO_COLOR environment variable to disable color output. * Improved --help output. Now mentions all options and nicer order. * Fix multiple issues of exit code using --exit-code/-e option. * Add --raw-output0 for NUL (zero byte) separated output. * Fix assert crash and validate JSON for --jsonarg. * Remove deprecated --argfile option. Language changes * Use decimal number literals to preserve precision. Comparison operations respects precision but arithmetic operations might truncate. * Adds new builtin pick(stream) to emit a projection of the input object or array. * Adds new builtin debug(msgs) that works like debug but applies a filter on the input before writing to stderr. * Adds new builtin scan($re; $flags). Was documented but not implemented. * Adds new builtin abs to get absolute value. This potentially allows the literal value of numbers to be preserved as length and fabs convert to float. * Allow if without else-branch. When skipped the else-branch will be . (identity). * Allow use of $binding as key in object literals. * Allow dot between chained indexes when using .["index"] * Allow dot for chained value iterator .[], .[]? * Fix try/catch catches more than it should. OBS-URL: https://build.opensuse.org/request/show/1109563 OBS-URL: https://build.opensuse.org/package/show/utilities/jq?expand=0&rev=26
2023-09-18 12:37:22 +02:00
# Copyright (c) 2023 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/
#
%define jq_sover 1
Name: jq
Accepting request 1109563 from home:mnhauke - Update to version 1.7 * Make object key color configurable using JQ_COLORS environment variable. * Change the default color of null to Bright Black. * Respect NO_COLOR environment variable to disable color output. * Improved --help output. Now mentions all options and nicer order. * Fix multiple issues of exit code using --exit-code/-e option. * Add --raw-output0 for NUL (zero byte) separated output. * Fix assert crash and validate JSON for --jsonarg. * Remove deprecated --argfile option. Language changes * Use decimal number literals to preserve precision. Comparison operations respects precision but arithmetic operations might truncate. * Adds new builtin pick(stream) to emit a projection of the input object or array. * Adds new builtin debug(msgs) that works like debug but applies a filter on the input before writing to stderr. * Adds new builtin scan($re; $flags). Was documented but not implemented. * Adds new builtin abs to get absolute value. This potentially allows the literal value of numbers to be preserved as length and fabs convert to float. * Allow if without else-branch. When skipped the else-branch will be . (identity). * Allow use of $binding as key in object literals. * Allow dot between chained indexes when using .["index"] * Allow dot for chained value iterator .[], .[]? * Fix try/catch catches more than it should. OBS-URL: https://build.opensuse.org/request/show/1109563 OBS-URL: https://build.opensuse.org/package/show/utilities/jq?expand=0&rev=26
2023-09-18 12:37:22 +02:00
Version: 1.7
Release: 0
Summary: A lightweight and flexible command-line JSON processor
License: CC-BY-3.0 AND MIT
Group: Productivity/Text/Utilities
Accepting request 1109563 from home:mnhauke - Update to version 1.7 * Make object key color configurable using JQ_COLORS environment variable. * Change the default color of null to Bright Black. * Respect NO_COLOR environment variable to disable color output. * Improved --help output. Now mentions all options and nicer order. * Fix multiple issues of exit code using --exit-code/-e option. * Add --raw-output0 for NUL (zero byte) separated output. * Fix assert crash and validate JSON for --jsonarg. * Remove deprecated --argfile option. Language changes * Use decimal number literals to preserve precision. Comparison operations respects precision but arithmetic operations might truncate. * Adds new builtin pick(stream) to emit a projection of the input object or array. * Adds new builtin debug(msgs) that works like debug but applies a filter on the input before writing to stderr. * Adds new builtin scan($re; $flags). Was documented but not implemented. * Adds new builtin abs to get absolute value. This potentially allows the literal value of numbers to be preserved as length and fabs convert to float. * Allow if without else-branch. When skipped the else-branch will be . (identity). * Allow use of $binding as key in object literals. * Allow dot between chained indexes when using .["index"] * Allow dot for chained value iterator .[], .[]? * Fix try/catch catches more than it should. OBS-URL: https://build.opensuse.org/request/show/1109563 OBS-URL: https://build.opensuse.org/package/show/utilities/jq?expand=0&rev=26
2023-09-18 12:37:22 +02:00
URL: https://github.com/jqlang
Source: https://github.com/jqlang/jq/releases/download/%{name}-%{version}/%{name}-%{version}.tar.gz
BuildRequires: chrpath
BuildRequires: pkgconfig
BuildRequires: pkgconfig(oniguruma)
# https://github.com/stedolan/jq/issues/1904
Requires: libjq%{jq_sover} = %{version}
%ifarch aarch64 x86_64 ppc64le s390x
BuildRequires: valgrind
%endif
%description
A lightweight and flexible command-line JSON processor. jq is like sed for
JSON data you can use it to slice and filter and map and transform
structured data with the same ease that sed, awk, grep and friends let
you play with text.
%package -n libjq%{jq_sover}
Summary: Library for a lightweight and flexible command-line JSON processor
Group: System/Libraries
%description -n libjq%{jq_sover}
Library for a lightweight and flexible command-line JSON processor.
%package -n libjq-devel
Summary: Development files for jq
Group: Development/Languages/C and C++
Requires: libjq%{jq_sover} = %{version}
%description -n libjq-devel
Development files (headers and libraries for jq).
%prep
%autosetup -p1
%build
%configure \
--disable-static \
%ifarch aarch64 x86_64 ppc64le s390x
--enable-valgrind \
%else
--disable-valgrind \
%endif
%{nil}
Accepting request 1109563 from home:mnhauke - Update to version 1.7 * Make object key color configurable using JQ_COLORS environment variable. * Change the default color of null to Bright Black. * Respect NO_COLOR environment variable to disable color output. * Improved --help output. Now mentions all options and nicer order. * Fix multiple issues of exit code using --exit-code/-e option. * Add --raw-output0 for NUL (zero byte) separated output. * Fix assert crash and validate JSON for --jsonarg. * Remove deprecated --argfile option. Language changes * Use decimal number literals to preserve precision. Comparison operations respects precision but arithmetic operations might truncate. * Adds new builtin pick(stream) to emit a projection of the input object or array. * Adds new builtin debug(msgs) that works like debug but applies a filter on the input before writing to stderr. * Adds new builtin scan($re; $flags). Was documented but not implemented. * Adds new builtin abs to get absolute value. This potentially allows the literal value of numbers to be preserved as length and fabs convert to float. * Allow if without else-branch. When skipped the else-branch will be . (identity). * Allow use of $binding as key in object literals. * Allow dot between chained indexes when using .["index"] * Allow dot for chained value iterator .[], .[]? * Fix try/catch catches more than it should. OBS-URL: https://build.opensuse.org/request/show/1109563 OBS-URL: https://build.opensuse.org/package/show/utilities/jq?expand=0&rev=26
2023-09-18 12:37:22 +02:00
%make_build
%install
%make_install
# RPATH contains the builddir yucks!
chrpath -d %{buildroot}%{_bindir}/jq
# No static stuff
rm %{buildroot}%{_libdir}/libjq.la
# we install the documentation in a separate location using the doc macro
rm -rf %{buildroot}%{_datadir}/doc/%{name}
%check
%if "%{qemu_user_space_build}" == "0"
Accepting request 1109563 from home:mnhauke - Update to version 1.7 * Make object key color configurable using JQ_COLORS environment variable. * Change the default color of null to Bright Black. * Respect NO_COLOR environment variable to disable color output. * Improved --help output. Now mentions all options and nicer order. * Fix multiple issues of exit code using --exit-code/-e option. * Add --raw-output0 for NUL (zero byte) separated output. * Fix assert crash and validate JSON for --jsonarg. * Remove deprecated --argfile option. Language changes * Use decimal number literals to preserve precision. Comparison operations respects precision but arithmetic operations might truncate. * Adds new builtin pick(stream) to emit a projection of the input object or array. * Adds new builtin debug(msgs) that works like debug but applies a filter on the input before writing to stderr. * Adds new builtin scan($re; $flags). Was documented but not implemented. * Adds new builtin abs to get absolute value. This potentially allows the literal value of numbers to be preserved as length and fabs convert to float. * Allow if without else-branch. When skipped the else-branch will be . (identity). * Allow use of $binding as key in object literals. * Allow dot between chained indexes when using .["index"] * Allow dot for chained value iterator .[], .[]? * Fix try/catch catches more than it should. OBS-URL: https://build.opensuse.org/request/show/1109563 OBS-URL: https://build.opensuse.org/package/show/utilities/jq?expand=0&rev=26
2023-09-18 12:37:22 +02:00
%make_build check
%endif
%ldconfig_scriptlets -n libjq%{jq_sover}
%files
%license COPYING
Accepting request 1109563 from home:mnhauke - Update to version 1.7 * Make object key color configurable using JQ_COLORS environment variable. * Change the default color of null to Bright Black. * Respect NO_COLOR environment variable to disable color output. * Improved --help output. Now mentions all options and nicer order. * Fix multiple issues of exit code using --exit-code/-e option. * Add --raw-output0 for NUL (zero byte) separated output. * Fix assert crash and validate JSON for --jsonarg. * Remove deprecated --argfile option. Language changes * Use decimal number literals to preserve precision. Comparison operations respects precision but arithmetic operations might truncate. * Adds new builtin pick(stream) to emit a projection of the input object or array. * Adds new builtin debug(msgs) that works like debug but applies a filter on the input before writing to stderr. * Adds new builtin scan($re; $flags). Was documented but not implemented. * Adds new builtin abs to get absolute value. This potentially allows the literal value of numbers to be preserved as length and fabs convert to float. * Allow if without else-branch. When skipped the else-branch will be . (identity). * Allow use of $binding as key in object literals. * Allow dot between chained indexes when using .["index"] * Allow dot for chained value iterator .[], .[]? * Fix try/catch catches more than it should. OBS-URL: https://build.opensuse.org/request/show/1109563 OBS-URL: https://build.opensuse.org/package/show/utilities/jq?expand=0&rev=26
2023-09-18 12:37:22 +02:00
%doc AUTHORS ChangeLog NEWS.md README.md
%{_bindir}/%{name}
%{_mandir}/man1/%{name}.1%{?ext_man}
%files -n libjq%{jq_sover}
%license COPYING
%{_libdir}/libjq.so.%{jq_sover}*
%files -n libjq-devel
%license COPYING
%{_includedir}/jq.h
%{_includedir}/jv.h
%{_libdir}/libjq.so
Accepting request 1109563 from home:mnhauke - Update to version 1.7 * Make object key color configurable using JQ_COLORS environment variable. * Change the default color of null to Bright Black. * Respect NO_COLOR environment variable to disable color output. * Improved --help output. Now mentions all options and nicer order. * Fix multiple issues of exit code using --exit-code/-e option. * Add --raw-output0 for NUL (zero byte) separated output. * Fix assert crash and validate JSON for --jsonarg. * Remove deprecated --argfile option. Language changes * Use decimal number literals to preserve precision. Comparison operations respects precision but arithmetic operations might truncate. * Adds new builtin pick(stream) to emit a projection of the input object or array. * Adds new builtin debug(msgs) that works like debug but applies a filter on the input before writing to stderr. * Adds new builtin scan($re; $flags). Was documented but not implemented. * Adds new builtin abs to get absolute value. This potentially allows the literal value of numbers to be preserved as length and fabs convert to float. * Allow if without else-branch. When skipped the else-branch will be . (identity). * Allow use of $binding as key in object literals. * Allow dot between chained indexes when using .["index"] * Allow dot for chained value iterator .[], .[]? * Fix try/catch catches more than it should. OBS-URL: https://build.opensuse.org/request/show/1109563 OBS-URL: https://build.opensuse.org/package/show/utilities/jq?expand=0&rev=26
2023-09-18 12:37:22 +02:00
%{_libdir}/pkgconfig/libjq.pc
%changelog