gentoo/dev-cpp/gulrak-filesystem/gulrak-filesystem-1.5.14.ebuild
Sam James f39f3a77fd
dev-cpp/gulrak-filesystem: Stabilize 1.5.14 amd64, #945620
Signed-off-by: Sam James <sam@gentoo.org>
2024-12-05 18:30:16 +00:00

41 lines
855 B
Bash

# Copyright 1999-2024 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2
EAPI=8
inherit cmake
DESCRIPTION="Header-only single-file std::filesystem compatible helper library"
HOMEPAGE="https://github.com/gulrak/filesystem"
SRC_URI="https://github.com/gulrak/filesystem/archive/v${PV}.tar.gz -> ${P}.tar.gz"
LICENSE="MIT"
SLOT="0"
KEYWORDS="amd64 ~arm64 x86"
IUSE="examples test"
RESTRICT="!test? ( test )"
S="${WORKDIR}/${P#*-}"
src_prepare() {
cmake_src_prepare
sed -i "s:-Werror::g" cmake/GhcHelper.cmake test/CMakeLists.txt || die
}
src_configure() {
local mycmakeargs=(
-DGHC_FILESYSTEM_BUILD_EXAMPLES=OFF
-DGHC_FILESYSTEM_BUILD_TESTING=$(usex test)
-DGHC_FILESYSTEM_WITH_INSTALL=ON
)
cmake_src_configure
}
src_install() {
cmake_src_install
docinto examples
use examples && dodoc examples/*.cpp
}