/[gentoo-x86]/net-misc/i2pd/i2pd-9999.ebuild
Gentoo

Contents of /net-misc/i2pd/i2pd-9999.ebuild

Parent Directory Parent Directory | Revision Log Revision Log


Revision 1.2 - (show annotations) (download)
Mon Feb 2 17:06:04 2015 UTC (4 years, 10 months ago) by mgorny
Branch: MAIN
CVS Tags: HEAD
Changes since 1.1: +3 -3 lines
Use cpu_flags_x86_aes, bug #538556.

(Portage version: 2.2.15/cvs/Linux x86_64, signed Manifest commit with key EFB4464E!)

1 # Copyright 1999-2015 Gentoo Foundation
2 # Distributed under the terms of the GNU General Public License v2
3 # $Header: /var/cvsroot/gentoo-x86/net-misc/i2pd/i2pd-9999.ebuild,v 1.1 2015/01/08 22:44:46 blueness Exp $
4
5 EAPI=5
6 inherit eutils systemd user git-2 cmake-multilib
7
8 DESCRIPTION="A C++ daemon for accessing the I2P anonymous network"
9 HOMEPAGE="https://github.com/PrivacySolutions/i2pd"
10 SRC_URI=""
11 EGIT_REPO_URI="git://github.com/PrivacySolutions/i2pd"
12 LICENSE="GPL-2"
13 SLOT="0"
14 KEYWORDS=""
15 IUSE="cpu_flags_x86_aes i2p-hardening library static"
16
17 RDEPEND="!static? ( >=dev-libs/boost-1.46[threads] )
18 !static? ( dev-libs/crypto++ )
19 library? ( >=dev-libs/boost-1.46[threads,${MULTILIB_USEDEP}] )
20 library? ( dev-libs/crypto++[${MULTILIB_USEDEP}] )"
21 DEPEND="${RDEPEND}
22 static? ( >=dev-libs/boost-1.46[static-libs,threads] )
23 static? ( dev-libs/crypto++[static-libs] )
24 >=dev-util/cmake-2.8.5
25 i2p-hardening? ( >=sys-devel/gcc-4.6 )
26 || ( >=sys-devel/gcc-4.6 >=sys-devel/clang-3.3 )"
27
28 I2PD_USER="${I2PD_USER:-i2pd}"
29 I2PD_GROUP="${I2PD_GROUP:-i2pd}"
30
31 CMAKE_USE_DIR="${S}/build"
32
33 multilib_src_configure() {
34 mycmakeargs=(
35 $(cmake-utils_use_with cpu_flags_x86_aes AESNI)
36 $(cmake-utils_use_with i2p-hardening HARDENING)
37 $(cmake-utils_use_with library LIBRARY)
38 $(cmake-utils_use_with static STATIC)
39 $(multilib_is_native_abi && echo -DWITH_BINARY=ON \
40 || echo -DWITH_BINARY=OFF)
41 )
42 (multilib_is_native_abi || use library) && cmake-utils_src_configure
43 }
44
45 multilib_src_compile() {
46 (multilib_is_native_abi || use library) && cmake-utils_src_compile
47 }
48
49 multilib_src_install() {
50 (multilib_is_native_abi || use library) && cmake-utils_src_install
51 }
52
53 multilib_src_install_all() {
54 dodoc README.md
55 doman "${FILESDIR}/${PN}.1"
56 keepdir /var/lib/i2pd/
57 fowners "${I2PD_USER}:${I2PD_GROUP}" /var/lib/i2pd/
58 fperms 700 /var/lib/i2pd/
59 insinto /etc/
60 doins "${FILESDIR}/${PN}.conf"
61 fowners "${I2PD_USER}:${I2PD_GROUP}" "/etc/${PN}.conf"
62 fperms 600 "/etc/${PN}.conf"
63 dodir /usr/share/i2pd
64 cp -R "${S}/contrib/certificates" "${D}/var/lib/i2pd" || die "Install failed!"
65 newconfd "${FILESDIR}/${PN}.confd" "${PN}"
66 newinitd "${FILESDIR}/${PN}.initd" "${PN}"
67 systemd_dounit "${FILESDIR}/${PN}.service"
68 doenvd "${FILESDIR}/99${PN}"
69 insinto /etc/logrotate.d
70 newins "${FILESDIR}/${PN}.logrotate" "${PN}"
71 }
72
73 pkg_setup() {
74 enewgroup "${I2PD_GROUP}"
75 enewuser "${I2PD_USER}" -1 -1 "/var/lib/run/${PN}" "${I2PD_GROUP}"
76 }

  ViewVC Help
Powered by ViewVC 1.1.20