From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from lists.gentoo.org (pigeon.gentoo.org [208.92.234.80]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits)) (No client certificate requested) by finch.gentoo.org (Postfix) with ESMTPS id 693A2158241 for ; Fri, 17 Nov 2023 13:38:03 +0000 (UTC) Received: from pigeon.gentoo.org (localhost [127.0.0.1]) by pigeon.gentoo.org (Postfix) with SMTP id AEF4E2BC023; Fri, 17 Nov 2023 13:38:02 +0000 (UTC) Received: from smtp.gentoo.org (woodpecker.gentoo.org [140.211.166.183]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by pigeon.gentoo.org (Postfix) with ESMTPS id 8DEA12BC023 for ; Fri, 17 Nov 2023 13:38:02 +0000 (UTC) Received: from oystercatcher.gentoo.org (oystercatcher.gentoo.org [148.251.78.52]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by smtp.gentoo.org (Postfix) with ESMTPS id A5961335D1E for ; Fri, 17 Nov 2023 13:38:01 +0000 (UTC) Received: from localhost.localdomain (localhost [IPv6:::1]) by oystercatcher.gentoo.org (Postfix) with ESMTP id 41E651396 for ; Fri, 17 Nov 2023 13:38:00 +0000 (UTC) From: "Matthew Smith" To: gentoo-commits@lists.gentoo.org Content-Transfer-Encoding: 8bit Content-type: text/plain; charset=UTF-8 Reply-To: gentoo-dev@lists.gentoo.org, "Matthew Smith" Message-ID: <1700228275.044183e4a844a7607d8ed23c407ec4a6006fa626.matthew@gentoo> Subject: [gentoo-commits] repo/gentoo:master commit in: dev-lang/erlang/ X-VCS-Repository: repo/gentoo X-VCS-Files: dev-lang/erlang/Manifest dev-lang/erlang/erlang-26.1.2.ebuild X-VCS-Directories: dev-lang/erlang/ X-VCS-Committer: matthew X-VCS-Committer-Name: Matthew Smith X-VCS-Revision: 044183e4a844a7607d8ed23c407ec4a6006fa626 X-VCS-Branch: master Date: Fri, 17 Nov 2023 13:38:00 +0000 (UTC) Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-commits@lists.gentoo.org X-Auto-Response-Suppress: DR, RN, NRN, OOF, AutoReply X-Archives-Salt: 9e8cd7e6-9043-4e09-8480-7a54209266f7 X-Archives-Hash: 7125ff77d35f040612f8f281105f1085 commit: 044183e4a844a7607d8ed23c407ec4a6006fa626 Author: Matthew Smith gentoo org> AuthorDate: Fri Nov 17 13:37:29 2023 +0000 Commit: Matthew Smith gentoo org> CommitDate: Fri Nov 17 13:37:55 2023 +0000 URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=044183e4 dev-lang/erlang: add 26.1.2 Closes: https://bugs.gentoo.org/917442 Closes: https://bugs.gentoo.org/917441 Signed-off-by: Matthew Smith gentoo.org> dev-lang/erlang/Manifest | 3 + dev-lang/erlang/erlang-26.1.2.ebuild | 182 +++++++++++++++++++++++++++++++++++ 2 files changed, 185 insertions(+) diff --git a/dev-lang/erlang/Manifest b/dev-lang/erlang/Manifest index 7a2439cc7101..ca409a228252 100644 --- a/dev-lang/erlang/Manifest +++ b/dev-lang/erlang/Manifest @@ -1,6 +1,9 @@ DIST erlang-25.3.tar.gz 60060354 BLAKE2B c18beb1aa00f88ac303ce2488da6973cd63b4cb3c611d9ee93bdb8a522fa068bfab2307448d085e40c7c6e1b300a1d2b72f0626e8fd236c84617ff031afcb569 SHA512 cf104918917e33db250b48aaad3c098899739358035d764ea2ee1fc9ba7937504190752163ce8430bdbfc576ce2c2533d4f50fc8f0994ff155e3df188a8db99e DIST erlang-26.0.tar.gz 61355457 BLAKE2B 4f5abc04b794d2b2b9e27e20be9197a7c81113607a5ca2605c189212eef70db55eee5120eca36426a2c16237f576751605cdc943c7c2f070d68c6cca6585c46b SHA512 732e259f2018102b62a5d8076953a6a78d3e1f1714edde2c306fe863e5377b9a7f87052e03e92df93eea270a608b29ab4e22d5841d1314f9a532dac4aeff5436 +DIST erlang-26.1.2.tar.gz 63932020 BLAKE2B 56c862270398b458106056ea0e86a167b40d769c5b2fd84c39a0ed0c074c00d301145a98ef6e5f4b755d1124005da382ade6d4f0648823cf0e7d662a9b6bdcf2 SHA512 6907bba4ee726582b6344995c73223f725ea628897b34fc807a2a0306536bb15ce55c7fd4da1cb596dc59c9695b3bb6bba59618ca2a7a9a999e183f671656710 DIST erlang_doc_html_25.3.tar.gz 37134864 BLAKE2B 86af9f6eacccbdc8e66e1407a29bc70620052f5968f4378df751f89795f98898a057c2e187553e5b938b5a9cc55a223fedb9bc2936cb3ade5f444e05a810f7d0 SHA512 d469f6088a20a840687ceed66b3d4ef3bf9446a00ea490f6bb14e5ec8a0b642ac0ff14243010e45483e9d4d33742525916d05ec93e171fe9f5e0dfbac3733837 DIST erlang_doc_html_26.0.tar.gz 37434137 BLAKE2B 0a1bd0f4966d90cc5aaa8852b280204d81271af0449a019399dfcbeab4b2427a91fa57e1dafe24c55ee1a7abf5f52c019ca7454f7c2ca8dbe604d60ef437a4e0 SHA512 c11cf064808bee3a9e8334ee597daadfff397bd700622c80affa8df127a53de3cb5685c3338fa6d28b5c7a5c171379e0289f557dc3fc6ab0459ada757219ce3e +DIST erlang_doc_html_26.1.tar.gz 37562532 BLAKE2B 235841cd644deb5c4d47adf7aa49cdb9be5dcb17154d91b8716ab8dcd8b74ca8f805348879c7ebb45a4b31dfabab772aa9f0d5dd5eb4e573a4a687ed0a93cec2 SHA512 160f208c81cbd8c615d233ad913a2e1ddfac4f3a3368f9b33ddb5202b5bf839116cddce2dbe1c5d7ba38d30083a0b33fe3a4fe5121452057d898be1a4e8950f9 DIST erlang_doc_man_25.3.tar.gz 1719335 BLAKE2B d3d91e5920648ddb5b8375c969586b904d743f1d60acbefddd98577bd11b82246a2f149fdaa8ff1d16e8efc9f3793ce1dbc61efc9bc28c68f50919460d1e8e24 SHA512 9f2e6c4e4a39dd41deb6a2d7b7a04dd374f110bf776c8d08f3139265a8fa00e7c9420e2d2c406231a8d2748bdc65ca7e40ef1d4b9bfe6b06f52a24881ee8747d DIST erlang_doc_man_26.0.tar.gz 1742307 BLAKE2B cd52b6e148fd45a1a1b427fa9dccdb7127082f0cfc23a850c519a9dc9e6cc7e0fca3894433d44dcad27e2a8123626b09d86b7f581e503d977f0977ef62a574d8 SHA512 9e3fc06667e633fd1c90f57d86159cbbdbb6105719e3c1ab6733e5190aa48b8c8fbf735172e5763b6893e89a56ec13c0afcdf6c6505de739312b37ff246ed113 +DIST erlang_doc_man_26.1.tar.gz 1745691 BLAKE2B b06532551ab9d02c08a664eeeeae495d706969eed5151a013eb64da962e73d871c6e8a17506bdd854a3ac86caa756f78be0fdcfc76c00be89b8e4564ab881457 SHA512 2129c7c7f60f456dd0322d4fbbf3fc0398f8cdb982bb9450a99d7f45573f685fddd36a0440c4d51b89c0e4f19dc2145d1285b9fcf847c7c8bc3d95b2393c20b9 diff --git a/dev-lang/erlang/erlang-26.1.2.ebuild b/dev-lang/erlang/erlang-26.1.2.ebuild new file mode 100644 index 000000000000..1f48b8bb0ef4 --- /dev/null +++ b/dev-lang/erlang/erlang-26.1.2.ebuild @@ -0,0 +1,182 @@ +# Copyright 1999-2023 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=8 +WX_GTK_VER="3.2-gtk3" + +inherit autotools elisp-common flag-o-matic java-pkg-opt-2 systemd toolchain-funcs wxwidgets + +# NOTE: If you need symlinks for binaries please tell maintainers or +# open up a bug to let it be created. + +UPSTREAM_V="$(ver_cut 1-2)" + +DESCRIPTION="Erlang programming language, runtime environment and libraries (OTP)" +HOMEPAGE="https://www.erlang.org/" +SRC_URI="https://github.com/erlang/otp/archive/OTP-${PV}.tar.gz -> ${P}.tar.gz + https://github.com/erlang/otp/releases/download/OTP-${UPSTREAM_V}/otp_doc_man_${UPSTREAM_V}.tar.gz -> ${PN}_doc_man_${UPSTREAM_V}.tar.gz + doc? ( https://github.com/erlang/otp/releases/download/OTP-${UPSTREAM_V}/otp_doc_html_${UPSTREAM_V}.tar.gz -> ${PN}_doc_html_${UPSTREAM_V}.tar.gz )" + +LICENSE="Apache-2.0" +# We use this subslot because Compiled HiPE Code can be loaded on the exact +# same build of ERTS that was used when compiling the code. See +# http://erlang.org/doc/system_principles/misc.html for more information. +SLOT="0/${PV}" +KEYWORDS="~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~riscv ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x64-solaris" +IUSE="doc emacs java +kpoll odbc sctp ssl systemd tk wxwidgets" + +RDEPEND=" + acct-group/epmd + acct-user/epmd + sys-libs/ncurses:0 + sys-libs/zlib + emacs? ( >=app-editors/emacs-23.1:* ) + java? ( >=virtual/jdk-1.8:* ) + odbc? ( dev-db/unixODBC ) + sctp? ( net-misc/lksctp-tools ) + ssl? ( >=dev-libs/openssl-0.9.7d:0= ) + systemd? ( sys-apps/systemd ) + wxwidgets? ( x11-libs/wxGTK:${WX_GTK_VER}[X,opengl] ) +" +DEPEND="${RDEPEND} + dev-lang/perl +" + +S="${WORKDIR}/otp-OTP-${PV}" + +PATCHES=( + "${FILESDIR}"/${PN}-22.0-dont-ignore-LDFLAGS.patch + "${FILESDIR}"/${PN}-24.0.2-serial-configure.patch + "${FILESDIR}"/${PN}-25.1.2-c99.patch # Bug #882887 +) + +SITEFILE=50"${PN}"-gentoo.el + +src_prepare() { + default + + tc-export AR CPP CXX LD + + # bug #797886: erlang's VM does unsafe casts for ints + # to pointers and back. This breaks on gcc-11 -flto. + append-flags -fno-strict-aliasing + + # Ensure that we use erl_interface's libei.a, and not the system + # libei.so from dev-libs/libei. Bug #912888. + sed -i 's/-lei$/-l:libei.a/' \ + "${S}"/lib/odbc/c_src/Makefile.in || die + (cd "${S}"/lib/odbc && + eautoconf -B "${S}"/make/autoconf && + eautoheader -B "${S}"/make/autoconf) || die +} + +src_configure() { + use wxwidgets && setup-wxwidgets + + local myconf=( + --disable-builtin-zlib + + # don't search for static zlib + --with-ssl-zlib=no + + $(use_enable kpoll kernel-poll) + $(use_with java javac) + $(use_enable sctp) + $(use_with ssl ssl) + $(use_enable ssl dynamic-ssl-lib) + $(use_enable systemd) + $(usex wxwidgets "--with-wx-config=${WX_CONFIG}" "--with-wxdir=/dev/null") + ) + econf "${myconf[@]}" +} + +src_compile() { + emake + + if use doc ; then + emake docs DOC_TARGETS=chunks + fi + + if use emacs ; then + pushd lib/tools/emacs &>/dev/null || die + elisp-compile *.el + popd &>/dev/null || die + fi +} + +extract_version() { + local path="$1" + local var_name="$2" + sed -n -e "/^${var_name} = \(.*\)$/s::\1:p" "${S}/${path}/vsn.mk" || die "extract_version() failed" +} + +src_install() { + local erl_libdir_rel="$(get_libdir)/erlang" + local erl_libdir="/usr/${erl_libdir_rel}" + local erl_interface_ver="$(extract_version lib/erl_interface EI_VSN)" + local erl_erts_ver="$(extract_version erts VSN)" + local my_manpath="/usr/share/${PN}/man" + + [[ -z "${erl_erts_ver}" ]] && die "Couldn't determine erts version" + [[ -z "${erl_interface_ver}" ]] && die "Couldn't determine interface version" + + emake INSTALL_PREFIX="${D}" install + + if use doc ; then + emake INSTALL_PREFIX="${D}" install-docs DOC_TARGETS=chunks + + # Note: we explicitly install docs into: + # /usr/share/doc/${PF}/{doc,lib,erts-*} + # To maintain that layout we gather everything in 'html-docs'. + # See bug #684376. + mkdir html-docs || die + mv "${WORKDIR}"/doc "${WORKDIR}"/lib "${WORKDIR}"/erts-* html-docs/ || die + local DOCS=( "AUTHORS" "HOWTO"/* "README.md" "CONTRIBUTING.md" html-docs/. ) + docompress -x /usr/share/doc/${PF} + else + local DOCS=("README.md") + fi + + einstalldocs + + dosym "../${erl_libdir_rel}/bin/erl" /usr/bin/erl + dosym "../${erl_libdir_rel}/bin/erlc" /usr/bin/erlc + dosym "../${erl_libdir_rel}/bin/escript" /usr/bin/escript + dosym "../${erl_libdir_rel}/lib/erl_interface-${erl_interface_ver}/bin/erl_call" /usr/bin/erl_call + dosym "../${erl_libdir_rel}/erts-${erl_erts_ver}/bin/beam.smp" /usr/bin/beam.smp + + ## Clean up the no longer needed files + rm "${ED}/${erl_libdir}/Install" || die + + insinto "${my_manpath}" + doins -r "${WORKDIR}"/man/* + # extend MANPATH, so the normal man command can find it + # see bug 189639 + newenvd - "90erlang" <<-_EOF_ + MANPATH="${my_manpath}" + _EOF_ + + if use emacs ; then + elisp-install erlang lib/tools/emacs/*.{el,elc} + sed -e "s:/usr/share:${EPREFIX}/usr/share:g" \ + "${FILESDIR}/${SITEFILE}" > "${T}/${SITEFILE}" || die + elisp-site-file-install "${T}/${SITEFILE}" + fi + + newinitd "${FILESDIR}"/epmd.init-r3 epmd + use systemd && systemd_newunit "${FILESDIR}"/epmd.service-r1 epmd.service +} + +src_test() { + # Only run a subset of tests to test that everything was built + # successfully, otherwise we will be here for a long time. + emake kernel_test ARGS="-suite os_SUITE" +} + +pkg_postinst() { + use emacs && elisp-site-regen +} + +pkg_postrm() { + use emacs && elisp-site-regen +}