forked from gentoo/gentoo
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
dev-libs/crossguid: add 0.2.2_p20190529
Signed-off-by: Sam James <[email protected]>
- Loading branch information
1 parent
e0a9ed3
commit 98841dd
Showing
3 changed files
with
77 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1 +1,2 @@ | ||
DIST crossguid-0.2.2_p20190529.tar.gz 141660 BLAKE2B 0f78a8ab5a420297f666b3b8156d499a9141ec25c049d4d2bb2ba594dc585abe211a149b83c605cce4f5530207231a065d5f3a87a0c969781de8c6381afa2527 SHA512 f0a80d8e99b10473bcfdfde3d1c5fd7b766959819f0d1c0595ac84ce46db9007a5fbfde9a55aca60530c46cb7f8ef4c7e472c6191559ded92f868589c141ccaf | ||
DIST crossguid-0_pre20150817.tar.gz 46569 BLAKE2B 3384b6c507c4713f5ea0d6012138f3543445a42c7353e934e267b91275f7cf75720a446f5fe24f334b1022946f856a65f5c158d0036c999c761e626c1e30062a SHA512 823ca301f1d3b78a778649cd9169194d98dd33c65cadd5bfb9f86429e82049c99c17e09f093b92675981d2aac2aac25b60cbb157fad57a3e1bada826edd8ba0a |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,52 @@ | ||
# Copyright 1999-2023 Gentoo Authors | ||
# Distributed under the terms of the GNU General Public License v2 | ||
|
||
EAPI=8 | ||
|
||
inherit edo cmake | ||
|
||
MY_COMMIT="ca1bf4b810e2d188d04cb6286f957008ee1b7681" | ||
|
||
DESCRIPTION="Lightweight cross platform C++ GUID/UUID library" | ||
HOMEPAGE="https://github.com/graeme-hill/crossguid" | ||
SRC_URI="https://github.com/graeme-hill/crossguid/archive/${MY_COMMIT}.tar.gz -> ${P}.tar.gz" | ||
S="${WORKDIR}/${PN}-${MY_COMMIT}" | ||
|
||
LICENSE="MIT" | ||
SLOT="0" | ||
KEYWORDS="~amd64 ~arm ~arm64 ~riscv ~x86" | ||
IUSE="test" | ||
RESTRICT="!test? ( test )" | ||
|
||
# We use libuuid from util-linux. | ||
DEPEND="sys-apps/util-linux" | ||
RDEPEND="${DEPEND}" | ||
|
||
PATCHES=( | ||
"${FILESDIR}"/${PN}-0.2.2_p20190529-gcc-13.patch | ||
) | ||
|
||
src_prepare() { | ||
# https://github.com/graeme-hill/crossguid/pull/62 | ||
sed -i -e 's:-Werror::' CMakeLists.txt || die | ||
|
||
cmake_src_prepare | ||
} | ||
|
||
src_configure() { | ||
local mycmakeargs=( | ||
-DCROSSGUID_TESTS=$(usex test) | ||
) | ||
|
||
cmake_src_configure | ||
} | ||
|
||
src_test() { | ||
edo "${BUILD_DIR}"/crossguid-test | ||
} | ||
|
||
src_install() { | ||
cmake_src_install | ||
|
||
rm "${ED}"/usr/share/crossguid/LICENSE || die | ||
} |
24 changes: 24 additions & 0 deletions
24
dev-libs/crossguid/files/crossguid-0.2.2_p20190529-gcc-13.patch
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
https://github.com/graeme-hill/crossguid/pull/67 | ||
|
||
From 1eb9bea38c320b2b588635cffceaaa2a8d434780 Mon Sep 17 00:00:00 2001 | ||
From: Khem Raj <[email protected]> | ||
Date: Wed, 25 Jan 2023 22:09:26 -0800 | ||
Subject: [PATCH] include missing <cstdint> | ||
|
||
gcc 13 moved some includes around and as a result <cstdint> is no longer transitively | ||
included [1]. Explicitly include it for uint{32,64}_t. | ||
|
||
[1] https://gcc.gnu.org/gcc-13/porting_to.html#header-dep-changes | ||
|
||
Signed-off-by: Khem Raj <[email protected]> | ||
--- a/include/crossguid/guid.hpp | ||
+++ b/include/crossguid/guid.hpp | ||
@@ -29,6 +29,7 @@ THE SOFTWARE. | ||
#include <jni.h> | ||
#endif | ||
|
||
+#include <cstdint> | ||
#include <functional> | ||
#include <iostream> | ||
#include <array> | ||
|