1 |
commit: e84b3e1f7fa95d97ec2064d570ad5b1ed583d377 |
2 |
Author: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org> |
3 |
AuthorDate: Tue Jan 31 09:02:32 2017 +0000 |
4 |
Commit: Robin H. Johnson <robbat2 <AT> gentoo <DOT> org> |
5 |
CommitDate: Tue Jan 31 09:02:49 2017 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=e84b3e1f |
7 |
|
8 |
net-proxy/haproxy: bump. |
9 |
|
10 |
Package-Manager: portage-2.3.2 |
11 |
|
12 |
net-proxy/haproxy/Manifest | 1 + |
13 |
net-proxy/haproxy/haproxy-1.7.2.ebuild | 166 +++++++++++++++++++++++++++++++++ |
14 |
2 files changed, 167 insertions(+) |
15 |
|
16 |
diff --git a/net-proxy/haproxy/Manifest b/net-proxy/haproxy/Manifest |
17 |
index 96f87e6..8e5421c 100644 |
18 |
--- a/net-proxy/haproxy/Manifest |
19 |
+++ b/net-proxy/haproxy/Manifest |
20 |
@@ -6,3 +6,4 @@ DIST haproxy-1.6.11.tar.gz 1574029 SHA256 62fe982edb102a9f55205792bc14b0d05745cc |
21 |
DIST haproxy-1.6.9.tar.gz 1566715 SHA256 cf7d2fa891d2ae4aa6489fc43a9cadf68c42f9cb0de4801afad45d32e7dda133 SHA512 0060a93c628689e1ca9e5845f9f93641f7647efc176cbf093bce59be19496492c317c8101fa50dd6181b130f861c74a20199f18e41ebd6995715364b1ea46a2e WHIRLPOOL a7311cb08507898cf19a422a6a55a6d429cbb99e0329b2de0defea472314c495d6c426a973ef436d532340f95d5abee2ad07fbf1d051d36fe4618ac28b743a35 |
22 |
DIST haproxy-1.7.0.tar.gz 1728237 SHA256 abdce486f98c024f3df45dade4011caeb925f48129370f4754a45f1623794622 SHA512 e41c4d73e438f3975dd704de5048eb1179cfa884ae16970d868d8ae7e0958ee0ab5bd58a952113e90b89c040cb84402dafd4ae6e4daf03ea6621e03b861837c7 WHIRLPOOL a82563956cad92ccb257cfe202a43ea1cae3c2b4fa36fb954829096e55b524cbe224080669f60a8b62e38e73e682321a50a59e3d650a6b0ae340d3bf24a9768d |
23 |
DIST haproxy-1.7.1.tar.gz 1730401 SHA256 56a7f5e919755d9b01b64f91b497c2c4eabdbe3a6fd84f7e5192a264097d8759 SHA512 97dd81493a8902efd1b15171ace2da16f77feb537657e22c28f0ace3c05600f860e4d6f70a40f6fde8f0701e5399f8a4a7d982d4acf9cbccda6e2cf7dbe6f68e WHIRLPOOL 5bed6c02e888f2193574881be16c6bb87041438486edf73f2bcbaeda4394012d966465645c95e8a0e9fc30e3c306a327589a603e48b0dc880b6499876bb39116 |
24 |
+DIST haproxy-1.7.2.tar.gz 1735073 SHA256 f95b40f52a4d61feaae363c9b15bf411c16fe8f61fddb297c7afcca0072e4b2f SHA512 1db3bdc5110d84694390b357ded0700b3fc902516ae7a67902fe7dfc76f18abb3c56e0c46209f9b0e025904d62859020ee97b98680f237a2e15f03154f24fe5d WHIRLPOOL 6ffc05ca50243b2dd24b414264852fcfdda724888a00f0b987b0d6d3ef4d9df92192befa6e0e36a17aef696e96cdde6c865689ef6c27e87486d53aa094d06241 |
25 |
|
26 |
diff --git a/net-proxy/haproxy/haproxy-1.7.2.ebuild b/net-proxy/haproxy/haproxy-1.7.2.ebuild |
27 |
new file mode 100644 |
28 |
index 00000000..3a264d3 |
29 |
--- /dev/null |
30 |
+++ b/net-proxy/haproxy/haproxy-1.7.2.ebuild |
31 |
@@ -0,0 +1,166 @@ |
32 |
+# Copyright 1999-2017 Gentoo Foundation |
33 |
+# Distributed under the terms of the GNU General Public License v2 |
34 |
+# $Id$ |
35 |
+ |
36 |
+EAPI="6" |
37 |
+ |
38 |
+[[ ${PV} == *9999 ]] && SCM="git-r3" |
39 |
+inherit user versionator toolchain-funcs flag-o-matic systemd linux-info $SCM |
40 |
+ |
41 |
+MY_P="${PN}-${PV/_beta/-dev}" |
42 |
+ |
43 |
+DESCRIPTION="A TCP/HTTP reverse proxy for high availability environments" |
44 |
+HOMEPAGE="http://haproxy.1wt.eu" |
45 |
+if [[ ${PV} != *9999 ]]; then |
46 |
+ SRC_URI="http://haproxy.1wt.eu/download/$(get_version_component_range 1-2)/src/${MY_P}.tar.gz" |
47 |
+ KEYWORDS="~amd64 ~arm ~ppc ~x86" |
48 |
+else |
49 |
+ EGIT_REPO_URI="http://git.haproxy.org/git/haproxy-$(get_version_component_range 1-2).git/" |
50 |
+ EGIT_BRANCH=master |
51 |
+fi |
52 |
+ |
53 |
+LICENSE="GPL-2 LGPL-2.1" |
54 |
+SLOT="0" |
55 |
+IUSE="+crypt doc examples libressl slz net_ns +pcre pcre-jit ssl tools vim-syntax +zlib lua device-atlas 51degrees wurfl" |
56 |
+REQUIRED_USE="pcre-jit? ( pcre ) |
57 |
+ device-atlas? ( pcre ) |
58 |
+ ?? ( slz zlib )" |
59 |
+ |
60 |
+DEPEND=" |
61 |
+ pcre? ( |
62 |
+ dev-libs/libpcre |
63 |
+ pcre-jit? ( dev-libs/libpcre[jit] ) |
64 |
+ ) |
65 |
+ ssl? ( |
66 |
+ !libressl? ( dev-libs/openssl:0=[zlib?] ) |
67 |
+ libressl? ( dev-libs/libressl:0= ) |
68 |
+ ) |
69 |
+ slz? ( dev-libs/libslz:= ) |
70 |
+ zlib? ( sys-libs/zlib ) |
71 |
+ lua? ( dev-lang/lua:5.3 ) |
72 |
+ device-atlas? ( dev-libs/device-atlas-api-c )" |
73 |
+RDEPEND="${DEPEND}" |
74 |
+ |
75 |
+S="${WORKDIR}/${MY_P}" |
76 |
+ |
77 |
+DOCS=( CHANGELOG CONTRIBUTING MAINTAINERS README ) |
78 |
+version_is_at_least 1.7.0 $PV && PATCHES=( "${FILESDIR}"/haproxy-1.7-contrib.patch ) |
79 |
+CONTRIBS=( halog iprange ) |
80 |
+# ip6range is present in 1.6, but broken. |
81 |
+version_is_at_least 1.7.0 $PV && CONTRIBS+=( ip6range spoa_example tcploop ) |
82 |
+ |
83 |
+haproxy_use() { |
84 |
+ (( $# != 2 )) && die "${FUNCNAME} <USE flag> <make option>" |
85 |
+ |
86 |
+ usex "${1}" "USE_${2}=1" "USE_${2}=" |
87 |
+} |
88 |
+ |
89 |
+pkg_setup() { |
90 |
+ enewgroup haproxy |
91 |
+ enewuser haproxy -1 -1 -1 haproxy |
92 |
+ |
93 |
+ if use net_ns; then |
94 |
+ CONFIG_CHECK="~NET_NS" |
95 |
+ linux-info_pkg_setup |
96 |
+ fi |
97 |
+} |
98 |
+ |
99 |
+src_prepare() { |
100 |
+ default |
101 |
+ |
102 |
+ sed -e 's:@SBINDIR@:'/usr/bin':' contrib/systemd/haproxy.service.in \ |
103 |
+ > contrib/systemd/haproxy.service || die |
104 |
+ |
105 |
+ sed -ie 's:/usr/sbin/haproxy:/usr/bin/haproxy:' src/haproxy-systemd-wrapper.c || die |
106 |
+} |
107 |
+ |
108 |
+src_compile() { |
109 |
+ local -a args=( |
110 |
+ TARGET=linux2628 |
111 |
+ USE_GETADDRINFO=1 |
112 |
+ USE_TFO=1 |
113 |
+ ) |
114 |
+ |
115 |
+ args+=( $(haproxy_use crypt LIBCRYPT) ) |
116 |
+ args+=( $(haproxy_use net_ns NS) ) |
117 |
+ args+=( $(haproxy_use pcre PCRE) ) |
118 |
+ args+=( $(haproxy_use pcre-jit PCRE_JIT) ) |
119 |
+ args+=( $(haproxy_use ssl OPENSSL) ) |
120 |
+ args+=( $(haproxy_use slz SLZ) ) |
121 |
+ args+=( $(haproxy_use zlib ZLIB) ) |
122 |
+ args+=( $(haproxy_use lua LUA) ) |
123 |
+ args+=( $(haproxy_use 51degrees 51DEGREES) ) |
124 |
+ args+=( $(haproxy_use device-atlas DEVICEATLAS) ) |
125 |
+ args+=( $(haproxy_use wurfl WURFL) ) |
126 |
+ |
127 |
+ # For now, until the strict-aliasing breakage will be fixed |
128 |
+ append-cflags -fno-strict-aliasing |
129 |
+ |
130 |
+ emake CFLAGS="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) ${args[@]} |
131 |
+ |
132 |
+ if use tools ; then |
133 |
+ for contrib in ${CONTRIBS[@]} ; do |
134 |
+ emake -C contrib/${contrib} \ |
135 |
+ CFLAGS="${CFLAGS}" OPTIMIZE="${CFLAGS}" LDFLAGS="${LDFLAGS}" CC=$(tc-getCC) ${args[@]} |
136 |
+ done |
137 |
+ fi |
138 |
+} |
139 |
+ |
140 |
+src_install() { |
141 |
+ dobin haproxy |
142 |
+ |
143 |
+ newconfd "${FILESDIR}/${PN}.confd" $PN |
144 |
+ newinitd "${FILESDIR}/${PN}.initd-r3" $PN |
145 |
+ |
146 |
+ doman doc/haproxy.1 |
147 |
+ |
148 |
+ dobin haproxy-systemd-wrapper |
149 |
+ systemd_dounit contrib/systemd/haproxy.service |
150 |
+ |
151 |
+ einstalldocs |
152 |
+ |
153 |
+ # The errorfiles are used by upstream defaults. |
154 |
+ insinto /etc/haproxy/errors/ |
155 |
+ doins examples/errorfiles/* |
156 |
+ |
157 |
+ if use doc; then |
158 |
+ dodoc ROADMAP doc/*.txt |
159 |
+ #if use lua; then |
160 |
+ # TODO: doc/lua-api/ |
161 |
+ #fi |
162 |
+ fi |
163 |
+ |
164 |
+ if use tools ; then |
165 |
+ has halog "${CONTRIBS[@]}" && dobin contrib/halog/halog |
166 |
+ has "iprange" "${CONTRIBS[@]}" && newbin contrib/iprange/iprange haproxy_iprange |
167 |
+ has "ip6range" "${CONTRIBS[@]}" && newbin contrib/ip6range/ip6range haproxy_ip6range |
168 |
+ has "spoa_example" "${CONTRIBS[@]}" && newbin contrib/spoa_example/spoa haproxy_spoa_example |
169 |
+ has "spoa_example" "${CONTRIBS[@]}" && newdoc contrib/spoa_example/README README.spoa_example |
170 |
+ has "tcploop" "${CONTRIBS[@]}" && newbin contrib/tcploop/tcploop haproxy_tcploop |
171 |
+ fi |
172 |
+ |
173 |
+ if use examples ; then |
174 |
+ docinto examples |
175 |
+ dodoc examples/*.cfg |
176 |
+ dodoc examples/seamless_reload.txt |
177 |
+ fi |
178 |
+ |
179 |
+ if use vim-syntax ; then |
180 |
+ insinto /usr/share/vim/vimfiles/syntax |
181 |
+ doins examples/haproxy.vim |
182 |
+ fi |
183 |
+} |
184 |
+ |
185 |
+pkg_postinst() { |
186 |
+ if [[ ! -f "${EROOT}/etc/haproxy/haproxy.cfg" ]] ; then |
187 |
+ ewarn "You need to create /etc/haproxy/haproxy.cfg before you start the haproxy service." |
188 |
+ ewarn "It's best practice to not run haproxy as root, user and group haproxy was therefore created." |
189 |
+ ewarn "Make use of them with the \"user\" and \"group\" directives." |
190 |
+ |
191 |
+ if [[ -d "${EROOT}/usr/share/doc/${PF}" ]]; then |
192 |
+ einfo "Please consult the installed documentation for learning the configuration file's syntax." |
193 |
+ einfo "The documentation and sample configuration files are installed here:" |
194 |
+ einfo " ${EROOT}usr/share/doc/${PF}" |
195 |
+ fi |
196 |
+ fi |
197 |
+} |