summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthew Smith <matthew@gentoo.org>2022-08-20 08:11:30 +0100
committerMatthew Smith <matthew@gentoo.org>2022-08-20 08:13:28 +0100
commite6770b8f10903056f2d7073899fd476e7a2f04ef (patch)
tree6314e12a04218b15f9ca426fefe014e054d9a09d /dev-lang/erlang
parentnet-mail/mu: add 1.8.9 (diff)
downloadgentoo-e6770b8f10903056f2d7073899fd476e7a2f04ef.tar.gz
gentoo-e6770b8f10903056f2d7073899fd476e7a2f04ef.tar.bz2
gentoo-e6770b8f10903056f2d7073899fd476e7a2f04ef.zip
dev-lang/erlang: add 25.0.4
Signed-off-by: Matthew Smith <matthew@gentoo.org>
Diffstat (limited to 'dev-lang/erlang')
-rw-r--r--dev-lang/erlang/Manifest1
-rw-r--r--dev-lang/erlang/erlang-25.0.4.ebuild168
2 files changed, 169 insertions, 0 deletions
diff --git a/dev-lang/erlang/Manifest b/dev-lang/erlang/Manifest
index a76d47eb1acc..00c19a6faac9 100644
--- a/dev-lang/erlang/Manifest
+++ b/dev-lang/erlang/Manifest
@@ -4,6 +4,7 @@ DIST erlang-24.3.3.tar.gz 59296830 BLAKE2B 1792274c77001b6f49e84f1584620a247cf3a
DIST erlang-24.3.4.2.tar.gz 59532491 BLAKE2B 28c48f1a3197a151010a775286cf0b775567301411b8480b32cfb39c68978de5586b63c245fe58bff8034ebc04fcc3b002dee7c953127ecf581ed6d716587ae4 SHA512 78bc2dc67fe60d3ea6049c361a017c054e12b0adeeae890b0a1ee5301744505593bd19f3731acebff8312b323a3bd21a1359507d122fc34f0eb85eefb3aac88c
DIST erlang-25.0.2.tar.gz 59800286 BLAKE2B 4344ff5a21a6c0139842067d10d82435f504a5bd3b4112137f92ad06d7bff21352244c80eadad4a9efbc29692ac2be2a81b87ddde9b29433d1461a1148a733c7 SHA512 717406816b4428fb8bd808a9d25575b7e33a05e6aed5428295682ba8576d53f1433bd1b1593236943e592e673ed2168047873127cfd293b5522636c514328f43
DIST erlang-25.0.3.tar.gz 59811038 BLAKE2B 81176f415e814b57f298782d2ae77ebf68c1493753b747b29409d95f811dc501ec5301975e90ec464ef611c3f06cf066d36b34f21e92bae10e5f02fe3f87c8b7 SHA512 d6c83722bd86e20568b879cb770e95e37b6227b932e4e74e50bbb9dc426b1f7f5286600a182011baa2b83ff7f006717ee62812959f133868765d819ddf57399f
+DIST erlang-25.0.4.tar.gz 59812650 BLAKE2B cebba32e859ec4ff0868de506771449a6d5d053d50d8f4a2cf84f9bc90da1e14ae320420b3c33f6febd5977fd1ccff98b55d3ee1a0c4b90e674e912883cb0f29 SHA512 8d9d12496d55181c0d866bbd97576551d1d78232fe34b845e8efbfbd4e95ce8426e73221d8126d12453959cd8adc5e07f121aaa93f3a5696074b43c69291d363
DIST erlang-25.0.tar.gz 59574655 BLAKE2B fddcd0d099b84981862b06397dcd6d1a53e11c5624f5e8e60ef0caa1db215a8447b6a9eaecd56761d3d7d213ca40b5e7e7b0860d2cbf0d547f5dfcf9e9edd08b SHA512 36f2d36c5d2d5dcd28c6f817f3dc008c902838115b8830a684f9d9290017074cbfbb616d4a28f02fedaab097e73183c86cef1ce28f656e0852df0a95c30c5639
DIST erlang_doc_html_23.3.tar.gz 36224657 BLAKE2B 7e2a3e16f4cfa0f15c01074740e02af7a45b480b4a94e764463717658ab7e5d0281f928c3ec585582b10168645e3e06cfe72cf6a0ba1b88f539b80f2b7ad99be SHA512 8be4aae46839239604b875b39339e7b6b6c677c099b3d749d5f1041c4508c1c3b4aa8136a93df12b1e5cb6333ef907276f5965c9726ed2b9e77a6043c8ef53b1
DIST erlang_doc_html_24.3.tar.gz 36645792 BLAKE2B ef90b7d05ed43656ab1ffdbbd0833c9da08a867ad7a99ec0f7f1eb59697c1f9cd5ccd150b2e564af80b2098f063da0c76121d4444b5444e603581442ad1c7bc8 SHA512 b8d3832ffdbdede656b362d719474f7b9ff04a32ea7235e77d63755629cf9305c203cd6cd9ae089171b2cee694f9641d6ed5d0197e2acf893a31d25696096f1e
diff --git a/dev-lang/erlang/erlang-25.0.4.ebuild b/dev-lang/erlang/erlang-25.0.4.ebuild
new file mode 100644
index 000000000000..e5b9526aba8a
--- /dev/null
+++ b/dev-lang/erlang/erlang-25.0.4.ebuild
@@ -0,0 +1,168 @@
+# Copyright 1999-2022 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+WX_GTK_VER="3.0-gtk3"
+
+inherit 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
+)
+
+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
+}
+
+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 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
+ # 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-r2 epmd
+ newconfd "${FILESDIR}"/epmd.confd-r2 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
+}