commit: b213aea03b532aa4b74ce07bb269051a9df1ad68 Author: Sam James <sam <AT> gentoo <DOT> org> AuthorDate: Sat Feb 4 21:17:03 2023 +0000 Commit: Sam James <sam <AT> gentoo <DOT> org> CommitDate: Sat Feb 4 21:31:53 2023 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=b213aea0
dev-libs/log4cxx: add 1.0.0 Closes: https://bugs.gentoo.org/314139 Closes: https://bugs.gentoo.org/373391 Closes: https://bugs.gentoo.org/775581 Signed-off-by: Sam James <sam <AT> gentoo.org> dev-libs/log4cxx/Manifest | 1 + dev-libs/log4cxx/log4cxx-1.0.0.ebuild | 55 +++++++++++++++++++++++++++++++++++ 2 files changed, 56 insertions(+) diff --git a/dev-libs/log4cxx/Manifest b/dev-libs/log4cxx/Manifest index 672c69d34f73..36dd4b448efa 100644 --- a/dev-libs/log4cxx/Manifest +++ b/dev-libs/log4cxx/Manifest @@ -1 +1,2 @@ DIST apache-log4cxx-0.11.0.tar.gz 1145075 BLAKE2B 786f3374923a5d47172bdaba7edb1725bedc766cb310b7b1237cfcc2fdd84cf2e390b47d55284ad0ce65631798e545523723090f4c0f7ab262f6cbe41a03e327 SHA512 f8aa37c9c094e7a4d6ca92dff13c032f69f1e078c51ea55e284fcb931c13256b08950af3ea6eaf7a12282240f6073e9acab19bfe217f88dbd62a5d2360f3fbdd +DIST apache-log4cxx-1.0.0.tar.gz 554344 BLAKE2B 2664cdcb84c298cd9be49e98ee767f16665614435ad44e79fa4d10219f42373ba8bb3f6cfe698bd65c0565ba120b6f6e1ab7a8de8ce9a1f43e977dde80596c3a SHA512 a6b928d7b5b4fb60a67504be082f436a6d1a750b752a89df51d0660670b6c008e7376cf56c1749fd5fc17777ae8a2d957f72879c9a89487ecb0f179999dc1283 diff --git a/dev-libs/log4cxx/log4cxx-1.0.0.ebuild b/dev-libs/log4cxx/log4cxx-1.0.0.ebuild new file mode 100644 index 000000000000..f706d1664e4b --- /dev/null +++ b/dev-libs/log4cxx/log4cxx-1.0.0.ebuild @@ -0,0 +1,55 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 + +inherit cmake + +MY_P=apache-${P} +DESCRIPTION="Library of C++ classes for logging to files, syslog and other destinations" +HOMEPAGE="https://logging.apache.org/log4cxx/" +SRC_URI="mirror://apache/logging/${PN}/${PV}/${MY_P}.tar.gz" +S="${WORKDIR}/${MY_P}" + +LICENSE="Apache-2.0" +SLOT="0/15" +KEYWORDS="~amd64" +IUSE="odbc smtp test" +RESTRICT="!test? ( test )" + +RDEPEND=" + dev-libs/apr:1= + dev-libs/apr-util:1= + dev-libs/libfmt:= + odbc? ( dev-db/unixODBC ) + smtp? ( net-libs/libesmtp ) +" +DEPEND="${RDEPEND}" +BDEPEND=" + test? ( + app-alternatives/gzip + app-arch/zip + ) +" + +src_prepare() { + # https://github.com/apache/logging-log4cxx/issues/189 + if ! use odbc ; then + sed -i -e 's:pkg_check_modules( odbc QUIET odbc ):pkg_check_modules( odbc QUIET odbcDoNotFindMe ):' src/main/include/CMakeLists.txt || die + fi + + if ! use smtp ; then + sed -i -e 's:CHECK_LIBRARY_EXISTS(esmtp smtp_create_session "" HAS_LIBESMTP):CHECK_LIBRARY_EXISTS(esmtpDoNotFindMe smtp_create_session "" HAS_LIBESMTP):' src/main/include/CMakeLists.txt || die + fi + + cmake_src_prepare +} + +src_configure() { + local mycmakeargs=( + -DENABLE_FMT_LAYOUT=ON + -DLOG4CXX_QT_SUPPORT=OFF + ) + + cmake_src_configure +}