1 |
commit: a988da45ce12d8bf2e47c47dfd775ef4dee49620 |
2 |
Author: Sam James <sam <AT> gentoo <DOT> org> |
3 |
AuthorDate: Mon Jun 20 00:22:37 2022 +0000 |
4 |
Commit: Sam James <sam <AT> gentoo <DOT> org> |
5 |
CommitDate: Wed Jun 29 08:39:44 2022 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=a988da45 |
7 |
|
8 |
app-admin/apache-tools: drop which dependency |
9 |
|
10 |
Closes: https://bugs.gentoo.org/844868 |
11 |
Signed-off-by: Sam James <sam <AT> gentoo.org> |
12 |
|
13 |
.../apache-tools/apache-tools-2.4.54-r1.ebuild | 108 +++++++++++++++++++++ |
14 |
.../files/apache-tools-2.4.54-no-which.patch | 54 +++++++++++ |
15 |
2 files changed, 162 insertions(+) |
16 |
|
17 |
diff --git a/app-admin/apache-tools/apache-tools-2.4.54-r1.ebuild b/app-admin/apache-tools/apache-tools-2.4.54-r1.ebuild |
18 |
new file mode 100644 |
19 |
index 000000000000..8b3560d27cf2 |
20 |
--- /dev/null |
21 |
+++ b/app-admin/apache-tools/apache-tools-2.4.54-r1.ebuild |
22 |
@@ -0,0 +1,108 @@ |
23 |
+# Copyright 1999-2022 Gentoo Authors |
24 |
+# Distributed under the terms of the GNU General Public License v2 |
25 |
+ |
26 |
+EAPI=8 |
27 |
+ |
28 |
+inherit autotools toolchain-funcs |
29 |
+ |
30 |
+DESCRIPTION="Useful Apache tools - htdigest, htpasswd, ab, htdbm" |
31 |
+HOMEPAGE="https://httpd.apache.org/" |
32 |
+SRC_URI="mirror://apache/httpd/httpd-${PV}.tar.bz2" |
33 |
+ |
34 |
+LICENSE="Apache-2.0" |
35 |
+SLOT="0" |
36 |
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~riscv ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~sparc64-solaris ~x64-solaris" |
37 |
+IUSE="ssl" |
38 |
+RESTRICT="test" |
39 |
+ |
40 |
+RDEPEND=">=dev-libs/apr-1.5.0:1= |
41 |
+ dev-libs/apr-util:1= |
42 |
+ dev-libs/expat |
43 |
+ dev-libs/libpcre |
44 |
+ virtual/libcrypt:= |
45 |
+ kernel_linux? ( sys-apps/util-linux ) |
46 |
+ ssl? ( dev-libs/openssl:0= )" |
47 |
+DEPEND="${RDEPEND} |
48 |
+ sys-devel/libtool" |
49 |
+BDEPEND=" |
50 |
+ virtual/pkgconfig |
51 |
+" |
52 |
+ |
53 |
+S="${WORKDIR}/httpd-${PV}" |
54 |
+ |
55 |
+PATCHES=( |
56 |
+ "${FILESDIR}/${PN}-2.4.7-Makefile.patch" #459446 |
57 |
+ "${FILESDIR}/${PN}-2.4.54-no-which.patch" #844868 |
58 |
+) |
59 |
+ |
60 |
+src_prepare() { |
61 |
+ default |
62 |
+ |
63 |
+ # This package really should upgrade to using pcre's .pc file. |
64 |
+ cat <<-\EOF >"${T}"/pcre-config |
65 |
+ #!/bin/bash |
66 |
+ flags=() |
67 |
+ for flag; do |
68 |
+ if [[ ${flag} == "--version" ]]; then |
69 |
+ flags+=( --modversion ) |
70 |
+ else |
71 |
+ flags+=( "${flag}" ) |
72 |
+ fi |
73 |
+ done |
74 |
+ exec ${PKG_CONFIG} libpcre "${flags[@]}" |
75 |
+ EOF |
76 |
+ chmod a+x "${T}"/pcre-config || die |
77 |
+ |
78 |
+ # Only here for which patch |
79 |
+ eautoreconf |
80 |
+} |
81 |
+ |
82 |
+src_configure() { |
83 |
+ # Brain dead check. |
84 |
+ tc-is-cross-compiler && export ap_cv_void_ptr_lt_long="no" |
85 |
+ |
86 |
+ tc-export PKG_CONFIG |
87 |
+ |
88 |
+ local myeconfargs=( |
89 |
+ --libexecdir="${EPREFIX}"/usr/$(get_libdir)/apache2/modules |
90 |
+ --sbindir="${EPREFIX}"/usr/sbin |
91 |
+ --with-z="${EPREFIX}"/usr |
92 |
+ --with-apr="${ESYSROOT}"/usr |
93 |
+ --with-apr-util="${ESYSROOT}"/usr |
94 |
+ --with-pcre="${T}"/pcre-config |
95 |
+ $(use_enable ssl) |
96 |
+ $(usex ssl '--with-ssl="${EPREFIX}"/usr' '') |
97 |
+ ) |
98 |
+ # econf overwrites the stuff from config.layout. |
99 |
+ ac_cv_path_PKGCONFIG="${PKG_CONFIG}" \ |
100 |
+ econf "${myeconfargs[@]}" |
101 |
+ sed -i \ |
102 |
+ -e '/^LTFLAGS/s:--silent::' \ |
103 |
+ build/rules.mk build/config_vars.mk || die |
104 |
+} |
105 |
+ |
106 |
+src_compile() { |
107 |
+ emake -C support |
108 |
+} |
109 |
+ |
110 |
+src_install() { |
111 |
+ emake -C support DESTDIR="${D}" install |
112 |
+ dodoc CHANGES |
113 |
+ doman docs/man/{dbmmanage,htdigest,htpasswd,htdbm,ab,logresolve}.1 \ |
114 |
+ docs/man/{htcacheclean,rotatelogs}.8 |
115 |
+ |
116 |
+ # Providing compatiblity symlinks for #177697 (which we'll stop to install |
117 |
+ # at some point). |
118 |
+ pushd "${ED}"/usr/sbin >/dev/null || die |
119 |
+ local i |
120 |
+ for i in *; do |
121 |
+ dosym ${i} /usr/sbin/${i}2 |
122 |
+ done |
123 |
+ popd >/dev/null || die |
124 |
+ |
125 |
+ # Provide a symlink for ab-ssl |
126 |
+ if use ssl ; then |
127 |
+ dosym ab /usr/bin/ab-ssl |
128 |
+ dosym ab /usr/bin/ab2-ssl |
129 |
+ fi |
130 |
+} |
131 |
|
132 |
diff --git a/app-admin/apache-tools/files/apache-tools-2.4.54-no-which.patch b/app-admin/apache-tools/files/apache-tools-2.4.54-no-which.patch |
133 |
new file mode 100644 |
134 |
index 000000000000..65764dfe022a |
135 |
--- /dev/null |
136 |
+++ b/app-admin/apache-tools/files/apache-tools-2.4.54-no-which.patch |
137 |
@@ -0,0 +1,54 @@ |
138 |
+https://bugs.gentoo.org/844868 |
139 |
+https://bz.apache.org/bugzilla/show_bug.cgi?id=66130 |
140 |
+--- a/build/aix/buildaix.ksh |
141 |
++++ b/build/aix/buildaix.ksh |
142 |
+@@ -26,14 +26,14 @@ export CFLAGS='-O2 -qlanglvl=extc99' |
143 |
+ lslpp -L bos.adt.insttools >/dev/null |
144 |
+ [[ $? -ne 0 ]] && echo "must have bos.adt.insttools installed" && exit -1 |
145 |
+ |
146 |
+-apr_config=`which apr-1-config` |
147 |
+-apu_config=`which apu-1-config` |
148 |
++apr_config=`command -v apr-1-config 2>/dev/null` |
149 |
++apu_config=`command -v apu-1-config 2>/dev/null` |
150 |
+ |
151 |
+ if [[ -z ${apr_config} && -z ${apu_config} ]] |
152 |
+ then |
153 |
+ export PATH=/opt/bin:${PATH} |
154 |
+- apr_config=`which apr-1-config` |
155 |
+- apu_config=`which apu-1-config` |
156 |
++ apr_config=`command -v apr-1-config 2>/dev/null` |
157 |
++ apu_config=`command -v apu-1-config 2>/dev/null` |
158 |
+ fi |
159 |
+ |
160 |
+ while test $# -gt 0 |
161 |
+--- a/build/pkg/buildpkg.sh |
162 |
++++ b/build/pkg/buildpkg.sh |
163 |
+@@ -24,8 +24,8 @@ PREFIX=/usr/local/apache2 |
164 |
+ TEMPDIR=/var/tmp/$USER/httpd-root |
165 |
+ rm -rf $TEMPDIR |
166 |
+ |
167 |
+-apr_config=`which apr-1-config` |
168 |
+-apu_config=`which apu-1-config` |
169 |
++apr_config=`command -v apr-1-config 2>/dev/null` |
170 |
++apu_config=`command -v apu-1-config 2>/dev/null` |
171 |
+ |
172 |
+ while test $# -gt 0 |
173 |
+ do |
174 |
+--- a/configure.in |
175 |
++++ b/configure.in |
176 |
+@@ -216,13 +216,13 @@ AC_ARG_WITH(pcre, |
177 |
+ APACHE_HELP_STRING(--with-pcre=PATH,Use external PCRE library)) |
178 |
+ if test "x$with_pcre" = "x" || test "$with_pcre" = "yes"; then |
179 |
+ with_pcre="$PATH" |
180 |
+-else if which $with_pcre 2>/dev/null; then :; else |
181 |
++else if command -v $with_pcre 2>/dev/null; then :; else |
182 |
+ with_pcre="$with_pcre/bin:$with_pcre" |
183 |
+ fi |
184 |
+ fi |
185 |
+ |
186 |
+ AC_CHECK_TARGET_TOOLS(PCRE_CONFIG, [pcre2-config pcre-config], |
187 |
+- [`which $with_pcre 2>/dev/null`], $with_pcre) |
188 |
++ [`command -v $with_pcre 2>/dev/null`], $with_pcre) |
189 |
+ |
190 |
+ if test "x$PCRE_CONFIG" != "x"; then |
191 |
+ if $PCRE_CONFIG --version >/dev/null 2>&1; then :; else |