Skip to content

Commit

Permalink
net-misc/mosh: set -std=gnu++17 for newer abseil-cpp
Browse files Browse the repository at this point in the history
Setting the C++ standard via append-cxxflags ignores the configure.ac logic that
already does that for the same reasons and leads to duplicate flats. To rectify
that, change the targeted standard in configure.ac itself.

Closes: https://bugs.gentoo.org/935130
Signed-off-by: Paul Zander <[email protected]>
Signed-off-by: Sam James <[email protected]>
  • Loading branch information
negril authored and thesamesam committed Sep 5, 2024
1 parent 3bd01ad commit 694c395
Showing 1 changed file with 9 additions and 4 deletions.
13 changes: 9 additions & 4 deletions net-misc/mosh/mosh-1.4.0.ebuild
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@

EAPI=8

inherit autotools bash-completion-r1 flag-o-matic
inherit autotools bash-completion-r1

MY_P=${PN}-${PV/_rc/rc}
DESCRIPTION="Mobile shell that supports roaming and intelligent local echo"
Expand Down Expand Up @@ -51,15 +51,20 @@ PATCHES=(
src_prepare() {
default

# abseil-cpp needs >=c++14
local CXXSTD="14"
if has_version ">=dev-cpp/abseil-cpp-20240722.0"; then
# needs >=c++17
CXXSTD="17"
fi
sed -e "/AX_CXX_COMPILE_STDCXX/{s/11/${CXXSTD}/}" -i configure.ac || die

eautoreconf
}

src_configure() {
MAKEOPTS+=" V=1"

# protobuf needs >=c++14
append-cxxflags -std=gnu++14

local myeconfargs=(
# We install it ourselves in src_install
--disable-completion
Expand Down

0 comments on commit 694c395

Please sign in to comment.