1 |
commit: 52161eabaa7da1d524db1a7b24b32f9006c85dcd |
2 |
Author: Hinnerk van Bruinehsen <h.v.bruinehsen <AT> fu-berlin <DOT> de> |
3 |
AuthorDate: Thu Oct 2 20:16:50 2014 +0000 |
4 |
Commit: Anthony G. Basile <blueness <AT> gentoo <DOT> org> |
5 |
CommitDate: Thu Oct 2 21:20:30 2014 +0000 |
6 |
URL: http://sources.gentoo.org/gitweb/?p=proj/hardened-dev.git;a=commit;h=52161eab |
7 |
|
8 |
pax-utils-0.8.1: substitute __BEGIN/END_DECLS by ifdefs |
9 |
|
10 |
Signed-of-by: Hinnerk van Bruinehsen <h.v.bruinehsen <AT> fu-berlin.de> |
11 |
|
12 |
--- |
13 |
.../files/pax-utils-0.8.1-remove_DECLS.patch | 25 ++++++++++++ |
14 |
app-misc/pax-utils/metadata.xml | 16 ++++++++ |
15 |
app-misc/pax-utils/pax-utils-0.8.1-r99.ebuild | 47 ++++++++++++++++++++++ |
16 |
3 files changed, 88 insertions(+) |
17 |
|
18 |
diff --git a/app-misc/pax-utils/files/pax-utils-0.8.1-remove_DECLS.patch b/app-misc/pax-utils/files/pax-utils-0.8.1-remove_DECLS.patch |
19 |
new file mode 100644 |
20 |
index 0000000..38fd77a |
21 |
--- /dev/null |
22 |
+++ b/app-misc/pax-utils/files/pax-utils-0.8.1-remove_DECLS.patch |
23 |
@@ -0,0 +1,25 @@ |
24 |
+diff --git a/elf.h b/elf.h |
25 |
+index d131b9b..e625240 100644 |
26 |
+--- a/elf.h |
27 |
++++ b/elf.h |
28 |
+@@ -21,7 +21,9 @@ |
29 |
+ |
30 |
+ #include <features.h> |
31 |
+ |
32 |
+-__BEGIN_DECLS |
33 |
++#ifdef __cplusplus |
34 |
++extern "C" { |
35 |
++#endif |
36 |
+ |
37 |
+ /* Standard ELF types. */ |
38 |
+ |
39 |
+@@ -3375,6 +3377,8 @@ typedef Elf32_Addr Elf32_Conflict; |
40 |
+ #define R_TILEGX_NUM 130 |
41 |
+ |
42 |
+ |
43 |
+-__END_DECLS |
44 |
++#ifdef __cplusplus |
45 |
++} |
46 |
++#endif |
47 |
+ |
48 |
+ #endif /* elf.h */ |
49 |
|
50 |
diff --git a/app-misc/pax-utils/metadata.xml b/app-misc/pax-utils/metadata.xml |
51 |
new file mode 100644 |
52 |
index 0000000..448899f |
53 |
--- /dev/null |
54 |
+++ b/app-misc/pax-utils/metadata.xml |
55 |
@@ -0,0 +1,16 @@ |
56 |
+<?xml version="1.0" encoding="UTF-8"?> |
57 |
+<!DOCTYPE pkgmetadata SYSTEM "http://www.gentoo.org/dtd/metadata.dtd"> |
58 |
+<pkgmetadata> |
59 |
+ <maintainer> |
60 |
+ <email>solar@g.o</email> |
61 |
+ <description>Maintainer</description> |
62 |
+ </maintainer> |
63 |
+ <maintainer> |
64 |
+ <email>vapier@g.o</email> |
65 |
+ <description>Maintainer</description> |
66 |
+ </maintainer> |
67 |
+ <longdescription>A suite of ELF tools to aid auditing systems. Contains various ELF related utils for ELF32, ELF64 binaries useful for displaying PaX and security info on a large groups of binary files.</longdescription> |
68 |
+ <use> |
69 |
+ <flag name='python'>Install a more powerful/faster version of lddtree</flag> |
70 |
+ </use> |
71 |
+</pkgmetadata> |
72 |
|
73 |
diff --git a/app-misc/pax-utils/pax-utils-0.8.1-r99.ebuild b/app-misc/pax-utils/pax-utils-0.8.1-r99.ebuild |
74 |
new file mode 100644 |
75 |
index 0000000..3f05c41 |
76 |
--- /dev/null |
77 |
+++ b/app-misc/pax-utils/pax-utils-0.8.1-r99.ebuild |
78 |
@@ -0,0 +1,47 @@ |
79 |
+# Copyright 1999-2014 Gentoo Foundation |
80 |
+# Distributed under the terms of the GNU General Public License v2 |
81 |
+# $Header: /var/cvsroot/gentoo-x86/app-misc/pax-utils/pax-utils-0.8.1.ebuild,v 1.1 2014/03/21 05:36:34 vapier Exp $ |
82 |
+ |
83 |
+EAPI=4 |
84 |
+ |
85 |
+inherit eutils toolchain-funcs unpacker |
86 |
+ |
87 |
+DESCRIPTION="ELF related utils for ELF 32/64 binaries that can check files for security relevant properties" |
88 |
+HOMEPAGE="http://hardened.gentoo.org/pax-utils.xml" |
89 |
+SRC_URI="mirror://gentoo/pax-utils-${PV}.tar.xz |
90 |
+ http://dev.gentoo.org/~solar/pax/pax-utils-${PV}.tar.xz |
91 |
+ http://dev.gentoo.org/~vapier/dist/pax-utils-${PV}.tar.xz" |
92 |
+ |
93 |
+LICENSE="GPL-2" |
94 |
+SLOT="0" |
95 |
+KEYWORDS="~alpha ~amd64 ~arm ~arm64 ~hppa ~ia64 ~m68k ~mips ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86 ~amd64-fbsd ~sparc-fbsd ~x86-fbsd" |
96 |
+IUSE="caps python" |
97 |
+#RESTRICT="mirror" |
98 |
+ |
99 |
+RDEPEND="caps? ( sys-libs/libcap ) |
100 |
+ python? ( dev-python/pyelftools )" |
101 |
+DEPEND="${RDEPEND} |
102 |
+ app-arch/xz-utils" |
103 |
+ |
104 |
+_emake() { |
105 |
+ emake \ |
106 |
+ USE_CAP=$(usex caps) \ |
107 |
+ USE_PYTHON=$(usex python) \ |
108 |
+ "$@" |
109 |
+} |
110 |
+ |
111 |
+src_prepare() { |
112 |
+ epatch "${FILESDIR}"/${P}-remove_DECLS.patch |
113 |
+} |
114 |
+ |
115 |
+src_compile() { |
116 |
+ _emake CC="$(tc-getCC)" |
117 |
+} |
118 |
+ |
119 |
+src_test() { |
120 |
+ _emake check |
121 |
+} |
122 |
+ |
123 |
+src_install() { |
124 |
+ _emake DESTDIR="${ED}" PKGDOCDIR='$(DOCDIR)'/${PF} install |
125 |
+} |