Diff jq-1.7 with a jq-1.7_pre20201109-r1

/usr/portage/app-misc/jq/jq-1.7_pre20201109-r1.ebuild 2023-10-09 14:52:28.804368333 +0300
1
# Copyright 1999-2023 Gentoo Authors
1
# Copyright 1999-2022 Gentoo Authors
2 2
# Distributed under the terms of the GNU General Public License v2
3 3

  
4
EAPI=8
4
EAPI=7
5 5

  
6 6
inherit autotools
7 7

  
8
MY_PV="${PV/_/}"
9
MY_P="${PN}-${MY_PV}"
8
COMMIT_HASH="a17dd3248a666d01be75f6b16be37e80e20b0954"
9

  
10 10
DESCRIPTION="A lightweight and flexible command-line JSON processor"
11 11
HOMEPAGE="https://stedolan.github.io/jq/"
12
SRC_URI="https://github.com/jqlang/jq/archive/refs/tags/${MY_P}.tar.gz -> ${P}.gh.tar.gz"
13
S="${WORKDIR}/${PN}-${MY_P}"
12
#SRC_URI="https://github.com/stedolan/jq/releases/download/${P}/${P}.tar.gz"
13
SRC_URI="https://github.com/stedolan/jq/archive/${COMMIT_HASH}.tar.gz -> ${P}.tar.gz"
14
S="${WORKDIR}/${PN}-${COMMIT_HASH}"
14 15

  
15 16
LICENSE="MIT CC-BY-3.0"
16 17
SLOT="0"
17
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~ia64 ~loong ~ppc ~ppc64 ~riscv ~sparc ~x86 ~amd64-linux ~arm64-macos ~x64-macos ~x64-solaris"
18
KEYWORDS="~alpha amd64 ~arm arm64 ~ia64 ~loong ~ppc ppc64 ~riscv x86 ~amd64-linux ~x64-macos"
18 19
IUSE="+oniguruma static-libs test"
19 20

  
20
ONIGURUMA_MINPV='>=dev-libs/oniguruma-6.9.3' # Keep this in sync with bundled modules/oniguruma/
21
ONIGURUMA_MINPV='>=dev-libs/oniguruma-6.1.3' # Keep this in sync with bundled modules/oniguruma/
21 22
DEPEND="
22 23
	>=sys-devel/bison-3.0
23 24
	sys-devel/flex
......
31 32
PATCHES=(
32 33
	"${FILESDIR}"/jq-1.6-r3-never-bundle-oniguruma.patch
33 34
	"${FILESDIR}"/jq-1.7-runpath.patch
35
	"${FILESDIR}"/jq-1.7-warnings.patch
36
	"${FILESDIR}"/jq-1.7-visible-null.patch
37
	# https://bugs.gentoo.org/776385
38
	"${FILESDIR}"/jq-1.7_pre20201109-no-git-bdep.patch
39
	"${FILESDIR}"/jq-1.7_pre20201109-fix-configure-test.patch
34 40
)
35 41

  
36 42
RESTRICT="!test? ( test )"
......
38 44

  
39 45
src_prepare() {
40 46
	sed -e '/^dist_doc_DATA/d; s:-Wextra ::' -i Makefile.am || die
41
	printf "#!/bin/sh\\nprintf '%s'\\n\n" "${MY_PV}" > scripts/version || die
47
	sed -r -e "s:(m4_define\(\[jq_version\],) .+\):\1 \[${PV}\]):" \
48
		-i configure.ac || die
42 49

  
43 50
	# jq-1.6-r3-never-bundle-oniguruma makes sure we build with the system oniguruma,
44 51
	# but the bundled copy of oniguruma still gets eautoreconf'd since it
......
47 54
	rm -rf "${S}"/modules/oniguruma || die
48 55

  
49 56
	default
50

  
51
	sed -i "s/\[jq_version\]/[${MY_PV}]/" configure.ac || die
52

  
53 57
	eautoreconf
54 58
}
55 59

  
......
77 81
}
78 82

  
79 83
src_install() {
80
	local DOCS=( AUTHORS NEWS.md README.md SECURITY.md )
84
	local DOCS=( AUTHORS NEWS README.md )
81 85
	default
82 86

  
83 87
	use static-libs || { find "${D}" -name '*.la' -delete || die; }
Thank you!