diff options
author | Georgy Yakovlev <gyakovlev@gentoo.org> | 2021-06-29 20:18:08 -0700 |
---|---|---|
committer | Georgy Yakovlev <gyakovlev@gentoo.org> | 2021-07-06 10:09:42 -0700 |
commit | 2b57511643716436599d1ec2b839035d3cb6d696 (patch) | |
tree | f8dac5435fab31dac97cee00577234d768965ece /app-shells/fish | |
parent | sys-libs/compiler-rt-sanitizers: Port to py3.10 (diff) | |
download | gentoo-2b57511643716436599d1ec2b839035d3cb6d696.tar.gz gentoo-2b57511643716436599d1ec2b839035d3cb6d696.tar.bz2 gentoo-2b57511643716436599d1ec2b839035d3cb6d696.zip |
app-shells/fish: add 3.3.1
terminal size test fails, depending on
size of terminal fish is tested in.
Bug: https://bugs.gentoo.org/790596
Signed-off-by: Georgy Yakovlev <gyakovlev@gentoo.org>
Diffstat (limited to 'app-shells/fish')
-rw-r--r-- | app-shells/fish/Manifest | 1 | ||||
-rw-r--r-- | app-shells/fish/files/3.3.1-don-t-override-linker.patch | 48 | ||||
-rw-r--r-- | app-shells/fish/files/3.3.1-sbin-path-sh-test.patch | 25 | ||||
-rw-r--r-- | app-shells/fish/fish-3.3.1.ebuild | 94 |
4 files changed, 168 insertions, 0 deletions
diff --git a/app-shells/fish/Manifest b/app-shells/fish/Manifest index 0ad814f70c26..fc67224f5d13 100644 --- a/app-shells/fish/Manifest +++ b/app-shells/fish/Manifest @@ -1,3 +1,4 @@ DIST fish-3.1.2.tar.gz 6816214 BLAKE2B d994cb867a1a86850db2ec36d262328cd8dc21d63edb860c26d727aac08fa257392690999e099d754287d9f12a294222815e4cc84abbb2e2a87a982bb6627b6b SHA512 b6ae2c928774a2eaccf35312d3a9446bfa3e1335182c8f2b2d6198161d0916904f4964fb20ed13a5bf850c1c819e003905d13db3bc8b1faa5b401a60b47dc563 DIST fish-3.2.1.tar.xz 3409808 BLAKE2B ad136c60cc98ae9fdb2e2abecb722107543184cb162a3c6b058e8ebe40a383a09c0e9b0eca762ab95725227dd6630605ad875bd4da59d38e605bc1f82fa1d517 SHA512 bf565bac93e7d163af5253b4053f9c9e760508b929624440fd8a160504a127c34013882576293c72a47ce7f285f87e0b594d61d7cebcefcc3be4e92c572926bc DIST fish-3.2.2.tar.xz 3411748 BLAKE2B f8b20b6c56c54f84f347b930b71528dbd61a4f53adfd8addec05314c9d15992257cea89ce854adef2eecf3adfb07e6fa576b9d45c2e362ff360b24cf1edf3afc SHA512 e82c5a390bd94f84c60843a94dc4f30bd46539828a54d2e96f208e0d54a0aa361a8c9d4a66cdf2fa636a5fab310a96bf1c165c58440c38d123f788fff3598f4a +DIST fish-3.3.1.tar.xz 3489152 BLAKE2B 61b2bf96526d957d3f9706df5a76d4d9b4ccf55a1ff2b7b66f1a0d5d126a220df9984551f5adb06dcedbfb5674b93c4f3d75ef991585980a29d4dd84f7697559 SHA512 fc50ca44fab3f2d942284d4f714150f7ccf1e49c73da36f8d4ae4a33a9b3280f98bed15848839f5d443b4274fd0ff90174bafa6a8e9a4da226dda63d7766a660 diff --git a/app-shells/fish/files/3.3.1-don-t-override-linker.patch b/app-shells/fish/files/3.3.1-don-t-override-linker.patch new file mode 100644 index 000000000000..cb67498fd2ba --- /dev/null +++ b/app-shells/fish/files/3.3.1-don-t-override-linker.patch @@ -0,0 +1,48 @@ +From c9ab706be64439d1a03f978d3a47450135c87002 Mon Sep 17 00:00:00 2001 +From: Georgy Yakovlev <ya@sysdump.net> +Date: Tue, 29 Jun 2021 09:40:44 -0700 +Subject: [PATCH] don't override linker + +--- + CMakeLists.txt | 18 +----------------- + 1 file changed, 1 insertion(+), 17 deletions(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index fda837cd3..507dc8817 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -56,22 +56,6 @@ set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -Wall -Wextra \ + # Disable exception handling. + add_compile_options(-fno-exceptions) + +-# Prefer lld or the gold linker because they don't emit useless warnings about sys_nerr and +-# _sys_errlist. They're also faster (significantly so in the case of lld). +-if (UNIX) +- execute_process(COMMAND ${CMAKE_C_COMPILER} -fuse-ld=lld -Wl,--version +- ERROR_QUIET OUTPUT_VARIABLE LD_VERSION) +- if ("${LD_VERSION}" MATCHES "LLD ") +- set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -fuse-ld=lld") +- elseif (NOT APPLE) +- execute_process(COMMAND ${CMAKE_C_COMPILER} -fuse-ld=gold -Wl,--version +- ERROR_QUIET OUTPUT_VARIABLE LD_VERSION) +- if ("${LD_VERSION}" MATCHES "GNU gold") +- set(CMAKE_EXE_LINKER_FLAGS "${CMAKE_EXE_LINKER_FLAGS} -fuse-ld=gold") +- endif() +- endif() +-endif() +- + # Hide the CMake Rules directories in Xcode projects. + source_group("CMake Rules" REGULAR_EXPRESSION "^$") + +@@ -128,7 +112,7 @@ set(FISH_SRCS + src/proc.cpp src/reader.cpp src/redirection.cpp src/sanity.cpp src/screen.cpp + src/signal.cpp src/termsize.cpp src/timer.cpp src/tinyexpr.cpp + src/tokenizer.cpp src/topic_monitor.cpp src/trace.cpp src/utf8.cpp src/util.cpp +- src/wait_handle.cpp src/wcstringutil.cpp src/wgetopt.cpp src/wildcard.cpp ++ src/wait_handle.cpp src/wcstringutil.cpp src/wgetopt.cpp src/wildcard.cpp + src/wutil.cpp src/fds.cpp + ) + +-- +2.32.0 + diff --git a/app-shells/fish/files/3.3.1-sbin-path-sh-test.patch b/app-shells/fish/files/3.3.1-sbin-path-sh-test.patch new file mode 100644 index 000000000000..ce66e98eb124 --- /dev/null +++ b/app-shells/fish/files/3.3.1-sbin-path-sh-test.patch @@ -0,0 +1,25 @@ +From 1f73c8d923e41442cefd5a58498798971282c701 Mon Sep 17 00:00:00 2001 +From: Georgy Yakovlev <ya@sysdump.net> +Date: Tue, 29 Jun 2021 09:55:14 -0700 +Subject: [PATCH] sbin path sh test + +--- + tests/checks/type.fish | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/tests/checks/type.fish b/tests/checks/type.fish +index 85a2d142a..6ce3a4f68 100644 +--- a/tests/checks/type.fish ++++ b/tests/checks/type.fish +@@ -31,7 +31,7 @@ echo $status + # Test that we print a command path + type sh + # (we resolve the path, so if /bin is a symlink to /usr/bin this shows /usr/bin/sh) +-# CHECK: sh is {{.*}}/bin/sh ++# CHECK: sh is {{.*}}/{{s*}}bin/sh + + # Test that we print a function definition. + # The exact definition and description here depends on the system, so we'll ignore the actual code. +-- +2.32.0 + diff --git a/app-shells/fish/fish-3.3.1.ebuild b/app-shells/fish/fish-3.3.1.ebuild new file mode 100644 index 000000000000..fc205e24afcf --- /dev/null +++ b/app-shells/fish/fish-3.3.1.ebuild @@ -0,0 +1,94 @@ +# Copyright 1999-2021 Gentoo Authors +# Distributed under the terms of the GNU General Public License v2 + +EAPI=7 + +PYTHON_COMPAT=( python3_{7..9} ) + +inherit cmake python-any-r1 readme.gentoo-r1 + +DESCRIPTION="Friendly Interactive SHell" +HOMEPAGE="http://fishshell.com/" + +MY_PV="${PV/_beta/b}" +MY_P="${PN}-${MY_PV}" + +if [[ ${PV} == "9999" ]]; then + inherit git-r3 + EGIT_REPO_URI="https://github.com/${PN}-shell/${PN}-shell.git" +else + SRC_URI="https://github.com/${PN}-shell/${PN}-shell/releases/download/${MY_PV}/${MY_P}.tar.xz" + KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sparc ~x86 ~amd64-linux ~x86-linux ~ppc-macos ~x64-macos ~x86-solaris" +fi + +LICENSE="GPL-2" +SLOT="0" +IUSE="+doc nls test" + +RESTRICT="!test? ( test )" + +PATCHES=( + "${FILESDIR}/3.3.1-don-t-override-linker.patch" + "${FILESDIR}/3.3.1-sbin-path-sh-test.patch" +) + +RDEPEND=" + >=dev-libs/libpcre2-10.32[pcre32] + sys-apps/coreutils + sys-libs/ncurses:0=[unicode] +" + +DEPEND="${RDEPEND}" +BDEPEND=" + nls? ( sys-devel/gettext ) + test? ( + ${PYTHON_DEPS} + dev-tcltk/expect + $(python_gen_any_dep ' + dev-python/pexpect[${PYTHON_USEDEP}] + ') + ) +" +# we don't need shpinx dep for release tarballs +[[ ${PV} == 9999 ]] && DEPEND+=" doc? ( dev-python/sphinx )" + +S="${WORKDIR}/${MY_P}" + +python_check_deps() { + use test || return 0 + has_version -d "dev-python/pexpect[${PYTHON_USEDEP}]" +} + +src_prepare() { + # workaround for https://github.com/fish-shell/fish-shell/issues/4883 + sed -i 's#${TEST_INSTALL_DIR}/${CMAKE_INSTALL_PREFIX}#${TEST_INSTALL_DIR}#' \ + cmake/Tests.cmake || die + cmake_src_prepare +} + +src_configure() { + local mycmakeargs=( + -DCMAKE_INSTALL_BINDIR="${EPREFIX}/bin" + -DCMAKE_INSTALL_SYSCONFDIR="${EPREFIX}/etc" + -DCURSES_NEED_NCURSES=ON + -DINSTALL_DOCS="$(usex doc)" + -DWITH_GETTEXT="$(usex nls)" + ) + # release tarballs ship pre-built docs // -DHAVE_PREBUILT_DOCS=TRUE + [[ ${PV} == 9999 ]] && mycmakeargs+=( -DBUILD_DOCS="$(usex doc)" ) + cmake_src_configure +} + +src_install() { + cmake_src_install + keepdir /usr/share/fish/vendor_{completions,conf,functions}.d + readme.gentoo_create_doc +} + +src_test() { + cmake_build test +} + +pkg_postinst() { + readme.gentoo_print_elog +} |