Sync with portage [Fri Aug 3 15:43:09 MSK 2018].

mhiretskiy 1191
root 6 years ago
parent bce8250ba7
commit 08cde36298

Binary file not shown.

Binary file not shown.

@ -5,8 +5,10 @@ DIST mongo-tools-3.4.10.tar.gz 4719399 BLAKE2B 8165248bf58f2ea2b02e365a3609c72b7
DIST mongo-tools-3.4.13.tar.gz 4719488 BLAKE2B 27c7716b21f1a23408d0f31aee111c5877f5172121a987c234ff01eb2690bbc71bca4e00fc13b701ca6b91dce0c9aaae43c2239a60a52e130e1390bf5bafef60 SHA512 c233268328ef868ec06c9a9d83009141b39c84ba642e7de7dece3210717ba8de600f39896a30ed23d1577db9f4697c3a8d720cf35248bca2b00a17642b043237
DIST mongo-tools-3.4.14.tar.gz 4719370 BLAKE2B 2add25ddf9b5b7d2ebecdd647dfb2c818643b16f623fd1faba36a8d6f5a181e80ad47de45fc56e462290f61f6c16c27a6b0587542315981537627256e69b4958 SHA512 a0d715fe36769740ba25e92b742b157dc264b141ddd56d64ca4c6f8ffea11df291ce871aaa723acdb8b7f5318ac1edb8c5fb9dd7bf2edfe08d4e7cef343abea7
DIST mongo-tools-3.4.15.tar.gz 4697188 BLAKE2B 690ec3187cb781c9cae903a27eca9d1d504e2e52cc7f48790b5d5b5a1dfe18cff95dd52f8fa03854548a2e634d2aed56e626b8702f2fcd27a10952a37dff9120 SHA512 f7c8655f56a1f5fedad00fbadd26b150d6fea071edccaa7ac18e80c9051ed2324691e98e799e6a9ca09e944ebe340b63a2ac0b9caeffbcc8c8dee0744cba1af7
DIST mongo-tools-3.4.16.tar.gz 4697191 BLAKE2B 2e9a0e7dc8016d3e7d7c7f8d0cf80a97d3d199603c0b8b791df5a0d79d418ffaa232eee694047a7ca11fa7623023b4123becd437cfe3dec11e26cd525720bcad SHA512 b40c6dee75d860de1da73faf79f5f68c098ce7c80681486c66fff04a937474dcede91c7be907a8e36033b3898f7499e8f53271944c0df3360756c27361efb6f5
DIST mongo-tools-3.6.2.tar.gz 4693924 BLAKE2B 61c44d579f6eb4013ee6c0118ebe89a2d454ef8cf6ad933479885cb71d169185272b03d9c63fa738d67bbd1b9efd4bc964eb17adcc5002508589d198cdb17752 SHA512 5ac2b1d2b33271f63c406c69bd8a576a21f4dcaa6f75839e0f907ebc9968f0e121eb3800e88da050c120856e7ddda4f12d551bb731d4acac0f5cf09f66fc948a
DIST mongo-tools-3.6.3.tar.gz 4693833 BLAKE2B fc7139984cf3dcb7b4ce6f6c2028296651aa59ac68d7068bdf748e28eeb65b1fd9b07580d0c93f3f41dbb01030a12433a07a04deadf28e0ff792387fa78ae4aa SHA512 7dba782c84a728aa9ceb28cbd9934f58b615dccfb238a9dbd63b18661ba4e74ddba21f93d9f12e6d80d293ebe42a82d31fa64448aacdba75bd07d964a5f631fc
DIST mongo-tools-3.6.4.tar.gz 4693872 BLAKE2B 5d72b32fa8ad7bc106c6ea3c09a27a093b9a1ae2392b4fa534042c5461fdc2b958dcbbf32e0ed596be234921e2ee21cc8f6132d57ae870a234abfc7adbb3b2e9 SHA512 53d06fa4a1b58de8001d6bf6e85f7edc97ce2cfbbb69c1ab05219deaa05ad9dd77d93f98c5526b4f58644a766e1b0f123686358095f059c71a4277634603f23f
DIST mongo-tools-3.6.5.tar.gz 4720814 BLAKE2B 5dd064f70557ec1ab979d08523f3dd305fb310c533b69bc99be3ad3d006036354f62b9f3d61c242e1481a254bed538a5e1cf5662f0e35705f1c50a76f31fddbb SHA512 dd2d7cc64043b42a70b5de0ea493f94722a4476248bfd77d6892861e4be6ab20175992367965dfd687bf8b7ebece6113b7f7a3e59256497e3ecd7e2678875965
DIST mongo-tools-3.6.6.tar.gz 4723751 BLAKE2B 876d46c47190398d1218a760bdeb8167c9224ef000a96b5f6080d6dcd44fe8187fdfbc38b1a61dbf437132e16e053212cf122daec3915647448d114983e51fc3 SHA512 b8cc02626accb90d8dacf50ea851619885a01503e28b17ed6a12cc9ccec2680a8cd12a566b32187d472f74c9625bf013afcdebed1a42d78ff613c49d3fc838b2
DIST mongo-tools-4.0.0.tar.gz 10872217 BLAKE2B 84e92178c0e4827926de525a70d6124635d59e270a3d37e23ec8653cc64d99bb7489fa6266917437ca45aa3ca5e00bc59b81e65c5b72e717db2701c6f7327bec SHA512 d67c4aca9b41266109adc39bb1a642206738fda393e1f9f05570c02a00a02e29ec71c71e67ad232c72d66543ae7e7bfe07fbcf26958d48ed0e631da452c1904d

@ -0,0 +1,60 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
MY_PV=${PV/_rc/-rc}
MY_P=${PN}-r${MY_PV}
DESCRIPTION="A high-performance, open source, schema-free document-oriented database"
HOMEPAGE="https://www.mongodb.com"
SRC_URI="https://github.com/mongodb/mongo-tools/archive/r${MY_PV}.tar.gz -> mongo-tools-${MY_PV}.tar.gz"
LICENSE="Apache-2.0"
SLOT="0"
KEYWORDS="~amd64"
IUSE="sasl ssl"
RDEPEND="!<dev-db/mongodb-3.0.0"
DEPEND="${RDEPEND}
dev-lang/go:=
net-libs/libpcap
sasl? ( dev-libs/cyrus-sasl )
ssl? ( dev-libs/openssl:0= )"
S=${WORKDIR}/${MY_P}
src_prepare() {
default
# 1) ensure we use bash wrt #582906
# 2) do not substitute version because it uses git
sed -e 's@/bin/sh@/bin/bash@g' \
-e '/^sed/,+3d' \
-e '/^mv/d' \
-i build.sh || die
# build pie to avoid text relocations wrt #582854
# skip on ppc64 wrt #610984
if ! use ppc64; then
sed -i 's/\(go build\)/\1 -buildmode=pie/g' build.sh || die
fi
}
src_compile() {
local myconf=()
if use sasl; then
myconf+=(sasl)
fi
if use ssl; then
myconf+=(ssl)
fi
./build.sh "${myconf[@]}" || die "build failed"
}
src_install() {
dobin bin/*
}

@ -0,0 +1,61 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
MY_PV=${PV/_rc/-rc}
MY_P=${PN}-r${MY_PV}
DESCRIPTION="A high-performance, open source, schema-free document-oriented database"
HOMEPAGE="https://www.mongodb.com"
SRC_URI="https://github.com/mongodb/mongo-tools/archive/r${MY_PV}.tar.gz -> mongo-tools-${MY_PV}.tar.gz"
LICENSE="Apache-2.0"
SLOT="0"
KEYWORDS="~amd64"
IUSE="sasl ssl"
RDEPEND="!<dev-db/mongodb-3.0.0"
DEPEND="${RDEPEND}
dev-lang/go:=
net-libs/libpcap
sasl? ( dev-libs/cyrus-sasl )
ssl? ( dev-libs/openssl:0= )"
S=${WORKDIR}/${MY_P}
src_prepare() {
default
# 1) ensure we use bash wrt #582906
# 2) do not substitute version because it uses git
sed -e 's@/bin/sh@/bin/bash@g' \
-e '/^sed/,+3d' \
-e '/^stty/d' \
-e '/^mv/d' \
-i build.sh || die
# build pie to avoid text relocations wrt #582854
# skip on ppc64 wrt #610984
if ! use ppc64; then
sed -i 's/\(go build\)/\1 -buildmode=pie/g' build.sh || die
fi
}
src_compile() {
local myconf=()
if use sasl; then
myconf+=(sasl)
fi
if use ssl; then
myconf+=(ssl)
fi
./build.sh "${myconf[@]}" || die "build failed"
}
src_install() {
dobin bin/*
}

@ -1 +1 @@
DIST password-store-1.7.2.tar.xz 63620 BLAKE2B a1fe0b7ee1fdb94d2b76773653462d14c07c8fb239ffbcae210cc3c9c829fc5c0bd0bf85d8d44343a0cec50aae953b13a70d67aa7c94abf6c02f84bfd0d7c4ff SHA512 e6719a7125af6ecd80fdbeb38b4e2e89e7358ff16e18739d68a04b72dfdf860294b54f7ec0ec9676a62d2e270db8f54784a357c82217a478694472f8136e3657
DIST password-store-1.7.3.tar.xz 63416 BLAKE2B 5931608e0208dfe6965b79f586c153a4930d1c3d3b74433d026ee0bc5889fcc29334c637ca4fb68308d0169bad7c8235b6632e9f80eda1e24f0f5721353f88e3 SHA512 89755a7b02f05d75055a9fc14fd3f456c0a49ec31bdffd097a027f91228c64a98b18c1e80017aeda811773ae3287ff1b9737532da8ded06799d8fe3979ca06f7

@ -1,78 +0,0 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
inherit bash-completion-r1 elisp-common
DESCRIPTION="Stores, retrieves, generates, and synchronizes passwords securely"
HOMEPAGE="https://www.passwordstore.org/"
SRC_URI="https://git.zx2c4.com/password-store/snapshot/password-store-${PV}.tar.xz"
SLOT="0"
LICENSE="GPL-2"
KEYWORDS="amd64 ~arm x86 ~x86-macos"
IUSE="+git X zsh-completion fish-completion emacs dmenu importers elibc_Darwin"
RDEPEND="
app-crypt/gnupg
media-gfx/qrencode
>=app-text/tree-1.7.0
git? ( dev-vcs/git )
X? ( x11-misc/xclip )
elibc_Darwin? ( app-misc/getopt )
zsh-completion? ( app-shells/gentoo-zsh-completions )
fish-completion? ( app-shells/fish )
dmenu? ( x11-misc/dmenu x11-misc/xdotool )
emacs? ( virtual/emacs )
"
S="${WORKDIR}/password-store-${PV}"
src_prepare() {
default
use elibc_Darwin || return
# use coreutils'
sed -i -e 's/openssl base64/base64/g' src/platform/darwin.sh || die
# host getopt isn't cool, and we aren't brew (rip out brew reference)
sed -i -e '/^GETOPT=/s/=.*$/=getopt-long/' src/platform/darwin.sh || die
# make sure we can find "mount"
sed -i -e 's:mount -t:/sbin/mount -t:' src/platform/darwin.sh || die
}
src_compile() {
:;
}
src_install() {
emake install \
DESTDIR="${D}" \
PREFIX="${EPREFIX}/usr" \
BASHCOMPDIR="$(get_bashcompdir)" \
WITH_BASHCOMP=yes \
WITH_ZSHCOMP=$(usex zsh-completion) \
WITH_FISHCOMP=$(usex fish-completion)
use dmenu && dobin contrib/dmenu/passmenu
if use emacs; then
elisp-install ${PN} contrib/emacs/*.el
elisp-site-file-install "${FILESDIR}/50${PN}-gentoo.el"
fi
if use importers; then
exeinto /usr/share/${PN}/importers
doexe contrib/importers/*
fi
}
pkg_postinst() {
use emacs && elisp-site-regen
if use importers; then
einfo "To import passwords from other password managers, you may use the"
einfo "various importer scripts found in:"
einfo " ${EROOT%/}/usr/share/${PN}/importers/"
fi
}
pkg_postrm() {
use emacs && elisp-site-regen
}

@ -11,7 +11,7 @@ SRC_URI="https://git.zx2c4.com/password-store/snapshot/password-store-${PV}.tar.
SLOT="0"
LICENSE="GPL-2"
KEYWORDS="~amd64 ~arm ~x86"
KEYWORDS="~amd64 ~arm ~x86 ~x86-macos"
IUSE="+git X zsh-completion fish-completion emacs dmenu importers elibc_Darwin"
RDEPEND="

@ -1,12 +1,4 @@
DIST rsyslog-8.28.0.tar.gz 2471122 BLAKE2B 48ed55cbf02eca22591c3d1d59db8f956e4d852cbabb4ae8837767a2c843209a53becbe2a9f595290b44d79c8813414c20954ce1ccaa08bf0786423df79344e3 SHA512 e27ba0ff22e945393536abc5bc6e234d8849db291a5056429b59b47abe15fb060fc5c26efedcfe347b386d438b3f8a029ae4577a1d803666701431677f628cb1
DIST rsyslog-8.32.0.tar.gz 2478990 BLAKE2B 21bfc93b55da107bec2eddb89cb42d76990ced2675caeb6e73183a109f9bc8293bde43f202bb56007f9ea4e49de385b004c158059cb13e8d3d376bf050ca445a SHA512 eea85d77bf3624fbad6f0838fa2a4af7c14d853c8f120f14cf697cdfda7f7e0692dab684d2ddd07fe44a0bcd50cf91baf69af1bb63dc9d60e19146f1150155ac
DIST rsyslog-8.33.1.tar.gz 2494338 BLAKE2B 680ad2c062386e4e3e6c6e1a83cf0001d63da305edae9df527d1079a2fa13b8715e3cbfa211ca908e0005f1762becfd88369a7cd1488134564980137f0e98d86 SHA512 c4b426409e89463a8e8f7f9d0267f2fa1df1a84e947ce7bf91255db88b4cad5b7e607c476ba2db0543af069c44cdbb35330e0839696bf83668200e8ac009c6a0
DIST rsyslog-8.34.0.tar.gz 2545544 BLAKE2B 66caf277a814563027183ecf267d76067c384adf8d6d7b8543203df9a7c37242722dd35445e4446aacf1e680f5f3957cea40ece8a284ef2a393b4a71e3a2b49c SHA512 69eaececa2f8b98799deac8e6cb2cf635a5117da7a21cbb0b880b7df1d83c6ccf16133dab099a6e5fb865f34c2dad164a1bf1952d16ca116af3b1dd35d15065e
DIST rsyslog-8.35.0.tar.gz 2590108 BLAKE2B e201c1366b8ab96c070829d51de079212e82216a793eb7622aa91c66e2330981de8be547b1ee7f102ed7d8c8de054d58ba151e95238146a61fba8fe908c5f929 SHA512 3b8845fc057147c2dd740b3bb432e7fb101ad60be5c6bc86a2c2796bcd3f3526c617d45b9e8301388d51047a125ca18ba4ac54f8be2a13eabbbe8fb9361beecc
DIST rsyslog-8.36.0.tar.gz 2639477 BLAKE2B 9c7343d853f79e2955a8999e2871a2a9b008cb3ef75b94e2381a3a0ff3e49445593d852d7de3819851dc0d4c17a91d966ca2fbfd52e8215ebdbaf6b7ccd68bdf SHA512 b0c8689374b5b0fb5ad9675ad8983ce67bd04d34ad07d39cf8f91498fd2fd21a173f1077e5fa1b66a89a9d93ab011fc6345ac1a3be9961f4794fc9e152c32a50
DIST rsyslog-docs-8.28.0.tar.gz 4424901 BLAKE2B 9753b1a48b9d3bb045f2d088de5df0bbe5bc9045a82a5cab98b27c2df7648ac312929a173ec34c81ced46cb0eba336d708204b73b57413686769afa882dceaa5 SHA512 c085e09149cfc27ce0cd22edf9ad3f81b111f491fbea79afbc3172882065bd8324e366e3b5d09c885c1a3aa63fe8fbbe154d66488319d4ffc0867f938e1ab07d
DIST rsyslog-docs-8.32.0.tar.gz 5368254 BLAKE2B 6d1efb191698bb1cfb03660167e5dcf9eea8f2fd2e459c350cd55aa24afcc5fb44d2bc0ef5590c6951326fbd0215aecbd59a6122e88ff449f566b37d1ee00d56 SHA512 e64eba3c40eab35e266826fb7e183418f38eb008f2a21ddf2c523d1e42aacaa20f882a561e5df67a979463048b58232fa82759645a21dc6962f6836ac8f57bce
DIST rsyslog-docs-8.33.1.tar.gz 6770438 BLAKE2B e076688d7559c16986241149c00f6df603e2c90771222f4f91dc944fbdeace3dbc6e47fc82602f852a7407e064fe31df0a1c2940d521ae6ae21f5663518bfeb7 SHA512 fcc8ffee372c0b0dc2ab1b76dcf68a66ce820996cf2d46a2b5c6fd40e6fad5ef3c33da97a2e88956751597c20cf0c4a9b6537c22db0b3b46d1a734a9d9f95df5
DIST rsyslog-docs-8.34.0.tar.gz 7419160 BLAKE2B 928e6a4044d6d2161483f934e6c2cd5e489a3ec95b823419d7d57b98a7dd6c73f4d28d17c238471592fe1c692b626b57c7bf647e926c1c38ff5a774e5d2defd5 SHA512 edf9aa63c777624c3dc27dfd64b38893b9b4c9b56941df1d7a8c6bc3cb4cbbfb83e8c356cbefeab7c688ecb6017b66ed99931cb71b69b7c927b4743548dd40d4
DIST rsyslog-docs-8.35.0.tar.gz 7427270 BLAKE2B 5441080c07a8398cd5d513ba6abe0335f62762f105354105549f0440c0429c62a4f28a4cc84a71d049bc8134cd64bda2c2210a2f30fd5b94f53e0bc783e7c8d1 SHA512 f78d0451eef789d60f7c5ae1eed46c4a9f7a6ade73b829f65aa2373aa786b00e84e8957089532b1b652838bd9f62b41d92530276a0d27e21b8e94d5f0e4728a6
DIST rsyslog-docs-8.36.0.tar.gz 7570338 BLAKE2B 031f94b88fb97e6c8b01d224279138c371a5f54ecc5d7a9298b4ec6351c5d380065877888ab1969386b76b9e715937b7335bee59c3d5b8ddd4910392a58d08cb SHA512 a93f56c9c9464a9ca87f61169c6fcfaa94608f31210eaac77e882e64bf5f514c887765db6bb57e4defafeb2a6e552506f0274c1ed275306efc1656f5520b5efa
DIST rsyslog-doc-8.35.0.tar.gz 7427270 BLAKE2B 5441080c07a8398cd5d513ba6abe0335f62762f105354105549f0440c0429c62a4f28a4cc84a71d049bc8134cd64bda2c2210a2f30fd5b94f53e0bc783e7c8d1 SHA512 f78d0451eef789d60f7c5ae1eed46c4a9f7a6ade73b829f65aa2373aa786b00e84e8957089532b1b652838bd9f62b41d92530276a0d27e21b8e94d5f0e4728a6
DIST rsyslog-doc-8.36.0.tar.gz 7570338 BLAKE2B 031f94b88fb97e6c8b01d224279138c371a5f54ecc5d7a9298b4ec6351c5d380065877888ab1969386b76b9e715937b7335bee59c3d5b8ddd4910392a58d08cb SHA512 a93f56c9c9464a9ca87f61169c6fcfaa94608f31210eaac77e882e64bf5f514c887765db6bb57e4defafeb2a6e552506f0274c1ed275306efc1656f5520b5efa

@ -1,95 +0,0 @@
#######################
### DEFAULT ACTIONS ###
#######################
auth,authpriv.* action(
type="omfile"
File="/var/log/auth.log"
FileCreateMode="0600"
FileOwner="root"
FileGroup="adm"
Sync="off"
)
cron.* action(
type="omfile"
File="/var/log/cron.log"
FileOwner="root"
FileGroup="adm"
)
daemon.* action(
type="omfile"
File="/var/log/daemon.log"
FileOwner="root"
FileGroup="adm"
)
kern.* action(
type="omfile"
File="/var/log/kern.log"
FileOwner="root"
FileGroup="adm"
)
lpr.* action(
type="omfile"
File="/var/log/lpr.log"
FileOwner="root"
FileGroup="adm"
)
mail.* action(
type="omfile"
File="/var/log/mail.log"
FileOwner="root"
FileGroup="adm"
)
news.* action(
type="omfile"
File="/var/log/news.log"
FileOwner="root"
FileGroup="adm"
)
user.* action(
type="omfile"
File="/var/log/user.log"
FileOwner="root"
FileGroup="adm"
)
*.=debug;auth,authpriv,news,mail.none action(
type="omfile"
File="/var/log/debug.log"
FileOwner="root"
FileGroup="adm"
)
*.info;auth,authpriv,cron,daemon,lpr,mail,news.none action(
type="omfile"
File="/var/log/messages"
FileOwner="root"
FileGroup="adm"
)
# Uncomment the following directive to re-enable the
# deprecated "/var/log/syslog" log file (don't forget to re-enable log
# rotation in "/etc/logrotate.d/rsyslog" if you do that!)
#*.*;auth,authpriv.none action(
# type="omfile"
# File="/var/log/syslog"
# FileOwner="root"
# FileGroup="adm"
#)
*.emerg action(
type="omusrmsg"
Users="*"
action.execOnlyOnceEveryInterval="10"
)
# Create an additional socket for the default chroot location
# (used by net-misc/openssh[hpn], see https://bugs.gentoo.org/490744)
input(type="imuxsock" Socket="/var/empty/dev/log")

@ -1,23 +0,0 @@
https://github.com/rsyslog/rsyslog/pull/1791
---
tests/Makefile.am | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -498,7 +498,6 @@ TESTS += msgvar-concurrency-array.sh \
mmnormalize_processing_test2.sh \
mmnormalize_processing_test3.sh \
mmnormalize_processing_test4.sh
-endif
if ENABLE_IMPTCP
TESTS += \
@@ -512,6 +511,7 @@ if LOGNORM_REGEX_SUPPORTED
TESTS += \
mmnormalize_regex.sh
endif
+endif
if ENABLE_MMJSONPARSE
TESTS += \

@ -1,137 +0,0 @@
https://github.com/rsyslog/rsyslog/commit/d9475f133e3c79875a7c4ccd92038b7123c1f155
https://github.com/rsyslog/rsyslog/commit/468eeb79b8da91fb71dfef6bfb25476b2a37f446
https://github.com/rsyslog/rsyslog/commit/50205ced0fc22e74f26f2a07b557b69c5d30e168
--- a/grammar/rainerscript.c
+++ b/grammar/rainerscript.c
@@ -1935,6 +1935,7 @@ num2ipv4(struct svar *__restrict__ const sourceVal) {
return(estr);
}
+#ifdef HAVE_LIBCURL
/* curl callback for doFunc_http_request */
static size_t
curlResult(void *ptr, size_t size, size_t nmemb, void *userdata)
@@ -2010,6 +2011,7 @@ doFunc_http_request(struct cnffunc *__restrict__ const func,
}
RETiRet;
}
+#endif
static int ATTR_NONNULL(1,3,4)
doFunc_is_time(const char *__restrict__ const str,
@@ -2513,11 +2515,16 @@ doFuncCall(struct cnffunc *__restrict__ const func, struct svar *__restrict__ co
if(bMustFree2) free(str2);
break;
case CNFFUNC_HTTP_REQUEST:
+#ifdef HAVE_LIBCURL
cnfexprEval(func->expr[0], &r[0], usrptr, pWti);
str = (char*) var2CString(&r[0], &bMustFree);
doFunc_http_request(func, ret, str);
if(bMustFree) free(str);
varFreeMembers(&r[0]);
+#else
+ LogError(0, RS_RET_INTERNAL_ERROR,
+ "rainerscript: internal error: HTTP_Fetch not supported, not built with libcurl support");
+#endif
break;
default:
if(Debug) {
--- a/configure.ac
+++ b/configure.ac
@@ -454,6 +454,8 @@ if test "$enable_libcurl" = "yes"; then
)
fi
+AM_CONDITIONAL(ENABLE_LIBCURL, test "x${enable_libcurl}" = "xyes")
+
# klog
AC_ARG_ENABLE(klog,
[AS_HELP_STRING([--enable-klog],[Integrated klog functionality @<:@default=yes@:>@])],
--- a/tests/Makefile.am
+++ b/tests/Makefile.am
@@ -226,7 +226,6 @@ TESTS += \
rscript_contains.sh \
rscript_bare_var_root.sh \
rscript_bare_var_root-empty.sh \
- rscript_http_request.sh \
rscript_ipv42num.sh \
rscript_field.sh \
rscript_stop.sh \
@@ -305,7 +304,11 @@ TESTS += \
lookup_table_rscript_reload.sh \
lookup_table_rscript_reload_without_stub.sh \
multiple_lookup_tables.sh
-endif
+if ENABLE_LIBCURL
+TESTS += \
+ rscript_http_request.sh
+endif # ENABLE_LIBCURL
+endif # ENABLE_TESTBENCH2
if HAVE_VALGRIND
TESTS += \
@@ -313,7 +316,6 @@ TESTS += \
mmexternal-InvldProg-vg.sh \
internal-errmsg-memleak-vg.sh \
rscript_set_memleak-vg.sh \
- rscript_http_request-vg.sh \
no-parser-vg.sh \
discard-rptdmsg-vg.sh \
discard-allmark-vg.sh \
@@ -338,6 +340,10 @@ TESTS += \
multiple_lookup_tables-vg.sh \
fac_local0-vg.sh \
rscript_trim-vg.sh
+if ENABLE_LIBCURL
+TESTS += \
+ rscript_http_request-vg.sh
+endif # ENABLE_LIBCURL
endif # HAVE_VALGRIND
if ENABLE_ROOT_TESTS
--- a/grammar/Makefile.am
+++ b/grammar/Makefile.am
@@ -12,8 +12,11 @@ libgrammar_la_SOURCES = \
parserif.h \
grammar.h
libgrammar_la_CPPFLAGS = $(RSRT_CFLAGS) $(LIBLOGGING_STDLOG_CFLAGS)
-#libgrammar_la_LIBADD = $(CURL_LIBS) $(RSRT_LIBS) $(SOL_LIBS)
-libgrammar_la_LIBADD = $(CURL_LIBS)
+libgrammar_la_LIBADD =
+if ENABLE_LIBCURL
+libgrammar_la_CPPFLAGS += $(CURL_CFLAGS)
+libgrammar_la_LIBADD += $(CURL_LIBS)
+endif
#testdriver_SOURCES = testdriver.c libgrammar.la
#testdriver_CPPFLAGS = $(RSRT_CFLAGS)
--- a/plugins/omelasticsearch/Makefile.am
+++ b/plugins/omelasticsearch/Makefile.am
@@ -1,7 +1,7 @@
pkglib_LTLIBRARIES = omelasticsearch.la
omelasticsearch_la_SOURCES = omelasticsearch.c
-omelasticsearch_la_CPPFLAGS = $(RSRT_CFLAGS) $(PTHREADS_CFLAGS)
+omelasticsearch_la_CPPFLAGS = $(RSRT_CFLAGS) $(PTHREADS_CFLAGS) $(CURL_CFLAGS)
omelasticsearch_la_LDFLAGS = -module -avoid-version
omelasticsearch_la_LIBADD = $(CURL_LIBS) $(LIBM)
--- a/grammar/rainerscript.c
+++ b/grammar/rainerscript.c
@@ -36,7 +36,11 @@
#include <sys/types.h>
#include <libestr.h>
#include <time.h>
+
+#ifdef HAVE_LIBCURL
#include <curl/curl.h>
+#endif
+
#include "rsyslog.h"
#include "rainerscript.h"
#include "conf.h"

@ -1,13 +0,0 @@
https://github.com/rsyslog/rsyslog/issues/2612
--- a/configure.ac
+++ b/configure.ac
@@ -254,7 +254,7 @@ AC_LINK_IFELSE([AC_LANG_PROGRAM(, return __builtin_expect(main != 0, 1))],
# speeds up processig.
# note that when automic operations are enabled but not available, they
# will silently NOT be used!
-AC_ARG_ENABLE(regexp,
+AC_ARG_ENABLE(atomic_operations,
[AS_HELP_STRING([--enable-atomic-operations],[Enable atomic operation support @<:@default=yes@:>@])],
[case "${enableval}" in
yes) enable_atomic_operations="yes" ;;

@ -1,37 +0,0 @@
# Uncomment the following directive if you have re-enabled
# "/var/log/syslog" in "/etc/rsyslog.d/50-default.conf"
#/var/log/syslog
#{
# rotate 7
# daily
# missingok
# notifempty
# delaycompress
# compress
# postrotate
# test -r /run/rsyslogd.pid && kill -HUP $(cat /run/rsyslogd.pid) &>/dev/null
# endscript
#}
/var/log/auth.log
/var/log/cron.log
/var/log/daemon.log
/var/log/kern.log
/var/log/lpr.log
/var/log/mail.log
/var/log/news.log
/var/log/user.log
/var/log/debug.log
/var/log/messages
{
rotate 4
weekly
missingok
notifempty
compress
delaycompress
sharedscripts
postrotate
test -r /run/rsyslogd.pid && kill -HUP $(cat /run/rsyslogd.pid) &>/dev/null
endscript
}

@ -1,5 +1,5 @@
#!/sbin/openrc-run
# Copyright 1999-2015 Gentoo Foundation
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
RSYSLOG_CONFIGFILE=${RSYSLOG_CONFIGFILE:-"/etc/rsyslog.conf"}

@ -1,451 +0,0 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI="6"
inherit autotools eutils linux-info systemd
DESCRIPTION="An enhanced multi-threaded syslogd with database support and more"
HOMEPAGE="https://www.rsyslog.com/"
BRANCH="8-stable"
if [[ ${PV} == "9999" ]]; then
EGIT_REPO_URI="https://github.com/rsyslog/${PN}.git"
DOC_REPO_URI="https://github.com/rsyslog/${PN}-doc.git"
inherit git-r3
else
MY_PV=${PV%_rc*}
MY_FILENAME="${PN}-${PV}.tar.gz"
MY_FILENAME_DOCS="${PN}-docs-${PV}.tar.gz"
S="${WORKDIR}/${PN}-${MY_PV}"
# Upstream URL schema:
# RC: http://www.rsyslog.com/files/download/rsyslog/rc/rsyslog-8.18.0.tar.gz
# http://www.rsyslog.com/files/download/rsyslog/rc2/rsyslog-8.18.0.tar.gz
# Release: http://www.rsyslog.com/files/download/rsyslog/rsyslog-8.18.0.tar.gz
MY_URL_PREFIX=
if [[ ${PV} = *_rc* ]]; then
_tmp_last_index=$(($(get_last_version_component_index ${PV})+1))
_tmp_suffix=$(get_version_component_range ${_tmp_last_index} ${PV})
if [[ ${_tmp_suffix} = *rc* ]]; then
MY_URL_PREFIX="${_tmp_suffix}/"
fi
# Cleaning up temporary variables
unset _tmp_last_index
unset _tmp_suffix
else
KEYWORDS="hppa"
fi
SRC_URI="
https://www.rsyslog.com/files/download/${PN}/${MY_URL_PREFIX}${PN}-${MY_PV}.tar.gz -> ${MY_FILENAME}
doc? ( https://www.rsyslog.com/files/download/${PN}/${MY_URL_PREFIX}${PN}-doc-${MY_PV}.tar.gz -> ${MY_FILENAME_DOCS} )
"
PATCHES=( "${FILESDIR}"/8-stable/${PN}-8.27.0-fix-mmnormalize-tests.patch )
fi
LICENSE="GPL-3 LGPL-3 Apache-2.0"
SLOT="0"
IUSE="dbi debug doc elasticsearch +gcrypt grok jemalloc kafka kerberos libressl mdblookup mongodb mysql normalize omhttpfs"
IUSE+=" omudpspoof postgres rabbitmq redis relp rfc3195 rfc5424hmac snmp ssl systemd test usertools +uuid zeromq"
RDEPEND="
>=dev-libs/libfastjson-0.99.3:=
>=dev-libs/libestr-0.1.9
>=dev-libs/liblogging-1.0.1:=[stdlog]
>=sys-libs/zlib-1.2.5
dbi? ( >=dev-db/libdbi-0.8.3 )
elasticsearch? ( >=net-misc/curl-7.35.0 )
gcrypt? ( >=dev-libs/libgcrypt-1.5.3:= )
grok? ( >=dev-libs/grok-0.9.2 )
jemalloc? ( >=dev-libs/jemalloc-3.3.1:= )
kafka? ( >=dev-libs/librdkafka-0.9.0.99:= )
kerberos? ( virtual/krb5 )
mdblookup? ( dev-libs/libmaxminddb:= )
mongodb? ( >=dev-libs/libmongo-client-0.1.4 )
mysql? ( virtual/libmysqlclient:= )
normalize? (
>=dev-libs/libee-0.4.0
>=dev-libs/liblognorm-2.0.3:=
)
omhttpfs? ( >=net-misc/curl-7.35.0 )
omudpspoof? ( >=net-libs/libnet-1.1.6 )
postgres? ( >=dev-db/postgresql-8.4.20:= )
rabbitmq? ( >=net-libs/rabbitmq-c-0.3.0:= )
redis? ( >=dev-libs/hiredis-0.11.0:= )
relp? ( >=dev-libs/librelp-1.2.14:= )
rfc3195? ( >=dev-libs/liblogging-1.0.1:=[rfc3195] )
rfc5424hmac? (
!libressl? ( >=dev-libs/openssl-0.9.8y:0= )
libressl? ( dev-libs/libressl:= )
)
snmp? ( >=net-analyzer/net-snmp-5.7.2 )
ssl? ( >=net-libs/gnutls-2.12.23:0= )
systemd? ( >=sys-apps/systemd-208 )
uuid? ( sys-apps/util-linux:0= )
zeromq? (
>=net-libs/zeromq-4.1.1:=
>=net-libs/czmq-3.0.0
)"
DEPEND="${RDEPEND}
>=sys-devel/autoconf-archive-2015.02.24
virtual/pkgconfig
test? ( sys-libs/libfaketime )"
if [[ ${PV} == "9999" ]]; then
DEPEND+=" doc? ( >=dev-python/sphinx-1.1.3-r7 )"
DEPEND+=" >=sys-devel/flex-2.5.39-r1"
DEPEND+=" >=sys-devel/bison-2.4.3"
DEPEND+=" >=dev-python/docutils-0.12"
fi
CONFIG_CHECK="~INOTIFY_USER"
WARNING_INOTIFY_USER="CONFIG_INOTIFY_USER isn't set. Imfile module on this system will only support polling mode!"
src_unpack() {
if [[ ${PV} == "9999" ]]; then
git-r3_fetch
git-r3_checkout
else
unpack ${P}.tar.gz
fi
if use doc; then
if [[ ${PV} == "9999" ]]; then
local _EGIT_BRANCH=
if [[ -n "${EGIT_BRANCH}" ]]; then
# Cannot use rsyslog commits/branches for documentation repository
_EGIT_BRANCH=${EGIT_BRANCH}
unset EGIT_BRANCH
fi
git-r3_fetch "${DOC_REPO_URI}"
git-r3_checkout "${DOC_REPO_URI}" "${S}"/docs
if [[ -n "${_EGIT_BRANCH}" ]]; then
# Restore previous EGIT_BRANCH information
EGIT_BRANCH=${_EGIT_BRANCH}
fi
else
cd "${S}" || die "Cannot change dir into '${S}'"
mkdir docs || die "Failed to create docs directory"
cd docs || die "Failed to change dir into '${S}/docs'"
unpack ${MY_FILENAME_DOCS}
fi
fi
}
src_prepare() {
default
eautoreconf
}
src_configure() {
# Maintainer notes:
# * Guardtime support is missing because libgt isn't yet available
# in portage.
# * Hadoop's HDFS file system output module is currently not
# supported in Gentoo because nobody is able to test it
# (JAVA dependency).
# * dev-libs/hiredis doesn't provide pkg-config (see #504614,
# upstream PR 129 and 136) so we need to export HIREDIS_*
# variables because rsyslog's build system depends on pkg-config.
if use redis; then
export HIREDIS_LIBS="-L${EPREFIX}/usr/$(get_libdir) -lhiredis"
export HIREDIS_CFLAGS="-I${EPREFIX}/usr/include"
fi
local myeconfargs=(
--disable-debug-symbols
--disable-generate-man-pages
--without-valgrind-testbench
$(use_enable test testbench)
# Input Plugins without depedencies
--enable-imdiag
--enable-imfile
--enable-impstats
--enable-imptcp
# Message Modificiation Plugins without depedencies
--enable-mmanon
--enable-mmaudit
--enable-mmcount
--enable-mmfields
--enable-mmjsonparse
--enable-mmpstrucdata
--enable-mmrm1stspace
--enable-mmsequence
--enable-mmutf8fix
# Output Modification Plugins without dependencies
--enable-mail
--enable-omprog
--enable-omruleset
--enable-omstdout
--enable-omuxsock
# Misc
--enable-pmaixforwardedfrom
--enable-pmciscoios
--enable-pmcisconames
--enable-pmlastmsg
--enable-pmsnare
# DB
$(use_enable dbi libdbi)
$(use_enable mongodb ommongodb)
$(use_enable mysql)
$(use_enable postgres pgsql)
$(use_enable redis omhiredis)
# Debug
$(use_enable debug)
$(use_enable debug diagtools)
$(use_enable debug memcheck)
$(use_enable debug rtinst)
$(use_enable debug valgrind)
# Misc
$(use_enable elasticsearch)
$(use_enable gcrypt libgcrypt)
$(use_enable jemalloc)
$(use_enable kafka imkafka)
$(use_enable kafka omkafka)
$(use_enable kerberos gssapi-krb5)
$(use_enable normalize mmnormalize)
$(use_enable mdblookup mmdblookup)
$(use_enable grok mmgrok)
$(use_enable omhttpfs)
$(use_enable omudpspoof)
$(use_enable rabbitmq omrabbitmq)
$(use_enable relp)
$(use_enable rfc3195)
$(use_enable rfc5424hmac mmrfc5424addhmac)
$(use_enable snmp)
$(use_enable snmp mmsnmptrapd)
$(use_enable ssl gnutls)
$(use_enable systemd imjournal)
$(use_enable systemd omjournal)
$(use_enable usertools)
$(use_enable uuid)
$(use_enable zeromq imczmq)
$(use_enable zeromq imzmq3)
$(use_enable zeromq omczmq)
$(use_enable zeromq omzmq3)
--with-systemdsystemunitdir="$(systemd_get_systemunitdir)"
)
econf "${myeconfargs[@]}"
}
src_compile() {
default
if use doc && [[ "${PV}" == "9999" ]]; then
einfo "Building documentation ..."
local doc_dir="${S}/docs"
cd "${doc_dir}" || die "Cannot chdir into \"${doc_dir}\"!"
sphinx-build -b html source build || die "Building documentation failed!"
fi
}
src_test() {
local _has_increased_ulimit=
# Sometimes tests aren't executable (i.e. when added via patch)
einfo "Adjusting permissions of test scripts ..."
find "${S}"/tests -type f -name '*.sh' \! -perm -111 -exec chmod a+x '{}' \; || \
die "Failed to adjust test scripts permission"
if ulimit -n 3072; then
_has_increased_ulimit="true"
fi
if ! emake --jobs 1 check; then
eerror "Test suite failed! :("
if [[ -z "${_has_increased_ulimit}" ]]; then
eerror "Probably because open file limit couldn't be set to 3072."
fi
if has userpriv ${FEATURES}; then
eerror "Please try to reproduce the test suite failure with FEATURES=-userpriv " \
"before you submit a bug report."
fi
fi
}
src_install() {
local DOCS=(
AUTHORS
ChangeLog
"${FILESDIR}"/${BRANCH}/README.gentoo
)
use doc && local HTML_DOCS=( "${S}/docs/build/." )
default
newconfd "${FILESDIR}/${BRANCH}/${PN}.confd-r1" ${PN}
newinitd "${FILESDIR}/${BRANCH}/${PN}.initd-r1" ${PN}
keepdir /var/empty/dev
keepdir /var/spool/${PN}
keepdir /etc/ssl/${PN}
keepdir /etc/${PN}.d
insinto /etc
newins "${FILESDIR}/${BRANCH}/${PN}.conf" ${PN}.conf
insinto /etc/rsyslog.d/
doins "${FILESDIR}/${BRANCH}/50-default.conf"
insinto /etc/logrotate.d/
newins "${FILESDIR}/${BRANCH}/${PN}.logrotate" ${PN}
if use mysql; then
insinto /usr/share/doc/${PF}/scripts/mysql
doins plugins/ommysql/createDB.sql
fi
if use postgres; then
insinto /usr/share/doc/${PF}/scripts/pgsql
doins plugins/ompgsql/createDB.sql
fi
prune_libtool_files --modules
}
pkg_postinst() {
local advertise_readme=0
if [[ -z "${REPLACING_VERSIONS}" ]]; then
# This is a new installation
advertise_readme=1
if use mysql || use postgres; then
echo
elog "Sample SQL scripts for MySQL & PostgreSQL have been installed to:"
elog " /usr/share/doc/${PF}/scripts"
fi
if use ssl; then
echo
elog "To create a default CA and certificates for your server and clients, run:"
elog " emerge --config =${PF}"
elog "on your logging server. You can run it several times,"
elog "once for each logging client. The client certificates will be signed"
elog "using the CA certificate generated during the first run."
fi
fi
if [[ ${advertise_readme} -gt 0 ]]; then
# We need to show the README file location
echo ""
elog "Please read"
elog ""
elog " ${EPREFIX}/usr/share/doc/${PF}/README.gentoo*"
elog ""
elog "for more details."
fi
}
pkg_config() {
if ! use ssl ; then
einfo "There is nothing to configure for rsyslog unless you"
einfo "used USE=ssl to build it."
return 0
fi
# Make sure the certificates directory exists
local CERTDIR="${EROOT}/etc/ssl/${PN}"
if [[ ! -d "${CERTDIR}" ]]; then
mkdir "${CERTDIR}" || die
fi
einfo "Your certificates will be stored in ${CERTDIR}"
# Create a default CA if needed
if [[ ! -f "${CERTDIR}/${PN}_ca.cert.pem" ]]; then
einfo "No CA key and certificate found in ${CERTDIR}, creating them for you..."
certtool --generate-privkey \
--outfile "${CERTDIR}/${PN}_ca.privkey.pem" &>/dev/null
chmod 400 "${CERTDIR}/${PN}_ca.privkey.pem"
cat > "${T}/${PF}.$$" <<- _EOF
cn = Portage automated CA
ca
cert_signing_key
expiration_days = 3650
_EOF
certtool --generate-self-signed \
--load-privkey "${CERTDIR}/${PN}_ca.privkey.pem" \
--outfile "${CERTDIR}/${PN}_ca.cert.pem" \
--template "${T}/${PF}.$$" &>/dev/null
chmod 400 "${CERTDIR}/${PN}_ca.privkey.pem"
# Create the server certificate
echo
einfon "Please type the Common Name of the SERVER you wish to create a certificate for: "
read -r CN
einfo "Creating private key and certificate for server ${CN}..."
certtool --generate-privkey \
--outfile "${CERTDIR}/${PN}_${CN}.key.pem" &>/dev/null
chmod 400 "${CERTDIR}/${PN}_${CN}.key.pem"
cat > "${T}/${PF}.$$" <<- _EOF
cn = ${CN}
tls_www_server
dns_name = ${CN}
expiration_days = 3650
_EOF
certtool --generate-certificate \
--outfile "${CERTDIR}/${PN}_${CN}.cert.pem" \
--load-privkey "${CERTDIR}/${PN}_${CN}.key.pem" \
--load-ca-certificate "${CERTDIR}/${PN}_ca.cert.pem" \
--load-ca-privkey "${CERTDIR}/${PN}_ca.privkey.pem" \
--template "${T}/${PF}.$$" &>/dev/null
chmod 400 "${CERTDIR}/${PN}_${CN}.cert.pem"
else
einfo "Found existing ${CERTDIR}/${PN}_ca.cert.pem, skipping CA and SERVER creation."
fi
# Create a client certificate
echo
einfon "Please type the Common Name of the CLIENT you wish to create a certificate for: "
read -r CN
einfo "Creating private key and certificate for client ${CN}..."
certtool --generate-privkey \
--outfile "${CERTDIR}/${PN}_${CN}.key.pem" &>/dev/null
chmod 400 "${CERTDIR}/${PN}_${CN}.key.pem"
cat > "${T}/${PF}.$$" <<- _EOF
cn = ${CN}
tls_www_client
dns_name = ${CN}
expiration_days = 3650
_EOF
certtool --generate-certificate \
--outfile "${CERTDIR}/${PN}_${CN}.cert.pem" \
--load-privkey "${CERTDIR}/${PN}_${CN}.key.pem" \
--load-ca-certificate "${CERTDIR}/${PN}_ca.cert.pem" \
--load-ca-privkey "${CERTDIR}/${PN}_ca.privkey.pem" \
--template "${T}/${PF}.$$" &>/dev/null
chmod 400 "${CERTDIR}/${PN}_${CN}.cert.pem"
rm -f "${T}/${PF}.$$"
echo
einfo "Here is the documentation on how to encrypt your log traffic:"
einfo " http://www.rsyslog.com/doc/rsyslog_tls.html"
}

@ -1,459 +0,0 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI="6"
PYTHON_COMPAT=( python{2_7,3_4,3_5,3_6} )
inherit autotools eutils linux-info python-any-r1 systemd
DESCRIPTION="An enhanced multi-threaded syslogd with database support and more"
HOMEPAGE="https://www.rsyslog.com/"
BRANCH="8-stable"
if [[ ${PV} == "9999" ]]; then
EGIT_REPO_URI="https://github.com/rsyslog/${PN}.git"
DOC_REPO_URI="https://github.com/rsyslog/${PN}-doc.git"
inherit git-r3
else
MY_PV=${PV%_rc*}
MY_FILENAME="${PN}-${PV}.tar.gz"
MY_FILENAME_DOCS="${PN}-docs-${PV}.tar.gz"
S="${WORKDIR}/${PN}-${MY_PV}"
# Upstream URL schema:
# RC: http://www.rsyslog.com/files/download/rsyslog/rc/rsyslog-8.18.0.tar.gz
# http://www.rsyslog.com/files/download/rsyslog/rc2/rsyslog-8.18.0.tar.gz
# Release: http://www.rsyslog.com/files/download/rsyslog/rsyslog-8.18.0.tar.gz
MY_URL_PREFIX=
if [[ ${PV} = *_rc* ]]; then
_tmp_last_index=$(($(get_last_version_component_index ${PV})+1))
_tmp_suffix=$(get_version_component_range ${_tmp_last_index} ${PV})
if [[ ${_tmp_suffix} = *rc* ]]; then
MY_URL_PREFIX="${_tmp_suffix}/"
fi
# Cleaning up temporary variables
unset _tmp_last_index
unset _tmp_suffix
else
KEYWORDS="amd64 arm ~arm64 ~hppa x86"
fi
SRC_URI="
https://www.rsyslog.com/files/download/${PN}/${MY_URL_PREFIX}${PN}-${MY_PV}.tar.gz -> ${MY_FILENAME}
doc? ( https://www.rsyslog.com/files/download/${PN}/${MY_URL_PREFIX}${PN}-doc-${MY_PV}.tar.gz -> ${MY_FILENAME_DOCS} )
"
PATCHES=( "${FILESDIR}"/8-stable/${PN}-8.32.0-fix-building-without-curl-r3.patch )
fi
LICENSE="GPL-3 LGPL-3 Apache-2.0"
SLOT="0"
IUSE="curl dbi debug doc elasticsearch +gcrypt grok jemalloc kafka kerberos libressl mdblookup mongodb mysql normalize omhttpfs"
IUSE+=" omudpspoof postgres rabbitmq redis relp rfc3195 rfc5424hmac snmp ssl systemd test usertools +uuid zeromq"
RDEPEND="
>=dev-libs/libfastjson-0.99.8:=
>=dev-libs/libestr-0.1.9
>=dev-libs/liblogging-1.0.1:=[stdlog]
>=sys-libs/zlib-1.2.5
curl? ( >=net-misc/curl-7.35.0 )
dbi? ( >=dev-db/libdbi-0.8.3 )
elasticsearch? ( >=net-misc/curl-7.35.0 )
gcrypt? ( >=dev-libs/libgcrypt-1.5.3:= )
grok? ( >=dev-libs/grok-0.9.2 )
jemalloc? ( >=dev-libs/jemalloc-3.3.1:= )
kafka? ( >=dev-libs/librdkafka-0.9.0.99:= )
kerberos? ( virtual/krb5 )
mdblookup? ( dev-libs/libmaxminddb:= )
mongodb? ( >=dev-libs/mongo-c-driver-1.1.10:= )
mysql? ( virtual/libmysqlclient:= )
normalize? (
>=dev-libs/libee-0.4.0
>=dev-libs/liblognorm-2.0.3:=
)
omhttpfs? ( >=net-misc/curl-7.35.0 )
omudpspoof? ( >=net-libs/libnet-1.1.6 )
postgres? ( >=dev-db/postgresql-8.4.20:= )
rabbitmq? ( >=net-libs/rabbitmq-c-0.3.0:= )
redis? ( >=dev-libs/hiredis-0.11.0:= )
relp? ( >=dev-libs/librelp-1.2.14:= )
rfc3195? ( >=dev-libs/liblogging-1.0.1:=[rfc3195] )
rfc5424hmac? (
!libressl? ( >=dev-libs/openssl-0.9.8y:0= )
libressl? ( dev-libs/libressl:= )
)
snmp? ( >=net-analyzer/net-snmp-5.7.2 )
ssl? ( >=net-libs/gnutls-2.12.23:0= )
systemd? ( >=sys-apps/systemd-234 )
uuid? ( sys-apps/util-linux:0= )
zeromq? (
>=net-libs/czmq-3.0.2
)"
DEPEND="${RDEPEND}
>=sys-devel/autoconf-archive-2015.02.24
virtual/pkgconfig
test? (
jemalloc? ( <sys-libs/libfaketime-0.9.7 )
!jemalloc? ( sys-libs/libfaketime )
${PYTHON_DEPS}
)"
if [[ ${PV} == "9999" ]]; then
DEPEND+=" doc? ( >=dev-python/sphinx-1.1.3-r7 )"
DEPEND+=" >=sys-devel/flex-2.5.39-r1"
DEPEND+=" >=sys-devel/bison-2.4.3"
DEPEND+=" >=dev-python/docutils-0.12"
fi
CONFIG_CHECK="~INOTIFY_USER"
WARNING_INOTIFY_USER="CONFIG_INOTIFY_USER isn't set. Imfile module on this system will only support polling mode!"
pkg_setup() {
use test && python-any-r1_pkg_setup
}
src_unpack() {
if [[ ${PV} == "9999" ]]; then
git-r3_fetch
git-r3_checkout
else
unpack ${P}.tar.gz
fi
if use doc; then
if [[ ${PV} == "9999" ]]; then
local _EGIT_BRANCH=
if [[ -n "${EGIT_BRANCH}" ]]; then
# Cannot use rsyslog commits/branches for documentation repository
_EGIT_BRANCH=${EGIT_BRANCH}
unset EGIT_BRANCH
fi
git-r3_fetch "${DOC_REPO_URI}"
git-r3_checkout "${DOC_REPO_URI}" "${S}"/docs
if [[ -n "${_EGIT_BRANCH}" ]]; then
# Restore previous EGIT_BRANCH information
EGIT_BRANCH=${_EGIT_BRANCH}
fi
else
cd "${S}" || die "Cannot change dir into '${S}'"
mkdir docs || die "Failed to create docs directory"
cd docs || die "Failed to change dir into '${S}/docs'"
unpack ${MY_FILENAME_DOCS}
fi
fi
}
src_prepare() {
default
eautoreconf
}
src_configure() {
# Maintainer notes:
# * Guardtime support is missing because libgt isn't yet available
# in portage.
# * Hadoop's HDFS file system output module is currently not
# supported in Gentoo because nobody is able to test it
# (JAVA dependency).
# * dev-libs/hiredis doesn't provide pkg-config (see #504614,
# upstream PR 129 and 136) so we need to export HIREDIS_*
# variables because rsyslog's build system depends on pkg-config.
if use redis; then
export HIREDIS_LIBS="-L${EPREFIX}/usr/$(get_libdir) -lhiredis"
export HIREDIS_CFLAGS="-I${EPREFIX}/usr/include"
fi
local myeconfargs=(
--disable-debug-symbols
--disable-generate-man-pages
--without-valgrind-testbench
$(use_enable test testbench)
$(use_enable curl libcurl)
# Input Plugins without depedencies
--enable-imdiag
--enable-imfile
--enable-impstats
--enable-imptcp
# Message Modificiation Plugins without depedencies
--enable-mmanon
--enable-mmaudit
--enable-mmcount
--enable-mmfields
--enable-mmjsonparse
--enable-mmpstrucdata
--enable-mmrm1stspace
--enable-mmsequence
--enable-mmutf8fix
# Output Modification Plugins without dependencies
--enable-mail
--enable-omprog
--enable-omruleset
--enable-omstdout
--enable-omuxsock
# Misc
--enable-pmaixforwardedfrom
--enable-pmciscoios
--enable-pmcisconames
--enable-pmlastmsg
--enable-pmsnare
# DB
$(use_enable dbi libdbi)
$(use_enable mongodb ommongodb)
$(use_enable mysql)
$(use_enable postgres pgsql)
$(use_enable redis omhiredis)
# Debug
$(use_enable debug)
$(use_enable debug diagtools)
$(use_enable debug memcheck)
$(use_enable debug rtinst)
$(use_enable debug valgrind)
# Misc
$(use_enable elasticsearch)
$(use_enable gcrypt libgcrypt)
$(use_enable jemalloc)
$(use_enable kafka imkafka)
$(use_enable kafka omkafka)
$(use_enable kerberos gssapi-krb5)
$(use_enable normalize mmnormalize)
$(use_enable mdblookup mmdblookup)
$(use_enable grok mmgrok)
$(use_enable omhttpfs)
$(use_enable omudpspoof)
$(use_enable rabbitmq omrabbitmq)
$(use_enable relp)
$(use_enable rfc3195)
$(use_enable rfc5424hmac mmrfc5424addhmac)
$(use_enable snmp)
$(use_enable snmp mmsnmptrapd)
$(use_enable ssl gnutls)
$(use_enable systemd imjournal)
$(use_enable systemd omjournal)
$(use_enable usertools)
$(use_enable uuid)
$(use_enable zeromq imczmq)
$(use_enable zeromq omczmq)
--with-systemdsystemunitdir="$(systemd_get_systemunitdir)"
)
econf "${myeconfargs[@]}"
}
src_compile() {
default
if use doc && [[ "${PV}" == "9999" ]]; then
einfo "Building documentation ..."
local doc_dir="${S}/docs"
cd "${doc_dir}" || die "Cannot chdir into \"${doc_dir}\"!"
sphinx-build -b html source build || die "Building documentation failed!"
fi
}
src_test() {
local _has_increased_ulimit=
# Sometimes tests aren't executable (i.e. when added via patch)
einfo "Adjusting permissions of test scripts ..."
find "${S}"/tests -type f -name '*.sh' \! -perm -111 -exec chmod a+x '{}' \; || \
die "Failed to adjust test scripts permission"
if ulimit -n 3072; then
_has_increased_ulimit="true"
fi
if ! emake --jobs 1 check; then
eerror "Test suite failed! :("
if [[ -z "${_has_increased_ulimit}" ]]; then
eerror "Probably because open file limit couldn't be set to 3072."
fi
if has userpriv ${FEATURES}; then
eerror "Please try to reproduce the test suite failure with FEATURES=-userpriv " \
"before you submit a bug report."
fi
fi
}
src_install() {
local DOCS=(
AUTHORS
ChangeLog
"${FILESDIR}"/${BRANCH}/README.gentoo
)
use doc && local HTML_DOCS=( "${S}/docs/build/." )
default
newconfd "${FILESDIR}/${BRANCH}/${PN}.confd-r1" ${PN}
newinitd "${FILESDIR}/${BRANCH}/${PN}.initd-r1" ${PN}
keepdir /var/empty/dev
keepdir /var/spool/${PN}
keepdir /etc/ssl/${PN}
keepdir /etc/${PN}.d
insinto /etc
newins "${FILESDIR}/${BRANCH}/${PN}.conf" ${PN}.conf
insinto /etc/rsyslog.d/
newins "${FILESDIR}/${BRANCH}/50-default-r1.conf" 50-default.conf
insinto /etc/logrotate.d/
newins "${FILESDIR}/${BRANCH}/${PN}.logrotate" ${PN}
if use mysql; then
insinto /usr/share/doc/${PF}/scripts/mysql
doins plugins/ommysql/createDB.sql
fi
if use postgres; then
insinto /usr/share/doc/${PF}/scripts/pgsql
doins plugins/ompgsql/createDB.sql
fi
prune_libtool_files --modules
}
pkg_postinst() {
local advertise_readme=0
if [[ -z "${REPLACING_VERSIONS}" ]]; then
# This is a new installation
advertise_readme=1
if use mysql || use postgres; then
echo
elog "Sample SQL scripts for MySQL & PostgreSQL have been installed to:"
elog " /usr/share/doc/${PF}/scripts"
fi
if use ssl; then
echo
elog "To create a default CA and certificates for your server and clients, run:"
elog " emerge --config =${PF}"
elog "on your logging server. You can run it several times,"
elog "once for each logging client. The client certificates will be signed"
elog "using the CA certificate generated during the first run."
fi
fi
if [[ ${advertise_readme} -gt 0 ]]; then
# We need to show the README file location
echo ""
elog "Please read"
elog ""
elog " ${EPREFIX}/usr/share/doc/${PF}/README.gentoo*"
elog ""
elog "for more details."
fi
}
pkg_config() {
if ! use ssl ; then
einfo "There is nothing to configure for rsyslog unless you"
einfo "used USE=ssl to build it."
return 0
fi
# Make sure the certificates directory exists
local CERTDIR="${EROOT}/etc/ssl/${PN}"
if [[ ! -d "${CERTDIR}" ]]; then
mkdir "${CERTDIR}" || die
fi
einfo "Your certificates will be stored in ${CERTDIR}"
# Create a default CA if needed
if [[ ! -f "${CERTDIR}/${PN}_ca.cert.pem" ]]; then
einfo "No CA key and certificate found in ${CERTDIR}, creating them for you..."
certtool --generate-privkey \
--outfile "${CERTDIR}/${PN}_ca.privkey.pem" &>/dev/null
chmod 400 "${CERTDIR}/${PN}_ca.privkey.pem"
cat > "${T}/${PF}.$$" <<- _EOF
cn = Portage automated CA
ca
cert_signing_key
expiration_days = 3650
_EOF
certtool --generate-self-signed \
--load-privkey "${CERTDIR}/${PN}_ca.privkey.pem" \
--outfile "${CERTDIR}/${PN}_ca.cert.pem" \
--template "${T}/${PF}.$$" &>/dev/null
chmod 400 "${CERTDIR}/${PN}_ca.privkey.pem"
# Create the server certificate
echo
einfon "Please type the Common Name of the SERVER you wish to create a certificate for: "
read -r CN
einfo "Creating private key and certificate for server ${CN}..."
certtool --generate-privkey \
--outfile "${CERTDIR}/${PN}_${CN}.key.pem" &>/dev/null
chmod 400 "${CERTDIR}/${PN}_${CN}.key.pem"
cat > "${T}/${PF}.$$" <<- _EOF
cn = ${CN}
tls_www_server
dns_name = ${CN}
expiration_days = 3650
_EOF
certtool --generate-certificate \
--outfile "${CERTDIR}/${PN}_${CN}.cert.pem" \
--load-privkey "${CERTDIR}/${PN}_${CN}.key.pem" \
--load-ca-certificate "${CERTDIR}/${PN}_ca.cert.pem" \
--load-ca-privkey "${CERTDIR}/${PN}_ca.privkey.pem" \
--template "${T}/${PF}.$$" &>/dev/null
chmod 400 "${CERTDIR}/${PN}_${CN}.cert.pem"
else
einfo "Found existing ${CERTDIR}/${PN}_ca.cert.pem, skipping CA and SERVER creation."
fi
# Create a client certificate
echo
einfon "Please type the Common Name of the CLIENT you wish to create a certificate for: "
read -r CN
einfo "Creating private key and certificate for client ${CN}..."
certtool --generate-privkey \
--outfile "${CERTDIR}/${PN}_${CN}.key.pem" &>/dev/null
chmod 400 "${CERTDIR}/${PN}_${CN}.key.pem"
cat > "${T}/${PF}.$$" <<- _EOF
cn = ${CN}
tls_www_client
dns_name = ${CN}
expiration_days = 3650
_EOF
certtool --generate-certificate \
--outfile "${CERTDIR}/${PN}_${CN}.cert.pem" \
--load-privkey "${CERTDIR}/${PN}_${CN}.key.pem" \
--load-ca-certificate "${CERTDIR}/${PN}_ca.cert.pem" \
--load-ca-privkey "${CERTDIR}/${PN}_ca.privkey.pem" \
--template "${T}/${PF}.$$" &>/dev/null
chmod 400 "${CERTDIR}/${PN}_${CN}.cert.pem"
rm -f "${T}/${PF}.$$"
echo
einfo "Here is the documentation on how to encrypt your log traffic:"
einfo " http://www.rsyslog.com/doc/rsyslog_tls.html"
}

@ -1,457 +0,0 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI="6"
PYTHON_COMPAT=( python{2_7,3_4,3_5,3_6} )
inherit autotools eutils linux-info python-any-r1 systemd
DESCRIPTION="An enhanced multi-threaded syslogd with database support and more"
HOMEPAGE="https://www.rsyslog.com/"
BRANCH="8-stable"
if [[ ${PV} == "9999" ]]; then
EGIT_REPO_URI="https://github.com/rsyslog/${PN}.git"
DOC_REPO_URI="https://github.com/rsyslog/${PN}-doc.git"
inherit git-r3
else
MY_PV=${PV%_rc*}
MY_FILENAME="${PN}-${PV}.tar.gz"
MY_FILENAME_DOCS="${PN}-docs-${PV}.tar.gz"
S="${WORKDIR}/${PN}-${MY_PV}"
# Upstream URL schema:
# RC: http://www.rsyslog.com/files/download/rsyslog/rc/rsyslog-8.18.0.tar.gz
# http://www.rsyslog.com/files/download/rsyslog/rc2/rsyslog-8.18.0.tar.gz
# Release: http://www.rsyslog.com/files/download/rsyslog/rsyslog-8.18.0.tar.gz
MY_URL_PREFIX=
if [[ ${PV} = *_rc* ]]; then
_tmp_last_index=$(($(get_last_version_component_index ${PV})+1))
_tmp_suffix=$(get_version_component_range ${_tmp_last_index} ${PV})
if [[ ${_tmp_suffix} = *rc* ]]; then
MY_URL_PREFIX="${_tmp_suffix}/"
fi
# Cleaning up temporary variables
unset _tmp_last_index
unset _tmp_suffix
else
KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~x86"
fi
SRC_URI="
https://www.rsyslog.com/files/download/${PN}/${MY_URL_PREFIX}${PN}-${MY_PV}.tar.gz -> ${MY_FILENAME}
doc? ( https://www.rsyslog.com/files/download/${PN}/${MY_URL_PREFIX}${PN}-doc-${MY_PV}.tar.gz -> ${MY_FILENAME_DOCS} )
"
fi
LICENSE="GPL-3 LGPL-3 Apache-2.0"
SLOT="0"
IUSE="curl dbi debug doc elasticsearch +gcrypt grok jemalloc kafka kerberos libressl mdblookup mongodb mysql normalize omhttpfs"
IUSE+=" omudpspoof postgres rabbitmq redis relp rfc3195 rfc5424hmac snmp ssl systemd test usertools +uuid zeromq"
RDEPEND="
>=dev-libs/libfastjson-0.99.8:=
>=dev-libs/libestr-0.1.9
>=dev-libs/liblogging-1.0.1:=[stdlog]
>=sys-libs/zlib-1.2.5
curl? ( >=net-misc/curl-7.35.0 )
dbi? ( >=dev-db/libdbi-0.8.3 )
elasticsearch? ( >=net-misc/curl-7.35.0 )
gcrypt? ( >=dev-libs/libgcrypt-1.5.3:= )
grok? ( >=dev-libs/grok-0.9.2 )
jemalloc? ( >=dev-libs/jemalloc-3.3.1:= )
kafka? ( >=dev-libs/librdkafka-0.9.0.99:= )
kerberos? ( virtual/krb5 )
mdblookup? ( dev-libs/libmaxminddb:= )
mongodb? ( >=dev-libs/mongo-c-driver-1.1.10:= )
mysql? ( virtual/libmysqlclient:= )
normalize? (
>=dev-libs/libee-0.4.0
>=dev-libs/liblognorm-2.0.3:=
)
omhttpfs? ( >=net-misc/curl-7.35.0 )
omudpspoof? ( >=net-libs/libnet-1.1.6 )
postgres? ( >=dev-db/postgresql-8.4.20:= )
rabbitmq? ( >=net-libs/rabbitmq-c-0.3.0:= )
redis? ( >=dev-libs/hiredis-0.11.0:= )
relp? ( >=dev-libs/librelp-1.2.14:= )
rfc3195? ( >=dev-libs/liblogging-1.0.1:=[rfc3195] )
rfc5424hmac? (
!libressl? ( >=dev-libs/openssl-0.9.8y:0= )
libressl? ( dev-libs/libressl:= )
)
snmp? ( >=net-analyzer/net-snmp-5.7.2 )
ssl? ( >=net-libs/gnutls-2.12.23:0= )
systemd? ( >=sys-apps/systemd-234 )
uuid? ( sys-apps/util-linux:0= )
zeromq? (
>=net-libs/czmq-3.0.2
)"
DEPEND="${RDEPEND}
>=sys-devel/autoconf-archive-2015.02.24
virtual/pkgconfig
test? (
jemalloc? ( <sys-libs/libfaketime-0.9.7 )
!jemalloc? ( sys-libs/libfaketime )
${PYTHON_DEPS}
)"
if [[ ${PV} == "9999" ]]; then
DEPEND+=" doc? ( >=dev-python/sphinx-1.1.3-r7 )"
DEPEND+=" >=sys-devel/flex-2.5.39-r1"
DEPEND+=" >=sys-devel/bison-2.4.3"
DEPEND+=" >=dev-python/docutils-0.12"
fi
CONFIG_CHECK="~INOTIFY_USER"
WARNING_INOTIFY_USER="CONFIG_INOTIFY_USER isn't set. Imfile module on this system will only support polling mode!"
pkg_setup() {
use test && python-any-r1_pkg_setup
}
src_unpack() {
if [[ ${PV} == "9999" ]]; then
git-r3_fetch
git-r3_checkout
else
unpack ${P}.tar.gz
fi
if use doc; then
if [[ ${PV} == "9999" ]]; then
local _EGIT_BRANCH=
if [[ -n "${EGIT_BRANCH}" ]]; then
# Cannot use rsyslog commits/branches for documentation repository
_EGIT_BRANCH=${EGIT_BRANCH}
unset EGIT_BRANCH
fi
git-r3_fetch "${DOC_REPO_URI}"
git-r3_checkout "${DOC_REPO_URI}" "${S}"/docs
if [[ -n "${_EGIT_BRANCH}" ]]; then
# Restore previous EGIT_BRANCH information
EGIT_BRANCH=${_EGIT_BRANCH}
fi
else
cd "${S}" || die "Cannot change dir into '${S}'"
mkdir docs || die "Failed to create docs directory"
cd docs || die "Failed to change dir into '${S}/docs'"
unpack ${MY_FILENAME_DOCS}
fi
fi
}
src_prepare() {
default
eautoreconf
}
src_configure() {
# Maintainer notes:
# * Guardtime support is missing because libgt isn't yet available
# in portage.
# * Hadoop's HDFS file system output module is currently not
# supported in Gentoo because nobody is able to test it
# (JAVA dependency).
# * dev-libs/hiredis doesn't provide pkg-config (see #504614,
# upstream PR 129 and 136) so we need to export HIREDIS_*
# variables because rsyslog's build system depends on pkg-config.
if use redis; then
export HIREDIS_LIBS="-L${EPREFIX}/usr/$(get_libdir) -lhiredis"
export HIREDIS_CFLAGS="-I${EPREFIX}/usr/include"
fi
local myeconfargs=(
--disable-debug-symbols
--disable-generate-man-pages
--without-valgrind-testbench
$(use_enable test testbench)
$(use_enable curl libcurl)
# Input Plugins without depedencies
--enable-imdiag
--enable-imfile
--enable-impstats
--enable-imptcp
# Message Modificiation Plugins without depedencies
--enable-mmanon
--enable-mmaudit
--enable-mmcount
--enable-mmfields
--enable-mmjsonparse
--enable-mmpstrucdata
--enable-mmrm1stspace
--enable-mmsequence
--enable-mmutf8fix
# Output Modification Plugins without dependencies
--enable-mail
--enable-omprog
--enable-omruleset
--enable-omstdout
--enable-omuxsock
# Misc
--enable-pmaixforwardedfrom
--enable-pmciscoios
--enable-pmcisconames
--enable-pmlastmsg
--enable-pmsnare
# DB
$(use_enable dbi libdbi)
$(use_enable mongodb ommongodb)
$(use_enable mysql)
$(use_enable postgres pgsql)
$(use_enable redis omhiredis)
# Debug
$(use_enable debug)
$(use_enable debug diagtools)
$(use_enable debug memcheck)
$(use_enable debug rtinst)
$(use_enable debug valgrind)
# Misc
$(use_enable elasticsearch)
$(use_enable gcrypt libgcrypt)
$(use_enable jemalloc)
$(use_enable kafka imkafka)
$(use_enable kafka omkafka)
$(use_enable kerberos gssapi-krb5)
$(use_enable normalize mmnormalize)
$(use_enable mdblookup mmdblookup)
$(use_enable grok mmgrok)
$(use_enable omhttpfs)
$(use_enable omudpspoof)
$(use_enable rabbitmq omrabbitmq)
$(use_enable relp)
$(use_enable rfc3195)
$(use_enable rfc5424hmac mmrfc5424addhmac)
$(use_enable snmp)
$(use_enable snmp mmsnmptrapd)
$(use_enable ssl gnutls)
$(use_enable systemd imjournal)
$(use_enable systemd omjournal)
$(use_enable usertools)
$(use_enable uuid)
$(use_enable zeromq imczmq)
$(use_enable zeromq omczmq)
--with-systemdsystemunitdir="$(systemd_get_systemunitdir)"
)
econf "${myeconfargs[@]}"
}
src_compile() {
default
if use doc && [[ "${PV}" == "9999" ]]; then
einfo "Building documentation ..."
local doc_dir="${S}/docs"
cd "${doc_dir}" || die "Cannot chdir into \"${doc_dir}\"!"
sphinx-build -b html source build || die "Building documentation failed!"
fi
}
src_test() {
local _has_increased_ulimit=
# Sometimes tests aren't executable (i.e. when added via patch)
einfo "Adjusting permissions of test scripts ..."
find "${S}"/tests -type f -name '*.sh' \! -perm -111 -exec chmod a+x '{}' \; || \
die "Failed to adjust test scripts permission"
if ulimit -n 3072; then
_has_increased_ulimit="true"
fi
if ! emake --jobs 1 check; then
eerror "Test suite failed! :("
if [[ -z "${_has_increased_ulimit}" ]]; then
eerror "Probably because open file limit couldn't be set to 3072."
fi
if has userpriv ${FEATURES}; then
eerror "Please try to reproduce the test suite failure with FEATURES=-userpriv " \
"before you submit a bug report."
fi
fi
}
src_install() {
local DOCS=(
AUTHORS
ChangeLog
"${FILESDIR}"/${BRANCH}/README.gentoo
)
use doc && local HTML_DOCS=( "${S}/docs/build/." )
default
newconfd "${FILESDIR}/${BRANCH}/${PN}.confd-r1" ${PN}
newinitd "${FILESDIR}/${BRANCH}/${PN}.initd-r1" ${PN}
keepdir /var/empty/dev
keepdir /var/spool/${PN}
keepdir /etc/ssl/${PN}
keepdir /etc/${PN}.d
insinto /etc
newins "${FILESDIR}/${BRANCH}/${PN}.conf" ${PN}.conf
insinto /etc/rsyslog.d/
newins "${FILESDIR}/${BRANCH}/50-default-r1.conf" 50-default.conf
insinto /etc/logrotate.d/
newins "${FILESDIR}/${BRANCH}/${PN}.logrotate" ${PN}
if use mysql; then
insinto /usr/share/doc/${PF}/scripts/mysql
doins plugins/ommysql/createDB.sql
fi
if use postgres; then
insinto /usr/share/doc/${PF}/scripts/pgsql
doins plugins/ompgsql/createDB.sql
fi
prune_libtool_files --modules
}
pkg_postinst() {
local advertise_readme=0
if [[ -z "${REPLACING_VERSIONS}" ]]; then
# This is a new installation
advertise_readme=1
if use mysql || use postgres; then
echo
elog "Sample SQL scripts for MySQL & PostgreSQL have been installed to:"
elog " /usr/share/doc/${PF}/scripts"
fi
if use ssl; then
echo
elog "To create a default CA and certificates for your server and clients, run:"
elog " emerge --config =${PF}"
elog "on your logging server. You can run it several times,"
elog "once for each logging client. The client certificates will be signed"
elog "using the CA certificate generated during the first run."
fi
fi
if [[ ${advertise_readme} -gt 0 ]]; then
# We need to show the README file location
echo ""
elog "Please read"
elog ""
elog " ${EPREFIX}/usr/share/doc/${PF}/README.gentoo*"
elog ""
elog "for more details."
fi
}
pkg_config() {
if ! use ssl ; then
einfo "There is nothing to configure for rsyslog unless you"
einfo "used USE=ssl to build it."
return 0
fi
# Make sure the certificates directory exists
local CERTDIR="${EROOT}/etc/ssl/${PN}"
if [[ ! -d "${CERTDIR}" ]]; then
mkdir "${CERTDIR}" || die
fi
einfo "Your certificates will be stored in ${CERTDIR}"
# Create a default CA if needed
if [[ ! -f "${CERTDIR}/${PN}_ca.cert.pem" ]]; then
einfo "No CA key and certificate found in ${CERTDIR}, creating them for you..."
certtool --generate-privkey \
--outfile "${CERTDIR}/${PN}_ca.privkey.pem" &>/dev/null
chmod 400 "${CERTDIR}/${PN}_ca.privkey.pem"
cat > "${T}/${PF}.$$" <<- _EOF
cn = Portage automated CA
ca
cert_signing_key
expiration_days = 3650
_EOF
certtool --generate-self-signed \
--load-privkey "${CERTDIR}/${PN}_ca.privkey.pem" \
--outfile "${CERTDIR}/${PN}_ca.cert.pem" \
--template "${T}/${PF}.$$" &>/dev/null
chmod 400 "${CERTDIR}/${PN}_ca.privkey.pem"
# Create the server certificate
echo
einfon "Please type the Common Name of the SERVER you wish to create a certificate for: "
read -r CN
einfo "Creating private key and certificate for server ${CN}..."
certtool --generate-privkey \
--outfile "${CERTDIR}/${PN}_${CN}.key.pem" &>/dev/null
chmod 400 "${CERTDIR}/${PN}_${CN}.key.pem"
cat > "${T}/${PF}.$$" <<- _EOF
cn = ${CN}
tls_www_server
dns_name = ${CN}
expiration_days = 3650
_EOF
certtool --generate-certificate \
--outfile "${CERTDIR}/${PN}_${CN}.cert.pem" \
--load-privkey "${CERTDIR}/${PN}_${CN}.key.pem" \
--load-ca-certificate "${CERTDIR}/${PN}_ca.cert.pem" \
--load-ca-privkey "${CERTDIR}/${PN}_ca.privkey.pem" \
--template "${T}/${PF}.$$" &>/dev/null
chmod 400 "${CERTDIR}/${PN}_${CN}.cert.pem"
else
einfo "Found existing ${CERTDIR}/${PN}_ca.cert.pem, skipping CA and SERVER creation."
fi
# Create a client certificate
echo
einfon "Please type the Common Name of the CLIENT you wish to create a certificate for: "
read -r CN
einfo "Creating private key and certificate for client ${CN}..."
certtool --generate-privkey \
--outfile "${CERTDIR}/${PN}_${CN}.key.pem" &>/dev/null
chmod 400 "${CERTDIR}/${PN}_${CN}.key.pem"
cat > "${T}/${PF}.$$" <<- _EOF
cn = ${CN}
tls_www_client
dns_name = ${CN}
expiration_days = 3650
_EOF
certtool --generate-certificate \
--outfile "${CERTDIR}/${PN}_${CN}.cert.pem" \
--load-privkey "${CERTDIR}/${PN}_${CN}.key.pem" \
--load-ca-certificate "${CERTDIR}/${PN}_ca.cert.pem" \
--load-ca-privkey "${CERTDIR}/${PN}_ca.privkey.pem" \
--template "${T}/${PF}.$$" &>/dev/null
chmod 400 "${CERTDIR}/${PN}_${CN}.cert.pem"
rm -f "${T}/${PF}.$$"
echo
einfo "Here is the documentation on how to encrypt your log traffic:"
einfo " http://www.rsyslog.com/doc/rsyslog_tls.html"
}

@ -1,464 +0,0 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI="6"
PYTHON_COMPAT=( python{2_7,3_4,3_5,3_6} )
inherit autotools eutils linux-info python-any-r1 systemd
DESCRIPTION="An enhanced multi-threaded syslogd with database support and more"
HOMEPAGE="https://www.rsyslog.com/"
BRANCH="8-stable"
if [[ ${PV} == "9999" ]]; then
EGIT_REPO_URI="https://github.com/rsyslog/${PN}.git"
DOC_REPO_URI="https://github.com/rsyslog/${PN}-doc.git"
inherit git-r3
else
MY_PV=${PV%_rc*}
MY_FILENAME="${PN}-${PV}.tar.gz"
MY_FILENAME_DOCS="${PN}-docs-${PV}.tar.gz"
S="${WORKDIR}/${PN}-${MY_PV}"
# Upstream URL schema:
# RC: https://www.rsyslog.com/files/download/rsyslog/rc/rsyslog-8.18.0.tar.gz
# https://www.rsyslog.com/files/download/rsyslog/rc2/rsyslog-8.18.0.tar.gz
# Release: https://www.rsyslog.com/files/download/rsyslog/rsyslog-8.18.0.tar.gz
MY_URL_PREFIX=
if [[ ${PV} = *_rc* ]]; then
_tmp_last_index=$(($(get_last_version_component_index ${PV})+1))
_tmp_suffix=$(get_version_component_range ${_tmp_last_index} ${PV})
if [[ ${_tmp_suffix} = *rc* ]]; then
MY_URL_PREFIX="${_tmp_suffix}/"
fi
# Cleaning up temporary variables
unset _tmp_last_index
unset _tmp_suffix
else
KEYWORDS="amd64 arm ~arm64 ~hppa x86"
fi
SRC_URI="
https://www.rsyslog.com/files/download/${PN}/${MY_URL_PREFIX}${PN}-${MY_PV}.tar.gz -> ${MY_FILENAME}
doc? ( https://www.rsyslog.com/files/download/${PN}/${MY_URL_PREFIX}${PN}-doc-${MY_PV}.tar.gz -> ${MY_FILENAME_DOCS} )
"
PATCHES=( "${FILESDIR}"/${BRANCH}/${PN}-8.34.0-fix-issue2612.patch )
fi
LICENSE="GPL-3 LGPL-3 Apache-2.0"
SLOT="0"
IUSE="curl dbi debug doc elasticsearch +gcrypt grok jemalloc kafka kerberos kubernetes libressl mdblookup mongodb mysql"
IUSE+=" normalize omhttpfs omudpspoof postgres rabbitmq redis relp rfc3195 rfc5424hmac snmp ssl systemd test usertools +uuid zeromq"
RDEPEND="
>=dev-libs/libfastjson-0.99.8:=
>=dev-libs/libestr-0.1.9
>=dev-libs/liblogging-1.0.1:=[stdlog]
>=sys-libs/zlib-1.2.5
curl? ( >=net-misc/curl-7.35.0 )
dbi? ( >=dev-db/libdbi-0.8.3 )
elasticsearch? ( >=net-misc/curl-7.35.0 )
gcrypt? ( >=dev-libs/libgcrypt-1.5.3:= )
grok? ( >=dev-libs/grok-0.9.2 )
jemalloc? ( >=dev-libs/jemalloc-3.3.1:= )
kafka? ( >=dev-libs/librdkafka-0.9.0.99:= )
kerberos? ( virtual/krb5 )
kubernetes? ( >=net-misc/curl-7.35.0 )
mdblookup? ( dev-libs/libmaxminddb:= )
mongodb? ( >=dev-libs/mongo-c-driver-1.1.10:= )
mysql? ( virtual/libmysqlclient:= )
normalize? (
>=dev-libs/libee-0.4.0
>=dev-libs/liblognorm-2.0.3:=
)
omhttpfs? ( >=net-misc/curl-7.35.0 )
omudpspoof? ( >=net-libs/libnet-1.1.6 )
postgres? ( >=dev-db/postgresql-8.4.20:= )
rabbitmq? ( >=net-libs/rabbitmq-c-0.3.0:= )
redis? ( >=dev-libs/hiredis-0.11.0:= )
relp? ( >=dev-libs/librelp-1.2.14:= )
rfc3195? ( >=dev-libs/liblogging-1.0.1:=[rfc3195] )
rfc5424hmac? (
!libressl? ( >=dev-libs/openssl-0.9.8y:0= )
libressl? ( dev-libs/libressl:= )
)
snmp? ( >=net-analyzer/net-snmp-5.7.2 )
ssl? ( >=net-libs/gnutls-2.12.23:0= )
systemd? ( >=sys-apps/systemd-234 )
uuid? ( sys-apps/util-linux:0= )
zeromq? (
>=net-libs/czmq-3.0.2
)"
DEPEND="${RDEPEND}
>=sys-devel/autoconf-archive-2015.02.24
virtual/pkgconfig
test? (
jemalloc? ( <sys-libs/libfaketime-0.9.7 )
!jemalloc? ( sys-libs/libfaketime )
${PYTHON_DEPS}
)"
REQUIRED_USE="kubernetes? ( normalize )"
if [[ ${PV} == "9999" ]]; then
DEPEND+=" doc? ( >=dev-python/sphinx-1.1.3-r7 )"
DEPEND+=" >=sys-devel/flex-2.5.39-r1"
DEPEND+=" >=sys-devel/bison-2.4.3"
DEPEND+=" >=dev-python/docutils-0.12"
fi
CONFIG_CHECK="~INOTIFY_USER"
WARNING_INOTIFY_USER="CONFIG_INOTIFY_USER isn't set. Imfile module on this system will only support polling mode!"
pkg_setup() {
use test && python-any-r1_pkg_setup
}
src_unpack() {
if [[ ${PV} == "9999" ]]; then
git-r3_fetch
git-r3_checkout
else
unpack ${P}.tar.gz
fi
if use doc; then
if [[ ${PV} == "9999" ]]; then
local _EGIT_BRANCH=
if [[ -n "${EGIT_BRANCH}" ]]; then
# Cannot use rsyslog commits/branches for documentation repository
_EGIT_BRANCH=${EGIT_BRANCH}
unset EGIT_BRANCH
fi
git-r3_fetch "${DOC_REPO_URI}"
git-r3_checkout "${DOC_REPO_URI}" "${S}"/docs
if [[ -n "${_EGIT_BRANCH}" ]]; then
# Restore previous EGIT_BRANCH information
EGIT_BRANCH=${_EGIT_BRANCH}
fi
else
cd "${S}" || die "Cannot change dir into '${S}'"
mkdir docs || die "Failed to create docs directory"
cd docs || die "Failed to change dir into '${S}/docs'"
unpack ${MY_FILENAME_DOCS}
fi
fi
}
src_prepare() {
default
eautoreconf
}
src_configure() {
# Maintainer notes:
# * Guardtime support is missing because libgt isn't yet available
# in portage.
# * Hadoop's HDFS file system output module is currently not
# supported in Gentoo because nobody is able to test it
# (JAVA dependency).
# * dev-libs/hiredis doesn't provide pkg-config (see #504614,
# upstream PR 129 and 136) so we need to export HIREDIS_*
# variables because rsyslog's build system depends on pkg-config.
if use redis; then
export HIREDIS_LIBS="-L${EPREFIX}/usr/$(get_libdir) -lhiredis"
export HIREDIS_CFLAGS="-I${EPREFIX}/usr/include"
fi
local myeconfargs=(
--disable-debug-symbols
--disable-generate-man-pages
--without-valgrind-testbench
$(use_enable test testbench)
$(use_enable curl libcurl)
# Input Plugins without depedencies
--enable-imdiag
--enable-imfile
--enable-impstats
--enable-imptcp
# Message Modificiation Plugins without depedencies
--enable-mmanon
--enable-mmaudit
--enable-mmcount
--enable-mmfields
--enable-mmjsonparse
--enable-mmpstrucdata
--enable-mmrm1stspace
--enable-mmsequence
--enable-mmutf8fix
# Output Modification Plugins without dependencies
--enable-mail
--enable-omprog
--enable-omruleset
--enable-omstdout
--enable-omuxsock
# Misc
--enable-pmaixforwardedfrom
--enable-pmciscoios
--enable-pmcisconames
--enable-pmlastmsg
--enable-pmsnare
# DB
$(use_enable dbi libdbi)
$(use_enable mongodb ommongodb)
$(use_enable mysql)
$(use_enable postgres pgsql)
$(use_enable redis omhiredis)
# Debug
$(use_enable debug)
$(use_enable debug diagtools)
$(use_enable debug memcheck)
$(use_enable debug rtinst)
$(use_enable debug valgrind)
# Misc
$(use_enable curl fmhttp)
$(use_enable elasticsearch)
$(use_enable gcrypt libgcrypt)
$(use_enable jemalloc)
$(use_enable kafka imkafka)
$(use_enable kafka omkafka)
$(use_enable kerberos gssapi-krb5)
$(use_enable kubernetes mmkubernetes)
$(use_enable normalize mmnormalize)
$(use_enable mdblookup mmdblookup)
$(use_enable grok mmgrok)
$(use_enable omhttpfs)
$(use_enable omudpspoof)
$(use_enable rabbitmq omrabbitmq)
$(use_enable relp)
$(use_enable rfc3195)
$(use_enable rfc5424hmac mmrfc5424addhmac)
$(use_enable snmp)
$(use_enable snmp mmsnmptrapd)
$(use_enable ssl gnutls)
$(use_enable systemd imjournal)
$(use_enable systemd omjournal)
$(use_enable usertools)
$(use_enable uuid)
$(use_enable zeromq imczmq)
$(use_enable zeromq omczmq)
--with-systemdsystemunitdir="$(systemd_get_systemunitdir)"
)
econf "${myeconfargs[@]}"
}
src_compile() {
default
if use doc && [[ "${PV}" == "9999" ]]; then
einfo "Building documentation ..."
local doc_dir="${S}/docs"
cd "${doc_dir}" || die "Cannot chdir into \"${doc_dir}\"!"
sphinx-build -b html source build || die "Building documentation failed!"
fi
}
src_test() {
local _has_increased_ulimit=
# Sometimes tests aren't executable (i.e. when added via patch)
einfo "Adjusting permissions of test scripts ..."
find "${S}"/tests -type f -name '*.sh' \! -perm -111 -exec chmod a+x '{}' \; || \
die "Failed to adjust test scripts permission"
if ulimit -n 3072; then
_has_increased_ulimit="true"
fi
if ! emake --jobs 1 check; then
eerror "Test suite failed! :("
if [[ -z "${_has_increased_ulimit}" ]]; then
eerror "Probably because open file limit couldn't be set to 3072."
fi
if has userpriv ${FEATURES}; then
eerror "Please try to reproduce the test suite failure with FEATURES=-userpriv " \
"before you submit a bug report."
fi
fi
}
src_install() {
local DOCS=(
AUTHORS
ChangeLog
"${FILESDIR}"/${BRANCH}/README.gentoo
)
use doc && local HTML_DOCS=( "${S}/docs/build/." )
default
newconfd "${FILESDIR}/${BRANCH}/${PN}.confd-r1" ${PN}
newinitd "${FILESDIR}/${BRANCH}/${PN}.initd-r1" ${PN}
keepdir /var/empty/dev
keepdir /var/spool/${PN}
keepdir /etc/ssl/${PN}
keepdir /etc/${PN}.d
insinto /etc
newins "${FILESDIR}/${BRANCH}/${PN}.conf" ${PN}.conf
insinto /etc/rsyslog.d/
newins "${FILESDIR}/${BRANCH}/50-default-r1.conf" 50-default.conf
insinto /etc/logrotate.d/
newins "${FILESDIR}/${BRANCH}/${PN}.logrotate" ${PN}
if use mysql; then
insinto /usr/share/doc/${PF}/scripts/mysql
doins plugins/ommysql/createDB.sql
fi
if use postgres; then
insinto /usr/share/doc/${PF}/scripts/pgsql
doins plugins/ompgsql/createDB.sql
fi
prune_libtool_files --modules
}
pkg_postinst() {
local advertise_readme=0
if [[ -z "${REPLACING_VERSIONS}" ]]; then
# This is a new installation
advertise_readme=1
if use mysql || use postgres; then
echo
elog "Sample SQL scripts for MySQL & PostgreSQL have been installed to:"
elog " /usr/share/doc/${PF}/scripts"
fi
if use ssl; then
echo
elog "To create a default CA and certificates for your server and clients, run:"
elog " emerge --config =${PF}"
elog "on your logging server. You can run it several times,"
elog "once for each logging client. The client certificates will be signed"
elog "using the CA certificate generated during the first run."
fi
fi
if [[ ${advertise_readme} -gt 0 ]]; then
# We need to show the README file location
echo ""
elog "Please read"
elog ""
elog " ${EPREFIX}/usr/share/doc/${PF}/README.gentoo*"
elog ""
elog "for more details."
fi
}
pkg_config() {
if ! use ssl ; then
einfo "There is nothing to configure for rsyslog unless you"
einfo "used USE=ssl to build it."
return 0
fi
# Make sure the certificates directory exists
local CERTDIR="${EROOT}/etc/ssl/${PN}"
if [[ ! -d "${CERTDIR}" ]]; then
mkdir "${CERTDIR}" || die
fi
einfo "Your certificates will be stored in ${CERTDIR}"
# Create a default CA if needed
if [[ ! -f "${CERTDIR}/${PN}_ca.cert.pem" ]]; then
einfo "No CA key and certificate found in ${CERTDIR}, creating them for you..."
certtool --generate-privkey \
--outfile "${CERTDIR}/${PN}_ca.privkey.pem" &>/dev/null
chmod 400 "${CERTDIR}/${PN}_ca.privkey.pem"
cat > "${T}/${PF}.$$" <<- _EOF
cn = Portage automated CA
ca
cert_signing_key
expiration_days = 3650
_EOF
certtool --generate-self-signed \
--load-privkey "${CERTDIR}/${PN}_ca.privkey.pem" \
--outfile "${CERTDIR}/${PN}_ca.cert.pem" \
--template "${T}/${PF}.$$" &>/dev/null
chmod 400 "${CERTDIR}/${PN}_ca.privkey.pem"
# Create the server certificate
echo
einfon "Please type the Common Name of the SERVER you wish to create a certificate for: "
read -r CN
einfo "Creating private key and certificate for server ${CN}..."
certtool --generate-privkey \
--outfile "${CERTDIR}/${PN}_${CN}.key.pem" &>/dev/null
chmod 400 "${CERTDIR}/${PN}_${CN}.key.pem"
cat > "${T}/${PF}.$$" <<- _EOF
cn = ${CN}
tls_www_server
dns_name = ${CN}
expiration_days = 3650
_EOF
certtool --generate-certificate \
--outfile "${CERTDIR}/${PN}_${CN}.cert.pem" \
--load-privkey "${CERTDIR}/${PN}_${CN}.key.pem" \
--load-ca-certificate "${CERTDIR}/${PN}_ca.cert.pem" \
--load-ca-privkey "${CERTDIR}/${PN}_ca.privkey.pem" \
--template "${T}/${PF}.$$" &>/dev/null
chmod 400 "${CERTDIR}/${PN}_${CN}.cert.pem"
else
einfo "Found existing ${CERTDIR}/${PN}_ca.cert.pem, skipping CA and SERVER creation."
fi
# Create a client certificate
echo
einfon "Please type the Common Name of the CLIENT you wish to create a certificate for: "
read -r CN
einfo "Creating private key and certificate for client ${CN}..."
certtool --generate-privkey \
--outfile "${CERTDIR}/${PN}_${CN}.key.pem" &>/dev/null
chmod 400 "${CERTDIR}/${PN}_${CN}.key.pem"
cat > "${T}/${PF}.$$" <<- _EOF
cn = ${CN}
tls_www_client
dns_name = ${CN}
expiration_days = 3650
_EOF
certtool --generate-certificate \
--outfile "${CERTDIR}/${PN}_${CN}.cert.pem" \
--load-privkey "${CERTDIR}/${PN}_${CN}.key.pem" \
--load-ca-certificate "${CERTDIR}/${PN}_ca.cert.pem" \
--load-ca-privkey "${CERTDIR}/${PN}_ca.privkey.pem" \
--template "${T}/${PF}.$$" &>/dev/null
chmod 400 "${CERTDIR}/${PN}_${CN}.cert.pem"
rm -f "${T}/${PF}.$$"
echo
einfo "Here is the documentation on how to encrypt your log traffic:"
einfo " https://www.rsyslog.com/doc/rsyslog_tls.html"
}

@ -2,15 +2,13 @@
# Distributed under the terms of the GNU General Public License v2
EAPI="6"
PYTHON_COMPAT=( python{2_7,3_4,3_5,3_6} )
PYTHON_COMPAT=( python{2_7,3_4,3_5,3_6,3_7} )
inherit autotools eutils linux-info python-any-r1 systemd
DESCRIPTION="An enhanced multi-threaded syslogd with database support and more"
HOMEPAGE="https://www.rsyslog.com/"
BRANCH="8-stable"
if [[ ${PV} == "9999" ]]; then
EGIT_REPO_URI="https://github.com/rsyslog/${PN}.git"
@ -18,39 +16,16 @@ if [[ ${PV} == "9999" ]]; then
inherit git-r3
else
MY_PV=${PV%_rc*}
MY_FILENAME="${PN}-${PV}.tar.gz"
MY_FILENAME_DOCS="${PN}-docs-${PV}.tar.gz"
S="${WORKDIR}/${PN}-${MY_PV}"
# Upstream URL schema:
# RC: https://www.rsyslog.com/files/download/rsyslog/rc/rsyslog-8.18.0.tar.gz
# https://www.rsyslog.com/files/download/rsyslog/rc2/rsyslog-8.18.0.tar.gz
# Release: https://www.rsyslog.com/files/download/rsyslog/rsyslog-8.18.0.tar.gz
MY_URL_PREFIX=
if [[ ${PV} = *_rc* ]]; then
_tmp_last_index=$(($(get_last_version_component_index ${PV})+1))
_tmp_suffix=$(get_version_component_range ${_tmp_last_index} ${PV})
if [[ ${_tmp_suffix} = *rc* ]]; then
MY_URL_PREFIX="${_tmp_suffix}/"
fi
# Cleaning up temporary variables
unset _tmp_last_index
unset _tmp_suffix
else
KEYWORDS="amd64 arm ~arm64 ~hppa x86"
fi
KEYWORDS="amd64 arm ~arm64 hppa x86"
SRC_URI="
https://www.rsyslog.com/files/download/${PN}/${MY_URL_PREFIX}${PN}-${MY_PV}.tar.gz -> ${MY_FILENAME}
doc? ( https://www.rsyslog.com/files/download/${PN}/${MY_URL_PREFIX}${PN}-doc-${MY_PV}.tar.gz -> ${MY_FILENAME_DOCS} )
https://www.rsyslog.com/files/download/${PN}/${P}.tar.gz
doc? ( https://www.rsyslog.com/files/download/${PN}/${PN}-doc-${PV}.tar.gz )
"
PATCHES=(
"${FILESDIR}"/${BRANCH}/${PN}-8.35.0-fix-issue2719.patch
"${FILESDIR}"/${BRANCH}/${PN}-8.35.0-fix-issue2726.patch
"${FILESDIR}"/${PN}-8.35.0-fix-issue2719.patch
"${FILESDIR}"/${PN}-8.35.0-fix-issue2726.patch
)
fi
@ -151,7 +126,7 @@ src_unpack() {
cd "${S}" || die "Cannot change dir into '${S}'"
mkdir docs || die "Failed to create docs directory"
cd docs || die "Failed to change dir into '${S}/docs'"
unpack ${MY_FILENAME_DOCS}
unpack ${PN}-doc-${PV}.tar.gz
fi
fi
}
@ -183,7 +158,6 @@ src_configure() {
--disable-generate-man-pages
--without-valgrind-testbench
$(use_enable test testbench)
$(use_enable curl libcurl)
# Input Plugins without depedencies
--enable-imdiag
--enable-imfile
@ -221,7 +195,6 @@ src_configure() {
$(use_enable debug)
$(use_enable debug diagtools)
$(use_enable debug memcheck)
$(use_enable debug rtinst)
$(use_enable debug valgrind)
# Misc
$(use_enable curl fmhttp)
@ -298,15 +271,15 @@ src_install() {
local DOCS=(
AUTHORS
ChangeLog
"${FILESDIR}"/${BRANCH}/README.gentoo
"${FILESDIR}"/README.gentoo
)
use doc && local HTML_DOCS=( "${S}/docs/build/." )
default
newconfd "${FILESDIR}/${BRANCH}/${PN}.confd-r1" ${PN}
newinitd "${FILESDIR}/${BRANCH}/${PN}.initd-r1" ${PN}
newconfd "${FILESDIR}/${PN}.confd-r1" ${PN}
newinitd "${FILESDIR}/${PN}.initd-r1" ${PN}
keepdir /var/empty/dev
keepdir /var/spool/${PN}
@ -314,13 +287,13 @@ src_install() {
keepdir /etc/${PN}.d
insinto /etc
newins "${FILESDIR}/${BRANCH}/${PN}.conf" ${PN}.conf
newins "${FILESDIR}/${PN}.conf" ${PN}.conf
insinto /etc/rsyslog.d/
newins "${FILESDIR}/${BRANCH}/50-default-r1.conf" 50-default.conf
newins "${FILESDIR}/50-default-r1.conf" 50-default.conf
insinto /etc/logrotate.d/
newins "${FILESDIR}/${BRANCH}/${PN}-r1.logrotate" ${PN}
newins "${FILESDIR}/${PN}-r1.logrotate" ${PN}
if use mysql; then
insinto /usr/share/doc/${PF}/scripts/mysql

@ -2,15 +2,13 @@
# Distributed under the terms of the GNU General Public License v2
EAPI="6"
PYTHON_COMPAT=( python{2_7,3_4,3_5,3_6} )
PYTHON_COMPAT=( python{2_7,3_4,3_5,3_6,3_7} )
inherit autotools eutils linux-info python-any-r1 systemd
DESCRIPTION="An enhanced multi-threaded syslogd with database support and more"
HOMEPAGE="https://www.rsyslog.com/"
BRANCH="8-stable"
if [[ ${PV} == "9999" ]]; then
EGIT_REPO_URI="https://github.com/rsyslog/${PN}.git"
@ -18,34 +16,11 @@ if [[ ${PV} == "9999" ]]; then
inherit git-r3
else
MY_PV=${PV%_rc*}
MY_FILENAME="${PN}-${PV}.tar.gz"
MY_FILENAME_DOCS="${PN}-docs-${PV}.tar.gz"
S="${WORKDIR}/${PN}-${MY_PV}"
# Upstream URL schema:
# RC: https://www.rsyslog.com/files/download/rsyslog/rc/rsyslog-8.18.0.tar.gz
# https://www.rsyslog.com/files/download/rsyslog/rc2/rsyslog-8.18.0.tar.gz
# Release: https://www.rsyslog.com/files/download/rsyslog/rsyslog-8.18.0.tar.gz
MY_URL_PREFIX=
if [[ ${PV} = *_rc* ]]; then
_tmp_last_index=$(($(get_last_version_component_index ${PV})+1))
_tmp_suffix=$(get_version_component_range ${_tmp_last_index} ${PV})
if [[ ${_tmp_suffix} = *rc* ]]; then
MY_URL_PREFIX="${_tmp_suffix}/"
fi
# Cleaning up temporary variables
unset _tmp_last_index
unset _tmp_suffix
else
KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~x86"
fi
KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~x86"
SRC_URI="
https://www.rsyslog.com/files/download/${PN}/${MY_URL_PREFIX}${PN}-${MY_PV}.tar.gz -> ${MY_FILENAME}
doc? ( https://www.rsyslog.com/files/download/${PN}/${MY_URL_PREFIX}${PN}-doc-${MY_PV}.tar.gz -> ${MY_FILENAME_DOCS} )
https://www.rsyslog.com/files/download/${PN}/${P}.tar.gz
doc? ( https://www.rsyslog.com/files/download/${PN}/${PN}-doc-${PV}.tar.gz )
"
PATCHES=()
@ -158,7 +133,7 @@ src_unpack() {
cd "${S}" || die "Cannot change dir into '${S}'"
mkdir docs || die "Failed to create docs directory"
cd docs || die "Failed to change dir into '${S}/docs'"
unpack ${MY_FILENAME_DOCS}
unpack ${PN}-doc-${PV}.tar.gz
fi
fi
}
@ -307,15 +282,15 @@ src_install() {
local DOCS=(
AUTHORS
ChangeLog
"${FILESDIR}"/${BRANCH}/README.gentoo
"${FILESDIR}"/README.gentoo
)
use doc && local HTML_DOCS=( "${S}/docs/build/." )
default
newconfd "${FILESDIR}/${BRANCH}/${PN}.confd-r1" ${PN}
newinitd "${FILESDIR}/${BRANCH}/${PN}.initd-r1" ${PN}
newconfd "${FILESDIR}/${PN}.confd-r1" ${PN}
newinitd "${FILESDIR}/${PN}.initd-r1" ${PN}
keepdir /var/empty/dev
keepdir /var/spool/${PN}
@ -323,13 +298,13 @@ src_install() {
keepdir /etc/${PN}.d
insinto /etc
newins "${FILESDIR}/${BRANCH}/${PN}.conf" ${PN}.conf
newins "${FILESDIR}/${PN}.conf" ${PN}.conf
insinto /etc/rsyslog.d/
newins "${FILESDIR}/${BRANCH}/50-default-r1.conf" 50-default.conf
newins "${FILESDIR}/50-default-r1.conf" 50-default.conf
insinto /etc/logrotate.d/
newins "${FILESDIR}/${BRANCH}/${PN}-r1.logrotate" ${PN}
newins "${FILESDIR}/${PN}-r1.logrotate" ${PN}
if use mysql; then
insinto /usr/share/doc/${PF}/scripts/mysql

@ -0,0 +1 @@
DIST spectre-meltdown-checker-0.37.tar.gz 40472 BLAKE2B 93d83605c2d410a176d944cbf7c83549cc70075dbd7ef1f90d4a9710d8fdafd0393c0ad6a9a46eba12f753a3b14d486ba093f9b7fb1dd6c08d17042a94f97b44 SHA512 f621e81a783e8e01caae25d76fae6ab7bd091990cd0a0f93de2e29e1964b6f0952c221c64e4e045f26231f800b0ba1b8152aac71a7348e8577ac6b9bd7e31cf2

@ -0,0 +1,15 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<maintainer type="person">
<email>lucianposton@pm.me</email>
<name>Lucian Poston</name>
</maintainer>
<maintainer type="project">
<email>proxy-maint@gentoo.org</email>
<name>Proxy Maintainers</name>
</maintainer>
<upstream>
<remote-id type="github">speed47/spectre-meltdown-checker</remote-id>
</upstream>
</pkgmetadata>

@ -0,0 +1,23 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=7
if [[ ${PV} == *9999 ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/speed47/spectre-meltdown-checker.git"
else
SRC_URI="https://github.com/speed47/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
KEYWORDS="~amd64 ~x86"
fi
DESCRIPTION="Spectre & Meltdown vulnerability/mitigation checker for Linux"
HOMEPAGE="https://github.com/speed47/spectre-meltdown-checker"
LICENSE="GPL-3+"
SLOT="0"
src_install() {
default
newbin spectre-meltdown-checker.sh spectre-meltdown-checker
}

@ -0,0 +1,23 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=7
if [[ ${PV} == *9999 ]]; then
inherit git-r3
EGIT_REPO_URI="https://github.com/speed47/spectre-meltdown-checker.git"
else
SRC_URI="https://github.com/speed47/${PN}/archive/v${PV}.tar.gz -> ${P}.tar.gz"
KEYWORDS="~amd64 ~x86"
fi
DESCRIPTION="Spectre & Meltdown vulnerability/mitigation checker for Linux"
HOMEPAGE="https://github.com/speed47/spectre-meltdown-checker"
LICENSE="GPL-3+"
SLOT="0"
src_install() {
default
newbin spectre-meltdown-checker.sh spectre-meltdown-checker
}

Binary file not shown.

@ -1,69 +0,0 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
inherit flag-o-matic qmake-utils toolchain-funcs
COMMIT="5023138d7c35c4667c938b853e5ea89737334e92"
DESCRIPTION="A better i7 (and now i3, i5) reporting tool for Linux"
HOMEPAGE="https://github.com/ajaiantilal/i7z"
SRC_URI="https://github.com/ajaiantilal/${PN}/archive/${COMMIT}.tar.gz -> ${P}.tar.gz"
SLOT="0"
LICENSE="GPL-2"
KEYWORDS="amd64 x86 ~amd64-linux ~x86-linux"
IUSE="qt5"
RDEPEND="
sys-libs/ncurses:0=
qt5? (
dev-qt/qtcore:5
dev-qt/qtgui:5
dev-qt/qtwidgets:5
)
"
DEPEND="${RDEPEND}"
PATCHES=(
"${FILESDIR}"/i7z-0.27.2-ncurses.patch
"${FILESDIR}"/qt5.patch
"${FILESDIR}"/gcc5.patch
# From Debian
"${FILESDIR}"/fix-insecure-tempfile.patch
"${FILESDIR}"/fix_cpuid_asm.patch
"${FILESDIR}"/hyphen-used-as-minus-sign.patch
"${FILESDIR}"/install-i7z_rw_registers.patch
"${FILESDIR}"/use_stdbool.patch
)
S="${WORKDIR}/${PN}-${COMMIT}"
src_configure() {
# The GUI segfaults with -O1. None of the documented flags make a
# difference. There may not be a specific flag for the culprit.
# Looks to work fine for me with -O2 (pacho - 20170530)
# filter-flags "-O*"
tc-export CC PKG_CONFIG
cd GUI || die
use qt5 && eqmake5 ${PN}_GUI.pro
}
src_compile() {
default
if use qt5; then
emake -C GUI clean
emake -C GUI
fi
}
src_install() {
emake DESTDIR="${ED}" docdir=/usr/share/doc/${PF} install
if use qt5; then
dosbin GUI/i7z_GUI
fi
}

Binary file not shown.

@ -1 +1,3 @@
DIST glep63-check-4.tar.gz 5898 BLAKE2B b28dd0843138bb54c81142959a28b121b043b7da4e3dc797b8ad3ebabfde6f850a11c40e94e3d20b9cf152b2138165733ba36754859081eb59bbbd5e99f2b98e SHA512 65a40ce097937df0517f86d1b32fd47e23d39abc6a49fa45dfa9075e7f7a163c2c2e25f6e39538a5e47c295bfdb2390bc4909e14a06b21f2bf14edf8cf43f199
DIST glep63-check-5.tar.gz 61234 BLAKE2B 15b2e38e00ec044c963f4aaea9be4bf0659441a94ba9958aa1e70ecd425cc9f3dada31ab194092abdf9953ca10d711aa0cdd615365a6e78761b07fb0739fadd5 SHA512 d79a2e2a92dc4f123fbfa73df501fb9a0829a879e0d3674e8d6a854b8a2b437698b77793d92c6862d646a58ef302638cb9e5d152f60e634c9ec06e804dea79b4
DIST glep63-check-6.tar.gz 61318 BLAKE2B 9310a70556deabf90003c154c326480e7a5fb58992bf79201100c21fbbeb17ebfdb560d861586d1c206a8d4ed3e64500a8eca4d99dacd072dce121736cdb2d3e SHA512 f0729683095222f60243923bcb7d9c1b984eb10cb0d8a0da2ec756b40a11c3f4f3de466fa533a66d4f645a2de09137a12a47eda5e80d7d5d562b0926a30b1a72

@ -0,0 +1,26 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
PYTHON_COMPAT=( python3_{4,5,6,7} pypy3 )
inherit distutils-r1
DESCRIPTION="GLEP 63 compliance checker for OpenPGP keys"
HOMEPAGE="https://github.com/mgorny/glep63-check/"
SRC_URI="https://github.com/mgorny/glep63-check/archive/v${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="BSD-2"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="test"
REQUIRED_USE="${PYTHON_REQUIRED_USE}"
RESTRICT="!test? ( test )"
RDEPEND="app-crypt/gnupg"
DEPEND="test? ( ${RDEPEND} )"
python_test() {
"${EPYTHON}" -m unittest -v || die "Tests fail with ${EPYTHON}"
}

@ -0,0 +1,30 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
PYTHON_COMPAT=( python3_{4,5,6,7} )
inherit distutils-r1
DESCRIPTION="GLEP 63 compliance checker for OpenPGP keys"
HOMEPAGE="https://github.com/mgorny/glep63-check/"
SRC_URI="https://github.com/mgorny/glep63-check/archive/v${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="BSD-2"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="test"
REQUIRED_USE="${PYTHON_REQUIRED_USE}"
RESTRICT="!test? ( test )"
RDEPEND="app-crypt/gnupg"
DEPEND="
test? (
${RDEPEND}
sys-libs/libfaketime
)"
python_test() {
"${EPYTHON}" -m unittest -v || die "Tests fail with ${EPYTHON}"
}

@ -1,5 +1,2 @@
DIST gentoo-release-test-sigs-20180706.tar.gz 1437 BLAKE2B 00fb0a491c84853068ea578e68e8ab0a57842f6098c14da7ec44faf20abb23deef480aca958a7e352b9c55a024681eabc0c9aaf400e5dcbf8873277a3a940e38 SHA512 2a7cc2c650693c0e1fdf7083d77bf975e05ece3ab1495ed03362d02e8411481c80a62a9f21b23861bdc602d74c656a618e9a39d2bdef7ccd253ea9f3e4c7531a
DIST gentoo-release.asc.20180323.gz 40546 BLAKE2B 7fed70d734a73368e4772cbca7810e8d61ad3b483e0e0c115072de9f96332b0c8c3c9f091b0ee1cdd056c775db1121deee77d6a629e0b99a4c67d485ccacdfe6 SHA512 31ffdf1e23ea6a36c5f4ab6bd49b9c0323b6b03627a9001589030b2b10e95459b959ee931762bcd43fb94b28eaba5d5ede290b1a41ce3ec0ad1b7b8b0f98d48a
DIST gentoo-release.asc.20180530.gz 47465 BLAKE2B de37e8e84570debd8b39003bc65ada276f730e8a792b8990c87f4ffd7bbefd2cf49e44b53d3554fc6ecc302da65c8fc480821fd6e9f11324d5ed08a5fac861ef SHA512 63fcb06ae84657cde66fa74bd2b499936906d7aef36c46d19439c72a8c0f199cdc273d7e25004c60b23c50684365192b2a304f26c2b173564a216316eb22f66a
DIST gentoo-release.asc.20180703.gz 46676 BLAKE2B 934db8c5896aa9fc268820c3349a60854e0a99586c84dbb16e92528b2fac7c043033f68f790bf737fa6835138bdf4dc7ae0df4d67ed96bd8664b16cd42db50a1 SHA512 85ceed12ca105a8dc9767c61b6ff391ed9d3ec2a116ed39b130aa75fa60998d0c2569677b783937bf4cae1cf91f472c9f16fb87abee051fa26f3c7b96bef0b27
DIST gentoo-release.asc.20180706.gz 44805 BLAKE2B 1ba26b90e564738a1282c5febe426628144ab70e526397b866f97214254c73bbb517cdaa48ba0e83ca75a7d88cd622375fda0f362c43d13b66720ffb682682d2 SHA512 ba48cb6d7e72c6a720df3ff2430a4b4dd261f947c23762cd0c1255a93391d10becfb491db1bb80b295edd1f8192580315d5c7be3670b8689ef702ed228b05894

@ -1,20 +0,0 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
DESCRIPTION="OpenPGP keys used for Gentoo releases (snapshots, stages)"
HOMEPAGE="https://www.gentoo.org/downloads/signatures/"
SRC_URI="https://dev.gentoo.org/~mgorny/dist/openpgp-keys/gentoo-release.asc.${PV}.gz"
LICENSE="public-domain"
SLOT="0"
KEYWORDS="alpha amd64 arm arm64 hppa ia64 m68k ~mips ppc ppc64 s390 sh sparc x86 ~amd64-fbsd ~x86-fbsd"
IUSE=""
S=${WORKDIR}
src_install() {
insinto /usr/share/openpgp-keys
newins "gentoo-release.asc.${PV}" gentoo-release.asc
}

@ -1,20 +0,0 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
DESCRIPTION="OpenPGP keys used for Gentoo releases (snapshots, stages)"
HOMEPAGE="https://www.gentoo.org/downloads/signatures/"
SRC_URI="https://dev.gentoo.org/~mgorny/dist/openpgp-keys/gentoo-release.asc.${PV}.gz"
LICENSE="public-domain"
SLOT="0"
KEYWORDS="alpha amd64 arm arm64 hppa ia64 m68k ~mips ppc ppc64 s390 sh sparc x86 ~amd64-fbsd ~x86-fbsd"
IUSE=""
S=${WORKDIR}
src_install() {
insinto /usr/share/openpgp-keys
newins "gentoo-release.asc.${PV}" gentoo-release.asc
}

@ -1,20 +0,0 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
DESCRIPTION="OpenPGP keys used for Gentoo releases (snapshots, stages)"
HOMEPAGE="https://www.gentoo.org/downloads/signatures/"
SRC_URI="https://dev.gentoo.org/~mgorny/dist/openpgp-keys/gentoo-release.asc.${PV}.gz"
LICENSE="public-domain"
SLOT="0"
KEYWORDS="alpha amd64 arm arm64 hppa ia64 m68k ~mips ppc ppc64 s390 sh sparc x86 ~amd64-fbsd ~x86-fbsd"
IUSE=""
S=${WORKDIR}
src_install() {
insinto /usr/share/openpgp-keys
newins "gentoo-release.asc.${PV}" gentoo-release.asc
}

@ -17,6 +17,7 @@ IUSE="bindist doc libressl"
RDEPEND="
dev-libs/libltdl:0=
dev-qt/qtgui:5
dev-qt/qtsql:5[sqlite]
dev-qt/qtwidgets:5
!libressl? ( dev-libs/openssl:0=[bindist=] )
libressl? ( dev-libs/libressl:0= )

Binary file not shown.

@ -0,0 +1,640 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
PLOCALES="ar bg ca cs da de el en en_US eo es fa fi fr he hi hr hu it ja ko lt ml nb_NO nl or pa pl pt_BR pt_PT rm ro ru sk sl sr_RS@cyrillic sr_RS@latin sv te th tr uk wa zh_CN zh_TW"
PLOCALE_BACKUP="en"
inherit autotools estack eutils flag-o-matic gnome2-utils l10n multilib multilib-minimal pax-utils toolchain-funcs virtualx versionator xdg-utils
MY_PN="${PN%%-*}"
MY_P="${MY_PN}-${PV}"
if [[ ${PV} == "9999" ]] ; then
EGIT_REPO_URI="https://source.winehq.org/git/wine.git"
EGIT_BRANCH="master"
inherit git-r3
SRC_URI=""
#KEYWORDS=""
else
MAJOR_V=$(get_version_component_range 1)
SRC_URI="https://dl.winehq.org/wine/source/${MAJOR_V}.x/${MY_P}.tar.xz"
KEYWORDS="-* ~amd64 ~x86 ~x86-fbsd"
fi
S="${WORKDIR}/${MY_P}"
STAGING_P="wine-staging-${PV}"
STAGING_DIR="${WORKDIR}/${STAGING_P}"
D3D9_P="wine-d3d9-${PV}"
D3D9_DIR="${WORKDIR}/wine-d3d9-patches-${D3D9_P}"
GWP_V="20180120"
PATCHDIR="${WORKDIR}/gentoo-wine-patches"
DESCRIPTION="Free implementation of Windows(tm) on Unix, with optional external patchsets"
HOMEPAGE="https://www.winehq.org/"
SRC_URI="${SRC_URI}
https://dev.gentoo.org/~np-hardass/distfiles/wine/gentoo-wine-patches-${GWP_V}.tar.xz
"
if [[ ${PV} == "9999" ]] ; then
STAGING_EGIT_REPO_URI="https://github.com/wine-staging/wine-staging.git"
D3D9_EGIT_REPO_URI="https://github.com/sarnex/wine-d3d9-patches.git"
else
SRC_URI="${SRC_URI}
staging? ( https://github.com/wine-staging/wine-staging/archive/v${PV}.tar.gz -> ${STAGING_P}.tar.gz )
d3d9? ( https://github.com/sarnex/wine-d3d9-patches/archive/${D3D9_P}.tar.gz )"
fi
LICENSE="LGPL-2.1"
SLOT="${PV}"
IUSE="+abi_x86_32 +abi_x86_64 +alsa capi cups custom-cflags d3d9 dos elibc_glibc ffmpeg +fontconfig +gecko gphoto2 gsm gssapi gstreamer +jpeg kerberos kernel_FreeBSD +lcms ldap +mono mp3 ncurses netapi nls odbc openal opencl +opengl osmesa oss +perl pcap pipelight +png prelink pulseaudio +realtime +run-exes samba scanner sdl selinux +ssl staging test themes +threads +truetype udev +udisks v4l vaapi vkd3d vulkan +X +xcomposite xinerama +xml"
REQUIRED_USE="|| ( abi_x86_32 abi_x86_64 )
X? ( truetype )
elibc_glibc? ( threads )
ffmpeg? ( staging )
osmesa? ( opengl )
pipelight? ( staging )
test? ( abi_x86_32 )
themes? ( staging )
vaapi? ( staging )" # osmesa-opengl #286560 # X-truetype #551124
# FIXME: the test suite is unsuitable for us; many tests require net access
# or fail due to Xvfb's opengl limitations.
RESTRICT="test"
COMMON_DEPEND="
X? (
x11-libs/libXcursor[${MULTILIB_USEDEP}]
x11-libs/libXext[${MULTILIB_USEDEP}]
x11-libs/libXfixes[${MULTILIB_USEDEP}]
x11-libs/libXrandr[${MULTILIB_USEDEP}]
x11-libs/libXi[${MULTILIB_USEDEP}]
x11-libs/libXxf86vm[${MULTILIB_USEDEP}]
)
alsa? ( media-libs/alsa-lib[${MULTILIB_USEDEP}] )
capi? ( net-libs/libcapi[${MULTILIB_USEDEP}] )
cups? ( net-print/cups:=[${MULTILIB_USEDEP}] )
d3d9? (
media-libs/mesa[d3d9,egl,${MULTILIB_USEDEP}]
x11-libs/libX11[${MULTILIB_USEDEP}]
x11-libs/libXext[${MULTILIB_USEDEP}]
x11-libs/libxcb[${MULTILIB_USEDEP}]
)
ffmpeg? ( >=media-video/ffmpeg-4:=[${MULTILIB_USEDEP}] )
fontconfig? ( media-libs/fontconfig:=[${MULTILIB_USEDEP}] )
gphoto2? ( media-libs/libgphoto2:=[${MULTILIB_USEDEP}] )
gsm? ( media-sound/gsm:=[${MULTILIB_USEDEP}] )
gssapi? ( virtual/krb5[${MULTILIB_USEDEP}] )
gstreamer? (
media-libs/gstreamer:1.0[${MULTILIB_USEDEP}]
media-plugins/gst-plugins-meta:1.0[${MULTILIB_USEDEP}]
)
jpeg? ( virtual/jpeg:0=[${MULTILIB_USEDEP}] )
kerberos? ( virtual/krb5:0=[${MULTILIB_USEDEP}] )
lcms? ( media-libs/lcms:2=[${MULTILIB_USEDEP}] )
ldap? ( net-nds/openldap:=[${MULTILIB_USEDEP}] )
mp3? ( >=media-sound/mpg123-1.5.0[${MULTILIB_USEDEP}] )
ncurses? ( >=sys-libs/ncurses-5.2:0=[${MULTILIB_USEDEP}] )
netapi? ( net-fs/samba[netapi(+),${MULTILIB_USEDEP}] )
nls? ( sys-devel/gettext[${MULTILIB_USEDEP}] )
odbc? ( dev-db/unixODBC:=[${MULTILIB_USEDEP}] )
openal? ( media-libs/openal:=[${MULTILIB_USEDEP}] )
opencl? ( virtual/opencl[${MULTILIB_USEDEP}] )
opengl? (
virtual/glu[${MULTILIB_USEDEP}]
virtual/opengl[${MULTILIB_USEDEP}]
)
osmesa? ( >=media-libs/mesa-13[osmesa,${MULTILIB_USEDEP}] )
pcap? ( net-libs/libpcap[${MULTILIB_USEDEP}] )
png? ( media-libs/libpng:0=[${MULTILIB_USEDEP}] )
pulseaudio? ( media-sound/pulseaudio[${MULTILIB_USEDEP}] )
scanner? ( media-gfx/sane-backends:=[${MULTILIB_USEDEP}] )
sdl? ( media-libs/libsdl2:=[haptic,joystick,${MULTILIB_USEDEP}] )
ssl? ( net-libs/gnutls:=[${MULTILIB_USEDEP}] )
staging? ( sys-apps/attr[${MULTILIB_USEDEP}] )
themes? (
dev-libs/glib:2[${MULTILIB_USEDEP}]
x11-libs/cairo[${MULTILIB_USEDEP}]
x11-libs/gtk+:3[${MULTILIB_USEDEP}]
)
truetype? ( >=media-libs/freetype-2.0.0[${MULTILIB_USEDEP}] )
udev? ( virtual/libudev:=[${MULTILIB_USEDEP}] )
udisks? ( sys-apps/dbus[${MULTILIB_USEDEP}] )
v4l? ( media-libs/libv4l[${MULTILIB_USEDEP}] )
vaapi? ( x11-libs/libva[X,${MULTILIB_USEDEP}] )
vkd3d? ( app-emulation/vkd3d[${MULTILIB_USEDEP}] )
vulkan? ( media-libs/vulkan-loader[${MULTILIB_USEDEP}] )
xcomposite? ( x11-libs/libXcomposite[${MULTILIB_USEDEP}] )
xinerama? ( x11-libs/libXinerama[${MULTILIB_USEDEP}] )
xml? (
dev-libs/libxml2[${MULTILIB_USEDEP}]
dev-libs/libxslt[${MULTILIB_USEDEP}]
)"
RDEPEND="${COMMON_DEPEND}
app-emulation/wine-desktop-common
>app-eselect/eselect-wine-0.3
!app-emulation/wine:0
dos? ( >=games-emulation/dosbox-0.74_p20160629 )
gecko? ( app-emulation/wine-gecko:2.47[abi_x86_32?,abi_x86_64?] )
mono? ( app-emulation/wine-mono:4.7.3 )
perl? (
dev-lang/perl
dev-perl/XML-Simple
)
pulseaudio? (
realtime? ( sys-auth/rtkit )
)
samba? ( >=net-fs/samba-3.0.25[winbind] )
selinux? ( sec-policy/selinux-wine )
udisks? ( sys-fs/udisks:2 )"
# tools/make_requests requires perl
DEPEND="${COMMON_DEPEND}
sys-devel/flex
>=sys-kernel/linux-headers-2.6
virtual/pkgconfig
virtual/yacc
X? ( x11-base/xorg-proto )
prelink? ( sys-devel/prelink )
staging? (
dev-lang/perl
dev-perl/XML-Simple
)
xinerama? ( x11-base/xorg-proto )"
# These use a non-standard "Wine" category, which is provided by
# /etc/xdg/applications-merged/wine.menu
QA_DESKTOP_FILE="usr/share/applications/wine-browsedrive.desktop
usr/share/applications/wine-notepad.desktop
usr/share/applications/wine-uninstaller.desktop
usr/share/applications/wine-winecfg.desktop"
PATCHES=(
"${PATCHDIR}/patches/${MY_PN}-1.5.26-winegcc.patch" #260726
"${PATCHDIR}/patches/${MY_PN}-1.9.5-multilib-portage.patch" #395615
"${PATCHDIR}/patches/${MY_PN}-1.6-memset-O3.patch" #480508
"${PATCHDIR}/patches/${MY_PN}-2.0-multislot-apploader.patch" #310611
)
PATCHES_BIN=()
# https://bugs.gentoo.org/show_bug.cgi?id=635222
if [[ ${#PATCHES_BIN[@]} -ge 1 ]] || [[ ${PV} == 9999 ]]; then
DEPEND+=" dev-util/patchbin"
fi
wine_compiler_check() {
[[ ${MERGE_TYPE} = "binary" ]] && return 0
# GCC-specific bugs
if tc-is-gcc; then
# bug #549768
if use abi_x86_64 && [[ $(gcc-major-version) = 5 && $(gcc-minor-version) -le 2 ]]; then
ebegin "Checking for gcc-5 ms_abi compiler bug"
$(tc-getCC) -O2 "${PATCHDIR}/files/pr66838.c" -o "${T}"/pr66838 || die
# Run in subshell to prevent "Aborted" message
( "${T}"/pr66838 || false ) >/dev/null 2>&1
if ! eend $?; then
eerror "64-bit wine cannot be built with gcc-5.1 or initial patchset of 5.2.0"
eerror "due to compiler bugs; please re-emerge the latest gcc-5.2.x ebuild,"
eerror "or use gcc-config to select a different compiler version."
eerror "See https://bugs.gentoo.org/549768"
eerror
return 1
fi
fi
# bug #574044
if use abi_x86_64 && [[ $(gcc-major-version) = 5 && $(gcc-minor-version) = 3 ]]; then
ebegin "Checking for gcc-5-3 stack realignment compiler bug"
# Compile in subshell to prevent "Aborted" message
( $(tc-getCC) -O2 -mincoming-stack-boundary=3 "${PATCHDIR}/files/pr69140.c" -o "${T}"/pr69140 ) >/dev/null 2>&1
if ! eend $?; then
eerror "Wine cannot be built with this version of gcc-5.3"
eerror "due to compiler bugs; please re-emerge the latest gcc-5.3.x ebuild,"
eerror "or use gcc-config to select a different compiler version."
eerror "See https://bugs.gentoo.org/574044"
eerror
return 1
fi
fi
fi
# Ensure compiler support
if use abi_x86_64; then
ebegin "Checking for 64-bit compiler with builtin_ms_va_list support"
# Compile in subshell to prevent "Aborted" message
( $(tc-getCC) -O2 "${PATCHDIR}/files/builtin_ms_va_list.c" -o "${T}"/builtin_ms_va_list >/dev/null 2>&1)
if ! eend $?; then
eerror "This version of $(tc-getCC) does not support builtin_ms_va_list, can't enable 64-bit wine"
eerror
eerror "You need gcc-4.4+ or clang 3.8+ to build 64-bit wine"
eerror
return 1
fi
fi
}
wine_build_environment_check() {
[[ ${MERGE_TYPE} = "binary" ]] && return 0
if use abi_x86_64; then
if tc-is-gcc && [[ $(gcc-major-version) -lt 4 || ( $(gcc-major-version) -eq 4 && $(gcc-minor-version) -lt 4 ) ]]; then
eerror "You need gcc-4.4+ to compile 64-bit wine"
die
elif tc-is-clang && [[ $(clang-major-version) -lt 3 || ( $(clang-major-version) -eq 3 && $(clang-minor-version) -lt 8 ) ]]; then
eerror "You need clang-3.8+ to compile 64-bit wine"
die
fi
fi
if tc-is-gcc && [[ $(gcc-major-version) -eq 5 && $(gcc-minor-version) -le 3 ]]; then
ewarn "GCC-5.0-5.3 suffered from compiler bugs and are no longer supported by"
ewarn "Gentoo's Toolchain Team. If your ebuild fails the compiler checks in"
ewarn "the configure phase, either update your compiler or switch to <5.0 || >=5.4"
fi
if tc-is-gcc && [[ $(gcc-major-version) -eq 5 && $(gcc-minor-version) -eq 4 ]]; then
if has "-march=i686" ${CFLAGS} && ! has "-mtune=generic" ${CFLAGS}; then
ewarn "Compilation can hang with CFLAGS=\"-march=i686\". You can temporarily work"
ewarn "around this by adding \"-mtune=generic\" to your CFLAGS for wine."
ewarn "See package.env in man 5 portage for more information on how to do this."
ewarn "See https://bugs.gentoo.org/show_bug.cgi?id=613128 for more details"
fi
fi
if use abi_x86_32 && use opencl && [[ "$(eselect opencl show 2> /dev/null)" == "intel" ]]; then
eerror "You cannot build wine with USE=opencl because intel-ocl-sdk is 64-bit only."
eerror "See https://bugs.gentoo.org/487864 for more details."
eerror
return 1
fi
}
wine_env_vcs_vars() {
local pn_live_var="${PN//[-+]/_}_LIVE_COMMIT"
local pn_live_val="${pn_live_var}"
eval pn_live_val='$'${pn_live_val}
if [[ ! -z ${pn_live_val} ]]; then
if use staging || use d3d9; then
eerror "Because of the multi-repo nature of ${MY_PN}, ${pn_live_var}"
eerror "cannot be used to set the commit. Instead, you may use the"
eerror "environmental variables WINE_COMMIT, STAGING_COMMIT, and D3D9_COMMIT."
eerror
return 1
fi
fi
if [[ ! -z ${EGIT_COMMIT} ]]; then
eerror "Commits must now be specified using the environmental variables"
eerror "WINE_COMMIT, STAGING_COMMIT, and D3D9_COMMIT"
eerror
return 1
fi
}
pkg_pretend() {
wine_build_environment_check || die
# Verify OSS support
if use oss && ! use kernel_FreeBSD; then
if ! has_version ">=media-sound/oss-4"; then
eerror "You cannot build wine with USE=oss without having support from a"
eerror "FreeBSD kernel or >=media-sound/oss-4 (only available through external repos)"
eerror
die
fi
fi
}
pkg_setup() {
wine_build_environment_check || die
wine_env_vcs_vars || die
WINE_VARIANT="${PN#wine}-${PV}"
WINE_VARIANT="${WINE_VARIANT#-}"
MY_PREFIX="${EPREFIX}/usr/lib/wine-${WINE_VARIANT}"
MY_DATAROOTDIR="${EPREFIX}/usr/share/wine-${WINE_VARIANT}"
MY_DATADIR="${MY_DATAROOTDIR}"
MY_DOCDIR="${EPREFIX}/usr/share/doc/${PF}"
MY_INCLUDEDIR="${EPREFIX}/usr/include/wine-${WINE_VARIANT}"
MY_LIBEXECDIR="${EPREFIX}/usr/libexec/wine-${WINE_VARIANT}"
MY_LOCALSTATEDIR="${EPREFIX}/var/wine-${WINE_VARIANT}"
MY_MANDIR="${MY_DATADIR}/man"
}
src_unpack() {
if [[ ${PV} == "9999" ]] ; then
EGIT_CHECKOUT_DIR="${S}" EGIT_COMMIT="${WINE_COMMIT}" git-r3_src_unpack
if use staging; then
local CURRENT_WINE_COMMIT=${EGIT_VERSION}
git-r3_fetch "${STAGING_EGIT_REPO_URI}" "${STAGING_COMMIT}"
git-r3_checkout "${STAGING_EGIT_REPO_URI}" "${STAGING_DIR}"
local COMPAT_WINE_COMMIT=$("${STAGING_DIR}/patches/patchinstall.sh" --upstream-commit) || die
if [[ "${CURRENT_WINE_COMMIT}" != "${COMPAT_WINE_COMMIT}" ]]; then
einfo "The current Staging patchset is not guaranteed to apply on this WINE commit."
einfo "If src_prepare fails, try emerging with the env var WINE_COMMIT."
einfo "Example: WINE_COMMIT=${COMPAT_WINE_COMMIT} emerge -1 wine"
fi
fi
if use d3d9; then
git-r3_fetch "${D3D9_EGIT_REPO_URI}" "${D3D9_COMMIT}"
git-r3_checkout "${D3D9_EGIT_REPO_URI}" "${D3D9_DIR}"
fi
fi
default
l10n_find_plocales_changes "${S}/po" "" ".po"
}
src_prepare() {
eapply_bin(){
local patch
for patch in ${PATCHES_BIN[@]}; do
patchbin --nogit < "${patch}" || die
done
}
local md5="$(md5sum server/protocol.def)"
if use staging; then
ewarn "Applying the Wine-Staging patchset. Any bug reports to the"
ewarn "Wine bugzilla should explicitly state that staging was used."
local STAGING_EXCLUDE=""
use pipelight || STAGING_EXCLUDE="${STAGING_EXCLUDE} -W Pipelight"
# Launch wine-staging patcher in a subshell, using eapply as a backend, and gitapply.sh as a backend for binary patches
ebegin "Running Wine-Staging patch installer"
(
set -- DESTDIR="${S}" --backend=eapply --no-autoconf --all ${STAGING_EXCLUDE}
cd "${STAGING_DIR}/patches"
source "${STAGING_DIR}/patches/patchinstall.sh"
)
eend $? || die "Failed to apply Wine-Staging patches"
fi
if use d3d9; then
if use staging; then
PATCHES+=( "${D3D9_DIR}/staging-helper.patch" )
else
PATCHES+=( "${D3D9_DIR}/d3d9-helper.patch" )
fi
PATCHES+=( "${D3D9_DIR}/wine-d3d9.patch" )
fi
default
eapply_bin
eautoreconf
# Modification of the server protocol requires regenerating the server requests
if [[ "$(md5sum server/protocol.def)" != "${md5}" ]]; then
einfo "server/protocol.def was patched; running tools/make_requests"
tools/make_requests || die #432348
fi
sed -i '/^UPDATE_DESKTOP_DATABASE/s:=.*:=true:' tools/Makefile.in || die
if ! use run-exes; then
sed -i '/^MimeType/d' loader/wine.desktop || die #117785
fi
# Edit wine.desktop to work for specific variant
sed -e "/^Exec=/s/wine /wine-${WINE_VARIANT} /" -i loader/wine.desktop || die
# hi-res default icon, #472990, https://bugs.winehq.org/show_bug.cgi?id=24652
cp "${PATCHDIR}/files/oic_winlogo.ico" dlls/user32/resources/ || die
l10n_get_locales > po/LINGUAS || die # otherwise wine doesn't respect LINGUAS
# Fix manpage generation for locales #469418 and abi_x86_64 #617864
# Duplicate manpages input files for wine64
local f
for f in loader/*.man.in; do
cp ${f} ${f/wine/wine64} || die
done
# Add wine64 manpages to Makefile
if use abi_x86_64; then
sed -i "/wine.man.in/i \
\\\twine64.man.in \\\\" loader/Makefile.in || die
sed -i -E 's/(.*wine)(.*\.UTF-8\.man\.in.*)/&\
\164\2/' loader/Makefile.in || die
fi
rm_man_file(){
local file="${1}"
loc=${2}
sed -i "/${loc}\.UTF-8\.man\.in/d" "${file}" || die
}
while read f; do
l10n_for_each_disabled_locale_do rm_man_file "${f}"
done < <(find -name "Makefile.in" -exec grep -q "UTF-8.man.in" "{}" \; -print)
}
src_configure() {
wine_compiler_check || die
export LDCONFIG=/bin/true
use custom-cflags || strip-flags
multilib-minimal_src_configure
}
multilib_src_configure() {
local myconf=(
--prefix="${MY_PREFIX}"
--datarootdir="${MY_DATAROOTDIR}"
--datadir="${MY_DATADIR}"
--docdir="${MY_DOCDIR}"
--includedir="${MY_INCLUDEDIR}"
--libdir="${EPREFIX}/usr/$(get_libdir)/wine-${WINE_VARIANT}"
--libexecdir="${MY_LIBEXECDIR}"
--localstatedir="${MY_LOCALSTATEDIR}"
--mandir="${MY_MANDIR}"
--sysconfdir=/etc/wine
$(use_with alsa)
$(use_with capi)
$(use_with lcms cms)
$(use_with cups)
$(use_with ncurses curses)
$(use_with udisks dbus)
$(use_with ffmpeg)
$(use_with fontconfig)
$(use_with ssl gnutls)
$(use_enable gecko mshtml)
$(use_with gphoto2 gphoto)
$(use_with gsm)
$(use_with gssapi)
$(use_with gstreamer)
--without-hal
$(use_with jpeg)
$(use_with kerberos krb5)
$(use_with ldap)
$(use_enable mono mscoree)
$(use_with mp3 mpg123)
$(use_with netapi)
$(use_with nls gettext)
$(use_with openal)
$(use_with opencl)
$(use_with opengl)
$(use_with osmesa)
$(use_with oss)
$(use_with pcap)
$(use_with png)
$(use_with pulseaudio pulse)
$(use_with threads pthread)
$(use_with scanner sane)
$(use_with sdl)
$(use_enable test tests)
$(use_with truetype freetype)
$(use_with udev)
$(use_with v4l)
$(use_with vkd3d)
$(use_with vulkan)
$(use_with X x)
$(use_with X xfixes)
$(use_with xcomposite)
$(use_with xinerama)
$(use_with xml)
$(use_with xml xslt)
)
use staging && myconf+=(
--with-xattr
$(use_with themes gtk3)
$(use_with vaapi va)
)
use d3d9 && myconf+=( $(use_with d3d9 d3d9-nine) )
local PKG_CONFIG AR RANLIB
# Avoid crossdev's i686-pc-linux-gnu-pkg-config if building wine32 on amd64; #472038
# set AR and RANLIB to make QA scripts happy; #483342
tc-export PKG_CONFIG AR RANLIB
if use amd64; then
if [[ ${ABI} == amd64 ]]; then
myconf+=( --enable-win64 )
else
myconf+=( --disable-win64 )
fi
# Note: using --with-wine64 results in problems with multilib.eclass
# CC/LD hackery. We're using separate tools instead.
fi
ECONF_SOURCE=${S} \
econf "${myconf[@]}"
emake depend
}
multilib_src_test() {
# FIXME: win32-only; wine64 tests fail with "could not find the Wine loader"
if [[ ${ABI} == x86 ]]; then
if [[ $(id -u) == 0 ]]; then
ewarn "Skipping tests since they cannot be run under the root user."
ewarn "To run the test ${MY_PN} suite, add userpriv to FEATURES in make.conf"
return
fi
WINEPREFIX="${T}/.wine-${ABI}" \
Xemake test
fi
}
multilib_src_install_all() {
local DOCS=( ANNOUNCE AUTHORS README )
add_locale_docs() {
local locale_doc="documentation/README.$1"
[[ ! -e ${locale_doc} ]] || DOCS+=( ${locale_doc} )
}
l10n_for_each_locale_do add_locale_docs
einstalldocs
prune_libtool_files --all
if ! use perl ; then # winedump calls function_grep.pl, and winemaker is a perl script
rm "${D%/}${MY_PREFIX}"/bin/{wine{dump,maker},function_grep.pl} \
"${D%/}${MY_MANDIR}"/man1/wine{dump,maker}.1 || die
fi
# Remove wineconsole if neither backend is installed #551124
if ! use X && ! use ncurses; then
rm "${D%/}${MY_PREFIX}"/bin/wineconsole* || die
rm "${D%/}${MY_MANDIR}"/man1/wineconsole* || die
rm_wineconsole() {
rm "${D%/}${MY_PREFIX}/$(get_libdir)"/wine/{,fakedlls/}wineconsole.exe* || die
}
multilib_foreach_abi rm_wineconsole
fi
use abi_x86_32 && pax-mark psmr "${D%/}${MY_PREFIX}"/bin/wine{,-preloader} #255055
use abi_x86_64 && pax-mark psmr "${D%/}${MY_PREFIX}"/bin/wine64{,-preloader}
if use abi_x86_64 && ! use abi_x86_32; then
dosym wine64 "${MY_PREFIX}"/bin/wine # 404331
dosym wine64-preloader "${MY_PREFIX}"/bin/wine-preloader
fi
# Failglob for binloops, shouldn't be necessary, but including to stay safe
eshopts_push -s failglob #615218
# Make wrappers for binaries for handling multiple variants
# Note: wrappers instead of symlinks because some are shell which use basename
local b
for b in "${D%/}${MY_PREFIX}"/bin/*; do
make_wrapper "${b##*/}-${WINE_VARIANT}" "${MY_PREFIX}/bin/${b##*/}"
done
eshopts_pop
}
pkg_postinst() {
eselect wine register ${P}
if [[ ${PN} == "wine-vanilla" ]]; then
eselect wine register --vanilla ${P} || die
else
if use staging; then
eselect wine register --staging ${P} || die
fi
if use d3d9; then
eselect wine register --d3d9 ${P} || die
fi
fi
eselect wine update --all --if-unset || die
xdg_desktop_database_update
if ! use gecko; then
ewarn "Without Wine Gecko, wine prefixes will not have a default"
ewarn "implementation of iexplore. Many older windows applications"
ewarn "rely upon the existence of an iexplore implementation, so"
ewarn "you will likely need to install an external one, like via winetricks"
fi
if ! use mono; then
ewarn "Without Wine Mono, wine prefixes will not have a default"
ewarn "implementation of .NET. Many windows applications rely upon"
ewarn "the existence of a .NET implementation, so you will likely need"
ewarn "to install an external one, like via winetricks"
fi
}
pkg_prerm() {
eselect wine deregister ${P}
if [[ ${PN} == "wine-vanilla" ]]; then
eselect wine deregister --vanilla ${P} || die
else
if use staging; then
eselect wine deregister --staging ${P} || die
fi
if use d3d9; then
eselect wine deregister --d3d9 ${P} || die
fi
fi
eselect wine update --all --if-unset || die
}
pkg_postrm() {
xdg_desktop_database_update
}

@ -138,7 +138,7 @@ RDEPEND="${COMMON_DEPEND}
!app-emulation/wine:0
dos? ( >=games-emulation/dosbox-0.74_p20160629 )
gecko? ( app-emulation/wine-gecko:2.47[abi_x86_32?,abi_x86_64?] )
mono? ( app-emulation/wine-mono:4.7.1 )
mono? ( app-emulation/wine-mono:4.7.3 )
perl? (
dev-lang/perl
dev-perl/XML-Simple

@ -0,0 +1,574 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
PLOCALES="ar bg ca cs da de el en en_US eo es fa fi fr he hi hr hu it ja ko lt ml nb_NO nl or pa pl pt_BR pt_PT rm ro ru sk sl sr_RS@cyrillic sr_RS@latin sv te th tr uk wa zh_CN zh_TW"
PLOCALE_BACKUP="en"
inherit autotools estack eutils flag-o-matic gnome2-utils l10n multilib multilib-minimal pax-utils toolchain-funcs virtualx versionator xdg-utils
MY_PN="${PN%%-*}"
MY_P="${MY_PN}-${PV}"
if [[ ${PV} == "9999" ]] ; then
EGIT_REPO_URI="https://source.winehq.org/git/wine.git"
EGIT_BRANCH="master"
inherit git-r3
SRC_URI=""
#KEYWORDS=""
else
MAJOR_V=$(get_version_component_range 1)
SRC_URI="https://dl.winehq.org/wine/source/${MAJOR_V}.x/${MY_P}.tar.xz"
KEYWORDS="-* ~amd64 ~x86 ~x86-fbsd"
fi
S="${WORKDIR}/${MY_P}"
D3D9_P="wine-d3d9-${PV}"
D3D9_DIR="${WORKDIR}/wine-d3d9-patches-${D3D9_P}"
GWP_V="20180120"
PATCHDIR="${WORKDIR}/gentoo-wine-patches"
DESCRIPTION="Free implementation of Windows(tm) on Unix, with Gallium Nine patchset"
HOMEPAGE="https://www.winehq.org/"
SRC_URI="${SRC_URI}
https://dev.gentoo.org/~np-hardass/distfiles/wine/gentoo-wine-patches-${GWP_V}.tar.xz
"
if [[ ${PV} == "9999" ]] ; then
D3D9_EGIT_REPO_URI="https://github.com/sarnex/wine-d3d9-patches.git"
else
SRC_URI="${SRC_URI}
d3d9? ( https://github.com/sarnex/wine-d3d9-patches/archive/${D3D9_P}.tar.gz )"
fi
LICENSE="LGPL-2.1"
SLOT="${PV}"
IUSE="+abi_x86_32 +abi_x86_64 +alsa capi cups custom-cflags d3d9 dos elibc_glibc +fontconfig +gecko gphoto2 gsm gssapi gstreamer +jpeg kerberos kernel_FreeBSD +lcms ldap +mono mp3 ncurses netapi nls odbc openal opencl +opengl osmesa oss +perl pcap +png prelink pulseaudio +realtime +run-exes samba scanner sdl selinux +ssl test +threads +truetype udev +udisks v4l vkd3d vulkan +X +xcomposite xinerama +xml"
REQUIRED_USE="|| ( abi_x86_32 abi_x86_64 )
X? ( truetype )
elibc_glibc? ( threads )
osmesa? ( opengl )
test? ( abi_x86_32 )" # osmesa-opengl #286560 # X-truetype #551124
# FIXME: the test suite is unsuitable for us; many tests require net access
# or fail due to Xvfb's opengl limitations.
RESTRICT="test"
COMMON_DEPEND="
X? (
x11-libs/libXcursor[${MULTILIB_USEDEP}]
x11-libs/libXext[${MULTILIB_USEDEP}]
x11-libs/libXfixes[${MULTILIB_USEDEP}]
x11-libs/libXrandr[${MULTILIB_USEDEP}]
x11-libs/libXi[${MULTILIB_USEDEP}]
x11-libs/libXxf86vm[${MULTILIB_USEDEP}]
)
alsa? ( media-libs/alsa-lib[${MULTILIB_USEDEP}] )
capi? ( net-libs/libcapi[${MULTILIB_USEDEP}] )
cups? ( net-print/cups:=[${MULTILIB_USEDEP}] )
d3d9? (
media-libs/mesa[d3d9,egl,${MULTILIB_USEDEP}]
x11-libs/libX11[${MULTILIB_USEDEP}]
x11-libs/libXext[${MULTILIB_USEDEP}]
x11-libs/libxcb[${MULTILIB_USEDEP}]
)
fontconfig? ( media-libs/fontconfig:=[${MULTILIB_USEDEP}] )
gphoto2? ( media-libs/libgphoto2:=[${MULTILIB_USEDEP}] )
gsm? ( media-sound/gsm:=[${MULTILIB_USEDEP}] )
gssapi? ( virtual/krb5[${MULTILIB_USEDEP}] )
gstreamer? (
media-libs/gstreamer:1.0[${MULTILIB_USEDEP}]
media-plugins/gst-plugins-meta:1.0[${MULTILIB_USEDEP}]
)
jpeg? ( virtual/jpeg:0=[${MULTILIB_USEDEP}] )
kerberos? ( virtual/krb5:0=[${MULTILIB_USEDEP}] )
lcms? ( media-libs/lcms:2=[${MULTILIB_USEDEP}] )
ldap? ( net-nds/openldap:=[${MULTILIB_USEDEP}] )
mp3? ( >=media-sound/mpg123-1.5.0[${MULTILIB_USEDEP}] )
ncurses? ( >=sys-libs/ncurses-5.2:0=[${MULTILIB_USEDEP}] )
netapi? ( net-fs/samba[netapi(+),${MULTILIB_USEDEP}] )
nls? ( sys-devel/gettext[${MULTILIB_USEDEP}] )
odbc? ( dev-db/unixODBC:=[${MULTILIB_USEDEP}] )
openal? ( media-libs/openal:=[${MULTILIB_USEDEP}] )
opencl? ( virtual/opencl[${MULTILIB_USEDEP}] )
opengl? (
virtual/glu[${MULTILIB_USEDEP}]
virtual/opengl[${MULTILIB_USEDEP}]
)
osmesa? ( >=media-libs/mesa-13[osmesa,${MULTILIB_USEDEP}] )
pcap? ( net-libs/libpcap[${MULTILIB_USEDEP}] )
png? ( media-libs/libpng:0=[${MULTILIB_USEDEP}] )
pulseaudio? ( media-sound/pulseaudio[${MULTILIB_USEDEP}] )
scanner? ( media-gfx/sane-backends:=[${MULTILIB_USEDEP}] )
sdl? ( media-libs/libsdl2:=[haptic,joystick,${MULTILIB_USEDEP}] )
ssl? ( net-libs/gnutls:=[${MULTILIB_USEDEP}] )
truetype? ( >=media-libs/freetype-2.0.0[${MULTILIB_USEDEP}] )
udev? ( virtual/libudev:=[${MULTILIB_USEDEP}] )
udisks? ( sys-apps/dbus[${MULTILIB_USEDEP}] )
v4l? ( media-libs/libv4l[${MULTILIB_USEDEP}] )
vkd3d? ( app-emulation/vkd3d[${MULTILIB_USEDEP}] )
vulkan? ( media-libs/vulkan-loader[${MULTILIB_USEDEP}] )
xcomposite? ( x11-libs/libXcomposite[${MULTILIB_USEDEP}] )
xinerama? ( x11-libs/libXinerama[${MULTILIB_USEDEP}] )
xml? (
dev-libs/libxml2[${MULTILIB_USEDEP}]
dev-libs/libxslt[${MULTILIB_USEDEP}]
)"
RDEPEND="${COMMON_DEPEND}
app-emulation/wine-desktop-common
>app-eselect/eselect-wine-0.3
!app-emulation/wine:0
dos? ( >=games-emulation/dosbox-0.74_p20160629 )
gecko? ( app-emulation/wine-gecko:2.47[abi_x86_32?,abi_x86_64?] )
mono? ( app-emulation/wine-mono:4.7.3 )
perl? (
dev-lang/perl
dev-perl/XML-Simple
)
pulseaudio? (
realtime? ( sys-auth/rtkit )
)
samba? ( >=net-fs/samba-3.0.25[winbind] )
selinux? ( sec-policy/selinux-wine )
udisks? ( sys-fs/udisks:2 )"
# tools/make_requests requires perl
DEPEND="${COMMON_DEPEND}
sys-devel/flex
>=sys-kernel/linux-headers-2.6
virtual/pkgconfig
virtual/yacc
X? ( x11-base/xorg-proto )
prelink? ( sys-devel/prelink )
xinerama? ( x11-base/xorg-proto )"
# These use a non-standard "Wine" category, which is provided by
# /etc/xdg/applications-merged/wine.menu
QA_DESKTOP_FILE="usr/share/applications/wine-browsedrive.desktop
usr/share/applications/wine-notepad.desktop
usr/share/applications/wine-uninstaller.desktop
usr/share/applications/wine-winecfg.desktop"
PATCHES=(
"${PATCHDIR}/patches/${MY_PN}-1.5.26-winegcc.patch" #260726
"${PATCHDIR}/patches/${MY_PN}-1.9.5-multilib-portage.patch" #395615
"${PATCHDIR}/patches/${MY_PN}-1.6-memset-O3.patch" #480508
"${PATCHDIR}/patches/${MY_PN}-2.0-multislot-apploader.patch" #310611
)
PATCHES_BIN=()
# https://bugs.gentoo.org/show_bug.cgi?id=635222
if [[ ${#PATCHES_BIN[@]} -ge 1 ]] || [[ ${PV} == 9999 ]]; then
DEPEND+=" dev-util/patchbin"
fi
wine_compiler_check() {
[[ ${MERGE_TYPE} = "binary" ]] && return 0
# GCC-specific bugs
if tc-is-gcc; then
# bug #549768
if use abi_x86_64 && [[ $(gcc-major-version) = 5 && $(gcc-minor-version) -le 2 ]]; then
ebegin "Checking for gcc-5 ms_abi compiler bug"
$(tc-getCC) -O2 "${PATCHDIR}/files/pr66838.c" -o "${T}"/pr66838 || die
# Run in subshell to prevent "Aborted" message
( "${T}"/pr66838 || false ) >/dev/null 2>&1
if ! eend $?; then
eerror "64-bit wine cannot be built with gcc-5.1 or initial patchset of 5.2.0"
eerror "due to compiler bugs; please re-emerge the latest gcc-5.2.x ebuild,"
eerror "or use gcc-config to select a different compiler version."
eerror "See https://bugs.gentoo.org/549768"
eerror
return 1
fi
fi
# bug #574044
if use abi_x86_64 && [[ $(gcc-major-version) = 5 && $(gcc-minor-version) = 3 ]]; then
ebegin "Checking for gcc-5-3 stack realignment compiler bug"
# Compile in subshell to prevent "Aborted" message
( $(tc-getCC) -O2 -mincoming-stack-boundary=3 "${PATCHDIR}/files/pr69140.c" -o "${T}"/pr69140 ) >/dev/null 2>&1
if ! eend $?; then
eerror "Wine cannot be built with this version of gcc-5.3"
eerror "due to compiler bugs; please re-emerge the latest gcc-5.3.x ebuild,"
eerror "or use gcc-config to select a different compiler version."
eerror "See https://bugs.gentoo.org/574044"
eerror
return 1
fi
fi
fi
# Ensure compiler support
if use abi_x86_64; then
ebegin "Checking for 64-bit compiler with builtin_ms_va_list support"
# Compile in subshell to prevent "Aborted" message
( $(tc-getCC) -O2 "${PATCHDIR}/files/builtin_ms_va_list.c" -o "${T}"/builtin_ms_va_list >/dev/null 2>&1)
if ! eend $?; then
eerror "This version of $(tc-getCC) does not support builtin_ms_va_list, can't enable 64-bit wine"
eerror
eerror "You need gcc-4.4+ or clang 3.8+ to build 64-bit wine"
eerror
return 1
fi
fi
}
wine_build_environment_check() {
[[ ${MERGE_TYPE} = "binary" ]] && return 0
if use abi_x86_64; then
if tc-is-gcc && [[ $(gcc-major-version) -lt 4 || ( $(gcc-major-version) -eq 4 && $(gcc-minor-version) -lt 4 ) ]]; then
eerror "You need gcc-4.4+ to compile 64-bit wine"
die
elif tc-is-clang && [[ $(clang-major-version) -lt 3 || ( $(clang-major-version) -eq 3 && $(clang-minor-version) -lt 8 ) ]]; then
eerror "You need clang-3.8+ to compile 64-bit wine"
die
fi
fi
if tc-is-gcc && [[ $(gcc-major-version) -eq 5 && $(gcc-minor-version) -le 3 ]]; then
ewarn "GCC-5.0-5.3 suffered from compiler bugs and are no longer supported by"
ewarn "Gentoo's Toolchain Team. If your ebuild fails the compiler checks in"
ewarn "the configure phase, either update your compiler or switch to <5.0 || >=5.4"
fi
if tc-is-gcc && [[ $(gcc-major-version) -eq 5 && $(gcc-minor-version) -eq 4 ]]; then
if has "-march=i686" ${CFLAGS} && ! has "-mtune=generic" ${CFLAGS}; then
ewarn "Compilation can hang with CFLAGS=\"-march=i686\". You can temporarily work"
ewarn "around this by adding \"-mtune=generic\" to your CFLAGS for wine."
ewarn "See package.env in man 5 portage for more information on how to do this."
ewarn "See https://bugs.gentoo.org/show_bug.cgi?id=613128 for more details"
fi
fi
if use abi_x86_32 && use opencl && [[ "$(eselect opencl show 2> /dev/null)" == "intel" ]]; then
eerror "You cannot build wine with USE=opencl because intel-ocl-sdk is 64-bit only."
eerror "See https://bugs.gentoo.org/487864 for more details."
eerror
return 1
fi
}
wine_env_vcs_vars() {
local pn_live_var="${PN//[-+]/_}_LIVE_COMMIT"
local pn_live_val="${pn_live_var}"
eval pn_live_val='$'${pn_live_val}
if [[ ! -z ${pn_live_val} ]]; then
if use d3d9; then
eerror "Because of the multi-repo nature of ${MY_PN}, ${pn_live_var}"
eerror "cannot be used to set the commit. Instead, you may use the"
eerror "environmental variables WINE_COMMIT, and D3D9_COMMIT."
eerror
return 1
fi
fi
if [[ ! -z ${EGIT_COMMIT} ]]; then
eerror "Commits must now be specified using the environmental variables"
eerror "WINE_COMMIT, and D3D9_COMMIT"
eerror
return 1
fi
}
pkg_pretend() {
wine_build_environment_check || die
# Verify OSS support
if use oss && ! use kernel_FreeBSD; then
if ! has_version ">=media-sound/oss-4"; then
eerror "You cannot build wine with USE=oss without having support from a"
eerror "FreeBSD kernel or >=media-sound/oss-4 (only available through external repos)"
eerror
die
fi
fi
}
pkg_setup() {
wine_build_environment_check || die
wine_env_vcs_vars || die
WINE_VARIANT="${PN#wine}-${PV}"
WINE_VARIANT="${WINE_VARIANT#-}"
MY_PREFIX="${EPREFIX}/usr/lib/wine-${WINE_VARIANT}"
MY_DATAROOTDIR="${EPREFIX}/usr/share/wine-${WINE_VARIANT}"
MY_DATADIR="${MY_DATAROOTDIR}"
MY_DOCDIR="${EPREFIX}/usr/share/doc/${PF}"
MY_INCLUDEDIR="${EPREFIX}/usr/include/wine-${WINE_VARIANT}"
MY_LIBEXECDIR="${EPREFIX}/usr/libexec/wine-${WINE_VARIANT}"
MY_LOCALSTATEDIR="${EPREFIX}/var/wine-${WINE_VARIANT}"
MY_MANDIR="${MY_DATADIR}/man"
}
src_unpack() {
if [[ ${PV} == "9999" ]] ; then
EGIT_CHECKOUT_DIR="${S}" EGIT_COMMIT="${WINE_COMMIT}" git-r3_src_unpack
if use d3d9; then
git-r3_fetch "${D3D9_EGIT_REPO_URI}" "${D3D9_COMMIT}"
git-r3_checkout "${D3D9_EGIT_REPO_URI}" "${D3D9_DIR}"
fi
fi
default
l10n_find_plocales_changes "${S}/po" "" ".po"
}
src_prepare() {
eapply_bin(){
local patch
for patch in ${PATCHES_BIN[@]}; do
patchbin --nogit < "${patch}" || die
done
}
local md5="$(md5sum server/protocol.def)"
if use d3d9; then
PATCHES+=( "${D3D9_DIR}/d3d9-helper.patch" )
PATCHES+=( "${D3D9_DIR}/wine-d3d9.patch" )
fi
default
eapply_bin
eautoreconf
# Modification of the server protocol requires regenerating the server requests
if [[ "$(md5sum server/protocol.def)" != "${md5}" ]]; then
einfo "server/protocol.def was patched; running tools/make_requests"
tools/make_requests || die #432348
fi
sed -i '/^UPDATE_DESKTOP_DATABASE/s:=.*:=true:' tools/Makefile.in || die
if ! use run-exes; then
sed -i '/^MimeType/d' loader/wine.desktop || die #117785
fi
# Edit wine.desktop to work for specific variant
sed -e "/^Exec=/s/wine /wine-${WINE_VARIANT} /" -i loader/wine.desktop || die
# hi-res default icon, #472990, https://bugs.winehq.org/show_bug.cgi?id=24652
cp "${PATCHDIR}/files/oic_winlogo.ico" dlls/user32/resources/ || die
l10n_get_locales > po/LINGUAS || die # otherwise wine doesn't respect LINGUAS
# Fix manpage generation for locales #469418 and abi_x86_64 #617864
# Duplicate manpages input files for wine64
local f
for f in loader/*.man.in; do
cp ${f} ${f/wine/wine64} || die
done
# Add wine64 manpages to Makefile
if use abi_x86_64; then
sed -i "/wine.man.in/i \
\\\twine64.man.in \\\\" loader/Makefile.in || die
sed -i -E 's/(.*wine)(.*\.UTF-8\.man\.in.*)/&\
\164\2/' loader/Makefile.in || die
fi
rm_man_file(){
local file="${1}"
loc=${2}
sed -i "/${loc}\.UTF-8\.man\.in/d" "${file}" || die
}
while read f; do
l10n_for_each_disabled_locale_do rm_man_file "${f}"
done < <(find -name "Makefile.in" -exec grep -q "UTF-8.man.in" "{}" \; -print)
}
src_configure() {
wine_compiler_check || die
export LDCONFIG=/bin/true
use custom-cflags || strip-flags
multilib-minimal_src_configure
}
multilib_src_configure() {
local myconf=(
--prefix="${MY_PREFIX}"
--datarootdir="${MY_DATAROOTDIR}"
--datadir="${MY_DATADIR}"
--docdir="${MY_DOCDIR}"
--includedir="${MY_INCLUDEDIR}"
--libdir="${EPREFIX}/usr/$(get_libdir)/wine-${WINE_VARIANT}"
--libexecdir="${MY_LIBEXECDIR}"
--localstatedir="${MY_LOCALSTATEDIR}"
--mandir="${MY_MANDIR}"
--sysconfdir=/etc/wine
$(use_with alsa)
$(use_with capi)
$(use_with lcms cms)
$(use_with cups)
$(use_with ncurses curses)
$(use_with udisks dbus)
$(use_with fontconfig)
$(use_with ssl gnutls)
$(use_enable gecko mshtml)
$(use_with gphoto2 gphoto)
$(use_with gsm)
$(use_with gssapi)
$(use_with gstreamer)
--without-hal
$(use_with jpeg)
$(use_with kerberos krb5)
$(use_with ldap)
$(use_enable mono mscoree)
$(use_with mp3 mpg123)
$(use_with netapi)
$(use_with nls gettext)
$(use_with openal)
$(use_with opencl)
$(use_with opengl)
$(use_with osmesa)
$(use_with oss)
$(use_with pcap)
$(use_with png)
$(use_with pulseaudio pulse)
$(use_with threads pthread)
$(use_with scanner sane)
$(use_with sdl)
$(use_enable test tests)
$(use_with truetype freetype)
$(use_with udev)
$(use_with v4l)
$(use_with vkd3d)
$(use_with vulkan)
$(use_with X x)
$(use_with X xfixes)
$(use_with xcomposite)
$(use_with xinerama)
$(use_with xml)
$(use_with xml xslt)
)
use d3d9 && myconf+=( $(use_with d3d9 d3d9-nine) )
local PKG_CONFIG AR RANLIB
# Avoid crossdev's i686-pc-linux-gnu-pkg-config if building wine32 on amd64; #472038
# set AR and RANLIB to make QA scripts happy; #483342
tc-export PKG_CONFIG AR RANLIB
if use amd64; then
if [[ ${ABI} == amd64 ]]; then
myconf+=( --enable-win64 )
else
myconf+=( --disable-win64 )
fi
# Note: using --with-wine64 results in problems with multilib.eclass
# CC/LD hackery. We're using separate tools instead.
fi
ECONF_SOURCE=${S} \
econf "${myconf[@]}"
emake depend
}
multilib_src_test() {
# FIXME: win32-only; wine64 tests fail with "could not find the Wine loader"
if [[ ${ABI} == x86 ]]; then
if [[ $(id -u) == 0 ]]; then
ewarn "Skipping tests since they cannot be run under the root user."
ewarn "To run the test ${MY_PN} suite, add userpriv to FEATURES in make.conf"
return
fi
WINEPREFIX="${T}/.wine-${ABI}" \
Xemake test
fi
}
multilib_src_install_all() {
local DOCS=( ANNOUNCE AUTHORS README )
add_locale_docs() {
local locale_doc="documentation/README.$1"
[[ ! -e ${locale_doc} ]] || DOCS+=( ${locale_doc} )
}
l10n_for_each_locale_do add_locale_docs
einstalldocs
prune_libtool_files --all
if ! use perl ; then # winedump calls function_grep.pl, and winemaker is a perl script
rm "${D%/}${MY_PREFIX}"/bin/{wine{dump,maker},function_grep.pl} \
"${D%/}${MY_MANDIR}"/man1/wine{dump,maker}.1 || die
fi
# Remove wineconsole if neither backend is installed #551124
if ! use X && ! use ncurses; then
rm "${D%/}${MY_PREFIX}"/bin/wineconsole* || die
rm "${D%/}${MY_MANDIR}"/man1/wineconsole* || die
rm_wineconsole() {
rm "${D%/}${MY_PREFIX}/$(get_libdir)"/wine/{,fakedlls/}wineconsole.exe* || die
}
multilib_foreach_abi rm_wineconsole
fi
use abi_x86_32 && pax-mark psmr "${D%/}${MY_PREFIX}"/bin/wine{,-preloader} #255055
use abi_x86_64 && pax-mark psmr "${D%/}${MY_PREFIX}"/bin/wine64{,-preloader}
if use abi_x86_64 && ! use abi_x86_32; then
dosym wine64 "${MY_PREFIX}"/bin/wine # 404331
dosym wine64-preloader "${MY_PREFIX}"/bin/wine-preloader
fi
# Failglob for binloops, shouldn't be necessary, but including to stay safe
eshopts_push -s failglob #615218
# Make wrappers for binaries for handling multiple variants
# Note: wrappers instead of symlinks because some are shell which use basename
local b
for b in "${D%/}${MY_PREFIX}"/bin/*; do
make_wrapper "${b##*/}-${WINE_VARIANT}" "${MY_PREFIX}/bin/${b##*/}"
done
eshopts_pop
}
pkg_postinst() {
eselect wine register ${P}
if [[ ${PN} == "wine-vanilla" ]]; then
eselect wine register --vanilla ${P} || die
else
if use d3d9; then
eselect wine register --d3d9 ${P} || die
fi
fi
eselect wine update --all --if-unset || die
xdg_desktop_database_update
if ! use gecko; then
ewarn "Without Wine Gecko, wine prefixes will not have a default"
ewarn "implementation of iexplore. Many older windows applications"
ewarn "rely upon the existence of an iexplore implementation, so"
ewarn "you will likely need to install an external one, like via winetricks"
fi
if ! use mono; then
ewarn "Without Wine Mono, wine prefixes will not have a default"
ewarn "implementation of .NET. Many windows applications rely upon"
ewarn "the existence of a .NET implementation, so you will likely need"
ewarn "to install an external one, like via winetricks"
fi
}
pkg_prerm() {
eselect wine deregister ${P}
if [[ ${PN} == "wine-vanilla" ]]; then
eselect wine deregister --vanilla ${P} || die
else
if use d3d9; then
eselect wine deregister --d3d9 ${P} || die
fi
fi
eselect wine update --all --if-unset || die
}
pkg_postrm() {
xdg_desktop_database_update
}

@ -122,7 +122,7 @@ RDEPEND="${COMMON_DEPEND}
!app-emulation/wine:0
dos? ( >=games-emulation/dosbox-0.74_p20160629 )
gecko? ( app-emulation/wine-gecko:2.47[abi_x86_32?,abi_x86_64?] )
mono? ( app-emulation/wine-mono:4.7.1 )
mono? ( app-emulation/wine-mono:4.7.3 )
perl? (
dev-lang/perl
dev-perl/XML-Simple

@ -1,3 +1,4 @@
DIST wine-mono-4.6.4.msi 45592064 BLAKE2B 30099b7f02276e47e350a96af07bf64b43c857b3b3323d0cab85864b753e9810c0d7b5d496e2f53f5b2c3a434eb440a19f9928707c4127303aa0335928e39097 SHA512 1d50df5d4d000998c74fbee79b8ffc691d88ee3b34db9fd7124e0df68d6f84768ece489ac8c3f5f3141c2073c8666b93ae23ca6cd652a6542a821df3d1b66b6d
DIST wine-mono-4.7.0.msi 64625152 BLAKE2B 9c533d9f9a5cec6aefa66ed916e88f0a03ab76e8292f112a669208c5b26855a314657c9950993a205941cd314f0c93a55f621ed71ebb4846a66d30fa9af3c855 SHA512 07cd2b26f3bfe6fc796a126b83e9c0aa655d3e8152af536ae2e8ae419013742706ddae6f93cc2341c94a2f3b8ae7d1b27d12f891d371928189291428f9ed877c
DIST wine-mono-4.7.1.msi 56470528 BLAKE2B b1b9dd832f725cb70b80889c08db524540c389c4eb8c990415f0c1b4a17274fc96390808c943bd0ff42c79f4bbb376b3d599d31ed42b5ebcb4be79dbc273eeec SHA512 d47f21fa3ddb31522366056a2062cf7b77eec0a12f96dc05326561c9d2604405128441ff40d1b9567a6e6cd1c19ee03444d2ba02dd3b8dd2d150030dfb52f765
DIST wine-mono-4.7.3.msi 56470528 BLAKE2B 59397f851bd0883f060fd359228fcdedea5a32ce06349fd563411dfa603a6c8700496111821fd9e571cfd4586e829acb12321528a4a8330d1fb6f92855482225 SHA512 d51c0e21c8448a4d11c3e4fd530bda340cc93cd420080e08aadd7b704183dcadf8553b0937e02c7a54a8a2fb46a395718a3e807b85f19936b0e4ee7b92052dfe

@ -0,0 +1,21 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
DESCRIPTION="Wine Mono is a replacement for the .NET runtime and class libraries in Wine"
HOMEPAGE="https://www.winehq.org/"
SRC_URI="https://dl.winehq.org/wine/${PN}/${PV}/${P}.msi"
LICENSE="BSD-2 GPL-2 LGPL-2.1 MIT MPL-1.1"
SLOT="${PV}"
KEYWORDS="~amd64 ~x86"
DEPEND="!!app-emulation/wine:0"
S="${WORKDIR}"
src_install() {
insinto /usr/share/wine/mono
doins "${DISTDIR}/${P}.msi"
}

@ -0,0 +1,611 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
PLOCALES="ar bg ca cs da de el en en_US eo es fa fi fr he hi hr hu it ja ko lt ml nb_NO nl or pa pl pt_BR pt_PT rm ro ru sk sl sr_RS@cyrillic sr_RS@latin sv te th tr uk wa zh_CN zh_TW"
PLOCALE_BACKUP="en"
inherit autotools estack eutils flag-o-matic gnome2-utils l10n multilib multilib-minimal pax-utils toolchain-funcs virtualx versionator xdg-utils
MY_PN="${PN%%-*}"
MY_P="${MY_PN}-${PV}"
if [[ ${PV} == "9999" ]] ; then
EGIT_REPO_URI="https://source.winehq.org/git/wine.git"
EGIT_BRANCH="master"
inherit git-r3
SRC_URI=""
#KEYWORDS=""
else
MAJOR_V=$(get_version_component_range 1)
SRC_URI="https://dl.winehq.org/wine/source/${MAJOR_V}.x/${MY_P}.tar.xz"
KEYWORDS="-* ~amd64 ~x86 ~x86-fbsd"
fi
S="${WORKDIR}/${MY_P}"
STAGING_P="wine-staging-${PV}"
STAGING_DIR="${WORKDIR}/${STAGING_P}"
GWP_V="20180120"
PATCHDIR="${WORKDIR}/gentoo-wine-patches"
DESCRIPTION="Free implementation of Windows(tm) on Unix, with Wine-Staging patchset"
HOMEPAGE="https://www.winehq.org/"
SRC_URI="${SRC_URI}
https://dev.gentoo.org/~np-hardass/distfiles/wine/gentoo-wine-patches-${GWP_V}.tar.xz
"
if [[ ${PV} == "9999" ]] ; then
STAGING_EGIT_REPO_URI="https://github.com/wine-staging/wine-staging.git"
else
SRC_URI="${SRC_URI}
staging? ( https://github.com/wine-staging/wine-staging/archive/v${PV}.tar.gz -> ${STAGING_P}.tar.gz )"
fi
LICENSE="LGPL-2.1"
SLOT="${PV}"
IUSE="+abi_x86_32 +abi_x86_64 +alsa capi cups custom-cflags dos elibc_glibc ffmpeg +fontconfig +gecko gphoto2 gsm gssapi gstreamer +jpeg kerberos kernel_FreeBSD +lcms ldap +mono mp3 ncurses netapi nls odbc openal opencl +opengl osmesa oss +perl pcap pipelight +png prelink pulseaudio +realtime +run-exes samba scanner sdl selinux +ssl staging test themes +threads +truetype udev +udisks v4l vaapi vkd3d vulkan +X +xcomposite xinerama +xml"
REQUIRED_USE="|| ( abi_x86_32 abi_x86_64 )
X? ( truetype )
elibc_glibc? ( threads )
ffmpeg? ( staging )
osmesa? ( opengl )
pipelight? ( staging )
test? ( abi_x86_32 )
themes? ( staging )
vaapi? ( staging )" # osmesa-opengl #286560 # X-truetype #551124
# FIXME: the test suite is unsuitable for us; many tests require net access
# or fail due to Xvfb's opengl limitations.
RESTRICT="test"
COMMON_DEPEND="
X? (
x11-libs/libXcursor[${MULTILIB_USEDEP}]
x11-libs/libXext[${MULTILIB_USEDEP}]
x11-libs/libXfixes[${MULTILIB_USEDEP}]
x11-libs/libXrandr[${MULTILIB_USEDEP}]
x11-libs/libXi[${MULTILIB_USEDEP}]
x11-libs/libXxf86vm[${MULTILIB_USEDEP}]
)
alsa? ( media-libs/alsa-lib[${MULTILIB_USEDEP}] )
capi? ( net-libs/libcapi[${MULTILIB_USEDEP}] )
cups? ( net-print/cups:=[${MULTILIB_USEDEP}] )
ffmpeg? ( >=media-video/ffmpeg-4:=[${MULTILIB_USEDEP}] )
fontconfig? ( media-libs/fontconfig:=[${MULTILIB_USEDEP}] )
gphoto2? ( media-libs/libgphoto2:=[${MULTILIB_USEDEP}] )
gsm? ( media-sound/gsm:=[${MULTILIB_USEDEP}] )
gssapi? ( virtual/krb5[${MULTILIB_USEDEP}] )
gstreamer? (
media-libs/gstreamer:1.0[${MULTILIB_USEDEP}]
media-plugins/gst-plugins-meta:1.0[${MULTILIB_USEDEP}]
)
jpeg? ( virtual/jpeg:0=[${MULTILIB_USEDEP}] )
kerberos? ( virtual/krb5:0=[${MULTILIB_USEDEP}] )
lcms? ( media-libs/lcms:2=[${MULTILIB_USEDEP}] )
ldap? ( net-nds/openldap:=[${MULTILIB_USEDEP}] )
mp3? ( >=media-sound/mpg123-1.5.0[${MULTILIB_USEDEP}] )
ncurses? ( >=sys-libs/ncurses-5.2:0=[${MULTILIB_USEDEP}] )
netapi? ( net-fs/samba[netapi(+),${MULTILIB_USEDEP}] )
nls? ( sys-devel/gettext[${MULTILIB_USEDEP}] )
odbc? ( dev-db/unixODBC:=[${MULTILIB_USEDEP}] )
openal? ( media-libs/openal:=[${MULTILIB_USEDEP}] )
opencl? ( virtual/opencl[${MULTILIB_USEDEP}] )
opengl? (
virtual/glu[${MULTILIB_USEDEP}]
virtual/opengl[${MULTILIB_USEDEP}]
)
osmesa? ( >=media-libs/mesa-13[osmesa,${MULTILIB_USEDEP}] )
pcap? ( net-libs/libpcap[${MULTILIB_USEDEP}] )
png? ( media-libs/libpng:0=[${MULTILIB_USEDEP}] )
pulseaudio? ( media-sound/pulseaudio[${MULTILIB_USEDEP}] )
scanner? ( media-gfx/sane-backends:=[${MULTILIB_USEDEP}] )
sdl? ( media-libs/libsdl2:=[haptic,joystick,${MULTILIB_USEDEP}] )
ssl? ( net-libs/gnutls:=[${MULTILIB_USEDEP}] )
staging? ( sys-apps/attr[${MULTILIB_USEDEP}] )
themes? (
dev-libs/glib:2[${MULTILIB_USEDEP}]
x11-libs/cairo[${MULTILIB_USEDEP}]
x11-libs/gtk+:3[${MULTILIB_USEDEP}]
)
truetype? ( >=media-libs/freetype-2.0.0[${MULTILIB_USEDEP}] )
udev? ( virtual/libudev:=[${MULTILIB_USEDEP}] )
udisks? ( sys-apps/dbus[${MULTILIB_USEDEP}] )
v4l? ( media-libs/libv4l[${MULTILIB_USEDEP}] )
vaapi? ( x11-libs/libva[X,${MULTILIB_USEDEP}] )
vkd3d? ( app-emulation/vkd3d[${MULTILIB_USEDEP}] )
vulkan? ( media-libs/vulkan-loader[${MULTILIB_USEDEP}] )
xcomposite? ( x11-libs/libXcomposite[${MULTILIB_USEDEP}] )
xinerama? ( x11-libs/libXinerama[${MULTILIB_USEDEP}] )
xml? (
dev-libs/libxml2[${MULTILIB_USEDEP}]
dev-libs/libxslt[${MULTILIB_USEDEP}]
)"
RDEPEND="${COMMON_DEPEND}
app-emulation/wine-desktop-common
>app-eselect/eselect-wine-0.3
!app-emulation/wine:0
dos? ( >=games-emulation/dosbox-0.74_p20160629 )
gecko? ( app-emulation/wine-gecko:2.47[abi_x86_32?,abi_x86_64?] )
mono? ( app-emulation/wine-mono:4.7.3 )
perl? (
dev-lang/perl
dev-perl/XML-Simple
)
pulseaudio? (
realtime? ( sys-auth/rtkit )
)
samba? ( >=net-fs/samba-3.0.25[winbind] )
selinux? ( sec-policy/selinux-wine )
udisks? ( sys-fs/udisks:2 )"
# tools/make_requests requires perl
DEPEND="${COMMON_DEPEND}
sys-devel/flex
>=sys-kernel/linux-headers-2.6
virtual/pkgconfig
virtual/yacc
X? ( x11-base/xorg-proto )
prelink? ( sys-devel/prelink )
staging? (
dev-lang/perl
dev-perl/XML-Simple
)
xinerama? ( x11-base/xorg-proto )"
# These use a non-standard "Wine" category, which is provided by
# /etc/xdg/applications-merged/wine.menu
QA_DESKTOP_FILE="usr/share/applications/wine-browsedrive.desktop
usr/share/applications/wine-notepad.desktop
usr/share/applications/wine-uninstaller.desktop
usr/share/applications/wine-winecfg.desktop"
PATCHES=(
"${PATCHDIR}/patches/${MY_PN}-1.5.26-winegcc.patch" #260726
"${PATCHDIR}/patches/${MY_PN}-1.9.5-multilib-portage.patch" #395615
"${PATCHDIR}/patches/${MY_PN}-1.6-memset-O3.patch" #480508
"${PATCHDIR}/patches/${MY_PN}-2.0-multislot-apploader.patch" #310611
)
PATCHES_BIN=()
# https://bugs.gentoo.org/show_bug.cgi?id=635222
if [[ ${#PATCHES_BIN[@]} -ge 1 ]] || [[ ${PV} == 9999 ]]; then
DEPEND+=" dev-util/patchbin"
fi
wine_compiler_check() {
[[ ${MERGE_TYPE} = "binary" ]] && return 0
# GCC-specific bugs
if tc-is-gcc; then
# bug #549768
if use abi_x86_64 && [[ $(gcc-major-version) = 5 && $(gcc-minor-version) -le 2 ]]; then
ebegin "Checking for gcc-5 ms_abi compiler bug"
$(tc-getCC) -O2 "${PATCHDIR}/files/pr66838.c" -o "${T}"/pr66838 || die
# Run in subshell to prevent "Aborted" message
( "${T}"/pr66838 || false ) >/dev/null 2>&1
if ! eend $?; then
eerror "64-bit wine cannot be built with gcc-5.1 or initial patchset of 5.2.0"
eerror "due to compiler bugs; please re-emerge the latest gcc-5.2.x ebuild,"
eerror "or use gcc-config to select a different compiler version."
eerror "See https://bugs.gentoo.org/549768"
eerror
return 1
fi
fi
# bug #574044
if use abi_x86_64 && [[ $(gcc-major-version) = 5 && $(gcc-minor-version) = 3 ]]; then
ebegin "Checking for gcc-5-3 stack realignment compiler bug"
# Compile in subshell to prevent "Aborted" message
( $(tc-getCC) -O2 -mincoming-stack-boundary=3 "${PATCHDIR}/files/pr69140.c" -o "${T}"/pr69140 ) >/dev/null 2>&1
if ! eend $?; then
eerror "Wine cannot be built with this version of gcc-5.3"
eerror "due to compiler bugs; please re-emerge the latest gcc-5.3.x ebuild,"
eerror "or use gcc-config to select a different compiler version."
eerror "See https://bugs.gentoo.org/574044"
eerror
return 1
fi
fi
fi
# Ensure compiler support
if use abi_x86_64; then
ebegin "Checking for 64-bit compiler with builtin_ms_va_list support"
# Compile in subshell to prevent "Aborted" message
( $(tc-getCC) -O2 "${PATCHDIR}/files/builtin_ms_va_list.c" -o "${T}"/builtin_ms_va_list >/dev/null 2>&1)
if ! eend $?; then
eerror "This version of $(tc-getCC) does not support builtin_ms_va_list, can't enable 64-bit wine"
eerror
eerror "You need gcc-4.4+ or clang 3.8+ to build 64-bit wine"
eerror
return 1
fi
fi
}
wine_build_environment_check() {
[[ ${MERGE_TYPE} = "binary" ]] && return 0
if use abi_x86_64; then
if tc-is-gcc && [[ $(gcc-major-version) -lt 4 || ( $(gcc-major-version) -eq 4 && $(gcc-minor-version) -lt 4 ) ]]; then
eerror "You need gcc-4.4+ to compile 64-bit wine"
die
elif tc-is-clang && [[ $(clang-major-version) -lt 3 || ( $(clang-major-version) -eq 3 && $(clang-minor-version) -lt 8 ) ]]; then
eerror "You need clang-3.8+ to compile 64-bit wine"
die
fi
fi
if tc-is-gcc && [[ $(gcc-major-version) -eq 5 && $(gcc-minor-version) -le 3 ]]; then
ewarn "GCC-5.0-5.3 suffered from compiler bugs and are no longer supported by"
ewarn "Gentoo's Toolchain Team. If your ebuild fails the compiler checks in"
ewarn "the configure phase, either update your compiler or switch to <5.0 || >=5.4"
fi
if tc-is-gcc && [[ $(gcc-major-version) -eq 5 && $(gcc-minor-version) -eq 4 ]]; then
if has "-march=i686" ${CFLAGS} && ! has "-mtune=generic" ${CFLAGS}; then
ewarn "Compilation can hang with CFLAGS=\"-march=i686\". You can temporarily work"
ewarn "around this by adding \"-mtune=generic\" to your CFLAGS for wine."
ewarn "See package.env in man 5 portage for more information on how to do this."
ewarn "See https://bugs.gentoo.org/show_bug.cgi?id=613128 for more details"
fi
fi
if use abi_x86_32 && use opencl && [[ "$(eselect opencl show 2> /dev/null)" == "intel" ]]; then
eerror "You cannot build wine with USE=opencl because intel-ocl-sdk is 64-bit only."
eerror "See https://bugs.gentoo.org/487864 for more details."
eerror
return 1
fi
}
wine_env_vcs_vars() {
local pn_live_var="${PN//[-+]/_}_LIVE_COMMIT"
local pn_live_val="${pn_live_var}"
eval pn_live_val='$'${pn_live_val}
if [[ ! -z ${pn_live_val} ]]; then
if use staging; then
eerror "Because of the multi-repo nature of ${MY_PN}, ${pn_live_var}"
eerror "cannot be used to set the commit. Instead, you may use the"
eerror "environmental variables WINE_COMMIT, and STAGING_COMMIT."
eerror
return 1
fi
fi
if [[ ! -z ${EGIT_COMMIT} ]]; then
eerror "Commits must now be specified using the environmental variables"
eerror "WINE_COMMIT, STAGING_COMMIT, and D3D9_COMMIT"
eerror
return 1
fi
}
pkg_pretend() {
wine_build_environment_check || die
# Verify OSS support
if use oss && ! use kernel_FreeBSD; then
if ! has_version ">=media-sound/oss-4"; then
eerror "You cannot build wine with USE=oss without having support from a"
eerror "FreeBSD kernel or >=media-sound/oss-4 (only available through external repos)"
eerror
die
fi
fi
}
pkg_setup() {
wine_build_environment_check || die
wine_env_vcs_vars || die
WINE_VARIANT="${PN#wine}-${PV}"
WINE_VARIANT="${WINE_VARIANT#-}"
MY_PREFIX="${EPREFIX}/usr/lib/wine-${WINE_VARIANT}"
MY_DATAROOTDIR="${EPREFIX}/usr/share/wine-${WINE_VARIANT}"
MY_DATADIR="${MY_DATAROOTDIR}"
MY_DOCDIR="${EPREFIX}/usr/share/doc/${PF}"
MY_INCLUDEDIR="${EPREFIX}/usr/include/wine-${WINE_VARIANT}"
MY_LIBEXECDIR="${EPREFIX}/usr/libexec/wine-${WINE_VARIANT}"
MY_LOCALSTATEDIR="${EPREFIX}/var/wine-${WINE_VARIANT}"
MY_MANDIR="${MY_DATADIR}/man"
}
src_unpack() {
if [[ ${PV} == "9999" ]] ; then
EGIT_CHECKOUT_DIR="${S}" EGIT_COMMIT="${WINE_COMMIT}" git-r3_src_unpack
if use staging; then
local CURRENT_WINE_COMMIT=${EGIT_VERSION}
git-r3_fetch "${STAGING_EGIT_REPO_URI}" "${STAGING_COMMIT}"
git-r3_checkout "${STAGING_EGIT_REPO_URI}" "${STAGING_DIR}"
local COMPAT_WINE_COMMIT=$("${STAGING_DIR}/patches/patchinstall.sh" --upstream-commit) || die
if [[ "${CURRENT_WINE_COMMIT}" != "${COMPAT_WINE_COMMIT}" ]]; then
einfo "The current Staging patchset is not guaranteed to apply on this WINE commit."
einfo "If src_prepare fails, try emerging with the env var WINE_COMMIT."
einfo "Example: WINE_COMMIT=${COMPAT_WINE_COMMIT} emerge -1 wine"
fi
fi
fi
default
l10n_find_plocales_changes "${S}/po" "" ".po"
}
src_prepare() {
eapply_bin(){
local patch
for patch in ${PATCHES_BIN[@]}; do
patchbin --nogit < "${patch}" || die
done
}
local md5="$(md5sum server/protocol.def)"
if use staging; then
ewarn "Applying the Wine-Staging patchset. Any bug reports to the"
ewarn "Wine bugzilla should explicitly state that staging was used."
local STAGING_EXCLUDE=""
use pipelight || STAGING_EXCLUDE="${STAGING_EXCLUDE} -W Pipelight"
# Launch wine-staging patcher in a subshell, using eapply as a backend, and gitapply.sh as a backend for binary patches
ebegin "Running Wine-Staging patch installer"
(
set -- DESTDIR="${S}" --backend=eapply --no-autoconf --all ${STAGING_EXCLUDE}
cd "${STAGING_DIR}/patches"
source "${STAGING_DIR}/patches/patchinstall.sh"
)
eend $? || die "Failed to apply Wine-Staging patches"
fi
default
eapply_bin
eautoreconf
# Modification of the server protocol requires regenerating the server requests
if [[ "$(md5sum server/protocol.def)" != "${md5}" ]]; then
einfo "server/protocol.def was patched; running tools/make_requests"
tools/make_requests || die #432348
fi
sed -i '/^UPDATE_DESKTOP_DATABASE/s:=.*:=true:' tools/Makefile.in || die
if ! use run-exes; then
sed -i '/^MimeType/d' loader/wine.desktop || die #117785
fi
# Edit wine.desktop to work for specific variant
sed -e "/^Exec=/s/wine /wine-${WINE_VARIANT} /" -i loader/wine.desktop || die
# hi-res default icon, #472990, https://bugs.winehq.org/show_bug.cgi?id=24652
cp "${PATCHDIR}/files/oic_winlogo.ico" dlls/user32/resources/ || die
l10n_get_locales > po/LINGUAS || die # otherwise wine doesn't respect LINGUAS
# Fix manpage generation for locales #469418 and abi_x86_64 #617864
# Duplicate manpages input files for wine64
local f
for f in loader/*.man.in; do
cp ${f} ${f/wine/wine64} || die
done
# Add wine64 manpages to Makefile
if use abi_x86_64; then
sed -i "/wine.man.in/i \
\\\twine64.man.in \\\\" loader/Makefile.in || die
sed -i -E 's/(.*wine)(.*\.UTF-8\.man\.in.*)/&\
\164\2/' loader/Makefile.in || die
fi
rm_man_file(){
local file="${1}"
loc=${2}
sed -i "/${loc}\.UTF-8\.man\.in/d" "${file}" || die
}
while read f; do
l10n_for_each_disabled_locale_do rm_man_file "${f}"
done < <(find -name "Makefile.in" -exec grep -q "UTF-8.man.in" "{}" \; -print)
}
src_configure() {
wine_compiler_check || die
export LDCONFIG=/bin/true
use custom-cflags || strip-flags
multilib-minimal_src_configure
}
multilib_src_configure() {
local myconf=(
--prefix="${MY_PREFIX}"
--datarootdir="${MY_DATAROOTDIR}"
--datadir="${MY_DATADIR}"
--docdir="${MY_DOCDIR}"
--includedir="${MY_INCLUDEDIR}"
--libdir="${EPREFIX}/usr/$(get_libdir)/wine-${WINE_VARIANT}"
--libexecdir="${MY_LIBEXECDIR}"
--localstatedir="${MY_LOCALSTATEDIR}"
--mandir="${MY_MANDIR}"
--sysconfdir=/etc/wine
$(use_with alsa)
$(use_with capi)
$(use_with lcms cms)
$(use_with cups)
$(use_with ncurses curses)
$(use_with udisks dbus)
$(use_with ffmpeg)
$(use_with fontconfig)
$(use_with ssl gnutls)
$(use_enable gecko mshtml)
$(use_with gphoto2 gphoto)
$(use_with gsm)
$(use_with gssapi)
$(use_with gstreamer)
--without-hal
$(use_with jpeg)
$(use_with kerberos krb5)
$(use_with ldap)
$(use_enable mono mscoree)
$(use_with mp3 mpg123)
$(use_with netapi)
$(use_with nls gettext)
$(use_with openal)
$(use_with opencl)
$(use_with opengl)
$(use_with osmesa)
$(use_with oss)
$(use_with pcap)
$(use_with png)
$(use_with pulseaudio pulse)
$(use_with threads pthread)
$(use_with scanner sane)
$(use_with sdl)
$(use_enable test tests)
$(use_with truetype freetype)
$(use_with udev)
$(use_with v4l)
$(use_with vkd3d)
$(use_with vulkan)
$(use_with X x)
$(use_with X xfixes)
$(use_with xcomposite)
$(use_with xinerama)
$(use_with xml)
$(use_with xml xslt)
)
use staging && myconf+=(
--with-xattr
$(use_with themes gtk3)
$(use_with vaapi va)
)
local PKG_CONFIG AR RANLIB
# Avoid crossdev's i686-pc-linux-gnu-pkg-config if building wine32 on amd64; #472038
# set AR and RANLIB to make QA scripts happy; #483342
tc-export PKG_CONFIG AR RANLIB
if use amd64; then
if [[ ${ABI} == amd64 ]]; then
myconf+=( --enable-win64 )
else
myconf+=( --disable-win64 )
fi
# Note: using --with-wine64 results in problems with multilib.eclass
# CC/LD hackery. We're using separate tools instead.
fi
ECONF_SOURCE=${S} \
econf "${myconf[@]}"
emake depend
}
multilib_src_test() {
# FIXME: win32-only; wine64 tests fail with "could not find the Wine loader"
if [[ ${ABI} == x86 ]]; then
if [[ $(id -u) == 0 ]]; then
ewarn "Skipping tests since they cannot be run under the root user."
ewarn "To run the test ${MY_PN} suite, add userpriv to FEATURES in make.conf"
return
fi
WINEPREFIX="${T}/.wine-${ABI}" \
Xemake test
fi
}
multilib_src_install_all() {
local DOCS=( ANNOUNCE AUTHORS README )
add_locale_docs() {
local locale_doc="documentation/README.$1"
[[ ! -e ${locale_doc} ]] || DOCS+=( ${locale_doc} )
}
l10n_for_each_locale_do add_locale_docs
einstalldocs
prune_libtool_files --all
if ! use perl ; then # winedump calls function_grep.pl, and winemaker is a perl script
rm "${D%/}${MY_PREFIX}"/bin/{wine{dump,maker},function_grep.pl} \
"${D%/}${MY_MANDIR}"/man1/wine{dump,maker}.1 || die
fi
# Remove wineconsole if neither backend is installed #551124
if ! use X && ! use ncurses; then
rm "${D%/}${MY_PREFIX}"/bin/wineconsole* || die
rm "${D%/}${MY_MANDIR}"/man1/wineconsole* || die
rm_wineconsole() {
rm "${D%/}${MY_PREFIX}/$(get_libdir)"/wine/{,fakedlls/}wineconsole.exe* || die
}
multilib_foreach_abi rm_wineconsole
fi
use abi_x86_32 && pax-mark psmr "${D%/}${MY_PREFIX}"/bin/wine{,-preloader} #255055
use abi_x86_64 && pax-mark psmr "${D%/}${MY_PREFIX}"/bin/wine64{,-preloader}
if use abi_x86_64 && ! use abi_x86_32; then
dosym wine64 "${MY_PREFIX}"/bin/wine # 404331
dosym wine64-preloader "${MY_PREFIX}"/bin/wine-preloader
fi
# Failglob for binloops, shouldn't be necessary, but including to stay safe
eshopts_push -s failglob #615218
# Make wrappers for binaries for handling multiple variants
# Note: wrappers instead of symlinks because some are shell which use basename
local b
for b in "${D%/}${MY_PREFIX}"/bin/*; do
make_wrapper "${b##*/}-${WINE_VARIANT}" "${MY_PREFIX}/bin/${b##*/}"
done
eshopts_pop
}
pkg_postinst() {
eselect wine register ${P}
if [[ ${PN} == "wine-vanilla" ]]; then
eselect wine register --vanilla ${P} || die
else
if use staging; then
eselect wine register --staging ${P} || die
fi
fi
eselect wine update --all --if-unset || die
xdg_desktop_database_update
if ! use gecko; then
ewarn "Without Wine Gecko, wine prefixes will not have a default"
ewarn "implementation of iexplore. Many older windows applications"
ewarn "rely upon the existence of an iexplore implementation, so"
ewarn "you will likely need to install an external one, like via winetricks"
fi
if ! use mono; then
ewarn "Without Wine Mono, wine prefixes will not have a default"
ewarn "implementation of .NET. Many windows applications rely upon"
ewarn "the existence of a .NET implementation, so you will likely need"
ewarn "to install an external one, like via winetricks"
fi
}
pkg_prerm() {
eselect wine deregister ${P}
if [[ ${PN} == "wine-vanilla" ]]; then
eselect wine deregister --vanilla ${P} || die
else
if use staging; then
eselect wine deregister --staging ${P} || die
fi
fi
eselect wine update --all --if-unset || die
}
pkg_postrm() {
xdg_desktop_database_update
}

@ -128,7 +128,7 @@ RDEPEND="${COMMON_DEPEND}
!app-emulation/wine:0
dos? ( >=games-emulation/dosbox-0.74_p20160629 )
gecko? ( app-emulation/wine-gecko:2.47[abi_x86_32?,abi_x86_64?] )
mono? ( app-emulation/wine-mono:4.7.1 )
mono? ( app-emulation/wine-mono:4.7.3 )
perl? (
dev-lang/perl
dev-perl/XML-Simple

@ -0,0 +1,531 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
PLOCALES="ar bg ca cs da de el en en_US eo es fa fi fr he hi hr hu it ja ko lt ml nb_NO nl or pa pl pt_BR pt_PT rm ro ru sk sl sr_RS@cyrillic sr_RS@latin sv te th tr uk wa zh_CN zh_TW"
PLOCALE_BACKUP="en"
inherit autotools estack eutils flag-o-matic gnome2-utils l10n multilib multilib-minimal pax-utils toolchain-funcs virtualx versionator xdg-utils
MY_PN="${PN%%-*}"
MY_P="${MY_PN}-${PV}"
if [[ ${PV} == "9999" ]] ; then
EGIT_REPO_URI="https://source.winehq.org/git/wine.git"
EGIT_BRANCH="master"
inherit git-r3
SRC_URI=""
#KEYWORDS=""
else
MAJOR_V=$(get_version_component_range 1)
SRC_URI="https://dl.winehq.org/wine/source/${MAJOR_V}.x/${MY_P}.tar.xz"
KEYWORDS="-* ~amd64 ~x86 ~x86-fbsd"
fi
S="${WORKDIR}/${MY_P}"
GWP_V="20180120"
PATCHDIR="${WORKDIR}/gentoo-wine-patches"
DESCRIPTION="Free implementation of Windows(tm) on Unix, without external patchsets"
HOMEPAGE="https://www.winehq.org/"
SRC_URI="${SRC_URI}
https://dev.gentoo.org/~np-hardass/distfiles/wine/gentoo-wine-patches-${GWP_V}.tar.xz
"
LICENSE="LGPL-2.1"
SLOT="${PV}"
IUSE="+abi_x86_32 +abi_x86_64 +alsa capi cups custom-cflags dos elibc_glibc +fontconfig +gecko gphoto2 gsm gssapi gstreamer +jpeg kerberos kernel_FreeBSD +lcms ldap +mono mp3 ncurses netapi nls odbc openal opencl +opengl osmesa oss +perl pcap +png prelink pulseaudio +realtime +run-exes samba scanner sdl selinux +ssl test +threads +truetype udev +udisks v4l vkd3d vulkan +X +xcomposite xinerama +xml"
REQUIRED_USE="|| ( abi_x86_32 abi_x86_64 )
X? ( truetype )
elibc_glibc? ( threads )
osmesa? ( opengl )
test? ( abi_x86_32 )" # osmesa-opengl #286560 # X-truetype #551124
# FIXME: the test suite is unsuitable for us; many tests require net access
# or fail due to Xvfb's opengl limitations.
RESTRICT="test"
COMMON_DEPEND="
X? (
x11-libs/libXcursor[${MULTILIB_USEDEP}]
x11-libs/libXext[${MULTILIB_USEDEP}]
x11-libs/libXfixes[${MULTILIB_USEDEP}]
x11-libs/libXrandr[${MULTILIB_USEDEP}]
x11-libs/libXi[${MULTILIB_USEDEP}]
x11-libs/libXxf86vm[${MULTILIB_USEDEP}]
)
alsa? ( media-libs/alsa-lib[${MULTILIB_USEDEP}] )
capi? ( net-libs/libcapi[${MULTILIB_USEDEP}] )
cups? ( net-print/cups:=[${MULTILIB_USEDEP}] )
fontconfig? ( media-libs/fontconfig:=[${MULTILIB_USEDEP}] )
gphoto2? ( media-libs/libgphoto2:=[${MULTILIB_USEDEP}] )
gsm? ( media-sound/gsm:=[${MULTILIB_USEDEP}] )
gssapi? ( virtual/krb5[${MULTILIB_USEDEP}] )
gstreamer? (
media-libs/gstreamer:1.0[${MULTILIB_USEDEP}]
media-plugins/gst-plugins-meta:1.0[${MULTILIB_USEDEP}]
)
jpeg? ( virtual/jpeg:0=[${MULTILIB_USEDEP}] )
kerberos? ( virtual/krb5[${MULTILIB_USEDEP}] )
lcms? ( media-libs/lcms:2=[${MULTILIB_USEDEP}] )
ldap? ( net-nds/openldap:=[${MULTILIB_USEDEP}] )
mp3? ( >=media-sound/mpg123-1.5.0[${MULTILIB_USEDEP}] )
ncurses? ( >=sys-libs/ncurses-5.2:0=[${MULTILIB_USEDEP}] )
netapi? ( net-fs/samba[netapi(+),${MULTILIB_USEDEP}] )
nls? ( sys-devel/gettext[${MULTILIB_USEDEP}] )
odbc? ( dev-db/unixODBC:=[${MULTILIB_USEDEP}] )
openal? ( media-libs/openal:=[${MULTILIB_USEDEP}] )
opencl? ( virtual/opencl[${MULTILIB_USEDEP}] )
opengl? (
virtual/glu[${MULTILIB_USEDEP}]
virtual/opengl[${MULTILIB_USEDEP}]
)
osmesa? ( >=media-libs/mesa-13[osmesa,${MULTILIB_USEDEP}] )
pcap? ( net-libs/libpcap[${MULTILIB_USEDEP}] )
png? ( media-libs/libpng:0=[${MULTILIB_USEDEP}] )
pulseaudio? ( media-sound/pulseaudio[${MULTILIB_USEDEP}] )
scanner? ( media-gfx/sane-backends:=[${MULTILIB_USEDEP}] )
sdl? ( media-libs/libsdl2:=[haptic,joystick,${MULTILIB_USEDEP}] )
ssl? ( net-libs/gnutls:=[${MULTILIB_USEDEP}] )
truetype? ( >=media-libs/freetype-2.0.0[${MULTILIB_USEDEP}] )
udev? ( virtual/libudev:=[${MULTILIB_USEDEP}] )
udisks? ( sys-apps/dbus[${MULTILIB_USEDEP}] )
v4l? ( media-libs/libv4l[${MULTILIB_USEDEP}] )
vkd3d? ( app-emulation/vkd3d[${MULTILIB_USEDEP}] )
vulkan? ( media-libs/vulkan-loader[${MULTILIB_USEDEP}] )
xcomposite? ( x11-libs/libXcomposite[${MULTILIB_USEDEP}] )
xinerama? ( x11-libs/libXinerama[${MULTILIB_USEDEP}] )
xml? (
dev-libs/libxml2[${MULTILIB_USEDEP}]
dev-libs/libxslt[${MULTILIB_USEDEP}]
)"
RDEPEND="${COMMON_DEPEND}
app-emulation/wine-desktop-common
>app-eselect/eselect-wine-0.3
!app-emulation/wine:0
dos? ( >=games-emulation/dosbox-0.74_p20160629 )
gecko? ( app-emulation/wine-gecko:2.47[abi_x86_32?,abi_x86_64?] )
mono? ( app-emulation/wine-mono:4.7.3 )
perl? (
dev-lang/perl
dev-perl/XML-Simple
)
pulseaudio? (
realtime? ( sys-auth/rtkit )
)
samba? ( >=net-fs/samba-3.0.25[winbind] )
selinux? ( sec-policy/selinux-wine )
udisks? ( sys-fs/udisks:2 )"
# tools/make_requests requires perl
DEPEND="${COMMON_DEPEND}
sys-devel/flex
>=sys-kernel/linux-headers-2.6
virtual/pkgconfig
virtual/yacc
X? ( x11-base/xorg-proto )
prelink? ( sys-devel/prelink )
xinerama? ( x11-base/xorg-proto )"
# These use a non-standard "Wine" category, which is provided by
# /etc/xdg/applications-merged/wine.menu
QA_DESKTOP_FILE="usr/share/applications/wine-browsedrive.desktop
usr/share/applications/wine-notepad.desktop
usr/share/applications/wine-uninstaller.desktop
usr/share/applications/wine-winecfg.desktop"
PATCHES=(
"${PATCHDIR}/patches/${MY_PN}-1.5.26-winegcc.patch" #260726
"${PATCHDIR}/patches/${MY_PN}-1.9.5-multilib-portage.patch" #395615
"${PATCHDIR}/patches/${MY_PN}-1.6-memset-O3.patch" #480508
"${PATCHDIR}/patches/${MY_PN}-2.0-multislot-apploader.patch" #310611
)
PATCHES_BIN=()
# https://bugs.gentoo.org/show_bug.cgi?id=635222
if [[ ${#PATCHES_BIN[@]} -ge 1 ]] || [[ ${PV} == 9999 ]]; then
DEPEND+=" dev-util/patchbin"
fi
wine_compiler_check() {
[[ ${MERGE_TYPE} = "binary" ]] && return 0
# GCC-specific bugs
if tc-is-gcc; then
# bug #549768
if use abi_x86_64 && [[ $(gcc-major-version) = 5 && $(gcc-minor-version) -le 2 ]]; then
ebegin "Checking for gcc-5 ms_abi compiler bug"
$(tc-getCC) -O2 "${PATCHDIR}/files/pr66838.c" -o "${T}"/pr66838 || die
# Run in subshell to prevent "Aborted" message
( "${T}"/pr66838 || false ) >/dev/null 2>&1
if ! eend $?; then
eerror "64-bit wine cannot be built with gcc-5.1 or initial patchset of 5.2.0"
eerror "due to compiler bugs; please re-emerge the latest gcc-5.2.x ebuild,"
eerror "or use gcc-config to select a different compiler version."
eerror "See https://bugs.gentoo.org/549768"
eerror
return 1
fi
fi
# bug #574044
if use abi_x86_64 && [[ $(gcc-major-version) = 5 && $(gcc-minor-version) = 3 ]]; then
ebegin "Checking for gcc-5-3 stack realignment compiler bug"
# Compile in subshell to prevent "Aborted" message
( $(tc-getCC) -O2 -mincoming-stack-boundary=3 "${PATCHDIR}/files/pr69140.c" -o "${T}"/pr69140 ) >/dev/null 2>&1
if ! eend $?; then
eerror "Wine cannot be built with this version of gcc-5.3"
eerror "due to compiler bugs; please re-emerge the latest gcc-5.3.x ebuild,"
eerror "or use gcc-config to select a different compiler version."
eerror "See https://bugs.gentoo.org/574044"
eerror
return 1
fi
fi
fi
# Ensure compiler support
if use abi_x86_64; then
ebegin "Checking for 64-bit compiler with builtin_ms_va_list support"
# Compile in subshell to prevent "Aborted" message
( $(tc-getCC) -O2 "${PATCHDIR}/files/builtin_ms_va_list.c" -o "${T}"/builtin_ms_va_list >/dev/null 2>&1)
if ! eend $?; then
eerror "This version of $(tc-getCC) does not support builtin_ms_va_list, can't enable 64-bit wine"
eerror
eerror "You need gcc-4.4+ or clang 3.8+ to build 64-bit wine"
eerror
return 1
fi
fi
}
wine_build_environment_check() {
[[ ${MERGE_TYPE} = "binary" ]] && return 0
if use abi_x86_64; then
if tc-is-gcc && [[ $(gcc-major-version) -lt 4 || ( $(gcc-major-version) -eq 4 && $(gcc-minor-version) -lt 4 ) ]]; then
eerror "You need gcc-4.4+ to compile 64-bit wine"
die
elif tc-is-clang && [[ $(clang-major-version) -lt 3 || ( $(clang-major-version) -eq 3 && $(clang-minor-version) -lt 8 ) ]]; then
eerror "You need clang-3.8+ to compile 64-bit wine"
die
fi
fi
if tc-is-gcc && [[ $(gcc-major-version) -eq 5 && $(gcc-minor-version) -le 3 ]]; then
ewarn "GCC-5.0-5.3 suffered from compiler bugs and are no longer supported by"
ewarn "Gentoo's Toolchain Team. If your ebuild fails the compiler checks in"
ewarn "the configure phase, either update your compiler or switch to <5.0 || >=5.4"
fi
if tc-is-gcc && [[ $(gcc-major-version) -eq 5 && $(gcc-minor-version) -eq 4 ]]; then
if has "-march=i686" ${CFLAGS} && ! has "-mtune=generic" ${CFLAGS}; then
ewarn "Compilation can hang with CFLAGS=\"-march=i686\". You can temporarily work"
ewarn "around this by adding \"-mtune=generic\" to your CFLAGS for wine."
ewarn "See package.env in man 5 portage for more information on how to do this."
ewarn "See https://bugs.gentoo.org/show_bug.cgi?id=613128 for more details"
fi
fi
if use abi_x86_32 && use opencl && [[ "$(eselect opencl show 2> /dev/null)" == "intel" ]]; then
eerror "You cannot build wine with USE=opencl because intel-ocl-sdk is 64-bit only."
eerror "See https://bugs.gentoo.org/487864 for more details."
eerror
return 1
fi
}
wine_env_vcs_vars() {
local pn_live_var="${PN//[-+]/_}_LIVE_COMMIT"
local pn_live_val="${pn_live_var}"
eval pn_live_val='$'${pn_live_val}
if [[ ! -z ${EGIT_COMMIT} ]]; then
eerror "Commits must now be specified using the environmental variables"
eerror "WINE_COMMIT"
eerror
return 1
fi
}
pkg_pretend() {
wine_build_environment_check || die
# Verify OSS support
if use oss && ! use kernel_FreeBSD; then
if ! has_version ">=media-sound/oss-4"; then
eerror "You cannot build wine with USE=oss without having support from a"
eerror "FreeBSD kernel or >=media-sound/oss-4 (only available through external repos)"
eerror
die
fi
fi
}
pkg_setup() {
wine_build_environment_check || die
wine_env_vcs_vars || die
WINE_VARIANT="${PN#wine}-${PV}"
WINE_VARIANT="${WINE_VARIANT#-}"
MY_PREFIX="${EPREFIX}/usr/lib/wine-${WINE_VARIANT}"
MY_DATAROOTDIR="${EPREFIX}/usr/share/wine-${WINE_VARIANT}"
MY_DATADIR="${MY_DATAROOTDIR}"
MY_DOCDIR="${EPREFIX}/usr/share/doc/${PF}"
MY_INCLUDEDIR="${EPREFIX}/usr/include/wine-${WINE_VARIANT}"
MY_LIBEXECDIR="${EPREFIX}/usr/libexec/wine-${WINE_VARIANT}"
MY_LOCALSTATEDIR="${EPREFIX}/var/wine-${WINE_VARIANT}"
MY_MANDIR="${MY_DATADIR}/man"
}
src_unpack() {
if [[ ${PV} == "9999" ]] ; then
EGIT_CHECKOUT_DIR="${S}" EGIT_COMMIT="${WINE_COMMIT}" git-r3_src_unpack
fi
default
l10n_find_plocales_changes "${S}/po" "" ".po"
}
src_prepare() {
eapply_bin(){
local patch
for patch in ${PATCHES_BIN[@]}; do
patchbin --nogit < "${patch}" || die
done
}
local md5="$(md5sum server/protocol.def)"
default
eapply_bin
eautoreconf
# Modification of the server protocol requires regenerating the server requests
if [[ "$(md5sum server/protocol.def)" != "${md5}" ]]; then
einfo "server/protocol.def was patched; running tools/make_requests"
tools/make_requests || die #432348
fi
sed -i '/^UPDATE_DESKTOP_DATABASE/s:=.*:=true:' tools/Makefile.in || die
if ! use run-exes; then
sed -i '/^MimeType/d' loader/wine.desktop || die #117785
fi
# Edit wine.desktop to work for specific variant
sed -e "/^Exec=/s/wine /wine-${WINE_VARIANT} /" -i loader/wine.desktop || die
# hi-res default icon, #472990, https://bugs.winehq.org/show_bug.cgi?id=24652
cp "${PATCHDIR}/files/oic_winlogo.ico" dlls/user32/resources/ || die
l10n_get_locales > po/LINGUAS || die # otherwise wine doesn't respect LINGUAS
# Fix manpage generation for locales #469418 and abi_x86_64 #617864
# Duplicate manpages input files for wine64
local f
for f in loader/*.man.in; do
cp ${f} ${f/wine/wine64} || die
done
# Add wine64 manpages to Makefile
if use abi_x86_64; then
sed -i "/wine.man.in/i \
\\\twine64.man.in \\\\" loader/Makefile.in || die
sed -i -E 's/(.*wine)(.*\.UTF-8\.man\.in.*)/&\
\164\2/' loader/Makefile.in || die
fi
rm_man_file(){
local file="${1}"
loc=${2}
sed -i "/${loc}\.UTF-8\.man\.in/d" "${file}" || die
}
while read f; do
l10n_for_each_disabled_locale_do rm_man_file "${f}"
done < <(find -name "Makefile.in" -exec grep -q "UTF-8.man.in" "{}" \; -print)
}
src_configure() {
wine_compiler_check || die
export LDCONFIG=/bin/true
use custom-cflags || strip-flags
multilib-minimal_src_configure
}
multilib_src_configure() {
local myconf=(
--prefix="${MY_PREFIX}"
--datarootdir="${MY_DATAROOTDIR}"
--datadir="${MY_DATADIR}"
--docdir="${MY_DOCDIR}"
--includedir="${MY_INCLUDEDIR}"
--libdir="${EPREFIX}/usr/$(get_libdir)/wine-${WINE_VARIANT}"
--libexecdir="${MY_LIBEXECDIR}"
--localstatedir="${MY_LOCALSTATEDIR}"
--mandir="${MY_MANDIR}"
--sysconfdir=/etc/wine
$(use_with alsa)
$(use_with capi)
$(use_with lcms cms)
$(use_with cups)
$(use_with ncurses curses)
$(use_with udisks dbus)
$(use_with fontconfig)
$(use_with ssl gnutls)
$(use_enable gecko mshtml)
$(use_with gphoto2 gphoto)
$(use_with gsm)
$(use_with gssapi)
$(use_with gstreamer)
--without-hal
$(use_with jpeg)
$(use_with kerberos krb5)
$(use_with ldap)
$(use_enable mono mscoree)
$(use_with mp3 mpg123)
$(use_with netapi)
$(use_with nls gettext)
$(use_with openal)
$(use_with opencl)
$(use_with opengl)
$(use_with osmesa)
$(use_with oss)
$(use_with pcap)
$(use_with png)
$(use_with pulseaudio pulse)
$(use_with threads pthread)
$(use_with scanner sane)
$(use_with sdl)
$(use_enable test tests)
$(use_with truetype freetype)
$(use_with udev)
$(use_with v4l)
$(use_with vkd3d)
$(use_with vulkan)
$(use_with X x)
$(use_with X xfixes)
$(use_with xcomposite)
$(use_with xinerama)
$(use_with xml)
$(use_with xml xslt)
)
local PKG_CONFIG AR RANLIB
# Avoid crossdev's i686-pc-linux-gnu-pkg-config if building wine32 on amd64; #472038
# set AR and RANLIB to make QA scripts happy; #483342
tc-export PKG_CONFIG AR RANLIB
if use amd64; then
if [[ ${ABI} == amd64 ]]; then
myconf+=( --enable-win64 )
else
myconf+=( --disable-win64 )
fi
# Note: using --with-wine64 results in problems with multilib.eclass
# CC/LD hackery. We're using separate tools instead.
fi
ECONF_SOURCE=${S} \
econf "${myconf[@]}"
emake depend
}
multilib_src_test() {
# FIXME: win32-only; wine64 tests fail with "could not find the Wine loader"
if [[ ${ABI} == x86 ]]; then
if [[ $(id -u) == 0 ]]; then
ewarn "Skipping tests since they cannot be run under the root user."
ewarn "To run the test ${MY_PN} suite, add userpriv to FEATURES in make.conf"
return
fi
WINEPREFIX="${T}/.wine-${ABI}" \
Xemake test
fi
}
multilib_src_install_all() {
local DOCS=( ANNOUNCE AUTHORS README )
add_locale_docs() {
local locale_doc="documentation/README.$1"
[[ ! -e ${locale_doc} ]] || DOCS+=( ${locale_doc} )
}
l10n_for_each_locale_do add_locale_docs
einstalldocs
prune_libtool_files --all
if ! use perl ; then # winedump calls function_grep.pl, and winemaker is a perl script
rm "${D%/}${MY_PREFIX}"/bin/{wine{dump,maker},function_grep.pl} \
"${D%/}${MY_MANDIR}"/man1/wine{dump,maker}.1 || die
fi
# Remove wineconsole if neither backend is installed #551124
if ! use X && ! use ncurses; then
rm "${D%/}${MY_PREFIX}"/bin/wineconsole* || die
rm "${D%/}${MY_MANDIR}"/man1/wineconsole* || die
rm_wineconsole() {
rm "${D%/}${MY_PREFIX}/$(get_libdir)"/wine/{,fakedlls/}wineconsole.exe* || die
}
multilib_foreach_abi rm_wineconsole
fi
use abi_x86_32 && pax-mark psmr "${D%/}${MY_PREFIX}"/bin/wine{,-preloader} #255055
use abi_x86_64 && pax-mark psmr "${D%/}${MY_PREFIX}"/bin/wine64{,-preloader}
if use abi_x86_64 && ! use abi_x86_32; then
dosym wine64 "${MY_PREFIX}"/bin/wine # 404331
dosym wine64-preloader "${MY_PREFIX}"/bin/wine-preloader
fi
# Failglob for binloops, shouldn't be necessary, but including to stay safe
eshopts_push -s failglob #615218
# Make wrappers for binaries for handling multiple variants
# Note: wrappers instead of symlinks because some are shell which use basename
local b
for b in "${D%/}${MY_PREFIX}"/bin/*; do
make_wrapper "${b##*/}-${WINE_VARIANT}" "${MY_PREFIX}/bin/${b##*/}"
done
eshopts_pop
}
pkg_postinst() {
eselect wine register ${P}
if [[ ${PN} == "wine-vanilla" ]]; then
eselect wine register --vanilla ${P} || die
fi
eselect wine update --all --if-unset || die
xdg_desktop_database_update
if ! use gecko; then
ewarn "Without Wine Gecko, wine prefixes will not have a default"
ewarn "implementation of iexplore. Many older windows applications"
ewarn "rely upon the existence of an iexplore implementation, so"
ewarn "you will likely need to install an external one, like via winetricks"
fi
if ! use mono; then
ewarn "Without Wine Mono, wine prefixes will not have a default"
ewarn "implementation of .NET. Many windows applications rely upon"
ewarn "the existence of a .NET implementation, so you will likely need"
ewarn "to install an external one, like via winetricks"
fi
}
pkg_prerm() {
eselect wine deregister ${P}
if [[ ${PN} == "wine-vanilla" ]]; then
eselect wine deregister --vanilla ${P} || die
fi
eselect wine update --all --if-unset || die
}
pkg_postrm() {
xdg_desktop_database_update
}

@ -107,7 +107,7 @@ RDEPEND="${COMMON_DEPEND}
!app-emulation/wine:0
dos? ( >=games-emulation/dosbox-0.74_p20160629 )
gecko? ( app-emulation/wine-gecko:2.47[abi_x86_32?,abi_x86_64?] )
mono? ( app-emulation/wine-mono:4.7.1 )
mono? ( app-emulation/wine-mono:4.7.3 )
perl? (
dev-lang/perl
dev-perl/XML-Simple

Binary file not shown.

@ -12,7 +12,7 @@ DESCRIPTION="GUI gettext translations editor"
HOMEPAGE="https://poedit.net"
SRC_URI="https://github.com/vslavik/${PN}/releases/download/v${PV}-oss/${P}.tar.gz"
KEYWORDS="~amd64 ~hppa ~ppc ~ppc64 ~sparc ~x86"
KEYWORDS="~amd64 ~hppa ~ppc ~ppc64 sparc ~x86"
LICENSE="MIT"
SLOT="0"

Binary file not shown.

@ -27,7 +27,7 @@ COMMON_DEPEND=">=dev-libs/boost-1.62
dev-qt/qtx11extras:5
dev-qt/qtconcurrent:5
dev-qt/linguist-tools:5
qwt? ( x11-libs/qwt:6[qt5] )"
qwt? ( x11-libs/qwt:6 )"
DEPEND="${COMMON_DEPEND}
doc? ( app-doc/doxygen )"
RDEPEND="${COMMON_DEPEND}

Binary file not shown.

@ -1,2 +1 @@
DIST collectd-5.7.2.tar.bz2 1798777 BLAKE2B 4af359a773457bb9c05b6a301d7728eea7598c200f7ca534875b07d1d011b280ab138f680d9607723f14523dd71dcbec3a41e0d8d183848c8ef809cef86c2b8f SHA512 8844b67159f8da2203b5ac57ef19fce0a01050a016174d196b48b5fb24925ad2935af9bdd9af06097ff663499abc496cdcc2d9e9a10f403f8d707c465c1a88f3
DIST collectd-5.8.0.tar.bz2 1686017 BLAKE2B 26d995cdb9c25869bf96a056e6ba879de9f009fd4bbf1364a7dedba93b822e57c4b606ca8c84da68cc29db8e77333047695e85d7eb101080de9cee783240f5ea SHA512 1b3d0cc44e2ca54e13eebf292074f1efa8b33d6800d04405e0eaaa2dd1cb2416c6eae580729fb5aead23a5039f41ffe8a9989a907a8c18be8f867f1099fc0008

@ -1,548 +0,0 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI="6"
PYTHON_COMPAT=( python{2_7,3_4,3_5,3_6} )
JAVA_PKG_OPT_USE="collectd_plugins_java"
inherit autotools fcaps flag-o-matic java-pkg-opt-2 linux-info multilib perl-functions python-single-r1 systemd tmpfiles user
DESCRIPTION="Collects system statistics and provides mechanisms to store the values"
HOMEPAGE="https://collectd.org/"
SRC_URI="${HOMEPAGE%/}/files/${P}.tar.bz2"
LICENSE="GPL-2"
SLOT="0"
KEYWORDS="alpha amd64 arm x86"
IUSE="contrib debug java kernel_Darwin kernel_FreeBSD kernel_linux perl selinux static-libs udev xfs"
# The plugin lists have to follow here since they extend IUSE
# Plugins that don't build (e.g. dependencies not in Gentoo)
# apple_sensors: Requires libIOKit
# aquaero: Requires aerotools-ng/libaquaero5
# barometer: Requires libi2c (i2c_smbus_read_i2c_block_data)
# dpdkstat: Requires dpdk
# grpc: Requires libgrpc
# intel_rdt Requires libpqos from intel-cmt-cat project
# lpar: Requires libperfstat (AIX only)
# mic: Requires Intel Many Integrated Core Architecture API
# (part of Intel's Xeon Phi software)
# netapp: Requires libnetapp (http://communities.netapp.com/docs/DOC-1110)
# pf: Requires BSD packet filter
# pinba: Requires MySQL Pinba engine (http://pinba.org/)
# tape: Requires libkstat (Solaris only)
# write_mongodb: https://github.com/collectd/collectd/issues/492
# write_riemann: Requires riemann-c-client
# xmms: Requires libxmms (v1)
# zone: Solaris only...
COLLECTD_IMPOSSIBLE_PLUGINS="apple_sensors aquaero barometer dpdkstat grpc
intel_rdt lpar mic netapp pf pinba tape write_mongodb
write_riemann xmms zone"
# Plugins that have been (compile) tested and can be enabled via COLLECTD_PLUGINS
COLLECTD_TESTED_PLUGINS="aggregation amqp apache apcups ascent battery bind
ceph cgroups chrony conntrack contextswitch cpu cpufreq cpusleep
csv curl curl_json curl_xml dbi df disk dns drbd email
entropy ethstat exec fhcount filecount fscache gmond gps hddtemp
hugepages interface ipc ipmi iptables ipvs irq java lua
load logfile log_logstash lvm madwifi match_empty_counter
match_hashed match_regex match_timediff match_value mbmon md
memcachec memcached memory modbus mqtt multimeter mysql netlink
network network nfs nginx notify_desktop notify_email notify_nagios
ntpd numa nut olsrd onewire openldap openvpn oracle perl ping
postgresql powerdns processes protocols python python redis
routeros rrdcached rrdtool sensors serial sigrok smart snmp statsd
swap syslog table tail tail_csv target_notification target_replace
target_scale target_set tcpconns teamspeak2 ted thermal threshold
tokyotyrant turbostat unixsock uptime users uuid varnish virt
vmem vserver wireless write_graphite write_http write_kafka
write_log write_prometheus write_redis write_sensu write_tsdb
xencpu zfs_arc zookeeper"
COLLECTD_DISABLED_PLUGINS="${COLLECTD_IMPOSSIBLE_PLUGINS}"
COLLECTD_ALL_PLUGINS=${COLLECTD_TESTED_PLUGINS}
for plugin in ${COLLECTD_ALL_PLUGINS}; do
IUSE="${IUSE} collectd_plugins_${plugin}"
done
unset plugin
# Now come the dependencies.
COMMON_DEPEND="
dev-libs/libgcrypt:=
dev-libs/libltdl:0=
perl? ( dev-lang/perl:=[ithreads] )
udev? ( virtual/udev )
xfs? ( sys-fs/xfsprogs )
collectd_plugins_amqp? ( net-libs/rabbitmq-c )
collectd_plugins_apache? ( net-misc/curl:0= )
collectd_plugins_ascent? ( net-misc/curl:0= dev-libs/libxml2:2= )
collectd_plugins_bind? ( net-misc/curl:0= dev-libs/libxml2:2= )
collectd_plugins_ceph? ( dev-libs/yajl:= )
collectd_plugins_curl? ( net-misc/curl:0= )
collectd_plugins_curl_json? ( net-misc/curl:0= dev-libs/yajl:= )
collectd_plugins_curl_xml? ( net-misc/curl:0= dev-libs/libxml2:2= )
collectd_plugins_dbi? ( dev-db/libdbi )
collectd_plugins_dns? ( net-libs/libpcap )
collectd_plugins_gmond? ( sys-cluster/ganglia )
collectd_plugins_gps? ( sci-geosciences/gpsd:= )
collectd_plugins_ipmi? ( >=sys-libs/openipmi-2.0.16-r1 )
collectd_plugins_iptables? ( >=net-firewall/iptables-1.4.13:0= )
collectd_plugins_log_logstash? ( dev-libs/yajl:= )
collectd_plugins_lua? ( dev-lang/lua:0= )
collectd_plugins_lvm? ( sys-fs/lvm2 )
collectd_plugins_memcachec? ( dev-libs/libmemcached )
collectd_plugins_modbus? ( dev-libs/libmodbus )
collectd_plugins_mqtt? ( app-misc/mosquitto )
collectd_plugins_mysql? ( virtual/libmysqlclient:= )
collectd_plugins_netlink? ( net-libs/libmnl )
collectd_plugins_nginx? ( net-misc/curl:0= )
collectd_plugins_notify_desktop? ( x11-libs/libnotify )
collectd_plugins_notify_email? ( net-libs/libesmtp )
collectd_plugins_nut? ( >=sys-power/nut-2.7.2-r2 )
collectd_plugins_openldap? ( net-nds/openldap )
collectd_plugins_onewire? ( >=sys-fs/owfs-3.1:= )
collectd_plugins_oracle? ( dev-db/oracle-instantclient-basic )
collectd_plugins_perl? ( dev-lang/perl:=[ithreads] )
collectd_plugins_ping? ( net-libs/liboping )
collectd_plugins_postgresql? ( dev-db/postgresql:= )
collectd_plugins_python? ( ${PYTHON_DEPS} )
collectd_plugins_redis? ( dev-libs/hiredis:= )
collectd_plugins_routeros? ( net-libs/librouteros )
collectd_plugins_rrdcached? ( net-analyzer/rrdtool:= )
collectd_plugins_rrdtool? ( net-analyzer/rrdtool:= )
collectd_plugins_sensors? ( sys-apps/lm_sensors )
collectd_plugins_sigrok? ( <sci-libs/libsigrok-0.4:= dev-libs/glib:2 )
collectd_plugins_smart? ( dev-libs/libatasmart )
collectd_plugins_snmp? ( net-analyzer/net-snmp )
collectd_plugins_tokyotyrant? ( net-misc/tokyotyrant )
collectd_plugins_varnish? ( www-servers/varnish )
collectd_plugins_virt? ( app-emulation/libvirt:= dev-libs/libxml2:2= )
collectd_plugins_write_http? ( net-misc/curl:0= dev-libs/yajl:= )
collectd_plugins_write_kafka? ( >=dev-libs/librdkafka-0.9.0.99:= dev-libs/yajl:= )
collectd_plugins_write_prometheus? ( >=dev-libs/protobuf-c-1.2.1-r1:= net-libs/libmicrohttpd:= )
collectd_plugins_write_redis? ( dev-libs/hiredis:= )
collectd_plugins_xencpu? ( app-emulation/xen-tools:= )
kernel_FreeBSD? (
collectd_plugins_disk? ( sys-libs/libstatgrab:= )
collectd_plugins_interface? ( sys-libs/libstatgrab:= )
collectd_plugins_load? ( sys-libs/libstatgrab:= )
collectd_plugins_memory? ( sys-libs/libstatgrab:= )
collectd_plugins_swap? ( sys-libs/libstatgrab:= )
collectd_plugins_users? ( sys-libs/libstatgrab:= )
)"
# Enforcing !=sys-kernel/linux-headers-4.5 > due to #577846
DEPEND="${COMMON_DEPEND}
collectd_plugins_iptables? ( || ( <=sys-kernel/linux-headers-4.4 >=sys-kernel/linux-headers-4.6 ) )
collectd_plugins_java? ( >=virtual/jdk-1.6 )
virtual/pkgconfig"
RDEPEND="${COMMON_DEPEND}
collectd_plugins_java? ( >=virtual/jre-1.6 )
collectd_plugins_syslog? ( virtual/logger )
selinux? ( sec-policy/selinux-collectd )
!<sys-apps/openrc-0.18.2"
REQUIRED_USE="
collectd_plugins_python? ( ${PYTHON_REQUIRED_USE} )
collectd_plugins_smart? ( udev )"
PATCHES=(
"${FILESDIR}"/${PN}-5.6.0-gentoo.patch
"${FILESDIR}"/${PN}-5.7.2-issue-2443.patch
"${FILESDIR}"/${PN}-5.7.2-CVE-2017-16820.patch
"${FILESDIR}"/${PN}-5.7.2-varnish-5.2+.patch
)
# @FUNCTION: collectd_plugin_kernel_linux
# @DESCRIPTION:
# USAGE: <plugin name> <kernel_options> <severity>
# kernel_options is a list of kernel configurations options; the check tests whether at least
# one of them is enabled. If no, depending on the third argument an elog, ewarn, or eerror message
# is emitted.
collectd_plugin_kernel_linux() {
local multi_opt opt
if has ${1} ${COLLECTD_ALL_PLUGINS}; then
if use collectd_plugins_${1}; then
for opt in ${2}; do
if linux_chkconfig_present ${opt}; then
return 0;
fi
done
multi_opt=${2//\ /\ or\ }
case ${3} in
(info)
elog "The ${1} plugin can use kernel features that are disabled now; enable ${multi_opt} in your kernel"
;;
(warn)
ewarn "The ${1} plugin uses kernel features that are disabled now; enable ${multi_opt} in your kernel"
;;
(error)
eerror "The ${1} plugin needs kernel features that are disabled now; enable ${multi_opt} in your kernel"
;;
(*)
die "function collectd_plugin_kernel_linux called with invalid third argument"
;;
esac
fi
fi
}
collectd_linux_kernel_checks() {
if ! linux_chkconfig_present PROC_FS; then
ewarn "/proc file system support is disabled, many plugins will not be able to read any statistics from your system unless you enable PROC_FS in your kernel"
fi
if ! linux_chkconfig_present SYSFS; then
ewarn "/sys file system support is disabled, many plugins will not be able to read any statistics from your system unless you enable SYSFS in your kernel"
fi
# battery.c: /proc/pmu/battery_%i
# battery.c: /proc/acpi/battery
collectd_plugin_kernel_linux battery ACPI_BATTERY warn
# cgroups.c: /sys/fs/cgroup/
collectd_plugin_kernel_linux cgroups CGROUPS warn
# cpufreq.c: /sys/devices/system/cpu/cpu%d/cpufreq/
collectd_plugin_kernel_linux cpufreq SYSFS warn
collectd_plugin_kernel_linux cpufreq CPU_FREQ_STAT warn
# drbd.c: /proc/drbd
collectd_plugin_kernel_linux drbd BLK_DEV_DRBD warn
# conntrack.c: /proc/sys/net/netfilter/*
collectd_plugin_kernel_linux conntrack NETFILTER warn
# fscache.c: /proc/fs/fscache/stats
collectd_plugin_kernel_linux fscache FSCACHE warn
# nfs.c: /proc/net/rpc/nfs
# nfs.c: /proc/net/rpc/nfsd
collectd_plugin_kernel_linux nfs NFS_COMMON warn
# serial.c: /proc/tty/driver/serial
# serial.c: /proc/tty/driver/ttyS
collectd_plugin_kernel_linux serial SERIAL_CORE warn
# swap.c: /proc/meminfo
collectd_plugin_kernel_linux swap SWAP warn
# thermal.c: /proc/acpi/thermal_zone
# thermal.c: /sys/class/thermal
collectd_plugin_kernel_linux thermal ACPI_THERMAL warn
# turbostat.c: /dev/cpu/%d/msr
collectd_plugin_kernel_linux turbostat X86_MSR warn
# vmem.c: /proc/vmstat
collectd_plugin_kernel_linux vmem VM_EVENT_COUNTERS warn
# vserver.c: /proc/virtual
collectd_plugin_kernel_linux vserver VSERVER warn
# uuid.c: /sys/hypervisor/uuid
collectd_plugin_kernel_linux uuid SYSFS info
# wireless.c: /proc/net/wireless
collectd_plugin_kernel_linux wireless "WIRELESS MAC80211 IEEE80211" warn
# zfs_arc.c: /proc/spl/kstat/zfs/arcstats
collectd_plugin_kernel_linux zfs_arc "SPL ZFS" warn
}
pkg_setup() {
if use kernel_linux; then
linux-info_pkg_setup
if linux_config_exists; then
einfo "Checking your linux kernel configuration:"
collectd_linux_kernel_checks
else
elog "Cannot find a linux kernel configuration. Continuing anyway."
fi
fi
if use collectd_plugins_java; then
java-pkg-opt-2_pkg_setup
fi
use collectd_plugins_python && python-single-r1_pkg_setup
enewgroup collectd
enewuser collectd -1 -1 /var/lib/collectd collectd
}
src_prepare() {
default
# There's some strange prefix handling in the default config file, resulting in
# paths like "/usr/var/..."
sed -i -e "s:@prefix@/var:/var:g" src/collectd.conf.in || die
# fix installdirs for perl, bug 444360
sed -i -e 's/INSTALL_BASE=$(DESTDIR)$(prefix) //' bindings/Makefile.am || die
# Adjust upstream's systemd unit
# - Get rid of EnvironmentFile directive; These files don't exist on Gentoo!
# - Add User=collectd to run collectd as user "collectd" per default
sed -i \
-e '/^EnvironmentFile=.*/d' \
-e '/^\[Service\]/aUser=collectd' \
contrib/systemd.${PN}.service || die
if use collectd_plugins_java; then
# Set javac -source and -target flags according to (R)DEPEND.
sed -i -e "s/\$(JAVAC)/\0 $(java-pkg_javac-args)/g" bindings/java/Makefile.am || die
fi
ebegin "Removing bundled libltdl"
rm -rf libltdl || die
eend 0
eautoreconf
}
src_configure() {
# Now come the lists of os-dependent plugins. Any plugin that is not listed anywhere here
# should work independent of the operating system.
local linux_plugins="barometer battery cpu cpufreq disk
drbd entropy ethstat hugepages interface iptables
ipvs irq ipc load memory md netlink nfs numa processes
serial swap tcpconns thermal turbostat users vmem wireless
zfc_arc"
local need_libstatgrab=0
local libstatgrab_plugins="cpu disk interface load memory swap users"
local bsd_plugins="cpu tcpconns ${libstatgrab_plugins} zfc_arc"
local darwin_plugins="apple_sensors battery cpu disk interface memory processes tcpconns"
local osdependent_plugins="${linux_plugins} ${bsd_plugins} ${darwin_plugins}"
local myos_plugins=""
if use kernel_linux; then
einfo "Enabling Linux plugins."
myos_plugins=${linux_plugins}
elif use kernel_FreeBSD; then
einfo "Enabling FreeBSD plugins."
myos_plugins=${bsd_plugins}
elif use kernel_Darwin; then
einfo "Enabling Darwin plugins."
myos_plugins=${darwin_plugins}
fi
local myconf="--disable-werror"
# Do we debug?
myconf+=" $(use_enable debug)"
# udev support?
# Required for smart plugin via REQUIRED_USE; Optional for disk plugin
if use udev; then
myconf+=" --with-libudev"
else
myconf+=" --without-libudev"
fi
local plugin
# Disable what needs to be disabled.
for plugin in ${COLLECTD_DISABLED_PLUGINS}; do
myconf+=" --disable-${plugin}"
done
# Set enable/disable for each single plugin.
for plugin in ${COLLECTD_ALL_PLUGINS}; do
if has ${plugin} ${osdependent_plugins}; then
# plugin is os-dependent ...
if has ${plugin} ${myos_plugins}; then
# ... and available in this os
myconf+=" $(use_enable collectd_plugins_${plugin} ${plugin})"
# ... must we link against libstatgrab? Bug #541518
if use kernel_FreeBSD && has ${plugin} ${libstatgrab_plugins}; then
einfo "We must link against libstatgrab due to plugin \"${plugin}\" ..."
need_libstatgrab=1
fi
else
# ... and NOT available in this os
if use collectd_plugins_${plugin}; then
ewarn "You try to enable the ${plugin} plugin, but it is not available for this"
ewarn "kernel. Disabling it automatically."
fi
myconf+=" --disable-${plugin}"
fi
elif [[ "${plugin}" = "collectd_plugins_perl" ]]; then
if use collectd_plugins_perl && ! use perl; then
ewarn "Perl plugin disabled as perl bindings disabled by -perl use flag"
myconf+= --disable-perl
else
myconf+=" $(use_enable collectd_plugins_${plugin} ${plugin})"
fi
else
myconf+=" $(use_enable collectd_plugins_${plugin} ${plugin})"
fi
done
if [ "${need_libstatgrab}" -eq 1 ]; then
myconf+=" --with-libstatgrab"
else
myconf+=" --without-libstatgrab"
fi
# JAVA_HOME is set by eclasses.
if use collectd_plugins_java; then
myconf+=" --with-java"
fi
# Need libiptc ONLY for iptables. If we try to use it otherwise bug 340109 happens.
# lots of libs are only needed for plugins, if they are disabled, also disable the lib
use collectd_plugins_iptables || myconf+=" --with-libiptc=no"
use collectd_plugins_openldap || myconf+=" --with-libldap=no"
use collectd_plugins_redis || use collectd_plugins_write_redis || myconf+=" --with-libhiredis=no"
use collectd_plugins_smart || myconf+=" --with-libatasmart=no"
use collectd_plugins_gps || myconf+=" --with-libgps=no"
if use perl; then
myconf+=" --with-perl-bindings=INSTALLDIRS=vendor"
else
myconf+=" --without-perl-bindings"
fi
# No need for v5upgrade
myconf+=" --disable-target_v5upgrade"
# Python
if use collectd_plugins_python; then
myconf+=" --with-libpython=yes"
export PYTHON_CONFIG=$(python_get_PYTHON_CONFIG)
else
myconf+=" --with-libpython=no"
fi
# XFS support
myconf+=" $(use_enable xfs)"
# Finally, run econf.
KERNEL_DIR="${KERNEL_DIR}" econf --config-cache \
$(use_enable static-libs static) \
--localstatedir=/var ${myconf}
}
src_install() {
emake DESTDIR="${D%/}" install
perl_delete_localpod
find "${ED}"usr/ -name "*.la" -delete || die
if use collectd_plugins_java; then
java-pkg_regjar "${ED}"usr/share/${PN}/java/*.jar
fi
fowners root:collectd /etc/collectd.conf
fperms u=rw,g=r,o= /etc/collectd.conf
dodoc AUTHORS ChangeLog README
if use contrib ; then
insinto /usr/share/doc/${PF}
doins -r contrib
fi
keepdir /var/lib/${PN}
fowners collectd:collectd /var/lib/${PN}
newinitd "${FILESDIR}/${PN}.initd-r2" ${PN}
newconfd "${FILESDIR}/${PN}.confd-r2" ${PN}
systemd_newunit "contrib/systemd.${PN}.service" ${PN}.service
insinto /etc/logrotate.d
newins "${FILESDIR}/${PN}.logrotate" ${PN}
newtmpfiles "${FILESDIR}"/${PN}.tmpfile ${PN}.conf
sed -i -e 's:^.*PIDFile "/var/run/collectd.pid":#PIDFile "/run/collectd.pid":' "${ED}"etc/collectd.conf || die
sed -i -e 's:^# SocketFile "/var/run/collectd-unixsock":# SocketFile "/run/collectd/collectd.socket":' "${ED}"etc/collectd.conf || die
sed -i -e 's:^.*LoadPlugin perl$:# The new, correct way to load the perl plugin -- \n# <LoadPlugin perl>\n# Globals true\n# </LoadPlugin>:' "${ED}"etc/collectd.conf || die
sed -i -e 's:^.*LoadPlugin python$:# The new, correct way to load the python plugin -- \n# <LoadPlugin python>\n# Globals true\n# </LoadPlugin>:' "${ED}"etc/collectd.conf || die
}
pkg_postinst() {
tmpfiles_process "${PN}.conf"
if use filecaps; then
local caps=()
use collectd_plugins_ceph && caps+=('CAP_DAC_OVERRIDE')
use collectd_plugins_exec && caps+=('CAP_SETUID' 'CAP_SETGID')
use collectd_plugins_iptables && caps+=('CAP_NET_ADMIN')
use collectd_plugins_filecount && caps+=('CAP_DAC_READ_SEARCH')
if use collectd_plugins_dns || use collectd_plugins_ping; then
caps+=('CAP_NET_RAW')
fi
if use collectd_plugins_turbostat || use collectd_plugins_smart; then
caps+=('CAP_SYS_RAWIO')
fi
if [ ${#caps[@]} -gt 0 ]; then
local caps_str=$(IFS=","; echo "${caps[*]}")
fcaps ${caps_str} usr/sbin/collectd
elog "Capabilities for ${EROOT}usr/sbin/collectd set to:"
elog " ${caps_str}+EP"
elog
local systemd_unit="$(systemd_get_systemunitdir)/collectd.service"
if [[ -e "${systemd_unit}" ]]; then
caps_str="${caps[*]}"
sed -i -e "s:^CapabilityBoundingSet=.*:CapabilityBoundingSet=${caps_str}:" "${systemd_unit}" || \
die "Failed to set CapabilityBoundingSet in '${systemd_unit}'"
elog "CapabilityBoundingSet in '${systemd_unit}'"
elog "updated to match capabilities set above."
elog
else
if has_version "sys-apps/systemd"; then
# Bug 596852
ewarn "Failed to update CapabilityBoundingSet in '${systemd_unit}'"
ewarn "because unit was not found. Please file a bug about this."
fi
fi
fi
fi
elog "Note: Collectd is only the collector."
elog " You need to install 'data' sources (applications) locally or"
elog " remotely on your own."
elog
elog "Collectd is configured to run as unprivileged user by default."
elog "You may want to revisit the configuration."
elog
if use collectd_plugins_email; then
ewarn "The email plug-in is deprecated. To submit statistics please use the unixsock plugin."
fi
if use collectd_plugins_smart; then
elog ""
elog "If you are using smart plugin and don't run collectd as root make sure"
elog "that the collectd user is allowed to access the disk you want to monitor"
elog "(can be done via udev rule for example) and that collectd has the required"
elog "capabilities set (which is the default when package was emerged with"
elog "'filecaps' USE flag set)."
fi
if use contrib; then
elog "The scripts in /usr/share/doc/${PF}/collection3 for generating graphs need dev-perl/HTML-Parser,"
elog "dev-perl/config-general, dev-perl/regexp-common, and net-analyzer/rrdtool[perl] to be installed."
fi
}

@ -3,7 +3,7 @@
EAPI="6"
PYTHON_COMPAT=( python{2_7,3_4,3_5,3_6} )
PYTHON_COMPAT=( python{2_7,3_4,3_5,3_6,3_7} )
JAVA_PKG_OPT_USE="collectd_plugins_java"
inherit autotools fcaps flag-o-matic java-pkg-opt-2 linux-info multilib perl-functions python-single-r1 systemd tmpfiles user
@ -159,6 +159,8 @@ REQUIRED_USE="
collectd_plugins_python? ( ${PYTHON_REQUIRED_USE} )
collectd_plugins_smart? ( udev )"
PATCHES=( "${FILESDIR}"/${P}-disk-plugin-udev-fix.patch )
# @FUNCTION: collectd_plugin_kernel_linux
# @DESCRIPTION:
# USAGE: <plugin name> <kernel_options> <severity>

@ -1,153 +0,0 @@
From 8fe20883e248572690798e4dd1423511aa2f4e5d Mon Sep 17 00:00:00 2001
From: Thomas Deutschmann <whissi@gentoo.org>
Date: Thu, 22 Sep 2016 00:53:58 +0200
Subject: [PATCH 1/3] Remove bundled libltdl
---
Makefile.am | 6 ------
configure.ac | 8 ++++----
2 files changed, 4 insertions(+), 10 deletions(-)
diff --git a/Makefile.am b/Makefile.am
index 03bdd39..ad04a3c 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -1,11 +1,5 @@
-ACLOCAL_AMFLAGS = -I libltdl/m4
-
SUBDIRS =
-if BUILD_INCLUDED_LTDL
-SUBDIRS += libltdl
-endif
-
SUBDIRS += proto src bindings .
AM_CPPFLAGS = $(LTDLINCL)
diff --git a/configure.ac b/configure.ac
index 9a6da11..68e15e0 100644
--- a/configure.ac
+++ b/configure.ac
@@ -3,7 +3,6 @@ AC_PREREQ([2.60])
AC_INIT([collectd],[m4_esyscmd(./version-gen.sh)])
AC_CONFIG_SRCDIR(src/target_set.c)
AC_CONFIG_HEADERS(src/config.h)
-AC_CONFIG_AUX_DIR([libltdl/config])
dnl older automake's default of ARFLAGS=cru is noisy on newer binutils;
dnl we don't really need the 'u' even in older toolchains. Then there is
@@ -13,7 +12,6 @@ m4_divert_text([DEFAULTS], [: "${ARFLAGS=cr} ${AR_FLAGS=cr}"])
m4_ifdef([LT_PACKAGE_VERSION],
# libtool >= 2.2
[
- LT_CONFIG_LTDL_DIR([libltdl])
LT_INIT([dlopen])
LTDL_INIT([convenience])
AC_DEFINE(LIBTOOL_VERSION, 2, [Define to used libtool version.])
@@ -25,12 +23,14 @@ m4_ifdef([LT_PACKAGE_VERSION],
AC_SUBST(LTDLINCL)
AC_SUBST(LIBLTDL)
AC_LIBTOOL_DLOPEN
- AC_CONFIG_SUBDIRS(libltdl)
AC_DEFINE(LIBTOOL_VERSION, 1, [Define to used libtool version.])
]
)
-AM_CONDITIONAL([BUILD_INCLUDED_LTDL], [test "x$LTDLDEPS" != "x"])
+if test "x$LTDLDEPS" != "x"
+then
+ AC_MSG_ERROR(["system's libltdl is too old! Should never happen. Please file a bug at https://bugs.gentoo.org"])
+fi
AM_INIT_AUTOMAKE([subdir-objects tar-pax dist-bzip2 no-dist-gzip foreign])
m4_ifdef([AM_SILENT_RULES], [AM_SILENT_RULES([yes])])
--
2.10.0
From 0b00f519ce183b8ceaab5cf8e56f574ecd2cb7c4 Mon Sep 17 00:00:00 2001
From: Thomas Deutschmann <whissi@gentoo.org>
Date: Thu, 22 Sep 2016 00:54:08 +0200
Subject: [PATCH 2/3] Remove libhal dependency
X-Gentoo-Bug: 353839
X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=353839
---
configure.ac | 24 ------------------------
1 file changed, 24 deletions(-)
diff --git a/configure.ac b/configure.ac
index 68e15e0..1700c44 100644
--- a/configure.ac
+++ b/configure.ac
@@ -1663,30 +1663,6 @@ AM_CONDITIONAL(BUILD_WITH_LIBRESOLV, test "x$with_libresolv" = "xyes")
dnl Check for HAL (hardware abstraction library)
with_libhal="no"
-PKG_CHECK_MODULES([HAL], [hal],
- [
- SAVE_LIBS="$LIBS"
- LIBS="$HAL_LIBS $LIBS"
- AC_CHECK_LIB([hal], [libhal_device_property_exists],
- [
- SAVE_CPPFLAGS="$CPPFLAGS"
- CPPFLAGS="$HAL_CFLAGS $CPPFLAGS"
- AC_CHECK_HEADERS([libhal.h],
- [
- with_libhal="yes"
- BUILD_WITH_LIBHAL_CFLAGS="$HAL_CFLAGS"
- BUILD_WITH_LIBHAL_LIBS="$HAL_LIBS"
- ])
- CPPFLAGS="$SAVE_CPPFLAGS"
- ],
- [ : ]
- )
- LIBS="$SAVE_LIBS"
- ],
- [ : ]
-)
-AC_SUBST(BUILD_WITH_LIBHAL_CFLAGS)
-AC_SUBST(BUILD_WITH_LIBHAL_LIBS)
SAVE_LIBS="$LIBS"
--
2.10.0
From 380c61888bed5856319fa32816d8f2f4c88ee7bc Mon Sep 17 00:00:00 2001
From: Thomas Deutschmann <whissi@gentoo.org>
Date: Thu, 22 Sep 2016 00:54:19 +0200
Subject: [PATCH 3/3] Link Oracle plug-in against libocci
Author: Aurelien Minet
X-Gentoo-Bug: 347607
X-Gentoo-Bug-URL: https://bugs.gentoo.org/show_bug.cgi?id=347607
---
configure.ac | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/configure.ac b/configure.ac
index 1700c44..83909a0 100644
--- a/configure.ac
+++ b/configure.ac
@@ -3587,14 +3587,14 @@ AC_ARG_WITH(oracle, [AS_HELP_STRING([--with-oracle@<:@=ORACLE_HOME@:>@], [Path t
])
if test "x$ORACLE_HOME" != "x"
then
- with_oracle_cppflags="-I$ORACLE_HOME/rdbms/public"
+ with_oracle_cppflags="-I$ORACLE_HOME/rdbms/public -locci"
if test -e "$ORACLE_HOME/lib/ldflags"
then
with_oracle_libs=`cat "$ORACLE_HOME/lib/ldflags"`
fi
#with_oracle_libs="-L$ORACLE_HOME/lib $with_oracle_libs -lclntsh"
- with_oracle_libs="-L$ORACLE_HOME/lib -lclntsh"
+ with_oracle_libs="-L$ORACLE_HOME/lib -lclntsh -locci"
fi
if test "x$with_oracle" = "xyes"
then
--
2.10.0

@ -1,39 +0,0 @@
CVE-2017-16820: Fix double free of request PDU
https://github.com/collectd/collectd/commit/d16c24542b2f96a194d43a73c2e5778822b9cb47
--- a/src/snmp.c
+++ b/src/snmp.c
@@ -1357,11 +1357,13 @@ static int csnmp_read_table(host_definition_t *host, data_definition_t *data) {
if (oid_list_todo_num == 0) {
/* The request is still empty - so we are finished */
DEBUG("snmp plugin: all variables have left their subtree");
+ snmp_free_pdu(req);
status = 0;
break;
}
res = NULL;
+ /* snmp_sess_synch_response always frees our req PDU */
status = snmp_sess_synch_response(host->sess_handle, req, &res);
if ((status != STAT_SUCCESS) || (res == NULL)) {
char *errstr = NULL;
@@ -1376,8 +1378,6 @@ static int csnmp_read_table(host_definition_t *host, data_definition_t *data) {
snmp_free_pdu(res);
res = NULL;
- /* snmp_synch_response already freed our PDU */
- req = NULL;
sfree(errstr);
csnmp_host_close_session(host);
@@ -1492,9 +1492,6 @@ static int csnmp_read_table(host_definition_t *host, data_definition_t *data) {
snmp_free_pdu(res);
res = NULL;
- if (req != NULL)
- snmp_free_pdu(req);
- req = NULL;
if (status == 0)
csnmp_dispatch_table(host, data, instance_list_head, value_list_head);

@ -1,160 +0,0 @@
turbostat: import msr-index header from linux to allow building against
>=linux-4.12
Backport of https://github.com/collectd/collectd/pull/2446
--- a/configure.ac
+++ b/configure.ac
@@ -805,28 +805,6 @@ AC_CACHE_CHECK([whether clock_boottime and clock_monotonic are supported],
# For the turbostat plugin
-have_asm_msrindex_h="no"
-AC_CHECK_HEADERS(asm/msr-index.h, [have_asm_msrindex_h="yes"])
-
-if test "x$have_asm_msrindex_h" = "xyes"
-then
- AC_CACHE_CHECK([whether asm/msr-index.h has MSR_PKG_C10_RESIDENCY],
- [c_cv_have_usable_asm_msrindex_h],
- AC_COMPILE_IFELSE([AC_LANG_PROGRAM(
-[[[
-#include<asm/msr-index.h>
-]]],
-[[[
-int y = MSR_PKG_C10_RESIDENCY;
-return(y);
-]]]
- )],
- [c_cv_have_usable_asm_msrindex_h="yes"],
- [c_cv_have_usable_asm_msrindex_h="no"],
- )
- )
-fi
-
have_cpuid_h="no"
AC_CHECK_HEADERS(cpuid.h, [have_cpuid_h="yes"])
@@ -6108,7 +6086,7 @@ then
then
plugin_ipvs="yes"
fi
- if test "x$c_cv_have_usable_asm_msrindex_h" = "xyes" && test "x$have_cpuid_h" = "xyes"
+ if test "x$have_cpuid_h" = "xyes"
then
plugin_turbostat="yes"
fi
--- a/src/Makefile.am
+++ b/src/Makefile.am
@@ -1212,7 +1212,9 @@ endif
if BUILD_PLUGIN_TURBOSTAT
pkglib_LTLIBRARIES += turbostat.la
-turbostat_la_SOURCES = turbostat.c
+turbostat_la_SOURCES = \
+ turbostat.c \
+ msr-index.h
turbostat_la_LDFLAGS = $(PLUGIN_LDFLAGS)
endif
--- /dev/null
+++ b/src/msr-index.h
@@ -0,0 +1,88 @@
+/*
+ * Partial header file imported from the linux kernel
+ * (arch/x86/include/asm/msr-index.h)
+ * as it is not provided by the kernel sources anymore
+ *
+ * Only the minimal blocks of macro have been included
+ * ----
+ * This program is free software; you can redistribute it and/or modify it
+ * under the terms and conditions of the GNU General Public License,
+ * version 2, as published by the Free Software Foundation.
+ *
+ * This program is distributed in the hope it will be useful, but WITHOUT
+ * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
+ * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
+ * more details.
+ *
+ * You should have received a copy of the GNU General Public License along with
+ * this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin St - Fifth Floor, Boston, MA 02110-1301 USA.
+ * ----
+ */
+
+#ifndef _ASM_X86_MSR_INDEX_H
+#define _ASM_X86_MSR_INDEX_H
+
+/*
+ * CPU model specific register (MSR) numbers.
+ *
+ * Do not add new entries to this file unless the definitions are shared
+ * between multiple compilation units.
+ */
+
+/* Intel MSRs. Some also available on other CPUs */
+
+/* C-state Residency Counters */
+#define MSR_PKG_C3_RESIDENCY 0x000003f8
+#define MSR_PKG_C6_RESIDENCY 0x000003f9
+#define MSR_ATOM_PKG_C6_RESIDENCY 0x000003fa
+#define MSR_PKG_C7_RESIDENCY 0x000003fa
+#define MSR_CORE_C3_RESIDENCY 0x000003fc
+#define MSR_CORE_C6_RESIDENCY 0x000003fd
+#define MSR_CORE_C7_RESIDENCY 0x000003fe
+#define MSR_KNL_CORE_C6_RESIDENCY 0x000003ff
+#define MSR_PKG_C2_RESIDENCY 0x0000060d
+#define MSR_PKG_C8_RESIDENCY 0x00000630
+#define MSR_PKG_C9_RESIDENCY 0x00000631
+#define MSR_PKG_C10_RESIDENCY 0x00000632
+
+/* Run Time Average Power Limiting (RAPL) Interface */
+
+#define MSR_RAPL_POWER_UNIT 0x00000606
+
+#define MSR_PKG_POWER_LIMIT 0x00000610
+#define MSR_PKG_ENERGY_STATUS 0x00000611
+#define MSR_PKG_PERF_STATUS 0x00000613
+#define MSR_PKG_POWER_INFO 0x00000614
+
+#define MSR_DRAM_POWER_LIMIT 0x00000618
+#define MSR_DRAM_ENERGY_STATUS 0x00000619
+#define MSR_DRAM_PERF_STATUS 0x0000061b
+#define MSR_DRAM_POWER_INFO 0x0000061c
+
+#define MSR_PP0_POWER_LIMIT 0x00000638
+#define MSR_PP0_ENERGY_STATUS 0x00000639
+#define MSR_PP0_POLICY 0x0000063a
+#define MSR_PP0_PERF_STATUS 0x0000063b
+
+#define MSR_PP1_POWER_LIMIT 0x00000640
+#define MSR_PP1_ENERGY_STATUS 0x00000641
+#define MSR_PP1_POLICY 0x00000642
+
+
+
+/* Intel defined MSRs. */
+#define MSR_IA32_TSC 0x00000010
+#define MSR_SMI_COUNT 0x00000034
+
+#define MSR_IA32_MPERF 0x000000e7
+#define MSR_IA32_APERF 0x000000e8
+
+#define MSR_IA32_THERM_STATUS 0x0000019c
+
+#define MSR_IA32_TEMPERATURE_TARGET 0x000001a2
+
+#define MSR_IA32_PACKAGE_THERM_STATUS 0x000001b1
+
+
+#endif /* _ASM_X86_MSR_INDEX_H */
--- a/src/turbostat.c
+++ b/src/turbostat.c
@@ -41,7 +41,7 @@
#include "plugin.h"
#include "utils_time.h"
-#include <asm/msr-index.h>
+#include "msr-index.h"
#include <cpuid.h>
#ifdef HAVE_SYS_CAPABILITY_H
#include <sys/capability.h>

File diff suppressed because it is too large Load Diff

@ -0,0 +1,98 @@
From ed696c1b3adcb42d55759efe6f8034337f0fd243 Mon Sep 17 00:00:00 2001
From: Dylan Stephano-Shachter <dylan@wopr.nasuni.net>
Date: Thu, 15 Feb 2018 16:37:33 -0500
Subject: [PATCH] change HAVE_UDEV_H to HAVE_LIBUDEV_H for bug 2651
---
src/disk.c | 20 ++++++++++----------
1 file changed, 10 insertions(+), 10 deletions(-)
diff --git a/src/disk.c b/src/disk.c
index 004ce9e2d7..04f337415f 100644
--- a/src/disk.c
+++ b/src/disk.c
@@ -139,7 +139,7 @@ static int pnumdisk;
#error "No applicable input method."
#endif
-#if HAVE_UDEV_H
+#if HAVE_LIBUDEV_H
#include <libudev.h>
static char *conf_udev_name_attr = NULL;
@@ -173,7 +173,7 @@ static int disk_config(const char *key, const char *value) {
"on Mach / Mac OS X and will be ignored.");
#endif
} else if (strcasecmp("UdevNameAttr", key) == 0) {
-#if HAVE_UDEV_H
+#if HAVE_LIBUDEV_H
if (conf_udev_name_attr != NULL) {
free(conf_udev_name_attr);
conf_udev_name_attr = NULL;
@@ -209,7 +209,7 @@ static int disk_init(void) {
/* #endif HAVE_IOKIT_IOKITLIB_H */
#elif KERNEL_LINUX
-#if HAVE_UDEV_H
+#if HAVE_LIBUDEV_H
if (conf_udev_name_attr != NULL) {
handle_udev = udev_new();
if (handle_udev == NULL) {
@@ -217,7 +217,7 @@ static int disk_init(void) {
return -1;
}
}
-#endif /* HAVE_UDEV_H */
+#endif /* HAVE_LIBUDEV_H */
/* #endif KERNEL_LINUX */
#elif KERNEL_FREEBSD
@@ -260,10 +260,10 @@ static int disk_init(void) {
static int disk_shutdown(void) {
#if KERNEL_LINUX
-#if HAVE_UDEV_H
+#if HAVE_LIBUDEV_H
if (handle_udev != NULL)
udev_unref(handle_udev);
-#endif /* HAVE_UDEV_H */
+#endif /* HAVE_LIBUDEV_H */
#endif /* KERNEL_LINUX */
return 0;
} /* int disk_shutdown */
@@ -325,7 +325,7 @@ static counter_t disk_calc_time_incr(counter_t delta_time,
}
#endif
-#if HAVE_UDEV_H
+#if HAVE_LIBUDEV_H
/**
* Attempt to provide an rename disk instance from an assigned udev attribute.
*
@@ -841,7 +841,7 @@ static int disk_read(void) {
output_name = disk_name;
-#if HAVE_UDEV_H
+#if HAVE_LIBUDEV_H
char *alt_name = NULL;
if (conf_udev_name_attr != NULL) {
alt_name =
@@ -852,7 +852,7 @@ static int disk_read(void) {
#endif
if (ignorelist_match(ignorelist, output_name) != 0) {
-#if HAVE_UDEV_H
+#if HAVE_LIBUDEV_H
/* release udev-based alternate name, if allocated */
sfree(alt_name);
#endif
@@ -878,7 +878,7 @@ static int disk_read(void) {
submit_io_time(output_name, io_time, weighted_time);
} /* if (is_disk) */
-#if HAVE_UDEV_H
+#if HAVE_LIBUDEV_H
/* release udev-based alternate name, if allocated */
sfree(alt_name);
#endif

Binary file not shown.

@ -1 +1,2 @@
DIST bijiben-3.24.2.tar.xz 843548 BLAKE2B 2441e3e9f672c7a9796dd1786bedf29ae1b5a6c4563b07943c4bfc252dc2ad9be0e8ab0569cbceb2b2c839a93d45ef3cd671d68d9b6717f880ffbb3f80d3392f SHA512 e5571c793fc75b1038a024f0f73b539079ca4415c7f4fd0756314a14baa1fe679d9513bf8c291aa20170f35616be409ebd0360e3d3ec8f962f2d3d143e02185e
DIST bijiben-3.26.1.tar.xz 864676 BLAKE2B 8c15939d356af70ed30c8bf7dcb9cb8d81ac6f1ad5969b0b6e9fefd08efd267c65454f582e368d5183425d3cfba9fe6d2d227d1825f1c7be52fbdc5ff53ef0ff SHA512 a057fcd0400eecff90bd8feb67c775ca036d0f40e92b44cc1f35fe418288ad9aec5cfb080c8c47ba862bfbecfd94ec69a0bbd811e0364d2e273901b7d4a8b2f9

@ -0,0 +1,32 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
inherit gnome2
DESCRIPTION="Note editor designed to remain simple to use"
HOMEPAGE="https://wiki.gnome.org/Apps/Bijiben"
LICENSE="GPL-3+"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE=""
RDEPEND="
>=dev-libs/glib-2.53.4:2
>=x11-libs/gtk+-3.11.4:3
>=gnome-extra/evolution-data-server-3.13.90:=
>=net-libs/webkit-gtk-2.10.0:4
net-libs/gnome-online-accounts:=
dev-libs/libxml2:2
>=app-misc/tracker-1:=
sys-apps/util-linux
"
DEPEND="${RDEPEND}
app-text/yelp-tools
dev-libs/appstream-glib
dev-util/gdbus-codegen
>=dev-util/intltool-0.50.1
sys-devel/gettext
virtual/pkgconfig
"

Binary file not shown.

@ -1,5 +1,3 @@
DIST gemato-12.2.tar.gz 66897 BLAKE2B 85ca439620afdb2045e571ed7a11f3eb8ce85e41c0984ad51af3b9d22c0926138eda0c7b02e1d70e200eb8c93cf4003e61f901e0fd5fd28861217b02a1e3ab64 SHA512 10ba7da5de3b90722b0bdcf9d3766a7c83c68d29d23e49744a31b0c8ad80eaa4917dff2fbd9f12ef2fa4fde03244e79f6fe5e9c108db7fb64fd6ea68fa0eb81c
DIST gemato-13.0.tar.gz 66899 BLAKE2B e75a16d6a26f010801df072154897a485e9aee6434cf60962d59d11fda70b790284a734d9137ccc7910b0a95278d922640aece45e42ca497d1118e01992c2a15 SHA512 0ca17f1df8606e09a88411d75d144094bd13e440b04721175c8d9a3ea92fc616b34de0c80c817898ee94a1d82e37e4de50319634a351a52bccaec9653ad2f166
DIST gemato-13.1.tar.gz 66699 BLAKE2B f779efc2ad00c2bb6ad7eb2bbab8f6fbc8b8bc026b593bfc830844ba50a6d5ff260ca0b73190b1739268b2181461fbd4c4c45adf244b23b8ade7803d90c6773f SHA512 2cda08cee937cfdf4ff46d60b44d49e4de7af5c57bfc12ba5394e967fcdae6e4cb9ceaf131b379a2c90e92b14d8b1ec375362415fc81e16efcb3279a0ff1e46a
DIST gemato-14.0-multiprocessing.tar.gz 71359 BLAKE2B b8c6fbcf8a83c8e85db4045ad23296944b94623d132a6c5f15b8388662fd092cb589600fda1d11c9645541106dc735dceaeed87d642b1fadf0f352f4a9b3f108 SHA512 2f1a1cbd837ab316bf544f713470f570286a313e002a4dcc075e464e77a3b10ba86410f805aad3d5702f3deedda48f8270f1274a67d76086b4ad5cd597426c5e
DIST gemato-14.0.tar.gz 70754 BLAKE2B e66d63a20e144e809555b2eeff6a24f899e1f488c95a14b2250c6eb45c39a6e6b0e614afe30a64f5a353720ab38371ba3e4bf9948052dae3e06f9f82ac3d04a2 SHA512 0494b8fab720b4e5ad2b190fab128baf997073137b933bc113dddc8c5f2c54f53d09bc640b01565e9757b41197d039c8487cb2b78de77313722d19baf008b51f

@ -1,34 +0,0 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
# pyblake2 & pysha3 are broken with pypy3
PYTHON_COMPAT=( python{2_7,3_4,3_5,3_6} pypy )
PYTHON_REQ_USE='threads(+)'
inherit distutils-r1
DESCRIPTION="Stand-alone Manifest generation & verification tool"
HOMEPAGE="https://github.com/mgorny/gemato"
SRC_URI="mirror://pypi/${PN::1}/${PN}/${P}.tar.gz"
LICENSE="BSD-2"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 ~x64-cygwin ~amd64-fbsd"
IUSE="+blake2 bzip2 +gpg lzma sha3 test"
MODULE_RDEPEND="
blake2? ( $(python_gen_cond_dep 'dev-python/pyblake2[${PYTHON_USEDEP}]' python{2_7,3_4,3_5} pypy{,3}) )
bzip2? ( $(python_gen_cond_dep 'dev-python/bz2file[${PYTHON_USEDEP}]' python2_7 pypy) )
gpg? ( app-crypt/gnupg )
lzma? ( $(python_gen_cond_dep 'dev-python/backports-lzma[${PYTHON_USEDEP}]' python2_7 pypy) )
sha3? ( $(python_gen_cond_dep 'dev-python/pysha3[${PYTHON_USEDEP}]' python{2_7,3_4,3_5} pypy{,3}) )"
RDEPEND="${MODULE_RDEPEND}
dev-python/setuptools[${PYTHON_USEDEP}]"
DEPEND=">=dev-python/setuptools-34[${PYTHON_USEDEP}]
test? ( ${MODULE_RDEPEND} )"
python_test() {
esetup.py test
}

@ -1,43 +0,0 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
# pyblake2 & pysha3 are broken with pypy3
PYTHON_COMPAT=( python{2_7,3_4,3_5,3_6,3_7} pypy )
PYTHON_REQ_USE='threads(+)'
inherit distutils-r1
DESCRIPTION="Stand-alone Manifest generation & verification tool"
HOMEPAGE="https://github.com/mgorny/gemato"
SRC_URI="mirror://pypi/${PN::1}/${PN}/${P}.tar.gz"
LICENSE="BSD-2"
SLOT="0"
KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~s390 ~sparc ~x86 ~x64-cygwin ~amd64-fbsd"
IUSE="+blake2 bzip2 +gpg lzma sha3 test tools"
MODULE_RDEPEND="
blake2? ( $(python_gen_cond_dep 'dev-python/pyblake2[${PYTHON_USEDEP}]' python{2_7,3_4,3_5} pypy{,3}) )
bzip2? ( $(python_gen_cond_dep 'dev-python/bz2file[${PYTHON_USEDEP}]' python2_7 pypy) )
gpg? ( app-crypt/gnupg )
lzma? ( $(python_gen_cond_dep 'dev-python/backports-lzma[${PYTHON_USEDEP}]' python2_7 pypy) )
sha3? ( $(python_gen_cond_dep 'dev-python/pysha3[${PYTHON_USEDEP}]' python{2_7,3_4,3_5} pypy{,3}) )"
RDEPEND="${MODULE_RDEPEND}
dev-python/setuptools[${PYTHON_USEDEP}]"
DEPEND=">=dev-python/setuptools-34[${PYTHON_USEDEP}]
test? ( ${MODULE_RDEPEND} )"
python_test() {
esetup.py test
}
python_install_all() {
distutils-r1_python_install_all
if use tools; then
exeinto /usr/share/gemato
doexe utils/*.{bash,py}
fi
}

@ -3,7 +3,7 @@
EAPI="6"
PYTHON_COMPAT=(python{2_7,3_4,3_5,3_6} pypy)
PYTHON_COMPAT=( python2_7 python3_{4,5,6,7} pypy )
PYTHON_REQ_USE="xml(+),threads(+)"
inherit distutils-r1

@ -0,0 +1 @@
DIST gverify-1.tar.gz 4558 BLAKE2B 193fb63dd3816b4577314199e4f8606a20f60d883f22f36636f1dba4c3fe4a701e89fd352b33ee3ce5bfb10b39e351f971aa55c8cd6eef493fc492e2c4c5d17e SHA512 f666306973bf173683edd845499ea1b244ffc9254ed0d816660022f871e7cec480d452fd962db5417b23d3101496b80a49caece29cbddf3058e2a21ec945a268

@ -0,0 +1,30 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=7
PYTHON_COMPAT=( python{2_7,3_{4,5,6,7}} )
inherit python-single-r1
DESCRIPTION="gentoo.git signature verification tool"
HOMEPAGE="https://github.com/mgorny/gverify"
SRC_URI="https://github.com/mgorny/gverify/archive/v${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="BSD-2"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE=""
RDEPEND="${PYTHON_DEPS}
app-crypt/gnupg
dev-vcs/git"
DEPEND="${PYTHON_DEPS}"
src_compile() {
emake PREFIX="${EPREFIX}"/usr
}
src_install() {
emake install DESTDIR="${D}" PREFIX=/usr
dodoc README
}

@ -0,0 +1,8 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<maintainer type="person">
<email>mgorny@gentoo.org</email>
<name>Michał Górny</name>
</maintainer>
</pkgmetadata>

@ -3,7 +3,7 @@
EAPI="6"
PYTHON_COMPAT=( python{2_7,3_4,3_5,3_6} )
PYTHON_COMPAT=( python2_7 python3_{4,5,6,7} )
inherit python-r1

@ -3,7 +3,7 @@
EAPI="6"
PYTHON_COMPAT=( python{2_7,3_4,3_5,3_6} )
PYTHON_COMPAT=( python2_7 python3_{4,5,6,7} )
inherit python-r1

Binary file not shown.

@ -1 +1,2 @@
DIST gspell-1.4.2.tar.xz 407356 BLAKE2B f2ee6ae43be55e8ad7253e10893868a8d7857bbe41e14d71103b27a0faf40b0ed247e9fa38ed7bc75039fe0f1f600fe739f538d50f69fb063d0932df6c0b1c27 SHA512 00f53d3ca47a4ba1af1e8b4983a41dc6df8a9788898b45ffdd161a3fc8de28024cc985f49fbb872912c0a94addbca3b28ce2edda70eeb206a794e2bcf65e4a5e
DIST gspell-1.6.1.tar.xz 416704 BLAKE2B 2a180bc52d3f09813d8de362e5bf900f831663c09530c8a9b993baf55f852a3939447a71c9c9dc0caafba7e8b74a2a5aad4443cf248eb87da4e15e0481e74262 SHA512 f1ffbd0d23d9743bcf924c25b3a3d7bf93c6a5e4ea5e362fb7300f657d8c1d0117e847f3dec29de377947f850e003b24a3231e88e99b313c955dd94ce358c23e

@ -0,0 +1,47 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI="6"
VALA_USE_DEPEND="vapigen"
inherit gnome2 vala virtualx
DESCRIPTION="Spell check library for GTK+ applications"
HOMEPAGE="https://wiki.gnome.org/Projects/gspell"
LICENSE="LGPL-2.1+"
SLOT="0/1" # subslot = libgspell-1 soname version
KEYWORDS="~alpha ~amd64 ~arm ~ppc ~sparc ~x86 ~amd64-fbsd"
IUSE="+introspection vala"
REQUIRED_USE="vala? ( introspection )"
RDEPEND="
app-text/iso-codes
>=app-text/enchant-1.6.0
>=dev-libs/glib-2.44:2
>=x11-libs/gtk+-3.20:3[introspection?]
introspection? ( >=dev-libs/gobject-introspection-1.42.0:= )
vala? ( $(vala_depend) )
"
DEPEND="${RDEPEND}
dev-libs/libxml2:2
>=dev-util/gtk-doc-am-1.25
>=sys-devel/gettext-0.19.4
virtual/pkgconfig
"
src_prepare() {
use vala && vala_src_prepare
gnome2_src_prepare
}
src_configure() {
gnome2_src_configure \
$(use_enable introspection) \
$(use_enable vala)
}
src_test() {
virtx emake check
}

Binary file not shown.

@ -5,8 +5,10 @@ DIST mongodb-src-r3.4.10.tar.gz 39959937 BLAKE2B f14f081525f694b939bc21f8cb6364c
DIST mongodb-src-r3.4.13.tar.gz 39992720 BLAKE2B 5620711c5ffddd9a96c29be1f2801a37f30536d1b7afe5a7b339a41cacf1f97caf8d03aafdf1d6b71cc488e48f5066ebc49a63a6bf318483d552863cd47a0c0e SHA512 295dbb38d44c99e0dce46c5e4aa5d73c64d813a3767e71a7187aff05e30f896d283ca7ef19c0a7bbd036eecf3d419e38ea3bc7d98ba93d12296c49e565df0f66
DIST mongodb-src-r3.4.14.tar.gz 40017360 BLAKE2B 617ebf0346b9ea5034d05ba607b21b745a44e70edb347c6bf0cd8b273b448caef7da2d5f11036d48add6f452883a9b15259fe8ad466e58199be5eb9512167b6d SHA512 f8c38d12e24ae332221db15aab646725ef666012837b8127a1ab128ac2d6da2ab702f3edd17fdf3e6a840f603c8c66acf2a87fe74adf30bd9c4fe6b873c98186
DIST mongodb-src-r3.4.15.tar.gz 40063153 BLAKE2B 7912a1b0450337c8b9935deb6abfbda6080f8fec68222b6eb9fbbd278e4d8a1ffb873c7c4a63c78c3eadc722c694d4d48b3f5d9247531f1731d7713a527daec5 SHA512 8b29c1cef4c34e9c2e16bbaf50aa10574eb63c9692ab248849a0cc476acc637794c3be27df0663a27ee4ced28c6d80bb0e11ac00fcd6d0a8babfc835b78fce59
DIST mongodb-src-r3.4.16.tar.gz 40093657 BLAKE2B 7123444dbdd0b2ad3adfb3391e0177d33c1b6c6a4ea83027821c564faad047a736e52926bc15c58bef59c18282436e913fd3bc9963705e030da01356f83ea367 SHA512 e22eb1fe2a832fed8305200614988c5ecfd619cee44fe2263bffa151732c0e26584084e64065dbc65152be6e5c1767a538193770359bea92f3703c72239075db
DIST mongodb-src-r3.6.2.tar.gz 39999539 BLAKE2B 3e38917ebaf79b63bf054279fbb91a648fe52e69d8194998dc74453ad6766688929a80456f6cb4801f2806ac938a5dfc0407e5f46345b47a80ecce0ba03d7fde SHA512 7acfbcc68c1bd4e6e63eee09be1dfbb064be6f8b0144418105100a065f8162cafc9b776fe0429fd64c79b958561aa42d0bdef56588dda65acee27ccc98631f39
DIST mongodb-src-r3.6.3.tar.gz 40093607 BLAKE2B bb21bf0487661eec6140ade22526617b26b2499bd36e138d955d14a4b13a0685ec7308bccfc11ef17c785cd8a71c5b6cd9d154d461b8973410b03952b93953ec SHA512 94aa9955f99d5f6bbbe65dc3755583952525398308ca7cb9224b91d1fa403de5bb3abb63a651583815cbecaff58966b5cfe7334a36ef6583f73d8c213410ddbc
DIST mongodb-src-r3.6.4.tar.gz 40159916 BLAKE2B d3878d4e6bbf331de672768b2c92a4d71f758232170432d757f7e61849e6e1ef3b190e6a089101c9ea23c4ce23087c684c86fc6ea0f32f6fe052ce322d47e438 SHA512 02c2a697af9fdcbb16d19792be17d987e18c684418a63ed4750471c7ec22eb2eabf84e93cb1d298f67898b7e23687f668bb333c50ffc4e1b8adf8859f856ad95
DIST mongodb-src-r3.6.5.tar.gz 40310152 BLAKE2B 72110ae47b17ec8b1f60636a5ef8491b076e1cc019513fd872ea38b3bb8393efff4bddc7b795b3da711f258d21be9fa23e24d396a9429349c51ce05fff180a53 SHA512 6ecb3140ee4a7929fabe62d698f23e87cb5030cf31abefe7f82374f407fb87dc05f712089998f96bc40e23698836a86e7f3590892bde9d2d6f2c4bcc15cc3ebf
DIST mongodb-src-r3.6.6.tar.gz 40391572 BLAKE2B 1cee1ad5431d2941cf2f0ee31290b2b5bc1c628f2cb5041d4d5a1427d342ecc3bbfb123e540581d81a1c5b018464abb9dcd1ead8df0de6a01a1462ca0c258e83 SHA512 cd91979ba29538c9e1645fe81e03ac56101b0fa8980ea2bdf89a4987ee8f7f6ddc97e2b27495500548a4424f155a1847471c7a5715beabf75ff894edf05c546b
DIST mongodb-src-r4.0.0.tar.gz 49138467 BLAKE2B 616e267c737729103de544d82db60489e7a32c5f9847ffd2d643a9025c18aa867718216f5de9f18a93fb2a7930c3dbe9ec3850eef09dbec084570328a99f2865 SHA512 11d00cdde606cfea268471cffccedb6d003e421aeffda2303aff4d4126c386aaec50a1de733d7a1d5fb6605403cf9f2218dae50374c7b5e8625fa80317804589

@ -0,0 +1,160 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
PYTHON_COMPAT=( python2_7 )
SCONS_MIN_VERSION="2.3.0"
CHECKREQS_DISK_BUILD="2400M"
CHECKREQS_DISK_USR="512M"
CHECKREQS_MEMORY="1024M"
inherit check-reqs eapi7-ver eutils flag-o-matic multilib multiprocessing pax-utils python-single-r1 scons-utils systemd toolchain-funcs user
MY_P=${PN}-src-r${PV/_rc/-rc}
DESCRIPTION="A high-performance, open source, schema-free document-oriented database"
HOMEPAGE="https://www.mongodb.com"
SRC_URI="https://fastdl.mongodb.org/src/${MY_P}.tar.gz"
LICENSE="AGPL-3 Apache-2.0"
SLOT="0"
KEYWORDS="~amd64"
IUSE="debug kerberos libressl mms-agent ssl test +tools"
RDEPEND=">=app-arch/snappy-1.1.3
>=dev-cpp/yaml-cpp-0.5.3
>=dev-libs/boost-1.60:=[threads(+)]
>=dev-libs/libpcre-8.41[cxx]
dev-libs/snowball-stemmer
net-libs/libpcap
>=sys-libs/zlib-1.2.8:=
kerberos? ( dev-libs/cyrus-sasl[kerberos] )
mms-agent? ( app-admin/mms-agent )
ssl? (
!libressl? ( >=dev-libs/openssl-1.0.1g:0= )
libressl? ( dev-libs/libressl:0= )
)"
DEPEND="${RDEPEND}
${PYTHON_DEPS}
dev-util/scons
sys-libs/ncurses:0=
sys-libs/readline:0=
debug? ( dev-util/valgrind )
test? (
dev-python/pymongo[${PYTHON_USEDEP}]
dev-python/pyyaml[${PYTHON_USEDEP}]
)"
PDEPEND="tools? ( >=app-admin/mongo-tools-${PV} )"
PATCHES=(
"${FILESDIR}/${PN}-3.4.0-fix-scons.patch"
"${FILESDIR}/${PN}-3.4.6-sysmacros-include.patch"
"${FILESDIR}/${PN}-3.4.7-no-boost-check.patch"
)
S=${WORKDIR}/${MY_P}
pkg_pretend() {
if [[ -n ${REPLACING_VERSIONS} ]]; then
if ver_test "$REPLACING_VERSIONS" -lt 3.2; then
ewarn "To upgrade from a version earlier than the 3.2-series, you must"
ewarn "successively upgrade major releases until you have upgraded"
ewarn "to 3.2-series. Then upgrade to 3.4 series."
fi
fi
}
pkg_setup() {
enewgroup mongodb
enewuser mongodb -1 -1 /var/lib/${PN} mongodb
python-single-r1_pkg_setup
}
src_prepare() {
default
# remove bundled libs
rm -r src/third_party/{boost-*,pcre-*,scons-*,snappy-*,yaml-cpp-*,zlib-*} || die
}
src_configure() {
# https://github.com/mongodb/mongo/wiki/Build-Mongodb-From-Source
# --use-system-icu fails tests
# --use-system-tcmalloc is strongly NOT recommended:
scons_opts=(
CC="$(tc-getCC)"
CXX="$(tc-getCXX)"
--disable-warnings-as-errors
--use-system-boost
--use-system-pcre
--use-system-snappy
--use-system-stemmer
--use-system-yaml
--use-system-zlib
)
use debug && scons_opts+=( --dbg=on )
use kerberos && scons_opts+=( --use-sasl-client )
use ssl && scons_opts+=( --ssl )
# respect mongoDB upstream's basic recommendations
# see bug #536688 and #526114
if ! use debug; then
filter-flags '-m*'
filter-flags '-O?'
fi
default
}
src_compile() {
escons "${scons_opts[@]}" core tools
}
# FEATURES="test -usersandbox" emerge dev-db/mongodb
src_test() {
# this one test fails
rm jstests/core/jsHeapLimit.js || die
"${EPYTHON}" ./buildscripts/resmoke.py --dbpathPrefix=test --suites core --jobs=$(makeopts_jobs) || die "Tests failed"
}
src_install() {
escons "${scons_opts[@]}" --nostrip install --prefix="${ED}"/usr
doman debian/mongo*.1
dodoc README docs/building.md
newinitd "${FILESDIR}/${PN}.initd-r3" ${PN}
newconfd "${FILESDIR}/${PN}.confd-r3" ${PN}
newinitd "${FILESDIR}/mongos.initd-r3" ${PN/db/s}
newconfd "${FILESDIR}/mongos.confd-r3" ${PN/db/s}
insinto /etc
newins "${FILESDIR}/${PN}.conf-r3" ${PN}.conf
newins "${FILESDIR}/mongos.conf-r2" ${PN/db/s}.conf
systemd_dounit "${FILESDIR}/${PN}.service"
insinto /etc/logrotate.d/
newins "${FILESDIR}/${PN}.logrotate" ${PN}
# see bug #526114
pax-mark emr "${ED}"/usr/bin/{mongo,mongod,mongos}
local x
for x in /var/{lib,log}/${PN}; do
diropts -m0750 -o mongodb -g mongodb
keepdir "${x}"
done
}
pkg_postinst() {
ewarn "Make sure to read the release notes and follow the upgrade process:"
ewarn " https://docs.mongodb.com/manual/release-notes/$(ver_cut 1-2)/"
ewarn " https://docs.mongodb.com/manual/release-notes/$(ver_cut 1-2)/#upgrade-procedures"
}

@ -0,0 +1,164 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
PYTHON_COMPAT=( python2_7 )
SCONS_MIN_VERSION="2.5.0"
CHECKREQS_DISK_BUILD="2400M"
CHECKREQS_DISK_USR="512M"
CHECKREQS_MEMORY="1024M"
inherit check-reqs eapi7-ver eutils flag-o-matic multilib multiprocessing pax-utils python-single-r1 scons-utils systemd toolchain-funcs user
MY_P=${PN}-src-r${PV/_rc/-rc}
DESCRIPTION="A high-performance, open source, schema-free document-oriented database"
HOMEPAGE="https://www.mongodb.com"
SRC_URI="https://fastdl.mongodb.org/src/${MY_P}.tar.gz"
LICENSE="AGPL-3 Apache-2.0"
SLOT="0"
KEYWORDS="~amd64"
IUSE="debug kerberos libressl mms-agent ssl test +tools"
RDEPEND=">=app-arch/snappy-1.1.3
>=dev-cpp/yaml-cpp-0.5.3
>=dev-libs/boost-1.60:=[threads(+)]
>=dev-libs/libpcre-8.41[cxx]
dev-libs/snowball-stemmer
net-libs/libpcap
>=sys-libs/zlib-1.2.8:=
kerberos? ( dev-libs/cyrus-sasl[kerberos] )
mms-agent? ( app-admin/mms-agent )
ssl? (
!libressl? ( >=dev-libs/openssl-1.0.1g:0= )
libressl? ( dev-libs/libressl:0= )
)"
DEPEND="${RDEPEND}
${PYTHON_DEPS}
dev-python/cheetah[${PYTHON_USEDEP}]
dev-python/pyyaml[${PYTHON_USEDEP}]
virtual/python-typing[${PYTHON_USEDEP}]
dev-util/scons
sys-libs/ncurses:0=
sys-libs/readline:0=
debug? ( dev-util/valgrind )
test? (
dev-python/pymongo[${PYTHON_USEDEP}]
)"
PDEPEND="tools? ( >=app-admin/mongo-tools-${PV} )"
PATCHES=(
"${FILESDIR}/${PN}-3.4.7-no-boost-check.patch"
"${FILESDIR}/${PN}-3.6.1-fix-scons.patch"
"${FILESDIR}/${PN}-3.6.1-no-compass.patch"
)
S=${WORKDIR}/${MY_P}
pkg_pretend() {
if [[ -n ${REPLACING_VERSIONS} ]]; then
if ver_test "$REPLACING_VERSIONS" -lt 3.4; then
ewarn "To upgrade from a version earlier than the 3.4-series, you must"
ewarn "successively upgrade major releases until you have upgraded"
ewarn "to 3.4-series. Then upgrade to 3.6 series."
else
ewarn "Be sure to set featureCompatibilityVersion to 3.4 before upgrading."
fi
fi
}
pkg_setup() {
enewgroup mongodb
enewuser mongodb -1 -1 /var/lib/${PN} mongodb
python-single-r1_pkg_setup
}
src_prepare() {
default
# remove bundled libs
rm -r src/third_party/{boost-*,pcre-*,scons-*,snappy-*,yaml-cpp-*,zlib-*} || die
# remove compass
rm -r src/mongo/installer/compass || die
}
src_configure() {
# https://github.com/mongodb/mongo/wiki/Build-Mongodb-From-Source
# --use-system-icu fails tests
# --use-system-tcmalloc is strongly NOT recommended:
scons_opts=(
CC="$(tc-getCC)"
CXX="$(tc-getCXX)"
--disable-warnings-as-errors
--use-system-boost
--use-system-pcre
--use-system-snappy
--use-system-stemmer
--use-system-yaml
--use-system-zlib
)
use debug && scons_opts+=( --dbg=on )
use kerberos && scons_opts+=( --use-sasl-client )
use ssl && scons_opts+=( --ssl )
# respect mongoDB upstream's basic recommendations
# see bug #536688 and #526114
if ! use debug; then
filter-flags '-m*'
filter-flags '-O?'
fi
default
}
src_compile() {
escons "${scons_opts[@]}" core tools
}
# FEATURES="test -usersandbox" emerge dev-db/mongodb
src_test() {
"${EPYTHON}" ./buildscripts/resmoke.py --dbpathPrefix=test --suites core --jobs=$(makeopts_jobs) || die "Tests failed"
}
src_install() {
escons "${scons_opts[@]}" --nostrip install --prefix="${ED}"/usr
doman debian/mongo*.1
dodoc README docs/building.md
newinitd "${FILESDIR}/${PN}.initd-r3" ${PN}
newconfd "${FILESDIR}/${PN}.confd-r3" ${PN}
newinitd "${FILESDIR}/mongos.initd-r3" ${PN/db/s}
newconfd "${FILESDIR}/mongos.confd-r3" ${PN/db/s}
insinto /etc
newins "${FILESDIR}/${PN}.conf-r3" ${PN}.conf
newins "${FILESDIR}/mongos.conf-r2" ${PN/db/s}.conf
systemd_dounit "${FILESDIR}/${PN}.service"
insinto /etc/logrotate.d/
newins "${FILESDIR}/${PN}.logrotate" ${PN}
# see bug #526114
pax-mark emr "${ED}"/usr/bin/{mongo,mongod,mongos}
local x
for x in /var/{lib,log}/${PN}; do
diropts -m0750 -o mongodb -g mongodb
keepdir "${x}"
done
}
pkg_postinst() {
ewarn "Make sure to read the release notes and follow the upgrade process:"
ewarn " https://docs.mongodb.com/manual/release-notes/$(ver_cut 1-2)/"
ewarn " https://docs.mongodb.com/manual/release-notes/$(ver_cut 1-2)/#upgrade-procedures"
}

Binary file not shown.

@ -1,10 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd">
<pkgmetadata>
<maintainer type="person">
<email>wibrown@redhat.com</email>
<name>William Brown</name>
</maintainer>
<maintainer type="person">
<email>wes@sol1.com.au</email>
<name>Wes</name>

Binary file not shown.

@ -1 +1,2 @@
DIST gdl-3.22.0.tar.xz 529072 BLAKE2B 7215c53051dc3ec467c97615fa7e8059bf6c610cd166bea28ba256bf26b4de75fc63ab1e627acdeb8228257844ae1b47bb5d88cef24c7efcbd5bfbe508928eae SHA512 408fd75627497c658b65e9cd39b8779ad0db2fdc1f780e369237fbdd3f0ccc035cd86456ff72e1581c524f1d35673d3b31ebb074290babf025596d08d823833d
DIST gdl-3.28.0.tar.xz 541252 BLAKE2B 7254a9e15e9e79229c85b12c02ff5307bf99569428b13629ac8b3a5e79383f14a248d6e74f139e44145cd1a2825a2d10859c922a07a22fe1243edfafdb01514b SHA512 d6a697b8cd098abfcb560d8b6c8a326b05f6f22211a3bc92ea458d643170abc514acd4105e372fb61777d2a5dd09709d7e3d6d3ad75215fffdf2809b3df3c471

@ -0,0 +1,31 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
inherit gnome2
DESCRIPTION="GNOME docking library"
HOMEPAGE="https://git.gnome.org/browse/gdl"
LICENSE="LGPL-2.1+"
SLOT="3/5" # subslot = libgdl-3 soname version
IUSE="+introspection"
KEYWORDS="~alpha ~amd64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sparc ~x86 ~x86-fbsd"
RDEPEND="
dev-libs/glib:2
>=x11-libs/gtk+-3.0.0:3[introspection?]
>=dev-libs/libxml2-2.4:2
introspection? ( >=dev-libs/gobject-introspection-0.6.7:= )
"
DEPEND="${RDEPEND}
>=dev-util/gtk-doc-am-1.4
>=dev-util/intltool-0.40.4
virtual/pkgconfig
"
src_configure() {
gnome2_src_configure \
$(use_enable introspection) \
--disable-gtk-doc
}

@ -2,6 +2,7 @@ DIST libbson-0.98.0.tar.gz 4451923 BLAKE2B 2d53cdc0cf1afa189eb1597ccc46a604c9801
DIST libbson-1.1.10.tar.gz 4431658 BLAKE2B 1e542797c6617296c0ca7cb6dbbd34be5b31789a39130fb61000f11dfce6f7e3584f884c9350234b9704143d6a3280635cd32572b35e83010a7e9ddcc3f86ff8 SHA512 636178bafb19e7b103b5192866dbda0c70b8d7173560b0466f88b3a85cce3292a7caac9521808fa8c09d187f8c96564dcd9fb787e855d1619610f813583379bc
DIST libbson-1.1.2.tar.gz 4492014 BLAKE2B 684c5053faf5a7f3afe6063e34247cfe7709afe0c17e8f387cfb337e6cc62e7b79c3cbf018e245bc189899e094858e1caff156344e126ba889964b1112820d21 SHA512 03e2ee337445286c14b846cd7545707959b1d351fa466c6292379a85e48ea1a171dae37dd7aff092212239ad59aac6f1ab216ee5de74ef00a8a2a124559e34da
DIST libbson-1.10.3.tar.gz 5616159 BLAKE2B 368e273aedc21ec79b804625276a49f7b670f027b410595b1e6455228dc776f0ed629d6ee599d16b9d0db08ec08a8e4dac2bdf06fa931ef1578849bf86d85726 SHA512 47af1baad1ad74bbbdf2fd22a437034d317a2f3ec02fee485e983ae6829b3f01af2649a09577f08144a88385fa940dfa211ea02bfa3c0e25b59dbe2090269603
DIST libbson-1.11.0.tar.gz 5681593 BLAKE2B 43f70943cc7f1a9f6285c71136b1284be7ef0f223b777d5884d795102910aedb8d4f516d5d50cdecfa9219835a884b237aa98ab3742067c36944f0abdc67a8e4 SHA512 d20d83c9470972641407550bf835701df28c196b1cf19097450a062fd3c560c452c658aa5080bb28066079cea27888731f3670e81bd1b0cd5be1b97a2988074e
DIST libbson-1.3.5.tar.gz 4547720 BLAKE2B e5e258344aea0969ac74d88d040a464b72d460a13776c5c8c639e569ed3208fabd2641e850bf035c6889b466ddcc33d487da0aeab58f308bee7446b5fd0a31a1 SHA512 b55ae1d424f786aabed6567a77cd09aa26c74ab0a09392e88faef8c156b1650c026f86f245bc8431a0ebcf404c4f80eb1b22e978a24289d32692c84375a66596
DIST libbson-1.3.6.tar.gz 4546329 BLAKE2B fa9102cd02e40e0ddb7518d34502f6ff63109b91af18a2285422530dae8c6cc04041b7589f340f2e6ed7a80e2474fea2684001b7ced5e8c911d4ba51e1a6edcc SHA512 a7da914ed0f03212d4fb01879543f0b2c7629923e33200fe30335a9a90a1082ffa2566c7a556b90a6c7ffbef5665a45ec67f87ffff2a5fcb89830769b1df5130
DIST libbson-1.6.2.tar.gz 4835257 BLAKE2B ebe20a6c9ac8a4fcbd8e838d1a7cd319a6b31956690aa2dfca2be42eaafb646405ea01fe2bf20b2dc21bf933c0eafc330fd45409f7c902a7bf0c0641cfe0891d SHA512 f95f5bb829cff3aac6c1d95a159e38396d8fccef66d3026dac8085ba13ec376274cddeb92277d711ac4d40cafd8b89b73e9a9d1cf29e22f7f79aa9422c69488b

@ -0,0 +1,41 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI=6
inherit cmake-utils
DESCRIPTION="Library routines related to building,parsing and iterating BSON documents"
HOMEPAGE="https://github.com/mongodb/mongo-c-driver/tree/master/src/libbson"
SRC_URI="https://github.com/mongodb/mongo-c-driver/archive/${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="Apache-2.0"
SLOT="0"
KEYWORDS="~amd64 ~hppa ~ppc ~x86"
IUSE="examples static-libs"
DEPEND="dev-python/sphinx"
S="${WORKDIR}/mongo-c-driver-${PV}"
src_configure() {
local mycmakeargs=(
-DENABLE_BSON=ON
-DENABLE_EXAMPLES=OFF
-DENABLE_MAN_PAGES=ON
-DENABLE_MONGOC=OFF
-DENABLE_TESTS=OFF
-DENABLE_STATIC="$(usex static-libs ON OFF)"
)
cmake-utils_src_configure
}
src_install() {
if use examples; then
docinto examples
dodoc src/libbson/examples/*.c
fi
cmake-utils_src_install
}

@ -1,4 +1,4 @@
DIST libinput-1.10.6.tar.xz 495536 BLAKE2B 3f23808635406eeb66cd6b4ce2a2dbaed69ee0917045f75ad262a59702d72923493b6faa7951ea3f7cc2591d4c9e1fc49cffc53b6dfbcb2aadc7b9f40c20517b SHA512 b76963c3429c5590ee04f1da94d08775c8bb8584830e678804fb1d4cf0e2af84826782eae71fdd57492461f85df87ac2fc940c280b0672c75cd81d5f34702fe4
DIST libinput-1.10.7.tar.xz 494648 BLAKE2B ddcbe5f54b90f8291c16e5912fa3d673fb2c66f0247c9d771f7c2dfeeef9b51404f31d7ac99cfd20b37e1d01d6b2b3bc95155ab6581c6a94e922e153d9098892 SHA512 b102b8065ceed7511ad26efba34d5d9b0c13f0f7aaa882bb21501f7a5166f4cbe140fcbb488e90e6880bd47bb2b27667a4d6aa79b8726269fa1337897034a684
DIST libinput-1.11.1.tar.xz 485064 BLAKE2B 15ab0fddee37323f3df0b52e297ac5b0995e7db6531854852a21c7182474df0ffb136886e3d305d987dcb4f82e9f1cf3724e2f34448ef40ed1df10bd27cb2218 SHA512 3dd1a318c89d66f5a66016c6dbfa5277b61a8cb5337d99f85b1eeef40ed894bdc04fd4588a97383988daea0f034df5a72bff318325320a01b857db9deb94a2b0
DIST libinput-1.11.2.tar.xz 485600 BLAKE2B 97b07493693e24be1bde3e7792c83c33b9ed4d64afbbecc1a5b77b4470fe9ff03cfbb2b4dc36f6cc5a9d58003410797979d7fbbb539d921bb9cddb5f8fb1cf0e SHA512 cb6ada877fc3c09f634f3db39d5507e66d4b86c3d632bb8f7498c7b01fdf8372b2053a79b641293900b7fcc0aa4e920f7c830d9c7b2d9ff3cd61c58eb7c20b65
DIST libinput-1.11.3.tar.xz 487408 BLAKE2B 38dc14cf018ca59279e8b6e85fd91f4b29545b4a55ab968cb11d9a8afc8d80c311efc6e57339b9baa9fb270f52cfb0758ff8ea313991867c35f3da47910977ac SHA512 5e18daab6202bcbfddeebc35dac4cabb5f726b5b73f5fc87975b58f3019a54a4b1f506a3200e920638ddddfb978a0b96c23c2e90b081942f86d33c16d4836949

@ -1,2 +1 @@
DIST liblognorm-2.0.4.tar.gz 665898 BLAKE2B 80bcd114d2be81f8eea847e699b7e8ade9ca37d4376f64af81bfaba1a440e1efbab579235aba775c46a9d011e930453d2c001de525577b7775784e7152b3e700 SHA512 3c7cbf0c8c320708615218009354d198ba0893632ca464a07270f59d137753dfc7ad6dae66b565660f14e9285f9c8964824d36070b1872b6c633589b4996ba02
DIST liblognorm-2.0.5.tar.gz 667709 BLAKE2B 9f2a774c2378caa460a1f11e21570e719f83e782c5731a35921099b1b31397495ea2a4baebd489d186526eb2d011f2ab30d971713a8083c1ae02168d3f632ce8 SHA512 2b36fabfa8b751127d47f307833414d339ae43bad5b687ce6ac42a961021f9a515703ca0c4808e098ef49be3a943abdbf307f90995a2331c6e266167ef041d00

@ -1,72 +0,0 @@
# Copyright 1999-2018 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
EAPI="6"
inherit autotools
DESCRIPTION="Fast samples-based log normalization library"
HOMEPAGE="http://www.liblognorm.com"
if [[ ${PV} == "9999" ]]; then
EGIT_REPO_URI="https://github.com/rsyslog/${PN}.git"
inherit git-r3
else
SRC_URI="http://www.liblognorm.com/files/download/${P}.tar.gz"
KEYWORDS="amd64 arm ~arm64 hppa x86 ~amd64-linux"
fi
LICENSE="LGPL-2.1 Apache-2.0"
SLOT="0/5.1.0"
IUSE="debug doc static-libs test"
RDEPEND="
>=dev-libs/libestr-0.1.3
>=dev-libs/libfastjson-0.99.2:=
"
DEPEND="
${RDEPEND}
>=sys-devel/autoconf-archive-2015.02.04
virtual/pkgconfig
doc? ( >=dev-python/sphinx-1.2.2 )
"
DOCS=( ChangeLog )
src_prepare() {
default
eautoreconf
}
src_configure() {
# regexp disabled due to https://github.com/rsyslog/liblognorm/issues/143
local myeconfargs=(
--enable-compile-warnings=yes
--disable-Werror
$(use_enable doc docs)
$(use_enable test testbench)
$(use_enable debug)
$(use_enable static-libs static)
--disable-regexp
)
econf "${myeconfargs[@]}"
}
src_test() {
# When adding new tests via patches we have to make them executable
einfo "Adjusting permissions of test scripts ..."
find "${S}"/tests -type f -name '*.sh' \! -perm -111 -exec chmod a+x '{}' \; || \
die "Failed to adjust test scripts permission"
emake --jobs 1 check
}
src_install() {
default
find "${ED}"usr/lib* -name '*.la' -delete || die
}

@ -4,6 +4,7 @@ DIST mongo-c-driver-0.98.2.tar.gz 5342760 BLAKE2B 399fb03464234c87dcb66647c5383c
DIST mongo-c-driver-1.1.10.tar.gz 5321144 BLAKE2B d63ba4b1a256b8b29654398a53d9ca46d49faad0e0327db0d51cfc4e2a1771568341ff4e7ba6ff2ff31fb11ad8a14c452e52cabdd83da7eb1c1ceb8af7bef7d2 SHA512 10ebd1bddc0c713c0934679974fb1ed29eda1bf8e2ebbe2a1ebbcba219574092c34c4b352231ec65ffe3e350d8d701ef85debaaa9f9c10e6ab36fc3fa29f69df
DIST mongo-c-driver-1.1.2.tar.gz 5443153 BLAKE2B f8004486baf6d2d3086e458bdb4bc8060462fd52ba700cbf05fdb9827adcbd087b61d7e0e00169cf635c8021983dc851b7f34c3e08d66efc65483fce98a85f74 SHA512 d420fc407f6a04c06a959b8971dc2643c987df5c3d82f2b13bfdf6a44e96bc377478c4d0e385abf67f21b56892c915c79675fe9ebf6efa9aab51fe452c5e6f95
DIST mongo-c-driver-1.10.3.tar.gz 5616159 BLAKE2B 368e273aedc21ec79b804625276a49f7b670f027b410595b1e6455228dc776f0ed629d6ee599d16b9d0db08ec08a8e4dac2bdf06fa931ef1578849bf86d85726 SHA512 47af1baad1ad74bbbdf2fd22a437034d317a2f3ec02fee485e983ae6829b3f01af2649a09577f08144a88385fa940dfa211ea02bfa3c0e25b59dbe2090269603
DIST mongo-c-driver-1.11.0.tar.gz 5681593 BLAKE2B 43f70943cc7f1a9f6285c71136b1284be7ef0f223b777d5884d795102910aedb8d4f516d5d50cdecfa9219835a884b237aa98ab3742067c36944f0abdc67a8e4 SHA512 d20d83c9470972641407550bf835701df28c196b1cf19097450a062fd3c560c452c658aa5080bb28066079cea27888731f3670e81bd1b0cd5be1b97a2988074e
DIST mongo-c-driver-1.3.5.tar.gz 5860804 BLAKE2B a55de56d285638f21caff06446e3c0c19a5b8722a2ed69fdf046c35973c9bedcc1686065e4355db28afc83c1415872eee2972a6fb3f21647d2cafce12706adc0 SHA512 23844ffe20580998308aa9c8409afcb87dccde874077eefc6806b705e5de5743846ba0513f3a3fe83147fc47842ab8c7438ad1de5f3f55b81586b9e19046aabf
DIST mongo-c-driver-1.6.2.tar.gz 6907818 BLAKE2B 7922a50ba58d92d2954eb5c2ccb02fd3b70861bd26516fd12fe6bdf79a926799fbc3a367e1c24a57932870726aa5abc1d264215ea964a56bc318ab0f413afc60 SHA512 b3fe08a31bc83707a4d94f8ea2742fc9b17d024d6c2f92b49cfc4fe012e58cd441c9f0fa4bae9f4205fca44b2a0d8c6d5bc32a05fc9ede9bab0011839a1394af
DIST mongo-c-driver-1.8.2.tar.gz 7308675 BLAKE2B ca82c2824486cee78b164d1fdfcf1de062804f0f8637a36ec197efe434ae23a387ec0e6b2e4aa3e9c8bb2434a3cef48fecd17fc4b159a92ad86b8b940b17598a SHA512 af23601ba33694d80acdb890c1b85a354fda966491c4bbfb341a884bcd6314886e405efa3a09e47398adf8dbfdeb1b05ae8b022a72f04a66265bfaeddb661f76

@ -0,0 +1,25 @@
diff --git a/CMakeLists.txt b/CMakeLists.txt
index 860e4ea..7d646b1 100644
--- a/CMakeLists.txt
+++ b/CMakeLists.txt
@@ -110,7 +110,6 @@ if (ENABLE_BSON STREQUAL SYSTEM)
message ("-- libbson include path \"${BSON_INCLUDE_DIRS}\"")
message ("-- libbson libraries \"${BSON_LIBRARIES}\"")
message ("-- disabling test-libmongoc since using system libbson")
- SET (ENABLE_TESTS OFF)
if (ENABLE_STATIC MATCHES "ON|AUTO")
find_package (libbson-static-1.0
diff --git a/src/libbson/tests/test-bson.c b/src/libbson/tests/test-bson.c
index 51514ed..accb251 100644
--- a/src/libbson/tests/test-bson.c
+++ b/src/libbson/tests/test-bson.c
@@ -18,7 +18,7 @@
#include <bson.h>
#include <bcon.h>
#define BSON_INSIDE
-#include <bson-private.h>
+#include "bson-private.h"
#undef BSON_INSIDE
#include <fcntl.h>
#include <time.h>

Some files were not shown because too many files have changed in this diff Show More

Loading…
Cancel
Save