aboutsummaryrefslogtreecommitdiff
blob: 2eb0ccaa2e13c86617f03b0b311fe8f45a22cfcf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
# Copyright 1999-2020 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

EAPI=7

DESCRIPTION="Fast strong hash functions: SipHash/HighwayHash"
HOMEPAGE="https://github.com/google/highwayhash"
COMMIT="bdd572de8cfa3a1fbef6ba32307c2629db7c4773"
SRC_URI="https://github.com/google/highwayhash/archive/${COMMIT}.tar.gz -> ${P}.tar.gz"
S="${WORKDIR}/${PN}-${COMMIT}"

LICENSE="Apache-2.0"
SLOT="0"
KEYWORDS="~amd64 ~x86"
IUSE="static-libs"

src_prepare() {
	sed -i "/CXXFLAGS/s/-O3/${CXXFLAGS}/" Makefile || die
	default
}

src_install() {
	emake DESTDIR="${ED}"\
		INCDIR="/usr/include" \
		LIBDIR="/usr/$(get_libdir)" \
		install
	use static-libs || \
		rm "${ED}/usr/$(get_libdir)"/lib*.a || die
	einstalldocs
}