1 |
tetromino 12/03/05 03:03:10 |
2 |
|
3 |
Added: paxctl.sh epiphany-3.2.1-paxctl-introspection.patch |
4 |
gir-paxctl-lt-wrapper |
5 |
Log: |
6 |
Fix build problems on PaX with USE=introspection and mark /usr/bin/epiphany so that it runs on PaX when webkit-gtk was built with USE=jit. |
7 |
|
8 |
(Portage version: 2.2.0_alpha89/cvs/Linux x86_64) |
9 |
|
10 |
Revision Changes Path |
11 |
1.1 www-client/epiphany/files/paxctl.sh |
12 |
|
13 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/epiphany/files/paxctl.sh?rev=1.1&view=markup |
14 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/epiphany/files/paxctl.sh?rev=1.1&content-type=text/plain |
15 |
|
16 |
Index: paxctl.sh |
17 |
=================================================================== |
18 |
#!/bin/bash |
19 |
# PaX marking code stolen from pax-utils.eclass |
20 |
|
21 |
flags=${1//-}; shift |
22 |
|
23 |
if type -p paxctl > /dev/null; then |
24 |
echo "PT PaX marking -${flags} $@" |
25 |
for f in "$@"; do |
26 |
# First, try modifying the existing PAX_FLAGS header |
27 |
paxctl -q${flags} "${f}" && continue |
28 |
# Second, try stealing the (unused under PaX) PT_GNU_STACK header |
29 |
paxctl -qc${flags} "${f}" && continue |
30 |
# Third, try pulling the base down a page, to create space and |
31 |
# insert a PT_GNU_STACK header (works on ET_EXEC) |
32 |
paxctl -qC${flags} "${f}" && continue |
33 |
done |
34 |
elif type -p scanelf > /dev/null; then |
35 |
# Try scanelf, the Gentoo swiss-army knife ELF utility |
36 |
# Currently this sets PT if it can, no option to control what it does. |
37 |
echo "Fallback PaX marking -${flags} $@" |
38 |
scanelf -Xxz ${flags} "$@" |
39 |
fi |
40 |
|
41 |
exit 0 |
42 |
|
43 |
|
44 |
|
45 |
1.1 www-client/epiphany/files/epiphany-3.2.1-paxctl-introspection.patch |
46 |
|
47 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/epiphany/files/epiphany-3.2.1-paxctl-introspection.patch?rev=1.1&view=markup |
48 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/epiphany/files/epiphany-3.2.1-paxctl-introspection.patch?rev=1.1&content-type=text/plain |
49 |
|
50 |
Index: epiphany-3.2.1-paxctl-introspection.patch |
51 |
=================================================================== |
52 |
From f9ba4d6428f06f717eb16e83a728f82b314383f1 Mon Sep 17 00:00:00 2001 |
53 |
From: Alexandre Rostovtsev <tetromino@g.o> |
54 |
Date: Sun, 4 Mar 2012 19:47:17 -0500 |
55 |
Subject: [PATCH] Add libtool wrapper for building introspection under PaX |
56 |
|
57 |
--- |
58 |
src/Makefile.am | 4 +++- |
59 |
1 files changed, 3 insertions(+), 1 deletions(-) |
60 |
|
61 |
diff --git a/src/Makefile.am b/src/Makefile.am |
62 |
index c46160c..2aa94d1 100644 |
63 |
--- a/src/Makefile.am |
64 |
+++ b/src/Makefile.am |
65 |
@@ -299,7 +299,7 @@ EPHY_GIR_C_FILES = \ |
66 |
|
67 |
EphyEgg-$(EPIPHANY_API_VERSION).gir: $(INTROSPECTION_SCANNER) |
68 |
$(AM_V_GEN) PKG_CONFIG_PATH=$(top_builddir)/data:$$PKG_CONFIG_PATH \ |
69 |
- $(INTROSPECTION_SCANNER) -v --warn-all \ |
70 |
+ LIBTOOL="$(LIBTOOL)" $(INTROSPECTION_SCANNER) -v --warn-all \ |
71 |
--identifier-prefix=Egg \ |
72 |
--symbol-prefix=egg \ |
73 |
--namespace=EphyEgg \ |
74 |
@@ -307,6 +307,7 @@ EphyEgg-$(EPIPHANY_API_VERSION).gir: $(INTROSPECTION_SCANNER) |
75 |
--include=Gtk-3.0 \ |
76 |
--include=libxml2-2.0 \ |
77 |
--library=$(top_builddir)/lib/egg/libegg.la \ |
78 |
+ --libtool="bash $(top_srcdir)/gir-paxctl-lt-wrapper -m" \ |
79 |
--pkg=gtk+-3.0 \ |
80 |
--pkg=libxml-2.0 \ |
81 |
--output=$@ \ |
82 |
@@ -318,6 +319,7 @@ EphyEgg-$(EPIPHANY_API_VERSION).gir: $(INTROSPECTION_SCANNER) |
83 |
|
84 |
Epiphany-$(EPIPHANY_API_VERSION).gir: EphyEgg-$(EPIPHANY_API_VERSION).gir $(INTROSPECTION_SCANNER) $(EPHY_GIR_H_FILES) \ |
85 |
$(EPHY_GIR_C_FILES) epiphany |
86 |
+ bash $(top_srcdir)/paxctl.sh -m ./epiphany |
87 |
$(AM_V_GEN) PKG_CONFIG_PATH=$(top_builddir)/data:$$PKG_CONFIG_PATH \ |
88 |
$(INTROSPECTION_SCANNER) -v --warn-all \ |
89 |
--identifier-prefix=Ephy \ |
90 |
-- |
91 |
1.7.8.5 |
92 |
|
93 |
|
94 |
|
95 |
|
96 |
1.1 www-client/epiphany/files/gir-paxctl-lt-wrapper |
97 |
|
98 |
file : http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/epiphany/files/gir-paxctl-lt-wrapper?rev=1.1&view=markup |
99 |
plain: http://sources.gentoo.org/viewvc.cgi/gentoo-x86/www-client/epiphany/files/gir-paxctl-lt-wrapper?rev=1.1&content-type=text/plain |
100 |
|
101 |
Index: gir-paxctl-lt-wrapper |
102 |
=================================================================== |
103 |
#!/bin/bash |
104 |
# Wrapper for $(LIBTOOL) that performs PaX marking on the dumper binary |
105 |
# generated by g-ir-scanner. |
106 |
|
107 |
flags=${1//-}; shift |
108 |
|
109 |
echo ${LIBTOOL} "$@" |
110 |
${LIBTOOL} "$@" |
111 |
|
112 |
retval=$? |
113 |
|
114 |
bash "@S@/paxctl.sh" "${flags}" $(find . -path "*tmp-introspect*/.libs/*") |
115 |
|
116 |
exit ${retval} |